[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] pygame is a disgrace



Sami Hangaslammi wrote:

As Luke pointed out, Python extensions have to be compiled with the
same compiler as the main Python DLL, which in case of the official
win32 distribution is VS.NET.

That's incorrect. The C calling convention is consistent across Window's compilers. The main concern is with linkage. Python 2.4 and 2.5 use the VC.NET 2003 proprietary msvcr71.dll library for the C standard library. MinGW headers are msvcr71 compatible, but MinGW doesn't link to msvcr71 by default.



It's relatively simple if you have the
commercial version of Visual Studio, but scraping a compatible
environment out of the freely available parts is a major hassle.
There's also no tool for automatically getting the dependencies, so we
Windows users have to hunt precompiled binaries with Google or try to
compile them ourselves, which is usually a bit complicated because the
Makefiles are designed for gcc and gnu make and are not compatible
with the VS tools.


There are Unix like build environments for Windows, Cygwin and Msys. But if the C code only makes Unix specific system calls that is another problem.


So basically, almost every Windows pythonista who hasn't bought the
latest Visual Studio is on the mercy of precompiled binary installers
for Python extensions. Unfortunate but true.


Actually Python's distutils won't use the latest Visual Studio. msvcr71.dll is obsolete. Otherwise the free 2005 Express could be used. 2003 Toolkit is no longer available, and in my experience, won't install on a newer XP system anyway.


--
Lenard Lindstrom
<len-l@xxxxxxxxx>