Java AWT does not work on feisty out of the box

Bug #77719 reported by Arthur Peters on 2007-01-02
This bug report is a duplicate of:  Bug #90380: Cannot load AWT toolkit. Edit Remove
Affects Status Importance Assigned to Milestone
gcj-4.1 (Ubuntu)
Tom Mortimer-Jones

Bug Description

Binary package hint: gij-4.1

I am trying to run 2 java programs off of sourceforge (pcgen and jreepad). Both fail with errors related to AWT.

Installing libgcj7-awt solves the problem, but AWT is very common so perhaps the package should be installed by default.

$ java -jar Jreepad-1.5.1.jar
Exception in thread "main" java.awt.AWTError: Cannot load AWT toolkit:
   at java.awt.Toolkit.getDefaultToolkit(
   at jreepad.JreepadViewer.<clinit>(
   at java.lang.Class.initializeClass(
Caused by: java.lang.UnsatisfiedLinkError: libgtkpeer: cannot open shared object file: No such file or directory
   at java.lang.Runtime._load(
   at java.lang.Runtime.loadLibrary(
   at java.lang.System.loadLibrary(
   at java.lang.Class.initializeClass(
   at java.lang.Class.forName(
   at java.awt.Toolkit.getDefaultToolkit(
   ...2 more

$ bash -x
++ dirname
+ cd .
+ pcgendir=/home/amp/.pcgen
+ '[' '!' -d /home/amp/.pcgen ']'
+ '[' x = x ']'
+ case "$WINDOWMANAGER" in
+ BROWSER=netscape
+ javaargs='-Xms128m -Xmx256m'
+ pcgenargs=
+ whosearg=java
+ '[' x '!=' x ']'
+ exec java -DBROWSER=netscape -Xms128m -Xmx256m -jar ./pcgen.jar
Exception in thread "main" java.awt.AWTError: Cannot load AWT toolkit:
   at java.awt.Toolkit.getDefaultToolkit(
   at pcgen.util.Logging.<clinit>(
   at java.lang.Class.initializeClass(
   at pcgen.core.Main.dieWithBadEntryPoint(
   at pcgen.core.Main.main(
Caused by: java.lang.NoClassDefFoundError:
   at java.lang.Class.initializeClass(
   at java.lang.Class.forName(
   at java.awt.Toolkit.getDefaultToolkit(
   ...4 more

PS: The programs fail to run even with the AWT package installed. Both with Null pointer deref exceptions.

Tom Mortimer-Jones (tom-morty) wrote :

Thanks for the bug report.

If you download software from other sources (such as SourceForge) then you will need to locate the dependencies in order to run them. I am glad that you managed to locate the correct library in order to run these applications. The packages installed by default by Ubuntu are deliberately kept to a minimum so that the distribution can fit on a single CD. It would not be possible to install all of the libraries to run even the most popular software without becoming far to big to fit on a CD.

If you are still having trouble with these applications and you believe that it is a problem with an Ubuntu library please post some more information. If you think that the problem is with the application then the developers of these applications will be able to help you.

Changed in gcj-4.1:
assignee: nobody → tom-morty
status: Unconfirmed → Needs Info
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers