--- a/nashorn/make/BuildNashorn.gmk Wed Jul 05 20:45:01 2017 +0200
+++ b/nashorn/make/BuildNashorn.gmk Thu Aug 13 19:07:27 2015 +0530
@@ -53,7 +53,10 @@
SERVER_JVM := $(SJAVAC_SERVER_JAVA)))
# Build nashorn into intermediate directory
-$(eval $(call SetupJavaCompilation,BUILD_NASHORN, \
+# Name the compilation setup the same as the module, as is done in the global
+# CompileJavaModules.gmk, to make dependency checking with other modules work
+# seamlessly.
+$(eval $(call SetupJavaCompilation,jdk.scripting.nashorn, \
SETUP := GENERATE_NEWBYTECODE_DEBUG, \
SRC := $(NASHORN_TOPDIR)/src/jdk.scripting.nashorn/share/classes, \
EXCLUDE_FILES := META-INF/MANIFEST.MF, \
@@ -71,7 +74,7 @@
ADD_JAVAC_FLAGS := -Xbootclasspath/p:"$(SUPPORT_OUTPUTDIR)/special_classes/jdk.scripting.nashorn/classes"))
# Nasgen needs nashorn classes
-$(BUILD_NASGEN): $(BUILD_NASHORN)
+$(BUILD_NASGEN): $(jdk.scripting.nashorn)
NASHORN_CLASSES_DIR := $(JDK_OUTPUTDIR)/modules/jdk.scripting.nashorn
NASGEN_RUN_FILE := $(NASHORN_CLASSES_DIR)/_the.nasgen.run