summaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorL. E. Segovia <amy@amyspark.me>2022-12-03 11:04:50 -0300
committerL. E. Segovia <amy@amyspark.me>2022-12-06 17:37:38 +0000
commitf69081bb94bfa75affafb17a371c1d66d91e5f19 (patch)
treec965d9b954a5cce1c698751541ac83a6a42868d0 /meson.build
parent76c01b83a96eeb4433e5d675045fb728bf30e04d (diff)
downloadlcms2-f69081bb94bfa75affafb17a371c1d66d91e5f19.tar.gz
meson: Add missing check for endianness
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build4
1 files changed, 4 insertions, 0 deletions
diff --git a/meson.build b/meson.build
index 85cb5a4..35cbec8 100644
--- a/meson.build
+++ b/meson.build
@@ -26,6 +26,10 @@ if cc.has_function_attribute('visibility:hidden')
cargs += '-DHAVE_FUNC_ATTRIBUTE_VISIBILITY=1'
endif
+if host_machine.endian() == 'big'
+ cargs = '-DWORDS_BIGENDIAN=1'
+endif
+
# Check for threadsafe variants of gmtime
if cc.has_function('gmtime_r', prefix: '#include <time.h>')
cargs += '-DHAVE_GMTIME_R=1'