I’ve been searching around and see that there are C libraries like wavm, wasmer, wasmtime, wasm3, that could probably work well with Zig but before diving into any of these, I ask if anyone has recommendations on embedding (running) wasm modules in a Zig program.
Not really an answer, but just wanted to note that Zig itself will have some interest in a WASM/WASI interpreter written in Zig for Run build.zig logic in a WebAssembly sandbox · Issue #14286 · ziglang/zig · GitHub
EDIT: The comments of that issue also have some links to two relevant projects:
3 Likes
Thanks a lot @squeek502 for these links. The issue is quite insightful and from looking over the two lined projects, I see zware
is more up-to-date and has a more intuitive API in my opinion. I’ll give it a try and see how it goes.
1 Like