error: could not create '/System/Library/Frameworks/Python.framework/Versions/2.7/share': Operation not permitted

在OSX下用pip安装networkx时报错:

error: could not create '/System/Library/Frameworks/Python.framework/Versions/2.7/share': Operation not permitted

原因:因为EI Captain引入了SIP管理机制,所以旧版本的pip创建的文件目录操作被拒绝,包括使用root也是如此。

解决方法是:

sudo pip install networkx --user

加上--user参数解决问题。

相关文章:

  • 2021-06-05
  • 2022-12-23
  • 2021-08-24
  • 2021-11-06
  • 2021-09-15
  • 2021-07-27
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2021-12-16
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案