$ sudo apt install libjpeg-dev
$ sudo apt install libpng-dev
$ git clone https://github.com/ImageMagick/ImageMagick.git $ cd ImageMagick $ ./configure --with-modules $ make $ sudo make install $ sudo ldconfig /usr/local/lib