# HG changeset patch # User lana # Date 1494526222 0 # Node ID 852e7f779f91a054c1f1dedc4aeb3467eebdc34e # Parent 9b46143dfff4fc15243f46aec4d63d0d523825f7# Parent cba0b620fd93a2dba2dc6fd1bff5a567202fff03 Merge diff -r 9b46143dfff4 -r 852e7f779f91 common/conf/jib-profiles.js --- a/common/conf/jib-profiles.js Thu May 11 16:26:48 2017 +0000 +++ b/common/conf/jib-profiles.js Thu May 11 18:10:22 2017 +0000 @@ -239,11 +239,8 @@ common.main_profile_base = { dependencies: ["boot_jdk", "gnumake", "jtreg"], default_make_targets: ["product-bundles", "test-bundles"], - configure_args: [ - "--with-version-opt=" + common.build_id, - "--enable-jtreg-failure-handler", - "--with-version-build=" + common.build_number - ] + configure_args: concat(["--enable-jtreg-failure-handler"], + versionArgs(input, common)) }; // Extra settings for debug profiles common.debug_suffix = "-debug"; @@ -269,10 +266,12 @@ /** * Define common artifacts template for all main profiles - * @param pf - Name of platform in bundle names - * @param demo_ext - Type of extension for demo bundle + * @param o - Object containing data for artifacts */ - common.main_profile_artifacts = function (pf, demo_ext) { + common.main_profile_artifacts = function (o) { + var jdk_subdir = (o.jdk_subdir != null ? o.jdk_subdir : "jdk-" + data.version); + var jre_subdir = (o.jre_subdir != null ? o.jre_subdir : "jre-" + data.version); + var pf = o.platform return { artifacts: { jdk: { @@ -281,7 +280,7 @@ "bundles/" + pf + "/jdk-" + data.version + "_" + pf + "_bin.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jdk-" + data.version, + subdir: jdk_subdir, exploded: "images/jdk" }, jre: { @@ -290,7 +289,7 @@ "bundles/" + pf + "/jre-" + data.version + "_" + pf + "_bin.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jre-" + data.version, + subdir: jre_subdir, exploded: "images/jre" }, test: { @@ -307,7 +306,7 @@ "bundles/" + pf + "/jdk-" + data.version + "_" + pf + "_bin-symbols.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jdk-" + data.version, + subdir: jdk_subdir, exploded: "images/jdk" }, jre_symbols: { @@ -316,15 +315,8 @@ "bundles/" + pf + "/jre-" + data.version + "_" + pf + "_bin-symbols.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jre-" + data.version, + subdir: jre_subdir, exploded: "images/jre" - }, - demo: { - local: "bundles/\\(jdk.*demo." + demo_ext + "\\)", - remote: [ - "bundles/" + pf + "/jdk-" + data.version + "_" + pf + "_demo." + demo_ext, - "bundles/" + pf + "/\\1" - ], } } }; @@ -333,9 +325,12 @@ /** * Define common artifacts template for all debug profiles - * @param pf - Name of platform in bundle names + * @param o - Object containing data for artifacts */ - common.debug_profile_artifacts = function (pf) { + common.debug_profile_artifacts = function (o) { + var jdk_subdir = "jdk-" + data.version + "/fastdebug"; + var jre_subdir = "jre-" + data.version + "/fastdebug"; + var pf = o.platform return { artifacts: { jdk: { @@ -344,7 +339,7 @@ "bundles/" + pf + "/jdk-" + data.version + "_" + pf + "_bin-debug.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jdk-" + data.version, + subdir: jdk_subdir, exploded: "images/jdk" }, jre: { @@ -353,7 +348,7 @@ "bundles/" + pf + "/jre-" + data.version + "_" + pf + "_bin-debug.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jre-" + data.version, + subdir: jre_subdir, exploded: "images/jre" }, test: { @@ -370,7 +365,7 @@ "bundles/" + pf + "/jdk-" + data.version + "_" + pf + "_bin-debug-symbols.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jdk-" + data.version, + subdir: jdk_subdir, exploded: "images/jdk" }, jre_symbols: { @@ -379,7 +374,7 @@ "bundles/" + pf + "/jre-" + data.version + "_" + pf + "_bin-debug-symbols.tar.gz", "bundles/" + pf + "/\\1" ], - subdir: "jre-" + data.version, + subdir: jre_subdir, exploded: "images/jre" } } @@ -621,7 +616,7 @@ var testOnlyProfilesPrebuilt = { "run-test-prebuilt": { src: "src.conf", - dependencies: [ "jtreg", "gnumake", testedProfile + ".jdk", + dependencies: [ "jtreg", "gnumake", "boot_jdk", testedProfile + ".jdk", testedProfile + ".test", "src.full" ], work_dir: input.get("src.full", "install_path") + "/test", @@ -665,61 +660,53 @@ // // Define artifacts for profiles // - // Macosx bundles are named osx and Windows demo bundles use zip instead of + // Macosx bundles are named osx // tar.gz. var artifactData = { "linux-x64": { platform: "linux-x64", - demo_ext: "tar.gz" }, "linux-x86": { platform: "linux-x86", - demo_ext: "tar.gz" }, "macosx-x64": { platform: "osx-x64", - demo_ext: "tar.gz" + jdk_subdir: "jdk-" + data.version + ".jdk/Contents/Home", + jre_subdir: "jre-" + data.version + ".jre/Contents/Home" }, "solaris-x64": { platform: "solaris-x64", - demo_ext: "tar.gz" }, "solaris-sparcv9": { platform: "solaris-sparcv9", - demo_ext: "tar.gz" }, "windows-x64": { platform: "windows-x64", - demo_ext: "zip" }, "windows-x86": { platform: "windows-x86", - demo_ext: "zip" }, "linux-arm64": { platform: "linux-arm64-vfp-hflt", - demo_ext: "tar.gz" }, "linux-arm-vfp-hflt": { platform: "linux-arm32-vfp-hflt", - demo_ext: "tar.gz" }, "linux-arm-vfp-hflt-dyn": { platform: "linux-arm32-vfp-hflt-dyn", - demo_ext: "tar.gz" } } // Generate common artifacts for all main profiles Object.keys(artifactData).forEach(function (name) { profiles[name] = concatObjects(profiles[name], - common.main_profile_artifacts(artifactData[name].platform, artifactData[name].demo_ext)); + common.main_profile_artifacts(artifactData[name])); }); // Generate common artifacts for all debug profiles Object.keys(artifactData).forEach(function (name) { var debugName = name + common.debug_suffix; profiles[debugName] = concatObjects(profiles[debugName], - common.debug_profile_artifacts(artifactData[name].platform)); + common.debug_profile_artifacts(artifactData[name])); }); // Extra profile specific artifacts @@ -740,7 +727,12 @@ artifacts: { jdk: { local: "bundles/\\(jdk.*bin.tar.gz\\)", - remote: "bundles/openjdk/GPL/linux-x64/\\1", + remote: [ + "bundles/openjdk/GPL/linux-x64/jdk-" + data.version + + "_linux-x64_bin.tar.gz", + "bundles/openjdk/GPL/linux-x64/\\1" + ], + subdir: "jdk-" + data.version }, jre: { local: "bundles/\\(jre.*bin.tar.gz\\)", @@ -748,20 +740,25 @@ }, test: { local: "bundles/\\(jdk.*bin-tests.tar.gz\\)", - remote: "bundles/openjdk/GPL/linux-x64/\\1", + remote: [ + "bundles/openjdk/GPL/linux-x64/jdk-" + data.version + + "_linux-x64_bin-tests.tar.gz", + "bundles/openjdk/GPL/linux-x64/\\1" + ] }, jdk_symbols: { local: "bundles/\\(jdk.*bin-symbols.tar.gz\\)", - remote: "bundles/openjdk/GPL/linux-x64/\\1", + remote: [ + "bundles/openjdk/GPL/linux-x64/jdk-" + data.version + + "_linux-x64_bin-symbols.tar.gz", + "bundles/openjdk/GPL/linux-x64/\\1" + ], + subdir: "jdk-" + data.version }, jre_symbols: { local: "bundles/\\(jre.*bin-symbols.tar.gz\\)", remote: "bundles/openjdk/GPL/linux-x64/\\1", }, - demo: { - local: "bundles/\\(jdk.*demo.tar.gz\\)", - remote: "bundles/openjdk/GPL/linux-x64/\\1", - }, doc_api_spec: { local: "bundles/\\(jdk.*doc-api-spec.tar.gz\\)", remote: "bundles/openjdk/GPL/linux-x64/\\1", @@ -773,11 +770,29 @@ artifacts: { jdk: { local: "bundles/\\(jdk.*bin.tar.gz\\)", - remote: "bundles/openjdk/GPL/profile/linux-x86/\\1", + remote: [ + "bundles/openjdk/GPL/linux-x86/jdk-" + data.version + + "_linux-x86_bin.tar.gz", + "bundles/openjdk/GPL/linux-x86/\\1" + ], + subdir: "jdk-" + data.version }, jdk_symbols: { local: "bundles/\\(jdk.*bin-symbols.tar.gz\\)", - remote: "bundles/openjdk/GPL/profile/linux-x86/\\1", + remote: [ + "bundles/openjdk/GPL/linux-x86/jdk-" + data.version + + "_linux-x86_bin-symbols.tar.gz", + "bundles/openjdk/GPL/linux-x86/\\1" + ], + subdir: "jdk-" + data.version + }, + test: { + local: "bundles/\\(jdk.*bin-tests.tar.gz\\)", + remote: [ + "bundles/openjdk/GPL/linux-x86/jdk-" + data.version + + "_linux-x86_bin-tests.tar.gz", + "bundles/openjdk/GPL/linux-x86/\\1" + ] }, jre: { // This regexp needs to not match the compact* files below @@ -803,7 +818,12 @@ artifacts: { jdk: { local: "bundles/\\(jdk.*bin.tar.gz\\)", - remote: "bundles/openjdk/GPL/windows-x86/\\1", + remote: [ + "bundles/openjdk/GPL/windows-x86/jdk-" + data.version + + "_windows-x86_bin.tar.gz", + "bundles/openjdk/GPL/windows-x86/\\1" + ], + subdir: "jdk-" + data.version }, jre: { local: "bundles/\\(jre.*bin.tar.gz\\)", @@ -811,19 +831,24 @@ }, test: { local: "bundles/\\(jdk.*bin-tests.tar.gz\\)", - remote: "bundles/openjdk/GPL/windows-x86/\\1", + remote: [ + "bundles/openjdk/GPL/windows-x86/jdk-" + data.version + + "_windows-x86_bin-tests.tar.gz", + "bundles/openjdk/GPL/windows-x86/\\1" + ] }, jdk_symbols: { local: "bundles/\\(jdk.*bin-symbols.tar.gz\\)", - remote: "bundles/openjdk/GPL/windows-x86/\\1" + remote: [ + "bundles/openjdk/GPL/windows-x86/jdk-" + data.version + + "_windows-x86_bin-symbols.tar.gz", + "bundles/openjdk/GPL/windows-x86/\\1" + ], + subdir: "jdk-" + data.version }, jre_symbols: { local: "bundles/\\(jre.*bin-symbols.tar.gz\\)", remote: "bundles/openjdk/GPL/windows-x86/\\1", - }, - demo: { - local: "bundles/\\(jdk.*demo.zip\\)", - remote: "bundles/openjdk/GPL/windows-x86/\\1", } } }, @@ -1148,12 +1173,29 @@ + "." + (minor != null ? minor : version_numbers.get("DEFAULT_VERSION_MINOR")) + "." + (security != null ? security : version_numbers.get("DEFAULT_VERSION_SECURITY")) + "." + (patch != null ? patch : version_numbers.get("DEFAULT_VERSION_PATCH")); - while (version.match(".*\.0$")) { + while (version.match(".*\\.0$")) { version = version.substring(0, version.length - 2); } return version; }; +/** + * Constructs the common version configure args based on build type and + * other version inputs + */ +var versionArgs = function(input, common) { + var args = ["--with-version-build=" + common.build_number]; + if (input.build_type == "promoted") { + args = concat(args, + // This needs to be changed when we start building release candidates + "--with-version-pre=ea", + "--without-version-opt"); + } else { + args = concat(args, "--with-version-opt=" + common.build_id); + } + return args; +} + // Properties representation of the common/autoconf/version-numbers file. Lazily // initiated by the function below. var version_numbers; diff -r 9b46143dfff4 -r 852e7f779f91 make/Bundles.gmk --- a/make/Bundles.gmk Thu May 11 16:26:48 2017 +0000 +++ b/make/Bundles.gmk Thu May 11 18:10:22 2017 +0000 @@ -183,6 +183,7 @@ $(JDK_SYMBOLS_EXCLUDE_PATTERN) \ $(JDK_EXTRA_EXCLUDES) \ $(SYMBOLS_EXCLUDE_PATTERN) \ + $(JDK_IMAGE_HOMEDIR)/demo/% \ , \ $(ALL_JDK_FILES) \ ) diff -r 9b46143dfff4 -r 852e7f779f91 make/Javadoc.gmk --- a/make/Javadoc.gmk Thu May 11 16:26:48 2017 +0000 +++ b/make/Javadoc.gmk Thu May 11 18:10:22 2017 +0000 @@ -367,13 +367,15 @@ $(foreach m, $(ALL_MODULES), \ $(eval SPECS_$m := $(call FindModuleSpecsDirs, $m)) \ - $(if $(SPECS_$m), \ - $(eval $(call SetupCopyFiles, COPY_$m, \ - SRC := $(SPECS_$m), \ - FILES := $(filter $(COPY_SPEC_FILTER), $(call CacheFind, $(SPECS_$m))), \ - DEST := $(JAVADOC_OUTPUTDIR)/specs/, \ - )) \ - $(eval JDK_SPECS_TARGETS += $(COPY_$m)) \ + $(foreach d, $(SPECS_$m), \ + $(if $(filter $(COPY_SPEC_FILTER), $(call CacheFind, $d)), \ + $(eval $(call SetupCopyFiles, COPY_$m, \ + SRC := $d, \ + FILES := $(filter $(COPY_SPEC_FILTER), $(call CacheFind, $d)), \ + DEST := $(JAVADOC_OUTPUTDIR)/specs/, \ + )) \ + $(eval JDK_SPECS_TARGETS += $(COPY_$m)) \ + ) \ ) \ ) diff -r 9b46143dfff4 -r 852e7f779f91 make/Main.gmk --- a/make/Main.gmk Thu May 11 16:26:48 2017 +0000 +++ b/make/Main.gmk Thu May 11 18:10:22 2017 +0000 @@ -277,7 +277,10 @@ demos-jdk: +($(CD) $(JDK_TOPDIR)/make && $(MAKE) $(MAKE_ARGS) -f CompileDemos.gmk) -ALL_TARGETS += demos-jdk +test-image-demos-jdk: + +($(CD) $(JDK_TOPDIR)/make && $(MAKE) $(MAKE_ARGS) -f CompileDemos.gmk images) + +ALL_TARGETS += demos-jdk test-image-demos-jdk ################################################################################ # Jigsaw specific data and analysis targets. @@ -631,6 +634,7 @@ # jdk libs, even though they don't need to. To avoid warnings, make sure they # aren't built until after libjava and libjvm are available to link to. demos-jdk: java.base-libs exploded-image-optimize + test-image-demos-jdk: demos-jdk # Declare dependency from -java to -gensrc $(foreach m, $(GENSRC_MODULES), $(eval $m-java: $m-gensrc)) @@ -963,7 +967,8 @@ # This target builds the test image test-image: prepare-test-image test-image-hotspot-jtreg-native \ - test-image-jdk-jtreg-native test-image-failure-handler test-image-hotspot-gtest + test-image-jdk-jtreg-native test-image-failure-handler test-image-hotspot-gtest \ + test-image-demos-jdk # all-images builds all our deliverables as images. all-images: product-images test-image docs-image diff -r 9b46143dfff4 -r 852e7f779f91 make/common/Modules.gmk --- a/make/common/Modules.gmk Thu May 11 16:26:48 2017 +0000 +++ b/make/common/Modules.gmk Thu May 11 18:10:22 2017 +0000 @@ -391,7 +391,10 @@ else ifeq ($$(classloader), ext) PLATFORM_MODULES += $1 endif - DOCS_MODULES += $1 + ifneq ($$(include_in_docs), false) + # defaults to true if unspecified + DOCS_MODULES += $1 + endif else # Default to include in all JRE_MODULES += $1