File tree Expand file tree Collapse file tree 4 files changed +20
-5
lines changed Expand file tree Collapse file tree 4 files changed +20
-5
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " vcpkg-cmake-module" ,
3
- "version-date" : " 2023-10-10 " ,
3
+ "version-date" : " 2023-10-11 " ,
4
4
"license" : " MIT"
5
5
}
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ include_guard(GLOBAL)
3
3
function (vcpkg_cmake_module )
4
4
# Set options
5
5
set (_opt )
6
- set (_single_opt )
6
+ set (_single_opt PACKAGE_NAME MODULE_PATH )
7
7
set (_multi_opt FILE_LIST DIRECTORY_LIST )
8
8
cmake_parse_arguments (PARSE_ARGV 0 "arg" "${_opt} " "${_single_opt} "
9
9
"${_multi_opt} " )
@@ -20,7 +20,16 @@ function(vcpkg_cmake_module)
20
20
FATAL_ERROR "Both arg_FILE_LIST and arg_DIRECTORY_LIST cannot be empty" )
21
21
endif ()
22
22
23
- set (_modules_path "_modules" )
23
+ if (NOT arg_PACKAGE_NAME )
24
+ set (arg_PACKAGE_NAME "${PORT} " )
25
+ endif ()
26
+
27
+ if (NOT arg_MODULE_PATH )
28
+ set (arg_MODULE_PATH "${arg_PACKAGE_NAME} " )
29
+ endif ()
30
+
31
+ set (_modules_dir_path "cmake" )
32
+ set (_modules_path "${_modules_dir_path} /${arg_MODULE_PATH} " )
24
33
25
34
if (arg_FILE_LIST )
26
35
foreach (_file ${arg_FILE_LIST} )
@@ -39,9 +48,10 @@ function(vcpkg_cmake_module)
39
48
40
49
file (
41
50
WRITE ${CURRENT_PACKAGES_DIR} /share/${PORT}/vcpkg-cmake-wrapper.cmake
42
- "include_guard(GLOBAL)\n\n list(APPEND CMAKE_MODULE_PATH \$ {CMAKE_CURRENT_LIST_DIR}/${_modules_path } )\n "
51
+ "include_guard(GLOBAL)\n\n list(APPEND CMAKE_MODULE_PATH \$ {CMAKE_CURRENT_LIST_DIR}/${_modules_dir_path } )\n "
43
52
)
44
53
54
+ unset (_modules_dir_path )
45
55
unset (_modules_path )
46
56
47
57
endfunction ()
Original file line number Diff line number Diff line change 5
5
"port-version" : 0
6
6
},
7
7
"vcpkg-cmake-module" : {
8
- "baseline" : " 2023-10-10 " ,
8
+ "baseline" : " 2023-10-11 " ,
9
9
"port-version" : 0
10
10
}
11
11
}
Original file line number Diff line number Diff line change 1
1
{
2
2
"versions" : [
3
+ {
4
+ "version-date" : " 2023-10-11" ,
5
+ "git-tree" : " 142c34e22ecfeb0ab76e55fcb196f67e2bbebe25" ,
6
+ "port-version" : 0
7
+ },
3
8
{
4
9
"version-date" : " 2023-10-10" ,
5
10
"git-tree" : " 5eb5bf9667874adcdf3c454039ac5d693ca314d4" ,
You can’t perform that action at this time.
0 commit comments