Page 1 of 1
Wrong JPEG VERSION: Library is 62, caller expects 80
Posted: 2012-05-31T10:29:38-07:00
by peter
Hi, All,
I am writing a wrapper program on IM, which is then converted to libtest.so file. Another C++ server will call libtest.so dynamically. I am doing all of these on Ubuntu 11.10. When I running of calling .so function, it complains,
catch exception,Wrong JPEG VERSION: Library is 62, caller expects 80 ....
When I "ldd libtest.so", it depends on both 62 and 80 JPEG versions. On my Ubutnu, there are also two versions of JPEG under /usr/lib/x86_64-linux-gnu/
I tried many ways. But still cannot figure the error out.
Could you help me on it?
Thanks a lot!
Peter
Re: Wrong JPEG VERSION: Library is 62, caller expects 80
Posted: 2012-05-31T12:12:18-07:00
by fmw42
I think you have to get rid of one libjeg and make sure the other is compiled correctly.
Search the archives. I found one post that may be helpful, but I did not review very carefully.
viewtopic.php?f=2&t=18905&p=73321&hilit=62+80#p73321
Re: Wrong JPEG VERSION: Library is 62, caller expects 80
Posted: 2012-05-31T19:08:08-07:00
by peter
Hi, fmw42,
Thanks a lot for your information! I uninstalled all the jpeg versions (both 62 and 80), and reinstalled jpeg8 by using
apt-get install libjpeg8 (on Ubuntu)
The previous error (Wrong JPEG Version) disappeared. But I got new error when I call libtest.so file as follows,
Magick: no decode delegate for this image format `/tmp/3.jpg`
Do you have any idea how to deal with this?
Thanks a lot!
Have a nice day!
Peter
Re: Wrong JPEG VERSION: Library is 62, caller expects 80
Posted: 2012-05-31T19:58:11-07:00
by fmw42
sounds like the jpeg install did not work correctly or IM cannot find it.
what do you get from
convert -list configure
look at the line starting with DELEGATES and see if it includes jpg.
My delegates look like this.
DELEGATES bzlib fftw fontconfig freetype gs jpeg jng jp2 lcms2 lqr openexr pango png rsvg tiff x11 xml zlib
I am not a unix expert. I am on a Mac. So there may be other parts to libjpeg (possibly a libjped-dev) that you might have to install. Check your install report and also your IM install report (config.log) for each and see if any errors.
Re: Wrong JPEG VERSION: Library is 62, caller expects 80
Posted: 2012-06-01T09:20:58-07:00
by mmlenz
I'm having this same problem only reversed. There is no trace of libjpeg 8 on my system and I still get:
convert: Wrong JPEG library version: library is 80, caller expects 62 `0-z.jpg' @ error/jpeg.c/JPEGErrorHandler/316.
I also have no libtest that I know of that has a dependency on libjpeg8
Re: Wrong JPEG VERSION: Library is 62, caller expects 80
Posted: 2012-06-01T09:47:14-07:00
by magick
This error occurs when one of the delegate libraries include an older version of JPEG than what is currently on your system. What happens is that the delegate was built with an older version of JPEG which has different sized structures than the one that is built with ImageMagick. You might be able to get around the issue by building a static distribution of ImageMagick, by eliminating the delegate library that includes an older version of JPEG, or by rebuilding the delegate library against the new version of JPEG.
Re: Wrong JPEG VERSION: Library is 62, caller expects 80
Posted: 2012-06-01T10:58:27-07:00
by mmlenz
Let me explain what I'm doing and maybe you can offer some advice.
1. I have no locally built software on this machine.
2. the only jpeg lib installed anywhere (I did a full file system find for any references to libjpeg) on this system is 6.2
3. I am building ghostscipt and imagemagick on debian 6. I have all the various build dependencies installed (none of which have a dep on jpeg8 or it would have to be installed by debians dependency) but have no trace of debian's own imagemagick, libmagick etc etc or any of the ghostscript packages installed. First I'm building and installing ghostscript. next i build install imagemagick. the only jpeg lib installed for either of these builds is libjpeg62.
Kinda going nuts here with this.
OK wait a sec. It looks like ghostscript includes it own version of libjpeg8c (grrr). Could that be it even if it isn't actually installing that lib anywhere? If imagemagick depends on ghostscript and ghostscript is compiled with its own jpeg8?
Re: Wrong JPEG VERSION: Library is 62, caller expects 80
Posted: 2012-06-01T14:19:50-07:00
by peter
fmw42 wrote:sounds like the jpeg install did not work correctly or IM cannot find it.
what do you get from
convert -list configure
look at the line starting with DELEGATES and see if it includes jpg.
My delegates look like this.
DELEGATES bzlib fftw fontconfig freetype gs jpeg jng jp2 lcms2 lqr openexr pango png rsvg tiff x11 xml zlib
I am not a unix expert. I am on a Mac. So there may be other parts to libjpeg (possibly a libjped-dev) that you might have to install. Check your install report and also your IM install report (config.log) for each and see if any errors.
Yes, I tried "convert -list configure". In DELEGATES line it shows,
DELEGATE bzlib fontconfig freetype jp2 openexr png tiff x11 xml zlib
It doesnot have jpeg as yours. Also number of my DELEGATE libraries is less than yours. Will it work if I run libjped-dev? How can I get the same number of delegate libraries as yours on Ubuntu? Any suggestions?
Thanks a lot!
Have a nice day!
Peter
Re: Wrong JPEG VERSION: Library is 62, caller expects 80
Posted: 2012-06-01T14:24:01-07:00
by peter
magick wrote:This error occurs when one of the delegate libraries include an older version of JPEG than what is currently on your system. What happens is that the delegate was built with an older version of JPEG which has different sized structures than the one that is built with ImageMagick. You might be able to get around the issue by building a static distribution of ImageMagick, by eliminating the delegate library that includes an older version of JPEG, or by rebuilding the delegate library against the new version of JPEG.
Hi, Magick,
Thanks a lot for your information! What is delegate library you mentioned? is it listed in DELEGATES line when we use "convert -list configure" command that fmw42 mentioned?
How can we eliminate the delegate library while installing IM?
Thanks a lot!
Have a nice day!
--Shuping
Re: Wrong JPEG VERSION: Library is 62, caller expects 80
Posted: 2012-06-01T17:24:25-07:00
by peter
peter wrote:fmw42 wrote:sounds like the jpeg install did not work correctly or IM cannot find it.
what do you get from
convert -list configure
look at the line starting with DELEGATES and see if it includes jpg.
My delegates look like this.
DELEGATES bzlib fftw fontconfig freetype gs jpeg jng jp2 lcms2 lqr openexr pango png rsvg tiff x11 xml zlib
I am not a unix expert. I am on a Mac. So there may be other parts to libjpeg (possibly a libjped-dev) that you might have to install. Check your install report and also your IM install report (config.log) for each and see if any errors.
Yes, I tried "convert -list configure". In DELEGATES line it shows,
DELEGATE bzlib fontconfig freetype jp2 openexr png tiff x11 xml zlib
It doesnot have jpeg as yours. Also number of my DELEGATE libraries is less than yours. Will it work if I run libjped-dev? How can I get the same number of delegate libraries as yours on Ubuntu? Any suggestions?
Thanks a lot!
Have a nice day!
Peter
Hi, fmw42,
I followed the link
viewtopic.php?f=2&t=18566, to install jpeg under ImageMagick directory. Now I can see jpeg in DELEGATES line,
DELEGATE bzlib fontconfig freetype jpeg jng jp2 openexr png tiff x11 xml zlib
But I still get "magick: no decode delegate for the image type" error.
Does anyone has some clue about it?
Thanks a lot!
Have a nice day!
--Peter
Re: Wrong JPEG VERSION: Library is 62, caller expects 80
Posted: 2012-06-01T18:53:30-07:00
by fmw42
try
convert logo: logo.jpg
convert logo.jpg logo.gif
display logo.jpg
Do they work? If so, the it could be your jpg file? If not, then you should post your exact command line and error message.
I installed all the delegates that I wanted to have before installing IM. I got my delegates from MacPorts. I don't think you have anything similar on Linux. So you have to install any delegate you want before installing IM. You can google for them. If you do not install any delegates, then you won't be able to do much except for things like gif, which come with the IM install. No png, no tiff, etc unless you install anything you need that does not show in your list of DELEGATES. IM relies upon those delegate libraries to do some things like convert to other image types and handle text and vector processing. So you may need to install, ghostscript and some of the others (fontconfig freetype gs)
Re: Wrong JPEG VERSION: Library is 62, caller expects 80
Posted: 2012-06-02T21:56:09-07:00
by peter
HI, fmw42 and magick,
Thanks a lot for all your useful information! Now I solved the problem. I am describing the solution as follows for the ImageMagickers who have the same problem.
I am using Ubuntu 11.10. Currently there are two versions of JPEG, 62 and 80, on the system. Somehow it only provides 62 version JPEG for ImageMagick. And also it seems that many other applications (such as eog, firefox, elcipse, maven, gnome-terminal etc.) depends on this 62 version, because all these applications will not work if I remove JPEG62 from the system (even though JPEG80 is in the system,too). I have no idea why this happens. Do you have any clue? I guess we may configure which version Ubuntu uses by default. But donot know how.
So what I did is to remove JPEG80 totally, then reinstall IM. The both IM and Ubutnu are using JPEG62 version. The problem is solved.
As for DELEGATE problem, fmw42 provided the good solution. In my case, I installed JPEG62-dev. Then the problem was solved.
Thanks a lot!
Peter