estraier / tkrzw

a set of implementations of DBM
Apache License 2.0
164 stars 20 forks source link

WASM / Emscripten Build? #40

Closed justin0mcateer closed 1 year ago

justin0mcateer commented 1 year ago

Any ideas as to how easy or difficult this would be to compile to WASM using Emscripten?

estraier commented 1 year ago

Tkrzw uses POSIX API on UNIX-like systems and Windows API on Windows. Both two depend on their OSes respectively so Tkrzw is not portable in that sense. However, Tkrzw has a mode to simulate them with the C++17 API. If you set --enable-stdonly for configure, you can check the behavior. If Emscripten supports C++17 fully, compiling Tkrzw for WASM is technically possible. As I'm not knowledgeable about WASM or Emscipten, I don't know the actual workload, though.