Does it occur with all compilation flags? If you remove -O2 and/or --closure 1, does it still occur? How about if you add -g to the build?
2014-12-28 16:25 GMT+02:00 <[email protected]>: > Hi all, > > I am new to Emscripten, and am really impressed with it so far! The setup > procedure on Windows was smooth, and hello world built just fine. I wanted > to see if I could get audio working through SDL2,, so I downloaded the SDL2 > port by way of the automatic setup command. Then, I ran the following from > the Emscripten console: > > emcc loopwave.cpp -o loopwave.html -DNDEBUG --preload-file sample.wav -O2 > -s USE_SDL=2 --closure 1 > > loopwave.cpp is basically loopwave.c from the SDL distribution, pulled > from the repo so that I get the emscriptin loop etc. I only made one minor > change; making it so that sample.wav is always used and no command line > input is considered. The file can be found at: > https://dl.dropboxusercontent.com/u/5121962/loopwave.cpp > > sample.wav is here: > https://dl.dropboxusercontent.com/u/5121962/sample.wav > > The program compiled without errors, letting me know that it was using > SDL2. I uploaded all the files to the server (the HTML, the .js, the .mem > and the .data files), and tried running it in both Firefox and IE. In IE I > saw nothing, but in Firefox I received what looks like UTF-8 strings and > then a ton of exceptions. They are basically all the same, looking as > follows: > > "[post-exception status] Exception thrown, see JavaScript console"12 > loopwave.html:1245 > ReferenceError: Runtime is not defined > loopwave.js line 14 > eval:1 > "[post-exception status] Exception thrown, see JavaScript console" > loopwave.html:1245 > ReferenceError: Runtime is not defined > loopwave.js line 14 > eval:1 > "[post-exception status] Exception thrown, see JavaScript console"2 > loopwave.html:1245 > ReferenceError: Runtime is not defined2 > loopwave.js line 14 > eval:1 > "[post-exception status] Exception thrown, see JavaScript console" > loopwave.html:1245 > ReferenceError: Runtime is not defined > loopwave.js line 14 > eval:1 > > Etc. I have no idea what these errors mean, could anyone shed some light? > > Thanks in advance for any help! > > Kind regards, > > Philip Bennefall > > -- > 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]. > For more options, visit https://groups.google.com/d/optout. > -- 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]. For more options, visit https://groups.google.com/d/optout.
