pypa / setuptools

Official project repository for the Setuptools build system
https://pypi.org/project/setuptools/
MIT License
2.49k stars 1.18k forks source link

Update docs for required compilers for Windows #1851

Open letmaik opened 5 years ago

letmaik commented 5 years ago

https://wiki.python.org/moin/WindowsCompilers has Visual C++ 14.X listed for Python 3.5, 3.6, 3.7, 3.8, which to me means I can use any 14.x compiler for these Python versions. This seems incorrect though as I'm getting the following error for Python 3.5 where I only have > 14.0 available:

error: Microsoft Visual C++ 14.0 is required. Get it with "Microsoft Visual C++ Build Tools": https://visualstudio.microsoft.com/downloads/

It would be great if the table could be fixed.

zooba commented 4 years ago

The table is fine - setuptools needs to be updated to detect newer versions than 14.0.

This function from distutils can be cloned, and possibly even enhanced to use the newer -find argument to vswhere.

https://github.com/python/cpython/blob/61691d833631fed42b86605b09e1535e3e8d40e5/Lib/distutils/_msvccompiler.py#L58-L88

letmaik commented 4 years ago

Please have a look at https://docs.microsoft.com/en-us/cpp/porting/binary-compat-2015-2017?view=vs-2019 in the comments sections:

Binary compat between 2015 and 2017 is guaranteed only when the consuming code is built with a toolset/compiler version that is the same or newer than the toolset/compiler used to build the library. So, a VS2015 exe + VS2017 DLL is not guaranteed to be compatible.