[Qt-interest] Resource difference between MSW7 and GNU/Linux ?

Penn Taylor penn.taylor at atdeconsulting.com
Fri Jun 25 23:07:56 CEST 2010


Images from icons.qrc turned into a cxx file via rcc and compiled into a 
dynamic library linked against at application linkage show up as 
available in Microsoft Windows and Mac OSX builds, but are unavailable 
on GNU/Linux.

I'm using 4.6.3 on Linux. I've tried Q_INIT_RESOURCES macro but it 
causes a linker error related to qInitResources_icons(). I can see from 
the build line that qrc_icons.os is being linked into the application, 
but get the linker error nonetheless.

Do resources have to have a prefix set to work with Q_INIT_RESOURCES? 
I'm unable to see any place that object code for qInitResources_icons 
would be generated since qrc_icons.cxx does not contain a function with 
this name, but instead contains

int QT_MANGLE_NAMESPACE(qInitResources)()
{
     QT_PREPEND_NAMESPACE(qRegisterResourceData)
         (0x01, qt_resource_struct, qt_resource_name, qt_resource_data);
     return 1;
}

Any suggestions?

-Penn Taylor



More information about the Qt-interest-old mailing list