Issue with building qtwebkit-opensource-src-5.7.1



  • Hi! I want to build WebKit module for Qt 5.7.1 and for Windows.

    I have installed Perl and downloaded qtwebkit-opensource-src-5.7.1.zip, extracted the archive:

    0_1504693999923_2017-09-06_133311.png

    Run VS2015 command prompt and run command: perl Tools\Scripts\build-webkit --qt --release

    I displays the error:

    'qmake' is not recognized as an internal or external command,
    operable program or batch file.
    ERROR: bison, gperf, win_flex missing but required to build WebKit.
    

    How to build it? Thanks in advance.


  • Moderators

    @Cobra91151
    i think it's better to let Qt make all the stuff.
    See this for a proper setup environment (Qt already ships bison, win_flex, etc -> gnuwin32\bin)

    then go to qtwebkit folder and run qmake and after that nmake



  • @raven-worx

    Hi! I have tried your solution, but it doesn't work.

    Error:
    0_1504707588257_2017-09-06_171908.png

    qt5vars

    @echo off
    
    REM Set up \Microsoft Visual Studio 2015, where <arch> is \c amd64, \c x86, etc.
    CALL "C:\Program Files\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" \c x86
    
    REM Edit this location to point to the source code of Qt
    SET _ROOT=C:\Qt
    
    SET PATH=%_ROOT%\qtbase\bin;%_ROOT%\gnuwin32\bin;%PATH%
    
    REM Uncomment the below line when using a git checkout of the source repository
    SET PATH=%_ROOT%\qtrepotools\bin;%PATH%
    
    REM Uncomment the below line when building with OpenSSL enabled. If so, make sure the directory points
    REM to the correct location (binaries for OpenSSL).
    REM SET PATH=C:\OpenSSL-Win32\bin;%PATH%
    
    REM When compiling with ICU, uncomment the lines below and change <icupath> appropriately:
    REM SET INCLUDE=<icupath>\include;%INCLUDE%
    REM SET LIB=<icupath>\lib;%LIB%
    REM SET PATH=<icupath>\lib;%PATH%
    
    REM Contrary to earlier recommendations, do NOT set QMAKESPEC.
    
    SET _ROOT=
    
    REM Keeps the command line open when this script is run.
    cmd /k
    


  • I have changed this line to: CALL "C:\Program Files\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" x86_amd64, and no error exists. But the same error: 'qmake' is not recognized as an internal or external command, operable program or batch file.



  • OK. I have set environment variable to C:\Qt\5.7\msvc2015\bin and run qmake on qtwebkit-opensource-src-5.7.1. But again the error:

    0_1504708520603_2017-09-06_173504.png



  • I have fixed it by setting SET SQLITE3SRCDIR=C:\Qt\5.7\Src\qtbase\src\3rdparty\sqlite. Then it throw the error again:

    0_1504717806190_2017-09-06_200954.png

    So I need to install all these software to finally build successfully? Thanks.



  • I have fixed the issues, but only one is still exists.

    0_1504726387904_2017-09-06_223208.png


  • Moderators

    @Cobra91151
    Qt ICU:

    configure -icu

    and make sure qt finds it. I see you have this in your script:

    REM When compiling with ICU, uncomment the lines below and change <icupath> appropriately:
    REM SET INCLUDE=<icupath>\include;%INCLUDE%
    REM SET LIB=<icupath>\lib;%LIB%
    REM SET PATH=<icupath>\lib;%PATH%
    

    remove it



  • @raven-worx

    Hi! I have run configure -icu and then jom to reconfigure Qt:

    0_1504771592251_2017-09-07_110558.png

    Waiting to the process to complete.



  • I get the errors:

    0_1504773622645_2017-09-07_113953.png

    I will try with nmake:

    0_1504773837080_2017-09-07_114312.png


  • Moderators

    @Cobra91151
    jom actually calls nmake...so you will get the same error.
    The strange thing here is. WTH do you build into C:\Windows\system32?!
    Something went wrong during your Qt configuration call.



  • @raven-worx

    Yes, you're right. I get the same error:

    0_1504775190876_2017-09-07_120624.png

    I will run nmake confclean command to clean old configurations.

    Then, I have created QtBuild directory (path: C:\QtBuild') navigate to that directory, run configure -icu and run jom.



  • It displays the error again:

    0_1504778222790_2017-09-07_125637.png

    I need to navigate to the Qt source dir and build there?

    Run configure -icu from C:\Qt\5.7\Src directory.

    And now jom:
    0_1504778908398_2017-09-07_130751.png

    And again errors:
    0_1504783257013_2017-09-07_142011.png

    I think configure -icu approach will not work.



  • From docs: https://wiki.qt.io/Building_Qt_5_from_Git#Configuring_Visual_Studio_2013_on_Windows_8.2C_8.1_.26_10

    ICU on Windows
    Qt 5 can make use of the ICU library for UNICODE and Localization support. This is required for building Qt WebKit. You can use pre-compiled versions of ICU with a Visual Studio 2010 dependency from the website, get pre-compiled versions for different compilers from download.qt.io, or compile ICU on your own.
    
    The absolute paths of include and lib folders of the ICU installation must be passed with -I and -L option to Qt's configure. In addition, uic.exe needs to find the ICU DLLs during compilation, for which the lib folder of the ICU installation must be added to the PATH environment variable.
    
    At run-time, the ICU DLLs need to be found. This can be achieved by copying the DLLs to the application folder or adding the lib folder of the ICU installation to the PATH environment variable.
    

    I get precompiled libs from the link only for VS 2013: http://download.qt.io/development_releases/prebuilt/icu/prebuilt/
    I think it will work.

    Nope. Even with these libs included to the PATH it doesn't work. The same error with ICU is required.

    I will uninstall Qt and then build it with the source with ICU.

    Edited:

    Again errors:

    0_1504797832553_2017-09-07_182325.png



  • Hi! Even when Qt was configured and compiled with ICU, QtWebKit module still can't find it and require ICU. So I think it's better to use qtwebkit_tp4_qt57_msvc2015_x86.zip (https://github.com/annulen/webkit/releases) and drop Win XP support in the application.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.