MinGW and Python

"Martin v. Löwis" martin at v.loewis.de
Tue Apr 25 16:00:00 EDT 2006


sturlamolden wrote:
>> - there is no build process available to do that
> 
> In MSYS:
> 
> $ ./configure --prefix=/c/mingw
> $ make
> $ make install
> 
> This should be obvious to any with Unix experience.
> 
> MinGW actually distribute precompiled Python binaries as well (in
> MSYS-DTK).

So how does that deal with the various extension modules that
PCbuild/readme.txt mentions? Do I get winsound.pyd? _msi.pyd
(in 2.5)?

Please believe me: there is currently no build process that
gives the same results as the build process used. It might
be fairly easy to create one, but none exists as of today.

>> - people building extensions to Python must be able to do so with
>>   Microsoft C++, since some of these extensions are written using MFC.
> 
> MinGW can compile MFC. Download Windows Platform SDK and you get the
> MFC source.

Did you actually try that? Last I tried, GCC would refuse to compile
the MinGW header files.

Even if you succeed, I don't think the SDK license will allow you
to distribute your binary, and it *will* be incompatible the official
MFC binary. MSVC++ has its own object layout, vtable layout, name
mangling, so you can't use GCC to link against MSVC-compiled
C++ libraries.

Regards,
Martin



More information about the Python-list mailing list