C++ – How to use Qt Creator with Visual C++ compiler on windows

cqtqt-creatorvisual studiowindows

I installed Visual Studio 2008, Qt 4.8 libraries for vs2008 and Qt add in. I can build Qt projects in VS2008. But it's very inconvenient for me. When I open Qt project in Qt creator it can't compile because can't find qmake.

So, how to build projects using Qt Creator on windows.

Best Answer

Use CMake to build your software. With CMake you can:

  • -Build your project on a continuous integration server
  • Compile with different compilers (Microsoft, gcc, clang) to get additional static checking.
  • Open the top level CMakeLists.txt with creator as a project file.
  • Have CMake create Visual Studio project files.

If you want to fix Creator only: Qt Creator needs to know where your Qt installation is. Choose the green Qt symbol in the settings menu, klick Qt Version and enter the path to qmake. Then Qt Creator should be ready to go.