2022-01-02 13:29:53 +01:00
|
|
|
From ee27a8ee0036cf79efdab7bb022a8ba2cc63dcb0 Mon Sep 17 00:00:00 2001
|
2017-06-02 18:20:04 +02:00
|
|
|
From: Martchus <martchus@gmx.net>
|
|
|
|
Date: Fri, 2 Jun 2017 16:42:07 +0200
|
2021-08-26 21:24:07 +02:00
|
|
|
Subject: [PATCH 22/32] Adjust linker flags for static build with
|
2017-06-02 18:20:04 +02:00
|
|
|
cmake/mingw-w64
|
|
|
|
|
2020-05-29 17:30:23 +02:00
|
|
|
It is not clear anymore where I picked that change up and for
|
|
|
|
what reason. Never touch a running system so let's keep it.
|
|
|
|
|
|
|
|
Change-Id: Iad665f18da5b4540f0899829a0165e1d3aa4ea60
|
2017-06-02 18:20:04 +02:00
|
|
|
---
|
2020-05-29 17:30:23 +02:00
|
|
|
src/corelib/Qt5CoreConfigExtras.cmake.in | 6 ++++++
|
|
|
|
1 file changed, 6 insertions(+)
|
2017-06-02 18:20:04 +02:00
|
|
|
|
|
|
|
diff --git a/src/corelib/Qt5CoreConfigExtras.cmake.in b/src/corelib/Qt5CoreConfigExtras.cmake.in
|
2020-09-10 21:17:46 +02:00
|
|
|
index 9da1361c95..5e802dea4c 100644
|
2017-06-02 18:20:04 +02:00
|
|
|
--- a/src/corelib/Qt5CoreConfigExtras.cmake.in
|
|
|
|
+++ b/src/corelib/Qt5CoreConfigExtras.cmake.in
|
2020-09-10 21:17:46 +02:00
|
|
|
@@ -206,3 +206,9 @@ if(NOT \"${QT_NO_CREATE_VERSIONLESS_TARGETS}\" AND NOT TARGET Qt::WinMain)
|
2020-05-29 17:30:23 +02:00
|
|
|
)
|
2019-12-13 01:00:48 +01:00
|
|
|
endif()
|
2020-05-29 17:30:23 +02:00
|
|
|
!!ENDIF
|
2017-06-02 18:20:04 +02:00
|
|
|
+
|
|
|
|
+!!IF !isEmpty(CMAKE_STATIC_WINDOWS_BUILD)
|
|
|
|
+set(_isExe $<STREQUAL:$<TARGET_PROPERTY:TYPE>,EXECUTABLE>)
|
|
|
|
+# INTERFACE_LINK_LIBRARIES is used to pass a linker flag '-static' and library ws2_32
|
|
|
|
+set_target_properties(${IMPORTED_TARGET_NAME} PROPERTIES \"INTERFACE_LINK_LIBRARIES\" \"$<${_isExe}:-static;ws2_32>\")
|
|
|
|
+unset(_isExe)
|
|
|
|
--
|
2022-01-02 13:29:53 +01:00
|
|
|
2.34.1
|
2017-06-02 18:20:04 +02:00
|
|
|
|