I understand that this question has been asked a lot earlier, but none of the solutions worked for me and I'm really desperate right now.
I'm trying to get rMagick to install using gem for an installation of diaspora. I already installed imagick via homebrew and when trying to run gem install rmagick I receive this error:
ERROR: Error installing rmagick:
ERROR: Failed to build gem native extension.
/Users/tobischweiger/.rvm/rubies/ruby-1.9.3-p385/bin/ruby extconf.rb
checking for Ruby version >= 1.8.5... yes
checking for gcc-4.2... yes
checking for Magick-config... no
Can't install RMagick 2.13.2. Can't find Magick-config in /Users/tobischweiger/.rvm/gems/ruby-1.9.3-p385@diaspora/bin:/Users/tobischweiger/.rvm/gems/ruby-1.9.3-p385@global/bin:/Users/tobischweiger/.rvm/rubies/ruby-1.9.3-p385/bin:/Users/tobischweiger/.rvm/bin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/opt/X11/bin:/usr/local/git/bin
*** 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=/Users/tobischweiger/.rvm/rubies/ruby-1.9.3-p385/bin/ruby
Gem files will remain installed in /Users/tobischweiger/.rvm/gems/ruby-1.9.3-p385@diaspora/gems/rmagick-2.13.2 for inspection.
Results logged to /Users/tobischweiger/.rvm/gems/ruby-1.9.3-p385@diaspora/gems/rmagick-2.13.2/ext/RMagick/gem_make.out
I'm not very experienced with gem and homebrew and I'm wondering if somebody could help me out.
Run this (using homebrew) before attempting to install the gem.
brew install imagemagick
This is the less destructive version using homebrew, rmagic also doesn't work with imagemacigk version 7
ImageMagick Version 6.4.9 or later (6.×.x). Version 7 is NOT yet supported; ETA April 2019 (https://github.com/rmagick/rmagick/pull/299 )
(from Readme)
. You can get ImageMagick from www.imagemagick.org., so with brew try this
brew install imagemagick@6
PKG_CONFIG_PATH=/usr/local/opt/imagemagick@6/lib/pkgconfig gem install rmagick
I'm using OS X Lion.
I ran brew doctor
and saw that imagemagick was unlinked so it told me to run brew link imagemagick
.
Then I closed and re-opened my terminal and everything worked thankfully.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With