hotspot/make/linux/makefiles/rules.make
changeset 29463 4b16497408b9
parent 26691 40ea2c41f53b
child 31620 53be635ad49c
--- a/hotspot/make/linux/makefiles/rules.make	Tue Mar 10 04:53:58 2015 -0700
+++ b/hotspot/make/linux/makefiles/rules.make	Tue Mar 10 09:42:23 2015 -0700
@@ -126,10 +126,17 @@
 RUN.JAR$(MAKE_VERBOSE) += >/dev/null
 
 # Settings for javac
-BOOT_SOURCE_LANGUAGE_VERSION = 6
-BOOT_TARGET_CLASS_VERSION = 6
 JAVAC_FLAGS = -g -encoding ascii
-BOOTSTRAP_JAVAC_FLAGS = $(JAVAC_FLAGS) -source $(BOOT_SOURCE_LANGUAGE_VERSION) -target $(BOOT_TARGET_CLASS_VERSION)
+
+# Prefer BOOT_JDK_SOURCETARGET if it's set (typically by the top build system)
+# Fall back to the values here if it's not set (hotspot only builds)
+ifeq ($(BOOT_JDK_SOURCETARGET),)
+BOOTSTRAP_SOURCETARGET := -source 8 -target 8
+else
+BOOTSTRAP_SOURCETARGET := $(BOOT_JDK_SOURCETARGET)
+endif
+
+BOOTSTRAP_JAVAC_FLAGS = $(JAVAC_FLAGS) $(BOOTSTRAP_SOURCETARGET)
 
 # With parallel makes, print a message at the end of compilation.
 ifeq    ($(findstring j,$(MFLAGS)),j)