<< gamekit goes browser | Home | Wood Games 3D is offline :( >>

Trapped in Emscripten?

Just started trying to port gamekit to emscripten. Beyond other problems I struggled on swig generated lua-layer which threw a for me cryptic “trapped”-exception in the ‘SWIG_Lua_namespace_register’-function.

To make the long story short. Swig 2.0.11 created invalid code with int SWIG_Lua_namespace_register(..) function that did not return a value, which seemed to be the problem. Adding a return 1; manually at the two problematic function fixed the problem.

For a happy ending for this specific problem it was sufficient to upgrade to swig3.0.3…


Actually swig3 seems to have changed its way of how inhertitance is handled, which somehow broke inheritance of methods at all!? Using the swig-switch -squash-bases let you use the old way, but this brought back the emscripten-problems :D. Ok, there seems no way around to fix it in swig itself.


Very cool, posted a pull-request on the swig-changes and they got merged immediately :D

Export this post as PDF document  Export this post to PDF document

Social Bookmarks :  Add this post to Slashdot    Add this post to Digg    Add this post to Reddit    Add this post to Delicious    Add this post to Stumble it    Add this post to Google    Add this post to Technorati    Add this post to Bloglines    Add this post to Facebook    Add this post to Furl    Add this post to Windows Live    Add this post to Yahoo!