Skip to content

Instantly share code, notes, and snippets.

@sjelfull
Last active March 28, 2020 05:37
Show Gist options
  • Star 11 You must be signed in to star a gist
  • Fork 6 You must be signed in to fork a gist
  • Save sjelfull/69136fe74339025aa151 to your computer and use it in GitHub Desktop.
Save sjelfull/69136fe74339025aa151 to your computer and use it in GitHub Desktop.
Installing Imagick with PHP 7

1. Download the phpseven branch of the imagick repository

git clone https://github.com/mkoppanen/imagick.git imagick

2. phpize for target PHP version

cd imagick && /path/to/php7/bin/phpize && ./configure && make && make install

3. Enable the extension for your PHP version

echo "extension=imagick.so" >> /path/to/php.ini

4. Restart PHP / Apache (I run php-fpm)

For php-fpm:

service php5-fpm restart

For apache, something like:

sudo apache2ctl graceful

@avatec
Copy link

avatec commented Apr 24, 2019

@mirko77 check my reply: https://stackoverflow.com/questions/11865600/imagemagick-brew-installation-with-php-module-in-mac-os-x/55656378#55656378

I've found solution and compile imagick using my method. Look at third answer (Grzegorz)

@mirko77
Copy link

mirko77 commented Apr 24, 2019

@avatec many thanks, I managed to install it using one of the methods mentioned among the answers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment