[Qt-interest] conditional resource inclusion
pmqt71
pmqt71 at gmail.com
Thu Jan 13 00:48:18 CET 2011
I'm not compiling/linking all the .qrc in the application, but only
the one for the specific platform.
For instance, the desktop version will have 100 icons, the mobile 10.
bye
pm
2011/1/13 Arnold Krille <arnold at arnoldarts.de>:
> On Wednesday 12 January 2011 21:31:48 pmqt71 wrote:
>> My goal is to reduce the executable footprint for mobile platforms and
>> I was looking for a way to have only 1 resource file.
>> As it is not possible, I'm going to use more .qrc files with
>> conditional inclusion, for instance:
>>
>> win32 {
>> RESOURCES += \
>> win32.qrc
>> }
>>
>> symbian {
>> RESOURCES += \
>> symbian.qrc
>> }
>>
>
> Please understand that only the resources you include take up space, not the
> fact whether these resources come from one, two or 42 resource-files...
>
> Which is what we try to tell you and which you seem to not understand.
>
> Maybe a comparison will show it: Whether you define all classes in one file or
> have one file per class doesn't matter for the resulting executable/library.
> There will be differences in compile-time. But the resulting binary is the same
> once the linker is finished. And all stuff you define as qt-resources ends up in
> char* constants. Doesn't matter whether there is one .c-file and one .o-file per
> constant or one object for all, the linker will link it all together...
>
> Arnold
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at qt.nokia.com
> http://lists.qt.nokia.com/mailman/listinfo/qt-interest
>
>
More information about the Qt-interest-old
mailing list