Skip to content

CI tweaks (#5)

CI tweaks (#5) #39

Workflow file for this run

name: Rust
on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]
env:
CARGO_TERM_COLOR: always
jobs:
ubuntu-build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Install llvm 16
run: wget https://apt.llvm.org/llvm.sh && chmod +x llvm.sh && sudo ./llvm.sh 16 && rm llvm.sh
- name: Install riscv64 target
run: rustup target add riscv64imac-unknown-none-elf
- name: Build and test
run: make
fedora-build:
runs-on: ubuntu-latest
container:
image: fedora:latest
volumes:
- ${{ github.workspace }}:/code
steps:
- name: Install dependencies
run: sudo dnf -y install clang git make
- uses: actions-rust-lang/setup-rust-toolchain@v1
- uses: actions/checkout@v3
with:
submodules: true
- name: Install riscv64 target
run: rustup target add riscv64imac-unknown-none-elf
- name: Build and test
run: make
macos-build:
runs-on: macos-latest
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Install llvm 16
run: brew install llvm@16
- name: Install riscv64 target
run: rustup target add riscv64imac-unknown-none-elf
- name: Build and test
run: make
windows-build:
runs-on: windows-2019
steps:
- uses: actions/checkout@v3
with:
submodules: true
- name: Install llvm
shell: pwsh
# https://github.com/ScoopInstaller/Install#for-admin
#
# Note that on Windows we cannot choose LLVM 16 here, we have to settle on latest stable LLVM
run: |
iex "& {$(irm get.scoop.sh)} -RunAsAdmin"
scoop install llvm yasm
echo "$env:USERPROFILE\scoop\shims" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
- name: Install riscv64 target
run: rustup target add riscv64imac-unknown-none-elf
- name: Build and test
run: make