|
cwist
Modern C web framework with libttak runtime
|
WASI (preview1) compatibility stubs for server-only subsystems. More...
Go to the source code of this file.
WASI (preview1) compatibility stubs for server-only subsystems.
The socket server runtime (reactor, parked writers, metrics) compiles into the WASI archive because request dispatch shares translation units with it, but a WASM host never binds sockets: the stubbed entry points are reachable at link time yet never executed. This mirrors how the Emscripten target satisfies the same references - through its system stub libraries (-lstubs, -lsockets) plus binaryen dead-code elimination - but expressed as plain C so the WASI link needs no post-processing.
pthread_* symbols come from wasi-sdk's libwasi-emulated-pthread; link with -lwasi-emulated-pthread.
Definition in file compat.c.