2013-05-01 104 views
0

我使用Python27窗口 - PIP使用MinGW安装 - 失败 - cc1.exe:错误:无法识别的命令行选项 '-mno-cygwin的'

我的PATH包含

C:\MinGW\libexec\gcc\mingw32\4.6.2 
C:\MinGW\bin 
C:\MinGW\msys\1.0\bin 
C:\Python27\ 
C:\Python27\Scripts 

我的PYTHONPATH包含

C:\Python27 
C:\Python\Lib\site-packages 

当我尝试安装特定软件包我不断收到错误,用gcc

cc1.exe: error: unrecognized command line option '-mno-cygwin' 

好像是罪魁祸首,但我一直无法找到如何解决这个问题的信息。

错误的一些例子:

pip install ctypes 
.... 
building '_ctypes' extension 

    C:\MinGW\bin\gcc.exe -mno-cygwin -mdll -O -Wall -Isource/libffi_msvc -IC:\Python27\Lib\site-packages\numpy\core\include -IC:\boost_1_53_0 -IC:\Python27\include -IC:\Python27\PC -c source/_ctypes.c -o 
    build\temp.win32-2.7\Release\source\_ctypes.o 

    cc1.exe: error: unrecognized command line option '-mno-cygwin' 

    error: command 'gcc' failed with exit status 1 

另一个与Python\Lib\distutils\cygwinccompiler.py导致此问题同样的问题

pip install bzr 
.... 
building 'bzrlib._annotator_pyx' extension 

C:\MinGW\bin\gcc.exe -mno-cygwin -mdll -O -Wall -DWIN32 -IC:\Python27\Lib\site-packages\numpy\core\include -IC:\boost_1_53_0 -IC:\Python27\include -IC:\Python27\PC -c bzrlib/_annotator_pyx.c -o build\ 
temp.win32-2.7\Release\bzrlib\_annotator_pyx.o 

cc1.exe: error: unrecognized command line option '-mno-cygwin' 



    Cannot build extension "bzrlib._annotator_pyx". 

回答

相关问题