summarylogtreecommitdiffstats
path: root/0029-Hardcode-linker-flags-for-libqwindows.dll.patch
blob: 56059692f042ad3e76ac4b25f0800819d8ecf1a3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
From d73ee96c1fcaab9351d7e8471f2d9c1a0d842377 Mon Sep 17 00:00:00 2001
From: Martchus <martchus@gmx.net>
Date: Wed, 25 Jan 2017 23:42:30 +0100
Subject: [PATCH 29/30] Hardcode linker flags for libqwindows.dll

Otherwise incorrect order of libs leads to linker
errors
---
 src/plugins/platforms/windows/windows.pro | 19 +++++++++++++++----
 1 file changed, 15 insertions(+), 4 deletions(-)

diff --git a/src/plugins/platforms/windows/windows.pro b/src/plugins/platforms/windows/windows.pro
index 23168c10dc..e27cf1a248 100644
--- a/src/plugins/platforms/windows/windows.pro
+++ b/src/plugins/platforms/windows/windows.pro
@@ -1,11 +1,22 @@
 TARGET = qwindows
 
 QT += \
-    core-private gui-private \
-    eventdispatcher_support-private accessibility_support-private \
-    fontdatabase_support-private theme_support-private
+    core-private gui-private
 
-LIBS += -lgdi32 -ldwmapi
+# Fix linker error when building libqwindows.dll by specifying linker flags for
+# required modules manually (otherwise order is messed)
+LIBS += \
+    -lQt5EventDispatcherSupport \
+    -lQt5AccessibilitySupport \
+    -lQt5FontDatabaseSupport \
+    -lQt5ThemeSupport \
+    -lfreetype -lole32 -lgdi32 -ldwmapi
+# However, this workaround leads to the necessity of specifying include dirs manually
+INCLUDEPATH += \
+    $$QT_SOURCE_TREE/include/QtEventDispatcherSupport/5.8.0 \
+    $$QT_SOURCE_TREE/include/QtAccessibilitySupport/5.8.0 \
+    $$QT_SOURCE_TREE/include/QtFontDatabaseSupport/5.8.0 \
+    $$QT_SOURCE_TREE/include/QtThemeSupport/5.8.0
 
 include(windows.pri)
 
-- 
2.12.1