External resource in pro file
-
wrote on 7 Jan 2012, 16:37 last edited by
How can I add external resource in file? For example in pro file I have:
@
RESOURCES = application.qrc
@
Then a resource will be build-in application, but I want to use an external resource. So my problem is:
How add resource to pro file that making a project will generate a application.rcc and copy it to binary folder? Then I would use this resource by code:
@
QResource::registerResource("/path/to/my/app/application.rcc");
@Sorry for my eng.
-
wrote on 7 Jan 2012, 23:54 last edited by
You can add the generation in a QMAKE_POST_LINK step. Or put the rcc call and the copy step into a script and add this as QMAKE_POST_LINK.
-
wrote on 8 Jan 2012, 10:54 last edited by
Thanx for reply. You confirm my idea to create a script which will run rcc and copy resource to folder with application binary. I made a prototype script in python.
2/3