ImageMagick 7 with RMagick 2.16 on MacOS Sierra Can't find MagickWand.h

florigee picture florigee · Jan 14, 2017 · Viewed 10k times · Source

I upgraded to imagemagick-7.0.4-3.sierra and now my previously installed RMagck 2.16 fails. I checked for MagicWand:

$ find /usr/local -name MagickWand.h /usr/local/Cellar/imagemagick/7.0.4-3/include/ImageMagick-7/MagickWand/MagickWand.h

So it seems to be there. Also I reinstalled and relinked pgk-config. Didn't help as well. Any ideas?

Answer

dyson returns picture dyson returns · Jan 19, 2017

I have just encountered and solved this issue on a new Mac running Sierra. There seems to be no solution for ImageMagick 7 at this time.

  1. Uninstall existing imagemagick if needed

  2. Install version 6:

    brew install imagemagick@6

  3. Since this is keg-only, you should then force-link it:

    brew link --force imagemagick@6

This installed imagemagick version 6.9.7-4 for me.

Afterwards, the gem then installed successfully. I am including the version numbers for future readers:

Installing rmagick 2.13.4 with native extensions