External tools needed for shrinking.

Tools

JPEG:

GIF:

  • Gifsicle: used only for optimizing animated GIFs

PNG:

SVG:

Installable packages

Most of above tools can be found already packaged in distributions repositories. Here is a probably incomplete list known to the author (contributions for other distributions or missing packages are very welcome).

Linux

Packages for Ubuntu:

  • libjpeg-progs (includes jpegtran)
  • jpegoptim
  • gifsicle
  • optipng
  • advancecomp
  • pngcrush

Packages for CentOS:

  • jpegtran: libjpeg
  • jpegoptim: can’t find rpm on internet
  • gifsicle: gifsicle package on repoforge
  • optipng: optipng package in EPEL
  • advancecomp: advancecomp package on repoforge
  • pngcrush: pngcrush package on repoforge

OS X

Brew for OS X:

  • jpeg
  • jpegoptim
  • mozjpeg
  • gifsicle
  • optipng
  • advancecomp
  • pngcrush
  • pngquant

Alternative installation on OS X (limited only to tools that come with ImageOptim): Install ImageOptim and then symlink from /usr/bin/ to all the required packages::

ln -s /Applications/ImageOptim.app/Contents/MacOS/advpng
ln -s /Applications/ImageOptim.app/Contents/MacOS/gifsicle
ln -s /Applications/ImageOptim.app/Contents/MacOS/jpegoptim
ln -s /Applications/ImageOptim.app/Contents/MacOS/jpegtran
ln -s /Applications/ImageOptim.app/Contents/MacOS/optipng
ln -s /Applications/ImageOptim.app/Contents/MacOS/pngcrush