LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 03-04-2006, 05:58 AM   #1
qwerty
Member
 
Registered: Feb 2005
Location: England
Distribution: Ubuntu 5.10
Posts: 80

Rep: Reputation: 15
Can't run java apps using gtk2.8 and glade2.13


Hello,

I'm trying to develop a java application using Glade gui components. I'm using the gtk2.8 and glade2.13 libraries. The programs compile fine but when I run them I get the following error
Code:
Exception in thread "main" java.lang.NoClassDefFoundError: org/gnu/glib/Struct
	at gnomeApp.ExampleGNOME.main(ExampleGNOME.java:25)
Basically this is saying that the class, Struct, is missing from the gtk library. The line that causes this error is
Code:
Gtk.init(args);
Please can someone tell me how to fix this or where to get the Struct class from. Thanks
 
Old 03-05-2006, 05:01 PM   #2
mrcheeks
Senior Member
 
Registered: Mar 2004
Location: far enough
Distribution: OS X 10.6.7
Posts: 1,690

Rep: Reputation: 52
are you sure you are not missing some glib libraries?
 
Old 03-08-2006, 01:28 PM   #3
qwerty
Member
 
Registered: Feb 2005
Location: England
Distribution: Ubuntu 5.10
Posts: 80

Original Poster
Rep: Reputation: 15
I don't think so, I've followed the example at http://people.redhat.com/overholt/na...pse/index.html and this just uses the same two libraries I mentioned in the original post, albeit older versions.

Also, does anyone know whether I have to use a native java compiler rather than the sun one?

Thanks
 
Old 03-09-2006, 07:22 AM   #4
qwerty
Member
 
Registered: Feb 2005
Location: England
Distribution: Ubuntu 5.10
Posts: 80

Original Poster
Rep: Reputation: 15
I've fixed the problem now. I'd tried installing all the relevent libraries from http://java-gnome.sourceforge.net/cg...n/GetJavaGnome however I found that for some reason it had installed everything to work with the native java runtime rather than the Sun one which I use. All I had to do was copy the relevant libraries into the Sun java directory and then two .so files as well. All fully working now.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
How to set various fonts for GTK2 apps? welson_sun Linux - Software 0 06-22-2004 03:40 AM
Am iI a total noob? I Want better window Gui for gtk2 apps when working in gnome!!!!! Samppa72 Linux - Distributions 1 06-07-2004 04:46 PM
Disable antialiasing in GTK2 apps Wynd Linux - General 0 12-18-2003 08:13 PM
Run Java apps Marcos Van Linux - Newbie 12 05-20-2003 10:36 PM
Using gtk1 themes with gtk2 apps? n_ick2000 Linux - Software 0 03-30-2003 10:32 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 07:05 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration