furufuru / ccsr.u-tokyo.ac.jp wrote:
> Hello all,
> 
> I'm using Ruby on Debian GNU/Linux.  Ruby itself
> and its standard library were installed as Debian
> packages.  Now, I want to add Ruby libraries
> which aren't standard part of Ruby.  What do
> people do?  I heard of "rubygem".  Is it a packaging
> system for Ruby?  How does it interact with the
> packaging system of Debian?

I'm using gems on Ubuntu (and were using it on debian as well).

You will have to manually install rubygems from source, but this will be
easy, after installing ruby-dev (with aptitude).

On Ubuntu I'm havin the following ruby packages installed via aptitude:
> i A libreadline-ruby1.8             - Readline interface for Ruby 1.8
> i A libruby1.8                      - Libraries necessary to run Ruby 1.8
> i   ruby                            - An interpreter of object-oriented scriptin
> i   ruby1.8                         - Interpreter of object-oriented scripting l
> i   ruby1.8-dev                     - Header files for compiling extension modul

Rubygems:
> *** LOCAL GEMS ***
> 
> coverage (0.3)
>     identifies inactive code
> 
> sources (0.0.1)
>     This package provides download sources for remote gem installation

This is an example for a library that is not available as a Debian package.

Debian packages on the other hand need to pass some procedure to be
included in the stable or testing branch, so it could take some time for
new libraries to show up.

Rubygems and debian packages are independent (they don't know about each
other), be careful if you both install a library via rubygems and debian
package management (should be: don't do this).

> I could just download the sources of those libraries
> and install them under ~/lib/ruby or /usr/local/lib/ruby
> or some such places.  But, I guess there are better,
> more organized, and standard ways.

There is http://raa.ruby-lang.org/ as well, but I haven't used it.

Using rubygems is working fine for me.