Package: java-wrappers
Version: 0.1.25
Severity: important
Tags: patch

I have just installed freemind. I have Oracle Java installed under
/usr/local/app/java-oracle/jdk1.7.0 and correctly mapped into
/etc/alternatives. I'm aware of issues surrounding Oracle Java but it's
required for another application I use. I also have OpenJDK versions 6 and 7
installed but unused.

Running freemind triggers a calls to java-wrappers, which in turn uses jvm-list
to detect an appropriate jvm. Unfortunately this fails because my jvm is not
installed under /usr/lib/jvm so java-wrappers is led to believe there is no
valid jvm installed, and consequently freemind will not start.

Investigating further it appears that there is a line within /usr/lib/java-
wrappers/jvm-list.sh that assumes a jvm linked from /etc/alternatives/java is
going to be somewhere under /usr/lib/jvm. The attached patch removes this
dependency assumption.



-- System Information:
Debian Release: 7.0
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'stable'), (500, 'oldstable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 3.2.0-4-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages java-wrappers depends on:
ii  unzip  6.0-8

java-wrappers recommends no packages.

java-wrappers suggests no packages.

-- no debconf information
--- jvm-list.sh.2013-06-10	2011-09-14 17:27:08.000000000 +0100
+++ jvm-list.sh	2013-06-10 11:43:05.205951794 +0100
@@ -56,7 +56,7 @@
 __jvm_java2="$__jvm_java5 $__jvm_gcj2"
 
 # current java alternatives
-__jvm_alt=$(readlink /etc/alternatives/java|sed -n 's/\(\/usr\/lib\/jvm\/[^\/]*\)\/.*/\1/p')
+__jvm_alt=$(readlink /etc/alternatives/java|sed -n 's!\(.*\)/bin/[^/]*$!\1!p')
 
 # All JVMs
 __jvm_all="$__jvm_default /usr/lib/jvm/*"

Reply via email to