-
Notifications
You must be signed in to change notification settings - Fork 13k
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
Prevent building the clippy plugin in rustbuild #66052
Conversation
This comment has been minimized.
This comment has been minimized.
I cannot approve PRs, you need to |
Some local testing shows that clippy builds sucessfully after this change. |
Can you confirm that all the tools are named the same as the tool? I am not sure that's the case, if it isn't we'll likely want to change the logic here a bit. |
Thanks for the PR! I'm sort of confused though as to why this fixes that issue, could you expand in the PR description, the comments, or the commit message about how this fixes the original issue? |
I have updated the description. |
Could you also place some comments in the source code about how tools are being avoided? Additionally does this affect Could we otherwise update |
68e9791
to
0ae076e
Compare
I added a comment. |
Can you expand on your reasoning on why rustfmt will still work? Simply pasting a link to the manifest is pretty opaque and doesn't really mean much to me. It doesn't answer my concern about this probably not building the |
The tools declaration is here: Lines 642 to 659 in d1fff4a
As you can see, the cargo-fmt and rustfmt binaries are defined with the same name both in this file and the manifest:https://github.com/rust-lang/rustfmt/blob/6aec17e4c372d1cda3484a2e292cff8f5995dd64/Cargo.toml#L14-L20 |
Also I have tested this locally with a full extended build. |
Clippy should drop |
Closed in favor of #66142 |
Provided the tool names as defined using
tool_extended!(...)
are valid binary names as defined in the manifest, this PR avoids building the clippy plugin by passing the--bin
flags followed by tool name to Cargo when building extended tools.If we don't pass the
--bin
flag, Cargo will build everything by default - including the plugin that causes the failure.Close #62558