What is the easiest way to install ImageMagick on CentOS?

logicsupport

Well-Known Member
Jun 5, 2007
138
0
166
How to install imagemagic in cpanel

In a cpanel server you can install imagemagic very easily using

/scripts/installimagemagick
 

DomineauX

Well-Known Member
PartnerNOC
Apr 12, 2003
425
11
168
Houston, TX
cPanel Access Level
Root Administrator
yum install ImageMagick will work to install very outdated versions (6.0.7 on Cent4 and 6.2.8 on Cent5).

Using /scripts/installimagemagick will install 6.4.8 which is outdated but only a bit over a year so it is better.

I have suggested a CentOS RPM to ImageMagick.org and they have replied confirming that it would be useful and easy to provide (since they themselves already build one for their own CentOS servers) and that they will add it to their Binary packages in the next day or two.
 

WiredTree Joe

Well-Known Member
Dec 13, 2006
68
1
158
Chicago, IL
What is the easiest way to install ImageMagick on CentOS?
The easiest way is using /scripts/installimagemagick or using an RPM as already stated, but if you require one of the most recent versions a source install is always an option. I had to do this on my personal cPanel/WHM CentOS 5.x server a few weeks ago.

Use at your own risk!
Code:
yum remove ImageMagick
yum install tcl-devel libpng-devel libjpeg-devel ghostscript-devel bzip2-devel freetype-devel libtiff-devel
mkdir /root/imagemagick
cd /root/imagemagick
wget ftp://ftp.imagemagick.org/pub/ImageMagick/ImageMagick.tar.gz
tar xzvf ImageMagick.tar.gz
cd ImageMagick-*
./configure --prefix=/usr/ --with-bzlib=yes --with-fontconfig=yes --with-freetype=yes --with-gslib=yes --with-gvc=yes --with-jpeg=yes --with-jp2=yes --with-png=yes --with-tiff=yes
make
make install
Test your install

Code:
[[email protected]:~]$ whereis convert
convert: /usr/bin/convert /usr/man/man1/convert.1 /usr/share/man/man1/convert.1
[[email protected]:~]$ convert --version
Version: ImageMagick 6.6.1-2 2010-04-10 Q16 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2010 ImageMagick Studio LLC
Features: OpenMP

You can add in your custom configure options as needed in the configure line above. If you want to "uninstall" your build, you can always run:

Code:
cd /root/imagemagick/ImageMagick-*
make uninstall
Following the same steps on a x86_64 CentOS 5 server, I ran into some lib issues and they were fixed with the below commands.

Code:
cd /usr/lib64
ln -s ../lib/libMagickCore.so.3 libMagickCore.so.3 
ln -s ../lib/libMagickWand.so.3 libMagickWand.so.3
Your mileage may vary. I consider installing from source to be a last resort to get the versions you require when using CentOS/RHL.

I have suggested a CentOS RPM to ImageMagick.org and they have replied confirming that it would be useful and easy to provide (since they themselves already build one for their own CentOS servers) and that they will add it to their Binary packages in the next day or two.
It would be nice to see some official RPM builds of the most recent versions of IM from ImageMagick.org.
 

AndyReed

Well-Known Member
PartnerNOC
May 29, 2004
2,221
4
193
Minneapolis, MN
Last edited:

dolay

Member
Apr 28, 2004
12
0
151
the easiest way is using /scripts/installimagemagick or using an rpm as already stated, but if you require one of the most recent versions a source install is always an option. I had to do this on my personal cpanel/whm centos 5.x server a few weeks ago.

use at your own risk!
Code:
yum remove imagemagick
yum install tcl-devel libpng-devel libjpeg-devel ghostscript-devel bzip2-devel freetype-devel libtiff-devel
mkdir /root/imagemagick
cd /root/imagemagick
wget ftp://ftp.imagemagick.org/pub/imagemagick/imagemagick.tar.gz
tar xzvf imagemagick.tar.gz
cd imagemagick-*
./configure --prefix=/usr/ --with-bzlib=yes --with-fontconfig=yes --with-freetype=yes --with-gslib=yes --with-gvc=yes --with-jpeg=yes --with-jp2=yes --with-png=yes --with-tiff=yes
make
make install
test your install

Code:
[[email protected]:~]$ whereis convert
convert: /usr/bin/convert /usr/man/man1/convert.1 /usr/share/man/man1/convert.1
[[email protected]:~]$ convert --version
version: Imagemagick 6.6.1-2 2010-04-10 q16 http://www.imagemagick.org
copyright: Copyright (c) 1999-2010 imagemagick studio llc
features: Openmp

you can add in your custom configure options as needed in the configure line above. If you want to "uninstall" your build, you can always run:

Code:
cd /root/imagemagick/imagemagick-*
make uninstall
following the same steps on a x86_64 centos 5 server, i ran into some lib issues and they were fixed with the below commands.

Code:
cd /usr/lib64
ln -s ../lib/libmagickcore.so.3 libmagickcore.so.3 
ln -s ../lib/libmagickwand.so.3 libmagickwand.so.3
your mileage may vary. I consider installing from source to be a last resort to get the versions you require when using centos/rhl.



It would be nice to see some official rpm builds of the most recent versions of im from imagemagick.org.
bad ass helper ;)