Solve running qmake: Project ERROR: Cannot run compiler 'cl'. Output:

Solve the problem that the cl.exe program cannot be found when qmake is running.

The error is as follows:

E:\project\QTProject\HelloWord>qmake
Project ERROR: Cannot run compiler 'cl'. Output:
===================
===================
Maybe you forgot to setup the environment?

E:\project\QTProject\HelloWord>

The cl.exe file I have been looking for for a long time has not been found. Finally, through a file search, I found the location of the cl.exe file: the location
insert image description here
on my computer:
insert image description here

Add the unspecified address of the entire cl.exe to the environment variable:
insert image description here

Execute again:
insert image description here

No problem.

Guess you like

Origin blog.csdn.net/qq_17623363/article/details/120380013