--- old/make/CompileJavaModules.gmk 2016-10-26 17:37:42.871450481 +0200 +++ new/make/CompileJavaModules.gmk 2016-10-26 17:37:42.783446814 +0200 @@ -461,6 +461,13 @@ jdk.localedata_EXCLUDE_FILES += sun/text/resources/ext/BreakIteratorRules_th.java ################################################################################ +# If this is an imported module that has prebuilt classes, only compile +# module-info.java. +ifneq ($(wildcard $(IMPORT_MODULES_CLASSES)/$(MODULE)), ) + $(MODULE)_INCLUDE_FILES := module-info.java +endif + +################################################################################ # Setup the compilation for the module # MODULE_SRC_DIRS := $(call FindModuleSrcDirs, $(MODULE))