This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: sh-coff broken
- To: Richard Henderson <rth at cygnus dot com>
- Subject: Re: sh-coff broken
- From: Alexandre Oliva <aoliva at redhat dot com>
- Date: 14 Sep 2000 14:39:18 -0300
- Cc: Joern Rennecke <amylaar at cygnus dot co dot uk>, gcc-patches at gcc dot gnu dot org
- Organization: GCC Team, Red Hat
- References: <200009140001.BAA16009@phal.cygnus.co.uk><orlmwv58w0.fsf@guarana.lsd.ic.unicamp.br><20000914102456.D11179@cygnus.com>
On Sep 14, 2000, Richard Henderson <rth@cygnus.com> wrote:
> On Thu, Sep 14, 2000 at 11:46:23AM -0300, Alexandre Oliva wrote:
>> That would be in ld/scripttempl/sh.sc. However, after several
>> attempts, I couldn't find out a simple way for GCC's crtstuff.c to
>> interact with the crt[1in].asm files on COFF the way it does on ELF.
> Really? I used to do exactly this on m68k-apple-aux,
> which used coff. And I didn't even do anything weird.
The problem is that crtstuff generates, in the `.init' section, when
not !defined(OBJECT_FORMAT_ELF), a function prologue in crtbegin.o and
an epilogue in crtend.o, which duplicate crti.o and crtn.o. Also, it
doesn't define `_init' and `_fini' symbols, as expected by crt1.asm.
Also, it apparently wouldn't generate a `.fini' section.
I tested several combinations, and ended up deciding to revert the
patch for COFF. I might give it another try further down the road.
--
Alexandre Oliva Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist *Please* write to mailing lists, not to me