summaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
authorTim-Philipp Müller <tim@centricular.com>2018-01-30 20:34:52 +0000
committerTim-Philipp Müller <tim@centricular.com>2018-01-30 20:34:54 +0000
commit4007aaf3a7953a9002b4921f25de62a36d3daae5 (patch)
tree928117b9e81f59372ea51a6fc1b4bc3e17ea3418 /meson.build
parent63f8d33a6fd6ab6c50069355b6619289b9869e53 (diff)
meson: use -fno-strict-aliasing where supported
https://bugzilla.gnome.org/show_bug.cgi?id=769183
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build5
1 files changed, 5 insertions, 0 deletions
diff --git a/meson.build b/meson.build
index eb96b7ba..72e785a9 100644
--- a/meson.build
+++ b/meson.build
@@ -47,6 +47,11 @@ if cc.has_argument('-fvisibility=hidden')
add_project_arguments('-fvisibility=hidden', language: 'c')
endif
+# Disable strict aliasing
+if cc.has_argument('-fno-strict-aliasing')
+ add_project_arguments('-fno-strict-aliasing', language: 'c')
+endif
+
cdata = configuration_data()
check_headers = [
['HAVE_DLFCN_H', 'dlfcn.h'],