CMake: Fix building tests with qt-cmake-standalone-test
We now require user projects to use find_package(Qt6FooPrivate) if the Qt6::FooPrivate target is used. We don't require this for Qt's autotests. But configuring such a test with qt-cmake-standalone-test failed. Fix this by setting QT_FIND_PRIVATE_MODULES to ON in the CMake project template for standalone tests. Change-Id: I778cbfc16638a94b5fe538c175394501df106b82 Reviewed-by: Alexey Edelev <alexey.edelev@qt.io>
This commit is contained in:
parent
58b9250aea
commit
a9f26c3f9a
@ -4,6 +4,9 @@
|
||||
# Includes QtSetup and friends for private CMake API.
|
||||
set(QT_INTERNAL_IS_STANDALONE_TEST TRUE)
|
||||
|
||||
# Make find_package(Qt6 COMPONENTS Foo) pull in FooPrivate too.
|
||||
set(QT_FIND_PRIVATE_MODULES TRUE)
|
||||
|
||||
# Checks minimum CMake version and upgrades policies.
|
||||
qt_internal_project_setup()
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user