mirror of
https://github.com/Kitware/CMake.git
synced 2026-01-11 16:32:14 -06:00
GNUInstallDirs: Make sure we test the CACHE variables
Signed-off-by: Cristian Le <git@lecris.dev>
This commit is contained in:
@@ -18,8 +18,27 @@ set(dirs
|
||||
SHAREDSTATEDIR
|
||||
SYSCONFDIR
|
||||
)
|
||||
set(dependent_dirs
|
||||
DATADIR
|
||||
LOCALEDIR
|
||||
DOCDIR
|
||||
RUNSTATEDIR
|
||||
)
|
||||
# See special cases for these in GNUInstallDirs
|
||||
if(NOT CMAKE_SYSTEM_NAME MATCHES "^(([^kF].*)?BSD|DragonFly)$")
|
||||
list(APPEND dependent_dirs INFODIR)
|
||||
endif()
|
||||
if(NOT CMAKE_SYSTEM_NAME MATCHES "^(([^k].*)?BSD|DragonFly)$"
|
||||
OR CMAKE_SYSTEM_NAME MATCHES "^(FreeBSD)$")
|
||||
list(APPEND dependent_dirs MANDIR)
|
||||
endif()
|
||||
|
||||
foreach(dir ${dirs})
|
||||
message("CMAKE_INSTALL_${dir}='${CMAKE_INSTALL_${dir}}'")
|
||||
if(dir IN_LIST dependent_dirs)
|
||||
message("CMAKE_INSTALL_${dir}='${CMAKE_INSTALL_${dir}}'")
|
||||
else()
|
||||
message("CMAKE_INSTALL_${dir}='$CACHE{CMAKE_INSTALL_${dir}}'")
|
||||
endif()
|
||||
endforeach()
|
||||
foreach(dir ${dirs})
|
||||
message("CMAKE_INSTALL_FULL_${dir}='${CMAKE_INSTALL_FULL_${dir}}'")
|
||||
|
||||
Reference in New Issue
Block a user