Thanks for getting back. On Thu, Oct 13, 2022 at 7:29 PM 'Sam Clegg' via emscripten-discuss < [email protected]> wrote:
> Can you share the full link command you are using? > > So, we are trying to build the simple skia hello_world c++ app via wasm, to be playable inside the browser. We are trying to setup the SDL2 backend for skia with https://skia-review.googlesource.com/c/skia/+/573643 Here, is our build command for hello_world.wasm, which internally invokes emscripten toolchain *bazel build //example:hello_world_wasm --noincompatible_enable_cc_toolchain_resolution* Can you take a look at the generated JS file? Do you see the > `_embind_register_void` function in that file? It should be defined as a > function then added to the `asmLibraryArg` object which gets passed to > instantiate. > > The generated JS file ( https://gist.github.com/sohanjg/a38f509275b84279e98c097c81c9b5e2) doesnt have `_embind_register_void`. Also the originally generated files somehow wasn't able to load the wasm without throwing errors. So, we changed an existing simple emscripten generated helloworld.js (which was almost identical) to refer to the wasm generated by skia. cheers, > sam > > Br, Sohan > On Thu, Oct 13, 2022 at 7:30 AM Sohan Jyoti Ghosh <[email protected]> > wrote: > >> Hi ! >> >> I am getting errors while instantiating Array Buffer, >> * WebAssembly.instantiate(binary, info)* >> >> The error is, >> *"Uncaught (in promise) RuntimeError: Aborted(LinkError: >> WebAssembly.instantiate(): Import #1 module="env" >> function="_embind_register_void" error: function import requires a >> callable)"* >> >> Any pointers, how "env" obj is missing the function ? And how to resolve >> it ? I am using the JS template coming out of emscripten. >> Is there some error in building the .wasm ? Nothing is reported on the >> build log though. >> >> Br, >> Sohan >> >> -- >> You received this message because you are subscribed to the Google Groups >> "emscripten-discuss" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to [email protected]. >> To view this discussion on the web visit >> https://groups.google.com/d/msgid/emscripten-discuss/1b7778de-a61c-44fe-9b65-3479dfdbbc1dn%40googlegroups.com >> <https://groups.google.com/d/msgid/emscripten-discuss/1b7778de-a61c-44fe-9b65-3479dfdbbc1dn%40googlegroups.com?utm_medium=email&utm_source=footer> >> . >> > -- > You received this message because you are subscribed to the Google Groups > "emscripten-discuss" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/emscripten-discuss/CAL_va29KUrmS82TbqrzuGMU36fZDHdVpJsLG7fne2kg7o9CjqA%40mail.gmail.com > <https://groups.google.com/d/msgid/emscripten-discuss/CAL_va29KUrmS82TbqrzuGMU36fZDHdVpJsLG7fne2kg7o9CjqA%40mail.gmail.com?utm_medium=email&utm_source=footer> > . > -- You received this message because you are subscribed to the Google Groups "emscripten-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/emscripten-discuss/CAOtrQ7ys8aWVjkRXCgdyvYvucNkeUhA6BrKEHiUAyj3w7tCJyA%40mail.gmail.com.
