Skip to content
You're viewing an older version of this GitHub Action. Do you want to see the latest version instead?
play

GitHub Action

Setup Android NDK

v1.2.0

Setup Android NDK

play

Setup Android NDK

Setup an Android NDK environment by downloading and optionally caching it and adding it to the PATH

Installation

Copy and paste the following snippet into your .yml file.

              

- name: Setup Android NDK

uses: nttld/setup-ndk@v1.2.0

Learn more about this action in nttld/setup-ndk

Choose a version

setup-ndk

build-test status

This action sets up an Android NDK environment by downloading and caching a version of the NDK and adding it to the PATH

Usage

See action.yml

Basic

steps:
  - uses: actions/checkout@v2
  - uses: nttld/setup-ndk@v1
    with:
      ndk-version: r25b
  - runs: ndk-build NDK_PROJECT_PATH=. APP_BUILD_SCRIPT=./Android.mk NDK_APPLICATION_MK=./Application.mk

Using the installation path

steps:
  - uses: actions/checkout@v2
  - uses: nttld/setup-ndk@v1
    id: setup-ndk
    with:
      ndk-version: r21e
      add-to-path: false
  - run: ./build.sh
    env:
      ANDROID_NDK_HOME: ${{ steps.setup-ndk.outputs.ndk-path }}

Caching locally

steps:
  - uses: actions/checkout@v2
  - uses: nttld/setup-ndk@v1
    with:
      ndk-version: r25b
      local-cache: true