Skip to content

Commit aa727f5

Browse files
committed
[ci][linux] build client and manager for arm64
Signed-off-by: Vitalii Koshura <[email protected]>
1 parent bb300e7 commit aa727f5

11 files changed

+331
-88
lines changed

.github/workflows/linux.yml

Lines changed: 64 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,28 @@ jobs:
4040
runs-on: ubuntu-latest
4141
strategy:
4242
matrix:
43-
type: [libs, client, apps, manager, libs-vcpkg, client-vcpkg, apps-vcpkg, libs-cmake, libs-arm64, apps-arm64, libs-vcpkg-arm64, apps-vcpkg-arm64, manager-with-webview-vcpkg, server, manager-with-webview, manager-without-webview, unit-test, integration-test, coverity]
43+
type:
44+
- apps
45+
- apps-arm64
46+
- apps-vcpkg
47+
- apps-vcpkg-arm64
48+
- client
49+
- client-vcpkg
50+
- client-vcpkg-arm64
51+
- coverity
52+
- integration-test
53+
- libs
54+
- libs-arm64
55+
- libs-cmake
56+
- libs-vcpkg
57+
- libs-vcpkg-arm64
58+
- manager
59+
- manager-with-webview
60+
- manager-with-webview-vcpkg
61+
- manager-with-webview-vcpkg-arm64
62+
- manager-without-webview
63+
- server
64+
- unit-test
4465
fail-fast: false
4566
steps:
4667
- uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8
@@ -110,6 +131,19 @@ jobs:
110131
libssl-dev:arm64 \
111132
libzip-dev:arm64
112133
134+
- name: Install dependencies for client and manager arm64 vcpkg
135+
if: success() && matrix.type == 'manager-with-webview-vcpkg-arm64'
136+
run: |
137+
sudo apt install -y \
138+
libx11-dev:arm64 \
139+
libxft-dev:arm64 \
140+
libxext-dev:arm64 \
141+
libdbus-1-dev:arm64 \
142+
libxi-dev:arm64 \
143+
libxtst-dev:arm64 \
144+
libxrandr-dev:arm64 \
145+
libx11-xcb-dev:arm64
146+
113147
- name: Install dependencies for unit testing
114148
if: success() && matrix.type == 'unit-test'
115149
run: |
@@ -148,43 +182,43 @@ jobs:
148182
if: success() && matrix.type == 'libs'
149183
run: |
150184
./configure --disable-server --disable-client --disable-manager --enable-boinczip
151-
make
185+
make -j $(nproc --all)
152186
153187
- name: Build client
154188
if: success() && matrix.type == 'client'
155189
run: |
156190
./configure --disable-server --enable-client --disable-manager
157-
make
191+
make -j $(nproc --all)
158192
159193
- name: Build apps
160194
if: success() && matrix.type == 'apps'
161195
run: |
162196
./configure --enable-apps --enable-apps-vbox --enable-apps-gui --disable-server --disable-client --disable-manager
163-
make
197+
make -j $(nproc --all)
164198
165199
- name: Build manager
166200
if: success() && matrix.type == 'manager'
167201
run: |
168202
./configure --disable-server --disable-client --enable-manager
169-
make
203+
make -j $(nproc --all)
170204
171205
- name: Build libs with vcpkg
172206
if: success() && matrix.type == 'libs-vcpkg'
173207
run: |
174208
linux/ci_configure_libs.sh
175-
make
209+
make -j $(nproc --all)
176210
177211
- name: Build client with vcpkg
178212
if: success() && matrix.type == 'client-vcpkg'
179213
run: |
180214
linux/ci_configure_client.sh
181-
make
215+
make -j $(nproc --all)
182216
183217
- name: Build apps with vcpkg
184218
if: success() && matrix.type == 'apps-vcpkg'
185219
run: |
186220
linux/ci_configure_apps.sh
187-
make
221+
make -j $(nproc --all)
188222
189223
- name: Build libs with cmake vcpkg
190224
if: success() && matrix.type == 'libs-cmake'
@@ -196,7 +230,7 @@ jobs:
196230
if: success() && matrix.type == 'manager-with-webview-vcpkg'
197231
run: |
198232
linux/ci_configure_manager.sh
199-
make
233+
make -j $(nproc --all)
200234
201235
- name: Build server
202236
if: success() && matrix.type == 'server'
@@ -209,14 +243,14 @@ jobs:
209243
run: |
210244
./3rdParty/buildLinuxDependencies.sh
211245
./configure --disable-server --disable-client --with-wx-prefix=${GITHUB_WORKSPACE}/3rdParty/buildCache/linux
212-
make
246+
make -j $(nproc --all)
213247
214248
- name: Build manager without webview
215249
if: success() && matrix.type == 'manager-without-webview'
216250
run: |
217251
./3rdParty/buildLinuxDependencies.sh --disable-webview
218252
./configure --disable-server --disable-client --with-wx-prefix=${GITHUB_WORKSPACE}/3rdParty/buildCache/linux
219-
make
253+
make -j $(nproc --all)
220254
221255
- name: Build server for unit testing
222256
if: success() && matrix.type == 'unit-test'
@@ -227,26 +261,26 @@ jobs:
227261
- name: Build libraries for arm64 with vcpkg
228262
if: success() && matrix.type == 'libs-vcpkg-arm64'
229263
run: |
230-
export CC=aarch64-linux-gnu-gcc
231-
export CXX=aarch64-linux-gnu-g++
232-
BUILD_DIR="$PWD/3rdParty/linux"
233-
VCPKG_ROOT="$BUILD_DIR/vcpkg"
234-
export VCPKG_DIR="$VCPKG_ROOT/installed/arm64-linux-release"
235-
export CPPFLAGS="-I$VCPKG_DIR/include -I$VCPKG_DIR/include/"
236264
./linux/arm64/ci_configure_libs.sh
237-
make
265+
make -j $(nproc --all)
238266
239267
- name: Build apps for arm64 with vcpkg
240268
if: success() && matrix.type == 'apps-vcpkg-arm64'
241269
run: |
242-
export CC=aarch64-linux-gnu-gcc
243-
export CXX=aarch64-linux-gnu-g++
244-
BUILD_DIR="$PWD/3rdParty/linux"
245-
VCPKG_ROOT="$BUILD_DIR/vcpkg"
246-
export VCPKG_DIR="$VCPKG_ROOT/installed/arm64-linux-release"
247-
export CPPFLAGS="-I$VCPKG_DIR/include -I$VCPKG_DIR/include/"
248270
./linux/arm64/ci_configure_apps.sh
249-
make
271+
make -j $(nproc --all)
272+
273+
- name: Build client for arm64 with vcpkg
274+
if: success() && matrix.type == 'client-vcpkg-arm64'
275+
run: |
276+
./linux/arm64/ci_configure_client.sh
277+
make -j $(nproc --all)
278+
279+
- name: Build manager with webview for arm64 with vcpkg
280+
if: success() && matrix.type == 'manager-with-webview-vcpkg-arm64'
281+
run: |
282+
./linux/arm64/ci_configure_manager.sh
283+
make -j $(nproc --all)
250284
251285
- name: Build libraries for arm64
252286
if: success() && matrix.type == 'libs-arm64'
@@ -260,7 +294,7 @@ jobs:
260294
export RELEASE_ARCH=arm64
261295
export PKG_CONFIG_LIBDIR=/usr/lib/aarch64-linux-gnu/pkgconfig:/usr/share/pkgconfig
262296
./configure --host=aarch64-linux --with-boinc-platform="aarch64-unknown-linux-gnu" --with-boinc-alt-platform="arm-unknown-linux-gnueabihf" --enable-boinczip --disable-server --disable-manager --disable-client --disable-shared --enable-static
263-
make
297+
make -j $(nproc --all)
264298
265299
- name: Build apps for arm64
266300
if: success() && matrix.type == 'apps-arm64'
@@ -274,7 +308,7 @@ jobs:
274308
export RELEASE_ARCH=arm64
275309
export PKG_CONFIG_LIBDIR=/usr/lib/aarch64-linux-gnu/pkgconfig:/usr/share/pkgconfig
276310
./configure --host=aarch64-linux --with-boinc-platform="aarch64-unknown-linux-gnu" --with-boinc-alt-platform="arm-unknown-linux-gnueabihf" --enable-apps --disable-server --disable-manager --disable-client --disable-shared --enable-static
277-
make
311+
make -j $(nproc --all)
278312
279313
- name: Prepare for coverity scan
280314
if: success() && matrix.type == 'coverity' && github.ref == 'refs/heads/master' && github.event_name == 'schedule'
@@ -392,7 +426,7 @@ jobs:
392426
export LDFLAGS="-static-libstdc++ -s"
393427
export RELEASE_ARCH=x86_64
394428
./configure --enable-apps --enable-apps-vbox --disable-server --disable-client --disable-manager --disable-shared --enable-static
395-
make
429+
make -j $(nproc --all)
396430
397431
- name: Make x86 apps
398432
if: success() && matrix.type == 'apps-x86'
@@ -402,7 +436,7 @@ jobs:
402436
export LDFLAGS="-static-libstdc++ -s -m32"
403437
export RELEASE_ARCH=i686
404438
./configure --host=i686-linux-gnu --enable-apps --enable-apps-vbox --disable-server --disable-client --disable-manager --disable-shared --enable-static
405-
make
439+
make -j $(nproc --all)
406440
407441
- name: Make arm64 apps
408442
if: success() && matrix.type == 'apps-arm64'
@@ -416,7 +450,7 @@ jobs:
416450
export RELEASE_ARCH=arm64
417451
export PKG_CONFIG_LIBDIR=/usr/lib/aarch64-linux-gnu/pkgconfig:/usr/share/pkgconfig
418452
./configure --host=aarch64-linux --with-boinc-platform="aarch64-unknown-linux-gnu" --with-boinc-alt-platform="arm-unknown-linux-gnueabihf" --enable-apps --disable-server --disable-manager --disable-client --disable-shared --enable-static
419-
make
453+
make -j $(nproc --all)
420454
421455
- name: Prepare logs on failure
422456
if: ${{ failure() }}

deploy/prepare_deployment.py

Lines changed: 17 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -300,6 +300,9 @@ def prepare_linux_client(target_directory):
300300
def prepare_linux_client_vcpkg(target_directory):
301301
prepare_7z_archive('linux_client-vcpkg', target_directory, linux_client_list)
302302

303+
def prepare_linux_client_vcpkg_arm64(target_directory):
304+
prepare_7z_archive('linux_client-vcpkg-arm64', target_directory, linux_client_list)
305+
303306
def prepare_linux_apps(target_directory):
304307
prepare_7z_archive('linux_apps', target_directory, linux_apps_list)
305308

@@ -321,6 +324,9 @@ def prepare_linux_manager_with_webview(target_directory):
321324
def prepare_linux_manager_with_webview_vcpkg(target_directory):
322325
prepare_7z_archive('linux_manager-with-webview-vcpkg', target_directory, linux_manager_list)
323326

327+
def prepare_linux_manager_with_webview_vcpkg_arm64(target_directory):
328+
prepare_7z_archive('linux_manager-with-webview-vcpkg-arm64', target_directory, linux_manager_list)
329+
324330
def prepare_linux_manager_without_webview(target_directory):
325331
prepare_7z_archive('linux_manager-without-webview', target_directory, linux_manager_list)
326332

@@ -358,26 +364,28 @@ def prepare_logs(target_directory):
358364
prepare_7z_archive('logs', target_directory, logs_list)
359365

360366
boinc_types = {
361-
'linux_client': prepare_linux_client,
362-
'linux_client-vcpkg': prepare_linux_client_vcpkg,
367+
'android_apps': prepare_android_apps,
363368
'linux_apps': prepare_linux_apps,
364369
'linux_apps-arm64': prepare_linux_apps_arm64,
365-
'linux_apps-vcpkg-arm64': prepare_linux_apps_vcpkg_arm64,
366370
'linux_apps-vcpkg': prepare_linux_apps_vcpkg,
371+
'linux_apps-vcpkg-arm64': prepare_linux_apps_vcpkg_arm64,
372+
'linux_client': prepare_linux_client,
373+
'linux_client-vcpkg': prepare_linux_client_vcpkg,
374+
'linux_client-vcpkg-arm64': prepare_linux_client_vcpkg_arm64,
367375
'linux_manager': prepare_linux_manager,
368376
'linux_manager-with-webview': prepare_linux_manager_with_webview,
369377
'linux_manager-with-webview-vcpkg': prepare_linux_manager_with_webview_vcpkg,
378+
'linux_manager-with-webview-vcpkg-arm64': prepare_linux_manager_with_webview_vcpkg_arm64,
370379
'linux_manager-without-webview': prepare_linux_manager_without_webview,
380+
'logs': prepare_logs,
381+
'macos_manager': prepare_macos_apps,
382+
'macos_samples-makefile': prepare_macos_makefile_apps,
383+
'win_apps': prepare_win_apps,
371384
'win_apps-mingw': prepare_win_apps_mingw,
372385
'win_apps-mingw-vcpkg': prepare_win_apps_mingw_vcpkg,
373-
'android_apps': prepare_android_apps,
374-
'win_apps': prepare_win_apps,
375386
'win_client': prepare_win_client,
376-
'win_manager': prepare_win_manager,
377387
'win_installer': prepare_win_installer,
378-
'macos_manager': prepare_macos_apps,
379-
'macos_samples-makefile': prepare_macos_makefile_apps,
380-
'logs': prepare_logs,
388+
'win_manager': prepare_win_manager,
381389
}
382390

383391
if (len(sys.argv) != 2):

linux/arm64/ci_configure_apps.sh

Lines changed: 31 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,23 @@
1+
#!/bin/sh
2+
3+
# This file is part of BOINC.
4+
# https://boinc.berkeley.edu
5+
# Copyright (C) 2025 University of California
6+
#
7+
# BOINC is free software; you can redistribute it and/or modify it
8+
# under the terms of the GNU Lesser General Public License
9+
# as published by the Free Software Foundation,
10+
# either version 3 of the License, or (at your option) any later version.
11+
#
12+
# BOINC is distributed in the hope that it will be useful,
13+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
14+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
15+
# See the GNU Lesser General Public License for more details.
16+
#
17+
# You should have received a copy of the GNU Lesser General Public License
18+
# along with BOINC. If not, see <http://www.gnu.org/licenses/>.
19+
#
20+
121
#!/bin/sh
222
set -e
323

@@ -6,12 +26,21 @@ if [ ! -d "linux" ]; then
626
exit 1
727
fi
828

29+
TRIPLET="arm64-linux-release"
30+
931
BUILD_DIR="$PWD/3rdParty/linux"
1032
VCPKG_ROOT="$BUILD_DIR/vcpkg"
11-
export VCPKG_DIR="$VCPKG_ROOT/installed/arm64-linux-release"
33+
export VCPKG_DIR="$VCPKG_ROOT/installed/$TRIPLET"
1234

13-
linux/arm64/update_vcpkg_apps.sh
35+
linux/update_vcpkg_apps.sh $TRIPLET
1436

37+
export CC=aarch64-linux-gnu-gcc
38+
export CXX=aarch64-linux-gnu-g++
39+
export LD=aarch64-linux-gnu-ld
40+
export CFLAGS="-march=armv8-a -O3"
41+
export CXXFLAGS="-march=armv8-a -O3 -std=c++11"
42+
export CPPFLAGS="-I$VCPKG_DIR/include -I$VCPKG_DIR/include/"
43+
export LDFLAGS="-march=armv8-a -static-libstdc++ -s"
1544
export _libcurl_pc="$VCPKG_DIR/lib/pkgconfig/libcurl.pc"
1645
export PKG_CONFIG_PATH=$VCPKG_DIR/lib/pkgconfig/
1746
export X_EXTRA_LIBS="-I$VCPKG_DIR/include $(pkg-config --libs freeglut)"

linux/arm64/ci_configure_client.sh

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
#!/bin/sh
2+
3+
# This file is part of BOINC.
4+
# https://boinc.berkeley.edu
5+
# Copyright (C) 2025 University of California
6+
#
7+
# BOINC is free software; you can redistribute it and/or modify it
8+
# under the terms of the GNU Lesser General Public License
9+
# as published by the Free Software Foundation,
10+
# either version 3 of the License, or (at your option) any later version.
11+
#
12+
# BOINC is distributed in the hope that it will be useful,
13+
# but WITHOUT ANY WARRANTY; without even the implied warranty of
14+
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
15+
# See the GNU Lesser General Public License for more details.
16+
#
17+
# You should have received a copy of the GNU Lesser General Public License
18+
# along with BOINC. If not, see <http://www.gnu.org/licenses/>.
19+
20+
set -e
21+
22+
exec_prefix=""
23+
24+
while [ $# -gt 0 ]; do
25+
key="$1"
26+
case $key in
27+
--exec_prefix)
28+
exec_prefix="--exec_prefix=$2"
29+
shift
30+
;;
31+
*)
32+
echo "unrecognized option $key"
33+
;;
34+
esac
35+
shift # past argument or value
36+
done
37+
38+
if [ ! -d "linux" ]; then
39+
echo "start this script in the source root directory"
40+
exit 1
41+
fi
42+
43+
TRIPLET="arm64-linux-release"
44+
45+
BUILD_DIR="$PWD/3rdParty/linux"
46+
VCPKG_ROOT="$BUILD_DIR/vcpkg"
47+
export VCPKG_DIR="$VCPKG_ROOT/installed/$TRIPLET"
48+
49+
linux/update_vcpkg_client.sh $TRIPLET
50+
51+
export CC=aarch64-linux-gnu-gcc
52+
export CXX=aarch64-linux-gnu-g++
53+
export LD=aarch64-linux-gnu-ld
54+
export CFLAGS="-march=armv8-a -O3"
55+
export CXXFLAGS="-march=armv8-a -O3 -std=c++11"
56+
export CPPFLAGS="-I$VCPKG_DIR/include -I$VCPKG_DIR/include/"
57+
export LDFLAGS="-march=armv8-a -static-libstdc++ -s"
58+
export _libcurl_pc="$VCPKG_DIR/lib/pkgconfig/libcurl.pc"
59+
export PKG_CONFIG_PATH=$VCPKG_DIR/lib/pkgconfig/
60+
61+
./configure --host=aarch64-linux-gnu --with-boinc-platform="aarch64-unknown-linux-gnu" --with-boinc-alt-platform="arm-unknown-linux-gnueabihf" --with-libcurl=$VCPKG_DIR --with-ssl=$VCPKG_DIR --disable-server --enable-client --disable-manager $exec_prefix

0 commit comments

Comments
 (0)