From: Brendan Hansen Date: Thu, 14 Dec 2023 14:53:28 +0000 (-0600) Subject: fixed: broken WASI builds due to `_initialize` X-Git-Url: https://git.brendanfh.com/?a=commitdiff_plain;h=fe499b97151dc3b82f20690d6d2529c6c771151f;p=onyx.git fixed: broken WASI builds due to `_initialize` --- 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