-
-
Notifications
You must be signed in to change notification settings - Fork 16.8k
rustc: use 1.82.0 binary to bootstrap rustc 1.82.0 #351028
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
Conversation
3d60dc0
to
5f08f83
Compare
Maintainers what do you think? |
FWIW while I'm not listed as a maintainer, that's basically an accident. I'm generally the one who handles rustc upgrades and a lot of other rust stuff. Apparently in 2017 we were told that we should be using the previous version of rustc, not the current one. @workingjubilee do you know if that's still what we should be preferring in general? |
Correct, the Rust compiler must be able to build itself. |
In 2017, our usual flow for bootstrapping the compiler was different, so it could have been much rockier, and it has always been touchy on 32-bit. Nowadays, for development purposes, we build the standard library with the last beta version. From release to release, that means "the last version". This was easier to standardize on, and have everyone reuse it. Then we build the compiler with the beta + new library. Then it builds its own library again to complete its sysroot. Then, after building the compiler with the beta, there is another build with the new compiler. In many cases there are no practical differences. |
5f08f83
to
2c251e0
Compare
So if upstream now ensures that each version can build itself, then I propose to change the bootstrap accordingly. I have updated the PR to do so. |
Could you put an explanation of why we're making this change in the commit message please? |
2c251e0
to
f130af6
Compare
Change the bootstrap on all platforms to use a version of the upstream binary that is equal to the version that is being built, instead of a binary of one version prior. This is necessary for the 1.82.0 release because on some platforms (rust-lang/rust#129268) the 1.81.0 binary can not build the 1.82.0 source. Furthermore, upstream reported that their development process (now) usually involves building a release compiler with itself and that "the Rust compiler must be able to build itself".
f130af6
to
4026e88
Compare
Thank you! |
This uses the upstream version 1.82.0 binary to bootstrap the rust compiler of the same version instead of the binary of the previous version on riscv64-linux. The reason is that the older 1.81.0 cannot bootstrap the new version for this platform as discussed in rust-lang/rust#129268. This is a temporary fix that is only necessary for this version and it only applies to native compilation, not to cross compilation.
Edit: Update it for all platforms.
Things done
nix.conf
? (See Nix manual)sandbox = relaxed
sandbox = true
nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD"
. Note: all changes have to be committed, also see nixpkgs-review usage./result/bin/
)Add a 👍 reaction to pull requests you find important.