diff options
author | thakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-05-04 15:33:19 +0000 |
---|---|---|
committer | thakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-05-04 15:33:19 +0000 |
commit | 57e9402cd9f5451c8a9b307a0d135abe0b938665 (patch) | |
tree | d4defb9171f2e7a07e39e257d0151982c2703138 /build | |
parent | b562cf28ce23bd27eadc3624f4a31d472ee2aa78 (diff) | |
download | chromium_src-57e9402cd9f5451c8a9b307a0d135abe0b938665.zip chromium_src-57e9402cd9f5451c8a9b307a0d135abe0b938665.tar.gz chromium_src-57e9402cd9f5451c8a9b307a0d135abe0b938665.tar.bz2 |
Mac: Explicitly disable -fstrict-aliasing.
Mark says: "When GCC_STRICT_ALIASING is YES, Xcode adds -fstrict-aliasing to the compiler command line. When it’s NO, it doesn’t add anything (not even -fno-strict-aliasing). Xcode doesn’t know that -fstrict-aliasing is on at our selected optimization level."
So add this directly to OTHER_CLFAGS.
BUG=32204
TEST=none
Review URL: http://codereview.chromium.org/6909037
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@84064 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'build')
-rw-r--r-- | build/common.gypi | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/build/common.gypi b/build/common.gypi index 81f2dca..7ce6a47 100644 --- a/build/common.gypi +++ b/build/common.gypi @@ -1028,12 +1028,7 @@ # Enable -Werror by default, but put it in a variable so it can # be disabled in ~/.gyp/include.gypi on the valgrind builders. 'variables': { - # Use -fno-strict-aliasing by default since gcc 4.4 has periodic - # issues that slip through the cracks. We could do this just for - # gcc 4.4 but it makes more sense to be consistent on all - # compilers in use. TODO(Craig): turn this off again when - # there is some 4.4 test infrastructure in place and existing - # aliasing issues have been fixed. + # Use -fno-strict-aliasing, see http://crbug.com/32204 'no_strict_aliasing%': 1, 'conditions': [['OS=="linux"', {'werror%': '-Werror',}], ['OS=="freebsd"', {'werror%': '',}], @@ -1382,6 +1377,9 @@ 'MACOSX_DEPLOYMENT_TARGET': '<(mac_deployment_target)', 'PREBINDING': 'NO', # No -Wl,-prebind 'USE_HEADERMAP': 'NO', + 'OTHER_CFLAGS': [ + '-fno-strict-aliasing', # See http://crbug.com/32204 + ], 'WARNING_CFLAGS': [ '-Wall', '-Wendif-labels', |