-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Build failure using source tar for 1.27.1 #52227
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
Comments
@bryteise can you share steps of how to reproduce this? What configure arguments did you use? What system are you on? Do you have more logs we can inspect? |
Sure, I should add I see this when trying to rebuild 1.27.0 using the 1.27.0 compiler built with the same configuration flags (both using cargo 0.28.0). The flags are
I am running on Clear Linux. Logs for 1.27.0 and 1.27.1 attached. We are also carrying a patch that fixes a different build problem. |
Oh I'm just dumb and was missing the other patch Fedora is carrying to avoid conflicts with the stage0 compiler bits. Nevermind X(. |
So I thought this was related to #48319 but looking at the config.toml full-bootstrap is not enabled. And I added verbose logging and the added verbosity gave me the compiler command used:
|
The problem seems to be the system proc_macro crate isn't able to load, I note the strace shows the usual 1.27 dance of:
But then does a
for a simple little
The proc_macro .so library seems to have normal looking content under readelf -s and rustc --verbose doesn't give any new information. The binary content including the proc_macro lib can be found here but I'm not sure what to look through next. We do configure the libdir for /usr/lib and then mv the libs and rustlib over to /usr/lib64 after the build though if I move them back over to /usr/lib I get a linker error:
Which looks gets passed the proc_macro portion going off of strace:
Though this looks a bit different from successful compilation still from a different system. I'm mostly just confused at this point. |
It looks like it's failing very early in the build, when it's building the build system. That probably means that something may not be quite right about your bootstrap compiler? If you let the bootstrap download its own compiler does the help the situation? |
Yes, sorry I should have added more background. This is using a bootstrap compiler that was built using the prebuilt rustc binary as the original bootstrap compiler (using the same configure flags). This compiler seems to be unable to find the correct libdir for the moved libraries even after the ldconfig cache has been built and if the libraries are not moved has the linker error I mentioned above (libstd-682c743c97115687.so: undefined reference to `rust_metadata_std_e9e557cbe6ff8dd919e08d2804b88683'). |
It looks like the bootstrap compiler can't find its own set of target libraries though? If it can find |
Exactly! I'm curious why the strace log above shows it finding the library at least at some point during the compilation but then printing out it can't find the proc_macro crate when I have the libraries moved to /usr/lib64 from /usr/lib. I could live with just creating symlinks to /usr/lib64 for everything but that doesn't work either (based on the linker error if I have the libraries in /usr/lib). |
I'm not sure myself :( It doesn't sound like this is a regression, though, so I'm going to remove the tag. |
Yea, agreed. Thanks for thinking about it =). |
@bryteise Is this still an issue for you? We've changed some things around with proc macros since then I believe, in particular we now uplift them to both host and target sysroots I believe, so perhaps that's helped here? |
@Mark-Simulacrum I'll take a look at building the latest release tomorrow and get back to you. |
Okay, I think this is fixed (though I may be hitting a different error earlier in the build now hiding it). I'll close this issue though since I can't readily reproduce it. |
Attempting to build 1.27.1 from https://static.rust-lang.org/dist/rustc-1.27.1-src.tar.gz gives the following error:
The text was updated successfully, but these errors were encountered: