Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add the the implicit promotion to global for Qt platform targets
Bundled 3rdparty libraries link Qt platform targets implicitly, which lead to the dependency resolution when the library is used by another targets. For qtbase this works just fine since all platform targets are not imported and they are used from a build tree. But in case if 3rdparty library is built as part of Qt repo different from qtbase platform targets are imported and trigger the global promotion in CMake. Usually qt_find_package for the 3rdparty libraries is called somewhere in src/... directory and since Qt::Platform* targets are already created in the top-level repo CMakeLists.txt by the find_package(Qt ...) call, this leads to an error. The propsed fix forces the global promotion of Qt platform targets as soon as they created by the one of the initial find_package(Qt ...) calls. Change-Id: Iceb53f9ecccbdc438f9bc3bcc836583cfd4de535 Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
- Loading branch information