Skip to content

Commit 29408da

Browse files
committed
Fix configure check for freetype version
Unfortunately the versions reported by system freetype packages with pkg-config are not always consistent with the actual freetype version. Instead, we now use a compile time check, similar to what the corresponding check for qtgui does. Change-Id: I3316f5dfe423ffead5fd9cfec1542407c2b21bd8 Fixes: QTBUG-71033 Reviewed-by: Allan Sandfeld Jensen <[email protected]>
1 parent 3edd946 commit 29408da

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

configure.json

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -205,8 +205,21 @@
205205
},
206206
"webengine-freetype": {
207207
"label": "freetype >= 2.4.2",
208+
"test": {
209+
"head": [
210+
"#include <ft2build.h>",
211+
"#include FT_FREETYPE_H",
212+
"#if ((FREETYPE_MAJOR*10000 + FREETYPE_MINOR*100 + FREETYPE_PATCH) < 20402)",
213+
"# error This version of freetype is too old.",
214+
"#endif"
215+
],
216+
"main": [
217+
"FT_Face ft_face = 0;",
218+
"FT_Reference_Face(ft_face);"
219+
]
220+
},
208221
"sources": [
209-
{ "type": "pkgConfig", "args": "freetype2 >= 2.4.2" }
222+
{ "type": "pkgConfig", "args": "freetype2" }
210223
]
211224
}
212225
},

0 commit comments

Comments
 (0)