1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-29 08:01:23 +03:00

Add JS infrastructure to ostensibly allow us to customize the wasm imports, which will hypothetically allow us to eliminate the dependency on EM_JS(), but the corresponding Emscripten glue-level feature currently breaks fatally with WASMFS builds so it's disabled.

FossilOrigin-Name: 88d9253b0db5494bf1c9b6d24f22524eeec856b89e64a66ffb30d945f0df21d3
This commit is contained in:
stephan
2022-09-29 22:08:22 +00:00
parent b0ccf50cbd
commit f71c954cbc
11 changed files with 123 additions and 36 deletions

View File

@ -57,10 +57,13 @@ SOAP.js := sqlite3-opfs-async-proxy.js
$(dir.fiddle)/$(SOAP.js): $(SOAP.js)
cp $< $@
$(eval $(call call-make-pre-js,fiddle-module))
$(fiddle-module.js): $(MAKEFILE) $(MAKEFILE.fiddle) \
EXPORTED_FUNCTIONS.fiddle EXPORTED_RUNTIME_METHODS.fiddle \
$(fiddle.cs) $(post-jses.deps) $(dir.fiddle)/$(SOAP.js)
$(emcc.bin) -o $@ $(fiddle.emcc-flags) $(fiddle.cs)
$(fiddle.cs) $(pre-post-fiddle.deps) $(dir.fiddle)/$(SOAP.js)
$(emcc.bin) -o $@ $(fiddle.emcc-flags) \
$(pre-post-common.flags) $(pre-post-fiddle.flags) \
$(fiddle.cs)
$(maybe-wasm-strip) $(fiddle-module.wasm)
gzip < $@ > $@.gz
gzip < $(fiddle-module.wasm) > $(fiddle-module.wasm).gz