From: Simon McVittie Date: Fri, 15 Jul 2022 09:42:19 +0000 (+0100) Subject: meson: Build with -fno-strict-aliasing if supported X-Git-Tag: dbus-1.15.0~28^2~4 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=0c4ec2d2e10f1f6e31ca6e8ad3d7dbfcc9525fda;p=thirdparty%2Fdbus.git meson: Build with -fno-strict-aliasing if supported We know that dbus is not fully strict-aliasing-compliant. In Autotools we got this from AX_COMPILER_FLAGS_CFLAGS. Signed-off-by: Simon McVittie --- diff --git a/meson.build b/meson.build index 12064738d..765a5a33a 100644 --- a/meson.build +++ b/meson.build @@ -154,6 +154,11 @@ compile_args = [ '-D_GNU_SOURCE', ] +# dbus makes assumptions about aliasing that Standard C does not guarantee, +# particularly in DBusString. +# See https://gitlab.freedesktop.org/dbus/dbus/-/issues/4 +compile_args += ['-fno-strict-aliasing'] + if host_os.contains('solaris') compile_args += [ # Solaris' C library apparently needs these runes to be threadsafe...