Skip to content

VFIO Build

VFIO Build #70

Workflow file for this run

name: VFIO Build
on: [pull_request, create]
jobs:
build:
if: github.event_name == 'pull_request'
name: VFIO Build using MSHV changes
runs-on: ubuntu-latest
strategy:
matrix:
rust:
- stable
target:
- x86_64-unknown-linux-gnu
steps:
- name: Code checkout
uses: actions/checkout@v4
with:
path: mshv
- name: Install Rust toolchain (${{ matrix.rust }})
uses: dtolnay/rust-toolchain@stable
with:
toolchain: ${{ matrix.rust }}
target: ${{ matrix.target }}
components: rustfmt, clippy
- name: Cloning vfio Repo
uses: actions/checkout@v4
with:
repository: rust-vmm/vfio
path: vfio
- name: Copying script to vfio directory
working-directory: ./mshv
run: cp scripts/use-local-mshv-for-vfio-build.sh ../vfio/
- name: Applying patch(to use local mshv crates) with script
working-directory: ./vfio
run: ./use-local-mshv-for-vfio-build.sh
- name: Build vfio(mshv)
working-directory: ./vfio
run: cargo build --release --all --no-default-features --features mshv
- name: Build vfio(nohv)
working-directory: ./vfio
run: cargo build --release --no-default-features
- name: Clippy(mshv)
working-directory: ./vfio
run: cargo clippy --workspace --bins --examples --benches --no-default-features --features mshv --all-targets -- -D warnings
- name: Clippy(nohv)
working-directory: ./vfio
run: cargo clippy --workspace --bins --examples --benches --no-default-features --all-targets -- -D warnings