pip install命令导致破坏的工具链错误

时间:2017-02-06 19:08:27

标签: tensorflow

使用pip install安装TensorFlow会生成多条消息,并以Broken toolchain错误结束。以下是成绩单的一部分:

...<lots of warnings and errors>

You have not agreed to the Xcode license agreements, please run 
'xcodebuild -license' (for user-level acceptance) or  
'sudo xcodebuild -license' (for system-wide acceptance) from within a 
Terminal window to review and agree to the Xcode license agreements.

...<more stack trace output>

  File "numpy/core/setup.py", line 653, in get_mathlib_info

    raise RuntimeError("Broken toolchain: cannot link a simple C program")

RuntimeError: Broken toolchain: cannot link a simple C program

1 个答案:

答案 0 :(得分:2)

错误表明 您的系统上安装了Xcode构建工具, 但您尚未接受许可协议。要解决此问题,请执行以下任一操作:

  1. 打开Xcode和 接受许可协议。
  2. 调用以下命令:

    xcodebuild -license
    

    请参阅 xcodebuild documentation了解更多详情。