Skip to content

Commit b692fbe

Browse files
author
Sven Van Asbroeck
committed
CI: Add support for 32-bit arm
qemu emulates the virt machine running a cortex-a7. kernel-arm-release.config corresponds to: - arch/arm/configs/realview_defconfig (includes cortex-a7 virt support) - remove unused kernel infrastructure and drivers - enable rust support, enable rust samples (as modules) - enable android/binder rust support - switch from SLAB to SLUB kernel-arm-debug.config corresponds to: - kernel-arm-release.config - add debug settings under "Kernel Hacking", borrowed from arm64 - use RUST_OPT_LEVEL_2 to prevent stack overflows - enable CONFIG_KASAN Signed-off-by: Sven Van Asbroeck <[email protected]>
1 parent 9841e9c commit b692fbe

File tree

3 files changed

+3398
-3
lines changed

3 files changed

+3398
-3
lines changed

.github/workflows/ci.yaml

+16-3
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,19 @@ jobs:
1010

1111
strategy:
1212
matrix:
13-
arch: [arm64, ppc64le, x86_64]
13+
arch: [arm, arm64, ppc64le, x86_64]
1414
toolchain: [gcc, clang, llvm]
1515
config: [debug, release]
1616
rustc: [2021-02-20]
1717
output: [src] # [src, build]
1818
install: [rustup] # [rustup, standalone]
1919
sysroot: [common] # [common, custom]
2020

21-
# Exclude `LLVM=1` where not supported.
2221
exclude:
22+
# arm 32-bit gcc not yet supported
23+
- arch: arm
24+
toolchain: gcc
25+
# Exclude `LLVM=1` where not supported.
2326
- arch: ppc64le
2427
toolchain: llvm
2528

@@ -81,6 +84,14 @@ jobs:
8184
echo 'QEMU_ARCH=ppc64' >> $GITHUB_ENV
8285
echo 'QEMU_MACHINE=pseries' >> $GITHUB_ENV
8386
echo 'QEMU_CPU=POWER9' >> $GITHUB_ENV
87+
- if: matrix.arch == 'arm'
88+
run: |
89+
echo 'MAKE_ARCH=ARCH=arm' >> $GITHUB_ENV
90+
echo 'MAKE_CROSS_COMPILE=CROSS_COMPILE=arm-linux-gnueabi-' >> $GITHUB_ENV
91+
echo 'IMAGE_PATH=arch/arm/boot/zImage' >> $GITHUB_ENV
92+
echo 'QEMU_ARCH=arm' >> $GITHUB_ENV
93+
echo 'QEMU_MACHINE=virt' >> $GITHUB_ENV
94+
echo 'QEMU_CPU=cortex-a7' >> $GITHUB_ENV
8495
8596
- if: matrix.toolchain == 'clang'
8697
run: echo 'MAKE_TOOLCHAIN=CC=clang-11' >> $GITHUB_ENV
@@ -105,6 +116,8 @@ jobs:
105116
- run: echo $(llvm-config-11 --bindir) >> $GITHUB_PATH
106117

107118
# Setup: GCC
119+
- if: matrix.arch == 'arm'
120+
run: sudo apt-get install -y gcc-arm-linux-gnueabi lzop
108121
- if: matrix.arch == 'arm64'
109122
run: sudo apt-get install -y gcc-aarch64-linux-gnu
110123
- if: matrix.arch == 'ppc64le'
@@ -116,7 +129,7 @@ jobs:
116129
# Setup: QEMU
117130
- if: matrix.arch == 'x86_64'
118131
run: sudo apt-get install -y qemu-system-x86
119-
- if: matrix.arch == 'arm64'
132+
- if: matrix.arch == 'arm' || matrix.arch == 'arm64'
120133
run: sudo apt-get install -y qemu-system-arm
121134
- if: matrix.arch == 'ppc64le'
122135
run: sudo apt-get install -y qemu-system-ppc

0 commit comments

Comments
 (0)