aboutsummaryrefslogtreecommitdiffstats
path: root/cmake
diff options
context:
space:
mode:
authorEike Ziller <eike.ziller@qt.io>2021-07-07 13:55:37 +0200
committerEike Ziller <eike.ziller@qt.io>2021-07-07 14:07:06 +0000
commitcd843318485749d4e019a3f039ba16dc18079a7a (patch)
tree7e6f6eba36ac534c54a4163a64853516048d732e /cmake
parent42141fed2620e4aedc0e6e9f3ca2c2844846127d (diff)
CMake build: Fix workaround for new *Private targets with CMake < 3.18
Amends a803d04c171b31ec90c1ea2bb82930a967027ec8 Change-Id: I2df067d988a79845f4a9f85485c13e5e2f8019dc Reviewed-by: Christian Stenger <christian.stenger@qt.io> Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
Diffstat (limited to 'cmake')
-rw-r--r--cmake/FindQt5.cmake1
1 files changed, 1 insertions, 0 deletions
diff --git a/cmake/FindQt5.cmake b/cmake/FindQt5.cmake
index ae58487eea..dbbb07681f 100644
--- a/cmake/FindQt5.cmake
+++ b/cmake/FindQt5.cmake
@@ -48,6 +48,7 @@ else()
if(dcIndex GREATER_EQUAL 0)
find_package(Qt6${possible_private_libs}Private CONFIG QUIET)
if(TARGET Qt6::${possible_private_libs}Private)
+ set_property(TARGET Qt6::${possible_private_libs}Private PROPERTY IMPORTED_GLOBAL TRUE)
add_library(Qt5::${possible_private_libs} ALIAS Qt6::${possible_private_libs}Private)
list(REMOVE_AT Qt5_FIND_COMPONENTS ${dcIndex})
endif()