name: CI
on:
push:
branches: [master, smp, ci]
pull_request:
branches: [master]
env:
CARGO_TERM_COLOR: always
jobs:
build-demos:
name: Build Demos
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
targets: >-
thumbv6m-none-eabi,
thumbv7m-none-eabi,
thumbv7em-none-eabihf,
armv7a-none-eabi,
aarch64-unknown-none,
riscv32imac-unknown-none-elf
- name: Build Cortex-M0 demo
run: cd demo/cortex-m0 && cargo build --release
- name: Build Cortex-M3 demo
run: cd demo/cortex-m3 && cargo build --release
- name: Build Cortex-M4F demo
run: cd demo/cortex-m4f && cargo build --release
- name: Build Cortex-A9 demo
run: cd demo/cortex-a9 && cargo build --release
continue-on-error: true
- name: Build Cortex-A53 demo
run: cd demo/cortex-a53 && cargo build --release
- name: Build RISC-V32 demo
run: cd demo/riscv32 && cargo build --release
check-features:
name: Check Feature Combinations
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
targets: thumbv7em-none-eabihf
- name: Check with heap-4
run: cargo check --target thumbv7em-none-eabihf --features "port-cortex-m4f,heap-4"
- name: Check with heap-5
run: cargo check --target thumbv7em-none-eabihf --features "port-cortex-m4f,heap-5"
- name: Check with all kernel features
run: cargo check --target thumbv7em-none-eabihf --features "port-cortex-m4f,heap-4,use-mutexes,timers,task-delete,task-suspend,queue-sets,stream-buffers"
formatting:
name: Formatting
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt
- run: cargo fmt --check