Details
-
Bug
-
Resolution: Unresolved
-
P2: Important
-
None
-
5.3.1
-
None
-
Windows 7 64-bit
Qt 5.3.1
Description
When deploying a Qt Application on Windows you need to provide all relevant DLL's and plugins along with the application. Therefore, you also need to provide the Windows platform plugin, i.e. under "<PATH_TO_MY_EXECUTABLE>/platforms/qwindows.dll". However, the default library path search order tries to load the platform plugins from the system folder first, and the files in this directory might not be the appropriate ones. If the files at this location can be found but do not correspond to the correct Qt version, this will lead to the message in the screenshot attached.
Printing the library path from my application gives the following output on my system:
qDebug() << "Library Paths: " << QCoreApplication::libraryPaths(); Library Paths: ("C:/Programme_x86/Qt5/5.3/mingw482_32/plugins", "C:/Users/franke/Code/build/build-LBliverec-Desktop_Qt_5_3_MinGW_32bit-Debug/debug")
I think the order should be the other way around, to make sure that the deployed platform plugins are loaded preferably, right?
I can workaround this problem by providing a qt.conf file along with my application containing the following code:
[Paths] Plugins = .
However, I think this file should not be needed if we simply change the order of the library paths.