There's an echo in my head

日々のメモ。

ImageMagickでLittle CMSを扱った処理を行うために

こんなエラーが出たとき、Little CMSのライブラリに対応できていない。

convert: delegate library support not built-in `/path/to/jpg' (LCMS) @ warning/profile.c/ProfileImage/565.

対応しているdelegateは次のコマンドで確認できる。

$ convert -list configure | grep -i "delegates"
DELEGATES      bzlib freetype jpeg jng lcms2 png tiff xml zlib

対応するにはLCMSのライブラリを入れた上でImageMagickをビルドする。Homebrewだとこんな感じで、--with-little-cmsオプションをつける。

$ brew install lcms2
$ brew install imagemagick --with-ghostscript --with-libtiff --with-little-cms
このブログに出てくるコードスニペッツは、引用あるいは断りがない限りMITライセンスです。