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

1.38 beta fails to bootstrap itself #63911

Closed
Keruspe opened this issue Aug 26, 2019 · 4 comments · Fixed by #63941
Closed

1.38 beta fails to bootstrap itself #63911

Keruspe opened this issue Aug 26, 2019 · 4 comments · Fixed by #63941
Labels
T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

Comments

@Keruspe
Copy link
Contributor

Keruspe commented Aug 26, 2019

When using 1.38 beta to bootstrap itself, I get:

error: unnecessary `unsafe` block
   --> src/bootstrap/builder.rs:148:19
    |                    
148 |             name: unsafe { ::std::intrinsics::type_name::<S>() },
    |                   ^^^^^^ unnecessary `unsafe` block
    |                  
@jonas-schievink jonas-schievink added T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) C-enhancement Category: An issue proposing an enhancement or a PR with one. labels Aug 26, 2019
@estebank estebank added I-nominated T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. and removed C-enhancement Category: An issue proposing an enhancement or a PR with one. labels Aug 26, 2019
@Mark-Simulacrum
Copy link
Member

This is expected and not a supported bootstrapping configuration; if you want to not see these errors you'll want to either bootstrap with N-1 compiler (so, in this case, 1.37) or I believe remove deny(warnings) from bootstrap and some other libraries, as well as set deny-warnings in config.toml to false. Note that only the 1.37 bootstrap method is officially supported as "guaranteed to work", the deny warnings fix is more of a hack. Closing as won't fix.

@Mark-Simulacrum Mark-Simulacrum removed I-nominated T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Aug 26, 2019
@Keruspe
Copy link
Contributor Author

Keruspe commented Aug 27, 2019

@Mark-Simulacrum Huh? In the past this was always fixed as it's a very common practice for distribution packaging (I don't know of a single packager not doing that).

See e.g. #54322 or #60265 (in which you sort of acknowledged that yourself)

deny-warnings is already set to false in config.toml, so I guess it somehow doesn't apply to building bootstrap itself.

@Keruspe
Copy link
Contributor Author

Keruspe commented Aug 27, 2019

I hope #63941 is an acceptable compromise wrt this. Thanks for pointing out the deny-warnings option which I forgot (since it has been set to false forever for us and never had any effect on the build of bootstrap itself)

@Mark-Simulacrum
Copy link
Member

Yeah #63941 is great; in this case the unsafe block is needed for 1.37 but not on 1.38; if there was an easy way to support both use cases then I'd be happy to accept a PR targeting beta but I'm not personally aware of one -- it looks like we don't seem to have an #[allow(unused_unsafe)] or similar?

We try to support distros and such where possible in this configuration, it's just that this specific case I'm not sure how much we can do. deny-warnings=false is always my recommendation when using a different bootstrap compiler, or manual patches to the code.

Keruspe added a commit to Keruspe/rust that referenced this issue Aug 27, 2019
When deny-warnings is not specified or set to true, the behaviour is the same as before.
When deny-warnings is set to false, warnings are now allowed

Fixes rust-lang#63911

Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>
Centril added a commit to Centril/rust that referenced this issue Aug 29, 2019
rustbuild: allow disabling deny(warnings) for bootstrap

When deny-warnings is not specified or set to true, the behaviour is the same as before.
When deny-warnings is set to false, warnings are now allowed

Fixes rust-lang#63911
Centril added a commit to Centril/rust that referenced this issue Aug 29, 2019
rustbuild: allow disabling deny(warnings) for bootstrap

When deny-warnings is not specified or set to true, the behaviour is the same as before.
When deny-warnings is set to false, warnings are now allowed

Fixes rust-lang#63911
Centril added a commit to Centril/rust that referenced this issue Aug 29, 2019
rustbuild: allow disabling deny(warnings) for bootstrap

When deny-warnings is not specified or set to true, the behaviour is the same as before.
When deny-warnings is set to false, warnings are now allowed

Fixes rust-lang#63911
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants