I have some problem when a try to build my code upon the 4.7.4 dynamic version. I have linkage error because of the 2 following lines :
Q_IMPORT_PLUGIN(qgif)
Q_IMPORT_PLUGIN(qjpeg)
To resolve the problem i just commented the above lines. Now everything compile correctly, which is strange. Does that mean that the code is not using the plugin (look a stupid question, but the project has several hundred thousand lines, i don,t know every part of it)
Question : What is the purpose of qgif and qjped plugin. Should i expect code using explicitly functions form these plugins?
I just want to be sure that i will not broke something by committing these lines…
You’ll only need those if you’re linking the plugins statically. Since you’re using the dynamic version, you don’t need them, and can safely leave them out. You simply need to place the plugin DLL or SO files adjacent executable. If you open up the installation where you installed the Qt libraries to (in my case, G:\Libraries\Qt\4.7.1), you’ll see a directory called ‘plugins’ which you can copy and paste into your project, adjacent to your executable.
As for the purpose of those plugins, they add support to QImage and the other Qt image related components for addition file formats so you can read and write, with varying levels of support. The level of support can be found here, under Reading and Writing Image Files.