I am a newbie. I am trying to compile following code in qt creator 2.6 shipped with Qt 5 beta for windows:
#include
#include
int main(int argc, char *argv[])
{
QCoreApplication a(argc, argv);
qDebug() << "hello Qt5";
return a.exec();
}
I am getting following error:
Qt Creator needs a compiler set up to build. Configure a compiler in the kit options.
File not found:
Qt creator > tools > options > build and run > kits is as follows:
Name:
Auto-detect:
Desktop Qt 5.0.0 beta2 MSVC2010 32bit (SDK) (default)
Manual: (none)
Important thing here is there is no compiler selected
When i click on "manage" button, it takes me to "compilers" tab :
Auto-detect:
Microsoft Windows SDK for Windows 7 (7.1.1700.0.30514)(x86)
Microsoft Windows SDK for Windows 7 (7.1.1700.0.30514)(amd64)
Microsoft Windows SDK for Windows 7 (7.1.1700.0.30514)(ia64)
Microsoft Windows SDK for Windows 7 (7.1.1700.0.30514)()
....
Microsoft Visual C++ Compiler 10.0 (x86)
Microsoft Visual C++ Compiler 10.0 (x86)
Microsoft Visual C++ Compiler 10.0 (amd64)
...
Qt versions tab is as follows:
Auto-detect: Qt 5.0.0 beta2 MSVC2010 32bit (SDK)
I am using:
OS: Windows 7
First I tried "Microsoft Windows SDK for Windows 7 and .NET Framework 4" and failed to compile the code. Then i installed VS2010 and also failed to compile.
Can any body help me??
I wanted to post images of my qt creator 2.6 Build and Run options, but Stack Overflow did not allow me to do so as I am a new member of it.
Thanks in advance
解决方案
Go to the "Qt Versions" tab, select the Details button in the Helpers row and select the compiler that you want to use (it must be compatible with the compiler used to compile the Qt libraries).