aboutsummaryrefslogtreecommitdiff
path: root/ports/qtimageformats/no_target_promotion.patch
blob: 73e5f7d4e00395cb306a964594436f0ca1db4e92 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 7fdd7ddbd..f189c472c 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -9,7 +9,16 @@ project(QtImageFormats # special case
     HOMEPAGE_URL "https://qt.io/"
     LANGUAGES CXX C
 )
-
+find_package(Threads)
+set_property(TARGET Threads::Threads PROPERTY _qt_no_promote_global TRUE)
+find_package(ZLIB)
+if(TARGET ZLIB::ZLIB)
+	set_property(TARGET ZLIB::ZLIB PROPERTY _qt_no_promote_global TRUE)
+endif()
+find_package(JPEG)
+if(TARGET JPEG::JPEG)
+	set_property(TARGET JPEG::JPEG PROPERTY _qt_no_promote_global TRUE)
+endif()
 # special case begin
 # Make sure we only use latest private CMake API, aka no compatibility wrappers.
 set(QT_NO_INTERNAL_COMPATIBILITY_FUNCTIONS TRUE)