I've installed ImageMagick with ImageMagick installer script https://github.com/maddox/magick-installer. I am on OSX Lion 10.7, using RVM, Ruby 1.9.3p125.
The problem seems to be with MagickWand.h here is the complete log
/Users/pdjimeno/.rvm/rubies/ruby-1.9.3-p125/bin/ruby extconf.rb
checking for Ruby version >= 1.8.5... yes
extconf.rb:128: Use RbConfig instead of obsolete and deprecated Config.
checking for /usr/bin/gcc... yes
checking for Magick-config... yes
checking for ImageMagick version >= 6.4.9... yes
checking for HDRI disabled version of ImageMagick... yes
Package MagickCore was not found in the pkg-config search path.
Perhaps you should add the directory containing `MagickCore.pc'
to the PKG_CONFIG_PATH environment variable
No package 'MagickCore' found
Package MagickCore was not found in the pkg-config search path.
Perhaps you should add the directory containing `MagickCore.pc'
to the PKG_CONFIG_PATH environment variable
No package 'MagickCore' found
Package MagickCore was not found in the pkg-config search path.
Perhaps you should add the directory containing `MagickCore.pc'
to the PKG_CONFIG_PATH environment variable
No package 'MagickCore' found
Package MagickCore was not found in the pkg-config search path.
Perhaps you should add the directory containing `MagickCore.pc'
to the PKG_CONFIG_PATH environment variable
No package 'MagickCore' found
checking for stdint.h... yes
checking for sys/types.h... yes
checking for wand/MagickWand.h... no
Can't install RMagick 2.13.1. 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
--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=/Users/pdjimeno/.rvm/rubies/ruby-1.9.3-p125/bin/ruby
I tried everything, but what ended up being the solution was:
brew uninstall --force imagemagick
# removes all versionsthen
brew install imagemagick@6
finally
gem install rmagick
At the time of writing this, imagemagick 7 is the default version installed via
brew install imagemagick
, but is incompatible withrmagick
. Fix this by:brew uninstall imagemagick
brew install imagemagick@6
sudo
depending on your config)PKG_CONFIG_PATH=/usr/local/opt/imagemagick@6/lib/pkgconfig gem install rmagick
Also found a solution using homebrew:
and then
For what it is worth I had this problem with Ruby ree-1.8.7-2012-02. Here's how I fixed it:
I removed ImageMagick and re-installed it
I then added these symbolic links in /usr/local/Cellar/imagemagick/6.8.9-7/lib/
I then removed the Ruby version and re-installed it
Finally installed the Gem
Hope this helps.
I suggest that you use brew to manage your binary dependencies. You can easily install imageMagick with brew, like this:
This is what I have on my system:
And I have the same setup as you have in terms of machine and ruby-version.
1) install by installer
http://cactuslab.com/imagemagick/
2) try gem install rmagick
if checking for wand/MagickWand.h... no
type
find some thing like
and type in terminal
if, after that you have this error (because a had it) "Package MagickCore was not found in the pkg-config search path."
type
find some thing like /opt/ImageMagick/lib/pkgconfig/MagickCore.pc
and finally in terminal type: