Add android build
This commit is contained in:
parent
7e6975e5be
commit
714022af1f
1 changed files with 66 additions and 72 deletions
32
.github/workflows/release.yaml
vendored
32
.github/workflows/release.yaml
vendored
|
@ -1,8 +1,8 @@
|
|||
on:
|
||||
# Indicates I want to run this workflow on all branches, PR, and tags
|
||||
push:
|
||||
branches: ["main", "draft"]
|
||||
tags: ["*"]
|
||||
branches: [ "main", "draft" ]
|
||||
tags: [ "*" ]
|
||||
pull_request:
|
||||
branches: [ "main" ]
|
||||
|
||||
|
@ -40,11 +40,13 @@ jobs:
|
|||
target: i686-unknown-freebsd
|
||||
build-args: "--release"
|
||||
|
||||
# - name: Android aarch64
|
||||
# target: aarch64-linux-android
|
||||
- name: Android aarch64
|
||||
target: aarch64-linux-android
|
||||
build-args: "--release"
|
||||
|
||||
# - name: Android armv7
|
||||
# target: armv7-linux-androideabi
|
||||
- name: Android armv7
|
||||
target: armv7-linux-androideabi
|
||||
build-args: "--release"
|
||||
|
||||
#- name: Linux mips
|
||||
# target: mips-unknown-linux-musl
|
||||
|
@ -91,6 +93,10 @@ jobs:
|
|||
if: contains(matrix.platform.target, 'android')
|
||||
run: sudo apt install android-libunwind libunwind8
|
||||
|
||||
- name: Setup Android SDK
|
||||
if: contains(matrix.platform.target, 'android')
|
||||
uses: android-actions/setup-android@v3
|
||||
|
||||
- name: Checkout Git repo
|
||||
uses: actions/checkout@v3
|
||||
|
||||
|
@ -105,18 +111,6 @@ jobs:
|
|||
target: ${{ matrix.platform.target }}
|
||||
components: rustfmt, clippy
|
||||
|
||||
- name: Install rust toolchain for Android
|
||||
if: ${{ contains(matrix.platform.target, 'android') }}
|
||||
uses: actions-rs/toolchain@v1
|
||||
with:
|
||||
# Need new release of cross to target rust > 1.68.0
|
||||
# https://github.com/cross-rs/cross/issues/1222
|
||||
profile: minimal
|
||||
toolchain: 1.67.0
|
||||
override: true
|
||||
target: ${{ matrix.platform.target }}
|
||||
components: rustfmt, clippy
|
||||
|
||||
- name: Show command used for Cargo
|
||||
run: |
|
||||
echo "cargo command is: ${{ env.CARGO }}"
|
||||
|
@ -140,7 +134,7 @@ jobs:
|
|||
|
||||
release:
|
||||
name: Release
|
||||
needs: [build]
|
||||
needs: [ build ]
|
||||
# We run the release job only if a tag starts with 'v' letter
|
||||
if: startsWith( github.ref, 'refs/tags/v' )
|
||||
runs-on: ubuntu-22.04
|
||||
|
|
Loading…
Reference in a new issue