docomscope fails to start UnsatisfiedLinkError: no jInterface

Bug #1656227 reported by Martin Weis
10
This bug affects 2 people
Affects Status Importance Assigned to Milestone
dicomscope (Debian)
Fix Released
Unknown
dicomscope (Ubuntu)
Fix Released
Undecided
Unassigned
Trusty
Confirmed
Undecided
Unassigned

Bug Description

I get the following error at startup:

dicomscope
starting DICOMscope
please wait...
Exception in thread "main" java.lang.UnsatisfiedLinkError: no jInterface in java.library.path
 at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1716)
 at java.lang.Runtime.loadLibrary0(Runtime.java:844)
 at java.lang.System.loadLibrary(System.java:1057)
 at main.MainContext.<clinit>(MainContext.java:58)
 at dicomscope.DICOMscope.main(DICOMscope.java:91)

This error is the same for all tested java versions (see at bottom).

file $(which dicomscope)
/usr/bin/dicomscope: symbolic link to `../share/java/DICOMscope.jar'

The deb installs the lib here:
/usr/lib/x86_64-linux-gnu/jni/libjInterface.so

dicomscope can successfully be started like this:
java -Djava.library.path=/usr/lib/x86_64-linux-gnu/jni/ -jar /usr/bin/dicomscope

The related bugreport in Debian states the problem not being in dicomscope, but binfmt/java package:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=731778

The small program there reveals:
java GetSystemProperty java.library.path
:/home/martin/local/lib:/usr/java/packages/lib/amd64:/usr/lib64:/lib64:/lib:/usr/lib

which may be missing /usr/lib/x86_64-linux-gnu/jni/

A start script could be written instead of linking dicomscope directly to the jar, that resolves
-Djava.library.path=/usr/lib/x86_64-linux-gnu/jni/ properly for all architectures.

lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 14.04.5 LTS
Release: 14.04
Codename: trusty

Tested java versions:

java -version
java version "1.8.0_111"
Java(TM) SE Runtime Environment (build 1.8.0_111-b14)
Java HotSpot(TM) 64-Bit Server VM (build 25.111-b14, mixed mode)

java version "1.7.0_121"
OpenJDK Runtime Environment (IcedTea 2.6.8) (7u121-2.6.8-1ubuntu0.14.04.1)
OpenJDK 64-Bit Server VM (build 24.121-b00, mixed mode)

java -version
java version "1.6.0_40"
OpenJDK Runtime Environment (IcedTea6 1.13.12) (6b40-1.13.12-0ubuntu0.14.04.3)
OpenJDK 64-Bit Server VM (build 23.40-b40, mixed mode)

Revision history for this message
Martin Weis (martin-weis-newsadress) wrote :

I also tested (unsuccessfully) with

LD_LIBRARY_PATH=/usr/lib/x86_64-linux-gnu/jni/:$LD_LIBRARY_PATH

Changed in dicomscope (Debian):
status: Unknown → Incomplete
Revision history for this message
Alfonso (alfonso-martone) wrote :

WORKAROUND:

java -jar /usr/share/java/DICOMscope.jar

Revision history for this message
Launchpad Janitor (janitor) wrote :

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

Changed in dicomscope (Ubuntu):
status: New → Confirmed
Revision history for this message
Dylan Aïssi (daissi) wrote :

This bug is reproducible in Trusty but not in Xenial neither in Bionic.
It was fixed somewhere between dicomscope 3.6.0-11 and 3.6.0-15build1.

Changed in dicomscope (Ubuntu):
status: Confirmed → Fix Released
Changed in dicomscope (Ubuntu Trusty):
status: New → Confirmed
Changed in dicomscope (Debian):
status: Incomplete → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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