在python 3上通过pip安装scipy库时出错:"编译失败,错误代码为1"

Dan*_*yal 7 python pip scipy python-3.x

我正在尝试通过python 3.3.5上的pip安装scipy库.在脚本结束时,我收到此错误:

命令/usr/local/opt/python3/bin/python3.3 -c"import setuptools,tokenize; file ='/ private/tmp/pip_build_root/scipy/setup.py'; exec(compile(getattr(tokenize,'open) ',open)(file).read().replace('\ r \n','\n'),file,'exec'))"install --record/tmp/pip-9r7808-record/install- record.txt --single-version-external-managed --compile失败,错误代码1在/ private/tmp/pip_build_root/scipy在/Users/dan/.pip/pip.log中存储失败的调试日志

小智 18

使用pip时我得到的是同样的东西,我去了安装,它指向了以下依赖项.

sudo apt-get install python python-dev libatlas-base-dev gcc gfortran g++

  • 我得到了OP的错误,但是使用了Python-pip 2.7.安装这些依赖项允许我安装. (2认同)

Dan*_*yal 1

我从https://github.com/scipy/scipy下载了源代码,并能够使用 python 3 成功构建和安装它。