QtCreator qmake Cannot run compiler 'cl' - c++

Just configured new windows environment with MSVS 2017 and Qt5.9.1.
While building example project bars met an error
Project ERROR: Cannot run compiler 'cl'. Maybe you forgot to setup the environment?
With mingw build and run fine.
I tried to add Custom build step before qmake
"C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\VC\Auxiliary\Build\vcvarsall.bat" amd64
But got the same results. In cmd this command works fine. After it cl.exe is reachable.
All toolsets was found automatically by Qt and seems to be right
here were screenshots
Update1. Build in Developer Command Prompt for VS 2017
**********************************************************************
** Visual Studio 2017 Developer Command Prompt v15.0.26730.16
** Copyright (c) 2017 Microsoft Corporation
**********************************************************************
C:\Users\Admin\source>"C:\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\bin\qmake.exe" C:\Devel\Qt\Qt5.9.1\Examples\Qt-5.9.1\datavisualization\bars\bars.pro -spec win32-msvc
C:\Users\Admin\source>nmake
Microsoft (R) Program Maintenance Utility Version 14.11.25508.2
Copyright (C) Microsoft Corporation. All rights reserved.
"C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\VC\Tools\MSVC\14.11.25503\bin\HostX86\x86\nmake.exe" -f Makefile.Release
Microsoft (R) Program Maintenance Utility Version 14.11.25508.2
Copyright (C) Microsoft Corporation. All rights reserved.
cl -c -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -O2 -MD -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -EHsc -DUNICODE -DWIN32 -DQT_NO_DEBUG -DQT_DATAVISUALIZATION_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -DNDEBUG -I..\..\..\Devel\Qt\Qt5.9.1\Examples\Qt-5.9.1\datavisualization\bars -I. -I../../../include -I..\..\..\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\include -I..\..\..\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\include\QtDataVisualization -I..\..\..\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\include\QtWidgets -I..\..\..\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\include\QtGui -I..\..\..\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\include\QtANGLE -I..\..\..\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\include\QtCore -Irelease -I..\..\..\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\mkspecs\win32-msvc -Forelease\ #C:\Users\Admin\AppData\Local\Temp\nm6ED7.tmp
main.cpp
graphmodifier.cpp
Generating Code...
cl -c -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -O2 -MD -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -EHsc -DUNICODE -DWIN32 -DQT_NO_DEBUG -DQT_DATAVISUALIZATION_LIB -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_CORE_LIB -DNDEBUG -I..\..\..\Devel\Qt\Qt5.9.1\Examples\Qt-5.9.1\datavisualization\bars -I. -I../../../include -I..\..\..\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\include -I..\..\..\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\include\QtDataVisualization -I..\..\..\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\include\QtWidgets -I..\..\..\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\include\QtGui -I..\..\..\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\include\QtANGLE -I..\..\..\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\include\QtCore -Irelease -I..\..\..\Devel\Qt\Qt5.9.1\5.9.1\msvc2017_64\mkspecs\win32-msvc -Forelease\ #C:\Users\Admin\AppData\Local\Temp\nm7EF5.tmp
moc_graphmodifier.cpp
link /NOLOGO /DYNAMICBASE /NXCOMPAT /INCREMENTAL:NO /SUBSYSTEM:WINDOWS "/MANIFESTDEPENDENCY:type='win32' name='Microsoft.Windows.Common-Controls' version='6.0.0.0' publicKeyToken='6595b64144ccf1df' language='*' processorArchitecture='*'" /MANIFEST:embed /OUT:release\bars.exe #C:\Users\Admin\AppData\Local\Temp\nm8417.tmp
Qt5DataVisualization.lib(Qt5DataVisualization.dll) : fatal error LNK1112: module machine type 'x64' conflicts with target machine type 'x86'
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\VC\Tools\MSVC\14.11.25503\bin\HostX86\x86\link.EXE"' : return code '0x458'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\VC\Tools\MSVC\14.11.25503\bin\HostX86\x86\nmake.exe"' : return code '0x2'
Stop.
C:\Users\Admin\source>
Linkage errors. But cl.exe found.

I had a similar case, which was solved by adding the path to cl.exe to the path environment variable:
set path=%path%;%qtdir%\bin;"C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.12.25827\bin\Hostx64\x64"
set QMakeSpec=win32-msvc
qmake -tp vc
Maybe another cl.exe is interfering here?

This is the solution for anyone who has or had NVMW installed:
After a year of not being able to use Qt on my work laptop and private PC, I have finally figured out how to fix it, if you have installed the Node.js version manager for Windows at any point:
I found the file %HOMEPATH%\cmd_auto_run.cmd in my user directory (thanks to this barely related SO answer), which has been constantly resetting the PATH variable to a constant string, overriding any changes I was making to the system environment variables. The path to this file was set in the Windows Registry under HKCU\SOFTWARE\Microsoft\Command Processor\Autorun
After opening the file, I simply added a %PATH%; just after the = sign and just to be sure I removed any duplicate paths that were defined after that. Afterwards, the line was looking like this:
SET "PATH=%PATH%;C:\Users\MYUSER\nvmw\nodejs\v15.2.1"
Then, I added the following paths to the system environment variable named PATH, for both the VS Build Tools (needed for cl.exe - I added 2017 and 2019 just to be safe) and the Windows 10 SDK (needed for rc.exe):
C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools\VC\Tools\MSVC\14.27.29110\bin\Hostx64\x64
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\bin\Hostx64\x64
C:\Program Files (x86)\Windows Kits\10\bin\10.0.19041.0\x64
Then I restarted Qt and it found all of the project's files again and I could compile it just like I used to.
This is a problem with NVMW, a Node.js version manager for Windows. There is an issue on a repo on GitHub from 2015 but it hasn't been fixed yet and the main repo was archived. This was the most frustrating sh!t ever and it probably took me over 20 hours actively to fix it so I hope I can help someone who has been struggling just like me.

Just reboot. It helped me. Probably finalizes the installation of Visual Studio or Qt.

After next steps all runs fine.
Set Dracula style for QtCreator :)
Modify MSVS installation addning VC++ 2015.3 v140 toolset for desktop (x86,x64).
Very strange. And that is why I don't like windows. It lives its own live!
So the answer is TRY TO REINSTALL/modify components, including QtCreator itself.

I had the same problem on Windows 10 with VC2019 and Qt 6.0.2.
When i then started
Start->Visual Studio 2019->x64 Native Tools Command prompt
i saw a error message in the console window saying something like
"\ is syntactically not correct"
This was caused by a backslash at the end of the %path% variable set up in System settings->system->extended...
I removed this backslash and then "x64 Native Tools Command prompt" opened without error, and after restarting qtCreator projects built without error.
Unfortunately after fixing this once i can not reproduce it any more.

Executing the following file setup environment, also you have qtcreator vs/cl.exe or mingw/g++?
C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat

Related

How to set a debugger flag on C build?

I'am following a tutorial on making a game in C/C++. The building part takes place with just a .bat file. I'll show it.
#echo off
mkdir ..\build
pushd ..\build
cl -zi s:\games\game1\code\win32_game1.cpp user32.lib
popd
The flag -zi is used for getting the debugger output/information. The only problem is that when I run this script in the command line I get the following error:
Ignoring unknown option "-zi"
Can somebody tells me why -zi isn't working or what I can use instead? I'm using Visual Studio 2017.

How to build mysql driver for qt?

I read a lot of instructions and tutorials how to do that, and I tried many of that, but 6 hours have gone and it's all the same. Please help...
I know, there are some similar questions on stackoverflow but answers on them doesn't help.
Problem:
I want to build Mysql driver for my qt program. According to instructions I did:
1) set mysql=C:\PROGRA~1\MySQL\MYSQLS~1.6 (full path is C:\Program Files\MySQL\MySQL Server 5.6)
2)
cd C:\Qt_Sources\5.2.1\Src\qtbase\src\plugins\sqldrivers\mysql
qmake -o Makefile "INCLUDEPATH+=%mysql%\include" "LIBS+=%mysql%\lib\libmysql.lib" mysql.pro
mingw32-make
mingw32-make from (C:\MinGW\bin)
After this I got:
mingw32-make -f Makefile.Release all
mingw32-make[1]: Entering directory 'C:/Qt_Sources/5.2.1/Src/qtbase/src/plugins/
sqldrivers/mysql'
Makefile.Release:65: *** missing separator. Stop.
mingw32-make[1]: Leaving directory 'C:/Qt_Sources/5.2.1/Src/qtbase/src/plugins/s
qldrivers/mysql'
Makefile:40: recipe for target 'release-all' failed
mingw32-make: *** [release-all] Error 2
Also I tried nmake from (C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\bin) and result is:
Microsoft (R) Program Maintenance Utility Version 11.00.50727.1
Copyright (C) Microsoft Corporation. All rights reserved.
"C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC\bin\nmake.exe" -
f Makefile.Release all
Microsoft (R) Program Maintenance Utility Version 11.00.50727.1
Copyright (C) Microsoft Corporation. All rights reserved.
cl -c -nologo -Zm200 -Zc:wchar_t -O2 -MD -GR -W3 -w34100 -w34189 -DUNICO
DE -DWIN32 -DQT_EDITION=QT_EDITION_DESKTOP -DQT_EVAL -DQT_NO_CAST_TO_ASCII -DQT_
NO_CAST_FROM_ASCII -DQT_NO_EXCEPTIONS -DQT_NO_DEBUG -DQT_PLUGIN -DQT_SQL_LIB -DQ
T_CORE_LIB -DNDEBUG -I"%mysql%\include" -I"C:\Qt\5.2.1\msvc2012\include\QtSql\5.
2.1" -I"C:\Qt\5.2.1\msvc2012\include\QtSql\5.2.1\QtSql" -I"C:\Qt\5.2.1\msvc2012\
include" -I"C:\Qt\5.2.1\msvc2012\include\QtSql" -I"C:\Qt\5.2.1\msvc2012\include\
QtCore\5.2.1" -I"C:\Qt\5.2.1\msvc2012\include\QtCore\5.2.1\QtCore" -I"C:\Qt\5.2.
1\msvc2012\include\QtCore" -I".moc\release" -I"..\..\..\..\mkspecs\win32-msvc201
2" -Fo.obj\release\ #C:\Users\GOODSP~1\AppData\Local\Temp\nmD5C6.tmp
NMAKE : fatal error U1077: 'cl' : return code '0xc0000135'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 11.0
\VC\bin\nmake.exe"' : return code '0x2'
Stop.
Please explain what I did wrong...
Yes, I finally resolve this issue...
I used qmake for another qt version, for me I think I used qmake from msvc2012, and tried to make it by mingw32-make and nmake (but nmake from visual studio 2011.. maybe this is the problem).
And solution is:
Use qmake from mingw48_32 directory (for me it's: C:\Qt\5.2.1\mingw48_32. Install qt sources with mingw, if you don't have it). After that all works fine with mingw32-make.

Compiler error when building Qt

I am trying to build Qt myself. I checked out everything and want to run configure now. The Visual Studio 2013 compiler is in PATH but I get this error
C:\Users\Philipp\Desktop\Qt>configure -developer-build -opensource -nomake examp
les -nomake tests -opengl desktop
+ cd qtbase
+ C:\Users\Philipp\Desktop\Qt\qtbase\configure.bat -top-level -developer-build -
opensource -nomake examples -nomake tests -opengl desktop
Please wait while bootstrapping configure ...
<srcbase> = C:/Users/Philipp/Desktop/Qt/qtbase
<outbase> = C:/Users/Philipp/Desktop/Qt/qtbase
Microsoft (R) Program Maintenance Utility Version 12.00.21005.1
Copyright (C) Microsoft Corporation. All rights reserved.
cl -c -Yc -nologo -Zm200 -Zc:wchar_t -MT -W3 -GR -EHsc -w34100 -w34189
-DUNICODE -DQT_NO_CODECS -DQT_NO_TEXTCODEC -DQT_NO_UNICODETABLES -DQT_LITE_COMPO
NENT -DQT_NO_COMPRESS -DQT_NO_THREAD -DQT_NO_QOBJECT -DQT_NO_GEOM_VARIANT -D_CRT
_SECURE_NO_DEPRECATE -DQT_BOOTSTRAPPED -DQT_BUILD_CONFIGURE -DCOMMERCIAL_VERSION
-I"..\..\include" -I"..\..\include\QtCore" -I"..\..\include\QtCore\5.2.0" -I"..
\..\include\QtCore\5.2.0\QtCore" -I"C:\Users\Philipp\Desktop\Qt\qtbase\tools\sha
red" -I"C:\Users\Philipp\Desktop\Qt\qtbase\mkspecs\win32-msvc2008" -Fpconfigure_
pch.pch -Foconfigure_pch.obj -TP C:\Users\Philipp\Desktop\Qt\qtbase\tools\config
ure\configure_pch.h
configure_pch.h
c:\users\philipp\desktop\qt\qtbase\include\qtcore\../../src/corelib/global/qglob
al.h(46) : fatal error C1083: Cannot open include file: 'stddef.h': No such file
or directory
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 12.0
\VC\bin\cl.EXE"' : return code '0x2'
Stop.
Does anyone know how to solve this?
Compiler itself in the PATH variable is not enough, it needs to know where include files and libraries are located.
Check vc++ has PATH variables it uses defined (at least both INCLUDE and LIBPATH).
If not you have two options:
Run configure from Developer Command Prompt (you can find it in the Visual Studio Tools program group).
From any command prompt window run VcVars32.bat batch file (or VsVars32.bat) located in Common7\Tools folder under VS installation directory.

Error while building project when executing build step 'Make'

I've just installed Qt SDK 1.2.1 on my PC. I created a new project as a test:
File > New File or Project... > Other Project > Plain C++ Project
I chose these build settings:
Qt Creator generated this .pro file:
TEMPLATE = app
CONFIG += console
CONFIG -= qt
SOURCES += main.cpp
and this main.cpp file:
#include <iostream>
using namespace std;
int main()
{
cout << "Hello World!" << endl;
return 0;
}
The build fails:
13:39:35: Running build steps for project test...
13:39:35: Starting: "C:\Dev\Qt\QtSDK\QtCreator\bin\jom.exe" clean
Could Not Find C:\Dev\Projects\Qt\test\debug\main.obj
del debug\main.obj
del debug\test.intermediate.manifest debug\test.exp debug\test.ilk vc*.pdb vc*.idb
Could Not Find C:\Dev\Projects\Qt\test\debug\test.intermediate.manifest
Could Not Find C:\Dev\Projects\Qt\test\vc*.pdb
Could Not Find C:\Dev\Projects\Qt\test\test.intermediate.manifest
Could Not Find C:\Dev\Projects\Qt\test\test.exp
Could Not Find C:\Dev\Projects\Qt\test\test.ilk
Could Not Find C:\Dev\Projects\Qt\test\vc*.pdb
c:\dev\qt\qtsdk\desktop\qt\4.8.1\msvc2008\bin\qmake.exe -spec ..\..\..\Qt\QtSDK\Desktop\Qt\4.8.1\msvc2008\mkspecs\win32-msvc2008 CONFIG+=declarative_debug -o Makefile test.pro
C:\Dev\Qt\QtSDK\QtCreator\bin\jom.exe -f Makefile.Debug clean
C:\Dev\Qt\QtSDK\QtCreator\bin\jom.exe -f Makefile.Release clean
Could Not Find C:\Dev\Projects\Qt\test\release\main.obj
Could Not Find C:\Dev\Projects\Qt\test\release\test.intermediate.manifest
del release\main.obj
del release\test.intermediate.manifest release\test.exp
del ".\test.intermediate.manifest"
del test.exp
del test.ilk
del vc*.pdb
del vc*.idb
Could Not Find C:\Dev\Projects\Qt\test\vc*.idb
jom 1.0.8 - empower your cores
13:39:36: The process "C:\Dev\Qt\QtSDK\QtCreator\bin\jom.exe" exited normally.
13:39:36: Configuration unchanged, skipping qmake step.
13:39:36: Starting: "C:\Dev\Qt\QtSDK\QtCreator\bin\jom.exe"
cl -c -nologo -Zm200 -Zc:wchar_t- -Zi -MDd -GR -EHsc -W3 -w34100 -w34189 -DUNICODE -DWIN32 -DQT_LARGEFILE_SUPPORT -I"..\..\..\Qt\QtSDK\Desktop\Qt\4.8.1\msvc2008\mkspecs\win32-msvc2008" -Fodebug\ #C:\DOCUME~1\Mitch!\LOCALS~1\Temp\main.obj.5936.16.jom
C:\Dev\Qt\QtSDK\QtCreator\bin\jom.exe -f Makefile.Debug
'cl' is not recognized as an internal or external command,
operable program or batch file.
jom: C:\Dev\Projects\Qt\test\Makefile.Debug [debug\main.obj] Error 1
jom 1.0.8 - empower your cores
jom: C:\Dev\Projects\Qt\test\Makefile [debug] Error 2
13:39:36: The process "C:\Dev\Qt\QtSDK\QtCreator\bin\jom.exe" exited with code 2.
Error while building project test (target: Desktop)
When executing build step 'Make'
I've tried running the Qt 4.8.1 for Desktop (MSVC 2008) batch script before starting Qt Creator and checking the Projects > Build Settings > Build Environment > Using System Environment > Clear System Environment without success.
My PATH variable after installing Qt SDK 1.2.1:
%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;c:\Program Files\Microsoft SQL Server\90\Tools\binn\;C:\Program Files\QuickTime\QTSystem\;C:\Program Files\jEdit;C:\Program Files\TortoiseSVN\bin;C:\Program Files\doxygen\bin;C:\Program Files\NVIDIA Corporation\Cg\bin;C:\Program Files\Microsoft SQL Server\100\Tools\Binn\;C:\Program Files\Microsoft SQL Server\100\DTS\Binn\;C:\Program Files\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\;C:\Program Files\Microsoft Visual Studio 9.0\Common7\IDE\PrivateAssemblies\;C:\WINDOWS\system32\WindowsPowerShell\v1.0
My computer is running Windows XP Professional (Service Pack 2). The version of Qt Creator that ships with Qt SDK 1.2.1 is 2.4.1.
Looks like cl is either not installed on your system, or needs to be added to the PATH environment variable. Try to find the cl.exe binary somewhere in C:\Program Files\Microsoft Visual Studio [version]\ and add the directory that contains that binary to your PATH.

Qt SOAP install

I've ran into problems installing the LGPL version of the Qt SOAP component:
http://qt.nokia.com/products/appdev/add-on-products/catalog/4/Utilities/qtsoap/
I've followed the instructions in INSTALL but can't seem to get it to build the DLL.
Unpacking and installation
Unpacking the archive (if you have not done so already).
On Unix and Mac OS X (in a terminal window):
cd your-install-dir
gunzip some-package.tar.gz
tar xvf some-package.tar
This creates the subdirectory some-package containing the files.
On Windows:
Unpack the .zip archive by right-clicking it in explorer and
choosing "Extract All...". If your version of Windows does not
have zip support, you can use the infozip tools available
from www.info-zip.org.
If you are using the infozip tools (in a command prompt window):
cd your-install-dir
unzip some-package.zip
Configuring the package.
The configure script is called "configure" on unix/mac and
"configure.bat" on Windows. It should be run from a command line
after cd'ing to the package directory.
You can choose whether you want to use the component by including
its source code directly into your project, or build the component
as a dynamic shared library (DLL) that is loaded into the
application at run-time. The latter may be preferable for
technical or licensing (LGPL) reasons. If you want to build a DLL,
run the configure script with the argument "-library". Also see
the note about usage below.
(Components that are Qt plugins, e.g. styles and image formats,
are by default built as a plugin DLL.)
The configure script will prompt you in some cases for further
information. Answer these questions and carefully read the license text
before accepting the license conditions. The package cannot be used if
you do not accept the license conditions.
Building the component and examples (when required).
If a DLL is to be built, or if you would like to build the
examples, next give the commands
qmake
make [or nmake if your are using Microsoft Visual C++]
The example program(s) can be found in the directory called
"examples" or "example".
Components that are Qt plugins, e.g. styles and image formats, are
ready to be used as soon as they are built, so the rest of this
installation instruction can be skipped.
I get the following error when running nmake:
C:\Qt\qtsoap-2.6-opensource>nmake
Microsoft (R) Program Maintenance Utility Version 9.00.30729.01
Copyright (C) Microsoft Corporation. All rights reserved.
cd buildlib\ && "C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin\nmake.exe" -f Makefile
Microsoft (R) Program Maintenance Utility Version 9.00.30729.01
Copyright (C) Microsoft Corporation. All rights reserved.
"C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC\bin\nmake.exe" -f Makefile.Debug all
Microsoft (R) Program Maintenance Utility Version 9.00.30729.01
Copyright (C) Microsoft Corporation. All rights reserved.
C:/Qt/2009.03/qt/bin\moc.exe -DUNICODE -DQT_LARGEFILE_SUPPORT -DQT_QTSOAP_EXPORT -DQT_DLL -DQT_XML_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -DQT_THREAD_SUPPORT -I"....\2009.03\qt\include\QtCore" -I"....\2009.03\qt\include\QtNetwork" -I"....\2009.03\qt\include\QtGui" -I"....\2009.03\qt\include\QtXml" -I"....\2009.03\qt\include" -I"..\src" -I"....\2009.03\qt\include\ActiveQt" -I "debug" -I"....\2009.03\qt\mkspecs\default" -D__GNUC__ -DWIN32 ..\src\qtsoap.h -o debug\moc_qtsoap.cpp
g++ -c -g -frtti -fexceptions -mthreads -Wall -DUNICODE -DQT_LARGEFILE_SUPPORT -DQT_QTSOAP_EXPORT -DQT_DLL -DQT_XML_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -D QT_CORE_LIB -DQT_THREAD_SUPPORT -I"....\2009.03\qt\include\QtCore" -I"....\2009.03\qt\include\QtNetwork" -I"....\2009.03\qt\include\QtGui" -I"....\2009.03\qt\include\QtXml" -I"....\2009.03\qt\include" -I"..\src" -I"....\2009.03\qt\include\ActiveQt" -I"debug" -I"....\2009.03\qt\mkspecs\default" -o debug\moc_qtsoap.o debug\moc_qtsoap.cpp
g++.EXE: debug\moc_qtsoap.cpp: No such file or directory
g++.EXE: no input files
NMAKE : fatal error U1077: 'C:\Qt\2009.03\mingw\bin\g++.EXE' : return code '0x1'
Stop.
NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio 9.0\
VC\bin\nmake.exe"' : return code '0x2'
Stop.
NMAKE : fatal error U1077: 'cd' : return code '0x2'
Stop.
C:\Qt\qtsoap-2.6-opensource>
Any help on solving this would be much appreciated.
You're using qmake from a Qt built with MinGW. That means you should use the make from MinGW, not nmake.
If you want to compile some Qt software with MSVC then you must use a version of Qt built with MSVC.