strapyourself.in and flouri.sh

Installing RMagick properly in OSX

February 24th, 2007

I've seen the craziest problems with people installing the RMagick gem before. In this article, I will show you the procedure I use to fix any and all rmagick problems. First, I start by cleaning out any of the following packages:

sudo port uninstall imagemagick
sudo port uninstall graphicsmagick
sudo port uninstall ghostscript
sudo port uninstall freetype
sudo gem uninstall rmagick

Then, I reinstall them:

sudo port install freetype
sudo port install ghostscript
sudo port install imagemagick
sudo port install graphicsmagick
sudo gem install rmagick

This software cocktail has solved the following problems:

  • RMagick gem won't compile native extensions
  • RMagick can't find fonts - This is a really common problem, and we have seen a case where this approach will not solve this problem.
  • RMagick renders text incorrectly and/or unreadable in the validates_captcha plugin

ImageScience is an alternative to RMagick which requires fewer native libraries, but not zero unfortunately. It may or may not be easier for you to use, depending on what you need RMagick for (it won't do text rendering, for example).

Originally posted on ELC

Sorry, comments are closed for this article.

original design by gorotron ported by railsgrunt powered by mephisto