我在使用pip安装spacy时遇到错误(在mac python3下)。以下是错误报告的最后一部分。它接缝有很多错误。我该如何解决?我已经安装了gcc。
gcc: warning: x86_64 conflicts with i386 (arch flags ignored)
cc1plus: warning: command line option '-Wno-strict-prototypes' is valid for C/ObjC but not for C++
g++-4.2 -bundle -undefined dynamic_lookup -arch i386 -arch x86_64 -g build/temp.macosx-10.6-intel-3.6/thinc/linalg.o -o build/lib.macosx-10.6-intel-3.6/thinc/linalg.cpython-36m-darwin.so
unable to execute 'g++-4.2': No such file or directory
error: command 'g++-4.2' failed with exit status 1
.......
/usr/local/bin/gcc -fno-strict-aliasing -Wsign-compare -fno-common -dynamic -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -arch i386 -arch x86_64 -g -I/Library/Frameworks/Python.framework/Versions/3.6/include/python3.6m -I/private/var/folders/md/8kgtqqz12j94hbcvhqz0w7gw0000gp/T/pip-build-sm84mnwa/murmurhash/murmurhash/include -I/Library/Frameworks/Python.framework/Versions/3.6/include/python3.6m -c murmurhash/mrmr.cpp -o build/temp.macosx-10.6-intel-3.6/murmurhash/mrmr.o -O3 -Wno-strict-prototypes -Wno-unused-function
gcc: warning: x86_64 conflicts with i386 (arch flags ignored)
gcc: error: murmurhash/mrmr.cpp: No such file or directory
gcc: fatal error: no input files
compilation terminated.
error: command '/usr/local/bin/gcc' failed with exit status 1
----------------------------------------
命令 “/ Library/Frameworks/Python.framework/Versions/3.6/bin/python3.6 -u -c “import setuptools, 标记化的文件 = '/私有的/ var /文件夹/ MD / 8kgtqqz12j94hbcvhqz0w7gw0000gp / T / PIP-积聚sm84mnwa / murmur哈希/ setup.py'; F = GETATTR(标记化, 'open',open)( file ); code = f.read()。replace('\ r \ n', '\ n'); f.close(); exec(编译(代码,文件,'exec'))“安装 --record /var/folders/md/8kgtqqz12j94hbcvhqz0w7gw0000gp/T/pip-4_7dl2wl-record/install-record.txt --single-version-external-managed --compile“失败,错误代码为1 /私有的/ var /文件夹/ MD / 8kgtqqz12j94hbcvhqz0w7gw0000gp / T / PIP-积聚sm84mnwa / murmur哈希/
答案 0 :(得分:0)
我真的不确定这是否相关,但是今天早上我看到一个讨论,说最新的macOS升级(Catalina)完全放弃了对32位应用程序的支持。我之所以提到它,是因为x86_64与i386冲突可能是指32位/ 64位问题。
您最近是否升级了Mac OS?如果是这样,也许您需要将依赖项升级到64位等效项?