3 ms·
The easiest way to compile C code to WebAssembly is by using Zig (https://ziglang.org https://ziglang.org): zig cc -target=wasm32-wasi and you’re done. Nothing
by jedisct1 5y ago
The easiest way to compile C code to WebAssembly is by using Zig (https://ziglang.org https://ziglang.org): zig cc -target=wasm32-wasi and you’re done. Nothing else to install. It is equally easy to cross-compile to another platform, against without installing anything else.
- puohufgh 5y agoThanks! I see that Zig is much more than just a programming language then; it has its own C compiler that addresses much of the toil of cross compiling C code.