← Back to team overview

openjdk team mailing list archive

[Bug 1421501] Re: UnsatisfiedLinkError JPEGImageWriter.initWriterIDs (libjpeg link issue?)

 

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

** Changed in: openjdk-8 (Ubuntu)
       Status: New => Confirmed

-- 
You received this bug notification because you are a member of OpenJDK,
which is subscribed to openjdk-8 in Ubuntu.
https://bugs.launchpad.net/bugs/1421501

Title:
  UnsatisfiedLinkError JPEGImageWriter.initWriterIDs (libjpeg link
  issue?)

Status in openjdk-8 package in Ubuntu:
  Confirmed

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

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/openjdk-8/+bug/1421501/+subscriptions


References