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

Rustc shim is now a wrapper #110854

Conversation

albertlarsan68
Copy link
Member

This is preparatory work to make clippy work in the repo (#107628).
This changes the rustc shim in bootstrap to be RUSTC_WRAPPER, instead of RUSTC.

This is preparatory work to make clippy work in the repo.
This changes the rustc shim in bootstrap to be RUSTC_WRAPPER,
instead of RUSTC.
@rustbot
Copy link
Collaborator

rustbot commented Apr 26, 2023

r? @ozkanonur

(rustbot has picked a reviewer for you, use r? to override)

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) labels Apr 26, 2023
@rust-log-analyzer

This comment has been minimized.

@rustbot rustbot added A-testsuite Area: The testsuite used to check the correctness of rustc T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue. labels Apr 26, 2023
@rust-log-analyzer

This comment has been minimized.

@jyn514
Copy link
Member

jyn514 commented Apr 26, 2023

@albertlarsan68 locally you have rustc in PATH. In CI, you must always set RUSTC or use the absolute path to the rustc binary, or it will fail.

@the8472
Copy link
Member

the8472 commented Apr 26, 2023

I think this would also break setups using sccache via RUSTC_WRAPPER.

@rust-log-analyzer
Copy link
Collaborator

The job x86_64-gnu-tools failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)

Caused by:
  process didn't exit successfully: `/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-std/release/build/libc-d2d75a169efdb097/build-script-build` (exit status: 101)
  --- stdout
  cargo:rerun-if-changed=build.rs
  --- stderr
  --- stderr
  thread 'main' panicked at 'Failed to get rustc version', /cargo/registry/src/index.crates.io-6f17d22bba15001f/libc-0.2.140/build.rs:188:9
warning: build failed, waiting for other jobs to finish...
Build completed unsuccessfully in 0:00:20
cat: /tmp/toolstate/toolstates.json: No such file or directory

@jyn514
Copy link
Member

jyn514 commented Apr 26, 2023

I think this would also break setups using sccache via RUSTC_WRAPPER.

"break" is a little strong, they just won't be cached, right? How often is it possible to cache these in practice anyway, won't you have to rebuild every time you rebase (or even more frequently for stage 1 builds)?

@jyn514
Copy link
Member

jyn514 commented Apr 26, 2023

That said, we could probably do this for check/clippy only if it causes issues.

@the8472
Copy link
Member

the8472 commented Apr 26, 2023

sccache sometimes saves me quite a bit of compile time when when switching back and forth between commits or blasting away parts of the build dir.

@albertlarsan68
Copy link
Member Author

I could "cache" the RUSTC_WRAPPER, to call him with the right command and flags.

@bors
Copy link
Contributor

bors commented May 5, 2023

☔ The latest upstream changes (presumably #111231) made this pull request unmergeable. Please resolve the merge conflicts.

@albertlarsan68 albertlarsan68 deleted the bootstraps-rustc-shim-is-now-a-wrapper branch June 26, 2023 08:46
@jyn514 jyn514 mentioned this pull request Nov 5, 2023
@onur-ozkan onur-ozkan removed the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Oct 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-testsuite Area: The testsuite used to check the correctness of rustc T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-infra Relevant to the infrastructure team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants