Skip to content

Commit d759ba4

Browse files
committed
build termux
1 parent 5780f8f commit d759ba4

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed

.github/workflows/build-termux.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Build for Termux
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
jobs:
9+
build:
10+
runs-on: ubuntu-latest # Or another suitable runner
11+
12+
steps:
13+
- name: Checkout code
14+
uses: actions/checkout@v4
15+
16+
- name: Install Rust and Android target
17+
run: |
18+
rustup target add aarch64-linux-android
19+
# Install cargo-ndk or cargo-xbuild if needed
20+
21+
- name: Setup Android NDK
22+
uses: nttld/setup-ndk@v1
23+
with:
24+
ndk-version: r25b # You might need to adjust this NDK version
25+
26+
- name: Build with Cargo for Termux
27+
run: |
28+
# Set any necessary environment variables for cross-compilation
29+
# Example: CARGO_NDK_ON_ANDROID=1 cargo ndk build --target aarch64-linux-android --release
30+
cargo build --target aarch64-linux-android --release
31+
#
32+
# - name: Upload artifact (optional)
33+
# uses: actions/upload-artifact@v4
34+
# with:
35+
# name: termux-binary
36+
# path: target/aarch64-linux-android/release/your_binary_name

0 commit comments

Comments
 (0)