Page 1 of 1

undefined reference to jpeg_default_qtables

Posted: 2018-06-06T11:02:32-07:00
by ditto
My servers is CentOS 7.5, PHP 7.1.18 and Apache 2.4.33.

Currently I am running ImageMagick 7.0.7-25, and it compiled and works correct.

I am attempting to upgrade to ImageMagick 7.0.7-38, but get errors during "make", heres is the commands until the error happen:

Code: Select all

cd /root
wget http://www.imagemagick.org/download/ImageMagick-7.0.7-38.tar.gz
tar zxf ImageMagick-7.0.7-38.tar.gz
cd ImageMagick-7.0.7-38
./configure --with-gslib --with-perl=/usr/bin/perl
make
...
MagickCore/.libs/libMagickCore-7.Q16HDRI.so: undefined reference to `jpeg_default_qtables'
collect2: error: ld returned 1 exit status
make[1]: *** [utilities/magick] Error 1
make[1]: Leaving directory `/root/ImageMagick-7.0.7-38'
make: *** [all] Error 2
Only two things has changed since it worked:
1: It is a newer ImageMagick version
2: I have upgraded libjpeg 6b to libjpeg 9c

Is this a bug with ImageMagick 7.0.7-38 and libjpeg 9c? If not I would be happy for any help pointing me in the right direction. Thanks!

Re: undefined reference to jpeg_default_qtables

Posted: 2018-06-06T11:18:18-07:00
by fmw42
Check if you have both libjpeg 6b and libjpeg 9c on your system. If so there may be conflicts and you should remove 6b unless other software requires it.

Re: undefined reference to jpeg_default_qtables

Posted: 2018-06-06T12:48:33-07:00
by ditto
That fixed it. I needed to remove the old libjpeg 6b versions at /usr/lib64/libjpeg.so and /usr/lib64/libjpeg.so.62 and /usr/lib64/libjpeg.so.62.1.0

Then I could compile ImageMagick 7.0.7-38 without any errors. Thank you very mush!

Re: undefined reference to jpeg_default_qtables

Posted: 2018-09-08T01:50:05-07:00
by MaverickPL
I have the same problem with install ImageMagick on CentOS-6.5-x86_64.

Code: Select all

# ldconfig -p | grep libjpeg
libjpeg.so.62 (libc6) => /usr/lib/libjpeg.so.62
libjpeg.so.9 (libc6,x86-64) => /usr/local/lib/libjpeg.so.9
libjpeg.so (libc6,x86-64) => /usr/local/lib/libjpeg.so
After "make" command at the end i have message:

Code: Select all

/usr/bin/ld: warning: libjpeg.so.62, needed by /usr/lib/gcc/x86_64-redhat-linux/4.4.7/../../../../lib64/libdjvulibre.so, not found (try using -rpath or -rpath-link)
After "convert --version" command i have:

Code: Select all

convert: error while loading shared libraries: libjpeg.so.62: cannot open shared object file: No such file or directory
So i dont know what to do now ... Can somebody help ?