summaryrefslogtreecommitdiffstats
path: root/cmake
diff options
context:
space:
mode:
authorAlexandru Croitor <alexandru.croitor@qt.io>2021-10-21 10:29:28 +0000
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2021-10-21 16:22:02 +0000
commit5049cdb87521e2ef5a68a85126b7fd2c4eb13d07 (patch)
tree97fa420bcf2ab44c04d2f93bf37c8a0d32afe763 /cmake
parent51305779291284d4a8c534d8071ac64f9c6e28ad (diff)
Revert "CMake: Fix rpath-link dependencies when cross-compiling"
This reverts commit 87215c70c0ff0bdc52dfa463f050d2aa049cdd91. Reason for revert: Breaks configuration of standalone tests in leaf modules Fixes: QTBUG-97673 Task-number: QTBUG-86533 Change-Id: Idd5014b57a8d10070108f5b235c822863dbac088 Reviewed-by: Alexey Edelev <alexey.edelev@qt.io> (cherry picked from commit 8d1db12bba73ad0b74723e58ad0f1f3134767a36) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'cmake')
-rw-r--r--cmake/QtFindPackageHelpers.cmake12
1 files changed, 2 insertions, 10 deletions
diff --git a/cmake/QtFindPackageHelpers.cmake b/cmake/QtFindPackageHelpers.cmake
index 7d8e9420e2..8519922f85 100644
--- a/cmake/QtFindPackageHelpers.cmake
+++ b/cmake/QtFindPackageHelpers.cmake
@@ -308,18 +308,10 @@ function(qt_register_target_dependencies target public_libs private_libs)
set(target_deps "")
endif()
+ # Only process private dependencies if target is a static library
get_target_property(target_type ${target} TYPE)
set(lib_list ${public_libs})
- # Record Qt target private dependencies information which will be used to generate
- # find_dependency() calls.
- #
- # Private static library dependencies become $<LINK_ONLY:> dependencies in
- # INTERFACE_LINK_LIBRARIES.
- #
- # Private shared library dependencies are listed in the target's
- # IMPORTED_LINK_DEPENDENT_LIBRARIES and used in rpath-link calculation.
- # See QTBUG-86533 for some details.
- if (target_type STREQUAL "STATIC_LIBRARY" OR target_type STREQUAL "SHARED_LIBRARY")
+ if (target_type STREQUAL "STATIC_LIBRARY")
list(APPEND lib_list ${private_libs})
endif()