提交 c4fa11c8 编写于 作者: K kvn

6769748: Fix solaris makefiles for the case when "CC -V" produces several lines

Summary: Fix solaris makefiles for 5.10 compilers
Reviewed-by: jcoomes
上级 56fbde00
...@@ -30,7 +30,7 @@ DEBUG_CFLAGS/BYFILE = $(DEBUG_CFLAGS/$@)$(DEBUG_CFLAGS/DEFAULT$(DEBUG_CFLAGS/$@) ...@@ -30,7 +30,7 @@ DEBUG_CFLAGS/BYFILE = $(DEBUG_CFLAGS/$@)$(DEBUG_CFLAGS/DEFAULT$(DEBUG_CFLAGS/$@)
ifeq ("${Platform_compiler}", "sparcWorks") ifeq ("${Platform_compiler}", "sparcWorks")
ifeq ($(COMPILER_REV),5.8) ifeq ($(COMPILER_REV_NUMERIC),508)
# SS11 SEGV when compiling with -g and -xarch=v8, using different backend # SS11 SEGV when compiling with -g and -xarch=v8, using different backend
DEBUG_CFLAGS/compileBroker.o = $(DEBUG_CFLAGS) -xO0 DEBUG_CFLAGS/compileBroker.o = $(DEBUG_CFLAGS) -xO0
DEBUG_CFLAGS/jvmtiTagMap.o = $(DEBUG_CFLAGS) -xO0 DEBUG_CFLAGS/jvmtiTagMap.o = $(DEBUG_CFLAGS) -xO0
......
...@@ -37,7 +37,7 @@ ifeq ("${Platform_compiler}", "sparcWorks") ...@@ -37,7 +37,7 @@ ifeq ("${Platform_compiler}", "sparcWorks")
OPT_CFLAGS/SLOWER = -xO2 OPT_CFLAGS/SLOWER = -xO2
# Problem with SS12 compiler, dtrace doesn't like the .o files (bug 6693876) # Problem with SS12 compiler, dtrace doesn't like the .o files (bug 6693876)
ifeq ($(COMPILER_REV), 5.9) ifeq ($(COMPILER_REV_NUMERIC), 509)
# To avoid jvm98 crash # To avoid jvm98 crash
OPT_CFLAGS/instanceKlass.o = $(OPT_CFLAGS/SLOWER) OPT_CFLAGS/instanceKlass.o = $(OPT_CFLAGS/SLOWER)
# Not clear this workaround could be skipped in some cases. # Not clear this workaround could be skipped in some cases.
...@@ -46,25 +46,25 @@ ifeq ($(COMPILER_REV), 5.9) ...@@ -46,25 +46,25 @@ ifeq ($(COMPILER_REV), 5.9)
OPT_CFLAGS/jni.o = $(OPT_CFLAGS/SLOWER) OPT_CFLAGS/jni.o = $(OPT_CFLAGS/SLOWER)
endif endif
ifeq ($(COMPILER_REV), 5.5) ifeq ($(COMPILER_REV_NUMERIC), 505)
# CC 5.5 has bug 4908364 with -xO4 (Fixed in 5.6) # CC 5.5 has bug 4908364 with -xO4 (Fixed in 5.6)
OPT_CFLAGS/library_call.o = $(OPT_CFLAGS/SLOWER) OPT_CFLAGS/library_call.o = $(OPT_CFLAGS/SLOWER)
endif # COMPILER_REV == 5.5 endif # COMPILER_REV_NUMERIC == 505
ifeq ($(shell expr $(COMPILER_REV) \<= 5.4), 1) ifeq ($(shell expr $(COMPILER_REV_NUMERIC) \<= 504), 1)
# Compilation of *_<arch>.cpp can take an hour or more at O3. Use O2 # Compilation of *_<arch>.cpp can take an hour or more at O3. Use O2
# See comments at top of sparc.make. # See comments at top of sparc.make.
OPT_CFLAGS/ad_$(Platform_arch).o = $(OPT_CFLAGS/SLOWER) OPT_CFLAGS/ad_$(Platform_arch).o = $(OPT_CFLAGS/SLOWER)
OPT_CFLAGS/dfa_$(Platform_arch).o = $(OPT_CFLAGS/SLOWER) OPT_CFLAGS/dfa_$(Platform_arch).o = $(OPT_CFLAGS/SLOWER)
endif # COMPILER_REV <= 5.4 endif # COMPILER_REV_NUMERIC <= 504
ifeq (${COMPILER_REV}, 5.0) ifeq (${COMPILER_REV_NUMERIC}, 500)
# Avoid a compiler bug caused by using -xO<level> -g<level> # Avoid a compiler bug caused by using -xO<level> -g<level>
# Since the bug also occurs with -xO0, use an innocuous value (must not be null) # Since the bug also occurs with -xO0, use an innocuous value (must not be null)
OPT_CFLAGS/c1_LIROptimizer_i486.o = -c OPT_CFLAGS/c1_LIROptimizer_i486.o = -c
endif endif
ifeq ($(shell expr $(COMPILER_REV) \< 5.5), 1) ifeq ($(shell expr $(COMPILER_REV_NUMERIC) \< 505), 1)
# Same problem with Solaris/x86 compiler (both 5.0 and 5.2) on ad_i486.cpp. # Same problem with Solaris/x86 compiler (both 5.0 and 5.2) on ad_i486.cpp.
# CC build time is also too long for ad_i486_{gen,misc}.o # CC build time is also too long for ad_i486_{gen,misc}.o
OPT_CFLAGS/ad_i486.o = -c OPT_CFLAGS/ad_i486.o = -c
......
...@@ -36,16 +36,12 @@ ifeq ("${Platform_compiler}", "sparcWorks") ...@@ -36,16 +36,12 @@ ifeq ("${Platform_compiler}", "sparcWorks")
# _lwp_create_interpose must have a frame # _lwp_create_interpose must have a frame
OPT_CFLAGS/os_solaris_i486.o = -xO1 OPT_CFLAGS/os_solaris_i486.o = -xO1
# force C++ interpreter to be full optimization
OPT_CFLAGS/interpret.o = -fast -O4
else else
ifeq ("${Platform_compiler}", "gcc") ifeq ("${Platform_compiler}", "gcc")
# gcc # gcc
# _lwp_create_interpose must have a frame # _lwp_create_interpose must have a frame
OPT_CFLAGS/os_solaris_i486.o = -fno-omit-frame-pointer OPT_CFLAGS/os_solaris_i486.o = -fno-omit-frame-pointer
# force C++ interpreter to be full optimization
OPT_CFLAGS/interpret.o = -O3
# #
else else
# error # error
...@@ -57,7 +53,7 @@ endif ...@@ -57,7 +53,7 @@ endif
ifeq ("${Platform_compiler}", "sparcWorks") ifeq ("${Platform_compiler}", "sparcWorks")
# ILD is gone as of SS11 (5.8), not supported in SS10 (5.7) # ILD is gone as of SS11 (5.8), not supported in SS10 (5.7)
ifeq ($(shell expr $(COMPILER_REV) \< 5.7), 1) ifeq ($(shell expr $(COMPILER_REV_NUMERIC) \< 507), 1)
# #
# Bug in ild causes it to fail randomly. Until we get a fix we can't # Bug in ild causes it to fail randomly. Until we get a fix we can't
# use ild. # use ild.
......
...@@ -30,7 +30,7 @@ DEBUG_CFLAGS/BYFILE = $(DEBUG_CFLAGS/$@)$(DEBUG_CFLAGS/DEFAULT$(DEBUG_CFLAGS/$@) ...@@ -30,7 +30,7 @@ DEBUG_CFLAGS/BYFILE = $(DEBUG_CFLAGS/$@)$(DEBUG_CFLAGS/DEFAULT$(DEBUG_CFLAGS/$@)
ifeq ("${Platform_compiler}", "sparcWorks") ifeq ("${Platform_compiler}", "sparcWorks")
ifeq ($(COMPILER_REV),5.8) ifeq ($(COMPILER_REV_NUMERIC),508)
# SS11 SEGV when compiling with -g and -xarch=v8, using different backend # SS11 SEGV when compiling with -g and -xarch=v8, using different backend
DEBUG_CFLAGS/compileBroker.o = $(DEBUG_CFLAGS) -xO0 DEBUG_CFLAGS/compileBroker.o = $(DEBUG_CFLAGS) -xO0
DEBUG_CFLAGS/jvmtiTagMap.o = $(DEBUG_CFLAGS) -xO0 DEBUG_CFLAGS/jvmtiTagMap.o = $(DEBUG_CFLAGS) -xO0
......
...@@ -33,7 +33,7 @@ OPT_CFLAGS/BYFILE = $(OPT_CFLAGS/$@)$(OPT_CFLAGS/DEFAULT$(OPT_CFLAGS/$@)) ...@@ -33,7 +33,7 @@ OPT_CFLAGS/BYFILE = $(OPT_CFLAGS/$@)$(OPT_CFLAGS/DEFAULT$(OPT_CFLAGS/$@))
ifeq ("${Platform_compiler}", "sparcWorks") ifeq ("${Platform_compiler}", "sparcWorks")
# Problem with SS12 compiler, dtrace doesn't like the .o files (bug 6693876) # Problem with SS12 compiler, dtrace doesn't like the .o files (bug 6693876)
ifeq ($(COMPILER_REV),5.9) ifeq ($(COMPILER_REV_NUMERIC),509)
# Not clear this workaround could be skipped in some cases. # Not clear this workaround could be skipped in some cases.
OPT_CFLAGS/vmGCOperations.o = $(OPT_CFLAGS/SLOWER) -g OPT_CFLAGS/vmGCOperations.o = $(OPT_CFLAGS/SLOWER) -g
OPT_CFLAGS/java.o = $(OPT_CFLAGS/SLOWER) -g OPT_CFLAGS/java.o = $(OPT_CFLAGS/SLOWER) -g
...@@ -41,9 +41,9 @@ ifeq ($(COMPILER_REV),5.9) ...@@ -41,9 +41,9 @@ ifeq ($(COMPILER_REV),5.9)
endif endif
# Workaround SS11 bug 6345274 (all platforms) (Fixed in SS11 patch and SS12) # Workaround SS11 bug 6345274 (all platforms) (Fixed in SS11 patch and SS12)
ifeq ($(COMPILER_REV),5.8)) ifeq ($(COMPILER_REV_NUMERIC),508))
OPT_CFLAGS/ciTypeFlow.o = $(OPT_CFLAGS/O2) OPT_CFLAGS/ciTypeFlow.o = $(OPT_CFLAGS/O2)
endif # COMPILER_REV == 5.8 endif # COMPILER_REV_NUMERIC == 508
endif # Platform_compiler == sparcWorks endif # Platform_compiler == sparcWorks
......
...@@ -41,7 +41,7 @@ endif ...@@ -41,7 +41,7 @@ endif
ifeq ("${Platform_compiler}", "sparcWorks") ifeq ("${Platform_compiler}", "sparcWorks")
# Problem with SS12 compiler, dtrace doesn't like the .o files (bug 6693876) # Problem with SS12 compiler, dtrace doesn't like the .o files (bug 6693876)
ifeq ($(COMPILER_REV),5.9) ifeq ($(COMPILER_REV_NUMERIC),509)
# Not clear this workaround could be skipped in some cases. # Not clear this workaround could be skipped in some cases.
OPT_CFLAGS/vmGCOperations.o = $(OPT_CFLAGS/SLOWER) -g OPT_CFLAGS/vmGCOperations.o = $(OPT_CFLAGS/SLOWER) -g
OPT_CFLAGS/java.o = $(OPT_CFLAGS/SLOWER) -g OPT_CFLAGS/java.o = $(OPT_CFLAGS/SLOWER) -g
...@@ -49,9 +49,9 @@ ifeq ($(COMPILER_REV),5.9) ...@@ -49,9 +49,9 @@ ifeq ($(COMPILER_REV),5.9)
endif endif
# Workaround SS11 bug 6345274 (all platforms) (Fixed in SS11 patch and SS12) # Workaround SS11 bug 6345274 (all platforms) (Fixed in SS11 patch and SS12)
ifeq ($(COMPILER_REV),5.8) ifeq ($(COMPILER_REV_NUMERIC),508)
OPT_CFLAGS/ciTypeFlow.o = $(OPT_CFLAGS/O2) OPT_CFLAGS/ciTypeFlow.o = $(OPT_CFLAGS/O2)
endif # COMPILER_REV == 5.8 endif # COMPILER_REV_NUMERIC == 508
endif # Platform_compiler == sparcWorks endif # Platform_compiler == sparcWorks
......
...@@ -26,7 +26,7 @@ Obj_Files += solaris_sparc.o ...@@ -26,7 +26,7 @@ Obj_Files += solaris_sparc.o
ASFLAGS += $(AS_ARCHFLAG) ASFLAGS += $(AS_ARCHFLAG)
ifeq ("${Platform_compiler}", "sparcWorks") ifeq ("${Platform_compiler}", "sparcWorks")
ifeq ($(shell expr $(COMPILER_REV) \< 5.5), 1) ifeq ($(shell expr $(COMPILER_REV_NUMARIC) \< 505), 1)
# For 5.2 ad_sparc file is compiled with -O2 %%%% remove when adlc is fixed # For 5.2 ad_sparc file is compiled with -O2 %%%% remove when adlc is fixed
OPT_CFLAGS/ad_sparc.o = $(OPT_CFLAGS/SLOWER) OPT_CFLAGS/ad_sparc.o = $(OPT_CFLAGS/SLOWER)
OPT_CFLAGS/dfa_sparc.o = $(OPT_CFLAGS/SLOWER) OPT_CFLAGS/dfa_sparc.o = $(OPT_CFLAGS/SLOWER)
......
...@@ -41,9 +41,9 @@ REORDER_FLAG = -xF ...@@ -41,9 +41,9 @@ REORDER_FLAG = -xF
# Get the last thing on the line that looks like x.x+ (x is a digit). # Get the last thing on the line that looks like x.x+ (x is a digit).
COMPILER_REV := \ COMPILER_REV := \
$(shell $(CPP) -V 2>&1 | sed -e 's/^.*\([1-9]\.[0-9][0-9]*\).*/\1/') $(shell $(CPP) -V 2>&1 | sed -n 's/^.*[ ,\t]C++[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/p')
C_COMPILER_REV := \ C_COMPILER_REV := \
$(shell $(CC) -V 2>&1 | grep -i "cc:" | sed -e 's/^.*\([1-9]\.[0-9][0-9]*\).*/\1/') $(shell $(CC) -V 2>&1 | sed -n 's/^.*[ ,\t]C[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/p')
# Pick which compiler is validated # Pick which compiler is validated
ifeq ($(JDK_MINOR_VERSION),6) ifeq ($(JDK_MINOR_VERSION),6)
...@@ -60,17 +60,19 @@ endif ...@@ -60,17 +60,19 @@ endif
ENFORCE_COMPILER_REV${ENFORCE_COMPILER_REV} := ${VALIDATED_COMPILER_REV} ENFORCE_COMPILER_REV${ENFORCE_COMPILER_REV} := ${VALIDATED_COMPILER_REV}
ifneq (${COMPILER_REV},${ENFORCE_COMPILER_REV}) ifneq (${COMPILER_REV},${ENFORCE_COMPILER_REV})
dummy_target_to_enforce_compiler_rev:=\ dummy_target_to_enforce_compiler_rev:=\
$(info WARNING: You are using CC version ${COMPILER_REV} \ $(shell echo >&2 WARNING: You are using CC version ${COMPILER_REV} \
and should be using version ${ENFORCE_COMPILER_REV}) and should be using version ${ENFORCE_COMPILER_REV}. Set ENFORCE_COMPILER_REV=${COMPILER_REV} to avoid this warning.)
endif endif
ENFORCE_C_COMPILER_REV${ENFORCE_C_COMPILER_REV} := ${VALIDATED_C_COMPILER_REV} ENFORCE_C_COMPILER_REV${ENFORCE_C_COMPILER_REV} := ${VALIDATED_C_COMPILER_REV}
ifneq (${C_COMPILER_REV},${ENFORCE_C_COMPILER_REV}) ifneq (${C_COMPILER_REV},${ENFORCE_C_COMPILER_REV})
dummy_target_to_enforce_c_compiler_rev:=\ dummy_target_to_enforce_c_compiler_rev:=\
$(info WARNING: You are using cc version ${C_COMPILER_REV} \ $(shell echo >&2 WARNING: You are using cc version ${C_COMPILER_REV} \
and should be using version ${ENFORCE_C_COMPILER_REV}) and should be using version ${ENFORCE_C_COMPILER_REV}. Set ENFORCE_C_COMPILER_REV=${C_COMPILER_REV} to avoid this warning.)
endif endif
COMPILER_REV_NUMERIC := $(shell echo $(COMPILER_REV) | awk -F. '{ print $$1 * 100 + $$2 }')
# Fail the build if __fabsf is used. __fabsf exists only in Solaris 8 2/04 # Fail the build if __fabsf is used. __fabsf exists only in Solaris 8 2/04
# and newer; objects with a dependency on this symbol will not run on older # and newer; objects with a dependency on this symbol will not run on older
# Solaris 8. # Solaris 8.
...@@ -120,7 +122,7 @@ ARCHFLAG_OLD/amd64 = -xarch=amd64 ...@@ -120,7 +122,7 @@ ARCHFLAG_OLD/amd64 = -xarch=amd64
ARCHFLAG_NEW/amd64 = -m64 ARCHFLAG_NEW/amd64 = -m64
# Select the ARCHFLAGs and other SS12 (5.9) options # Select the ARCHFLAGs and other SS12 (5.9) options
ifeq ($(shell expr $(COMPILER_REV) \>= 5.9), 1) ifeq ($(shell expr $(COMPILER_REV_NUMERIC) \>= 509), 1)
ARCHFLAG/sparc = $(ARCHFLAG_NEW/sparc) ARCHFLAG/sparc = $(ARCHFLAG_NEW/sparc)
ARCHFLAG/sparcv9 = $(ARCHFLAG_NEW/sparcv9) ARCHFLAG/sparcv9 = $(ARCHFLAG_NEW/sparcv9)
ARCHFLAG/i486 = $(ARCHFLAG_NEW/i486) ARCHFLAG/i486 = $(ARCHFLAG_NEW/i486)
...@@ -150,7 +152,7 @@ OPT_CFLAGS/NOOPT=-xO1 ...@@ -150,7 +152,7 @@ OPT_CFLAGS/NOOPT=-xO1
# Begin current (>=5.6) Forte compiler options # # Begin current (>=5.6) Forte compiler options #
################################################# #################################################
ifeq ($(shell expr $(COMPILER_REV) \>= 5.6), 1) ifeq ($(shell expr $(COMPILER_REV_NUMERIC) \>= 506), 1)
ifeq ("${Platform_arch}", "sparc") ifeq ("${Platform_arch}", "sparc")
...@@ -167,7 +169,7 @@ endif ...@@ -167,7 +169,7 @@ endif
# Begin current (>=5.5) Forte compiler options # # Begin current (>=5.5) Forte compiler options #
################################################# #################################################
ifeq ($(shell expr $(COMPILER_REV) \>= 5.5), 1) ifeq ($(shell expr $(COMPILER_REV_NUMERIC) \>= 505), 1)
CFLAGS += $(ARCHFLAG) CFLAGS += $(ARCHFLAG)
AOUT_FLAGS += $(ARCHFLAG) AOUT_FLAGS += $(ARCHFLAG)
...@@ -255,7 +257,7 @@ LFLAGS += -library=%none ...@@ -255,7 +257,7 @@ LFLAGS += -library=%none
LFLAGS += -mt LFLAGS += -mt
endif # COMPILER_REV >= 5.5 endif # COMPILER_REV_NUMERIC >= 505
###################################### ######################################
# End 5.5 Forte compiler options # # End 5.5 Forte compiler options #
...@@ -265,7 +267,7 @@ endif # COMPILER_REV >= 5.5 ...@@ -265,7 +267,7 @@ endif # COMPILER_REV >= 5.5
# Begin 5.2 Forte compiler options # # Begin 5.2 Forte compiler options #
###################################### ######################################
ifeq ($(COMPILER_REV), 5.2) ifeq ($(COMPILER_REV_NUMERIC), 502)
CFLAGS += $(ARCHFLAG) CFLAGS += $(ARCHFLAG)
AOUT_FLAGS += $(ARCHFLAG) AOUT_FLAGS += $(ARCHFLAG)
...@@ -324,7 +326,7 @@ PICFLAG/BYFILE = $(PICFLAG/$@)$(PICFLAG/DEFAULT$(PICFLAG/$@)) ...@@ -324,7 +326,7 @@ PICFLAG/BYFILE = $(PICFLAG/$@)$(PICFLAG/DEFAULT$(PICFLAG/$@))
LFLAGS += -library=Crun LFLAGS += -library=Crun
LIBS += -library=Crun -lCrun LIBS += -library=Crun -lCrun
endif # COMPILER_REV == 5.2 endif # COMPILER_REV_NUMERIC == 502
################################## ##################################
# End 5.2 Forte compiler options # # End 5.2 Forte compiler options #
...@@ -333,7 +335,7 @@ endif # COMPILER_REV == 5.2 ...@@ -333,7 +335,7 @@ endif # COMPILER_REV == 5.2
################################## ##################################
# Begin old 5.1 compiler options # # Begin old 5.1 compiler options #
################################## ##################################
ifeq ($(COMPILER_REV), 5.1) ifeq ($(COMPILER_REV_NUMERIC), 501)
_JUNK_ := $(shell echo >&2 \ _JUNK_ := $(shell echo >&2 \
"*** ERROR: sparkWorks.make incomplete for 5.1 compiler") "*** ERROR: sparkWorks.make incomplete for 5.1 compiler")
...@@ -347,7 +349,7 @@ endif ...@@ -347,7 +349,7 @@ endif
# Begin old 5.0 compiler options # # Begin old 5.0 compiler options #
################################## ##################################
ifeq (${COMPILER_REV}, 5.0) ifeq (${COMPILER_REV_NUMERIC}, 500)
# Had to hoist this higher apparently because of other changes. Must # Had to hoist this higher apparently because of other changes. Must
# come before -xarch specification. # come before -xarch specification.
...@@ -379,7 +381,7 @@ endif # sparc ...@@ -379,7 +381,7 @@ endif # sparc
ifeq ("${Platform_arch_model}", "x86_32") ifeq ("${Platform_arch_model}", "x86_32")
OPT_CFLAGS=-xtarget=pentium $(EXTRA_OPT_CFLAGS) OPT_CFLAGS=-xtarget=pentium $(EXTRA_OPT_CFLAGS)
ifeq ("${COMPILER_REV}", "5.0") ifeq ("${COMPILER_REV_NUMERIC}", "500")
# SC5.0 tools on x86 are flakey at -xO4 # SC5.0 tools on x86 are flakey at -xO4
OPT_CFLAGS+=-xO3 OPT_CFLAGS+=-xO3
else else
...@@ -405,13 +407,13 @@ PICFLAG/DEFAULT = $(PICFLAG) ...@@ -405,13 +407,13 @@ PICFLAG/DEFAULT = $(PICFLAG)
PICFLAG/BETTER = $(PICFLAG/DEFAULT) PICFLAG/BETTER = $(PICFLAG/DEFAULT)
PICFLAG/BYFILE = $(PICFLAG/$@)$(PICFLAG/DEFAULT$(PICFLAG/$@)) PICFLAG/BYFILE = $(PICFLAG/$@)$(PICFLAG/DEFAULT$(PICFLAG/$@))
endif # COMPILER_REV = 5.0 endif # COMPILER_REV_NUMERIC = 500
################################ ################################
# End old 5.0 compiler options # # End old 5.0 compiler options #
################################ ################################
ifeq ("${COMPILER_REV}", "4.2") ifeq ("${COMPILER_REV_NUMERIC}", "402")
# 4.2 COMPILERS SHOULD NO LONGER BE USED # 4.2 COMPILERS SHOULD NO LONGER BE USED
_JUNK_ := $(shell echo >&2 \ _JUNK_ := $(shell echo >&2 \
"*** ERROR: SC4.2 compilers are not supported by this code base!") "*** ERROR: SC4.2 compilers are not supported by this code base!")
...@@ -443,7 +445,7 @@ LINK_MODE/debug = ...@@ -443,7 +445,7 @@ LINK_MODE/debug =
LINK_MODE/optimized = -Bsymbolic -znodefs LINK_MODE/optimized = -Bsymbolic -znodefs
# Have thread local errnos # Have thread local errnos
ifeq ($(shell expr $(COMPILER_REV) \>= 5.5), 1) ifeq ($(shell expr $(COMPILER_REV_NUMERIC) \>= 505), 1)
CFLAGS += -mt CFLAGS += -mt
else else
CFLAGS += -D_REENTRANT CFLAGS += -D_REENTRANT
...@@ -460,7 +462,7 @@ FASTDEBUG_CFLAGS = -g0 ...@@ -460,7 +462,7 @@ FASTDEBUG_CFLAGS = -g0
# The -g0 setting allows the C++ frontend to inline, which is a big win. # The -g0 setting allows the C++ frontend to inline, which is a big win.
# Special global options for SS12 # Special global options for SS12
ifeq ($(COMPILER_REV),5.9) ifeq ($(COMPILER_REV_NUMERIC),509)
# There appears to be multiple issues with the new Dwarf2 debug format, so # There appears to be multiple issues with the new Dwarf2 debug format, so
# we tell the compiler to use the older 'stabs' debug format all the time. # we tell the compiler to use the older 'stabs' debug format all the time.
# Note that this needs to be used in optimized compiles too to be 100%. # Note that this needs to be used in optimized compiles too to be 100%.
...@@ -479,8 +481,8 @@ endif ...@@ -479,8 +481,8 @@ endif
#DEBUG_CFLAGS += -Qoption ccfe -xglobalstatic #DEBUG_CFLAGS += -Qoption ccfe -xglobalstatic
#FASTDEBUG_CFLAGS += -Qoption ccfe -xglobalstatic #FASTDEBUG_CFLAGS += -Qoption ccfe -xglobalstatic
ifeq (${COMPILER_REV}, 5.2) ifeq (${COMPILER_REV_NUMERIC}, 502)
COMPILER_DATE := $(shell $(CPP) -V 2>&1 | awk '{ print $$NF; }') COMPILER_DATE := $(shell $(CPP) -V 2>&1 | sed -n '/^.*[ ]C++[ ]\([1-9]\.[0-9][0-9]*\)/p' | awk '{ print $$NF; }')
ifeq (${COMPILER_DATE}, 2001/01/31) ifeq (${COMPILER_DATE}, 2001/01/31)
# disable -g0 in fastdebug since SC6.1 dated 2001/01/31 seems to be buggy # disable -g0 in fastdebug since SC6.1 dated 2001/01/31 seems to be buggy
# use an innocuous value because it will get -g if it's empty # use an innocuous value because it will get -g if it's empty
...@@ -493,7 +495,7 @@ endif ...@@ -493,7 +495,7 @@ endif
CFLAGS += $(CFLAGS_BROWSE) CFLAGS += $(CFLAGS_BROWSE)
# ILD is gone as of SS11 (5.8), not supportted in SS10 (5.7) # ILD is gone as of SS11 (5.8), not supportted in SS10 (5.7)
ifeq ($(shell expr $(COMPILER_REV) \< 5.7), 1) ifeq ($(shell expr $(COMPILER_REV_NUMERIC) \< 507), 1)
# use ild when debugging (but when optimizing we want reproducible results) # use ild when debugging (but when optimizing we want reproducible results)
ILDFLAG = $(ILDFLAG/$(VERSION)) ILDFLAG = $(ILDFLAG/$(VERSION))
ILDFLAG/debug = -xildon ILDFLAG/debug = -xildon
......
...@@ -26,7 +26,7 @@ Obj_Files += solaris_sparc.o ...@@ -26,7 +26,7 @@ Obj_Files += solaris_sparc.o
ASFLAGS += $(AS_ARCHFLAG) ASFLAGS += $(AS_ARCHFLAG)
ifeq ("${Platform_compiler}", "sparcWorks") ifeq ("${Platform_compiler}", "sparcWorks")
ifeq ($(shell expr $(COMPILER_REV) \< 5.5), 1) ifeq ($(shell expr $(COMPILER_REV_NUMERIC) \< 505), 1)
# When optimized fully, stubGenerator_sparc.cpp # When optimized fully, stubGenerator_sparc.cpp
# has bogus code for the routine # has bogus code for the routine
# StubGenerator::generate_flush_callers_register_windows() # StubGenerator::generate_flush_callers_register_windows()
......
...@@ -101,7 +101,7 @@ LIBM=/usr/lib$(ISA_DIR)/libm.so.1 ...@@ -101,7 +101,7 @@ LIBM=/usr/lib$(ISA_DIR)/libm.so.1
ifeq ("${Platform_compiler}", "sparcWorks") ifeq ("${Platform_compiler}", "sparcWorks")
# The whole megilla: # The whole megilla:
ifeq ($(shell expr $(COMPILER_REV) \>= 5.5), 1) ifeq ($(shell expr $(COMPILER_REV_NUMERIC) \>= 505), 1)
# Old Comment: List the libraries in the order the compiler was designed for # Old Comment: List the libraries in the order the compiler was designed for
# Not sure what the 'designed for' comment is referring too above. # Not sure what the 'designed for' comment is referring too above.
# The order may not be too significant anymore, but I have placed this # The order may not be too significant anymore, but I have placed this
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册