From 5c70b000deb5131c116751bc3ccb7e56e2ef4d08 Mon Sep 17 00:00:00 2001 From: "Dr. David von Oheimb" Date: Thu, 14 Mar 2024 20:21:20 +0100 Subject: [PATCH] fixup! CMakeLists.txt: fix CMAKE_INSTALL_PREFIX for non-Unix and MacOS --- CMakeLists.txt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index bcf29eb7..3a0a30f6 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -62,10 +62,10 @@ if(CMAKE_SYSTEM_NAME MATCHES "Linux") # help CPackDeb please dpkg-shlibdeps if(${CMAKE_VERSION} VERSION_GREATER_EQUAL "3.20.0") set(CPACK_DEBIAN_PACKAGE_SHLIBDEPS_PRIVATE_DIRS - "../lib/${CMAKE_INSTALL_FULL_LIBDIR}") + "../lib/${CMAKE_INSTALL_LIBDIR}") else() set(CMAKE_INSTALL_RPATH # must be done before add_executable() - "../lib/${CMAKE_INSTALL_FULL_LIBDIR}") + "../lib/${CMAKE_INSTALL_LIBDIR}") endif() endif() @@ -186,15 +186,15 @@ endif() # installation and uninstall -#if(CMAKE_SYSTEM_NAME MATCHES "Linux" OR (UNIX AND NOT APPLE)) +#if(UNIX AND NOT APPLE) set(CMAKE_INSTALL_PREFIX "/usr") #else() # set(CMAKE_INSTALL_PREFIX "tmp") #endif() +include(GNUInstallDirs) # CMAKE_INSTALL_PREFIX must be set before if(DEFINED ENV{ROOTFS}) set(CMAKE_INSTALL_PREFIX $ENV{ROOTFS} CACHE PATH "comment" FORCE) endif() -include(GNUInstallDirs) # CMAKE_INSTALL_PREFIX must be set before install(FILES doc/Generic_CMP_client_API.pdf DESTINATION ${CMAKE_INSTALL_DOCDIR}-dev