error: cannot find -lQt5WebKitWidgetsd, cannot find -lQt5WebKitd

  • I installed Qt-5.8.0 with MinGW-5.3.0 (32-bit) compiler on my Windows 10.
    Then I unpacked from [] to $my_Qt_installation_path$\5.8\mingw53_32.

    When I tried to compile simple code which used QWebView (I added in .pro "QT += webkitwidgets"), I got the next compilation error:

    D:/PROGRAMS/QT/Tools/mingw530_32/bin/mingw32-make -f Makefile.Debug
    mingw32-make[1]: Entering directory 'D:/QT_projects/ISO/chapter46/build-SimpleView-Desktop_Qt_5_8_0_MinGW_32bit-Debug'
    g++ -c -pipe -fno-keep-inline-dllexport -g -std=gnu++11 -frtti -Wall -Wextra -fexceptions -mthreads -DUNICODE -DQT_QML_DEBUG -DQT_WEBKITWIDGETS_LIB -DQT_WIDGETS_LIB -DQT_WEBKIT_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_NEEDS_QMAIN -I..\SimpleView -I. -I..\..\..\..\PROGRAMS\QT\5.8\mingw53_32\include -I..\..\..\..\PROGRAMS\QT\5.8\mingw53_32\include\QtWebKitWidgets -I..\..\..\..\PROGRAMS\QT\5.8\mingw53_32\include\QtWidgets -I..\..\..\..\PROGRAMS\QT\5.8\mingw53_32\include\QtWebKit -I..\..\..\..\PROGRAMS\QT\5.8\mingw53_32\include\QtGui -I..\..\..\..\PROGRAMS\QT\5.8\mingw53_32\include\QtANGLE -I..\..\..\..\PROGRAMS\QT\5.8\mingw53_32\include\QtNetwork -I..\..\..\..\PROGRAMS\QT\5.8\mingw53_32\include\QtCore -Idebug -I..\..\..\..\PROGRAMS\QT\5.8\mingw53_32\mkspecs\win32-g++  -o debug\main.o ..\SimpleView\main.cpp
    g++ -Wl,-subsystem,windows -mthreads -o .\SimpleView.exe debug/main.o  -lmingw32 -LD:\PROGRAMS\QT\5.8\mingw53_32\lib D:\PROGRAMS\QT\5.8\mingw53_32\lib\libqtmaind.a -LC:\utils\my_sql\my_sql\lib -LC:\utils\postgresql\pgsql\lib -lshell32 -lQt5WebKitWidgetsd D:\PROGRAMS\QT\5.8\mingw53_32\lib\libQt5Widgetsd.a -lQt5WebKitd D:\PROGRAMS\QT\5.8\mingw53_32\lib\libQt5Guid.a D:\PROGRAMS\QT\5.8\mingw53_32\lib\libQt5Networkd.a D:\PROGRAMS\QT\5.8\mingw53_32\lib\libQt5Cored.a 
    D:/PROGRAMS/QT/Tools/mingw530_32/bin/../lib/gcc/i686-w64-mingw32/5.3.0/../../../../i686-w64-mingw32/bin/ld.exe: cannot find -lQt5WebKitWidgetsd
    D:/PROGRAMS/QT/Tools/mingw530_32/bin/../lib/gcc/i686-w64-mingw32/5.3.0/../../../../i686-w64-mingw32/bin/ld.exe: cannot find -lQt5WebKitd
    collect2.exe: error: ld returned 1 exit status

    I think I should configure path to some Qt5WebKit libraries, but I have no idea where and how. Thanks in advance.

  • Lifetime Qt Champion


    QtWebkit has been deprecated and then removed since Qt 5.6.

    If you'd like to go with it you have to build it yourself, however you should go with the latest branch based on @Konstantin-Tokarev reboot of the module.

    Otherwise, you can also take a look at the QtWebEngine module.

  • @SGaist It's awful... To use QWebKit I should build it with MSVC, to use QWebEngine I should install MSVC. Why I have no way to stay on tiny mingw... Or I have to start with QML to use QWebEngine.

    I downloaded binaries from @Konstantin-Tokarev github repo, I thought they should work.

  • Lifetime Qt Champion

    AFAIK, QtWebKit can be build with MinGW.

    As for QtWebEngine, Qt can only follow the restrictions set by the Chromium project.

  • @SGaist then why QWebKit was deprecated? I think if chromium is not available with other compilers, it should have an analog for them.

  • Lifetime Qt Champion

    The reasoning of QtWebEngine can be found here.

Log in to reply