Adding the MinGW Compiler to QT 5.6.0 Windows

I am here Total Noob and I know almost nothing about it. I just started using Qt Creator for Windows 5.6.0, and so far I have written my first "Hello World" code.

I was asked to add a kit. I searched the net for similar problems, and said that I needed a compiler for Qt. So I installed MinGW from QtForums

Now when I go to Tools-> Options-> Build & Run Compiler->, I can’t figure out how to add it to the list.

Please help me with this?

+5
source share
3 answers

To get started, the easiest way would be to go here:

Link to Qt Download Page

Scroll down and select Qt 5.6.0 for Windows 32-bit (MinGW 4.9.2, 1.0 GB) this will download the installer (its about 1 GB). Run it and select all the default options. Then you will have Qt 5.6 with mingw and Qt Creator ready to go. Note: before you start, it is probably better to delete the current version if you are not attached to it in any way :)

If you want to fix your current settings, then you may need more time to find out what you are missing in mingw. For example, you need a mingw qmake file that will be located here (using the default installation options):

  • C:\Qt\Qt5.5.1\5.5\mingw492_32\bin\qmake.exe

create your part of the "Qt Version" in the set. And the actual mingw compiler, which is here (using the default installation options):

  • C:\Qt\Qt5.5.1\Tools\mingw492_32\bin\g++.exe

create your own compiler. If you have both of them, you can put them together to create a new kit.

But to just add a compiler, all you have to do is:

  • Click the compilers tab
  • Click add and select Mingw
  • New compiler added, click on it
  • Below you will see some options, add the path to the executable file of your compiler (such as the one above).
  • And you're done - there are some other options, but you probably don't need to use them.

note my paths for qt 5.5.1 (obviously) are so slightly different from 5.6 :)

Refresh

Its all been moved! - here are the new ways:

offline installers

old version archives

+6
source

Well. I have not been able to provide data before, but now it all makes sense. What I installed was Qt for Windows 64-bit (vs 2013, 836mb).

Therefore, instead of MinGW, I have msvc2013_64. It has qmake.exe but does not have g ++. Exe. And I downloaded it separately. You answered very helpful.

+2
source

MinGW packages have been added for installing QT using the QT Maintenance Tool (C: \ Qt \ MaintenanceTool.exe). It allows you to add / remove components through qt repositories. Therefore, there is no need to reinstall.

0
source

Source: https://habr.com/ru/post/1245458/


All Articles