[New-bugs-announce] [issue2234] cygwinccompiler.py fails for latest MinGW releases.
Lenard Lindstrom
report at bugs.python.org
Tue Mar 4 19:43:39 CET 2008
New submission from Lenard Lindstrom:
The cygwinccompiler.py module for distutils on Pythons 2.5 and 2.4 fails
with an exception for the latest MinGW tools.
running build_ext
Traceback (most recent call last):
File "setup.py", line 224, in <module>
setup(**PACKAGEDATA)
File "C:\PRG\PYTHON25\lib\distutils\core.py", line 151, in setup
dist.run_commands()
File "C:\PRG\PYTHON25\lib\distutils\dist.py", line 974, in run_commands
self.run_command(cmd)
File "C:\PRG\PYTHON25\lib\distutils\dist.py", line 994, in run_command
cmd_obj.run()
File "C:\PRG\PYTHON25\lib\distutils\command\build.py", line 112, in run
self.run_command(cmd_name)
File "C:\PRG\PYTHON25\lib\distutils\cmd.py", line 333, in run_command
self.distribution.run_command(command)
File "C:\PRG\PYTHON25\lib\distutils\dist.py", line 994, in run_command
cmd_obj.run()
File "setup.py", line 186, in run
build_ext.run(self)
File "C:\PRG\PYTHON25\lib\distutils\command\build_ext.py", line 264,
in run
force=self.force)
File "C:\prg\pygame\trunk_\mingw32distutils.py", line 31, in new_compiler
return Mingw32DefaultCCompiler (None, dry_run, force)
File "C:\PRG\PYTHON25\lib\distutils\cygwinccompiler.py", line 292, in
__init__
CygwinCCompiler.__init__ (self, verbose, dry_run, force)
File "C:\PRG\PYTHON25\lib\distutils\cygwinccompiler.py", line 84, in
__init__
get_versions()
File "C:\PRG\PYTHON25\lib\distutils\cygwinccompiler.py", line 424, in
get_vers
ions
ld_version = StrictVersion(result.group(1))
File "C:\PRG\PYTHON25\lib\distutils\version.py", line 40, in __init__
self.parse(vstring)
File "C:\PRG\PYTHON25\lib\distutils\version.py", line 107, in parse
raise ValueError, "invalid version number '%s'" % vstring
ValueError: invalid version number '2.18.50.20080109'
For instance "ld -v" now returns "GNU ld (GNU Binutils)
2.18.50.20080109", not "GNU ld version 2.17.50 20060824". The extra
period between the version number and date causes class StrictVersion to
raise a ValueError. A fix is to alter the regular expressions in
cygwinccompiler.get_versions().
This enclosed patch to cygwinccompiler.py has been tested with the
current and previous linker as well as gcc 4.2.1 and gcc 3.4.5.
----------
components: Distutils
files: cygwinccompiler.patch
keywords: patch
messages: 63257
nosy: kermode
severity: normal
status: open
title: cygwinccompiler.py fails for latest MinGW releases.
versions: Python 2.5
Added file: http://bugs.python.org/file9604/cygwinccompiler.patch
__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue2234>
__________________________________
More information about the New-bugs-announce
mailing list