[Qt-qml] How to deploy a QML app with WebView on a machine without a Qt installation?

Johan Paul johan.paul at gmail.com
Thu Jun 30 06:45:54 CEST 2011


>> It should be in the same dir as the qmlwebkitplugin.dll
>> ($QTINSTALLDIR/imports/QtWebKit). If you cannot find it, just create a
>> file named qmldir with contents as "plugin qmlwebkitplugin".
>
> Thank you very much! I will test this tomorrow when I am back at the
> office and let you know.

Hi Girish,

I tested copying the qmldir file to the folder where my
qmlwebkitplugin.dll is on the machine without Qt installed. However,
it did not change the outcome.. :-/ QML WebView is still not being
loaded.

However, this is not that surprising to me, now that I think of it.
The machine that has Qt installed did not have the qmldir file in the
plugin import location either, but the application could load the
plugin successfully anyway.

LoadLibraryW("D:\temp\demo\qmlimports\qmlwebkitplugin.dll") called
from "d:\temp\demo\QTCORE4.DLL" at address 0x6A2A8BE9.

(So dir qmlimports/ did not have qmldir in i. qmlimport/ is being
added to the QDeclarativeEngine:
m_dengine->addPluginPath(QCoreApplication::applicationDirPath() +
QLatin1String("/qmlimports/"));
m_dengine->addImportPath(QCoreApplication::applicationDirPath() +
QLatin1String("/qmlimports/"));
).

I can also see that the dependency chain goes qtcore4 ->
qmlwebkitplugin -> qtwebkit. So it really seems that the
qmlwebkitplugin.dll should be loaded anyway first before worrying
about other dependencies (this of course makes sense). I just can't
figure out why the plugin is not being loaded at this stage although
the path structure on both machines is the same and
qmlwebkitplugin.dll does not depend on any files that are from the Qt
installation location so it can't be because of that the plugin cannot
be loaded...

If you need any more information for this, just let me know.


Cheers,

Johan


>
>
> Cheers,
>
> Johan
>


More information about the Qt-qml mailing list