Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Bug#603932: josm: Sould depend on openjdk-6-jre

0 views
Skip to first unread message

Noel David Torres Taño

unread,
Nov 18, 2010, 11:10:04 AM11/18/10
to
Package: josm
Version: 0.0.svn3376-1
Severity: important


Package should depend on openjdk-6-jre which provides libmawt.so

$ josm
Using /usr/lib/jvm/java-6-openjdk/bin/java to execute josm.
Exception in thread "main" java.lang.UnsatisfiedLinkError: Can't load library: /usr/lib/jvm/java-6-openjdk/jre/lib/amd64/xawt/libmawt.so
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1649)
at java.lang.Runtime.load0(Runtime.java:787)
at java.lang.System.load(System.java:1022)
at java.lang.ClassLoader$NativeLibrary.load(Native Method)
at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1750)
at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1667)
at java.lang.Runtime.loadLibrary0(Runtime.java:840)
at java.lang.System.loadLibrary(System.java:1047)
at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:67)
at sun.security.action.LoadLibraryAction.run(LoadLibraryAction.java:47)
at java.security.AccessController.doPrivileged(Native Method)
at java.awt.Toolkit.loadLibraries(Toolkit.java:1614)
at java.awt.Toolkit.<clinit>(Toolkit.java:1636)
at java.awt.Component.<clinit>(Component.java:568)
at org.openstreetmap.josm.Main.<clinit>(Main.java:285)
Could not find the main class: JOSM. Program will exit.


-- System Information:
Debian Release: squeeze/sid
APT prefers testing
APT policy: (990, 'testing'), (500, 'unstable'), (1, 'experimental')
Architecture: amd64 (x86_64)

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

Versions of packages josm depends on:
ii libgettext-commons-java 0.9.6-2 Java classes for internationalizat
ii libmetadata-extractor-j 2.3.1+dfsg-2 JPEG metadata extraction framework
ii liboauth-signpost-java 1.2.1.1-1 simple OAuth message signing for J
ii openstreetmap-map-icons 1:0.0.svn20783-1 Collection of map icons (classic s
ii sun-java6-jre 6.22-1 Sun Java(TM) Runtime Environment (

Versions of packages josm recommends:
ii josm-plugins 0.0.svn22363-1 Plugins for JOSM

josm suggests no packages.

-- no debconf information

--
To UNSUBSCRIBE, email to debian-bugs-...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listm...@lists.debian.org

Giovanni Mascellani

unread,
Nov 23, 2010, 6:50:02 PM11/23/10
to
Il 18/11/2010 17:02, Noel David Torres Taño ha scritto:
> Package: josm
> Version: 0.0.svn3376-1
> Severity: important
>
>
> Package should depend on openjdk-6-jre which provides libmawt.so
>
> $ josm
> Using /usr/lib/jvm/java-6-openjdk/bin/java to execute josm.
> Exception in thread "main" java.lang.UnsatisfiedLinkError: Can't load library: /usr/lib/jvm/java-6-openjdk/jre/lib/amd64/xawt/libmawt.so

I'm somewhat puzzled: josm already depends on openjdk-6-jre |
sun-java5-jre | sun-java6-jre: any of these should work. Moreover, I
already have openjdk-6-jre installed, because you're using to execute josm.

Anyway, you also appear to have Java 6 from SUN. Could you try to use
it, for example with:

JAVACMD=/usr/lib/jvm/java-6-sun/bin/java josm

BTW, are you experiencing problems with other Java graphical applications?

Ciao, Giovanni.
--
Giovanni Mascellani <masce...@poisson.phc.unipi.it>
Pisa, Italy

Web: http://poisson.phc.unipi.it/~mascellani
Jabber: g.masc...@jabber.org / giov...@elabor.homelinux.org

signature.asc

Noel David Torres Taño

unread,
Nov 24, 2010, 4:30:02 PM11/24/10
to
On Martes 23 Noviembre 2010 23:40:05 usted escribió:
> Il 18/11/2010 17:02, Noel David Torres Taño ha scritto:
> > Package: josm
> > Version: 0.0.svn3376-1
> > Severity: important
> >
> >
> > Package should depend on openjdk-6-jre which provides libmawt.so
> >
> > $ josm
> > Using /usr/lib/jvm/java-6-openjdk/bin/java to execute josm.
> > Exception in thread "main" java.lang.UnsatisfiedLinkError: Can't load
> > library: /usr/lib/jvm/java-6-openjdk/jre/lib/amd64/xawt/libmawt.so
>
> I'm somewhat puzzled: josm already depends on openjdk-6-jre |
> sun-java5-jre | sun-java6-jre: any of these should work. Moreover, I
> already have openjdk-6-jre installed, because you're using to execute josm.

From what you can see in the bug report, I do not have openjdk-6-jre
installed. Since the dependencie is ORed, I have installed only sun-java6-jre.


>
> Anyway, you also appear to have Java 6 from SUN. Could you try to use
> it, for example with:
>
> JAVACMD=/usr/lib/jvm/java-6-sun/bin/java josm

This works ok. Maybe the problem is that you need to have installed the same
jre than the java you'll use by default, and not just to have a jre. I have
openjdk-6-jre-headless installed (which provides /usr/lib/jvm/java-6-
openjdk/bin/java ) but not openjdk-6-jre, because of this dependency chain:

i openoffice.org Depende liblucene2-java (>= 2.3.2)
i A liblucene2-java Depende openjdk-6-jre-headless | java5-runtime-headless

That is, the dependencies of your package must take into account which java is
to be used.


>
> BTW, are you experiencing problems with other Java graphical applications?

I'm sorry, but have no other java apps installed.
>
> Ciao, Giovanni.

Thanks

Noel
er Envite

David Paleino

unread,
Nov 25, 2010, 4:00:01 AM11/25/10
to
On Wed, 24 Nov 2010 21:18:52 +0000, Noel David Torres Taño wrote:

> On Martes 23 Noviembre 2010 23:40:05 usted escribió:

> > Anyway, you also appear to have Java 6 from SUN. Could you try to use
> > it, for example with:
> >
> > JAVACMD=/usr/lib/jvm/java-6-sun/bin/java josm
>

> This works ok. Maybe the problem is that you need to have installed the same
> jre than the java you'll use by default, and not just to have a jre. I have
> openjdk-6-jre-headless installed (which provides /usr/lib/jvm/java-6-
> openjdk/bin/java ) but not openjdk-6-jre, because of this dependency chain:

josm uses whatever the default java is on the system.
Could you please paste the output of:

$ LANG=C update-alternatives --display java

?

It seems like in your case openjdk's is the default one:

$ josm
Using /usr/lib/jvm/java-6-openjdk/bin/java to execute josm.

[..]

If you want to use Sun's java, please change the alternative. Otherwise,
install openjdk-6-jre.

JOSM really supports both, so it's not wise to just force the dependency on
OpenJDK.

In the end, I think this is just a misconfiguration of your system, and the bug
can be closed.

Thanks,
David

--
. ''`. Debian developer | http://wiki.debian.org/DavidPaleino
: :' : Linuxer #334216 --|-- http://www.hanskalabs.net/
`. `'` GPG: 1392B174 ----|---- http://deb.li/dapal
`- 2BAB C625 4E66 E7B8 450A C3E1 E6AA 9017 1392 B174

signature.asc

Noel David Torres Taño

unread,
Nov 26, 2010, 5:30:01 AM11/26/10
to
On Jueves 25 Noviembre 2010 08:50:11 usted escribió:
[...]

> josm uses whatever the default java is on the system.

I know

> Could you please paste the output of:
>
> $ LANG=C update-alternatives --display java
>

java - auto mode
link currently points to /usr/lib/jvm/java-6-openjdk/jre/bin/java
/usr/lib/jvm/java-6-openjdk/jre/bin/java - priority 1061
slave java.1.gz: /usr/lib/jvm/java-6-openjdk/jre/man/man1/java.1.gz
/usr/lib/jvm/java-6-sun/jre/bin/java - priority 63
slave java.1.gz: /usr/lib/jvm/java-6-sun/jre/man/man1/java.1.gz
Current 'best' version is '/usr/lib/jvm/java-6-openjdk/jre/bin/java'.

>
> It seems like in your case openjdk's is the default one:
>
> $ josm
> Using /usr/lib/jvm/java-6-openjdk/bin/java to execute josm.
> [..]

Yes, it is my default. The problem is that your dependencies do not take into
account which java is user's default, they just say "any one of these will
work", and that is not true: if user has one of them installed and it does not
correspond to the user's default java, the needed jre will not be installed
and the package executable will fail.


>
> If you want to use Sun's java, please change the alternative. Otherwise,
> install openjdk-6-jre.

Yes, that is the solution to my particular problem, but it is not a solution
to the bug.


>
> JOSM really supports both, so it's not wise to just force the dependency on
> OpenJDK.

I understand. Is there a way to check which java will the user use and install
the really needed dependency?


>
> In the end, I think this is just a misconfiguration of your system, and the
> bug can be closed.
>
> Thanks,
> David

The point is: if a user has Sun's java installed, by any reason, and later
installs openjdk-6-jre-headless by any other reason, for example by installing
OpenOffice.org which depends on it, then when the user is to install josm the
dependencies system thinks that all dependencies are fullfilled and they are
not, since openjdk-6-jre-headless provides a high priority java binary which
needs openjdk-6-jre (not installed) to execute josm.

Hope this helps

Noel
er Envite

signature.asc
0 new messages