File tree 1 file changed +28
-9
lines changed
1 file changed +28
-9
lines changed Original file line number Diff line number Diff line change @@ -2,12 +2,14 @@ name: NDK build
2
2
3
3
on :
4
4
push :
5
- branches : [ main ]
5
+ branches : [ main, dev ]
6
6
pull_request :
7
- branches : [ main ]
7
+ branches : [ main, dev ]
8
8
9
9
jobs :
10
10
build :
11
+ env :
12
+ module_id : clockmod
11
13
runs-on : ubuntu-latest
12
14
13
15
steps :
@@ -18,15 +20,32 @@ jobs:
18
20
lfs : true
19
21
- name : Install Powershell
20
22
run : sudo apt-get install -y powershell
21
-
22
- - name : Setup NDK
23
- id : setup-ndk
24
-
23
+
24
+ - name : Cache Android NDK
25
+ id : cache-ndk
26
+ uses : actions/cache@v2
27
+ env :
28
+ cache-name : cache-ndk
29
+ ndkname : android-ndk-r21
25
30
with :
26
- ndk-version : r21
31
+ path : ndk
32
+ key : ${{ runner.os }}-${{ env.cache-name }}-${{ env.ndkname }}
33
+ restore-keys : |
34
+ ${{ runner.os }}-${{ env.cache-name }}-${{ env.ndkname }}
35
+
36
+ - name : Install Android NDK
37
+ if : steps.cache-ndk.outputs.cache-hit != 'true'
38
+ env :
39
+ ndkname : android-ndk-r21
40
+ run : |
41
+ wget -q -O ndk.zip https://dl.google.com/android/repository/${ndkname}-linux-x86_64.zip
42
+ unzip -q ndk.zip
43
+ mv ${ndkname} ndk
27
44
28
45
- name : Create ndkpath.txt
29
- run : echo ${{ steps.setup-ndk.outputs.ndk-path }} > ${GITHUB_WORKSPACE}/ndkpath.txt
46
+ run : |
47
+ cd ndk
48
+ pwd > ${GITHUB_WORKSPACE}/ndkpath.txt
30
49
31
50
# - name: Cache QPM
32
51
# id: cache-qpm
76
95
id : libname
77
96
run : |
78
97
cd ./libs/arm64-v8a/
79
- pattern="libclockmod .so"
98
+ pattern="lib${module_id}* .so"
80
99
files=( $pattern )
81
100
echo ::set-output name=NAME::"${files[0]}"
82
101
- name : Upload non-debug artifact
You can’t perform that action at this time.
0 commit comments