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]

-findirect-dispatch: broken on Linux, working on Mingw?


Hey all

I once started a discussion that ecj1 can't be compiled for a host=Linux target=Linux static gcj: http://gcc.gnu.org/ml/java/2007-01/msg00082.html
Back then, no one knew why the error occurred. I think I now stumbled over the answer:


Having Test.java as a simple "HelloWorld" and working with the compiled class:

On Linux:
---------

static-gcj-for-lin Test.class --main=Test -findirect-dispatch
-> /tmp/ccq2qpMg.o: In function `main':cc3Fk97a.i:(.text+0x30): undefined reference to `JvRunMainName'
collect2: ld returned 1 exit status


static-gcj-for-win Test.class --main=Test -findirect-dispatch
-> works

On Windows:
-----------

static-gcj-for-win Test.class --main=Test -findirect-dispatch
-> works

static-gcj-for-lin Test.class --main=Test -findirect-dispatch
-> C:\DOKUME~1\Marco\LOKALE~1\Temp/cce2caaa.o: In function `main':ccIjcaaa.i:(.text+0x30): undefined reference to `JvRunMainName'
collect2: ld returned 1 exit status



It works if I remove the "-findirect-dispatch". I have seen undefined references to JvRunMainName, _Jv_MonitorExit, _Jv_RegisterResource and _Jv_JNI_PopSystemFrame.



Any direct ideas? Otherwise I'll add a bugreport.


BTW: What is preferred? If I directly go ahead and create a bugreport or first kick on a discussion on the list?

BTW2: It seems Mingw slowly becomes better than Linux ;-)


Marco



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