-
Notifications
You must be signed in to change notification settings - Fork 557
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
Fails to detect the compiler if RUSTC_WORKSPACE_WRAPPER is set #1274
Comments
The executable set in |
I think it's not enough to check the Without a reliable way to know if there's a wrapper a heuristic could be to check the second argument if the first does not match a known compiler. |
This is a duplicate of #861, right? |
This is close, but there is still a difference as |
So using So the usage actually exceeds what was covered in the statement in the rustc issue PR rust-lang/cargo#8143 (comment) . A major focus should be put on the interaction of the workspace specific one with the global wrapper, in rustc, from the initial PR, the I'll review the PR in the next days. |
Based on my testing, that is not the case. The global wrapper is run before the workspace wrapper, but they are both invoked for every call to |
You're correct, it's not either or, the wrappers are combined, the relevant code in the current master of rust is https://github.com/rust-lang/cargo/blob/8827baaa781b37872134c1ba692a6f0aeb37890e/src/cargo/util/rustc.rs#L102-L108 |
When the RUSTC_WORKSPACE_WRAPPER environment variable is set, sccache fails to detect the compiler being used.
This has caused issues for Rust's Clippy in the past, and has been worked around by special-casing Clippy in sccache: #728
However, Clippy is not the only user of
RUSTC_WORKSPACE_WRAPPER
. For example https://github.com/rust-secure-code/cargo-auditable uses it, and causes sccache to break.Steps to reproduce:
The text was updated successfully, but these errors were encountered: