aboutsummarylogtreecommitdiffstats
path: root/0011-Fix-linking-against-static-freetype2.patch
blob: 911a609e6a7a14da8e6c1e69bf95e5d257bf3ddd (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
From f4d9c0c1b22a122df1393b47d485a0f4416ad8bc Mon Sep 17 00:00:00 2001
From: Martchus <martchus@gmx.net>
Date: Fri, 3 Feb 2017 20:51:19 +0100
Subject: [PATCH 11/33] Fix linking against static freetype2

---
 src/gui/configure.json | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

diff --git a/src/gui/configure.json b/src/gui/configure.json
index dbb6f708b0..a7ffa0f113 100644
--- a/src/gui/configure.json
+++ b/src/gui/configure.json
@@ -163,9 +163,12 @@
                 ]
             },
             "sources": [
-                { "type": "pkgConfig", "args": "freetype2" },
-                { "type": "freetype", "libs": "-lfreetype", "condition": "!config.wasm" },
-                { "type": "freetype", "libs": "-s USE_FREETYPE=1", "condition": "config.wasm" }
+                { "type": "pkgConfig", "args": "--static --libs freetype2", "condition": "!features.shared" },
+                { "type": "pkgConfig", "args": "--libs freetype2", "condition": "features.shared" },
+                { "libs": "-lfreetype -lharfbuzz -lfreetype -lglib-2.0 -lintl -lws2_32 -lole32 -lwinmm -lshlwapi -lpcre -lintl -lpcre -lintl -liconv -lgraphite2 -lbz2", "condition": "!features.shared && !config.wasm" },
+                { "libs": "-Wl,-Bdynamic -lfreetype -Wl,-Bstatic", "condition": "!features.shared && !config.wasm" },
+                { "libs": "-lfreetype", "condition": "features.shared && !config.wasm" },
+                { "type": "freetype", "libs": "-s USE_FREETYPE=1", "condition": "features.shared && config.wasm" }
             ]
         },
         "fontconfig": {
-- 
2.19.2