[英]command 'gcc' failed with exit status 1
我嘗試了所有答案,但無法解決安裝 Biopython 包的問題 我安裝了Mingw
,但是當我嘗試安裝包時: python setup.py install
我收到以下錯誤:
running install
running build
running build_py
running build_ext
building 'Bio.cpairwise2' extension
c:\mingw\bin\gcc.exe -mno-cygwin -mdll -O -Wall -Ic:\Python33\include -Ic:\Pytho
n33\include -c Bio/cpairwise2module.c -o build\temp.win-amd64-3.3\Release\bio\cp
airwise2module.o
writing build\temp.win-amd64-3.3\Release\bio\cpairwise2.def
c:\mingw\bin\gcc.exe -mno-cygwin -shared -s build\temp.win-amd64-3.3\Release\bio
\cpairwise2module.o build\temp.win-amd64-3.3\Release\bio\cpairwise2.def -Lc:\Pyt
hon33\libs -Lc:\Python33\PCbuild\amd64 -lpython33 -lmsvcr100 -o build\lib.win-am
d64-3.3\Bio\cpairwise2.pyd
c:/mingw/bin/../lib/gcc/mingw32/4.3.3/../../../../mingw32/bin/ld.exe: c:\Python3
3\libs/python33.lib(python33.dll): Recognised but unhandled machine type (0x8664
) in Import Library Format archive
c:/mingw/bin/../lib/gcc/mingw32/4.3.3/../../../../mingw32/bin/ld.exe: cannot fin
d -lmsvcr100
collect2: ld returned 1 exit status
error: command 'gcc' failed with exit status 1
根據here for error: cannot find -lmsvcr100
you need to first install Microsoft Visual C++ 2010 Redistributable Package,其次,將msvcr100.dll
復制到C:\Python33\libs
鏈接目錄是 C:\Python44\libs 因為兩者-lpython
和-lmsvcr100
在編譯期間指向同一個位置,因此它們必須位於同一個目錄中。當我需要安裝 Cython 時,此解決方案對我有用。
你會得到兩個錯誤。 第一個是你的:
error: cannot find -lmsvcr100
error: command 'gcc' failed with exit status 1
解決第一個錯誤后,您將收到第二個錯誤:
error: unrecognized command line option '-mno-cygwin'
error: command 'gcc' failed with exit status 1
它們是兩個不同的錯誤,有兩種不同的解決方案。 你可以在這里找到更多。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.