MCPcopy Create free account
hub / github.com/emscripten-core/emscripten / get_metadata

Function get_metadata

tools/emscripten.py:480–494  ·  view source on GitHub ↗
(infile, outfile, modify_wasm, args)

Source from the content-addressed store, hash-verified

478
479@ToolchainProfiler.profile()
480def get_metadata(infile, outfile, modify_wasm, args):
481 metadata = extract_metadata.extract_metadata(infile)
482 if modify_wasm:
483 # In some cases we still need to modify the wasm file
484 # using wasm-emscripten-finalize.
485 building.run_binaryen_command('wasm-emscripten-finalize',
486 infile=infile,
487 outfile=outfile,
488 args=args)
489 # When we do this we can generate new imports, so
490 # re-read parts of the metadata post-finalize
491 extract_metadata.update_metadata(outfile, metadata)
492 if DEBUG:
493 logger.debug("Metadata: " + pprint.pformat(metadata.__dict__))
494 return metadata
495
496
497def finalize_wasm(infile, outfile, js_syms):

Callers 2

emscriptFunction · 0.85
finalize_wasmFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected