-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Non-reproducible builds #5351
Comments
With this patch the output of two consecutive builds is identical: --- a/Cargo.toml
+++ b/Cargo.toml
@@ -5,6 +5,8 @@ members = [ "crates/*", "xtask/" ]
# disabling debug info speeds up builds a bunch,
# and we don't rely on it for debugging that much.
debug = 0
+incremental = false
+codegen-units = 1
[profile.release] Therefore, closing as a rustc bug. |
I still see differences with that patch, both in To make it more clear, I'm not talking about two repeated builds of the same directory but two builds of different directories. That is, clone the repo, make a copy of it in a different location, add |
Hmm, I see. Are you sure this is not a rustc bug? |
No, I'm not sure. But the steps I described in the first comment here reproduce for me when I clone this project by itself, so I don't think it's a bug in the rustc build system, if that's what you meant. The cause of the non-reproducibility could be due to a bug in rustc itself, of course, but it also could be due to something here; it's not obvious to me which is the case. |
If I make two different copies of rust-analyzer, set them both to build with
--remap-path-prefix
by adding it torustflags
in.cargo/config
, and build them withcargo xtask install
, I see multiple differences in the output files, includinglibrust_analyzer.rlib
and a number of the rlibs inrelease/deps
. Many of the rlib differences are non-obvious differences in rmeta files.Now that this is part of the rustc tree, this affects rust-lang/rust#34902.
The text was updated successfully, but these errors were encountered: