Error while installing ImageMagick for Ruby on Rails on Windows

338 views Asked by At

I'm installing ruby on rails and redmine with xampp following this documentation:

http://nlb-creations.com/2013/06/26/installing-ruby-on-rails-and-redmine-with-xampp-on-windows-7/

Step 12 requires installing rmagick, I followed the steps correctly till I reached 12-d :

In the cmd window, run the following:

gem install rmagick --platform=ruby -- --with-opt-lib=c:/ImageMagick/lib --with-opt-include=c:/ImageMagick/include

I got the following error:

    C:\xampp\htdocs\dev-ruby\redmine>gem install rmagick --platform=ruby -- --with-o
    pt-lib=c:/ImageMagick/lib --with-opt-include=c:/ImageMagick/include

Temporarily enhancing PATH to include DevKit...
Building native extensions.  This could take a while...
ERROR:  Error installing rmagick:
        ERROR: Failed to build gem native extension.

        C:/RailsInstaller/Ruby1.9.3/bin/ruby.exe extconf.rb --with-opt-lib=c:/Im
ageMagick/lib --with-opt-include=c:/ImageMagick/include
checking for Ruby version >= 1.8.5... yes
Invalid drive specification.
Unable to get ImageMagick version
*** 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=${opt-dir}/include
        --with-opt-lib=${opt-dir}/lib
        --with-make-prog
        --without-make-prog
        --srcdir=.
        --curdir
        --ruby=C:/RailsInstaller/Ruby1.9.3/bin/ruby


Gem files will remain installed in C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9
.1/gems/rmagick-2.13.3 for inspection.
Results logged to C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/rmagick-2
.13.3/ext/RMagick/gem_make.out

I downloaded ImageMagick-devel-6.8.9.9.aarch64.rpm cz it might solve my problem but I don't know how to install it. Any ideas please?

1

There are 1 answers

0
Reuben Mallaby On BEST ANSWER

Sounds like you're trying to install the RMagick gem before installing ImageMagick:

The RPM is for certain Linux distributions.

Try installing http://www.imagemagick.org/script/binary-releases.php#windows then the gem.