summaryrefslogtreecommitdiff
path: root/scripts/spidermonkify.py
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/spidermonkify.py')
-rw-r--r--scripts/spidermonkify.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/scripts/spidermonkify.py b/scripts/spidermonkify.py
index d7b2ea138..623015fde 100644
--- a/scripts/spidermonkify.py
+++ b/scripts/spidermonkify.py
@@ -51,7 +51,11 @@ js = js.replace("'" + base_wast_target + "'", "'" + base_wasm_target + "'")
open(js_target, 'w').write(js)
shutil.copyfile(wast_target + '.mappedGlobals', wasm_target + '.mappedGlobals')
-# convert to binary using spidermonkey
+# convert to binary using spidermonkey, something like
+#mozjs -e 'os.file.writeTypedArrayToFile("moz.wasm",
+#new Uint8Array(wasmTextToBinary(os.file.readFile("test/hello_world.wast"))))'
+#investigate with
+#>>> map(chr, map(ord, open('moz.wasm').read()))
subprocess.check_call(
emscripten.shared.SPIDERMONKEY_ENGINE +
['-e', 'os.file.writeTypedArrayToFile("' + wasm_target +