Numpy Install RuntimeError: Broken toolchain: cannot link a simple C program

前端 未结 4 559
既然无缘
既然无缘 2020-12-18 16:20

(macbook air)

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

4条回答
  •  萌比男神i
    2020-12-18 17:15

    I'm having this same problem (only I'm using brew install numpy), with:

    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
    

    (Here is a full gist-log of my error.)

    This question has some potential solutions: Problems with pip install numpy - RuntimeError: Broken toolchain: cannot link a simple C program.

    Though I don't want to resort to sudo, and I want to stick with homebrew (because I'm really aiming for a homebrewed opencv), so I've had no luck so far.

    Edit: adding export ARCHFLAGS=-Wno-error=unused-command-line-argument-hard-error-in-future to my .bash_profile (as was suggested in the other question I linked) let brew install numpy almost flawlessly. All that remained after was that I had to brew link --overwrite numpy (because I had a non-brew installation of numpy before). Seems to be working now.

提交回复
热议问题