Skip to content

Instantly share code, notes, and snippets.

@eddies
Created May 18, 2011 13:53
Show Gist options
  • Save eddies/978603 to your computer and use it in GitHub Desktop.
Save eddies/978603 to your computer and use it in GitHub Desktop.
RVM + bundle install for gem w/ native extensions fails, but gem install succeeds
$ bundle install
Installing nokogiri (1.4.4) with native extensions /usr/local/rvm/rubies/ree-1.8.7-2011.03/lib/ruby/site_ruby/1.8/rubygems/installer.rb:533:in `build_extensions': ERROR: Failed to build gem native extension. (Gem::Installer::ExtensionBuildError)
/usr/local/rvm/rubies/ree-1.8.7-2011.03/bin/ruby extconf.rb
Gem files will remain installed in /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/nokogiri-1.4.4 for inspection.
Results logged to /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/nokogiri-1.4.4/ext/nokogiri/gem_make.out
from /usr/local/rvm/rubies/ree-1.8.7-2011.03/lib/ruby/site_ruby/1.8/rubygems/installer.rb:486:in `each'
from /usr/local/rvm/rubies/ree-1.8.7-2011.03/lib/ruby/site_ruby/1.8/rubygems/installer.rb:486:in `build_extensions'
from /usr/local/rvm/rubies/ree-1.8.7-2011.03/lib/ruby/site_ruby/1.8/rubygems/installer.rb:159:in `install'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/lib/bundler/source.rb:100:in `install'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/lib/bundler/installer.rb:58:in `run'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/lib/bundler/rubygems_integration.rb:90:in `with_build_args'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/lib/bundler/installer.rb:57:in `run'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/lib/bundler/spec_set.rb:12:in `each'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/lib/bundler/spec_set.rb:12:in `each'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/lib/bundler/installer.rb:49:in `run'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/lib/bundler/installer.rb:8:in `install'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/lib/bundler/cli.rb:222:in `install'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/lib/bundler/vendor/thor/task.rb:22:in `send'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/lib/bundler/vendor/thor/task.rb:22:in `run'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/lib/bundler/vendor/thor/invocation.rb:118:in `invoke_task'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/lib/bundler/vendor/thor.rb:246:in `dispatch'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/lib/bundler/vendor/thor/base.rb:389:in `start'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/bundler-1.0.13/bin/bundle:13
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/bin/bundle:19:in `load'
from /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/bin/bundle:19
$ cat /usr/local/rvm/gems/ree-1.8.7-2011.03@hyhull/gems/nokogiri-1.4.4/ext/nokogiri/gem_make.out
/usr/local/rvm/rubies/ree-1.8.7-2011.03/bin/ruby extconf.rb
$ gem install nokogiriBuilding native extensions. This could take a while...
Successfully installed nokogiri-1.4.4
1 gem installed
@eddies
Copy link
Author

eddies commented May 18, 2011

This is using rvm 1.6.10 and ree-1.8.7 on a CentOS 5.5 derivative and I've duplicated the same error on a separate Ubuntu 11.04 instance.

@jpantuso
Copy link

Did you get anywhere with this? Hitting same issue trying to bundle RedCloth on ree-1.8.7-2011.03

@eddies
Copy link
Author

eddies commented May 21, 2011

No. Downgrading rvm to 1.6.3 on the instances that were exhibiting the problem didn't help either. I ended up bringing up several new CentOS 5.4 instances and haven't seen the problem there. What environment are you running where you're seeing this problem?

@jpantuso
Copy link

OS X 10.6.7

I'm starting to think it is a Bundler issue. If I use Rubygems 1.3.5 I can successfully install the gems that Bundler 1.0.13 is failing on. I need to try downgrading to an older Bundler.

@eddies
Copy link
Author

eddies commented May 23, 2011

I'm using rvm 1.6.3, RubyGems 1.6.2, and Bundler 1.0.13 on OS X 10.6.7 with no problems. I just nuked rvm (rvm implode) and installed the latest 1.6.13 and no problems bundling native gems. I'll try spinning up another Ubuntu instance and see if I can replicate the problem again and if so, try changing RubyGems version down to 1.3.5.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment