我正在使用 Python27
我的 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
另一个有同样问题的
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".