带有rbenv的'bundle install'会多次导致相同的错误消息

时间:2015-01-19 14:16:21

标签: ruby macos gem bundler rbenv

在Mac OSX Yosemite上,我在运行' bundle install'时多次出现以下错误。

我的过程......

$ brew install rbenv
$ brew install ruby-build
$ rbenv install 2.1.2
$ rbenv rehash
$ bundle install
$ rbenv rehash
$ cd myrepos 
$ bundle install

ERROR!

Gem files will remain installed in /Users/user/.gem/ruby/2.1.0/gems/debase-0.0.9 for inspection.
Results logged to /Users/user/.gem/ruby/2.1.0/extensions/x86_64-darwin-14/2.1.0-static/debase-0.0.9/gem_make.out
from /Users/user/.rbenv/versions/2.1.2/lib/ruby/2.1.0/rubygems/ext/ext_conf_builder.rb:38:in `block in build'
from /Users/user/.rbenv/versions/2.1.2/lib/ruby/2.1.0/tempfile.rb:324:in `open'

...

from /Users/user/.rbenv/versions/2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:132:in `rescue in require'
from /Users/user/.rbenv/versions/2.1.2/lib/ruby/2.1.0/rubygems/core_ext/kernel_require.rb:144:in `require'
from extconf.rb:24:in `<main>'

extconf failed, exit code 1

1 个答案:

答案 0 :(得分:0)

只需删除~/.gem

我试过跟随。但是它们对这个问题没有意义。

  • 更新xcode
  • 将gcc更改为clang
  • 重新安装ruby

似乎~/.gem导致运行rbenv包时出错。