summaryrefslogtreecommitdiffstats
path: root/Modules/Platform/HP-UX.cmake
diff options
context:
space:
mode:
authorMatthew Hanna <mhanna21@bloomberg.net>2016-05-17 15:53:27 (GMT)
committerBrad King <brad.king@kitware.com>2016-05-17 17:36:29 (GMT)
commit5a21557b339e389d6988895c6322562ff531e5d7 (patch)
treeb4734b8ac9c8c17cdc1e4f0db846dd6841ddb60c /Modules/Platform/HP-UX.cmake
parent7d2a0aa76c25d92f1e2a03778f5666bdd7e56b92 (diff)
downloadCMake-5a21557b339e389d6988895c6322562ff531e5d7.zip
CMake-5a21557b339e389d6988895c6322562ff531e5d7.tar.gz
CMake-5a21557b339e389d6988895c6322562ff531e5d7.tar.bz2
AIX,HP: Allow user to override the default runtime path (libpath)
The `CMAKE_PLATFORM_REQUIRED_RUNTIME_PATH` is used by CMake to always append `-Wl,-blibpath:/usr/lib:/lib` to the link line. This is needed by default on these platforms but needs to be overridden in some use cases (e.g. an environment in which one maintains versioned shared libraries). Change our logic to set this value only if it not already set by the user, project, or toolchain file.
Diffstat (limited to 'Modules/Platform/HP-UX.cmake')
-rw-r--r--Modules/Platform/HP-UX.cmake4
1 files changed, 3 insertions, 1 deletions
diff --git a/Modules/Platform/HP-UX.cmake b/Modules/Platform/HP-UX.cmake
index 88932ad..9572a7e 100644
--- a/Modules/Platform/HP-UX.cmake
+++ b/Modules/Platform/HP-UX.cmake
@@ -1,4 +1,6 @@
-set(CMAKE_PLATFORM_REQUIRED_RUNTIME_PATH /usr/lib)
+if(NOT DEFINED CMAKE_PLATFORM_REQUIRED_RUNTIME_PATH)
+ set(CMAKE_PLATFORM_REQUIRED_RUNTIME_PATH /usr/lib)
+endif()
if(NOT CMAKE_SYSTEM_PROCESSOR STREQUAL "ia64")
set(CMAKE_SHARED_LIBRARY_SUFFIX ".sl") # .so