summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@qt.io>2020-03-31 09:39:50 +0200
committerJoerg Bornemann <joerg.bornemann@qt.io>2020-04-01 21:19:32 +0200
commitc20f23e03b3208f445202f5b071f0b62de1b7d01 (patch)
treef48d34821513b90ce63afdd288e2acde59977c71
parenta97703d33a088865e5d3b077a36cdea1f2725ac3 (diff)
CMake: Port the 'rpath' feature
This is needed for qmake mixing. Change-Id: I368169606606a8de4dc8f2db5b98660a0a2fa349 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Leander Beernaert <leander.beernaert@qt.io>
-rw-r--r--configure.cmake6
-rwxr-xr-xutil/cmake/configurejson2cmake.py7
2 files changed, 11 insertions, 2 deletions
diff --git a/configure.cmake b/configure.cmake
index c11a2a4933..a842b8b317 100644
--- a/configure.cmake
+++ b/configure.cmake
@@ -387,6 +387,12 @@ qt_feature("simulator_and_device" PUBLIC
CONDITION UIKIT AND NOT QT_UIKIT_SDK
)
qt_feature_config("simulator_and_device" QMAKE_PUBLIC_QT_CONFIG)
+qt_feature("rpath" PUBLIC
+ LABEL "Build with RPATH"
+ AUTODETECT 1
+ CONDITION BUILD_SHARED_LIBS AND UNIX AND NOT WIN32 AND NOT ANDROID AND NOT APPLE
+)
+qt_feature_config("rpath" QMAKE_PUBLIC_QT_CONFIG)
qt_feature("force_asserts" PUBLIC
LABEL "Force assertions"
AUTODETECT OFF
diff --git a/util/cmake/configurejson2cmake.py b/util/cmake/configurejson2cmake.py
index b8e32c9cc9..ec734a9ef8 100755
--- a/util/cmake/configurejson2cmake.py
+++ b/util/cmake/configurejson2cmake.py
@@ -817,8 +817,11 @@ def get_feature_mapping():
"qpa_default_platform": None, # Not a bool!
"release": None,
"release_tools": None,
- "rpath_dir": None, # rpath related
- "rpath": None,
+ "rpath_dir": None, # merely used to fill the qmake variable EXTRA_RPATHS
+ "rpath": {
+ "autoDetect": "1",
+ "condition": "BUILD_SHARED_LIBS AND UNIX AND NOT WIN32 AND NOT ANDROID AND NOT APPLE"
+ },
"sanitize_address": None, # sanitizer
"sanitize_memory": None,
"sanitizer": None,