-
Notifications
You must be signed in to change notification settings - Fork 670
272 lines (260 loc) · 8.27 KB
/
build.yml
File metadata and controls
272 lines (260 loc) · 8.27 KB
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
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
name: Build
on:
workflow_dispatch:
push:
branches:
- main
- release/*
pull_request:
branches:
- main
- release/*
concurrency:
# Cancel any workflow currently in progress for the same PR.
# Allow running concurrently with any other commits.
group: build-${{ github.event.pull_request.number || github.sha }}
cancel-in-progress: true
permissions:
contents: read
jobs:
build-windows:
name: WinUser
needs: []
strategy:
fail-fast: false
matrix:
config: ['Debug', 'Release']
plat: [windows, uwp] # TODO: Support gamecore_console
os: ['windows-2022']
arch: [x86, x64, arm64]
tls: [schannel, quictls, openssl]
static: ['', '-Static']
exclude:
# OpenSSL/quictls doesn't support arm64
- tls: quictls
arch: arm64
- plat: uwp
tls: openssl
# TODO: FIX: OpenSSL/quictls build fails with UWP
- plat: uwp
tls: quictls
# TODO: FIX: Static builds fail with UWP
- plat: uwp
static: '-Static'
uses: ./.github/workflows/build-reuse-win.yml
with:
config: ${{ matrix.config }}
plat: ${{ matrix.plat }}
os: ${{ matrix.os }}
arch: ${{ matrix.arch }}
tls: ${{ matrix.tls }}
static: ${{ matrix.static }}
repo: ${{ github.repository }}
build-windows-official:
name: WinUser-Official
needs: []
strategy:
fail-fast: false
matrix:
config: ['Debug', 'Release']
uses: ./.github/workflows/build-reuse-win.yml
with:
config: ${{ matrix.config }}
plat: 'windows'
os: 'windows-2022'
arch: 'x64'
tls: 'schannel'
official: '-ForceOfficialRelease'
repo: ${{ github.repository }}
build-windows-kernel:
name: WinKernel
needs: []
strategy:
fail-fast: false
matrix:
config: ['Debug', 'Release']
plat: [winkernel]
os: ['windows-2022']
arch: [x64, arm64]
tls: [schannel]
uses: ./.github/workflows/build-reuse-winkernel.yml
with:
config: ${{ matrix.config }}
plat: ${{ matrix.plat }}
os: ${{ matrix.os }}
arch: ${{ matrix.arch }}
tls: ${{ matrix.tls }}
repo: ${{ github.repository }}
build-ubuntu-cross-compile:
name: UbuntuArm
needs: []
strategy:
fail-fast: false
matrix:
config: ['Debug', 'Release']
plat: [android, linux]
os: ['ubuntu-22.04', 'ubuntu-24.04']
arch: [arm, arm64]
tls: [quictls, openssl]
static: ['', '-Static']
uses: ./.github/workflows/build-reuse-unix.yml
with:
config: ${{ matrix.config }}
plat: ${{ matrix.plat }}
os: ${{ matrix.os }}
arch: ${{ matrix.arch }}
tls: ${{ matrix.tls }}
static: ${{ matrix.static }}
repo: ${{ github.repository }}
build-ubuntu:
name: Ubuntu
needs: []
strategy:
fail-fast: false
matrix:
config: ['Debug', 'Release']
plat: [linux, android]
os: ['ubuntu-22.04', 'ubuntu-24.04']
arch: [x86, x64]
tls: [quictls, openssl]
systemcrypto: ['', '-UseSystemOpenSSLCrypto']
static: ['', '-Static']
clang: ['', '-Clang']
codecheck: ['', '-CodeCheck']
iouring: ['', '-UseIoUring']
exclude:
# Android doesn't support x86, Clang, CodeCheck or SystemCrypto
- plat: android
arch: x86
- plat: android
systemcrypto: '-UseSystemOpenSSLCrypto'
# No openssl system crypto on ubuntu-22.04
- os: 'ubuntu-22.04'
tls: 'quictls'
systemcrypto: '-UseSystemOpenSSLCrypto'
# No openssl system crypto on ubuntu-24.04
- os: 'ubuntu-24.04'
tls: 'quictls'
systemcrypto: '-UseSystemOpenSSLCrypto'
# No openssl system crypto on ubuntu-22.04
- os: 'ubuntu-22.04'
tls: 'openssl'
systemcrypto: '-UseSystemOpenSSLCrypto'
# No openssl system crypto on ubuntu-24.04
- os: 'ubuntu-24.04'
tls: 'openssl'
systemcrypto: '-UseSystemOpenSSLCrypto'
- plat: android
clang: '-Clang'
- plat: android
codecheck: '-CodeCheck'
# linux io_uring is for ubuntu24.04 only for now
- plat: android
iouring: "-UseIoUring"
# CodeCheck doesn't work with SystemCrypto, Clang, Static or Release builds
- codecheck: '-CodeCheck'
systemcrypto: '-UseSystemOpenSSLCrypto'
- codecheck: '-CodeCheck'
clang: '-Clang'
- codecheck: '-CodeCheck'
static: '-Static'
- codecheck: '-CodeCheck'
config: Release
# Static build can't dynamically link to libcrypto
- static: '-Static'
systemcrypto: '-UseSystemOpenSSLCrypto'
# No openssl system crypto on ubuntu 22.04 or 24.04
- os: 'ubuntu-22.04'
systemcrypto: '-UseSystemOpenSSLCrypto'
- os: 'ubuntu-24.04'
systemcrypto: '-UseSystemOpenSSLCrypto'
# Linux io_uring is for x64 ubuntu24.04 only for now
- iouring: "-UseIoUring"
os: 'ubuntu-22.04'
- iouring: "-UseIoUring"
arch: x86
uses: ./.github/workflows/build-reuse-unix.yml
with:
config: ${{ matrix.config }}
plat: ${{ matrix.plat }}
os: ${{ matrix.os }}
arch: ${{ matrix.arch }}
tls: ${{ matrix.tls }}
systemcrypto: ${{ matrix.systemcrypto }}
static: ${{ matrix.static }}
clang: ${{ matrix.clang }}
codecheck: ${{ matrix.codecheck }}
iouring: ${{ matrix.iouring }}
repo: ${{ github.repository }}
build-darwin:
name: MacOs
needs: []
strategy:
fail-fast: false
matrix:
config: ['Debug', 'Release']
plat: [macos, ios]
os: ['macos-15']
arch: [x64, arm64]
tls: [quictls, openssl]
static: ['', '-Static']
uses: ./.github/workflows/build-reuse-unix.yml
with:
config: ${{ matrix.config }}
plat: ${{ matrix.plat }}
os: ${{ matrix.os }}
arch: ${{ matrix.arch }}
tls: ${{ matrix.tls }}
static: ${{ matrix.static }}
repo: ${{ github.repository }}
build-nuget:
name: Build Nuget Package
needs: [build-windows]
strategy:
fail-fast: false
matrix:
vec: [
#{ plat: "uwp", tls: "quictls", arg: "-UWP" }, # TODO: Fix build first
{ plat: "windows", tls: "quictls" },
{ plat: "windows", tls: "openssl" },
{ plat: "windows", tls: "schannel" },
]
runs-on: windows-2022
steps:
- name: Checkout repository
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd
- name: Download Build Artifacts
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c
with:
name: Release-${{ matrix.vec.plat }}-windows-2022-x86-${{ matrix.vec.tls }}
path: artifacts
- name: Download Build Artifacts
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c
with:
name: Release-${{ matrix.vec.plat }}-windows-2022-x64-${{ matrix.vec.tls }}
path: artifacts
- name: Download Build Artifacts
uses: actions/download-artifact@3e5f45b2cfb9172054b4087a40e8e0b5a5461e7c
if: matrix.vec.tls != 'quictls' # TODO: Remove once quictls is supported
with:
name: Release-${{ matrix.vec.plat }}-windows-2022-arm64-${{ matrix.vec.tls }}
path: artifacts
- name: Build Package
shell: pwsh
run: scripts/package-nuget.ps1 -Tls ${{ matrix.vec.tls }} ${{ matrix.vec.arg }} -GHA
- name: Upload build artifacts
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a
with:
name: Nuget-Release-${{ matrix.vec.plat }}-windows-2022-${{ matrix.vec.tls }}
path: artifacts/dist/*.nupkg
Complete:
name: Build Complete
if: always()
needs: [build-windows, build-windows-official, build-windows-kernel, build-ubuntu-cross-compile, build-ubuntu, build-darwin, build-nuget]
runs-on: ubuntu-latest
permissions: {} # No need for any permissions.
steps:
- name: Decide whether the needed jobs succeeded or failed
uses: re-actors/alls-green@05ac9388f0aebcb5727afa17fcccfecd6f8ec5fe
with:
jobs: ${{ toJSON(needs) }}