This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


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

Re: Writing a new BFD backend?


> 
>    Date: Thu, 6 Nov 1997 15:46:50 +0100
>    From: Michael Schwingen <michaels@stochastik.rwth-aachen.de>
> 
>    I hope this is at least remotelt on topic here.
> 
> There is already a mailing list for BFD development discussions:
> bfd@cygnus.com.  Send a note to bfd-request@cygnus.com in order to
> join.
> 
>    Is there any hint where to start, or where to look for more information?
> 
> I'm afraid not.  The documentation is out of date and actively
> misleading.  All you can do is look at existing backends and try to
> emulate them.  In my opinion the ELF and ECOFF backends are probably
> the cleanest.

For what he needs to do, IMHO, it's quicker and far more easy to just write
a little utility that links against libbfd.a, reads the sections and builds
a file for the target.  Besides that, you get the added advantage of knowing
that your toolchain is working properly by default since it's using m68k-coff
or m68k-elf.  This is the approach I took for PalmPilot, with the vision of
producing a BFD back end eventually, but there would be problems with that
since PalmPilot apps have all sorts of resources and such, which means
might fit arbitrary sections, but also a whole lot of other things that 
don't really fit the model.

If you'd like to start with my code for this (easy to understand, and also
deals with relocation info, thanks to Kresten Krab Thorup), look at
ftp://ryeham.ee.ryerson.ca/pub/PalmOS/prc-tools.0.5.0.tar.gz and find
the obj-res and build-prc utilities.  It's all GPL'd of course.

Jeff.

> 
> If you ask on bfd@cygnus.com, others may be able to help.  I can
> answer specific questions, but general questions are tough.
> 
> Ian
> 



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