-
Notifications
You must be signed in to change notification settings - Fork 6
53 lines (48 loc) · 1.25 KB
/
build.yml
File metadata and controls
53 lines (48 loc) · 1.25 KB
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
49
50
51
52
53
name: Build Module
on:
push:
tags: [ "*" ]
branches: [ "main" ]
workflow_call:
workflow_dispatch:
jobs:
build-module:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Setup Android SDK
uses: android-actions/setup-android@v3
with:
packages: ''
- name: Install toolchain
run: |
rustup default stable
rustup update stable
cargo install cargo-ndk
rustup target install aarch64-linux-android
- name: Cache Rust
uses: Swatinem/rust-cache@v2
with:
workspaces: my_lua_module
cache-targets: false
- name: Build Rust
run: |
cd my_lua_module
cargo ndk -t aarch64-linux-android -- build --release
- name: copy to output
run: |
mkdir -p build
cp my_lua_module/target/aarch64-linux-android/release/libhello.so build/
cp customize.sh build/
cp module.prop build/
cp mylua.lua build/
- name: Upload build artifact
uses: actions/upload-artifact@v5
with:
name: build
path: build