From: Thomas Debesse Date: Fri, 31 May 2019 22:17:18 +0000 (+0200) Subject: cmake: avoid useless dot dir in the middle of some paths X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=079e086248fa3b2c7122f5992755df519b5b97bf;p=xonotic%2Fnetradiant.git cmake: avoid useless dot dir in the middle of some paths avoid annoying something/./something --- diff --git a/CMakeLists.txt b/CMakeLists.txt index fd6e6f5f..f8aa635e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -25,14 +25,14 @@ endif () set(RADIANT_BASENAME netradiant CACHE INTERNAL "...") add_definitions(-DRADIANT_BASENAME="${RADIANT_BASENAME}") -set(RADIANT_LIB_SUBDIR . CACHE INTERNAL "...") -set(RADIANT_BIN_SUBDIR . CACHE INTERNAL "...") -set(RADIANT_DATA_SUBDIR . CACHE INTERNAL "...") +set(RADIANT_LIB_DIR ${CMAKE_INSTALL_PREFIX} CACHE INTERNAL "...") +set(RADIANT_BIN_DIR ${CMAKE_INSTALL_PREFIX} CACHE INTERNAL "...") +set(RADIANT_DATA_DIR ${CMAKE_INSTALL_PREFIX} CACHE INTERNAL "...") if (FHS_INSTALL) - set(RADIANT_LIB_SUBDIR lib/${RADIANT_BASENAME}) - set(RADIANT_BIN_SUBDIR bin) - set(RADIANT_DATA_SUBDIR share/${RADIANT_BASENAME}) + set(RADIANT_LIB_DIR lib/${RADIANT_BASENAME}) + set(RADIANT_BIN_DIR bin) + set(RADIANT_DATA_DIR share/${RADIANT_BASENAME}) endif () #----------------------------------------------------------------------- @@ -291,7 +291,7 @@ if (BUILD_BINARIES) add_executable(${name} ${ARGN}) install( TARGETS ${name} - RUNTIME DESTINATION ${RADIANT_BIN_SUBDIR} + RUNTIME DESTINATION ${RADIANT_BIN_DIR} ) endmacro() @@ -341,7 +341,7 @@ if (BUILD_BINARIES) install(DIRECTORY setup/data/tools docs - DESTINATION ${RADIANT_DATA_SUBDIR} + DESTINATION ${RADIANT_DATA_DIR} ) endif () @@ -357,7 +357,7 @@ if (DOWNLOAD_GAMEPACKS) install(DIRECTORY ${PROJECT_BINARY_DIR}/games ${GAME_DIRS} - DESTINATION ${RADIANT_DATA_SUBDIR} + DESTINATION ${RADIANT_DATA_DIR} ) endif() diff --git a/contrib/CMakeLists.txt b/contrib/CMakeLists.txt index 468b4f12..f2515bf8 100644 --- a/contrib/CMakeLists.txt +++ b/contrib/CMakeLists.txt @@ -8,7 +8,7 @@ macro(radiant_plugin name) copy_dlls(${name}) install( TARGETS ${name} - LIBRARY DESTINATION ${RADIANT_LIB_SUBDIR}/plugins + LIBRARY DESTINATION ${RADIANT_LIB_DIR}/plugins ) endmacro() diff --git a/plugins/CMakeLists.txt b/plugins/CMakeLists.txt index 808f3110..b3d29091 100644 --- a/plugins/CMakeLists.txt +++ b/plugins/CMakeLists.txt @@ -8,7 +8,7 @@ macro(radiant_plugin name) copy_dlls(${name}) install( TARGETS ${name} - LIBRARY DESTINATION ${RADIANT_LIB_SUBDIR}/modules + LIBRARY DESTINATION ${RADIANT_LIB_DIR}/modules ) endmacro()