-
Notifications
You must be signed in to change notification settings - Fork 211
48 lines (45 loc) · 1.52 KB
/
ci-android-jni.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
name: CI
on: [push, pull_request]
permissions:
contents: read
jobs:
build-android-jni:
runs-on: ubuntu-latest
strategy:
fail-fast: false
steps:
- name: Checkout the repository
uses: actions/checkout@v3
- name: Download and Setup the Android NDK
uses: nttld/setup-ndk@v1
id: setup-ndk
with:
# r25c is the same as 25.2.9519653.
ndk-version: r25c
add-to-path: false
- name: Setup ninja
uses: seanmiddleditch/gha-setup-ninja@v3
- name: Setup cmake
uses: jwlawson/[email protected]
with:
# This is the minimum cmake version needed to build libgav1.
cmake-version: "3.7.x"
- name: Build libgav1 with the Android NDK
working-directory: ext
run: bash libgav1_android.sh ${{ steps.setup-ndk.outputs.ndk-path }}
- name: Setup JDK
uses: actions/setup-java@v3
with:
distribution: "zulu"
java-version: 11
- name: Download and Setup the Android SDK
uses: android-actions/setup-android@v2
- name: Install CMake in the Android SDK
# This is the same version of cmake that is found in build.gradle. This
# will be used to build libavif and the JNI bindings.
run: sdkmanager "cmake;3.22.1"
- name: Build the libavif JNI Wrapper
working-directory: android_jni
run: ./gradlew --no-daemon assembleRelease
env:
ANDROID_NDK_HOME: ${{ steps.setup-ndk.outputs.ndk-path }}