Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 474476 - app-emulation/vagrant breaks with rvm: vagrant box list: /usr/lib64/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require': cannot load such file -- vagrant (LoadError)
Summary: app-emulation/vagrant breaks with rvm: vagrant box list: /usr/lib64/ruby/site...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Tim Harder
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-06-23 11:29 UTC by Benedikt Böhm
Modified: 2013-07-08 00:02 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Benedikt Böhm 2013-06-23 11:29:34 UTC
Since v1.1 vagrant is not distributed as a gem anymore (and ships with its own embedded ruby environment). Gentoo still uses the fakegem install method, which does not create an embedded environment (which is a good thing!).

Unfortunately, this breaks vagrant in rvm and bundler environments.

On MacOS using the dmg package with embedded ruby:

$ rvm tools identifier
ruby-1.9.3-p429
$ vagrant box list
There are no installed boxes! Use `vagrant box add` to add some.
$ rvm system
$ rvm tools identifier
system
$ vagrant box list
There are no installed boxes! Use `vagrant box add` to add some.

On Gentoo using the ebuild:

$ rvm tools identifier
ruby-1.9.3-p429
$ vagrant box list
/usr/lib64/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require': cannot load such file -- vagrant (LoadError)
        from /usr/lib64/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
        from /usr/lib64/ruby/gems/1.9.1/gems/vagrant-1.2.2/bin/vagrant:9:in `<top (required)>'
        from /usr/bin/vagrant:11:in `load'
        from /usr/bin/vagrant:11:in `<main>'
$ rvm system
$ rvm tools identifier
system
$ vagrant box list
There are no installed boxes! Use `vagrant box add` to add some.


This can be solved very easily by adding the following two lines to bin/vagrant (just before require 'vagrant'):

ENV.delete('GEM_HOME')
ENV.delete('GEM_PATH')

The same thing is done by the vagrant installers with embedded ruby.
Comment 1 Tim Harder gentoo-dev 2013-07-08 00:02:55 UTC
Fixed in 1.2.2-r1.