Re: [Java-gnome-developer] UnsatisfiedLinkError on HTMLDocument ( html_document_new)
Brought to you by:
afcowie
From: Luca De R. <pie...@fa...> - 2004-10-25 10:51:37
|
Il giorno lun, 25-10-2004 alle 10:09 +0200, Nicholas Rahn ha scritto: > Thanks for the info. >=20 > It is quite strange. Here's a small test program that shows the > problem. >=20 > import java.io.IOException; > import java.net.MalformedURLException; > import org.gnu.gnome.App; > import org.gnu.gnome.Program; > import org.gnu.gtk.Gtk; > import org.gnu.gtk.ScrolledWindow; > import org.gnu.gtkhtml.HTMLDocument; > import org.gnu.gtkhtml.HTMLView; >=20 > public class TestHTML { >=20 > public static void main( String[] argv ) { > // Initialization > Program.initGnomeUI("First", "0.1", argv); >=20 > App app =3D new App("First", "First App"); > app.show(); >=20 > HTMLDocument document =3D new HTMLDocument(); > HTMLView view =3D new HTMLView(); > ScrolledWindow sw =3D new ScrolledWindow(); > sw.add( view ); > try { > document.loadURL( "http://www.google.com" ); > view.setDocument( document ); > } catch( MalformedURLException ex ) { > System.err.println( ex ); > } catch( IOException ex ) { > System.err.println( ex ); > } >=20 > Gtk.main(); > } > } >=20 > I compile and run this (with Java 1.4.2 or 1.5) and i get the following > exception: >=20 > Exception in thread "main" java.lang.UnsatisfiedLinkError: > html_document_new > at org.gnu.gtkhtml.HTMLDocument.html_document_new(Native Method) > at org.gnu.gtkhtml.HTMLDocument.<init>(HTMLDocument.java:44) > at TestHTML.main(TestHTML.java:19) >=20 > I then run it with strace to see what's going on and i can see that it > is loading the correct library, but the UnsatisfiedLinkError is raised > just after the load. However, if i run nm on my library, i can see that > the above mentioned function is in the library. >=20 > i thought then that it might be my compile of the libgtkhtml-2.6.2 > library, so i re-emerged it. didn't work. then i compliled it by hand > into /usr/local. still the same error. >=20 > perhaps if there's some other gentooers out there (with a standard > gentoo setup) they could try out the little program above and see what > happens. i'll probably also post to the gentoo forum to see if anyone > there has had a similar experience. >=20 > As for a 2.8 ebuild, let me know if you want some help with testing. > Currently, I'm trying to get the CVS version of java-gnome installed, > hoping i'll have better luck with that (i have gnome 2.8 installed > already as it's in gentoo's ~x86). You can use jhbuild if we want, see the Hints and Tips sec. on the site. Probably all the problems you've experienced with java-gnome-2-6 will go away. --=20 Luca De Rugeriis <pie...@fa...> |