Skip to content

Commit bb9d205

Browse files
committed
Switch to gradle based build for Android CI
1 parent 4899137 commit bb9d205

1 file changed

Lines changed: 17 additions & 11 deletions

File tree

.github/workflows/cmake-multi-platform.yml

Lines changed: 17 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -82,15 +82,21 @@ jobs:
8282
steps:
8383
- uses: actions/checkout@v6
8484

85-
- name: Configure CMake
86-
run: >
87-
cmake -B build
88-
-DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK_LATEST_HOME/build/cmake/android.toolchain.cmake
89-
-DANDROID_ABI=${{ matrix.abi }}
90-
-DANDROID_PLATFORM=android-21
91-
-DCMAKE_BUILD_TYPE=${{ matrix.build_type }}
92-
-DSDL_UNIX_CONSOLE_BUILD=ON
93-
-S .
85+
- name: Setup JDK 17
86+
uses: actions/setup-java@v5
87+
with:
88+
java-version: '17'
89+
distribution: 'temurin'
90+
cache: 'gradle'
9491

95-
- name: Build
96-
run: cmake --build build --config ${{ matrix.build_type }}
92+
- name: Setup Android SDK
93+
uses: android-actions/setup-android@v4
94+
95+
- name: Grant execute permission for gradlew
96+
run: chmod +x android/gradlew
97+
98+
- name: Buld APK with Gradle
99+
run: ./gradlew assembleRelease
100+
working-directory: android
101+
env:
102+
ANDROID_NDK_HOME: ${{ env.ANDROID_NDK_HOME }}

0 commit comments

Comments
 (0)