From b4912a7f8eed37d612a5d026c17a225388f8ce76 Mon Sep 17 00:00:00 2001 From: Zoltan Varga Date: Wed, 20 Sep 2023 08:12:52 -0400 Subject: [PATCH] [wasi] Fix llvm target triple. (#92256) --- src/mono/mono/mini/mini-wasm.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/mono/mono/mini/mini-wasm.h b/src/mono/mono/mini/mini-wasm.h index 22c998018b59a..796b7a0069bdb 100644 --- a/src/mono/mono/mini/mini-wasm.h +++ b/src/mono/mono/mini/mini-wasm.h @@ -91,7 +91,11 @@ typedef struct { #define MONO_ARCH_HAS_REGISTER_ICALL 1 #define MONO_ARCH_HAVE_SDB_TRAMPOLINES 1 #define MONO_ARCH_LLVM_TARGET_LAYOUT "e-m:e-p:32:32-i64:64-n32:64-S128" +#ifdef TARGET_WASI +#define MONO_ARCH_LLVM_TARGET_TRIPLE "wasm32-unknown-wasi" +#else #define MONO_ARCH_LLVM_TARGET_TRIPLE "wasm32-unknown-emscripten" +#endif // sdks/wasm/driver.c is C and uses this G_EXTERN_C void mono_wasm_enable_debugging (int log_level);