This is the mail archive of the crossgcc@cygnus.com mailing list for the crossgcc project.


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

Re: Header Files


In crossgcc Olivier Carmona <Olivier.Carmona@epfl.ch> writes:

>I would like to know if we can have any control on the file header in
>the GNU tool chain for AOUT or COFF format. I have found clues in the
>LD documentation but only for the ELF format. My goal is to have at the
>end of the GNU tool chain a file ROMable. There is of course the simple
>solution that is to suppress the header at the end of the tool chain by
>a program made on purpose. Does anybody sees a better way ?

a.out and COFF have no equivalent to the ELF program headers, so I
think you are misunderstanding the PHDRS command.

It does not make sense to control the file header for a.out and COFF.
The header is completely determined by the contents of the file.

You may be asking for some way to generate a binary file.  To do that,
use objcopy with the binary output format.  I think there's a note on
this in the binutils or the ld documentation.  Using objcopy to
generate S-records is also appropriate for many ROM burners, and is
better than the binary format.

Ian