OpenOffice and gcj at runtime
Tue Dec 7 16:37:00 GMT 2004
>>>>> "Caolan" == Caolan McNamara <email@example.com> writes:
Caolan> with (FC3) gcj/g++ 3.4.2 this example fails
Caolan> with (rawhide) gcj/g++ 3.4.3 this example fails
Caolan> with gcj/g++ from head (20041126) this example passes.
With the FC2 gcj, this does something at least:
opsy. type gcj
gcj is /usr/bin/gcj
opsy. rpm -q gcc-java
opsy. sh runme.gcj.sh
registerInterfaceA is 959e668
registerInterfaceB is 95b47e0
Some versions of gcj did have a bug when calling an interface method
via JNI. Is that what you're running into? Do you get a
NullPointerException or something?
We can fix this on some branch or another, especially since it seemed
to work in 3.3 (regressions get special dispensation, usually).
This example doesn't work in the BEA JDK :-)
Caolan> Mixing gcj from head and g++ 3.4.2 and the example fails, which is
Caolan> more-or-less what I was doing with OOo (started with 3.4.2 and moved to
Caolan> the head gcj because of the URL snafu) :-) I deserved that I guess, can
Caolan> hardly complain about doing something odd like that.
Were there changes to libgcc? If not, I would actually expect this to
work ok. It seems to me that you wouldn't hit C++ ABI problems as the
JNI stuff is all inlined...
What goes wrong?
It would be nice to get this approach working, because most of the
other java stuff we're looking at (for, say, FC4) will most likely be
compiled with gcj4.
More information about the Java