使用Brew在osx上安装scipy时出错

提姆

我正在尝试使用brew在我的osx 10.9机器上安装scipy,但是安装一直失败:

administrators-iMac-3:sourcefind_python bill$ brew install scipy --default-fortran-flags
==> Using Homebrew-provided fortran compiler.
This may be changed by setting the FC environment variable.
==> Building with an alternative Fortran compiler
This is unsupported.
Warning: No Fortran optimization information was provided.  You may want to consider
setting FCFLAGS and FFLAGS or pass the `--default-fortran-flags` option to
`brew install` if your compiler is compatible with GCC.

If you like the default optimization level of your compiler, ignore this
warning.
==> Downloading https://downloads.sourceforge.net/project/scipy/scipy/0.13.3/scipy-0.13.3.tar.gz
Already downloaded: /Library/Caches/Homebrew/scipy-0.13.3.tar.gz
==> python setup.py build --fcompiler=gnu95 install --prefix=/usr/local/Cellar/scipy/0.13.3_1
  Referenced from: /usr/local/Cellar/gcc/4.8.3_1/libexec/gcc/x86_64-apple-darwin13.2.0/4.8.3/f951
  Reason: image not found
gfortran: internal compiler error: Trace/BPT trap: 5 (program f951)
sh: line 1:  9597 Abort trap: 6           /usr/local/bin/gfortran -Wall -ffixed-form -fno-second-underscore -ff2c -O3 -funroll-loops -I/usr/local/lib/python2.7/site-packages/numpy/core/include -c -c scipy/fftpack/src/dfftpack/dcosqb.f -o build/temp.macosx-10.9-x86_64-2.7/scipy/fftpack/src/dfftpack/dcosqb.o
error: Command "/usr/local/bin/gfortran -Wall -ffixed-form -fno-second-underscore -ff2c -O3 -funroll-loops -I/usr/local/lib/python2.7/site-packages/numpy/core/include -c -c scipy/fftpack/src/dfftpack/dcosqb.f -o build/temp.macosx-10.9-x86_64-2.7/scipy/fftpack/src/dfftpack/dcosqb.o" failed with exit status 134

READ THIS: https://github.com/Homebrew/homebrew/wiki/troubleshooting
If reporting this issue please do so at (not Homebrew/homebrew):
  https://github.com/samueljohn/homebrew-python/issues

我安装了应该包含gfortran的gcc:

administrators-iMac-3:sourcefind_python bill$ brew install gfortran
Error: No available formula for gfortran
GNU Fortran is now provided as part of GCC, and can be installed with:
  brew install gcc

administrators-iMac-3:sourcefind_python bill$ brew install gcc
Warning: gcc-4.8.3_1 already installed

应该在那里:

administrators-iMac-3:sourcefind_python bill$ gfortran
gfortran: fatal error: no input files
compilation terminated.
提姆

要解决此问题,您必须使用的另一个版本gfortran这里给出详细的解释

您可能还想尝试使用此处提供的.dmg安装程序进行安装

本文收集自互联网,转载请注明来源。

如有侵权,请联系 [email protected] 删除。

编辑于
0

我来说两句

0 条评论
登录 后参与评论

相关文章