Skip to content

Commit

Permalink
Add actions
Browse files Browse the repository at this point in the history
  • Loading branch information
Lauriethefish committed Apr 4, 2024
1 parent 20ba111 commit 4d9d38d
Showing 1 changed file with 34 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: "Compile and deploy"
on:
push:
pull_request:

jobs:
build:
name: Build and deploy site
runs-on: ubuntu-latest
env:
CC_aarch64_linux_android: /home/runner/android-ndk-r26c/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-android31-clang
AR_aarch64_linux_android: /home/runner/android-ndk-r26c/toolchains/llvm/prebuilt/linux-x86_64/bin/llvm-ar

steps:
- uses: actions/checkout@v4
- uses: actions-rust-lang/setup-rust-toolchain@v1
with:
target: aarch64-linux-android
- uses: mskelton/setup-yarn@v1
with:
node-version: '20.x'
- name: Download NDK
run: wget https://dl.google.com/android/repository/android-ndk-r26c-linux.zip -q -O ndk.zip
- name: Extract NDK
run: unzip ndk.zip -d /home/runner/ -q
- name: Create cargo config
run: |
echo '[target.aarch64-linux-android]
ar = "${{ env.AR_aarch64_linux_android }}"
linker = "${{ env.CC_aarch64_linux_android }}"' > /home/runner/.cargo/config.toml
- name: Output cargo config
run: cat /home/runner/.cargo/config.toml
- name: Build agent
run: cargo build --manifest-path=mbf-agent/Cargo.toml --target aarch64-linux-android --release

0 comments on commit 4d9d38d

Please sign in to comment.