can't install rmagick

Tried 'gem install rmagick'

Got

Installing latest IM. Hopefully that will solve it.

Just to add my two cents:

I am using Ubuntu 10.04. I followed following steps to get "rmagick" to
install properly.

1. Used Synaptic and removed following packages by selecting... "Mark
for complete removal"
- graphicsmagick
- imagemagick
- associated development libraries (searched for imagemagick-deve)
2. Re-installed libmagick++-dev which installed all other dependencies.
3. Tried installing "rmagick" and this time got success.

Please let me know, if this worked for you.