Failed to build qt5.2.1 static with MSVC 2010 x86 - qt

I've got Win 7 x64 and i am trying to build static qt5.2.1 from source winth MSVC 2010 x86.
The problem is
Generating Code...
link /NOLOGO /DYNAMICBASE /NXCOMPAT /INCREMENTAL:NO /SUBSYSTEM:WINDOWS "
/MANIFESTDEPENDENCY:type='win32' name='Microsoft.Windows.Common-Controls' versio
n='6.0.0.0' publicKeyToken='6595b64144ccf1df' language='*' processorArchitecture
='*'" /MANIFEST /MANIFESTFILE:release\musicplayer.exe.embed.manifest /OUT:releas
e\musicplayer.exe #C:\Users\AuST\AppData\Local\Temp\nm7949.tmp
Creating library release\musicplayer.lib and object release\musicplayer.exp
mt.exe /nologo /manifest release\musicplayer.exe.embed.manifest /outputr
esource:release\musicplayer.exe;1
cd quickplayer\ && ( if not exist Makefile E:\Lib\qt521static\qtbase\bin
\qmake E:\Lib\qt521static\qtwinextras\examples\winextras\quickplayer\quickplayer
.pro -o Makefile ) && "C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\BI
N\nmake.exe" -f Makefile
Project ERROR: Plugin qml_winextras is missing a classname entry, please add one
to the qmldir file.
NMAKE : fatal error U1077: 'cd' : return code '0x3'
Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2'
Stop.
What can i do to fix this?

Just in case someone runs into the same issue, not compiling the examples will not work, although it seems an obvious solution. After comparing .qmake.conf in qtwinextras and in another module's directory, I added the following lines to the .qmake.conf (seems like there is a bug with configure for this module):
CONFIG += qt_example_installs
CONFIG += warning_clean
After that, compilation went on fine--of course without examples.

Related

qwt cannot build Windows 8 64 bit

I have installed Qt5.5.1 on Windows 8 and the compiler is MSVC2013 64 bit, now I need to integrate qwt with Qt
I am following the instruction here, as a first step downloaded qwt source and extracted it, then opened Qt5.5 64bit(MASVC 2013) command prompt and run the command
C:\Qt\Qt5.5.1\5.5\msvc2013_64\bin\qmake.exe qwt.pro
Which end with no error.
Now I open Visual studio x64 Win64 Command prompt(2010) and run
nmake
Which give following error
Setting environment for using Microsoft Visual Studio 2010 x64 tools.
C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC>E:
E:\>cd
E:\
E:\>cd Software\Qt\QWT\qwt-6.1.1
E:\Software\Qt\QWT\qwt-6.1.1>nmake
Microsoft (R) Program Maintenance Utility Version 10.00.30319.01
Copyright (C) Microsoft Corporation. All rights reserved.
cd src\ && ( if not exist Makefile C:\Qt\Qt5.5.1\5.5\msvc2013_64\bin\qma
ke.exe E:\Software\Qt\QWT\qwt-6.1.1\src\src.pro -o Makefile ) && "C:\Program Fil
es (x86)\Microsoft Visual Studio 10.0\VC\BIN\amd64\nmake.exe" -f Makefile
Microsoft (R) Program Maintenance Utility Version 10.00.30319.01
Copyright (C) Microsoft Corporation. All rights reserved.
"C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\BIN\amd64\nmake.
exe" -f Makefile.Release all
Microsoft (R) Program Maintenance Utility Version 10.00.30319.01
Copyright (C) Microsoft Corporation. All rights reserved.
compiling .\qwt_abstract_scale_draw.cpp .\qwt_clipper.cpp .\qwt_color_map.cpp .\
qwt_column_symbol.cpp .\qwt_date.cpp .\qwt_date_scale_draw.cpp .\qwt_date_scale_
engine.cpp .\qwt_dyngrid_layout.cpp .\qwt_event_pattern.cpp .\qwt_graphic.cpp .\
qwt_interval.cpp .\qwt_interval_symbol.cpp .\qwt_math.cpp .\qwt_magnifier.cpp .\
qwt_null_paintdevice.cpp .\qwt_painter.cpp .\qwt_painter_command.cpp .\qwt_panne
r.cpp .\qwt_picker.cpp .\qwt_picker_machine.cpp .\qwt_pixel_matrix.cpp .\qwt_poi
nt_3d.cpp .\qwt_point_polar.cpp .\qwt_round_scale_draw.cpp .\qwt_scale_div.cpp .
\qwt_scale_draw.cpp .\qwt_scale_map.cpp .\qwt_spline.cpp .\qwt_scale_engine.cpp
.\qwt_symbol.cpp .\qwt_system_clock.cpp .\qwt_text_engine.cpp .\qwt_text_label.c
pp .\qwt_text.cpp .\qwt_transform.cpp .\qwt_widget_overlay.cpp .\qwt_curve_fitte
r.cpp .\qwt_abstract_legend.cpp .\qwt_legend.cpp .\qwt_legend_data.cpp .\qwt_leg
end_label.cpp .\qwt_plot.cpp .\qwt_plot_renderer.cpp .\qwt_plot_xml.cpp .\qwt_pl
ot_axis.cpp .\qwt_plot_curve.cpp .\qwt_plot_dict.cpp .\qwt_plot_directpainter.cp
p .\qwt_plot_grid.cpp .\qwt_plot_histogram.cpp .\qwt_plot_item.cpp .\qwt_plot_ab
stract_barchart.cpp .\qwt_plot_barchart.cpp .\qwt_plot_multi_barchart.cpp .\qwt_
plot_intervalcurve.cpp .\qwt_plot_zoneitem.cpp .\qwt_plot_tradingcurve.cpp .\qwt
_plot_spectrogram.cpp .\qwt_plot_spectrocurve.cpp .\qwt_plot_scaleitem.cpp .\qwt
_plot_legenditem.cpp .\qwt_plot_seriesitem.cpp .\qwt_plot_shapeitem.cpp .\qwt_pl
ot_marker.cpp .\qwt_plot_textlabel.cpp .\qwt_plot_layout.cpp .\qwt_plot_canvas.c
pp .\qwt_plot_panner.cpp .\qwt_plot_rasteritem.cpp .\qwt_plot_picker.cpp .\qwt_p
lot_zoomer.cpp .\qwt_plot_magnifier.cpp .\qwt_plot_rescaler.cpp .\qwt_point_mapp
er.cpp .\qwt_raster_data.cpp .\qwt_matrix_raster_data.cpp .\qwt_sampling_thread.
cpp .\qwt_series_data.cpp .\qwt_point_data.cpp .\qwt_scale_widget.cpp .\qwt_plot
_svgitem.cpp .\qwt_plot_glcanvas.cpp .\qwt_abstract_slider.cpp .\qwt_abstract_sc
ale.cpp .\qwt_arrow_button.cpp .\qwt_analog_clock.cpp .\qwt_compass.cpp .\qwt_co
mpass_rose.cpp .\qwt_counter.cpp .\qwt_dial.cpp .\qwt_dial_needle.cpp .\qwt_knob
.cpp .\qwt_slider.cpp .\qwt_thermo.cpp .\qwt_wheel.cpp
cl : Command line error D8021 : invalid numeric argument '/FS'
NMAKE : fatal error U1077: 'echo' : return code '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 10.0
\VC\BIN\amd64\nmake.exe"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2'
Stop.
E:\Software\Qt\QWT\qwt-6.1.1>
What could be the issue, my Qt using MSVC2013 64 bit compiler and where as I running nmake using visual studio 2010 command prompt. Could that be the issue?
If so do I need to install Visual studio 2013?
I also tried jom using the command
C:\Qt\Qt5.5.1\Tools\QtCreator\bin\jom.exe -j12
Which also end up with some error.
Any help will be appreciated,
Thanks
Haris
you need to open the command prompt like administrator.
And for be available to use the plugins, need to compile qwt in the same compiler that Qt Creator.

Building QtWebEngine: invalid directive: '%param'

Trying to build QtWebEngine from current sources(git clone git://code.qt.io/qt/qt5.git qt5) followed this instructions https://wiki.qt.io/QtWebEngine_on_Windows, faced with problem where compilation breaks with this error message:
(set PATH=F:/webengine/qt5/gnuwin32/bin;%PATH:)=^)%) & win_bison --no-lines --skeleton=yacc.c --defines=glslang_tab.h --output=glslang_tab.cpp ..\..\..\3rdparty\angle\src\compiler\translator\glslang.y
..\\..\\..\\3rdparty\\angle\\src\\compiler\\translator\\glslang.y:48.1-6: error: invalid directive: '%param'
..\\..\\..\\3rdparty\\angle\\src\\compiler\\translator\\glslang.y:48.10-24: error: syntax error, unexpected {...}
NMAKE : fatal error U1077: '(set' : return code '0x1'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\BIN\amd64\nmake.EXE"' : return code '0x2'
Tried to google it, with no luck.
Please help!

Building Qt 5.4.0 with ICC 15.0 Fails

As the title reads, ICC is apparently giving me some issues while compiling Qt 5.4.0 from source. Before trying this, I made a successful static build of Qt using msvc2013 and a copy of the same source files I am using for the ICC build (no static linking modifications on the mkspecs file for the ICC build, of course), and tested it with no issues.
The fact that it gave me no issues on one compiler but it is giving me issues now is why I've come to ask for any sort of help regarding the issue. The Build log is as follows:
C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include\d3d11.h(6050):warning #597: "CD3D11_QUERY_DESC::operator const D3D11_QUERY_DESC &() const" will not be called for implicit or explicit conversions
operator const D3D11_QUERY_DESC&() const { return *this; }
^
C:\Program Files (x86)\Microsoft DirectX SDK (June 2010)\Include\d3d11.h(6384):warning #597: "CD3D11_COUNTER_DESC::operator const D3D11_COUNTER_DESC &() const"
will not be called for implicit or explicit conversions
operator const D3D11_COUNTER_DESC&() const { return *this; }
^
C:\Program Files (x86)\Windows Kits\8.1\include\shared\dxgi1_2.h(1271): error: identifier "DXGI_RGBA" is undefined
_In_ const DXGI_RGBA *pColor) = 0;
^
C:\Program Files (x86)\Windows Kits\8.1\include\shared\dxgi1_2.h(1275): error: identifier "DXGI_RGBA" is undefined
_Out_ DXGI_RGBA *pColor) = 0;
^
../../../3rdparty/angle/src/common/mathutil.h(28): remark #3280: declaration hides member "gl::Vector4::x" (declared at line 30)
Vector4(float x, float y, float z, float w) : x(x), y(y), z(z), w(w) {}
^
../../../3rdparty/angle/src/common/mathutil.h(28): remark #3280: declaration hides member "gl::Vector4::y" (declared at line 31)
Vector4(float x, float y, float z, float w) : x(x), y(y), z(z), w(w) {}
^
../../../3rdparty/angle/src/common/mathutil.h(28): remark #3280: declaration hides member "gl::Vector4::z" (declared at line 32)
Vector4(float x, float y, float z, float w) : x(x), y(y), z(z), w(w) {}
^
../../../3rdparty/angle/src/common/mathutil.h(28): remark #3280: declaration hides member "gl::Vector4::w" (declared at line 33)
Vector4(float x, float y, float z, float w) : x(x), y(y), z(z), w(w) {}
^
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Intel\Composer XE 2015\bin\intel64\icl.EXE"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 12.0\VC\BIN\amd64\nmake.exe"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2'
Stop.
C:\Qt\Qt5.4.0-Intel\5.4\Src>
The first two warnings are just a couple from a bunch of warnings that looked pretty much just like those, so I just included those two seeing as most of the build process consisted of throwing a behemoth amount of warnings every 3 seconds and for every file. ICC paranoia, I presume.
What throws me off a little bit is the fact that the build log presents more warnings after the "identifier undefined" error, so I am unsure if that would be the error causing the build to fail or not. If that IS the issue, any idea on what might be causing it and why the msvc2013 build didn't struggle with it?
Differences between builds:
ICC, from Intel x64 Console:
>cd C:\Qt\Qt5.4.0-Intel\5.4\Src
>configure -mp -debug-and-release -angle -nomake tests -nomake examples -prefix C:\Qt\Qt5.4.0-Intel\5.4\ICC_64 -platform win32-icc
>nmake
Didn't modify any of the mkspecs files.
MSVC2013, from VS x64 Console:
>cd C:\Qt\QtSource\Src
>configure -mp -debug-and-release -static -angle -nomake tests -nomake examples -prefix C:\Qt\Qt5.4.0\5.4\msvc2013_64_opengl -platform win32-msvc2013
>nmake
>nmake -install
Modified win32-msvc2013 qmake.conf for static build.

How to compile Qt with embeddedVisualC++ 4.0?

Is it possible to compile Qt for WindowsCE 5.0 using embeddedVisualC++ 4.0 instead of MSVC 2005? I tried by following the official tutorial but couldn't get it to work.
The 'configure' script runs without errors, but when calling nmake to actually build the libraries, I get the following errors:
E:\QT\SDK\QtSources\4.8.0.ce>nmake
Microsoft (R) Program Maintenance Utility Version 6.00.8168.0
Copyright (C) Microsoft Corp 1988-1998. All rights reserved.
cd src\winmain\ && NMAKE -f Makefile
Microsoft (R) Program Maintenance Utility Version 6.00.8168.0
Copyright (C) Microsoft Corp 1988-1998. All rights reserved.
NMAKE -f Makefile.Debug all
Microsoft (R) Program Maintenance Utility Version 6.00.8168.0
Copyright (C) Microsoft Corp 1988-1998. All rights reserved.
cl -c -nologo -Zm200 -Zc:wchar_t- -DDEBUG -D_DEBUG -Zi -MDd -W3 -w34100 -w34189 -EHs-c- -DQT_THREAD_SUPPORT -DUNDER_CE -DWINCE -D_WINDOWS -D_UNICODE -DUNICODE -D_WIN32 -DQT_NO_PRINTER -DQT_NO_PRINTDIALOG -DSTANDARDSHELL_UI_MODEL -D_WIN32_WCE=0x500 -DARMV4I -D_ARMV4I_ -Darmv4i -D_ARM_ -DARM -D_M_ARM -DARM -D__arm__ -DQ_OS_WINCE_STD -DQT_NO_PRINTER -DQT_NO_PRINTDIALOG -DQT_NO_CAST_TO_ASCII -DQT_ASCII_CAST_WARNINGS -DQT_MOC_COMPAT -DQT_USE_QSTRINGBUILDER -D_USE_MATH_DEFINES -DQT_NO_DYNAMIC_CAST -I"..\..\include" -I"tmp" -I"..\..\include\QtCore" -I"e:\QT\SDK\QtSources\4.8.0.ce\include\qtmain" -I"tmp\rcc\debug_shared" -I"tmp" -I"..\..\include\ActiveQt" -I"tmp\moc\debug_shared" -I"e:\QT\SDK\QtSources\4.8.0\src\winmain" -I"." -I"e:\QT\SDK\QtSources\4.8.0\mkspecs\wince50standard-armv4i-msvc2005" -Fotmp\obj\debug_shared\ #C:\Users\XYZ\AppData\Local\Temp\nma02104.
Command line warning D4002 : ignoring unknown option '-Zc'
Command line warning D4002 : ignoring unknown option '-Z:'
Command line warning D4002 : ignoring unknown option '-Zw'
Command line warning D4002 : ignoring unknown option '-Zc'
Command line warning D4002 : ignoring unknown option '-Zh'
Command line warning D4002 : ignoring unknown option '-Zr'
Command line warning D4002 : ignoring unknown option '-Z_'
Command line warning D4002 : ignoring unknown option '-Zt'
Command line warning D4002 : ignoring unknown option '-Z-'
Command line warning D4002 : ignoring unknown option '-w34100'
Command line warning D4002 : ignoring unknown option '-w34189'
qtmain_win.cpp
E:\Microsoft SDKs\Windows CE Tools\wce500\STANDARDSDK_500\Include\ARMV4I\winnt.h(383) : error C2467: illegal declaration of anonymous 'struct'
E:\Microsoft SDKs\Windows CE Tools\wce500\STANDARDSDK_500\Include\ARMV4I\winnt.h(402) : error C2467: illegal declaration of anonymous 'struct'
E:\Microsoft SDKs\Windows CE Tools\wce500\STANDARDSDK_500\Include\ARMV4I\winnt.h(6040) : error C2467: illegal declaration of anonymous 'struct'
E:\Microsoft SDKs\Windows CE Tools\wce500\STANDARDSDK_500\Include\ARMV4I\winnt.h(6049) : error C2467: illegal declaration of anonymous 'struct'
E:\Microsoft SDKs\Windows CE Tools\wce500\STANDARDSDK_500\Include\ARMV4I\winnt.h(6746) : error C2133: 'pEventLogRecords' : unknown size
E:\Microsoft SDKs\Windows CE Tools\wce500\STANDARDSDK_500\Include\ARMV4I\winnt.h(6752) : error C2133: 'ulOffsets' : unknown size
E:\Microsoft SDKs\Windows CE Tools\wce500\STANDARDSDK_500\Include\ARMV4I\winbase.h(1130) : error C2467: illegal declaration of anonymous 'struct'
E:\Microsoft SDKs\Windows CE Tools\wce500\STANDARDSDK_500\Include\ARMV4I\kfuncs.h(109) : error C2144: syntax error : missing ';' before type 'void'
E:\Microsoft SDKs\Windows CE Tools\wce500\STANDARDSDK_500\Include\ARMV4I\kfuncs.h(109) : error C2501: '_inline' : missing storage-class or type specifiers
E:\Microsoft SDKs\Windows CE Tools\wce500\STANDARDSDK_500\Include\ARMV4I\kfuncs.h(109) : fatal error C1004: unexpected end of file found
NMAKE : fatal error U1077: 'cl' : return code '0x2'
Stop.
NMAKE : fatal error U1077: '"E:\Microsoft SDKs\Microsoft eMbedded C++ 4.0\COMMON\EVC\bin\NMAKE.EXE"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2'
Stop.
Can you verify you have Service Pack 4 installed for eVC? That adds support for Windows CE 5.0.
Next, try creating a project using the eVC wizard of the same type as your QT project that targets the Windows CE 5.0 SDK. Copy the compiler and linker settings from that wizard-created project to your QT project.
Also make sure you don't have language extensions disabled. Try adding -Ze to your compiler flags
-PaulH

Qt Opengl configuration for Windows CE

I am trying to configure Qt using the OpenGL parameter for a custom WinCE SDK, but I get a compiler error. I found a similar error faced in the http://www.qtcentre.org/threads/37052-WinCE-OpenGL-ES-build-error?s=7aa5ac49753e1c3f1e0b624bb9134faa post.
The link says to install OpenGL SDK from Imagination Technology, link the library, and include the file to solve the error.
When I tried the mentioned steps, I got linker errors.
link /LIBPATH:"c:\Qt\4.7.4_2\lib" /LIBPATH:"c:\Qt\4.7.4_2\lib" /NOLOGO /
NODEFAULTLIB:OLDNAMES.LIB /DEBUG /SUBSYSTEM:WINDOWSCE,6.00 /MACHINE:THUMB /DLL /
SAFESEH:NO /VERSION:4.74 /OUT:....\lib\QtGuid4.dll #C:\DOCUME~1\VARUN~1.JAJ\LOC
ALS~1\Temp\nm8796.tmp
Creating library ....\lib\QtGuid4.lib and object ....\lib\QtGuid4.exp
qegl.obj : error LNK2019: unresolved external symbol __imp_eglBindAPI referenced
in function "public: bool __cdecl QEglContext::createContext(class QEglContext
*,class QEglProperties const *)" (?createContext#QEglContext##QAA_NPAV1#PBVQEglP
roperties###Z)
....\lib\QtGuid4.dll : fatal error LNK1120: 1 unresolved externals
NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 8\VC\ce\bi
n\x86_arm\link.EXE"' : return code '0x460'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files\Microsoft Visual Studio 8\VC\BIN\n
make.exe"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2'
Stop.
Has anyone faced similar problems? Could you please suggest me what to do?

Resources