-
-
Save oskardotglobal/7c27c2030ca9ddd8f7650324daee5a9f to your computer and use it in GitHub Desktop.
Install Imagemagick with HEIC on DigitalOcean LAMP Ubuntu 20.04
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
sed -Ei 's/^# deb-src /deb-src /' /etc/apt/sources.list | |
apt-get update | |
apt-get -y install build-essential autoconf libtool git-core | |
apt-get -y build-dep imagemagick libmagickcore-dev libde265 libheif | |
cd /usr/src/ | |
git clone https://github.com/strukturag/libde265.git | |
git clone https://github.com/strukturag/libheif.git | |
cd libde265/ | |
./autogen.sh | |
./configure | |
make | |
make install | |
cd /usr/src/libheif/ | |
./autogen.sh | |
./configure | |
make | |
make install | |
cd /usr/src/ | |
wget https://www.imagemagick.org/download/ImageMagick.tar.gz | |
tar xf ImageMagick.tar.gz | |
cd ImageMagick-7* | |
./configure --with-heic=yes | |
make | |
make install | |
ldconfig | |
apt-get -y install php-imagick | |
cd /usr/src/ | |
wget http://pecl.php.net/get/imagick-3.5.1.tgz | |
tar -xvzf imagick-3.5.1.tgz | |
cd imagick-3.5.1/ | |
apt install php7.4-dev | |
phpize | |
./configure | |
make | |
make install | |
phpenmod imagick | |
systemctl restart apache2 | |
php -r 'phpinfo();' | grep HEIC |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment