cisco-open-source / qtwebdriver

WebDriver implementation for Qt
https://github.com/cisco-open-source/qtwebdriver/wiki
198 stars 59 forks source link

Can't build on windows for Qt 5.5.1 #14

Closed lsn793 closed 8 years ago

lsn793 commented 8 years ago

Hi, My configuration: Windows 7x64 Python 2.7.6 Qt 5.5.1 Visual Studio 2013

Created a configuration file wd.gypi

{ 'variables': { 'QT5': '1', # change to '0' to disable Qt5 'WD_CONFIG_QWIDGET_BASE': '1', # 1 to support widget or hybrid web 'WD_CONFIG_WEBKIT': '0', #1 to support Web views 'WD_CONFIG_QUICK': '0', #1 to support QML 'WD_BUILD_MONGOOSE': '1', #1 to inline mongoose code in WebDriver libraries. Leave as is. 'WD_CONFIG_PLAYER': '0', #For Qt5 only. If the Qt build includes QtMultimedia, then setting this field to 1 will enable to driving QMediaPlayer. See https://github.com/cisco-open-source/qtwebdriver/wiki/Media-Commands 'WD_CONFIG_ONE_KEYRELEASE': '0', # Set to 0 (default). On long key press WD will send as many key release as key press. If set to 1 only the final key release is sent 'QT_INC_PATH': 'C:/Qt/Qt-5.5.1-win32vs13/include', 'QT_BIN_PATH': 'C:/Qt/Qt-5.5.1-win32vs13/bin', 'QT_LIB_PATH': 'C:/Qt/Qt-5.5.1-win32vs13/lib' }, }

Ran build.bat

@ECHO OFF set PATH=%PATH%;C:\Users\zzzzz\Downloads\gyp python generate_wdversion.py gyp --depth . -G output_dir=. -D platform=desktop -D mode=release --generator-output=out/ wd.gyp

It generated me out dir with project files. Ran wd.sln in VS2013. Tried to build it and got errors same like this:

Error 1 error MSB6006: "CL.exe" exited with code -1073741701. C:\Program Files (x86)\MSBuild\Microsoft.Cpp\v4.0\V120\Microsoft.CppCommon.targets 341 5 WebDriver_core and also a lot of WARNINGS

Do you have any thoughts how to fix this?

hekra01 commented 8 years ago

1-There was an issue in you paths in the .gypi. It should be the paths to the x64 libs

{
  'variables': {
    'QT5%': '1',
    'WD_CONFIG_QWIDGET_BASE%': '1',
    'WD_CONFIG_WEBKIT%': '1',
    'WD_CONFIG_QUICK%': '1',
    'WD_BUILD_MONGOOSE%': '1',
    'WD_CONFIG_PLAYER%': '0',
    'WD_CONFIG_ONE_KEYRELEASE%': '0',

    'QT_BIN_PATH%': 'E:/Qt/Qt5.5.1/5.5/msvc2013_64/bin',
    'QT_INC_PATH%': 'E:/Qt/Qt5.5.1/5.5/msvc2013_64/include',
    'QT_LIB_PATH%': 'E:/Qt/Qt5.5.1/5.5/msvc2013_64/lib',
    'MONGOOSE_INC_PATH%': 'src/third_party/mongoose',  
  },
} 

2-I also fixed some build error on Qt5.5 with this commit https://github.com/cisco-open-source/qtwebdriver/commit/6705db23008eb255915f2758f4b930d1c02c7493

With this build succeeds