Wednesday, August 17, 2011

How to install ImageMagick in a Mac for MAMP

Hello,

First of all we need some tools:

For installing MacPort download the last version and on a terminal write:
$ sudo port selfupdate
If it doesn't work it's because you need to add the new path to the system PATH variable, ie:
$ export PATH=$PATH:/opt/local/bin
$ export MANPATH=$MANPATH:/opt/local/share/man
$ export INFOPATH=$INFOPATH:/opt/local/share/info
Now, we can install the ImageMagick and GhostScript
$ sudo port install ImageMagick
$ sudo port install ghostscript
Now it's time to configure the MAMP
$ vi /Applications/MAMP/Library/bin/envvars
and comments the lines

#DYLD_LIBRARY_PATH="/Applications/MAMP/Library/lib:$DYLD_LIBRARY_PATH"
#export DYLD_LIBRARY_PATH
and add a new line at the end of the file
export PATH="$PATH:/opt/local/bin"
and done!!!

Try it out
exec(‘convert -resize 640×480 -quality 70 test.eps test.jpg’);

Hope help!

No comments:

Post a Comment