summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexey Edelev <alexey.edelev@qt.io>2023-02-24 11:30:38 +0100
committerAlexey Edelev <alexey.edelev@qt.io>2023-03-01 09:54:58 +0000
commit216b560023c23b85e906350e1acfae6985b043fd (patch)
tree7e4bffe720515bee8507c32c142755c3b6989783
parentb507454edb7f12d478a33bb945f52d153b1866ee (diff)
Disable -fPIE for tools that depend on 3rdparty libs
If the 3rdparty libs are not built with -fPIE enabled we cannot link it to the tools. Disable the flag until provisioning got the proper update. Change-Id: I25aa3dcec480219e3d29225ee517d9a910a1966e Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io> (cherry picked from commit 6deec055f952070caf19e537b223eb1dbeb509a1) Reviewed-by: Jani Heikkinen <jani.heikkinen@qt.io>
-rw-r--r--src/linguist/lupdate/CMakeLists.txt6
-rw-r--r--src/qdoc/CMakeLists.txt4
2 files changed, 10 insertions, 0 deletions
diff --git a/src/linguist/lupdate/CMakeLists.txt b/src/linguist/lupdate/CMakeLists.txt
index 0a1214f04..56d4ad301 100644
--- a/src/linguist/lupdate/CMakeLists.txt
+++ b/src/linguist/lupdate/CMakeLists.txt
@@ -95,6 +95,12 @@ qt_internal_extend_target(${target_name} CONDITION QT_FEATURE_clangcpp
WrapLibClang::WrapLibClang
)
+if(QT_FEATURE_clangcpp)
+ # If libclangTooling.a is not built with -fPIE enabled we cannot link it to lupdate.
+ # TODO: Re-enable PIE once clang is built with PIE in provisioning.
+ set_target_properties(${target_name} PROPERTIES POSITION_INDEPENDENT_CODE FALSE)
+endif()
+
qt_internal_extend_target(${target_name} CONDITION MSVC
DEFINES _SILENCE_CXX17_ITERATOR_BASE_CLASS_DEPRECATION_WARNING)
diff --git a/src/qdoc/CMakeLists.txt b/src/qdoc/CMakeLists.txt
index b3b1ef5ef..9d8682279 100644
--- a/src/qdoc/CMakeLists.txt
+++ b/src/qdoc/CMakeLists.txt
@@ -96,6 +96,10 @@ qt_internal_add_tool(${target_name}
)
qt_internal_return_unless_building_tools()
+# If libclangTooling.a is not built with -fPIE enabled we cannot link it to qdoc.
+# TODO: Re-enable PIE once clang is built with PIE in provisioning.
+set_target_properties(${target_name} PROPERTIES POSITION_INDEPENDENT_CODE FALSE)
+
qt_internal_extend_target(${target_name} CONDITION TARGET Qt::QmlPrivate
LIBRARIES
Qt::QmlPrivate