Clean up gnumake duplicated logic. ihse-testmakefiles-branch
authorihse
Thu, 30 Nov 2017 00:30:37 +0100
branchihse-testmakefiles-branch
changeset 55920 143496e1a14c
parent 55919 0ffb2cce1b19
child 55921 60356323be38
Clean up gnumake duplicated logic.
make/conf/jib-profiles.js
--- a/make/conf/jib-profiles.js	Wed Nov 29 23:34:29 2017 +0100
+++ b/make/conf/jib-profiles.js	Thu Nov 30 00:30:37 2017 +0100
@@ -789,6 +789,10 @@
     var boot_jdk_platform = (input.build_os == "macosx" ? "osx" : input.build_os)
         + "-" + input.build_cpu;
 
+    var makeBinDir = (input.build_os == "windows"
+        ? input.get("gnumake", "install_path") + "/cygwin/bin"
+        : input.get("gnumake", "install_path") + "/bin");
+
     var dependencies = {
 
         boot_jdk: {
@@ -841,18 +845,13 @@
                 ? "gnumake-" + input.build_osenv_platform
                 : "gnumake-" + input.build_platform),
 
-            configure_args: (input.build_os == "windows"
-                ? "MAKE=" + input.get("gnumake", "install_path") + "/cygwin/bin/make"
-                : "MAKE=" + input.get("gnumake", "install_path") + "/bin/make"),
+            configure_args: "MAKE=" + makeBinDir + "/make",
 
-            environment_name: "MAKE",
-            environment_value: (input.build_os == "windows"
-                ? input.get("gnumake", "install_path") + "/cygwin/bin/make"
-                : input.get("gnumake", "install_path") + "/bin/make"),
+            environment: {
+                "MAKE": makeBinDir + "/make"
+            },
 
-            environment_path: (input.build_os == "windows"
-                ? input.get("gnumake", "install_path") + "/cygwin/bin"
-                : input.get("gnumake", "install_path") + "/bin")
+            environment_path: makeBinDir
         },
 
         freetype: {