summaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorChun-wei Fan <fanchunwei@src.gnome.org>2020-01-13 17:00:42 +0800
committerChun-wei Fan <fanchunwei@src.gnome.org>2020-04-29 16:52:01 +0800
commit57bd4e89ca4dda00d50fec4735e2d58317616ecf (patch)
tree54727035f132e32157b74071d64665dcf8c6816e /meson.build
parent641bac83e310e9882b796ee53faa17202a8fd325 (diff)
tests: Fix building tests with FreeType but no FontConfig
Cairo could have been built with FreeType support but has no FontConfig support, so we need to check for that too. Also allow building the tests on Windows even if FontConfig is not found, as a result.
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build3
1 files changed, 2 insertions, 1 deletions
diff --git a/meson.build b/meson.build
index 88d2fd7..03da81a 100644
--- a/meson.build
+++ b/meson.build
@@ -146,7 +146,8 @@ boost_unit_test_framework_dep = dependency('boost', modules: 'unit_test_framewor
static: true, version: '>=1.33.1', required: false)
fontconfig_dep = dependency('fontconfig', required: false)
test_dep = [ boost_unit_test_framework_dep, fontconfig_dep]
-can_test = boost_unit_test_framework_dep.found() and fontconfig_dep.found()
+can_test = boost_unit_test_framework_dep.found() and \
+ (fontconfig_dep.found() or host_machine.system() == 'windows')
build_tests = build_tests_opt == 'true' or \
(build_tests_opt == 'if-dependencies-found' and can_test)
if build_tests and not can_test