fix(fuzz-ci): build cargo-fuzz with stable, not the nightly override
Installing cargo-fuzz under a nightly directory override made rustix's build script (a cargo-fuzz dependency) gate on `rustc_attrs`, which this runner's nightly rejects as reserved-for-rustc. Install nightly without overriding the directory default so `cargo install cargo-fuzz` still builds under stable; only `fuzz build`/`fuzz run` opt into `+nightly`.
This commit is contained in:
1 file changed
+10
-2
@@ -29,12 +29,20 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
persist-credentials: false
|
persist-credentials: false
|
||||||
|
|
||||||
- name: Install nightly Rust toolchain
|
- name: Install stable Rust toolchain
|
||||||
uses: actions-rust-lang/setup-rust-toolchain@166cdcfd11aee3cb47222f9ddb555ce30ddb9659 # v1
|
uses: actions-rust-lang/setup-rust-toolchain@166cdcfd11aee3cb47222f9ddb555ce30ddb9659 # v1
|
||||||
with:
|
with:
|
||||||
toolchain: nightly
|
|
||||||
cache-key: fuzz
|
cache-key: fuzz
|
||||||
|
|
||||||
|
- name: Install nightly Rust toolchain
|
||||||
|
# Installed alongside, but deliberately not made the directory
|
||||||
|
# default: cargo-fuzz itself is built with the default stable
|
||||||
|
# toolchain below, and only `fuzz build`/`fuzz run` are run with
|
||||||
|
# `+nightly`. Building cargo-fuzz's own dependency tree under a
|
||||||
|
# nightly override can trip build scripts (e.g. rustix) that gate
|
||||||
|
# unstable internal attributes on detecting a nightly compiler.
|
||||||
|
run: rustup toolchain install nightly --profile minimal --no-self-update
|
||||||
|
|
||||||
- name: Install cargo-fuzz
|
- name: Install cargo-fuzz
|
||||||
run: cargo install cargo-fuzz --locked --version "${CARGO_FUZZ_VERSION}"
|
run: cargo install cargo-fuzz --locked --version "${CARGO_FUZZ_VERSION}"
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user