-
Notifications
You must be signed in to change notification settings - Fork 460
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
Use -windows-gnu for all UEFI targets #1264
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
cc @madsmtm can you take a look at this please?
Huh, I seemed to remember explicitly verifying that the code did the same thing, but I must have missed this, sorry about that :/ I'm not against doing this fix in I found this code comment in the
|
That makes sense. Unfortunately I don't have answers to most of those questions yet. The specific motivation for this PR was trying to build https://github.com/Amanieu/minicov for Possibly the Rust UEFI aarch64/x86_64 targets should be switched to -windows-gnu, as i686 already is. |
Fair enough, then perhaps a comment that we don't know why this hack is needed, and link to this PR ;) Alternatively, if you're feeling venturous, I found https://krinkinmu.github.io/2020/10/11/efi-getting-started.html#bulding, which seems to suggest that the actual fix is to pass the |
Actually, seems like LLVM should have support for UEFI nowadays: https://discourse.llvm.org/t/rfc-uefi-driver-support-uefi-target/73261. So maybe pass those targets ( |
Opened rust-lang/rust#132570 |
This restores the behavior prior to rust-lang#1252, when the UEFI targets were hardcoded in src/lib.rs.
9182f44
to
945dbcd
Compare
Thanks for opening that PR! I wasn't aware clang had added these targets. I've updated this PR to add a comment describing the history, the current state, and a TODO for the future. Also tweaked the way the override is set, so that it won't immediately change to follow rustc if the rustc targets are changed, since I think we would want to be intentional about changing cc-rs to match. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me now, thanks for writing things out!
This restores the behavior prior to #1252, when the UEFI targets were hardcoded in src/lib.rs.