From be0c9961912a21e4f43fb57623802f14e05b0a8e Mon Sep 17 00:00:00 2001 From: trav90 Date: Sun, 4 Mar 2018 15:05:47 -0600 Subject: [PATCH] Disable strict-aliasing for GCC in js/src Compiling our tree with strict-aliasing is not supported. --- js/src/moz.build | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/js/src/moz.build b/js/src/moz.build index 1162cb70c1..0a4abd80f3 100644 --- a/js/src/moz.build +++ b/js/src/moz.build @@ -785,7 +785,9 @@ if CONFIG['JS_HAS_CTYPES']: DEFINES['FFI_BUILDING'] = True if CONFIG['GNU_CXX']: - CXXFLAGS += ['-Wno-shadow', '-Werror=format'] + # Disable strict-aliasing for GCC, which is enabled by default + # starting with version 7.1, see Mozilla bug 1363009. + CXXFLAGS += ['-Wno-shadow', '-Werror=format', '-fno-strict-aliasing'] # Suppress warnings in third-party code. if CONFIG['CLANG_CXX']: