[Python-Dev] compiling python2.5 on linux under wine

Luke Kenneth Casson Leighton lkcl at lkcl.net
Thu Jan 8 16:18:03 CET 2009

> next bug: distutils.sysconfig.get_config_var('srcdir') is returning None (!!)

 ok ... actually, that's correct.  oops.

 sysconfig.get_config_vars() only returns these, on win32:

{'EXE': '.exe', 'exec_prefix': 'Z:\\mnt\\src\\python2.5-2.5.2',
'LIBDEST': 'Z:\\mnt\\src\\python2.5-2.5.2\\Lib', 'prefix':
'Z:\\mnt\\src\\python2.5-2.5.2', 'SO': '.pyd', 'BINLIBDEST':
'Z:\\mnt\\src\\python2.5-2.5.2\\Lib', 'INCLUDEPY':

 ... aaaand, that means disabling setup.py or hacking it significantly
to support a win32 build, e.g. to build pyexpat, detect which modules
are left, etc. by examining the remaining vcproj files in PCbuild.

 .... ok - i'm done for now.

 the project's not complete, but can be regarded as successful so far.
 i think the best thing is being able to do "import _winreg" on a
linux system.  that absolutely tickles me silly :)

been running a few tests  - test_mmap.py is a hoot, esp. the Try
opening a bad file descriptor... that causes a wine segfault.

if anyone wants to play with this further, source is here:


at some point - if i feel like taking this further, and if people
offer some advice and hints on where to go (with e.g. setup.py) i'll

 then once that's done i'll do python 2.6 as well.


More information about the Python-Dev mailing list