-
Notifications
You must be signed in to change notification settings - Fork 367
75 lines (75 loc) · 2 KB
/
android.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
name: Android
on:
# push代码时触发workflow
push:
paths:
- '3rdparty/**'
- 'examples/**'
- 'mkspecs/**'
- 'src/**'
- '.qmake.conf'
- 'TaoQuick.pro'
- '.github/workflows/android.yml'
# pull_request时触发workflow
pull_request:
paths:
- '3rdparty/**'
- 'examples/**'
- 'mkspecs/**'
- 'src/**'
- '.qmake.conf'
- 'TaoQuick.pro'
- '.github/workflows/android.yml'
jobs:
build:
name: Build
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- qt_ver: 5.12.10
qt_arch: android_x86
os: ubuntu-20.04
qt_target: android
- qt_ver: 5.12.10
qt_arch: android_armv7
os: ubuntu-20.04
qt_target: android
- qt_ver: 5.12.10
qt_arch: android_arm64_v8a
os: ubuntu-20.04
qt_target: android
- qt_ver: 5.15.2
# here no qt_arch, use default
os: ubuntu-20.04
qt_target: android
steps:
- name: Install Qt
uses: jurplel/install-qt-action@v2
if: ${{ matrix.qt_ver == '5.12.10' }}
with:
version: ${{ matrix.qt_ver }}
target: ${{ matrix.qt_target }}
arch: ${{ matrix.qt_arch }}
- name: Install Qt
uses: jurplel/install-qt-action@v2
if: ${{ matrix.qt_ver == '5.15.2' }}
with:
version: ${{ matrix.qt_ver }}
target: ${{ matrix.qt_target }}
# here need not arch
# arch: ${{ matrix.qt_arch }}
- uses: actions/checkout@v2
with:
fetch-depth: 1
submodules: 'true'
- name: build android
run: |
if test -z "$ANDROID_SDK_ROOT";then
export ANDROID_SDK_ROOT=$ANDROID_HOME
fi
if test -z "$ANDROID_NDK_ROOT";then
export ANDROID_NDK_ROOT=$ANDROID_NDK_HOME
fi
qmake
make