Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Specify '-optimize-size' when building Qt6
This is a part of effort to further reduce Qt binary sizes (#822). As far as Qt binaries are concerned, we would prefer binary sizes over performance as these binaries are not used so often. This is rather important for universal binary build in macOS, where we literally bundle two binaries. This commit specify '-optimize-size' [1] when configuring Qt6. The overall results look OK-ish in macOS and rather impressive in Windows. macOS aarch64 release build QtCore: 6545752 -> 6354056 = -191696 QtGui: 8609112 -> 8237560 = -371552 QtWidgets: 7003272 -> 7136344 = +133072 -430176 Windows x64_64 release build Qt6Core.dll: 5982720 -> 5190656 = -792064 Qt6Gui.dll: 6276096 -> 4994048 = -1282048 Qt6Widgets.dll: 6099456 -> 5074432 = -1025024 -3099136 As '-optimize-size' is something that is officially supported in Qt, there is expected to be no observable behavior change. [1]: https://doc.qt.io/qt-6/configure-options.html#debug-and-release-builds PiperOrigin-RevId: 573731405
- Loading branch information