changeset 45824:d161a843e941

8184075: Make run-test-prebuilt profile more robust Reviewed-by: tbell
author erikj
date Tue, 11 Jul 2017 14:04:05 +0200
parents f3cf2ee05985
children 49b020ee2a6a
files common/conf/jib-profiles.js
diffstat 1 files changed, 8 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/common/conf/jib-profiles.js	Thu Jul 06 16:03:54 2017 +0200
+++ b/common/conf/jib-profiles.js	Tue Jul 11 14:04:05 2017 +0200
@@ -615,6 +615,8 @@
     }
     var testOnlyProfilesPrebuilt = {
         "run-test-prebuilt": {
+            target_os: input.build_os,
+            target_cpu: input.build_cpu,
             src: "src.conf",
             dependencies: [ "jtreg", "gnumake", "boot_jdk", testedProfile + ".jdk",
                 testedProfile + ".test", "src.full"
@@ -635,13 +637,14 @@
     if (input.profile == "run-test-prebuilt") {
         if (profiles[testedProfile] == null) {
             error("testedProfile is not defined: " + testedProfile);
-        } else {
-            testOnlyProfilesPrebuilt["run-test-prebuilt"]["target_os"]
-                = profiles[testedProfile]["target_os"];
-            testOnlyProfilesPrebuilt["run-test-prebuilt"]["target_cpu"]
-                = profiles[testedProfile]["target_cpu"];
         }
     }
+    if (profiles[testedProfile] != null) {
+        testOnlyProfilesPrebuilt["run-test-prebuilt"]["target_os"]
+            = profiles[testedProfile]["target_os"];
+        testOnlyProfilesPrebuilt["run-test-prebuilt"]["target_cpu"]
+            = profiles[testedProfile]["target_cpu"];
+    }
     profiles = concatObjects(profiles, testOnlyProfilesPrebuilt);
 
     // On macosx add the devkit bin dir to the path in all the run-test profiles.