summaryrefslogtreecommitdiffstats
path: root/cmake/QtModuleConfig.cmake.in
diff options
context:
space:
mode:
authorAlexandru Croitor <alexandru.croitor@qt.io>2019-06-05 22:26:12 +0200
committerAlexandru Croitor <alexandru.croitor@qt.io>2019-06-06 12:51:33 +0000
commite7d1ec61e39da682fb4942af9a9bf74a9dd5913c (patch)
tree57ff237c1cfe821f2ddc8b4e2fe4829d153077dc /cmake/QtModuleConfig.cmake.in
parent053766d7968296b171aea1410a0e00184309185c (diff)
Collect more known modules when considering private libraries in
extend_target. In extend_target(Foo) we go over all the ModulePrivate dependencies to assign them to FooPrivate. To do that we use the QT_KNOWN_MODULES variable. The problem is that the variable gets reset when we build a new repository, so when we build qtdeclarative, QT_KNOWN_MODULES has no entries for Core, Gui, etc, but only Qml, Quick, etc. And yet QmlPrivate has to depend on CorePrivate. Change the module Config.cmake files to append their target name to a global variable called QT_ALL_MODULES_FOUND_VIA_FIND_PACKAGE. The global variable gets populated every time find_package(QtFoo) is called. Use the union of QT_KNOWN_MODULES and QT_ALL_MODULES_FOUND_VIA_FIND_PACKAGE when considering FooPrivate libraries. Change-Id: Ibd9449744478cea58eb5d9737cc8887b4df92420 Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Diffstat (limited to 'cmake/QtModuleConfig.cmake.in')
-rw-r--r--cmake/QtModuleConfig.cmake.in2
1 files changed, 2 insertions, 0 deletions
diff --git a/cmake/QtModuleConfig.cmake.in b/cmake/QtModuleConfig.cmake.in
index fcf5ba4644..0522b7d1e2 100644
--- a/cmake/QtModuleConfig.cmake.in
+++ b/cmake/QtModuleConfig.cmake.in
@@ -31,3 +31,5 @@ set("@INSTALL_CMAKE_NAMESPACE@@target@_FOUND" TRUE)
if(EXISTS "${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@@target@Plugins.cmake")
include("${CMAKE_CURRENT_LIST_DIR}/@INSTALL_CMAKE_NAMESPACE@@target@Plugins.cmake")
endif()
+
+list(APPEND QT_ALL_MODULES_FOUND_VIA_FIND_PACKAGE "@target@")