Install php imagick extension on CentOS

03 Mar 2014

  1. Download souce code

    tar xzfv imagick-3.1.2.tgz 
    cd imagick-3.1.2
  2. Install ImageMagick-devel first.

    yum install ImageMagick-devel
  3. Build

    ./configure --with-php-config=/usr/local/php/bin/php-config 
    make install
  4. Copy to extension directory.

    If you do not know the path, find it out by (or change it in php.ini):

    php -i | grep "extension_dir"

    Then, edit php.ini, add

    If you run php in a webserver, restart the it, for example:

    sudo service httpd restart
  5. Done.

The motto:

  • Quick money is not the solution.

  • You must plan ahead.

  • You should see the bigger picture.

comments powered by Disqus