TLDR:
xcode-select --install
In OS X 10.9, the command line developer tools are now installed on demand when they are used (this is the popup you mention seeing in a later comment).
The first time something tries to use one of the command line tools, the popup will be presented and the original command will return with a message that the command line tools need to be installed and with an error code. In this case, the problem is that the ruby process is hiding the message about the command line tools being needed.
If you wish to explicitly install the command line tools (instead of waiting for the popup to be triggered), you can run xcode-select --install
. The command line tools package is also available as an independent download from http://developer.apple.com/downloads.
Note that if you have Xcode installed on your system, you should no longer need the separate command line tools package, the tools in /usr/bin will automatically use the ones located inside of the Xcode application. This is why the Xcode UI no longer offers the option to install the command line tools for you.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…