Can't install rubygems - but getting closer

I’m runniing Ubuntu Breezy. The distributed version of ruby is 1.8.3
which is incompatible with the current rails. As a result, I’m trying to
get things up outside of apt. I have ruby installed - compiled to
install to /usr/bin. I’m trying to get rubygems installed, but still not
making it there.

When I run (as root) ruby setup.rb, from the rubygems-0.9.0 directory,
it terminates with

hook /software/rubygems-0.9.0/./post-install.rb failed:
uninitialized constant Gem::Builder::Package

This is further than I’ve been getting, but still not there. I want to
thank those of you for the help you’ve given so far, and need to ask for
some more. Any ideas on how to correct this?

tia
—Michael

Michael S. wrote:

I’m runniing Ubuntu Breezy. The distributed version of ruby is 1.8.3
which is incompatible with the current rails. As a result, I’m trying to
get things up outside of apt. I have ruby installed - compiled to
install to /usr/bin. I’m trying to get rubygems installed, but still not
making it there.

When I run (as root) ruby setup.rb, from the rubygems-0.9.0 directory,
it terminates with

hook /software/rubygems-0.9.0/./post-install.rb failed:
uninitialized constant Gem::Builder::Package

This is further than I’ve been getting, but still not there. I want to
thank those of you for the help you’ve given so far, and need to ask for
some more. Any ideas on how to correct this?

tia
—Michael

Gems for some reason on Debian/Ubuntu seems to want to install in
/usr/lib/ruby instead of /usr/local (rather annoying) I’d take a look
and see if that is what it did?

On Dapper running ruby from the repository and Gems from source I
install gems to /usr/local/lib/site_ruby this way…

export GEM_HOME=/usr/local/lib/site_ruby/1.8/gems
ruby setup.rb config --prefix=/usr/local/
–site-ruby/usr/local/lib/site-ruby
ruby setup.rb setup
ruby setup.rb install

Set necessary environment vars in /etc/environment

Add /usr/local/lib/site-ruby/1.8/gem/bin to the PATH entry
Add GEM_HOME="/usr/local/lib/site_ruby/1.8/gems"

Restart so they take system wide effect

I typed that (quickly) from memory away from my ubuntu box so you may
want to check/alter the directories a bit…

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs