Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cargo-audit build fails with cr117 toolchain #32816

Closed
rillian opened this issue Sep 6, 2023 · 0 comments · Fixed by brave/brave-core#20029
Closed

cargo-audit build fails with cr117 toolchain #32816

rillian opened this issue Sep 6, 2023 · 0 comments · Fixed by brave/brave-core#20029
Assignees
Labels

Comments

@rillian
Copy link

rillian commented Sep 6, 2023

Description

Since merging the chromium 117 changes, ci builds fail compiling cargo-audit.


FAILED: cargo_audit/release/cargo-audit 
19:13:58  python3 ../../build/gn_run_binary.py /home/ubuntu/workspace/brave-browser-build-noplatform-nightly/src/third_party/rust-toolchain/bin/cargo build --release --manifest-path /home/ubuntu/workspace/brave-browser-build-noplatform-nightly/src/brave/tools/crates/cargo_audit/v0_17/crate/Cargo.toml --target-dir /home/ubuntu/workspace/brave-browser-build-noplatform-nightly/src/out/Component_audit/cargo_audit
[...]
19:13:58  error[E0635]: unknown feature `proc_macro_span_shrink`
19:13:58    --> /home/ubuntu/.cargo/registry/src/index.crates.io-6f17d22bba15001f/proc-macro2-1.0.56/src/lib.rs:92:30
19:13:58     |
19:13:58  92 |     feature(proc_macro_span, proc_macro_span_shrink)
19:13:58     |                              ^^^^^^^^^^^^^^^^^^^^^^
19:13:58  

The offending feature is enabled by proc-macro2 v1.0.56 on nightly builds. The upstream chromium rust toolchain build we're using here is compiled as a nightly release, so the likely conflict is between unstable features.

Steps to Reproduce

  1. rustup install nightly-2023-07-21
  2. cd brave/tools/crates/cargo_audit/v0_17/crate
  3. cargo +nightly-2023-07-21 check

Actual result:

Reproduces failure above

Expected result:

Ideally it would build.

The current cargo-audit release (v0.18.1) bumps the proc-macros2 version to one without the failing feature reference, which works with the new chromium toolchain.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants