kripken / box2d.js

Port of Box2D to JavaScript using Emscripten
1.32k stars 198 forks source link

Rebuilt box2d.js much larger than checked in box2d.js #54

Closed mlogan closed 10 years ago

mlogan commented 10 years ago

I rebuilt box2d.js with emscripten 1.21.0 (installed via the SDK instructions at https://github.com/kripken/emscripten/wiki/Emscripten%20SDK), and the output file was about 893k. If I manually minify it with closure, it drops down to about 843k. The build checked in to this repository is 741k.

Any idea why my final build is so much larger? I don't really care much about the size of the file per se, I just want to make sure I'm not missing any optimizations in the build process.

Thanks.

mlogan commented 10 years ago

(sorry, accidentally closed the issue)

More info:

Do you build the checked in box2d.js file with just plain emmake make, or do you set any other options?

kripken commented 10 years ago

I just build with make, so yeah, that is odd...

kripken commented 10 years ago

I pushed a commit now with some more optimal build flags. Previous ones were from last year...

Build is now 653K, down from 724K.