[New-bugs-announce] [issue2056] install command rejects --compiler option

Lenard Lindstrom report at bugs.python.org
Sun Feb 10 03:05:45 CET 2008


New submission from Lenard Lindstrom:

The install command returns the following error when the --compiler
option is provided on the command line:

>python setup.py install --compiler=mingw32
usage: setup.py [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts] ...]
   or: setup.py --help [cmd1 cmd2 ...]
   or: setup.py --help-commands
   or: setup.py cmd --help

error: option --compiler not recognized

This is problematic on Windows when MinGW is being used in place of
Visual C. A package can be built with --compiler=mingw32, but if no
compiler is specified for install the following error occurs:

>python setup.py install
running install
running build
running build_py
running build_ext
error: Python was built with Visual Studio 2003;
extensions must be built with a compiler than can generate compatible
binaries.
Visual Studio 2003 was not found on this system. If you have Cygwin
installed,
you can try compiling with MingW32, by passing "-c mingw32" to setup.py.


The work-around is to specify compiler=mingw32 in a setup.cfg file under
a [build] or [build_ext] heading. But this would be inconvenient for
someone who has both Visual C and MinGW and wants to choose.

----------
components: Distutils
messages: 62241
nosy: kermode
severity: normal
status: open
title: install command rejects --compiler option
versions: Python 2.5

__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue2056>
__________________________________


More information about the New-bugs-announce mailing list