Howto: Install Imagick (for php) on Ubuntu 11.10

DJSunny picture DJSunny · Oct 24, 2011 · Viewed 91.5k times · Source

I'm attempting to install ImagicK as its required for a Yii Extension I want to use for my project.

I've checked around and followed a few different suggestions but nothing that has worked so far, ultimately the framework extension is still throwing me an error (Must have ImagicK installed).

I've tried things like:

sudo apt-get update
sudo apt-get install imagick-php5 .. etc

as well as the PECL install which ends up throwing me the following error:

Checking ImageMagick MagickWand API configuration program... configure: error: 
not found. Please provide a path to MagickWand-config or Wand-config program. 

Any help as to how to get ImagicK installed and integrated with PHP on Ubuntu 11.10 would be great.

Thanks in advance!

Answer

mario picture mario · Oct 24, 2011

The package has a different name in Ubuntu.

 sudo apt-get install php5-imagick

The error with building via PECL means you must install libmagickwand-dev, libmagickcore3, libmagickwand3 probably (there are alternatives: graphicsmagick-imagemagick-compat, see Synaptic).