[Python-Dev] Status of C compilers for Python on Windows

Ray Donnelly mingw.android at gmail.com
Sun Oct 26 02:24:23 CEST 2014

On Sat, Oct 25, 2014 at 11:44 PM, Paul Moore <p.f.moore at gmail.com> wrote:
> On 25 October 2014 23:22, Chris Angelico <rosuav at gmail.com> wrote:
>> On Sun, Oct 26, 2014 at 9:19 AM, Antoine Pitrou <solipsis at pitrou.net> wrote:
>>> My point is that your "Windows build" would not have the same behaviour
>>> as a MSVC-produced Windows build, and so testing it with it would not
>>> certify that your code would actually be compatible with genuine
>>> MSVC builds of CPython, which we will not stop supporting.
>> So you're saying it's impossible to support two compilers?
> No, rather that Windows currently only has a single supported compiler
> (excluding cygwin, which is essentially a different OS). Adding a
> second compiler doesn't just involve adding support for it - which is
> all that the people offering mingw patches are doing - but also
> involves going through the whole CPython ecosystem locating the places
> where there is an implicit assumption that "all Windows builds use the
> same compiler" and fixing them. I've already pointed out where this is
> a question for pip and wheel. Whoever wants to add support for a
> second compiler needs to be willing to do this part of the job as
> well.
> Handwaving arguments that "it's binary compatible" aren't enough. Prove it.

The msvcrt.dlls that MinGW-w64 depends on are those dating back to
Windows XP SP3 / XP64. Ironically, the official Windows CPython
doesn't come with any such crt guarantees and you must ensure that the
same msvcr??.dll is used for *all* extensions. This puts considerable
strain on extension developers to use the correct (or any) version of
Visual Studio to build their extensions for CPython on Windows. Also,
where are the publicly accessible specifications and other technical
descriptions that MinGW-w64 would need to implement strong binary
compatibility with MSVC? As a random example, those for C++ name
mangling and the PDB file format would be very helpful.

> Paul
> _______________________________________________
> Python-Dev mailing list
> Python-Dev at python.org
> https://mail.python.org/mailman/listinfo/python-dev
> Unsubscribe: https://mail.python.org/mailman/options/python-dev/mingw.android%40gmail.com

More information about the Python-Dev mailing list