Closed
Description
The UEFI targets (x86_64-unknown-uefi, i686-unknown-uefi, and aarch64-unknown-uefi) started failing to compile in the latest nightly when using build-std
, failing with "LLVM ERROR: dwo only supported with ELF and Wasm".
Code
src/main
:
#![no_main]
#![no_std]
#[panic_handler]
fn panic_handler(_info: &core::panic::PanicInfo) -> ! {
loop {}
}
#[export_name = "efi_main"]
pub extern "C" fn main(_h: *mut core::ffi::c_void, _st: *mut core::ffi::c_void) -> usize {
0
}
.cargo/config.toml
:
[unstable]
build-std = ["core", "compiler_builtins", "alloc"]
build-std-features = ["compiler-builtins-mem"]
Build:
$ cargo +nightly build --target x86_64-unknown-uefi
Compiling core v0.0.0 (/var/home/nbishop/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core)
Compiling rustc-std-workspace-core v1.99.0 (/var/home/nbishop/.rustup/toolchains/nightly-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/rustc-std-workspace-core)
LLVM ERROR: dwo only supported with ELF and Wasm
Compiling compiler_builtins v0.1.79
LLVM ERROR: dwo only supported with ELF and Wasm
error: could not compile `rustc-std-workspace-core`
warning: build failed, waiting for other jobs to finish...
error: could not compile `core`
LLVM ERROR: dwo only supported with ELF and Wasm
error: could not compile `compiler_builtins`
cargo-bisect-rustc
output
searched nightlies: from nightly-2022-08-25 to nightly-2022-08-27
regressed nightly: nightly-2022-08-27
searched commit range: 7480389...c07a8b4
regressed commit: 450e99f
bisected with cargo-bisect-rustc v0.6.4
Host triple: x86_64-unknown-linux-gnu
Reproduce with:
cargo bisect-rustc -- build --target x86_64-unknown-uefi
CC @davidtwco since bisect pointed to #98051