Skip to content

Instantly share code, notes, and snippets.

@jrep
Created October 3, 2011 22:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jrep/1260402 to your computer and use it in GitHub Desktop.
Save jrep/1260402 to your computer and use it in GitHub Desktop.
Can't "gem install bundler" under rvm
On RHEL 5.2, I can't do various bundler-related things under "rvm use 1.9.2-p180@rails". works fine under "rvm system". Where should I look for cause?
Example:
% rvm system
% gem install bundler # works
% rvm use 1.9.2-p180@rails
% gem install bundler
ERROR: Loading command: install (LoadError)
no such file to load -- zlib
ERROR: While executing gem ... (NameError)
uninitialized constant Gem::Commands::InstallCommand
Google led me to stack overflow:
% yum install zlib zlib1g zlib1g-dev # googled advice, for ubuntu
Package zlib - 1.2.3-3.x86_64 is already installed.
Package zlib - 1.2.3-3.i386 is already installed.
No package zlib1g available.
No package zlib1g-dev available.
Nothing to do
Since it works under "rvm system," this doesn't seem compellingly explanatory,but maybe?
@jrep
Copy link
Author

jrep commented Oct 3, 2011

OK, some progress: under 'rvm system', irb can find zlib, but under "rvm use 1.9.2-p180@rails" it can't

ruby-1.9.2-p180 :001 > require 'zlib'
LoadError: no such file to load -- zlib
from /usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in require' from /usr/local/rvm/rubies/ruby-1.9.2-p180/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:inrequire'
from (irb):1
from /usr/local/rvm/rubies/ruby-1.9.2-p180/bin/irb:16:in `

'

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