Skip to content

Commit 8d272e5

Browse files
committed
CMake: remove hardcoded CMAKECONFIG_INSTALL_DIR path
Currently this path is hardcoded to lib/cmake. Some distributions have different library path (like lib64). So reuse LIB_INSTALL_DIR for that to make CMAKECONFIG_INSTALL_DIR configurable and usable in such distros. Signed-off-by: Ruslan Bilovol <[email protected]>
1 parent bfdcf49 commit 8d272e5

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -199,9 +199,9 @@ CONFIGURE_FILE(${CMAKE_CURRENT_SOURCE_DIR}/${PROJECT_NAME}ConfigVersion.cmake.in
199199
${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}ConfigVersion.cmake @ONLY)
200200

201201
# ... for the install tree
202-
SET( CMAKECONFIG_INSTALL_DIR lib/cmake/${PROJECT_NAME} )
202+
SET( CMAKECONFIG_INSTALL_DIR ${LIB_INSTALL_DIR}/cmake/${PROJECT_NAME} )
203203
FILE( RELATIVE_PATH REL_INCLUDE_DIR
204-
"${CMAKE_INSTALL_PREFIX}/${CMAKECONFIG_INSTALL_DIR}"
204+
"${CMAKECONFIG_INSTALL_DIR}"
205205
"${CMAKE_INSTALL_PREFIX}/include" )
206206

207207
SET( ${PROJECT_NAME}_INCLUDE_DIR "\${${PROJECT_NAME}_CMAKE_DIR}/${REL_INCLUDE_DIR}" )

0 commit comments

Comments
 (0)