Once you got tired of reading and trying to comprehend Deploying an Application on Mac OS X in the Qt documentation, you realize at the bottom of the page that all you have to do is:
- Build your application in release mode
- Execute "macdeployqt myprog.app" (see -h for options)
This will bundle all the Qt libraries into the myprog.app - this will be approximately 40 MB. I guess one could still do the manual process for small applications that do not need all the Qt libraries. Or maybe the unnecessary libraries can be removed again manually?
To create a .dmg we can either use the -dmg option to macdeployqt or use the Mac Disk Utility as describe here or here (without the encryption part).
Application and package icon
During runtime the dock icon can be changed by calling QWidget::setWindowIcon() on the main window.
Including addition data
- ↑ Qt is Mac OS X Native
Bundle Programming Guide