浏览代码

Update the github Android builds config

The configuration was updated to generate:
- Godot Android Editor build
- Godot Android template build for arm32
- Godot Android template build for arm64

Co-authored-by: Rémi Verschelde <[email protected]>
Fredia Huya-Kouadio 1 年之前
父节点
当前提交
8026706748
共有 1 个文件被更改,包括 40 次插入14 次删除
  1. 40 14
      .github/workflows/android_builds.yml

+ 40 - 14
.github/workflows/android_builds.yml

@@ -13,9 +13,30 @@ concurrency:
   cancel-in-progress: true
   cancel-in-progress: true
 
 
 jobs:
 jobs:
-  android-template:
+  build-android:
     runs-on: "ubuntu-20.04"
     runs-on: "ubuntu-20.04"
-    name: Template (target=template_release)
+    name: ${{ matrix.name }}
+    strategy:
+      fail-fast: false
+      matrix:
+        include:
+          - name: Editor (target=editor)
+            cache-name: android-editor
+            target: editor
+            tests: false
+            sconsflags: arch=arm64 production=yes
+
+          - name: Template arm32 (target=template_release, arch=arm32)
+            cache-name: android-template-arm32
+            target: template_release
+            tests: false
+            sconsflags: arch=arm32
+
+          - name: Template arm64 (target=template_release, arch=arm64)
+            cache-name: android-template-arm64
+            target: template_release
+            tests: false
+            sconsflags: arch=arm64
 
 
     steps:
     steps:
       - uses: actions/checkout@v4
       - uses: actions/checkout@v4
@@ -30,33 +51,38 @@ jobs:
 
 
       - name: Setup Godot build cache
       - name: Setup Godot build cache
         uses: ./.github/actions/godot-cache
         uses: ./.github/actions/godot-cache
+        with:
+          cache-name: ${{ matrix.cache-name }}
         continue-on-error: true
         continue-on-error: true
 
 
       - name: Setup Python and SCons
       - name: Setup Python and SCons
         uses: ./.github/actions/godot-deps
         uses: ./.github/actions/godot-deps
 
 
-      - name: Compilation (arm32)
-        uses: ./.github/actions/godot-build
-        with:
-          sconsflags: ${{ env.SCONSFLAGS }} arch=arm32
-          platform: android
-          target: template_release
-          tests: false
-
-      - name: Compilation (arm64)
+      - name: Compilation
         uses: ./.github/actions/godot-build
         uses: ./.github/actions/godot-build
         with:
         with:
-          sconsflags: ${{ env.SCONSFLAGS }} arch=arm64
+          sconsflags: ${{ env.SCONSFLAGS }} ${{ matrix.sconsflags }}
           platform: android
           platform: android
-          target: template_release
-          tests: false
+          target: ${{ matrix.target }}
+          tests: ${{ matrix.tests }}
 
 
       - name: Generate Godot templates
       - name: Generate Godot templates
+        if: matrix.target == 'template_release'
         run: |
         run: |
           cd platform/android/java
           cd platform/android/java
           ./gradlew generateGodotTemplates
           ./gradlew generateGodotTemplates
           cd ../../..
           cd ../../..
           ls -l bin/
           ls -l bin/
 
 
+      - name: Generate Godot editor
+        if: matrix.target == 'editor'
+        run: |
+          cd platform/android/java
+          ./gradlew generateGodotEditor
+          cd ../../..
+          ls -l bin/android_editor_builds/
+
       - name: Upload artifact
       - name: Upload artifact
         uses: ./.github/actions/upload-artifact
         uses: ./.github/actions/upload-artifact
+        with:
+          name: ${{ matrix.cache-name }}