-
Notifications
You must be signed in to change notification settings - Fork 541
Open
Description
Recently firefox started failing to compile on powerpc with errors like warning: [email protected]: clang-20: error: version 'elfv2' in target triple 'powerpc64le-alpine-linux-muslelfv2' is invalid
.
If I understood the issue correctly this happens since rust-lang/rust#142321 cause elfv2
(and elfv1
) are appended to the target triplet when creating the clang target.
This patch fixed compilation of firefox but I would like advice if this is the right way to fix the compilation failure. One thing I wondered is if -mabi=elfv1
and -mabi=elfv2
should be passed explicitly to ensure the compiler uses the correct abi.
--- a/third_party/rust/cc/src/target/llvm.rs
+++ b/third_party/rust/cc/src/target/llvm.rs
@@ -98,6 +98,7 @@
"llvm" | "softfloat" | "uwp" | "vec-extabi" => "",
"ilp32" => "_ilp32",
"abi64" => "",
+ "elfv1" | "elfv2" => "",
abi => abi,
};
Cow::Owned(match (vendor, env, abi) {
fossdd
Metadata
Metadata
Assignees
Labels
No labels