diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a406645..67177fc 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -15,7 +15,7 @@ concurrency: env: CARGO_TERM_COLOR: always - RUSTFLAGS: -D warnings + RUSTFLAGS: -D warnings -C link-arg=-fuse-ld=mold jobs: build: @@ -27,16 +27,14 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable - with: - components: rustfmt, clippy + + - name: Install mold linker + uses: rui314/setup-mold@v1 - name: Cache Rust build artifacts uses: Swatinem/rust-cache@v2 with: cache-on-failure: true - - name: Build debug - run: cargo build --all --verbose - - - name: Build release - run: cargo build --all --release --verbose + - name: Check compilation + run: cargo check --all --all-targets diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index c4ec838..786ab05 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -44,6 +44,9 @@ jobs: with: components: clippy + - name: Install mold linker + uses: rui314/setup-mold@v1 + - name: Cache Rust build artifacts uses: Swatinem/rust-cache@v2 with: diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 8e20a83..682c687 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -16,6 +16,7 @@ concurrency: env: CARGO_TERM_COLOR: always RUST_MIN_STACK: 8388608 + RUSTFLAGS: -C link-arg=-fuse-ld=mold jobs: test: @@ -28,6 +29,9 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + - name: Install mold linker + uses: rui314/setup-mold@v1 + - name: Cache Rust build artifacts uses: Swatinem/rust-cache@v2 with: @@ -51,6 +55,9 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + - name: Install mold linker + uses: rui314/setup-mold@v1 + - name: Cache Rust build artifacts uses: Swatinem/rust-cache@v2 with: @@ -70,6 +77,9 @@ jobs: - name: Install Rust toolchain uses: dtolnay/rust-toolchain@stable + - name: Install mold linker + uses: rui314/setup-mold@v1 + - name: Cache Rust build artifacts uses: Swatinem/rust-cache@v2 with: