(osx) Improve script to build bundle