Pārlūkot izejas kodu

Lose MacOS and add Linux aarch64

Toni Helenius 3 nedēļas atpakaļ
vecāks
revīzija
b766fc4ca6
2 mainītis faili ar 35 papildinājumiem un 77 dzēšanām
  1. 17 22
      installers/build-installers.sh
  2. 18 55
      installers/download-jdks.sh

+ 17 - 22
installers/build-installers.sh

@@ -43,10 +43,20 @@ function prepare_nbpackage {
     fi
 }
 
+function build_nbpackage {
+    echo ">> Building the nbpackage installer for $1-$2"
+
+    ./nbpackage/nbpackage-$nbpackage_version/bin/nbpackage --input ../dist/jmonkeyplatform.zip --config $1-$2/$3 --output ../dist/ -v -Ppackage.version=$4
+
+    echo "<< OK!"
+}
+
+
 function build_linux_deb {
     echo "> Building the Linux DEB"
 
-    ./nbpackage/nbpackage-$nbpackage_version/bin/nbpackage --input ../dist/jmonkeyplatform.zip --config linux-x64/jmonkeyengine-x64-deb.properties --output ../dist/ -v -Ppackage.version=$1
+    build_nbpackage linux x64 jmonkeyengine-x64-deb.properties $1
+    build_nbpackage linux aarch64 jmonkeyengine-aarch64-deb.properties $1
 
     echo "< OK!"
 }
@@ -55,8 +65,8 @@ function build_windows_installer {
     echo "> Building the Windows installer"
     
     setup_inno_setup $2
-
-    ./nbpackage/nbpackage-$nbpackage_version/bin/nbpackage --input ../dist/jmonkeyplatform.zip --config windows-x64/jmonkeyengine-windows-x64.properties --output ../dist/ -v -Ppackage.version=$1
+    
+    build_nbpackage windows x64 jmonkeyengine-windows-x64.properties $1
 
     echo "< OK!"
 }
@@ -96,28 +106,12 @@ function download_inno_setup {
 function build_macos_pgk {
     echo "> Building the MacOS pgk"
     
-    build_macos_x64_pgk $1
-    build_macos_aarch64_pgk $1
+    build_nbpackage macos x64 jmonkeyengine-macos-x64.properties $1
+    build_nbpackage macos aarch64 jmonkeyengine-macos-aarch64.properties $1
 
     echo "< OK!"
 }
 
-function build_macos_x64_pgk {
-    echo ">> Building the MacOS x64 pgk"
-
-    ./nbpackage/nbpackage-$nbpackage_version/bin/nbpackage --input ../dist/jmonkeyplatform.zip --config macos-x64/jmonkeyengine-macos-x64.properties --output ../dist/ -v -Ppackage.version=$1
-
-    echo "<< OK!"
-}
-
-function build_macos_aarch64_pgk {
-    echo ">> Building the MacOS aarch64 pgk"
-
-    ./nbpackage/nbpackage-$nbpackage_version/bin/nbpackage --input ../dist/jmonkeyplatform.zip --config macos-aarch64/jmonkeyengine-macos-aarch64.properties --output ../dist/ -v -Ppackage.version=$1
-
-    echo "<< OK!"
-}
-
 echo "Building installers with version tag $1"
 
 versionString=$1
@@ -131,4 +125,5 @@ download_nbpackage
 prepare_nbpackage
 build_linux_deb $versionString
 build_windows_installer $versionString $2
-build_macos_pgk $versionString
+# MACOS needs signed packages etc. So disabled
+#build_macos_pgk $versionString

+ 18 - 55
installers/download-jdks.sh

@@ -20,26 +20,24 @@ function download_jdk {
     fi
 }
 
-function build_mac_jdk {
-    echo "> Getting the Mac JDK"
+function get_jdk_macos {
+    echo "> Getting the JDK for MacOS-$1"
 
-    download_jdk x64 macos .tar.gz
-    download_jdk aarch64 macos .tar.gz
+    download_jdk "$1" macos .tar.gz
 
     echo "< OK!"
 }
 
-# PARAMS arch
-function unpack_windows {
-    echo ">> Getting the JDK for windows-$1"
+function get_jdk_windows {
+    echo ">> Getting the JDK for Windows-$1"
 
     download_jdk "$1" windows .zip
     
     echo "<< OK!"
 }
 
-function unpack_linux {
-    echo ">> Getting the JDK for linux-$1"
+function get_jdk_linux {
+    echo ">> Getting the JDK for Linux-$1"
 
     download_jdk "$1" linux .tar.gz
 
@@ -48,63 +46,28 @@ function unpack_linux {
 
 
 # PARAMS: os arch arch_unzipsfx
-function compile_other {
+function get_jdk {
     echo "> Getting JDK for $1-$2"
 
-    if [[ $1 != "windows" && $1 != "linux" ]]; then
+    if [[ $1 != "windows" && $1 != "linux" && $1 != "macos" ]]; then
         echo "Unknown Platform $1. ERROR!!!"
         exit 1
     fi
 
     # Depends on UNPACK and thus DOWNLOAD
     if [ $1 == "windows" ]; then
-        unpack_windows $2
+        get_jdk_windows $2
     elif [ $1 == "linux" ]; then
-        unpack_linux $2
+        get_jdk_linux $2
+    elif [ $1 == "macos" ]; then
+        get_jdk_macos $2
     fi
 
     echo "< OK!"
 }
 
-
-# PARAMS: os arch arch_unzipsfx
-function build_other_jdk {
-    echo "> Getting Package for $1-$2"
-    compile_other $1 $2 $3 # Depend on Compile
-
-    echo "< OK!"
-}
-
-if [ "x$TRAVIS" != "x" ]; then
-    if [ "x$BUILD_X64" != "x" ]; then
-        build_other_jdk windows x64 x64
-        build_other_jdk linux x64 x64
-    fi
-    if [ "x$BUILD_X86" != "x" ]; then
-        build_other_jdk windows x86-32 x86
-    fi
-    if [ "x$BUILD_OTHER" != "x" ]; then
-        build_mac_jdk
-    fi
-else
-    if [ "x$PARALLEL" != "x" ];
-    then
-        build_mac_jdk &
-        build_other_jdk linux x64 x64 &
-        # Windows 32bit not by default build_other_jdk windows x86-32 x86 &
-        build_other_jdk windows x64 x64 &
-    else
-        build_mac_jdk
-        build_other_jdk linux x64 x64
-        ## Windows 32bit not by default build_other_jdk windows x86-32 x86
-        build_other_jdk windows x64 x64
-        # Linux 32bit not supported... build_other_jdk linux x86-32
-    fi
-    
-fi
-
-if [ "x$PARALLEL" != "x" ];
-then
-    wait
-fi
-cd ../../
+get_jdk linux x64
+get_jdk linux aarch64
+get_jdk windows x64
+#get_jdk macos x64
+#get_jdk macos aarch64