File tree Expand file tree Collapse file tree 10 files changed +528
-39
lines changed Expand file tree Collapse file tree 10 files changed +528
-39
lines changed Original file line number Diff line number Diff line change 26
26
strategy :
27
27
matrix :
28
28
os : [ubuntu-latest, windows-latest, macos-latest]
29
- ndk-version : [r21e, r25b ]
29
+ ndk-version : [r21e, r25c ]
30
30
local-cache : [true, false]
31
31
32
32
runs-on : ${{ matrix.os }}
@@ -37,10 +37,16 @@ jobs:
37
37
with :
38
38
ndk-version : ${{ matrix.ndk-version }}
39
39
local-cache : ${{ matrix.local-cache }}
40
+ link-to-sdk : true
40
41
41
42
- run : ndk-build --version
42
43
- run : ${{ steps.install-ndk.outputs.ndk-path }}/ndk-build --version
43
44
45
+ - run : $ANDROID_HOME/ndk/${{ steps.install-ndk.outputs.ndk-full-version }}/ndk-build --version
46
+ if : matrix.os != 'windows-latest'
47
+ - run : " & $Env:ANDROID_HOME/ndk/${{ steps.install-ndk.outputs.ndk-full-version }}/ndk-build --version"
48
+ if : matrix.os == 'windows-latest'
49
+
44
50
test-multiple :
45
51
runs-on : ubuntu-latest
46
52
strategy :
58
64
- uses : ./
59
65
id : install-ndk-25
60
66
with :
61
- ndk-version : r25b
67
+ ndk-version : r25c
62
68
add-to-path : false
63
69
local-cache : ${{ matrix.local-cache }}
64
70
Original file line number Diff line number Diff line change 1
1
# setup-ndk
2
2
3
- ![ test status] ( https://github.com/nttld/setup-ndk/actions/workflows/test.yml/badge.svg )
4
-
5
- This action sets up an Android NDK environment by downloading and caching a version of the NDK and adding it to the PATH
3
+ This action sets up an Android NDK environment by downloading and caching a version of the NDK and optionally adding it to the PATH and linking it to the Android SDK.
6
4
7
5
## Usage
8
6
@@ -12,18 +10,18 @@ See [action.yml](action.yml)
12
10
13
11
``` yml
14
12
steps :
15
- - uses : actions/checkout@v2
13
+ - uses : actions/checkout@v3
16
14
- uses : nttld/setup-ndk@v1
17
15
with :
18
- ndk-version : r25b
16
+ ndk-version : r25c
19
17
- runs : ndk-build NDK_PROJECT_PATH=. APP_BUILD_SCRIPT=./Android.mk NDK_APPLICATION_MK=./Application.mk
20
18
` ` `
21
19
22
20
### Using the installation path
23
21
24
22
` ` ` yml
25
23
steps :
26
- - uses : actions/checkout@v2
24
+ - uses : actions/checkout@v3
27
25
- uses : nttld/setup-ndk@v1
28
26
id : setup-ndk
29
27
with :
@@ -34,13 +32,26 @@ steps:
34
32
ANDROID_NDK_HOME : ${{ steps.setup-ndk.outputs.ndk-path }}
35
33
` ` `
36
34
37
- ### Caching locally
35
+ ### Linking to the SDK
36
+
37
+ ` ` ` yml
38
+ steps :
39
+ - uses : actions/checkout@v3
40
+ - uses : nttld/setup-ndk@v1
41
+ id : setup-ndk
42
+ with :
43
+ ndk-version : r25c
44
+ link-to-sdk : true
45
+ - run : ./gradlew build
46
+ ` ` `
47
+
48
+ ### Caching locally for the workflow
38
49
39
50
` ` ` yml
40
51
steps :
41
- - uses : actions/checkout@v2
52
+ - uses : actions/checkout@v3
42
53
- uses : nttld/setup-ndk@v1
43
54
with :
44
- ndk-version : r25b
55
+ ndk-version : r21e
45
56
local-cache : true
46
57
` ` `
Original file line number Diff line number Diff line change 1
1
name : Setup Android NDK
2
2
description : Setup an Android NDK environment by downloading and optionally caching it and adding it to the PATH
3
3
author : Raphaël Thériault
4
+ branding :
5
+ icon : play
6
+ color : green
7
+
4
8
inputs :
5
9
ndk-version :
6
10
description : Exact version to use
@@ -9,16 +13,20 @@ inputs:
9
13
description : Add installation directory to the PATH
10
14
required : false
11
15
default : " true"
16
+ link-to-sdk :
17
+ description : Add installed NDK to the Android SDK
18
+ required : false
19
+ default : " false"
12
20
local-cache :
13
21
description : Use the local job cache on top of the runner tool cache
14
22
required : false
15
23
default : " false"
16
24
outputs :
17
25
ndk-path :
18
26
description : Installation path
27
+ ndk-full-version :
28
+ description : Full NDK version
29
+
19
30
runs :
20
31
using : node16
21
32
main : dist/index.js
22
- branding :
23
- icon : play
24
- color : green
You can’t perform that action at this time.
0 commit comments