From fe499b97151dc3b82f20690d6d2529c6c771151f Mon Sep 17 00:00:00 2001 From: Brendan Hansen Date: Thu, 14 Dec 2023 08:53:28 -0600 Subject: [PATCH] fixed: broken WASI builds due to `_initialize` --- core/runtime/common.onyx | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/core/runtime/common.onyx b/core/runtime/common.onyx index 471b0a38..07fd0b1a 100644 --- a/core/runtime/common.onyx +++ b/core/runtime/common.onyx @@ -9,12 +9,14 @@ use runtime.platform { __output_string } // Every platform should define this, even if is it just '() {}'. #export "_start" platform.__start -// -// Export a common initialization procedure that should -// always be invoked before using anything in Onyx. -#export "_initialize" () { - __runtime_initialize(); - context.thread_id = 0; +#if runtime != .Wasi { + // + // Export a common initialization procedure that should + // always be invoked before using anything in Onyx. + #export "_initialize" () { + __runtime_initialize(); + context.thread_id = 0; + } } #local -- 2.25.1