Summary: | dev-ruby/racc-1.4.6-r1 fails to install : -e:1: uninitialized constant Gem (NameError) | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Andreas K. Hüttel <dilfridge> |
Component: | Current packages | Assignee: | Gentoo Ruby Team <ruby> |
Status: | RESOLVED NEEDINFO | ||
Severity: | normal | ||
Priority: | Normal | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: | emerge --info output |
Description
Andreas K. Hüttel
2012-05-23 22:27:46 UTC
I can't reproduce this. Which version of rubygems do you have installed? Is RUBYOPT environment variable set up properly? (In reply to comment #1) > I can't reproduce this. Which version of rubygems do you have installed? dev-ruby/rubygems-1.8.24 > Is > RUBYOPT environment variable set up properly? pinacolada ~ # set|grep RUBY RUBYOPT=-rauto_gem Where is it documented? (In reply to comment #2) > pinacolada ~ # set|grep RUBY > RUBYOPT=-rauto_gem > > Where is it documented? I'm not sure it is documented. It is set as part of the environment by dev-lang/ruby to ensure that rubygems are loaded automatically. It's something that commonly goes wrong when people chroot or something similar. Can you try this (which is the command failing in the eclass). That should fail due to the bogus filename, but the failure you are reporting happens earlier anyway. ruby -r yaml -e "puts Gem::Specification.from_yaml(File::open('bogus').read).to_ruby" pinacolada ~ # ruby -r yaml -e "puts Gem::Specification.from_yaml(File::open('bogus').read).to_ruby" -e:1:in `initialize': No such file or directory - bogus (Errno::ENOENT) from -e:1:in `open' from -e:1 Same as normal user... (In reply to comment #4) > pinacolada ~ # ruby -r yaml -e "puts > Gem::Specification.from_yaml(File::open('bogus').read).to_ruby" > -e:1:in `initialize': No such file or directory - bogus (Errno::ENOENT) So that works as expected. I'm really not sure why this won't work from within the ebuild then. Interestingly, in the ebuild environment file, RUBYOPT is empty... ... and after setting in make.conf RUBYOPT=-rauto_gem the build worked fine... ?:| (In reply to comment #6) > Interestingly, in the ebuild environment file, RUBYOPT is empty... > > ... and after setting in make.conf > RUBYOPT=-rauto_gem > > the build worked fine... ?:| Perhaps this was a new install and the environment wasn't re-read after installing dev-lang/ruby (and thus the RUBYOPT variable wasn't set yet)? (In reply to comment #7) > (In reply to comment #6) > > Interestingly, in the ebuild environment file, RUBYOPT is empty... > > > > ... and after setting in make.conf > > RUBYOPT=-rauto_gem > > > > the build worked fine... ?:| > > Perhaps this was a new install and the environment wasn't re-read after > installing dev-lang/ruby (and thus the RUBYOPT variable wasn't set yet)? Definitely not, this is my main dev system, continuously updated for a year at least... For me the problem is solved now, but I'm just not sure, is RUBYOPT supposed to be set in make.conf ? (In reply to comment #8) > For me the problem is solved now, but I'm just not sure, is RUBYOPT supposed > to be set in make.conf ? It is set in /etc/env.d/10rubygems, which is installed by dev-ruby/rubygems. Closing this old bug since it is not clear if there was something that we could fix. |