mirror of
https://github.com/trussed-dev/trussed.git
synced 2026-05-10 06:02:27 +00:00
45 lines
972 B
YAML
45 lines
972 B
YAML
name: CI
|
|
|
|
on:
|
|
pull_request:
|
|
branches: [main]
|
|
push:
|
|
branches: [main]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
target:
|
|
- x86_64-unknown-linux-gnu
|
|
- thumbv7em-none-eabi
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v2
|
|
|
|
- name: Install Rust toolchain
|
|
uses: actions-rs/toolchain@v1
|
|
with:
|
|
toolchain: stable
|
|
target: ${{ matrix.target }}
|
|
profile: minimal
|
|
|
|
- name: Install build dependencies
|
|
run: >
|
|
sudo apt-get update -y -qq &&
|
|
sudo apt-get install -y -qq llvm libc6-dev-i386 libclang-dev
|
|
|
|
- uses: fiam/arm-none-eabi-gcc@v1
|
|
with:
|
|
release: "9-2020-q2"
|
|
|
|
- name: Build
|
|
run: cargo build --verbose --target ${{ matrix.target }}
|
|
|
|
- name: Run tests
|
|
run: cargo test --verbose --features virt
|
|
if: matrix.target == 'x86_64-unknown-linux-gnu'
|
|
|