Skip to content

Commit 7b42f73

Browse files
author
Christian A. Ehrhardt
committed
ci: Add cheri riscv build configuration
Build a cheri purecap kernel for riscv in the ci workflow. This uses the llvm-18 compiler as published in the cheri alliance repo. Signed-off-by: Christian A. Ehrhardt <[email protected]>
1 parent c386987 commit 7b42f73

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

.github/workflows/build.yml

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,18 @@ jobs:
4141
arch: [ riscv64, aarch64 ]
4242
compiler: [ llvm-18, gcc ]
4343
config: [ defconfig ]
44+
install_compiler: [ true ]
4445
include:
4546
- arch: morello
4647
compiler: llvm-morello
4748
config: morello_pcuabi_defconfig
4849
container: docker.io/ctsrd/morello-sdk:latest
49-
50+
install_compiler: false
51+
- arch: riscv64cheri
52+
compiler: llvm-cheri
53+
config: qemu_riscv64cheripc_defconfig
54+
container: docker.io/chrehrhardt/riscvcheri-ubuntu-llvm18:latest
55+
install_compiler: false
5056
steps:
5157
# Install node.js in the docker container to allow testing this action with `gh act` locally.
5258
# This is not needed in real GitHub action runs, so limit this to env.ACT being set.
@@ -72,7 +78,7 @@ jobs:
7278
if [[ "${{ matrix.compiler }}" == llvm* ]]; then
7379
VER=${{ matrix.compiler }}
7480
VER=${VER#llvm-}
75-
if [[ "${{ matrix.compiler }}" != llvm-morello ]]; then
81+
if [[ "${{ matrix.install_compiler }}" == "true" ]]; then
7682
packages+=(clang-$VER lld-$VER llvm-$VER)
7783
fi
7884
elif [ "${{ matrix.compiler }}" == "gcc" ]; then
@@ -131,6 +137,7 @@ jobs:
131137
# Set pipefail to fail if make fails, otherwise any error is squashed
132138
set -o pipefail
133139
ARGS=""
140+
LLVM_DIR=
134141
if [ "${{ matrix.arch }}" = "aarch64" ]; then
135142
ARGS="$ARGS ARCH=arm64"
136143
CROSS="aarch64-linux-gnu-"
@@ -139,6 +146,8 @@ jobs:
139146
CROSS="riscv64-linux-gnu-"
140147
elif [ "${{ matrix.arch }}" = "morello" ]; then
141148
ARGS="$ARGS ARCH=arm64"
149+
elif [ "${{ matrix.arch }}" = "riscv64cheri" ]; then
150+
ARGS="$ARGS ARCH=riscv"
142151
fi
143152
144153
if [[ "${{ matrix.compiler }}" == "llvm-morello" ]]; then

0 commit comments

Comments
 (0)