summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorXavier Claessens <xavier.claessens@collabora.com>2020-10-03 22:04:04 -0400
committerXavier Claessens <xavier.claessens@collabora.com>2020-10-03 22:07:54 -0400
commitabc723366d692df2210346e0d4d3c5686e22c3ef (patch)
tree2d12aefddc9eed9d7be1d337921e60b28f822419
parent73353b3376e11e5d4b616d383569cad36c928718 (diff)
downloadfontconfig-abc723366d692df2210346e0d4d3c5686e22c3ef.tar.gz
meson: Fix build failure when compiler is not in PATH
When cross compiling gcc/clang could not exist in PATH and Meson could be using aarch64-linux-android-clang set in a cross file for example.
-rw-r--r--src/meson.build7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/meson.build b/src/meson.build
index 0065e8f..5af3818 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -31,12 +31,13 @@ fc_sources = [
]
# FIXME: obviously fragile, cc.preprocess would be sweet
+cpp = cc.cmd_array()
if cc.get_id() == 'gcc'
- cpp = ['gcc', '-E', '-P']
+ cpp += ['-E', '-P']
elif cc.get_id() == 'msvc'
- cpp = ['cl', '/EP']
+ cpp += ['/EP']
elif cc.get_id() == 'clang'
- cpp = ['clang', '-E', '-P']
+ cpp += ['-E', '-P']
else
error('FIXME: implement cc.preprocess')
endif