Install Python C extension compiler environment under windows (solve “error: command” cl.exe ‘ failed: No such file or directory”)

following a blog post resolved in python2: Debugger speedups using cython not found.

was found to have the same problem in python3.5. The original python required VC++ Compiler to compile and install (MInGW can also be used, is generally not recommended, is generally not recommended to use PIP to install some third-party python libraries under Windows, many use C to write some extensions, and need VC++ Compiler to compile and install, otherwise “error: The command ‘cl. Exe’ failed: “. The most common compiler for is Visual Studio C ++.

like Python2.7 requires VS2008 C++ compiler, whereas python3 to 3.4 is compiled in VS2010, and python3.5 is compiled in VS2015.

however, anyone who has ever installed VS this huge bloated IDE knows that it comes bundled with a bunch of Microsoft plug-ins, takes up a lot of C disk space, and starts slowly,
if the computer configuration is general, the computer will be very stuck, generally do not do related development, there is no need to install the whole VS.

for Python 2.7, the Microsoft Visual C++ Compiler for Python 2.7 is available for download and installation.
http://www.microsoft.com/en-us/download/details.aspx?id=44266

for python3.5 the compiler provided by Microsoft is installed – Visual C++ Build Tools

Download address:

http://landinghub.visualstudio.com/visual-cpp-build-tools
to install, remember to choose the Windows SDK 8.1 and Windows SDK 10 , so don’t pack VS2015 can also compiled a package of C code in the PIP.

Read More: