[Interest] Installation Sizes for Applications using Qt

Thiago Macieira thiago.macieira at intel.com
Mon Aug 30 20:48:16 CEST 2021


On Monday, 30 August 2021 10:32:03 PDT Henry Skoglund wrote:
> configure that has a "-skip xxxx" for all
> modules expect qtbase.

That makes zero difference in your final binary.

If you need a library that wasn't compiled, your application will fail to 
link. If you have a library that your application doesn't link to, it won't be 
linked to.

The convenience "-skip" option to the top-level configure is not at all the 
same as the feature system that we're discussing.

> When using MinGW 8.1.0 the .exe size is 19151 kB and when using MSVC2019
> it becomes 11616 kB, i.e. 40% smaller.

Do note that both QtCore and QtGui are compiled with -O3, which expands code 
size, when using GCC or Clang. There's no equivalent option to MSVC. You may 
want to disable this feature too and stick to -O2.

You may also want to optimise for size, at the expense of runtime performance. 
That's usually not worth it.

-- 
Thiago Macieira - thiago.macieira (AT) intel.com
  Software Architect - Intel DPG Cloud Engineering





More information about the Interest mailing list