This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [ATTACHEMENT TO:] BUG REPORT. Loading native-libs dynamicallyend up with cast-error...


Hi!

First I want to say, that I´m really happy how freindly the people are here! (especally tom and you!)

Hmm, the problem is, that the problem does still exist:


tes: Loader.o bi.o lib-bte.so
$(GCJ) --main=Loader -o $@ bi.o Loader.o

This does mean, you linked bte to tes at compile-time, not at run-time.
Its needed, that the compilier doesnt know the class bte at all, it is only allowed to now its interface bi, which must be the same for all "plugin"-classes i want to use.

What I want to do is to write an app, to parse the name of the class that should loaded out of a config-file and the load the class whithout knowing how the class is built.
This should generally work, and it does so in interprted-mode, but it semms libgcj has problems with native code....

Your executable already knows bte at compile-time because its into libbte.so, thats not what I want to do ;-((
It should be enough to only compile the interface into the executable....

You have to make sure lib-bte.so is on your LD_LIBRARY_PATH, so I just
ran it like this:

$ LD_LIBRARY_PATH=./ tes

Of cource I did this. Na dit also worked for me when I did like you did, but thats not late-linking (sorry, dont know the exact name).

I want to thank you very much for your time, and that you´ve tried my examples, thats really freindly and helpful. I´ve already sent a bug-report
bug-report to bugs-gcc but t semms nobody has answered ;-((

Thanks, thx, thx, thx!

Could you please try to compile it without bte linked in? I know I´m nerving, but I cant belive that I´m to stupid (I´m really not very intelligent *g*) to get this up`n`running.

Mfg Linuxhippy


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]