UnsatisfiedLinkError JPEGImageWriter.initWriterIDs (libjpeg link issue?)

Bug #1421501 reported by Stian Soiland-Reyes on 2015-02-13
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
openjdk-8 (Ubuntu)
Undecided
Unassigned

Bug Description

Tested on Debian unstable (docker run -it debian:unstable bash)

root@8643ea75afc5:/tmp# apt-get update && apt-get install -y openjdk-7-jdk

root@8643ea75afc5:/tmp# /usr/lib//jvm/java-8-openjdk-amd64/bin/javac JpegLinkErrorTest.java

root@8643ea75afc5:/tmp# /usr/lib//jvm/java-8-openjdk-amd64/bin/java JpegLinkErrorTest
Writing image of format JPG
Exception in thread "main" java.lang.UnsatisfiedLinkError: com.sun.imageio.plugins.jpeg.JPEGImageWriter.initWriterIDs(Ljava/lang/Class;Ljava/lang/Class;)V
 at com.sun.imageio.plugins.jpeg.JPEGImageWriter.initWriterIDs(Native Method)
 at com.sun.imageio.plugins.jpeg.JPEGImageWriter.<clinit>(JPEGImageWriter.java:186)
 at com.sun.imageio.plugins.jpeg.JPEGImageWriterSpi.createWriterInstance(JPEGImageWriterSpi.java:96)
 at javax.imageio.spi.ImageWriterSpi.createWriterInstance(ImageWriterSpi.java:351)
 at javax.imageio.ImageIO$ImageWriterIterator.next(ImageIO.java:843)
 at javax.imageio.ImageIO$ImageWriterIterator.next(ImageIO.java:827)
 at javax.imageio.ImageIO.getWriter(ImageIO.java:1596)
 at javax.imageio.ImageIO.write(ImageIO.java:1520)
 at JpegLinkErrorTest.main(JpegLinkErrorTest.java:21)

It only fails on the 'jpg' file types (jpg/jpeg/JPG/JPEG) - but 'jpg' is first in the list.

Works on Oracle JDK 8u31 and with openjdk-7-jdk:

Writing image of format BMP
/tmp/imageio-test7772278913058063191.BMP
Writing image of format bmp
/tmp/imageio-test5546897060613663123.bmp
Writing image of format jpg
/tmp/imageio-test5473962376568317343.jpg
Writing image of format JPG
/tmp/imageio-test2913364248525400586.JPG
Writing image of format wbmp
/tmp/imageio-test8802041629818312263.wbmp
Writing image of format jpeg
/tmp/imageio-test474266998577835775.jpeg
Writing image of format png
/tmp/imageio-test6521680424907148555.png
Writing image of format JPEG
/tmp/imageio-test3733833046061183775.JPEG
Writing image of format PNG
/tmp/imageio-test1398529111087699330.PNG
Writing image of format WBMP
/tmp/imageio-test8959484672100902223.WBMP
Writing image of format GIF
/tmp/imageio-test4265877254881075995.GIF
Writing image of format gif
/tmp/imageio-test4516006851825566466.gif

Looking for initWriterIDs in Oracle JDK8 gives a hit in its bundled libjpeg.so:

stain@biggie-utopic:~/software/jdk1.8.0_31$ grep -r initWriterIDs .
Binary file ./jre/lib/amd64/libjpeg.so matches
Binary file ./jre/lib/rt.jar matches
Binary file ./lib/ct.sym matches

but libjpeg.so is not in /usr/lib//jvm/java-8-openjdk-amd64

Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in openjdk-8 (Ubuntu):
status: New → Confirmed
Luiz Felipe Talvik (talvik) wrote :

I think this is the best description and solution for this bug:
http://icedtea.classpath.org/bugzilla/show_bug.cgi?id=1393

Matthias Klose (doko) wrote :

fixed for 15.04

Changed in openjdk-8 (Ubuntu):
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.