-
Notifications
You must be signed in to change notification settings - Fork 26
64 lines (58 loc) · 1.76 KB
/
Copy pathmain.yml
File metadata and controls
64 lines (58 loc) · 1.76 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
name: CI
on: [push, pull_request]
jobs:
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt, clippy
- run: cargo fmt --all -- --check
build:
runs-on: ubuntu-latest
strategy:
matrix:
target: [
x86_64-unknown-linux-gnu,
x86_64-apple-darwin,
aarch64-unknown-linux-gnu,
aarch64-unknown-none-softfloat,
riscv32imac-unknown-none-elf,
riscv64imac-unknown-none-elf,
]
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
targets: ${{ matrix.target }}
components: clippy
- run: cargo build --all-features --target ${{ matrix.target }}
- run: cargo clippy --target ${{ matrix.target }}
- run: cargo doc --target ${{ matrix.target }}
build-x86_64-none:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@nightly
with:
components: rust-src
- run: cargo +nightly build --all-features --target x86_64-unknown-linux-gnu -Z build-std=core,alloc
- run: cargo +nightly doc --all-features --target x86_64-unknown-linux-gnu -Z build-std=core,alloc
test-x86_64:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest]
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- run: cargo test --all-features
test-aarch64:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
with:
targets: aarch64-unknown-linux-gnu
- run: cargo build --target aarch64-unknown-linux-gnu