-
Notifications
You must be signed in to change notification settings - Fork 11
359 lines (359 loc) · 21.7 KB
/
releases-deb.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
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
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
name: Build Artifacts (DEB)
on:
workflow_dispatch:
inputs:
logLevel:
description: 'Log level'
required: true
default: 'warning'
type: choice
options:
- info
- warning
- debug
tags:
description: 'Test scenario tags'
required: false
type: boolean
pull_request:
branches: [master, develop]
paths-ignore:
- '**/*.md'
- '.circleci/**'
- '.cirrus.yml'
push:
branches: [master, develop]
paths-ignore:
- '**/*.md'
- '.circleci/**'
- '.cirrus.yml'
release:
types: [published]
schedule:
- cron: '0 16 * * *'
concurrency:
group: ${{ github.workflow }} / ${{ startsWith(github.event_name, 'pull') && github.ref_name || github.sha }}
cancel-in-progress: ${{ startsWith(github.event_name, 'pull') }}
env:
CACHE_EPOCH: 131-1
GOPROXY: direct
DH_QUIET: 1
jobs:
deb-release:
runs-on: ubuntu-22.04
strategy:
fail-fast: false
matrix:
distro: [xenial]
arch: [amd64, i386]
gui_variant: [gtk3, qt5]
include:
- distro: bionic
arch: arm64
gui_variant: gtk3
- distro: jammy
arch: amd64
gui_variant: gtk4
use_cet: true
- distro: jammy
arch: amd64
gui_variant: qt6
use_cet: true
- distro: trixie
arch: riscv64
gui_variant: none
# XFAIL stretch
# XFAIL focal-i386,jammy-i386,noble-i386
# XFAIL trixie-riscv64 (gui, curl)
# distro: [trusty, xenial, bionic, focal, jammy, noble, stretch, buster, bullseye, bookworm]
# arch: [i386, amd64, armhf, arm64]
# include:
# - distro: stretch
# arch: armel
# - distro: stretch
# arch: mipsel
# - distro: stretch
# arch: mips64el
env:
DEBIAN_FRONTEND: 'noninteractive'
HOST_ARCH: '${{ matrix.arch }}'
HOST_DISTRO: '${{ matrix.distro }}'
steps:
- uses: actions/checkout@v4
- name: Checkout with shallow submodules
run: |
# unshallow must come first otherwise submodule may be get unshallowed
git fetch --tags --unshallow
git submodule update --init --depth 1
- name: Patch libcxxabi for both of armel and armhf
if: ${{ matrix.arch == 'armel' || matrix.arch == 'armhf' }}
run: |
cd third_party/libc++abi
patch -p1 < v8-6.7.17-fix-gcc-unwind-header.patch
- name: Cache toolchain
id: toolchain-cache
uses: actions/cache@v4
with:
path: |
third_party/llvm-build/Release+Asserts
key: ${{ runner.os }}-toolchain-${{ hashFiles('CLANG_REVISION') }}-v${{ env.CACHE_EPOCH }}
- name: "Install dependency: prebuilt clang and clang-tidy binaries"
if: ${{ steps.toolchain-cache.outputs.cache-hit != 'true' }}
run: |
./scripts/download-clang-prebuilt-binaries.py
rm -f third_party/llvm-build/Release+Asserts/*.tgz
- name: Change ubuntu mirror
run: |
sudo sed -i 's/azure.archive.ubuntu.com/azure.archive.ubuntu.com/g' /etc/apt/sources.list
sudo apt-get update -qq
- name: Populate dependencies (debian keyring, for debian distributions)
run: |
curl -O http://ftp.us.debian.org/debian/pool/main/d/debian-archive-keyring/debian-archive-keyring_2023.4_all.deb
sudo apt-get update -qq && sudo apt-get install -f -y $PWD/debian*.deb
rm -f *.deb
- name: Populate dependencies (sbuild, debhelper, schroot, debootstrap and ubuntu-dev-tools)
run: |
sudo apt-get update -qq
sudo apt-get install -y sbuild debhelper schroot debootstrap ubuntu-dev-tools qemu-user-static
- name: Populate dependencies (deboostrap update for trixie fix)
if: ${{ matrix.distro == 'trixie' }}
run: |
curl -L -O http://mirrors.kernel.org/ubuntu/pool/main/d/debootstrap/debootstrap_1.0.132ubuntu1_all.deb
sudo apt-get update -qq && sudo apt-get install -f -y $PWD/debootstrap*.deb
rm -f *.deb
- name: Copy sbuilrc
run: |
cp -fv sbuildrc ~/.sbuildrc
sudo usermod -aG sudo "$USER"
sudo usermod -aG sbuild "$USER"
sudo chown -R sbuild:sbuild /var/lib/sbuild/
sudo chmod g+rws /var/lib/sbuild/
- name: Pre-Populate sysroot (distro option)
if: ${{ matrix.distro == 'stretch' || matrix.distro == 'buster' || matrix.distro == 'bullseye' || matrix.distro == 'bookworm' || matrix.distro == 'trixie' }}
run: |
echo "mksbuild_distro_opts=--distro=debian" >> $GITHUB_ENV
- name: Pre-Populate BUILD_ARCH (i386)
if: ${{ matrix.arch == 'i386' }}
run: |
echo "mksbuild_arch_opts=--arch=i386" >> $GITHUB_ENV
echo "BUILD_ARCH=i386" >> $GITHUB_ENV
- name: Pre-Populate BUILD_ARCH (amd64)
if: ${{ matrix.arch != 'i386' }}
run: |
echo "mksbuild_arch_opts=--arch=amd64" >> $GITHUB_ENV
echo "BUILD_ARCH=$(dpkg-architecture -q DEB_BUILD_ARCH)" >> $GITHUB_ENV
- name: Set check build profile
if: ${{ matrix.arch == 'i386' || matrix.arch == 'amd64' }}
run: |
echo "DEB_BUILD_PROFILES=check ${{ env.DEB_BUILD_PROFILES }}" >> $GITHUB_ENV
- name: Set cross build profile
if: ${{ matrix.arch != 'i386' && matrix.arch != 'amd64' }}
run: |
echo "DEB_BUILD_PROFILES=nocheck cross ${{ env.DEB_BUILD_PROFILES }}" >> $GITHUB_ENV
- name: Set gui build profile (none of armel/mipsel/mips64el and riscv64)
if: ${{ matrix.gui_variant != 'none' }}
run: |
echo "DEB_BUILD_PROFILES=${{ matrix.gui_variant }} ${{ env.DEB_BUILD_PROFILES }}" >> $GITHUB_ENV
echo "APT_DEB_BUILD_PROFILES=-o Apt::Build-Profiles=${{ matrix.gui_variant }}" >> $GITHUB_ENV
- name: Set clang build profile
run: |
echo "DEB_BUILD_PROFILES=clang ${{ env.DEB_BUILD_PROFILES }}" >> $GITHUB_ENV
echo "CC=${{ github.workspace }}/third_party/llvm-build/Release+Asserts/bin/clang" >> $GITHUB_ENV
echo "CXX=${{ github.workspace }}/third_party/llvm-build/Release+Asserts/bin/clang++" >> $GITHUB_ENV
- name: Set cet build profile
if: ${{ matrix.use_cet == true }}
run: |
echo "DEB_BUILD_PROFILES=cet ${{ env.DEB_BUILD_PROFILES }}" >> $GITHUB_ENV
- name: Fix schroot permissions (set store permissions for restore)
run: |
sudo mkdir -p /etc/schroot/chroot.d /var/lib/schroot/chroots
sudo chown -R $USER:sbuild /etc/schroot/chroot.d /var/lib/schroot/chroots
- name: Cache schroot
id: schroot-cache
uses: actions/cache@v4
with:
path: |
/etc/schroot/chroot.d
/var/lib/schroot/chroots
key: ${{ runner.os }}-22.04-schroot-${{ matrix.distro }}-${{ matrix.arch }}-mix-v2
- name: Fix schroot permissions (restore root permissions)
run: |
sudo chown -R root:root /etc/schroot/chroot.d /var/lib/schroot/chroots
# mk-sbuild may fail due to the missing pkg-config-<gnu-type>, but it
# should be fine, will create pkg-config shim in next step
- name: Populate sysroot
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' }}
run: |
sudo -n sudo -u "$USER" -g sbuild mk-sbuild ${{ env.mksbuild_arch_opts }} ${{ matrix.distro }} --target=${{ matrix.arch }} ${{ env.mksbuild_distro_opts }} || true
sudo sed -i '/profile/d' /etc/schroot/chroot.d/*
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get clean
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get update -qq
- name: Populate sysroot (crosscompile toolchain)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' && matrix.arch != 'i386' && matrix.arch != 'amd64' }}
run: |
export HOST_GNU_TYPE=$(dpkg-architecture -a ${{ matrix.arch }} -q DEB_HOST_GNU_TYPE)
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
dpkg --add-architecture ${{ matrix.arch }}
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get update -qq
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get install -y dpkg-cross pkg-config gcc-$HOST_GNU_TYPE g++-$HOST_GNU_TYPE libc6:${{ matrix.arch }} libstdc++6:${{ matrix.arch }} linux-libc-dev:${{ matrix.arch }}
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
ln -sf /usr/share/pkg-config-crosswrapper /usr/bin/${HOST_GNU_TYPE}-pkg-config
- name: Populate sysroot (crosscompile toolchain, for bookworm and later distro)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' && matrix.arch != 'i386' && matrix.arch != 'amd64' }}
run: |
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
bash -c "[ ! -f /usr/share/pkg-config-crosswrapper ] && cp -v $PWD/debian/pkg-config-crosswrapper /usr/share/pkg-config-crosswrapper || :"
- name: Populate sysroot (standard toolchain)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' }}
run: |
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get install -y fakeroot advancecomp apt-utils file build-essential pkg-config debhelper lockfile-progs optipng tzdata ucf
- name: Populate sysroot (amd64 runtime for clang)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' && matrix.arch == 'i386' }}
run: |
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
cp -f /etc/apt/sources.list /etc/apt/sources.list.amd64
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
sed -i s/i386/amd64/g /etc/apt/sources.list.amd64
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
bash -c "cat /etc/apt/sources.list /etc/apt/sources.list.amd64 | tee /tmp/sources.list"
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
mv -f /tmp/sources.list /etc/apt/sources.list
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
dpkg --add-architecture amd64
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get update -qq
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get install -y libc6:amd64 libstdc++6:amd64 zlib1g:amd64
- name: Populate sysroot (ca-certificates, git)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' }}
run: |
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get install -y ca-certificates git
- name: Populate sysroot (golang, new distro)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' && matrix.distro != 'trusty' && matrix.distro != 'xenial' && matrix.distro != 'bionic' && matrix.distro != 'stretch' && matrix.distro != 'buster' && matrix.distro != 'bullseye' }}
run: |
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get install -y golang
- name: Populate sysroot (golang, old distro)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' && (matrix.distro == 'trusty' || matrix.distro == 'xenial' || matrix.distro == 'bionic' || matrix.distro == 'stretch' || matrix.distro == 'buster' || matrix.distro == 'bullseye') }}
run: |
# shipped with debian bullseye
curl -O http://ftp.us.debian.org/debian/pool/main/g/golang-defaults/golang_1.15~1_${{ env.BUILD_ARCH }}.deb
curl -O http://ftp.us.debian.org/debian/pool/main/g/golang-defaults/golang-go_1.15~1_${{ env.BUILD_ARCH }}.deb
curl -O http://ftp.us.debian.org/debian/pool/main/g/golang-defaults/golang-src_1.15~1_${{ env.BUILD_ARCH }}.deb
curl -O http://ftp.us.debian.org/debian/pool/main/g/golang-defaults/golang-doc_1.15~1_all.deb
curl -O http://ftp.us.debian.org/debian/pool/main/g/golang-1.15/golang-1.15_1.15.15-1~deb11u4_all.deb
curl -O http://ftp.us.debian.org/debian/pool/main/g/golang-1.15/golang-1.15-go_1.15.15-1~deb11u4_${{ env.BUILD_ARCH }}.deb
curl -O http://ftp.us.debian.org/debian/pool/main/g/golang-1.15/golang-1.15-src_1.15.15-1~deb11u4_${{ env.BUILD_ARCH }}.deb
curl -O http://ftp.us.debian.org/debian/pool/main/g/golang-1.15/golang-1.15-doc_1.15.15-1~deb11u4_all.deb
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
dpkg --force-depends -i $PWD/*.deb || true
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get install -y -f
rm -f *.deb
- name: Populate dependencie (cmake)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' }}
run: |
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get install -y cmake ninja-build
- name: Populate dependencie (cmake, overwrite)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' }}
run: |
curl -L -O https://github.com/Kitware/CMake/releases/download/v3.29.8/cmake-3.29.8-linux-x86_64.tar.gz
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
tar -C /usr/local --strip-components=1 -xf cmake-3.29.8-linux-x86_64.tar.gz
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
cmake --version
rm -f *.tar.gz
- name: Populate dependencie (base)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' }}
run: |
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get install -y perl gcc g++ ninja-build
- name: Populate dependencie (zlib)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' }}
run: |
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get install -y zlib1g-dev:${{ matrix.arch }}
- name: Populate dependencie (qt6, x86 only, jammy only)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' && (matrix.arch == 'i386' || matrix.arch == 'amd64') && matrix.distro == 'jammy' }}
run: |
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get -o DPkg::Options::="--force-confnew" install -y qt6-base-dev:${{ matrix.arch }}
- name: Populate dependencie (qt5, x86 only)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' && (matrix.arch == 'i386' || matrix.arch == 'amd64') }}
run: |
export HOST_GNU_TYPE=$(dpkg-architecture -a ${{ matrix.arch }} -q DEB_HOST_GNU_TYPE)
# DEB_HOST_GNU_TYPE produces i686-linux-gnu which is wrong
[ "${{ matrix.arch }}" = "i386" ] && export HOST_GNU_TYPE=i386-linux-gnu
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get -o DPkg::Options::="--force-confnew" install -y qtbase5-dev:${{ matrix.arch }}
# for qt 5.5 or before
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
sed -i 's#Q_DECL_CONSTEXPR inline QFlags(Zero = 0) Q_DECL_NOTHROW : i(0) {}#Q_DECL_CONSTEXPR inline QFlags() Q_DECL_NOTHROW : i(0) {}\n Q_DECL_CONSTEXPR inline QFlags(Zero) Q_DECL_NOTHROW : i(0) {}#g' /usr/include/$HOST_GNU_TYPE/qt5/QtCore/qflags.h
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
bash -c "sed -i 's#Qt::WindowFlags f = 0#Qt::WindowFlags f = {}#g' /usr/include/$HOST_GNU_TYPE/qt5/QtWidgets/*.h"
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
bash -c "sed -i 's#Qt::Alignment = 0#Qt::Alignment = {}#g' /usr/include/$HOST_GNU_TYPE/qt5/QtWidgets/*.h"
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
bash -c "sed -i 's#Qt::Alignment alignment = 0#Qt::Alignment alignment = {}#g' /usr/include/$HOST_GNU_TYPE/qt5/QtWidgets/*.h"
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
bash -c "sed -i 's#Qt::WindowFlags f=0#Qt::WindowFlags f = {}#g' /usr/include/$HOST_GNU_TYPE/qt5/QtWidgets/*.h"
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
bash -c "sed -i 's#Qt::WindowFlags flags = 0#Qt::WindowFlags flags = {}#g' /usr/include/$HOST_GNU_TYPE/qt5/QtWidgets/*.h"
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
bash -c "sed -i 's#Qt::WindowFlags flags=0#Qt::WindowFlags flags = {}#g' /usr/include/$HOST_GNU_TYPE/qt5/QtWidgets/*.h"
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
bash -c "sed -i 's#Qt::ItemFlags(0)#Qt::ItemFlags()#g' /usr/include/$HOST_GNU_TYPE/qt5/QtCore/*.h"
# for qt 5.6 or before
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
sed -i 's#Q_DECL_CONSTEXPR inline QFlags(Zero = Q_NULLPTR) Q_DECL_NOTHROW : i(0) {}#Q_DECL_CONSTEXPR inline QFlags() Q_DECL_NOTHROW : i(0) {}\n Q_DECL_CONSTEXPR inline QFlags(Zero) Q_DECL_NOTHROW : i(0) {}#g' /usr/include/$HOST_GNU_TYPE/qt5/QtCore/qflags.h
# fix clang after 3847
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
sed -i 's#: integral_constant<bool, (T(0) < T(-1))> {};#: integral_constant<bool, __is_unsigned(T)> {};#g' /usr/include/$HOST_GNU_TYPE/qt5/QtCore/qtypetraits.h
- name: Populate dependencie (gtk4, jammy only)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' && matrix.arch != 'armel' && matrix.arch != 'mipsel' && matrix.arch != 'mips64el' && matrix.arch != 'riscv64' && matrix.distro == 'jammy' }}
run: |
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get -o DPkg::Options::="--force-confnew" install -y libglib2.0-dev:${{ matrix.arch }} libgtk-4-dev:${{ matrix.arch }}
- name: Populate dependencie (gtk3, none of armel/mipsel/mips64el and riscv64)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' && matrix.arch != 'armel' && matrix.arch != 'mipsel' && matrix.arch != 'mips64el' && matrix.arch != 'riscv64' }}
run: |
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get -o DPkg::Options::="--force-confnew" install -y libglib2.0-dev:${{ matrix.arch }} libgtk-3-dev:${{ matrix.arch }}
- name: Populate dependencie (curl, for test purpose, exclude some arches)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' && matrix.arch != 'armel' && matrix.arch != 'mipsel' && matrix.arch != 'mips64el' && matrix.arch != 'riscv64' }}
run: |
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt-get install -y libcurl4-openssl-dev:${{ matrix.arch }}
- name: Populate dependencie (list upgradable packages)
run: |
sudo schroot --chroot "source:${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}" --user root -- \
apt list --upgradeable || true
- name: Build deb package
run: |
export DEB_BUILD_PROFILES
export DH_QUIET
sudo -E sudo -E -u "$USER" -g sbuild ./scripts/build-deb.sh
- name: Upload dist tarball (including debuginfo)
if: ${{ github.event_name == 'release' }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
gh release upload --clobber ${{ github.event.release.tag_name }} yass*.deb
- name: Shutdown schroot sessions
run: |
sudo schroot --end-session --all-sessions
- name: Fix schroot dev nodes permissions
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' }}
run: |
sudo rm -rf /var/lib/schroot/chroots/${{ matrix.distro }}-${{ env.BUILD_ARCH }}-${{ matrix.arch }}/dev
- name: Fix schroot permissions (restore store permissions)
if: ${{ steps.schroot-cache.outputs.cache-hit != 'true' }}
run: |
sudo chown -R $USER /etc/schroot/chroot.d /var/lib/schroot/chroots