[Qt-interest] distributing working qjpeg4.dll on Windows (missingdependencies)
David Ching
dc at remove-this.dcsoft.com
Wed Oct 14 00:46:03 CEST 2009
"Paul Miller" <paul at fxtech.com> wrote in message
news:4AD4CA31.3050906 at fxtech.com...
> I have built Qt 4.5.1 using VS 2005 SP 1, including qjpeg4.dll which I
> have included with my application. On my and several other machines, it
> works fine. But on some systems, qjpeg4.dll does not load.
>
> I looked at the dependencies using depends and it wants these DLLs:
>
> MSVCR80.DLL 8.0.50727.4053
> MSVCRT.DLL 7.0.2600.5512
>
> I am distributing the 8.0.50727.4053 MSVCR80.dll and associated manifest
> with my application, and the main app requires this and loads fine.
>
> However, I don't know why the plugin wants MSVCRT.DLL, and specifically
> the 7.0.2600.5512 version. The main Qt DLLs don't. And, I don't know which
> VS runtime includes this DLL.
>
> Has anyone encountered this and come up with a workaround?
>
Do you mean you are doing an app-local deployment and are putting the
MSVCR80.DLL in either the same directory as your .exe or in the
Microsoft.VC80.CRT\ folder? If so, you are supposed to build the Qt plugins
like qjpeg4.dll to have *no* manifest at all. Otherwise it will look for
the runtime DLL in the plugin folder, and it is not there, and that is why
it doesn't load. (I don't know why the manifest in your particular DLL
references MSVCRT.DLL 7.0.2600.5512, but the point is there shouldn't be any
manifest in the first place.)
See http://doc.trolltech.com/4.5/deployment-windows.html#qt-plugins:
---
If you are bundling the runtimes and need to deploy plugins as well, you
have to remove the manifest from the plugins (embedded as a resource) by
adding the following line to the .pro file of the plugins you are compiling:
CONFIG-=embed_manifest_dll
Warning: If you skip the step above, the plugins will not load on some
systems.
More information about the Qt-interest-old
mailing list