Skip to content

Commit 04f169a

Browse files
committed
build(cmake): add module path in config file
1 parent 596e1b4 commit 04f169a

2 files changed

Lines changed: 5 additions & 3 deletions

File tree

CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ include(cmake/Utils.cmake)
55
#
66
# Project details
77
#
8-
project(stdsharp VERSION 0.2.7.4 LANGUAGES CXX)
8+
project(stdsharp VERSION 0.2.8 LANGUAGES CXX)
99

1010
config_lib(${PROJECT_NAME} INTERFACE STD 23)
1111

@@ -37,7 +37,7 @@ target_install(
3737

3838
install(
3939
FILES cmake/Utils.cmake
40-
DESTINATION ${${PROJECT_NAME}_INSTALL_CMAKEDIR}
40+
DESTINATION ${${PROJECT_NAME}_INSTALL_CMAKEDIR}/stdsharp
4141
)
4242

4343
get_directory_property(is_subproject PARENT_DIRECTORY)

cmake/Utils.cmake

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,9 @@ function(target_install target)
169169
else()
170170
file(CONFIGURE
171171
OUTPUT "${target_config}"
172-
CONTENT "include(CMakeFindDependencyMacro)
172+
CONTENT
173+
"include(CMakeFindDependencyMacro)
174+
list(APPEND CMAKE_MODULE_PATH \"$\{CMAKE_CURRENT_LIST_DIR}\")
173175
foreach(dependency ${ARG_DEPENDENCIES})
174176
find_dependency(\"$\{dependency}\")
175177
endforeach()

0 commit comments

Comments
 (0)