undefined reference to `png_longjmp'

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
my600080
Posts: 13
Joined: 2010-06-11T12:41:30-07:00
Authentication code: 8675308

undefined reference to `png_longjmp'

Post by my600080 »

Hi,
When I tried to do "make", I kept getting the following message:

magick/.libs/libMagickCore.so: undefined reference to `png_longjmp'
magick/.libs/libMagickCore.so: undefined reference to `png_set_longjmp_fn'
collect2: ld returned 1 exit status
make[1]: *** [utilities/animate] Error 1

It seems that few people get this error. What might be the problem?

Thanks!
User avatar
glennrp
Posts: 1147
Joined: 2006-04-01T08:16:32-07:00
Location: Maryland 39.26.30N 76.16.01W

Re: undefined reference to `png_longjmp'

Post by glennrp »

Chances are you are compiling IM with png.h from libpng-1.5.x but
trying to link with 1.4.x or earlier. "png_longjmp" only exists in
libpng-1.5.x.
my600080
Posts: 13
Joined: 2010-06-11T12:41:30-07:00
Authentication code: 8675308

Re: undefined reference to `png_longjmp'

Post by my600080 »

Thanks a lot for your help.

I've installed all the font libraries locally under /home/mmj. So, I have the following directories under /home/mmj. How can I get ./configure or make to use my installed font libraries? Many thanks!

include/
freetype2 jconfig.h jpeglib.h pngconf.h tiffconf.h tiffio.hxx
ft2build.h jerror.h libpng14 png.h tiff.h tiffvers.h
ImageMagick jmorecfg.h libpng15 pnglibconf.h tiffio.h

lib/
ImageMagick-6.6.5 libMagickCore.so.4 libpng15.so
libfreetype.a libMagickCore.so.4.0.0 libpng15.so.15
libfreetype.la libMagick++.la libpng15.so.15.0.0
libfreetype.so libMagick++.so libpng.a
libfreetype.so.6 libMagick++.so.4 libpng.la
libfreetype.so.6.3.22 libMagick++.so.4.0.0 libpng.so
libjpeg.a libMagickWand.a libtiff.a
libjpeg.la libMagickWand.la libtiff.la
libjpeg.so libMagickWand.so libtiff.so
libjpeg.so.7 libMagickWand.so.4 libtiff.so.3
libjpeg.so.7.0.0 libMagickWand.so.4.0.0 libtiff.so.3.9.4
libjpeg.so.8 libpng14.a libtiffxx.a
libjpeg.so.8.0.0 libpng14.la libtiffxx.la
libjpeg.so.back libpng14.so libtiffxx.so
libMagick++.a libpng14.so.14 libtiffxx.so.3
libMagickCore.a libpng14.so.14.4.0 libtiffxx.so.3.9.4
libMagickCore.la libpng15.a perl5
libMagickCore.so libpng15.la pkgconfig
Post Reply