Douglas F Shearer

Installing RMagick on Ubuntu Dapper


Having played around with the latest version of the popular Ubuntu distribution in the last week or so, I thought I’d give a quick guide to installing RMagick. Unlike Breezy, Dapper doesn’t seem to work to well with the RMagick Gem (Norman Timmier has some great advice on installing RMagick under Breezy). Instead, use the following apt-get package command (It’s all one line) to get you up and running…

$ sudo apt-get install imagemagick libmagick9 librmagick-ruby-doc librmagick-ruby1.8

That should see you good. Now if you have the irb package you can test that RMagick is indeed loaded. If you don’t have irb installed, install it as so…

$ sudo apt-get install irb

Now you can test RMagick, remembering that the capitalisation is important here…


$ irb
> require 'RMagick'
=> true
> exit

Updated: If it returns true as in the above example, all is good. If you don’t get the true result, something has gone wrong with the installation, best try again it might still be ok, see Tim Hunter’s comment below to see why, thanks Tim.

I hope this guide makes the installation slightly easier for someone, it took me a while when I transitioned to Dapper, I was still used to using the gem like I do on the Mac.

Did you like my Ruby on Rails related article? Then why not recommend me on Working with Rails?

Tags

, , , .

Related Posts

October 5th 2006 11:47 | comments (2)
 

Comments


Gravatar

Tim Hunter

October 6th 2006 00:13

Glad to see you got RMagick installed okay! One small correction: if "require" returns false that doesn't necessarily mean that something's wrong, it just means that the library is already loaded. If require can't load a library it raises a LoadError exception. This is true for any library, not just RMagick.

Gravatar

Douglas F Shearer

October 6th 2006 19:24

Thanks Tim, I've updated the article to convey this. Explains why I've seen errors using this method to verify the installation of other libraries that were definitely installed.

Add Your Comments


(Required)

Your email address to get your Gravatar. Address itself is not shown.

(Include the http://)

(Required)

 

You Are Here


Douglas F Shearer

This is the homepage of Douglas F Shearer, a software developer and mountainbike racer. Find out more at the About page.

Gallery Latest


Side on Chips on crown Front on chip2 chip1 img67

Stay Informed


What is RSS?

Top Tags