hash_bucket()

Archive for January 2010

Installing Ruby / Gems (/ Rails) from the Debian packages is very convenient and nice, but the versions are old. If you want to stay on top of things, naturally you will want to install from source, but many who do run into the error below, when trying to install / update gems after a fresh install.

$ gem update --system
/usr/local/lib/ruby/site_ruby/1.9.1/rubygems/spec_fetcher.rb:1:in \
        `require': no such file to load -- zlib (LoadError)

The cause for this and a remedy has been suggested in the following thread (Bug#1090):

http://redmine.ruby-lang.org/issues/show/1090

Not sure if I agree with the thread that this is a bug because ruby doesn’t complain loud enough about the missing zlibs, but here’s the concise solution anyway:

Essentially, unless you first install the zlib packages ruby will build without them, so this is the first step:

apt-get install zlib1g zlib1g-dev zlibc libzlib-ruby

next, when you ./configure ruby, add the –prefix =/usr/local

$ cd 'your ruby source dir'
$ ./configure --prefix=/usr/local

next make, make test, make install and you should be able to

$ gem update --system

without problems.

あけおめ!!

こと

よろ!!


.

This blog has no clear focus. It has a focus though, it's just not very clear at the moment...

Dev Env.

Visual Studio 2008 Prof / NUnit / Gallio / csUnit / STools (ExactMagic) / doxygen / dxCore / TypeMock / TestDriven.net / SequenceViz / CLRProfiler / Snoop / Reflector / Mole / FxCop / Subversion / TortoiseSVN / SlikSVN / CruiseControl.net / msbuild / nant

Blog Stats

  • 81,346 hits