nwutils/nwjs-shell-builder

Binaries are gigantic.

ryanpcmcquen opened this issue · 5 comments

On my last build I ran out of disk space, because the resulting .zip files were between 30-40 GB for Linux and Mac builds. Is there a config I have messed up somewhere or has something changed in recent versions of nw.js (I am using 0.33.4). Here is my build script:
https://github.com/ryanpcmcquen/Simple/blob/master/build_desktop_apps.sh

He @ryanpcmcquen last build we used NW was 0.12 to tell the truth :(
I am not even sure this script is running.

Maybe try to wget https://github.com/Gisto/nwjs-shell-builder/archive/d4484401a9c5475e9cf9cdd36d3314e5111f5333.zip, I think this is last version I was able to build NW 0.12.

We've switched to electron for newer Gisto because NW was a hell to package. Feel free to ask if anything If I can I'll try to assist.

On macOS, one way to slim down would be to not have two separate copies at:

Contents/Versions/[version]/nwjs Framework.framework/Versions/A
Contents/Versions/[version]/nwjs Framework.framework/Versions/Current

In this case, Current should be a symlink to A.

On further inspection, there are actually three copies:

Contents/Versions/[version]/nwjs Framework.framework
Contents/Versions/[version]/nwjs Framework.framework/Versions/A
Contents/Versions/[version]/nwjs Framework.framework/Versions/Current

With the only difference being that the root version also contains:

libffmpeg.dylib
libnode.dylib

Which raises the question, is the Versions directory in the app build even needed?

@ryanpcmcquen @sanusart

The following commit may resolve your build bloat. My macOS builds on a very small project reduced by about 60%

ec64473

Resolved in #13