summaryrefslogtreecommitdiffhomepage
path: root/cmake
diff options
context:
space:
mode:
Diffstat (limited to 'cmake')
-rw-r--r--cmake/opentrack-hier.cmake4
-rw-r--r--cmake/opentrack-platform.cmake6
2 files changed, 7 insertions, 3 deletions
diff --git a/cmake/opentrack-hier.cmake b/cmake/opentrack-hier.cmake
index a9c1ee1a..632c5902 100644
--- a/cmake/opentrack-hier.cmake
+++ b/cmake/opentrack-hier.cmake
@@ -1,6 +1,6 @@
if(NOT opentrack-hier-included)
set(opentrack-hier-included TRUE)
-
+ set(opentrack-install-rpath "")
if(APPLE)
set(opentrack-hier-pfx ".")
set(opentrack-hier-path "/")
@@ -21,7 +21,7 @@ if(NOT opentrack-hier-included)
set(opentrack-hier-doc "/share/doc/opentrack/")
set(opentrack-doc-pfx "./share/doc/opentrack")
set(opentrack-doc-src-pfx "./share/doc/opentrack/source-code")
- set(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}/${opentrack-hier-pfx}")
+ set(opentrack-install-rpath "${CMAKE_INSTALL_PREFIX}/${opentrack-hier-pfx}")
set(opentrack-hier-str ARCHIVE DESTINATION lib/opentrack LIBRARY DESTINATION ${opentrack-hier-pfx} RUNTIME DESTINATION bin)
endif()
diff --git a/cmake/opentrack-platform.cmake b/cmake/opentrack-platform.cmake
index dac307eb..23558981 100644
--- a/cmake/opentrack-platform.cmake
+++ b/cmake/opentrack-platform.cmake
@@ -14,11 +14,15 @@ if(WIN32)
ENABLE_LANGUAGE(RC)
endif(WIN32)
+if(opentrack-install-rpath)
+ set(CMAKE_INSTALL_RPATH "${opentrack-install-rpath}")
+else()
+ set(CMAKE_INSTALL_RPATH "${CMAKE_INSTALL_PREFIX}")
+endif()
set(CMAKE_BUILD_WITH_INSTALL_RPATH TRUE)
set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE)
set(CMAKE_SKIP_INSTALL_RPATH FALSE)
set(CMAKE_SKIP_RPATH FALSE)
-set(CMAKE_INSTALL_RPATH ${CMAKE_INSTALL_PREFIX})
set(CMAKE_INCLUDE_CURRENT_DIR ON)
set(CMAKE_AUTOMOC OFF)
set(CMAKE_POSITION_INDEPENDENT_CODE ON)