# HG changeset patch # User mikael # Date 1360874167 28800 # Node ID e7e9e08147fc9ac7fa1fa837086a83220e4dc5f9 # Parent 3a531d40ad93067d35a0499c822cd4d65192b508 8007639: Workaround for ccache in vm.make is incorrect Summary: Fixed makefile logic to correctly special case JRE_RELEASE_VERSION and vm_version.o Reviewed-by: dholmes, erikj diff -r 3a531d40ad93 -r e7e9e08147fc make/bsd/makefiles/vm.make --- a/make/bsd/makefiles/vm.make Thu Feb 14 14:33:35 2013 -0500 +++ b/make/bsd/makefiles/vm.make Thu Feb 14 12:36:07 2013 -0800 @@ -94,7 +94,12 @@ # This is VERY important! The version define must only be supplied to vm_version.o # If not, ccache will not re-use the cache at all, since the version string might contain # a time and date. -vm_version.o: CXXFLAGS += ${JRE_VERSION} +CXXFLAGS/vm_version.o += ${JRE_VERSION} + +CXXFLAGS/BYFILE = $(CXXFLAGS/$@) + +# File specific flags +CXXFLAGS += $(CXXFLAGS/BYFILE) ifdef DEFAULT_LIBPATH CXXFLAGS += -DDEFAULT_LIBPATH="\"$(DEFAULT_LIBPATH)\"" diff -r 3a531d40ad93 -r e7e9e08147fc make/linux/makefiles/vm.make --- a/make/linux/makefiles/vm.make Thu Feb 14 14:33:35 2013 -0500 +++ b/make/linux/makefiles/vm.make Thu Feb 14 12:36:07 2013 -0800 @@ -100,7 +100,13 @@ # This is VERY important! The version define must only be supplied to vm_version.o # If not, ccache will not re-use the cache at all, since the version string might contain # a time and date. -vm_version.o: CXXFLAGS += ${JRE_VERSION} +CXXFLAGS/vm_version.o += ${JRE_VERSION} + +CXXFLAGS/BYFILE = $(CXXFLAGS/$@) + +# File specific flags +CXXFLAGS += $(CXXFLAGS/BYFILE) + ifndef JAVASE_EMBEDDED ifneq (${ARCH},arm) diff -r 3a531d40ad93 -r e7e9e08147fc make/solaris/makefiles/vm.make --- a/make/solaris/makefiles/vm.make Thu Feb 14 14:33:35 2013 -0500 +++ b/make/solaris/makefiles/vm.make Thu Feb 14 12:36:07 2013 -0800 @@ -88,7 +88,13 @@ # This is VERY important! The version define must only be supplied to vm_version.o # If not, ccache will not re-use the cache at all, since the version string might contain # a time and date. -vm_version.o: CXXFLAGS += ${JRE_VERSION} +CXXFLAGS/vm_version.o += ${JRE_VERSION} + +CXXFLAGS/BYFILE = $(CXXFLAGS/$@) + +# File specific flags +CXXFLAGS += $(CXXFLAGS/BYFILE) + # CFLAGS_WARN holds compiler options to suppress/enable warnings. CFLAGS += $(CFLAGS_WARN)