diff --git a/build.rs b/build.rs index f512fc2e6..39cee311f 100644 --- a/build.rs +++ b/build.rs @@ -644,9 +644,10 @@ mod c { // Include out-of-line atomics for aarch64, which are all generated by supplying different // sets of flags to the same source file. - // Note: Out-of-line aarch64 atomics are not supported by the msvc toolchain (#430). + // Note: Out-of-line aarch64 atomics are not supported by the msvc toolchain (#430) and + // on uefi. let src_dir = root.join("lib/builtins"); - if target.arch == "aarch64" && target.env != "msvc" { + if target.arch == "aarch64" && target.env != "msvc" && target.os != "uefi" { // See below for why we're building these as separate libraries. build_aarch64_out_of_line_atomics_libraries(&src_dir, cfg);