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: Problem compiling DLL


At http://gcc.gnu.org/ml/java/2007-09/msg00013.html

Daniel Adolfsson wrote:
> gcj -o HelloWorld.exe --main=HelloWorld --classpath=. -L. -ltest
HelloWorld.java

I don't know if this is the whole problem but, in win32-land, dll import
libraries (eg libtest.a) are static stub archives and must follow the
objects which depend open the library, otherwise the symbols will not be
resolved (no lazy binding). So try:

gcj -o HelloWorld.exe --main=HelloWorld HelloWorld.java --classpath=.
-L. -ltest 

A second problem that you may encounter with libgcj is that in order for
it to communicate exceptions across dll/dll or dll/exe boundaries, all
components must be built with -shared-libgcc.

Danny


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