Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

10.5: Install ImageMagick without Fink or MacPorts UNIX
I needed ImageMagick -- especially as a Ruby GEM -- so I had to somehow get gem install rmagick working, as it didn't work out of the box: Leopard doesn't ship with ImageMagick.

If you've ever tried to install ImageMagick without Fink or MacPorts, you'll have a quite good chance to go completely nuts. Especially the interdependencies of libjpeg and ghostscript are insane. I also wanted to keep the install as small as possible, and therefore I decided against installing the whole ghostscript package (but you may do so if you like).

I created a set of commands that you can copy-and-paste into a shell script, which should install ImageMagick flawlessly on your Mac. Please notice that Mac OS X 10.5.4 (or higher), XCode 3.1 (or higher), and X11 is required. You'll find the shell commands on this page; just copy and paste to use.

Afterwards, sudo gem install rmagick works like a charm for me. Hope this helps!

[robg adds: I haven't tested this one. To use it, click the Download button next to the code, then open the downloaded file (using Firefox 3, the file was named Download on my machine) in your favorite pure text editor. Save the resulting file to somewhere on your Unix $PATH, and remember to make it executable (chmod 755 scriptname), and you should be good to go.]
    •    
  • Currently 2.67 / 5
  You rated: 5 / 5 (9 votes cast)
 
[31,547 views]  

10.5: Install ImageMagick without Fink or MacPorts | 13 comments | Create New Account
Click here to return to the '10.5: Install ImageMagick without Fink or MacPorts' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.5: Install ImageMagick without Fink or MacPorts
Authored by: mario_grgic on Aug 25, '08 07:48:24AM
Why not simply download binary distribution from

http://www.imagemagick.org/script/binary-releases.php#macosx

Is there a problem with it? Does it not include all dependencies?

[ Reply to This | # ]
10.5: Install ImageMagick without Fink or MacPorts
Authored by: Pedro Estarque on Aug 25, '08 08:45:47PM

No it doesn't. I get ghostscript errors when trying to write with some non TrueType fonts. I still use my old, ppc, hard way compiled bins for that.



[ Reply to This | # ]
10.5: Install ImageMagick without Fink or MacPorts
Authored by: tetsuo_ on Aug 25, '08 08:14:16AM

Why not just use MacPorts ?!! ;)



[ Reply to This | # ]
Opinion: Why not MacPorts, and alternative way
Authored by: CuteDaemon on Aug 25, '08 10:00:28AM
MacPorts may be easy to use, but it is not bleeding-edge current with its releases. The Problem I've been having is a small install base for MacPorts. I found multpiple installs for ghostscript, for example. a lot of that included the massive ghostscript documentation if I remember correctly.
I am dealing with installs on private linux servers, and I rather take the direct step in making things work. MacPorts, as fantastic as it is with its somewhat confusing dependancies, creates an additional layer of FUBAR when things go really wrong.
And, *Nix people like it simple, as contradictory as it sounds. Download from supplier, compile from source, with exactly what you need, not additionally "recommended" add-ons -- even taking "variants" into account.

Here are more complete instructions with install script, not as beautifully laid out and adjusted as Bach's pastie:
http://onrails.org/articles/2007/11/03/installing-rmagick-on-leopard-without-macports-or-fink

Quick note about libTIFF, which I recommend using the new beta. Tiff has problems in Leopard, especially on a PowerPC under Leopard, but I digress.

If you are comfortable using terminal, and you have some time on your hands, install DIRECTLY from source.



[ Reply to This | # ]
Opinion: Why not MacPorts, and alternative way
Authored by: Anonymous on Aug 25, '08 05:26:39PM
There are two problems with your argument:
  1. most people don't want "bleeding edge" -- unless you meant "up to date", and not actually "unstable: use at your peril"
  2. Linux systems use package management systems: apt, yum, RHN, whatever. These provide all the dependencies a package needs. MacPorts and Fink replicate this approach, building from source (the Gentoo way)
On a side note, I find it amusing when Mac people claim to know "stuff" about Linux and then show they plainly don't. Please keep it up.

[ Reply to This | # ]
10.5: Install ImageMagick without Fink or MacPorts
Authored by: tonylinde on Aug 25, '08 12:36:30PM

Neither of the above ideas worked for me but this script did. Great work!



[ Reply to This | # ]
10.5: Install ImageMagick without Fink or MacPorts
Authored by: rbates on Sep 16, '08 05:07:20PM

I needed to specify rmagick 2.5.2 manually.

sudo gem install rmagick --version '= 2.5.2'



[ Reply to This | # ]
10.5: Install ImageMagick without Fink or MacPorts
Authored by: thomas_witt on Sep 21, '08 05:57:59AM
Please notice the newer versions of the Ruby rmagick gem (>=2.6.0) require also a newer version of imagemagick.
So instead of curling 6.4.2 when downloading ImageMagick just type:

curl -O 'ftp://ftp.imagemagick.org/pub/ImageMagick/ImageMagick-6.4.3-6.tar.bz2'
That's it.

[ Reply to This | # ]
10.5: Install ImageMagick without Fink or MacPorts
Authored by: sabernar on Sep 29, '08 04:18:46PM

The script works most of the way for me, but then I get this error:

i686-apple-darwin9-gcc-4.0.1: /usr/X11/lib/libX11.6.2.0.dylib: No such file or directory
i686-apple-darwin9-gcc-4.0.1: /usr/X11/lib/libXau.6.0.0.dylib: No such file or directory
i686-apple-darwin9-gcc-4.0.1: /usr/X11/lib/libXdmcp.6.0.0.dylib: No such file or directory
make[1]: *** [magick/libMagickCore.la] Error 1
make: *** [install] Error 2

Any ideas?



[ Reply to This | # ]
10.5: Install ImageMagick without Fink or MacPorts
Authored by: sabernar on Sep 29, '08 04:20:01PM

The script works most of the way for me, but then it poops out at the end with the following error:

i686-apple-darwin9-gcc-4.0.1: /usr/X11/lib/libX11.6.2.0.dylib: No such file or directory
i686-apple-darwin9-gcc-4.0.1: /usr/X11/lib/libXau.6.0.0.dylib: No such file or directory
i686-apple-darwin9-gcc-4.0.1: /usr/X11/lib/libXdmcp.6.0.0.dylib: No such file or directory
make[1]: *** [magick/libMagickCore.la] Error 1
make: *** [install] Error 2

Any ideas?



[ Reply to This | # ]
10.5: Install ImageMagick without Fink or MacPorts
Authored by: rbates on Oct 13, '08 03:08:50PM

Are you attempting to install it on OS X Server? I had the same problem there, but copying those files (and symlinks) from my client to the server seemed to fix it.



[ Reply to This | # ]
10.5: Install ImageMagick without Fink or MacPorts
Authored by: FiXato on Jun 27, '09 05:44:01PM
I updated the script a bit: http://pastie.org/526802
For instance the jpegsrc had to be updated to v7 since v6b wasn't available anymore.

[ Reply to This | # ]
10.5: Install ImageMagick without Fink or MacPorts
Authored by: xth on Aug 12, '09 03:28:46AM
Before trying this, try to install the binaries from the ImageMagick website: http://www.imagemagick.org/script/binary-releases.php#macosx
It worked for me without any problems. I did install the developer DVD from apple in the past, though.

On the other hand, the script in this hint failed at the first hurdle - couldn't even untar freetype-2.*.tar.bz2 -got the message
bzip2: (stdin) is not a bzip2 file

[ Reply to This | # ]