Numpy Install RuntimeError:断开的工具链:无法链接简单的C程序 [英] Numpy Install RuntimeError: Broken toolchain: cannot link a simple C program
问题描述
(macbook air)
(macbook air)
我花了一段时间尝试安装它.首先,我无法使用Homebrew,因为我已经安装了Homebrew,但是随后网络连接"断开了,现在我的计算机找不到"brew"命令,但它说已安装了homebrew.因此,我不知道如何在不使用brew命令的情况下将其卸载.
I spent a while trying to install this. First off, I can't use Homebrew because I installed it but then the 'network connection' dropped and now my computer can't find the 'brew' command, but it says homebrew in installed. So I don't know how to uninstall it without using the brew command.
所以我正在尝试从命令行安装numpy.我有xcode,命令行工具,gcc fortran 4.2.3和已下载的numpy.尝试安装时出现RuntimeError错误!我已经阅读并尝试了以前的帖子中的所有内容.
So I am trying to install numpy from the command line. I have xcode, command line tools, gcc fortran 4.2.3, and downloaded numpy. I am getting a RuntimeError when trying to install it! I've read and tried everything from previous posts.
我已附加我的路径以向大家展示,也许我搞砸了吗?
I have attached my Path to show you all, maybe I messed that up?
echo $PATH
/Library/Frameworks/Python.framework/Versions/2.6/bin:/Library/Frameworks/Python.framework/Versions/3.4 bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
希望您的帮助!
Traceback (most recent call last):
File "setup.py", line 251, in <module>
setup_package()
File "setup.py", line 243, in setup_package
setup(**metadata)
File "/Users/Anisa/Downloads/numpy-1.9.1/numpy/distutils/core.py", line 169, in setup
return old_setup(**new_attr)
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/distutils/core.py", line 152, in setup
dist.run_commands()
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/distutils/dist.py", line 975, in run_commands
self.run_command(cmd)
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/distutils/dist.py", line 995, in run_command
cmd_obj.run()
File "/Users/Anisa/Downloads/numpy-1.9.1/numpy/distutils/command/build.py", line 39, in run
old_build.run(self)
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/distutils/command/build.py", line 134, in run
self.run_command(cmd_name)
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/distutils/cmd.py", line 333, in run_command
self.distribution.run_command(command)
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/distutils/dist.py", line 995, in run_command
cmd_obj.run()
File "/Users/Anisa/Downloads/numpy-1.9.1/numpy/distutils/command/build_src.py", line 153, in run
self.build_sources()
File "/Users/Anisa/Downloads/numpy-1.9.1/numpy/distutils/command/build_src.py", line 164, in build_sources
self.build_library_sources(*libname_info)
File "/Users/Anisa/Downloads/numpy-1.9.1/numpy/distutils/command/build_src.py", line 299, in build_library_sources
sources = self.generate_sources(sources, (lib_name, build_info))
File "/Users/Anisa/Downloads/numpy-1.9.1/numpy/distutils/command/build_src.py", line 386, in generate_sources
source = func(extension, build_dir)
File "numpy/core/setup.py", line 686, in get_mathlib_info
raise RuntimeError("Broken toolchain: cannot link a simple C program")
RuntimeError: Broken toolchain: cannot link a simple C program
推荐答案
我两次遇到了这个问题,两次都这样解决:放弃点子.
I ran into this issue twice, and both times I fixed it this way: abandoning pip.
第一次是在osx上,我做了brew install numpy
.自制程序将处理所有依赖项.
First time was on osx I did brew install numpy
. Homebrew will take care of all of the dependencies.
第二次是在centos7上,就像上面我只是yum install -y numpy
.
Second time was on centos7 and much like above I just yum install -y numpy
.
这篇关于Numpy Install RuntimeError:断开的工具链:无法链接简单的C程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!