Skip to content

RMagick fails to install with ImageMagick 7 #41

Description

@fiznool
$ sudo gem install screengif
Fetching: rmagick-2.16.0.gem (100%)
Building native extensions.  This could take a while...
ERROR:  Error installing screengif:
	ERROR: Failed to build gem native extension.

    /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby extconf.rb
checking for xcrun... yes
checking for Magick-config... no
checking for pkg-config... yes
checking for outdated ImageMagick version (<= 6.4.9)... no
checking for presence of MagickWand API (ImageMagick version >= 6.9.0)... no
checking for Ruby version >= 1.8.5... yes
checking for stdint.h... yes
checking for sys/types.h... yes
checking for wand/MagickWand.h... no

Can't install RMagick 2.16.0. Can't find MagickWand.h.
*** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers.  Check the mkmf.log file for more details.  You may
need configuration options.

Provided configuration options:
	--with-opt-dir
	--without-opt-dir
	--with-opt-include
	--without-opt-include=${opt-dir}/include
	--with-opt-lib
	--without-opt-lib=${opt-dir}/lib
	--with-make-prog
	--without-make-prog
	--srcdir=.
	--curdir
	--ruby=/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/bin/ruby


Gem files will remain installed in /Library/Ruby/Gems/2.0.0/gems/rmagick-2.16.0 for inspection.
Results logged to /Library/Ruby/Gems/2.0.0/gems/rmagick-2.16.0/ext/RMagick/gem_make.out

The issue is due to the fact that ImageMagick 7 has moved its headerfiles and RMagick can't find them when compiling.

The easiest thing I've found to do is to use imagemagick 6 until the upstream issue is fixed.

brew uninstall imagemagick
brew install imagemagick@6 && brew link imagemagick@6 --force

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions