File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -27,6 +27,9 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -pedantic -Wextra")
2727# Set fPIC for all targets
2828set (CMAKE_POSITION_INDEPENDENT_CODE ON )
2929
30+ # Set CMAKE_INSTALL_LIBDIR explicitly to lib (to avoid lib64 on CC7)
31+ set (CMAKE_INSTALL_LIBDIR lib)
32+
3033# Set the default build type to "RelWithDebInfo"
3134if (NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES )
3235 set (CMAKE_BUILD_TYPE "RelWithDebInfo"
@@ -206,10 +209,10 @@ include(GNUInstallDirs)
206209# Build targets with install rpath on Mac to dramatically speed up installation
207210# https://gitlab.kitware.com/cmake/community/wikis/doc/cmake/RPATH-handling
208211set (CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE )
209- list (FIND CMAKE_PLATFORM_IMPLICIT_LINK_DIRECTORIES "${CMAKE_INSTALL_PREFIX} /lib " isSystemDir)
212+ list (FIND CMAKE_PLATFORM_IMPLICIT_LINK_DIRECTORIES "${CMAKE_INSTALL_PREFIX} /${CMAKE_INSTALL_LIBDIR} " isSystemDir)
210213if (CMAKE_SYSTEM_NAME STREQUAL "Darwin" )
211214 if ("${isSystemDir} " STREQUAL "-1" )
212- set (CMAKE_INSTALL_RPATH "@loader_path/../lib " )
215+ set (CMAKE_INSTALL_RPATH "@loader_path/../${CMAKE_INSTALL_LIBDIR} " )
213216 endif ()
214217 set (CMAKE_BUILD_WITH_INSTALL_RPATH TRUE )
215218endif ()
You can’t perform that action at this time.
0 commit comments