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]

Is this possible


Here is the situation,

I have a library of java files that I compile and turn into a .a file.
Then I create a java source file that uses that .a file. The command
I use to link the .a file and java source file is
gcj ReportsFrame.java  --main=ReportsFrame libGenCAM.a -o ReportsFrame

the binary gets created and I execute ReportsFrame and everything is fine.
Now the next step is to create a C++ equivalent of the ReportsFrame.java,
easy right? Well I thought it was until I actually tried. 

After some tries I simplified my problem, just write a C++ program that 
instantiates the ReportsFrame constructor. I got the whole monster to 
compile with the command,
gcj -o JavaTest ReportsFrame.o libGenCAM.a JavaTest.o
when I execute the resulting binary I get a core dump.
Any Ideas?

Is possible to have a c++ class instantiate a java class and call methods
from it?

I can zip up all the code that I have been working with and send it out
to someone who wants to see it. It's all open source anyways.

Dave


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