From 6a778e0ee1afc7b0d45bc089b1eddeb9e23588a4 Mon Sep 17 00:00:00 2001 From: James Chen Date: Sat, 30 Sep 2023 09:21:14 +0800 Subject: [PATCH] PATCH: add generate-android-ndk-cache.yml --- .../workflows/generate-android-ndk-cache.yml | 31 +++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 .github/workflows/generate-android-ndk-cache.yml diff --git a/.github/workflows/generate-android-ndk-cache.yml b/.github/workflows/generate-android-ndk-cache.yml new file mode 100644 index 000000000..b83a53e92 --- /dev/null +++ b/.github/workflows/generate-android-ndk-cache.yml @@ -0,0 +1,31 @@ +name: Generate Android NDK Cache + +on: + workflow_dispatch: + inputs: + android_ndk_sdk_version: + description: 'Android NDK Version' + type: string + default: 'r21e' + required: true + +jobs: + generate_android_ndk_cache: + name: "Generate Android NDK Cache" + runs-on: ubuntu-latest + steps: + - name: Setup Android NDK + uses: nttld/setup-ndk@v1 + id: setup-ndk + with: + ndk-version: ${{ github.event.inputs.android_ndk_sdk_version }} + local-cache: true + + - name: Verify + env: + ANDROID_NDK_HOME: ${{ steps.setup-ndk.outputs.ndk-path }} + run: | + cd ${ANDROID_NDK_HOME} + cat source.properties + platform=$(uname -s | tr '[:upper:]' '[:lower:]') + ./toolchains/llvm/prebuilt/${platform}-x86_64/bin/clang -v