Skip to content

Commit 0ffc516

Browse files
committed
GHA CI: use qemu-user from backports
This solves the PPC testing issue. The ARM testing issue is solved by the updated test suite.
1 parent 4de5b3b commit 0ffc516

File tree

1 file changed

+23
-22
lines changed

1 file changed

+23
-22
lines changed

tools/runner.sh

+23-22
Original file line numberDiff line numberDiff line change
@@ -33,25 +33,30 @@ if test -n "$opamroot"; then
3333
eval `opam env --safe`
3434
fi
3535

36+
# Install QEMU and other packages using apt-get
37+
38+
Apt_install() {
39+
sudo sh -c 'echo "deb http://deb.debian.org/debian bookworm-backports main" > /etc/apt/sources.list.d/backports.list'
40+
sudo apt-get update
41+
sudo apt-get -y -t bookworm-backports install qemu-user
42+
sudo apt-get -y install "$@"
43+
}
44+
3645
# Install additional system packages
3746

3847
System_install() {
3948
case "$target,$os" in
4049
aarch64,linux)
41-
sudo apt-get update
42-
sudo apt-get -y install qemu-user gcc-aarch64-linux-gnu
50+
Apt_install gcc-aarch64-linux-gnu
4351
;;
4452
arm,linux)
45-
sudo apt-get update
46-
sudo apt-get -y install qemu-user gcc-arm-linux-gnueabi gcc-arm-linux-gnueabihf
53+
Apt_install gcc-arm-linux-gnueabi gcc-arm-linux-gnueabihf
4754
;;
4855
ppc,linux)
49-
sudo apt-get update
50-
sudo apt-get -y install qemu-user gcc-powerpc-linux-gnu
56+
Apt_install gcc-powerpc-linux-gnu
5157
;;
5258
riscv,linux)
53-
sudo apt-get update
54-
sudo apt-get -y install qemu-user gcc-riscv64-linux-gnu
59+
Apt_install gcc-riscv64-linux-gnu
5560
;;
5661
x86_32,linux)
5762
sudo apt-get update
@@ -184,21 +189,17 @@ case "$target,$os" in
184189
2) Run_test "" "-Os";;
185190
esac;;
186191
arm,linux)
187-
# TEMPORARY: skip ARM testing because of QEMU problem on the test VM
188-
# case "$1" in
189-
# 1) Run_test "$simu_armhf" "-marm";;
190-
# 2) Run_test "$simu_armhf" "-mthumb";;
191-
# 3) Rebuild_runtime -toolprefix arm-linux-gnueabi- arm-eabi
192-
# Run_test "$simu_armsf" "-marm";;
193-
# esac;;
194-
echo "Skipping ARM tests";;
192+
case "$1" in
193+
1) Run_test "$simu_armhf" "-marm";;
194+
2) Run_test "$simu_armhf" "-mthumb";;
195+
3) Rebuild_runtime -toolprefix arm-linux-gnueabi- arm-eabi
196+
Run_test "$simu_armsf" "-marm";;
197+
esac;;
195198
ppc,linux)
196-
# TEMPORARY: skip PPC testing because of QEMU problem on the test VM
197-
# case "$1" in
198-
# 1) Run_test "$simu_ppc32" "";;
199-
# 2) Run_test "$simu_ppc32" "-Os";;
200-
# esac;;
201-
echo "Skipping PPC tests";;
199+
case "$1" in
200+
1) Run_test "$simu_ppc32" "";;
201+
2) Run_test "$simu_ppc32" "-Os";;
202+
esac;;
202203
riscv,linux)
203204
case "$1" in
204205
1) Run_test "$simu_rv64" "";;

0 commit comments

Comments
 (0)