From 14eedf440b7da2d36886add99a44412f63b15e0e Mon Sep 17 00:00:00 2001 From: Vinzenz Schroeter Date: Sat, 3 May 2025 23:16:30 +0200 Subject: [PATCH] split jobs? --- .github/workflows/rust.yml | 31 +++++++++---------------------- 1 file changed, 9 insertions(+), 22 deletions(-) diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index a60a10b..de0282c 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -13,7 +13,7 @@ env: RUSTFLAGS: "-Dwarnings" jobs: - clippy: + build-gnu-apt: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 @@ -26,30 +26,20 @@ jobs: - name: Run Clippy run: cargo clippy + - name: build + run: cargo build + - name: generate bindings run: ./generate-binding.sh - name: check that generated files did not change run: output=$(git status --porcelain) && [ -z "$output" ] - build-stable: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 - - - name: Update repos - run: sudo apt-get update -qq - - name: Install toolchain - run: sudo apt-get install -qy cargo rust-clippy liblzma-dev gcc make pkgconf - - - name: build - run: cargo build - - name: build example -- glibc release run: cd example && make clean && make TARGET=aarch64-unknown-linux-gnu PROFILE=release - name: build example -- glibc debug run: cd example && make clean && make TARGET=aarch64-unknown-linux-gnu PROFILE=debug - build-musl: + build-musl-stable: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 @@ -58,15 +48,15 @@ jobs: run: sudo apt-get update -qq - name: Install toolchain run: sudo apt-get install -qy liblzma-dev gcc make pkgconf musl-dev musl-tools rustup - - name: install musl rust target - run: rustup toolchain install nightly -t aarch64-unknown-linux-musl --no-self-update + - name: install rust target + run: rustup toolchain install stable -t aarch64-unknown-linux-musl --no-self-update - name: build example -- musl release run: cd example && make clean && make TARGET=aarch64-unknown-linux-musl PROFILE=release MUSL=1 CARGO="rustup run stable cargo" - name: build example -- musl debug run: cd example && make clean && make TARGET=aarch64-unknown-linux-musl PROFILE=debug MUSL=1 CARGO="rustup run stable cargo" - build-size: + build-size-unstable: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 @@ -75,11 +65,8 @@ jobs: run: sudo apt-get update -qq - name: Install toolchain run: sudo apt-get install -qy liblzma-dev gcc make pkgconf musl-dev musl-tools rustup - - name: install rust nightly - run: rustup default nightly - - name: install rust targets - run: rustup toolchain install nightly -t aarch64-unknown-linux-musl -t aarch64-unknown-linux-gnu --no-self-update + run: rustup toolchain install nightly -t aarch64-unknown-linux-musl -t aarch64-unknown-linux-gnu -c rust-src --no-self-update - name: build example -- glibc size-optimized run: cd example && make clean && make TARGET=aarch64-unknown-linux-gnu PROFILE=size-optimized CARGO="rustup run nightly cargo"