rustc: Change LLVM target for the wasm32-wasip2 Rust target

This commit changes the LLVM target of for the Rust `wasm32-wasip2`
target to `wasm32-wasip2` as well. LLVM does a bit of detection on the
target string to know when to call `wasm-component-ld` vs `wasm-ld` so
otherwise clang is invoking the wrong linker.
This commit is contained in:
Alex Crichton 2024-05-03 15:57:31 -07:00
parent befabbc9e5
commit 7a77108809

View File

@ -55,7 +55,7 @@ pub fn target() -> Target {
options.entry_name = "__main_void".into();
Target {
llvm_target: "wasm32-unknown-unknown".into(),
llvm_target: "wasm32-wasip2".into(),
metadata: crate::spec::TargetMetadata {
description: None,
tier: None,