-
Notifications
You must be signed in to change notification settings - Fork 13.2k
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
lld-wrapper failed on Darwin #97755
Comments
Is this issue related to #97375 ? |
I found no traces of the last working nightly. |
It's certainly somehow related because |
"-B/Users/awesome/.rustup/toolchains/nightly-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/bin/gcc-ld" "-Wl,-rustc-lld-flavor=darwin" "-L" "/Users/awsome/.rustup/toolchains/nightly-x86_64-apple-darwin/lib/rustlib/x86_64-apple-darwin/lib" = note: lld-wrapper: -rustc-lld-flavor=<flavor> is not passed
clang: error: linker command failed with exit code 1 (use -v to see invocation) cc --version
Apple clang version 13.1.6 (clang-1316.0.21.2.5)
Target: x86_64-apple-darwin21.4.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin Do you need more information? |
Yes, output of lld-wrapper with (You don't need whole compiler build to rebuild lld-wrapper, it's a single-file standalone program, it can be built with |
= note: [src/tools/lld-wrapper/src/main.rs:73] arg = "@/var/folders/y0/n29lr9g94s12d892pb6yg3l40000gn/T/response-c2238e.txt"
lld-wrapper: -rustc-lld-flavor=<flavor> is not passed
clang: error: linker command failed with exit code 1 (use -v to see invocation) let args = env::args_os()
.skip(1)
.filter(|arg| match arg.to_str().and_then(|s| s.strip_prefix("-rustc-lld-flavor=")) {
Some(suffix) => {
dbg!(arg);
flavor = Some(suffix.to_string());
return false
}
None => {dbg!(arg); return true},
})
.collect::<Vec<_>>(); |
Note that main:rs73 is the failure case. |
I see. Due to the way in which |
I don't know whether rustc has utilities for handling response files |
Ok, it's actually clang that packs the command line into a |
…imulacrum Change implementation of `-Z gcc-ld` and `lld-wrapper` again This PR partially reverts rust-lang#97375 and uses the strategy described in rust-lang#97402 (comment) instead, thus fixes rust-lang#97755.
…imulacrum Change implementation of `-Z gcc-ld` and `lld-wrapper` again This PR partially reverts rust-lang#97375 and uses the strategy described in rust-lang#97402 (comment) instead, thus fixes rust-lang#97755.
…imulacrum Change implementation of `-Z gcc-ld` and `lld-wrapper` again This PR partially reverts rust-lang#97375 and uses the strategy described in rust-lang#97402 (comment) instead, thus fixes rust-lang#97755.
…imulacrum Change implementation of `-Z gcc-ld` and `lld-wrapper` again This PR partially reverts rust-lang#97375 and uses the strategy described in rust-lang#97402 (comment) instead, thus fixes rust-lang#97755.
…imulacrum Change implementation of `-Z gcc-ld` and `lld-wrapper` again This PR partially reverts rust-lang#97375 and uses the strategy described in rust-lang#97402 (comment) instead, thus fixes rust-lang#97755.
…imulacrum Change implementation of `-Z gcc-ld` and `lld-wrapper` again This PR partially reverts rust-lang#97375 and uses the strategy described in rust-lang#97402 (comment) instead, thus fixes rust-lang#97755.
…imulacrum Change implementation of `-Z gcc-ld` and `lld-wrapper` again This PR partially reverts rust-lang#97375 and uses the strategy described in rust-lang#97402 (comment) instead, thus fixes rust-lang#97755.
…imulacrum Change implementation of `-Z gcc-ld` and `lld-wrapper` again This PR partially reverts rust-lang#97375 and uses the strategy described in rust-lang#97402 (comment) instead, thus fixes rust-lang#97755.
…imulacrum Change implementation of `-Z gcc-ld` and `lld-wrapper` again This PR partially reverts rust-lang#97375 and uses the strategy described in rust-lang#97402 (comment) instead, thus fixes rust-lang#97755.
…imulacrum Change implementation of `-Z gcc-ld` and `lld-wrapper` again This PR partially reverts rust-lang#97375 and uses the strategy described in rust-lang#97402 (comment) instead, thus fixes rust-lang#97755.
…imulacrum Change implementation of `-Z gcc-ld` and `lld-wrapper` again This PR partially reverts rust-lang#97375 and uses the strategy described in rust-lang#97402 (comment) instead, thus fixes rust-lang#97755.
lld-wrapper is unhappy.
I tried this code:
RUSTFLAGS='-Z gcc-ld=lld -C target-cpu=native' cargo +nightly run --release
Instead, this happened:
... x86_64-apple-darwin/bin/gcc-ld" "-Wl,-rustc-lld-flavor=darwin ...
Meta
rustc --version --verbose
:Backtrace
Note that this worked for months. This is a regression for me.
The text was updated successfully, but these errors were encountered: