Use LLVM's UEFI targets by madsmtm · Pull Request #132570 · rust-lang/rust (original) (raw)

The UEFI targets previously passed Windows targets to LLVM, because that's what they're the most similar to.

That's not ideal though (part of this problem was analyzed in #64334), but it seems like LLVM has gained support for UEFI in-tree, so we should probably just use that?

Unresolved is whether the linker flags /entry:efi_main /subsystem:efi_application are still needed, or if such details are handled by LLVM/LLD nowadays automatically?

Note that I am only opening this because it causes issues for cc when trying to pass that target name to LLVM, I have no idea if this is actually correct, and it's completely untested!

CC target maintainers @dvdhrm @nicholasbishop
@rustbot label O-uefi