diff make/linux/makefiles/gcc.make @ 235:9c2ecc2ffb12 jdk7-b31

Merge
author trims
date Fri, 11 Jul 2008 01:14:44 -0700
parents d1605aabd0a1 3e82d72933d0
children 69c752d99841
line wrap: on
line diff
--- a/make/linux/makefiles/gcc.make	Thu Jul 03 11:01:32 2008 -0700
+++ b/make/linux/makefiles/gcc.make	Fri Jul 11 01:14:44 2008 -0700
@@ -50,14 +50,7 @@
 
 VM_PICFLAG/LIBJVM = $(PICFLAG)
 VM_PICFLAG/AOUT   =
-
-ifneq ($(BUILDARCH), i486)
 VM_PICFLAG        = $(VM_PICFLAG/$(LINK_INTO))
-else
-# PIC has significant overhead on x86, build nonpic VM for now.
-# Link JVM at a "good" base location to avoid unnecessary .text patching.
-JVM_BASE_ADDR     = 0x06000000
-endif
 
 CFLAGS += $(VM_PICFLAG)
 CFLAGS += -fno-rtti
@@ -91,8 +84,17 @@
 
 # Compiler warnings are treated as errors
 WARNINGS_ARE_ERRORS = -Werror
+
 # Except for a few acceptable ones
+# Since GCC 4.3, -Wconversion has changed its meanings to warn these implicit
+# conversions which might affect the values. To avoid that, we need to turn
+# it off explicitly. 
+ifneq "$(shell expr \( $(CC_VER_MAJOR) \> 4 \) \| \( \( $(CC_VER_MAJOR) = 4 \) \& \( $(CC_VER_MINOR) \>= 3 \) \))" "0"
+ACCEPTABLE_WARNINGS = -Wpointer-arith -Wsign-compare
+else
 ACCEPTABLE_WARNINGS = -Wpointer-arith -Wconversion -Wsign-compare
+endif
+
 CFLAGS_WARN/DEFAULT = $(WARNINGS_ARE_ERRORS) $(ACCEPTABLE_WARNINGS)
 # Special cases
 CFLAGS_WARN/BYFILE = $(CFLAGS_WARN/$@)$(CFLAGS_WARN/DEFAULT$(CFLAGS_WARN/$@))