【问题标题】:Getting an error trying to install a particular gem 'oily_png (1.2.0)' MAC OS X El Capitan尝试安装特定 gem 'oily_png (1.2.0)' MAC OS X El Capitan 时出错
【发布时间】:2016-01-22 10:09:52
【问题描述】:

我在 mac OS X El Capitan 上,尝试运行 bundle install 后出现以下错误:

谁能帮我解决这个问题?

【问题讨论】:

  • 您最近安装了 10.11 吗?或者升级它或Xcode?在终端中尝试“xcode-select --install”,看看是否有帮助
  • 我最近安装了 10.11,现在可能是几周前。我正在尝试安装,希望它能修复它。谢谢。
  • 谢谢 Doon,这解决了问题!想要将其作为答案发布,以便我可以将其作为答案进行验证?

标签: ruby-on-rails ruby rubygems osx-elcapitan


【解决方案1】:

在 Mac 上,只要您升级 Xcode 或操作系统,命令行工具似乎就有可能被删除。

 xcode-select --install 

在终端窗口中,将安装工具,这也可以在 xcode 应用程序中完成。

[~] xcode-select -h
Usage: xcode-select [options]

Print or change the path to the active developer directory. This directory
controls which tools are used for the Xcode command line tools (for example,
xcodebuild) as well as the BSD development commands (such as cc and make).

Options:
  -h, --help                  print this help message and exit
  -p, --print-path            print the path of the active developer directory
  -s <path>, --switch <path>  set the path for the active developer directory
  --install                   open a dialog for installation of the command line developer tools
  -v, --version               print the xcode-select version
  -r, --reset                 reset to the default command line tools path

如果您安装了一组以上的工具(例如测试版),-s, --switch 标志也有助于将其指向您要使用的工具(或者如果它指向的版本已被删除)

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2016-04-14
    • 2016-04-22
    • 2016-08-26
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2015-11-05
    相关资源
    最近更新 更多