Browse Source

build: disable -fstrict-aliasing for any gcc < 4.6.0

It has been conclusively demonstrated that the -fstrict-aliasing bugs in gcc's
optimizer are not limited to the 4.5.x releases only.

Fixes #3601 among others.
v0.8.7-release
Ben Noordhuis 13 years ago
parent
commit
b731c96679
  1. 9
      configure

9
configure

@ -287,12 +287,9 @@ def configure_node(o):
# turn off strict aliasing if gcc < 4.6.0 unless it's llvm-gcc # turn off strict aliasing if gcc < 4.6.0 unless it's llvm-gcc
# see http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45883 # see http://gcc.gnu.org/bugzilla/show_bug.cgi?id=45883
# see http://code.google.com/p/v8/issues/detail?id=884 # see http://code.google.com/p/v8/issues/detail?id=884
o['variables']['strict_aliasing'] = b(is_clang or cc_version >= (4,6,0)) strict_aliasing = is_clang or cc_version >= (4,6,0)
o['variables']['strict_aliasing'] = b(strict_aliasing)
# disable strict aliasing in V8 if we're compiling with gcc 4.5.x, o['variables']['v8_no_strict_aliasing'] = b(not strict_aliasing)
# it makes V8 crash in various ways
o['variables']['v8_no_strict_aliasing'] = b(
not is_clang and (4,5,0) <= cc_version < (4,6,0))
# clang has always supported -fvisibility=hidden, right? # clang has always supported -fvisibility=hidden, right?
if not is_clang and cc_version < (4,0,0): if not is_clang and cc_version < (4,0,0):

Loading…
Cancel
Save