I am trying to build Qt 4.8.6 as a x64 static library by Visual Studio 2013 SP5 with webkit included, but I get this error after a few minutes of running nmake:
Generating Code...
lib /NOLOGO /OUT:..\..\lib\QtDeclarative.lib @C:\Users\Siavash\AppData\Local\Temp\nm3EA3.tmp qdeclarativeevents.obj : warning LNK4221: This object file does not define any previously undefined public symbols, so it will not be used by any link operation that consumes this library qlistmodelinterface.obj : warning LNK4221: This object file does not define any previously undefined public symbols, so it will not be used by any link operation that consumes this library
cd src\3rdparty\webkit\Source\ && C:\MSVS2013\VC\BIN\nmake.exe -f Makefile.WebKit
Microsoft (R) Program Maintenance Utility Version 12.00.21005.1 Copyright (C) Microsoft Corporation. All rights reserved.
cd JavaScriptCore\ && C:\MSVS2013\VC\BIN\nmake.exe -f Makefile.WebKit
Microsoft (R) Program Maintenance Utility Version 12.00.21005.1 Copyright (C) Microsoft Corporation. All rights reserved.
c:\Qt\4.8.6\bin\qmake.EXE -o Makefile.WebKit JavaScriptCore.pro
C:\MSVS2013\VC\BIN\nmake.exe -f Makefile.WebKit.Release
Microsoft (R) Program Maintenance Utility Version 12.00.21005.1 Copyright (C) Microsoft Corporation. All rights reserved.
cl -c -nologo -Zm200 -Zc:wchar_t- -FS -wd4291 -wd4344 -wd4396 -wd4503 -wd4800 -wd4819 -wd4996 -O2 -MD -GR -EHsc -DUNICODE -DWIN32 -DNDEBUG -DBUILDING_QT__=1 -DNDEBUG -DQT_ASCII_CAST_WARNINGS -D_HAS_TR1=0 -DBUILDING_JavaScriptCore -DBUILDING_WTF -DQT_NO_DEBUG -DQT_CORE_LIB -DQT_HAVE_MMX -DQT_HAVE_3DNOW -DQT_HAVE_SSE -DQT_HAVE_MMXEXT -DQT_HAVE_SSE2 -DQT_THREAD_SUPPORT -I"..\..\..\..\..\include\QtCore" -I"..\..\..\..\..\include" -I"." -I"..\..\Source" -I"..\ThirdParty" -I"assembler" -I"bytecode" -I"bytecompiler" -I"heap" -I"dfg" -I"debugger" -I"interpreter" -I"jit" -I"parser" -I"profiler" -I"runtime" -I"wtf" -I"wtf\gobject" -I"c:\Qt\4.8.6\src\3rdparty\webkit\Source\JavaScriptCore\wtf\symbian" -I"wtf\unicode" -I"yarr" -I"API" -I"ForwardingHeaders" -I"generated" -I"os-win32" -I"..\..\Source" -I"..\..\include" -I"\include\QtWebKit" -I"\include" -I"..\..\..\..\..\include\ActiveQt" -I"tmp\moc\release_static" -I"..\..\..\..\..\mkspecs\win32-msvc2013" -Fotmp\obj\release_static\ @C:\Users\Siavash\AppData\Local\Temp\nm4880.tmp DateMath.cpp
.\wtf/MathExtras.h(117) : error C2491: 'round' : definition of dllimport function not allowed
.\wtf/MathExtras.h(124) : error C2491: 'roundf' : definition of dllimport function not allowed
.\wtf/MathExtras.h(146) : error C2084: function 'bool signbit(double)' already has a body
C:\MSVS2013\VC\INCLUDE\math.h(324) : see previous definition of 'signbit'
c:\qt\4.8.6\src\3rdparty\webkit\source\javascriptcore\runtime\JSValueInlineMethods.h(168) : error C2264: 'signbit' : error in function definition or declaration; function not called dtoa.cpp
.\wtf/MathExtras.h(117) : error C2491: 'round' : definition of dllimport function not allowed
.\wtf/MathExtras.h(124) : error C2491: 'roundf' : definition of dllimport function not allowed
.\wtf/MathExtras.h(146) : error C2084: function 'bool signbit(double)' already has a body
C:\MSVS2013\VC\INCLUDE\math.h(324) : see previous definition of 'signbit' DecimalNumber.cpp
.\wtf/MathExtras.h(117) : error C2491: 'round' : definition of dllimport function not allowed
.\wtf/MathExtras.h(124) : error C2491: 'roundf' : definition of dllimport function not allowed
.\wtf/MathExtras.h(146) : error C2084: function 'bool signbit(double)' already has a body
C:\MSVS2013\VC\INCLUDE\math.h(324) : see previous definition of 'signbit' Generating Code...
NMAKE : fatal error U1077: 'C:\MSVS2013\VC\BIN\x86_amd64\cl.EXE' : return code '0x2' Stop.
NMAKE : fatal error U1077: 'C:\MSVS2013\VC\BIN\nmake.exe' : return code '0x2' Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2' Stop. NMAKE : fatal error U1077: 'cd' : return code '0x2' Stop.
This problem does not exist when I do not explicitly configure qt to build webkit, which will not be built otherwise, even if it is a default option. Also this is the configuration that I use:
configure -opensource -release -static -webkit -platform win32-msvc2013
I understand my problem might be similar to this one, but because Visual Studio 2013 is supported by Qt 4.8.6 I think this problem has a different reason. Furthermore, I have tried moving all of the necessary packages and even reinstalling VS to ensure that the PATHs that I use do not include any spaces or are not "too long". I have searched through so many guides and posts but nothing seems to help me with this. Is there something that I might be missing?