Call the compiler cygwin in msvc

Assume that the source code for the project need to make use instruction, because it is working on the windows, you need to call different versions of visual studio compiler cl.exe. Here to vs2013 example.

First, enter the set command in cmd, view the environment variables have been added

VS110COMNTOOLS=C:\Program Files (x86)\Microsoft Visual Studio 11.0\Common7\Tools\
VS120COMNTOOLS=C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\Tools\
VS80COMNTOOLS=C:\Program Files (x86)\Microsoft Visual Studio 8\Common7\Tools\

Use cd / d cd / d C: \ Program Files (x86) \ Microsoft Visual Studio 12.0 \ Common7 \ Tools \ switch to the tools directory

Execution vsvars32.bat. At this time, the current cl compiler is vs2013 of the.

Enter the following information can be seen cl.

Microsoft (R) C/C++ Optimizing Compiler Version 18.00.40629 for x86

Description Current vs compiler environment settings successful.

Then call cygwin.bat enter the bash in cmd, then you can normally use the make command.

 

Guess you like

Origin www.cnblogs.com/japelly/p/11719905.html