[Java-gnome-developer] Gtk.init throws exception when run on Ubuntu 13.04
Brought to you by:
afcowie
From: Johan G. <joh...@gm...> - 2013-07-19 23:38:48
|
Hi, I've just installed libjava-gnome-java on a Ubuntu 13.04 box (only Linux dist I've got available). Fired up Eclipse Juno, added the library to my project (and the docs of course) and tried to run it but I'm getting an exception! What is going on here? The program is this: package uk.org.linuxgrotto.ui; import org.apache.log4j.Logger; import org.gnome.gtk.Gtk; /** * The class instantiates the main window. * * @author jgroth * */ public class DesktopFileCreator { private static Logger log = Logger.getLogger(DesktopFileCreator.class); public static void main(String[] args) { Gtk.init(args); } } Exception in thread "main" java.lang.ExceptionInInitializerError at org.gnome.gtk.Gtk.init(Gtk.java:95) at uk.org.linuxgrotto.ui.DesktopFileCreator.main(DesktopFileCreator.java:63) Caused by: java.lang.NullPointerException at org.freedesktop.bindings.Plumbing.loadNativeCode(Plumbing.java:192) at org.freedesktop.bindings.Plumbing.<clinit>(Plumbing.java:110) ... 2 more This is so minimal it can't be any smaller and yet an exception. Regards, Johan |