How to Install ImageMagick and Imagick on Cpanel Server
ImageMagick is the application for working with images while the Imagick is a PHP extention to modify/create images using the ImageMagick API.
ImageMagick Installation:
# cd /usr/local/src/
# wget ftp://ftp.imagemagick.org/pub/ImageMagick/ImageMagick.tar.gz
# tar zxvf ImageMagick.tar.gz
# cd ImageMagick-*
# ./configure
# make
# make install
Then install the perl module:
# cd PerlMagick
# perl Makefile.PL
# make
# make install
You can check the path for the installed ImageMagick by executing the following command:
# which convert
/usr/local/bin/convert
Imagick Installation:
Download the imagick source from pecl.php.net and recomplie it.
# wget http://pecl.php.net/get/imagick-2.3.0.tgz
# tar -zxvf imagick-2.3.0.tgz
# cd imagick-2.3.0
# phpize
# ./configure
# make
# make install
Once the compilation is over you could find the file imagick.so in the /usr/local/lib/php/extensions/no-debug-non-zts-20060613 directory.
So add the extension entry imagick.so in the /usr/local/lib/php.ini file.
Entry will be like this:-
# vi /usr/local/lib/php.ini
==============================
extension_dir = "/usr/local/lib/php/extensions/no-debug-non-zts-20060613"
extension="imagick.so"
==============================
Restart Apache once this is done.
# /scripts/restartsrv_httpd
Thats it. Check the info.php page now.
|