[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

OSX: Can't install RMagick. Can't find the ImageMagick lib

Joshua Muheim

10/28/2008 6:18:00 PM

Hi all

I'm trying to install RMagick because one of my used plugins for RoR
needs it. But I have no idea how to do this. So I just tried

sudo gem install rmagick

But I'm getting the following error:

Building native extensions. This could take a while...
ERROR: Error installing rmagick:
ERROR: Failed to build gem native extension.

/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
extconf.rb install rmagick
checking for Ruby version >= 1.8.2... yes
checking for gcc... yes
checking for Magick-config... yes
checking for ImageMagick version >= 6.3.0... yes
checking for HDRI disabled version of ImageMagick... yes
checking for stdint.h... yes
checking for sys/types.h... yes
checking for magick/MagickCore.h... yes
checking for InitializeMagick() in -lMagick... no
checking for InitializeMagick() in -lMagickCore... no
checking for InitializeMagick() in -lMagick++... no
Can't install RMagick 2.7.0. Can't find the ImageMagick library or one
of the dependent libraries. Check the mkmf.log file for more detailed
information.

*** 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/1.8/usr/bin/ruby
--with-Magicklib
--without-Magicklib
--with-MagickCorelib
--without-MagickCorelib
--with-Magick++lib
--without-Magick++lib


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

What can I do?

Thanks,
Josh
--
Posted via http://www.ruby-....

5 Answers

Roger Pack

10/28/2008 6:21:00 PM

0

> Gem files will remain installed in
> /Library/Ruby/Gems/1.8/gems/rmagick-2.7.0 for inspection.
> Results logged to
> /Library/Ruby/Gems/1.8/gems/rmagick-2.7.0/ext/RMagick/gem_make.out
>
> What can I do?

post those files.
Also you may need to install imagemagick
I'd install macports
then
sudo port install ImageMagick
maybe it will work :)
-=R
--
Posted via http://www.ruby-....

Joshua Muheim

10/28/2008 6:26:00 PM

0

>> Results logged to
>> /Library/Ruby/Gems/1.8/gems/rmagick-2.7.0/ext/RMagick/gem_make.out
>>
>> What can I do?
>
> post those files.

/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
extconf.rb install rmagick
checking for Ruby version >= 1.8.2... yes
checking for gcc... yes
checking for Magick-config... yes
checking for ImageMagick version >= 6.3.0... yes
checking for HDRI disabled version of ImageMagick... yes
checking for stdint.h... yes
checking for sys/types.h... yes
checking for magick/MagickCore.h... yes
checking for InitializeMagick() in -lMagick... no
checking for InitializeMagick() in -lMagickCore... no
checking for InitializeMagick() in -lMagick++... no
Can't install RMagick 2.7.0. Can't find the ImageMagick library or one
of the dependent libraries. Check the mkmf.log file for more detailed
information.

*** 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/1.8/usr/bin/ruby
--with-Magicklib
--without-Magicklib
--with-MagickCorelib
--without-MagickCorelib
--with-Magick++lib
--without-Magick++lib


> Also you may need to install imagemagick
> I'd install macports

I've installed it, but it doesn't seem to be in the path, "port" is not
found. Where is it located?

> then
> sudo port install ImageMagick
> maybe it will work :)
> -=R

Thanks so far
--
Posted via http://www.ruby-....

Joshua Muheim

10/28/2008 6:36:00 PM

0

OK, found it, but encountered another problem while installing
ImageMagick:

---> Activating libxml2 2.7.1_1
---> Cleaning libxml2
---> Fetching tiff
---> Attempting to fetch tiff-3.8.2.tar.gz from
ftp://ftp.remotesensing.org/pu...
---> Verifying checksum(s) for tiff
---> Extracting tiff
---> Configuring tiff
---> Building tiff with target all
Error: Target org.macports.build returned: shell command " cd
"/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_graphics_tiff/work/tiff-3.8.2"
&& make all " returned error 2
Command output:
/System/Library/Frameworks/GLUT.framework/Headers/glut.h:560: error:
syntax error before 'size'
/System/Library/Frameworks/GLUT.framework/Headers/glut.h:561: error:
syntax error before 'size'
/System/Library/Frameworks/GLUT.framework/Headers/glut.h:562: error:
syntax error before 'innerRadius'
/System/Library/Frameworks/GLUT.framework/Headers/glut.h:563: error:
syntax error before 'innerRadius'
/System/Library/Frameworks/GLUT.framework/Headers/glut.h:566: error:
syntax error before 'size'
/System/Library/Frameworks/GLUT.framework/Headers/glut.h:567: error:
syntax error before 'size'
/System/Library/Frameworks/GLUT.framework/Headers/glut.h:577: error:
syntax error before 'param'
/System/Library/Frameworks/GLUT.framework/Headers/glut.h:617: error:
syntax error before 'mode'
tiffgt.c: In function 'raster_draw':
tiffgt.c:285: warning: implicit declaration of function 'glDrawPixels'
tiffgt.c:285: error: 'GL_RGBA' undeclared (first use in this function)
tiffgt.c:285: error: (Each undeclared identifier is reported only once
tiffgt.c:285: error: for each function it appears in.)
tiffgt.c:285: error: 'GL_UNSIGNED_BYTE' undeclared (first use in this
function)
tiffgt.c:285: error: syntax error before 'GLvoid'
tiffgt.c: In function 'raster_reshape':
tiffgt.c:291: error: 'GLfloat' undeclared (first use in this function)
tiffgt.c:291: error: syntax error before 'xratio'
tiffgt.c:293: error: 'xratio' undeclared (first use in this function)
tiffgt.c:293: error: 'yratio' undeclared (first use in this function)
tiffgt.c:295: warning: implicit declaration of function 'glPixelZoom'
tiffgt.c:296: warning: implicit declaration of function 'glViewport'
tiffgt.c: In function 'raster_keys':
tiffgt.c:303: warning: unused parameter 'x'
tiffgt.c:303: warning: unused parameter 'y'
tiffgt.c: In function 'raster_special':
tiffgt.c:348: warning: unused parameter 'x'
tiffgt.c:348: warning: unused parameter 'y'
make[1]: *** [tiffgt-tiffgt.o] Error 1
make: *** [all-recursive] Error 1

Error: The following dependencies failed to build: tiff
Error: Status 1 encountered during processing.
192:~ josh$

...why does such stuff always have to be so complicated...? :-/
--
Posted via http://www.ruby-....

Michael Guterl

10/28/2008 6:45:00 PM

0

On Tue, Oct 28, 2008 at 2:35 PM, Joshua Muheim <forum@josh.ch> wrote:
> OK, found it, but encountered another problem while installing
> ImageMagick:
>
> ---> Activating libxml2 2.7.1_1
> ---> Cleaning libxml2
> ---> Fetching tiff
> ---> Attempting to fetch tiff-3.8.2.tar.gz from
> ftp://ftp.remotesensing.org/pu...
> ---> Verifying checksum(s) for tiff
> ---> Extracting tiff
> ---> Configuring tiff
> ---> Building tiff with target all
> Error: Target org.macports.build returned: shell command " cd
> "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_graphics_tiff/work/tiff-3.8.2"
> && make all " returned error 2
> Command output:
> /System/Library/Frameworks/GLUT.framework/Headers/glut.h:560: error:
> syntax error before 'size'
> /System/Library/Frameworks/GLUT.framework/Headers/glut.h:561: error:
> syntax error before 'size'
> /System/Library/Frameworks/GLUT.framework/Headers/glut.h:562: error:
> syntax error before 'innerRadius'
> /System/Library/Frameworks/GLUT.framework/Headers/glut.h:563: error:
> syntax error before 'innerRadius'
> /System/Library/Frameworks/GLUT.framework/Headers/glut.h:566: error:
> syntax error before 'size'
> /System/Library/Frameworks/GLUT.framework/Headers/glut.h:567: error:
> syntax error before 'size'
> /System/Library/Frameworks/GLUT.framework/Headers/glut.h:577: error:
> syntax error before 'param'
> /System/Library/Frameworks/GLUT.framework/Headers/glut.h:617: error:
> syntax error before 'mode'
> tiffgt.c: In function 'raster_draw':
> tiffgt.c:285: warning: implicit declaration of function 'glDrawPixels'
> tiffgt.c:285: error: 'GL_RGBA' undeclared (first use in this function)
> tiffgt.c:285: error: (Each undeclared identifier is reported only once
> tiffgt.c:285: error: for each function it appears in.)
> tiffgt.c:285: error: 'GL_UNSIGNED_BYTE' undeclared (first use in this
> function)
> tiffgt.c:285: error: syntax error before 'GLvoid'
> tiffgt.c: In function 'raster_reshape':
> tiffgt.c:291: error: 'GLfloat' undeclared (first use in this function)
> tiffgt.c:291: error: syntax error before 'xratio'
> tiffgt.c:293: error: 'xratio' undeclared (first use in this function)
> tiffgt.c:293: error: 'yratio' undeclared (first use in this function)
> tiffgt.c:295: warning: implicit declaration of function 'glPixelZoom'
> tiffgt.c:296: warning: implicit declaration of function 'glViewport'
> tiffgt.c: In function 'raster_keys':
> tiffgt.c:303: warning: unused parameter 'x'
> tiffgt.c:303: warning: unused parameter 'y'
> tiffgt.c: In function 'raster_special':
> tiffgt.c:348: warning: unused parameter 'x'
> tiffgt.c:348: warning: unused parameter 'y'
> make[1]: *** [tiffgt-tiffgt.o] Error 1
> make: *** [all-recursive] Error 1
>
> Error: The following dependencies failed to build: tiff
> Error: Status 1 encountered during processing.
> 192:~ josh$
>
> ...why does such stuff always have to be so complicated...? :-/
I don't have a specific answer to your problem above, but I have found
that this site has helped with many RMagick installation related
questions and problems.

http://rmagick.rubyforge.org/instal...

Roger Pack

10/28/2008 8:47:00 PM

0

> ---> Building tiff with target all
> Error: Target org.macports.build returned: shell command " cd
> "/opt/local/var/macports/build

Dang I hate it when port upchucks.
One thing you can do is go to the macports irc and ask if this is a
common problem.
GL!
-=R
--
Posted via http://www.ruby-....