This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
RE: Problems compiling SWT apps using Mohans instructions
- From: "Erik Poupaert" <erik dot poupaert at chello dot be>
- To: Øyvind Harboe <oyvind dot harboe at zylin dot com>
- Cc: <java at gcc dot gnu dot org>
- Date: Mon, 17 Feb 2003 18:58:30 +0100
- Subject: RE: Problems compiling SWT apps using Mohans instructions
>>>> I tried Mohans GCJ at my clients and I got the error messages
>>>> below. No idea if this is GCJ or the SWT build included in
>>>> your package.
...
>>>>>>[apply] c:\temp/ccqMbaaa.o(.text+0xd434d): In function
`ZN3com5cyviz3gui9ComboItemC1EPN3org7eclipse3swt7widgets9CompositeEPN4java4l
ang6StringEPNS0_7blender5value10ComboModelE':
I used to have these seemingly unjustified linker errors all the time. With
3.2 sometimes, and even more often with 3.3.
Sometimes "Ant clean" helps. What really did the trick for me, however, was
to ask the linker to search libraries multiple times. Typically, I have ant
files that do:
<exec executable="gcj">
<arg line="-mwindows -s res/*.o -Xlinker --start-group x1.a x2.a
x3.a -Xlinker --end-group -o myexe --main=MainClass"/>
</exec>
Note that this probably requires you to create archives from you application
*.o files, prior to linking them:
<apply failonerror="true" executable="ar" parallel="true">
<fileset dir="obj/*" includes="**/*.o"/>
<arg line="-cr x1.a"/>
</apply>