Skip to content

Commit 7f2745f

Browse files
committed
Remove unnecessary config PATH_VARS and move ystdlib_INSTALL_CONFIG_DIR closer to use.
1 parent 6c55590 commit 7f2745f

2 files changed

Lines changed: 1 addition & 7 deletions

File tree

CMake/ystdlib-config.cmake.in

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,6 @@ include(CMakeFindDependencyMacro)
66

77
find_dependency(Boost REQUIRED)
88

9-
set_and_check(ystdlib_INCLUDE_DIR "@PACKAGE_ystdlib_INSTALL_INCLUDE_DIR@")
10-
119
check_required_components(ystdlib)
1210

1311
# Avoid repeatedly including the targets

CMakeLists.txt

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -82,9 +82,6 @@ if(ystdlib_ENABLE_TESTS)
8282
catch_discover_tests(${UNIFIED_UNIT_TEST_TARGET} WORKING_DIRECTORY ${CMAKE_BINARY_DIR}/testbin)
8383
endif()
8484

85-
set(ystdlib_INSTALL_CONFIG_DIR ${CMAKE_INSTALL_LIBDIR}/cmake/ystdlib)
86-
set(ystdlib_INSTALL_INCLUDE_DIR ${CMAKE_INSTALL_INCLUDEDIR})
87-
8885
add_subdirectory(src/ystdlib)
8986

9087
set(ystdlib_targets
@@ -107,14 +104,13 @@ foreach(install_target_name IN LISTS ystdlib_targets)
107104
)
108105
endforeach()
109106

107+
set(ystdlib_INSTALL_CONFIG_DIR ${CMAKE_INSTALL_LIBDIR}/cmake/ystdlib)
110108
install(EXPORT ystdlib-targets NAMESPACE ystdlib:: DESTINATION ${ystdlib_INSTALL_CONFIG_DIR})
111109

112110
configure_package_config_file(
113111
${CMAKE_CURRENT_LIST_DIR}/CMake/ystdlib-config.cmake.in
114112
${CMAKE_CURRENT_BINARY_DIR}/ystdlib-config.cmake
115113
INSTALL_DESTINATION ${ystdlib_INSTALL_CONFIG_DIR}
116-
PATH_VARS
117-
ystdlib_INSTALL_INCLUDE_DIR
118114
)
119115

120116
write_basic_package_version_file(

0 commit comments

Comments
 (0)