From: Geoffrey F. <fu...@ga...> - 2001-11-14 06:15:17
|
Alan W. Irwin writes: > On Tue, 13 Nov 2001, [iso-8859-1] Jo=E3o Cardoso wrote: > > I don't know if this (LD_RUN_PATH) will work for the java demos, b= ut I guess that > > it will. >=20 > Thanks for that suggestion, but it did not work. I suspect LD_RUN_P= ATH is > specific to ld (or ld called implicitly by gcc). man ld is the only= place I > can find documentation for it. It is indeed that sort of functional= ity (or > the sys.path.insert() functionality in python) that I am needing for= java, > but I haven't found such functionality, yet. It would have to be applied ot the jvm in order for it to be active when the jvm goes to look to dlopen libplplot.so. We can't control how the jvm is formed. I'd say we're sunk in this regard. I suppose this is as good a place as any to just point out that I don't actually share your aversion to setting LD_LIBRARY_PATH. You have to set CLASSPATH to find .class files or .jar files, and you have to set LD_LIBRARY_PATH to find .so's. Doesn't seem like much of an issue to me, for the benefit of loading JNI code bases. > Your suggestion did point me toward gcj which is a java compiler tha= t is a > variation on gcc. Once I can get that compiler to work with our cod= e, it > may well be that LD_RUN_PATH is automatically honored since there is= an > implicit call to ld from gcc. I like the idea that all of our C fro= nt end, > our c++ front end and our java front end can potentially be compiled= under > gcc. So that is an additional reason to get gcj to work with our jav= a code. >=20 > However, I am having trouble. Currently gcj generates tons of undef= ined > symbols messages, but I suspect I am just not using the correct opti= ons > since the symbols I have looked at are the plplot ones that should b= e there > if it is finding our library at link time (deja vu all over again, s= ort > of!). Geoffrey, have you tried out gcj, and if so, how do you get i= t to > work with our code? I have not yet tried gcj, or jikes. It would be nice to work with both of these, but I haven't had time to investigate such matters, and cannot promise to ever do it. Work is getting ever more demanding, so my ability to do this kind of exploratory investigation is very limited.=20 |