54 lines
1.3 KiB
YAML
54 lines
1.3 KiB
YAML
name: Uniffi Builds
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
build_ios:
|
|
name: 'Build iOS'
|
|
runs-on: macos-latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
- name: Build
|
|
run: |
|
|
make prepare-apple
|
|
cd hello
|
|
make apple
|
|
|
|
- name: "Upload xcframework"
|
|
uses: actions/upload-artifact@v2
|
|
with:
|
|
name: HelloFFI.xcframework
|
|
path: hello/target/HelloFFI.xcframework
|
|
retention-days: 7
|
|
|
|
build_android:
|
|
name: 'Build Android'
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v3
|
|
with:
|
|
lfs: true
|
|
- uses: actions/setup-java@v3
|
|
with:
|
|
distribution: 'temurin'
|
|
java-version: '17'
|
|
cache: 'gradle'
|
|
# Reference: https://github.com/mozilla/rust-android-gradle/blob/master/.github/workflows/check.yml
|
|
- uses: actions-rs/toolchain@v1
|
|
# Reference: https://github.com/rust-windowing/android-ndk-rs/blob/master/.github/workflows/rust.yml
|
|
with:
|
|
toolchain: stable
|
|
override: true
|
|
target: aarch64-linux-android
|
|
- name: "More dependencies"
|
|
run: |
|
|
make prepare-android
|
|
- name: "Build Android library"
|
|
run: make android
|
|
working-directory: hello
|