< prev index next >

make/conf/jib-profiles.js

Print this page

        

@@ -1,7 +1,7 @@
 /*
- * Copyright (c) 2015, 2019, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
  * under the terms of the GNU General Public License version 2 only, as
  * published by the Free Software Foundation.  Oracle designates this

@@ -74,11 +74,10 @@
  *
  * Valid attributes are:
  * install_path
  * download_path
  * download_dir
- * home_path
  *
  *
  * The output data generated by this configuration file has the following
  * format:
  *

@@ -184,13 +183,11 @@
     var data = {};
 
     // Identifies the version of this format to the tool reading it.
     // 1.1 signifies that the publish, publish-src and get-src features are usable.
     // 1.2 signifies that artifact uploads should fail on missing artifacts by default.
-    // 1.3 input.get(<dep>, "home_path") automatically goes down into a single top
-    //     dir just like default configure_args and environment_path variables.
-    data.format_version = "1.3";
+    data.format_version = "1.2";
 
     // Organization, product and version are used when uploading/publishing build results
     data.organization = "";
     data.product = "jdk";
     data.version = getVersion();

@@ -239,21 +236,20 @@
 
     // List of the main profile names used for iteration
     common.main_profile_names = [
         "linux-x64", "linux-x86", "macosx-x64", "solaris-x64",
         "solaris-sparcv9", "windows-x64", "windows-x86",
-        "linux-aarch64", "linux-arm32", "linux-ppc64le", "linux-s390x"
+        "linux-aarch64", "linux-arm32"
     ];
 
     // These are the base setttings for all the main build profiles.
     common.main_profile_base = {
-        dependencies: ["boot_jdk", "gnumake", "jtreg", "jib", "autoconf", "jmh", "jcov"],
+        dependencies: ["boot_jdk", "gnumake", "jtreg", "jib", "autoconf", "jmh"],
         default_make_targets: ["product-bundles", "test-bundles"],
         configure_args: concat(["--enable-jtreg-failure-handler"],
             "--with-exclude-translations=de,es,fr,it,ko,pt_BR,sv,ca,tr,cs,sk,ja_JP_A,ja_JP_HA,ja_JP_HI,ja_JP_I,zh_TW,zh_HK",
             "--disable-manpages",
-            "--with-jvm-features=-shenandoahgc",
             versionArgs(input, common))
     };
     // Extra settings for debug profiles
     common.debug_suffix = "-debug";
     common.debug_profile_base = {

@@ -363,13 +359,12 @@
                 },
             }
         };
     };
 
-    common.boot_jdk_version = "12";
-    common.boot_jdk_build_number = "33";
-    common.boot_jdk_home = input.get("boot_jdk", "install_path") + "/jdk-"
+    common.boot_jdk_version = "11";
+    common.boot_jdk_home = input.get("boot_jdk", "home_path") + "/jdk-"
         + common.boot_jdk_version
         + (input.build_os == "macosx" ? ".jdk/Contents/Home" : "");
 
     return common;
 };

@@ -388,13 +383,11 @@
         "linux-x64": {
             target_os: "linux",
             target_cpu: "x64",
             dependencies: ["devkit", "graphviz", "pandoc", "graalunit_lib"],
             configure_args: concat(common.configure_args_64bit,
-                "--enable-full-docs", "--with-zlib=system",
-                (isWsl(input) ? [ "--host=x86_64-unknown-linux-gnu",
-                    "--build=x86_64-unknown-linux-gnu" ] : [])),
+                "--enable-full-docs", "--with-zlib=system"),
             default_make_targets: ["docs-bundles"],
         },
 
         "linux-x86": {
             target_os: "linux",

@@ -430,11 +423,11 @@
         },
 
         "windows-x64": {
             target_os: "windows",
             target_cpu: "x64",
-            dependencies: ["devkit", "pandoc", "graalunit_lib"],
+            dependencies: ["devkit", "graalunit_lib"],
             configure_args: concat(common.configure_args_64bit),
         },
 
         "windows-x86": {
             target_os: "windows",

@@ -463,32 +456,10 @@
             configure_args: [
                 "--openjdk-target=arm-linux-gnueabihf", "--with-freetype=bundled",
                 "--with-abi-profile=arm-vfp-hflt", "--disable-warnings-as-errors"
             ],
         },
-
-        "linux-ppc64le": {
-            target_os: "linux",
-            target_cpu: "ppc64le",
-            build_cpu: "x64",
-            dependencies: ["devkit", "build_devkit", "cups"],
-            configure_args: [
-                "--openjdk-target=ppc64le-linux-gnu", "--with-freetype=bundled",
-                "--disable-warnings-as-errors"
-            ],
-        },
-
-        "linux-s390x": {
-            target_os: "linux",
-            target_cpu: "s390x",
-            build_cpu: "x64",
-            dependencies: ["devkit", "build_devkit", "cups"],
-            configure_args: [
-                "--openjdk-target=s390x-linux-gnu", "--with-freetype=bundled",
-                "--disable-warnings-as-errors"
-            ],
-        },
     };
 
     // Add the base settings to all the main profiles
     common.main_profile_names.forEach(function (name) {
         profiles[name] = concatObjects(common.main_profile_base, profiles[name]);

@@ -510,29 +481,20 @@
     // platform. This profile only runs the makefile tests.
     // Ant is needed to run the idea project generator test.
     var testmakeBase = {
         dependencies: [ "ant" ],
         environment: {
-            "ANT_HOME": input.get("ant", "home_path")
+            "ANT_HOME": input.get("ant", "install_path") + "/apache-ant-1.7.1"
         }
     };
     [ "linux-x64", "macosx-x64", "solaris-sparcv9", "solaris-x64", "windows-x64"]
         .forEach(function (name) {
             var maketestName = name + "-testmake";
             profiles[maketestName] = concatObjects(profiles[name], testmakeBase);
             profiles[maketestName].default_make_targets = [ "test-make" ];
         });
 
-    // Generate -gcov profiles
-    [ "linux-x64", "macosx-x64" ].forEach(function (name) {
-        var gcovName = name + "-gcov";
-        profiles[gcovName] = clone(profiles[name]);
-        profiles[gcovName].default_make_targets = ["product-bundles", "test-bundles"];
-        profiles[gcovName].configure_args = concat(profiles[gcovName].configure_args,
-            ["--enable-native-coverage", "--disable-warnings-as-errors"]);
-    });
-
     // Profiles for building the zero jvm variant. These are used for verification.
     var zeroProfiles = {
         "linux-x64-zero": {
             target_os: "linux",
             target_cpu: "x64",

@@ -607,24 +569,10 @@
             var bootJdkIndex = profiles[bootcyclePrebuiltName].dependencies.indexOf("boot_jdk");
             delete profiles[bootcyclePrebuiltName].dependencies[bootJdkIndex];
             profiles[bootcyclePrebuiltName].default_make_targets = [ "product-images" ];
         });
 
-    // JCov profiles build JCov-instrumented JDK image based on images provided through dependencies.
-    [ "linux-x64", "macosx-x64", "solaris-sparcv9", "windows-x64"]
-        .forEach(function (name) {
-            var jcovName = name + "-jcov";
-            profiles[jcovName] = clone(common.main_profile_base);
-            profiles[jcovName].target_os = profiles[name].target_os
-            profiles[jcovName].target_cpu = profiles[name].target_cpu
-            profiles[jcovName].default_make_targets = [ "jcov-bundles" ];
-            profiles[jcovName].dependencies = concat(profiles[jcovName].dependencies,
-                [ name + ".jdk", "devkit" ]);
-            profiles[jcovName].configure_args = concat(profiles[jcovName].configure_args,
-                ["--with-jcov-input-jdk=" + input.get(name + ".jdk", "home_path")]);
-        });
-
     //
     // Define artifacts for profiles
     //
     // Macosx bundles are named osx
     // tar.gz.

@@ -656,16 +604,10 @@
        "linux-aarch64": {
             platform: "linux-aarch64",
         },
        "linux-arm32": {
             platform: "linux-arm32",
-        },
-       "linux-ppc64le": {
-            platform: "linux-ppc64le",
-        },
-       "linux-s390x": {
-            platform: "linux-s390x",
         }
     }
     // Generate common artifacts for all main profiles
     Object.keys(artifactData).forEach(function (name) {
         profiles[name] = concatObjects(profiles[name],

@@ -744,84 +686,34 @@
             "\/jdk-", "/openjdk-",
             replaceAll("\/\\1", "/open\\1",
                        profiles[openName].artifacts["jdk"].remote));
     });
 
+    // Enable ZGC in linux-x64-open builds
+    [ "linux-x64-open" ].forEach(function (name) {
+        var configureArgs = { configure_args: [ "--with-jvm-features=zgc" ] };
+        var debugName = name + common.debug_suffix;
+        profiles[name] = concatObjects(profiles[name], configureArgs);
+        profiles[debugName] = concatObjects(profiles[debugName], configureArgs);
+    });
+
     // Generate cmp-baseline profiles for each main profile and their
     // corresponding debug profile. This profile does a compare build run with no
     // changes to verify that the compare script has a clean baseline
     common.main_profile_names.forEach(function (name) {
         [ "", common.open_suffix ].forEach(function (suffix) {
             var cmpBaselineName = name + suffix + "-cmp-baseline";
             profiles[cmpBaselineName] = clone(profiles[name + suffix]);
             // Only compare the images target. This should pressumably be expanded
             // to include more build targets when possible.
-            profiles[cmpBaselineName].default_make_targets = [ "images", "test-image" ];
-            if (name == "linux-x64") {
-                profiles[cmpBaselineName].default_make_targets
-                    = concat(profiles[cmpBaselineName].default_make_targets, "docs");
-            }
+            profiles[cmpBaselineName].default_make_targets = [ "images" ];
             profiles[cmpBaselineName].make_args = [ "COMPARE_BUILD=CONF=" ];
             // Do not inherit artifact definitions from base profile
             delete profiles[cmpBaselineName].artifacts;
         });
     });
 
-    // Artifacts of JCov profiles
-    [ "linux-x64", "macosx-x64", "solaris-sparcv9", "windows-x64"]
-        .forEach(function (name) {
-            var o = artifactData[name]
-            var jdk_subdir = (o.jdk_subdir != null ? o.jdk_subdir : "jdk-" + data.version);
-            var jdk_suffix = (o.jdk_suffix != null ? o.jdk_suffix : "tar.gz");
-            var pf = o.platform
-            var jcovName = name + "-jcov";
-            profiles[jcovName].artifacts = {
-                jdk: {
-                    local: "bundles/\\(jdk-jcov.*bin." + jdk_suffix + "\\)",
-                    remote: [
-                        "bundles/" + pf + "/jdk-jcov-" + data.version + "_" + pf + "_bin." + jdk_suffix
-                    ],
-                    subdir: jdk_subdir,
-                    exploded: "images/jdk-jcov"
-                }
-            };
-        });
-
-    // Artifacts of gcov (native-code-coverage) profiles
-    [ "linux-x64", "macosx-x64" ].forEach(function (name) {
-        var o = artifactData[name]
-        var pf = o.platform
-        var jdk_subdir = (o.jdk_subdir != null ? o.jdk_subdir : "jdk-" + data.version);
-        var jdk_suffix = (o.jdk_suffix != null ? o.jdk_suffix : "tar.gz");
-        var gcovName = name + "-gcov";
-        profiles[gcovName].artifacts = {
-            jdk: {
-                local: "bundles/\\(jdk.*bin." + jdk_suffix + "\\)",
-                remote: [
-                    "bundles/" + pf + "/jdk-" + data.version + "_" + pf + "_bin-gcov." + jdk_suffix,
-                ],
-                subdir: jdk_subdir,
-                exploded: "images/jdk",
-            },
-            test: {
-                    local: "bundles/\\(jdk.*bin-tests.tar.gz\\)",
-                    remote: [
-                        "bundles/" + pf + "/jdk-" + data.version + "_" + pf + "_bin-gcov-tests.tar.gz",
-                    ],
-                    exploded: "images/test"
-            },
-            jdk_symbols: {
-                    local: "bundles/\\(jdk.*bin-symbols.tar.gz\\)",
-                    remote: [
-                        "bundles/" + pf + "/jdk-" + data.version + "_" + pf + "_bin-gcov-symbols.tar.gz",
-                    ],
-                    subdir: jdk_subdir,
-                    exploded: "images/jdk"
-                },
-            };
-    });
-
     // Profiles used to run tests.
     var testOnlyProfiles = {
         "run-test": {
             target_os: input.build_os,
             target_cpu: input.build_cpu,

@@ -837,35 +729,24 @@
     // Profiles used to run tests using Jib for internal dependencies.
     var testedProfile = input.testedProfile;
     if (testedProfile == null) {
         testedProfile = input.build_os + "-" + input.build_cpu;
     }
-    var testedProfileJDK = testedProfile + ".jdk";
-    var testedProfileTest = ""
-    if (testedProfile.endsWith("-jcov")) {
-        testedProfileTest = testedProfile.substring(0, testedProfile.length - "-jcov".length) + ".test";
-    } else {
-        testedProfileTest = testedProfile + ".test";
-    }
-    var testOnlyMake = [ "run-test-prebuilt", "LOG_CMDLINES=true", "JTREG_VERBOSE=fail,error,time" ];
-    if (testedProfile.endsWith("-gcov")) {
-        testOnlyMake = concat(testOnlyMake, "GCOV_ENABLED=true")
-    }
     var testOnlyProfilesPrebuilt = {
         "run-test-prebuilt": {
             target_os: input.build_os,
             target_cpu: input.build_cpu,
             dependencies: [
-                "jtreg", "gnumake", "boot_jdk", "devkit", "jib", "jcov", testedProfileJDK,
-                testedProfileTest
+                "jtreg", "gnumake", "boot_jdk", "devkit", "jib", testedProfile + ".jdk",
+                testedProfile + ".test"
             ],
             src: "src.conf",
-            make_args: testOnlyMake,
+            make_args: [ "run-test-prebuilt", "LOG_CMDLINES=true", "JTREG_VERBOSE=fail,error,time" ],
             environment: {
                 "BOOT_JDK": common.boot_jdk_home,
-                "JDK_IMAGE_DIR": input.get(testedProfileJDK, "home_path"),
-                "TEST_IMAGE_DIR": input.get(testedProfileTest, "home_path")
+                "JDK_IMAGE_DIR": input.get(testedProfile + ".jdk", "home_path"),
+                "TEST_IMAGE_DIR": input.get(testedProfile + ".test", "home_path")
             },
             labels: "test"
         }
     };
 

@@ -942,40 +823,25 @@
  * @returns {{}} Dependencies part of configuration
  */
 var getJibProfilesDependencies = function (input, common) {
 
     var devkit_platform_revisions = {
-        linux_x64: "gcc8.2.0-OL6.4+1.0",
-        macosx_x64: "Xcode10.1-MacOSX10.14+1.0",
+        linux_x64: "gcc7.3.0-OEL6.4+1.1",
+        macosx_x64: "Xcode9.4-MacOSX10.13+1.0",
         solaris_x64: "SS12u4-Solaris11u1+1.0",
         solaris_sparcv9: "SS12u6-Solaris11u3+1.0",
-        windows_x64: "VS2017-15.9.6+1.0",
-        linux_aarch64: "gcc8.2.0-Fedora27+1.0",
-        linux_arm: "gcc8.2.0-Fedora27+1.0",
-        linux_ppc64le: "gcc8.2.0-Fedora27+1.0",
-        linux_s390x: "gcc8.2.0-Fedora27+1.0"
+        windows_x64: "VS2017-15.5.5+1.0",
+        linux_aarch64: "gcc7.3.0-Fedora27+1.1",
+        linux_arm: "gcc7.3.0-Fedora27+1.1"
     };
 
     var devkit_platform = (input.target_cpu == "x86"
         ? input.target_os + "_x64"
         : input.target_platform);
 
-    var devkit_cross_prefix = "";
-    if (input.build_platform != input.target_platform
-       && input.build_platform != devkit_platform) {
-        devkit_cross_prefix = input.build_platform + "-to-";
-    }
-
     var boot_jdk_platform = (input.build_os == "macosx" ? "osx" : input.build_os)
         + "-" + input.build_cpu;
-    var boot_jdk_ext = (input.build_os == "windows" ? ".zip" : ".tar.gz")
-    // If running in WSL and building for Windows, it will look like Linux,
-    // but we need a Windows boot JDK.
-    if (isWsl(input) && input.target_os == "windows") {
-        boot_jdk_platform = "windows-" + input.build_cpu;
-        boot_jdk_ext = ".zip";
-    }
 
     var makeBinDir = (input.build_os == "windows"
         ? input.get("gnumake", "install_path") + "/cygwin/bin"
         : input.get("gnumake", "install_path") + "/bin");
 

@@ -983,21 +849,22 @@
 
         boot_jdk: {
             server: "jpg",
             product: "jdk",
             version: common.boot_jdk_version,
-            build_number: common.boot_jdk_build_number,
+            build_number: "28",
             file: "bundles/" + boot_jdk_platform + "/jdk-" + common.boot_jdk_version + "_"
-                + boot_jdk_platform + "_bin" + boot_jdk_ext,
+                + boot_jdk_platform + "_bin"
+                + (input.build_os == "windows" ? ".zip" : ".tar.gz"),
             configure_args: "--with-boot-jdk=" + common.boot_jdk_home,
             environment_path: common.boot_jdk_home + "/bin"
         },
 
         devkit: {
             organization: common.organization,
             ext: "tar.gz",
-            module: "devkit-" + devkit_cross_prefix + devkit_platform,
+            module: "devkit-" + devkit_platform,
             revision: devkit_platform_revisions[devkit_platform],
             environment: {
                 "DEVKIT_HOME": input.get("devkit", "home_path"),
             }
         },

@@ -1016,11 +883,11 @@
         },
 
         jtreg: {
             server: "javare",
             revision: "4.2",
-            build_number: "b14",
+            build_number: "b13",
             checksum_file: "MD5_VALUES",
             file: "jtreg_bin-4.2.zip",
             environment_name: "JT_HOME",
             environment_path: input.get("jtreg", "install_path") + "/jtreg/bin"
         },

@@ -1029,25 +896,10 @@
             organization: common.organization,
             ext: "tar.gz",
             revision: "1.21+1.0"
         },
 
-        jcov: {
-            // Until an official build of JCov is available, use custom
-            // build to support classfile version 57.
-            // See CODETOOLS-7902358 for more info.
-            // server: "jpg",
-            // product: "jcov",
-            // version: "3.0",
-            // build_number: "b07",
-            // file: "bundles/jcov-3_0.zip",
-            organization: common.organization,
-            revision: "3.0-58-support+1.0",
-            ext: "zip",
-            environment_name: "JCOV_HOME",
-        },
-
         gnumake: {
             organization: common.organization,
             ext: "tar.gz",
             revision: "4.0+1.0",
 

@@ -1086,11 +938,11 @@
 
         pandoc: {
             organization: common.organization,
             ext: "tar.gz",
             revision: "2.3.1+1.0",
-            module: "pandoc-" + input.build_platform,
+            module: "pandoc-" + input.target_platform,
             configure_args: "PANDOC=" + input.get("pandoc", "install_path") + "/pandoc/pandoc",
             environment_path: input.get("pandoc", "install_path") + "/pandoc"
         },
 
         // This adds java jib as a dependency for the test artifacts resolver

@@ -1098,11 +950,12 @@
             organization: "com.oracle.java.jib",
             ext: "zip",
             classifier: "distribution",
             revision: "3.0-SNAPSHOT",
             environment_name: "JIB_HOME",
-            environment_value: input.get("jib", "home_path")
+            environment_value: input.get("jib", "install_path")
+                + "/jib-3.0-SNAPSHOT-distribution"
         },
 
         ant: {
             organization: common.organization,
             ext: "zip",

@@ -1281,14 +1134,11 @@
 var getVersion = function (feature, interim, update, patch) {
     var version_numbers = getVersionNumbers();
     var version = (feature != null ? feature : version_numbers.get("DEFAULT_VERSION_FEATURE"))
         + "." + (interim != null ? interim : version_numbers.get("DEFAULT_VERSION_INTERIM"))
         + "." + (update != null ? update :  version_numbers.get("DEFAULT_VERSION_UPDATE"))
-        + "." + (patch != null ? patch : version_numbers.get("DEFAULT_VERSION_PATCH"))
-        + "." + version_numbers.get("DEFAULT_VERSION_EXTRA1")
-        + "." + version_numbers.get("DEFAULT_VERSION_EXTRA2")
-        + "." + version_numbers.get("DEFAULT_VERSION_EXTRA3");
+        + "." + (patch != null ? patch : version_numbers.get("DEFAULT_VERSION_PATCH"));
     while (version.match(".*\\.0$")) {
         version = version.substring(0, version.length - 2);
     }
     return version;
 };

@@ -1299,20 +1149,14 @@
  */
 var versionArgs = function(input, common) {
     var args = ["--with-version-build=" + common.build_number];
     if (input.build_type == "promoted") {
         args = concat(args,
-                      "--with-version-pre=" + version_numbers.get("DEFAULT_PROMOTED_VERSION_PRE"),
+                      // This needs to be changed when we start building release candidates
+                      // with-version-pre must be set to ea for 'ea' and empty for fcs build
+                      "--with-version-pre=ea",
                       "--without-version-opt");
-    } else if (input.build_type == "ci") {
-        var optString = input.build_id_data.ciBuildNumber;
-        var preString = input.build_id_data.projectName;
-        if (preString == "jdk") {
-            preString = version_numbers.get("DEFAULT_PROMOTED_VERSION_PRE");
-        }
-        args = concat(args, "--with-version-pre=" + preString,
-                     "--with-version-opt=" + optString);
     } else {
         args = concat(args, "--with-version-opt=" + common.build_id);
     }
     return args;
 }

@@ -1334,15 +1178,5 @@
         version_numbers.load(stream);
         stream.close();
     }
     return version_numbers;
 }
-
-/**
- * Returns true if running in Windows Subsystem for Linux. Jib does not yet
- * detect wsl as osenv, so fall back on linux with version containing Microsoft.
- */
-var isWsl = function (input) {
-    return ( input.build_osenv == "wsl"
-             || (input.build_os == "linux"
-                 && java.lang.System.getProperty("os.version").contains("Microsoft")));
-}
< prev index next >