From 48f1e3f952b29fedcac9885826fecccb9cffd6f4 Mon Sep 17 00:00:00 2001 From: james58899 Date: Wed, 5 Jun 2024 05:28:53 +0000 Subject: [PATCH] Fix --- .github/workflows/build.yml | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index daf7d3f..71dba95 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -175,9 +175,11 @@ jobs: steps: - uses: actions/checkout@v4 - name: Install Android NDK + id: setup-ndk uses: nttld/setup-ndk@v1 with: ndk-version: r26d + add-to-path: false - uses: actions/cache@v4 with: path: | @@ -193,11 +195,14 @@ jobs: rustup target add ${{ matrix.target }} - name: Build env: + ANDROID_NDK_HOME: ${{ steps.setup-ndk.outputs.ndk-path }} CARGO_TARGET_AARCH64_LINUX_ANDROID_LINKER: "aarch64-linux-android21-clang" CARGO_TARGET_ARMV7_LINUX_ANDROIDEABI_LINKER: "armv7a-linux-androideabi21-clang" CARGO_TARGET_I686_LINUX_ANDROID_LINKER: "i686-linux-android21-clang" CARGO_TARGET_X86_64_LINUX_ANDROID_LINKER: "x86_64-linux-android21-clang" - run: cargo build --verbose --release --target=${{ matrix.target }} + run: | + export PATH=$PATH:${ANDROID_NDK_HOME}/toolchains/llvm/prebuilt/linux-x86_64/bin + cargo build --verbose --release --target=${{ matrix.target }} - uses: actions/upload-artifact@v4 with: name: hath-rust-${{ matrix.target }}