]> git.rm.cloudns.org Git - xonotic/netradiant.git/commitdiff
cmake: avoid useless dot dir in the middle of some paths
authorThomas Debesse <dev@illwieckz.net>
Fri, 31 May 2019 22:17:18 +0000 (00:17 +0200)
committerThomas Debesse <dev@illwieckz.net>
Sat, 1 Jun 2019 20:52:54 +0000 (22:52 +0200)
avoid annoying something/./something

CMakeLists.txt
contrib/CMakeLists.txt
plugins/CMakeLists.txt

index fd6e6f5fdc96edf646a6e741a5cab24eabb35267..f8aa635ef99250d894a54e9987a6c3bfd8bae2af 100644 (file)
@@ -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()
 
index 468b4f12f26f2ab4f030fc4994a937167ee8dd00..f2515bf8bb235d8f91e7db81b88fa34619d96472 100644 (file)
@@ -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()
 
index 808f31108576304930fb248611dee58c3f24d822..b3d2909174cfe8490633cdb2767f04b0f356e528 100644 (file)
@@ -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()