From 07195cea8b29d5cb919c2d0262e60104a2d3f403 Mon Sep 17 00:00:00 2001 From: Christian Stenger Date: Fri, 29 Apr 2022 12:13:53 +0200 Subject: [PATCH] Fix cmake build Amends 88781a003ff. Change-Id: I37aa5c3fbf6490a186deacae257858d3ceb817d1 Reviewed-by: Cristian Adam --- cmake/FindQt5.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmake/FindQt5.cmake b/cmake/FindQt5.cmake index b64f3bdb178..fc16ec17237 100644 --- a/cmake/FindQt5.cmake +++ b/cmake/FindQt5.cmake @@ -61,13 +61,13 @@ set(__additional_imported_components ATSPI2_nolink) # Work around QTBUG-97023 foreach(comp IN LISTS Qt5_FIND_COMPONENTS __additional_imported_components) if(TARGET Qt6::${comp}) if (NOT TARGET Qt5::${comp}) - if (QT_BUILD_SHARED_LIBS) + if (NOT QT_FEATURE_static) set_property(TARGET Qt6::${comp} PROPERTY IMPORTED_GLOBAL TRUE) endif() add_library(Qt5::${comp} ALIAS Qt6::${comp}) endif() if (TARGET Qt6::${comp}Private AND NOT TARGET Qt5::${comp}Private) - if (QT_BUILD_SHARED_LIBS) + if (NOT QT_FEATURE_static) set_property(TARGET Qt6::${comp}Private PROPERTY IMPORTED_GLOBAL TRUE) endif() add_library(Qt5::${comp}Private ALIAS Qt6::${comp}Private)