From 70a53c200c24d10477767cc567b17a3bc5ce8fb0 Mon Sep 17 00:00:00 2001 From: Brendan Haines Date: Mon, 25 Aug 2025 21:31:48 -0600 Subject: [PATCH] compile riscv in docker --- .github/workflows/build.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .github/workflows/build.yml diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..b617894 --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,25 @@ +name: CI +on: push +jobs: + build: + name: Build C code + runs-on: ubuntu-latest + container: + image: plincar/riscv-gnu-toolchain:2023_03_12 + # volumes: + # - my_docker_volume:/volume_mount + steps: + - uses: actions/checkout@v4 + - name: Check for executables + run: | + # this really should have been added to path at install time when the container was made + export PATH=$PATH:/opt/riscv/gnu-toolchain/rv64/bin + riscv64-unknown-elf-gcc --version + - name: Build + run: | + cd tests/test_basic + # ls -lah + # cat Makefile + # make test.hex + export PATH=$PATH:/opt/riscv/gnu-toolchain/rv64/bin + riscv64-unknown-elf-as -march=rv32i -mabi=ilp32 test.S -o test.o