meson: use -fno-strict-aliasing where supported
authorTim-Philipp Müller <tim@centricular.com>
Tue, 30 Jan 2018 20:37:18 +0000 (20:37 +0000)
committerTim-Philipp Müller <tim@centricular.com>
Tue, 30 Jan 2018 20:37:22 +0000 (20:37 +0000)
https://bugzilla.gnome.org/show_bug.cgi?id=769183

meson.build

index 39c3859..419bd52 100644 (file)
@@ -96,6 +96,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
+
 if gst_dep.type_name() == 'internal'
     gst_proj = subproject('gstreamer')