forked from vgorloff/swift-everywhere-toolchain
-
Notifications
You must be signed in to change notification settings - Fork 1
69 lines (55 loc) · 1.81 KB
/
build-toolchain-mac.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
name: Build toochain for Android
on: [workflow_dispatch]
env:
NDK_VERSION: 21.4.7075529
jobs:
build:
name: Swift toolchain for Android
runs-on: macOS-12
timeout-minutes: 600
steps:
- uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: '13.3.1'
- uses: actions/checkout@master
- uses: nttld/setup-ndk@v1
with:
ndk-version: r25b
- name: Download dependencies
run: |
brew update
brew install cmake ninja autoconf automake libtool pkg-config git-lfs wget
- name: Setup NDK
run: |
wget -q https://dl.google.com/android/repository/android-ndk-r21e-darwin-x86_64.zip
unzip -qq android-ndk-r21e-darwin-x86_64.zip -d ./$NDK_VERSION
rm -rf android-ndk-r21e-darwin-x86_64.zip
sudo mkdir -p /usr/local/ndk
sudo ln -vsif ${GITHUB_WORKSPACE}/$NDK_VERSION/android-ndk-r21e /usr/local/ndk/$NDK_VERSION
echo $(ls /usr/local/ndk/$NDK_VERSION)
echo $(ls /Users/runner/Library/Android/sdk/ndk/)
echo $(ls /Users/runner/Library/Android/sdk/ndk/25.1.8937393)
- name: Init Caching
uses: ./.github/actions/cache-always
with:
key: swift-android-toolchain-cache
path: |
./ToolChain
- name: Check before build
run: |
which cmake
which ninja
which autoconf
which aclocal
which glibtool
which pkg-config
which git-lfs
xcode-select --print-path
- name: Build
run: |
node main.js bootstrap
- name: Archiving
uses: actions/upload-artifact@v3
with:
name: Toolchain build archive
path: ./ToolChain/swift-android-toolchain.tar.gz