#2 peer_example fails on linux, gcc 3.2.2, j2sdk 1.4.0.02

open
nobody
None
5
2003-05-19
2003-05-19
Anonymous
No

Hi,
I have recently installed Jace on my linux pc and managed
to make example1, map_example and vm_load_example
work.
However, your peer_example1 still fails for me with "An
unexpected exception has been detected in native code
outside the VM ...."
At first glance, the problem seems to be the dynamic_cast
in PeerExampleMappings.cpp. If I
replace "dynamic_cast<...>" simply by "(...)", then function
PeerExamples::getResources() is called. But within this
function, I get the same error message as above when the
members port() or server() are called. If I comment these
out and set up a fake response (array of strings), returning
to java works and the program terminates succesfully.
I suspect that I need to fix the dynamic_cast "problem"...
I saw that there was an issue with dynamic_cast and
shared libraries in gcc up to version 3.2.1 which should be
fixed in version 3.2.2 that I am using. Therefore I hope that
the right compiler and linker options could help. Since there
wasn't any compile/link script provided for this example in
the linux branch, I might have missed something important
here.
I would appreciate very much any help from somebody who
managed to make this example work on linux!
Regards,
Roland

Discussion