2013-05-01 83 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". 

回答

相關問題