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


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

Re: gas obj-multi experiences? (and small gas/Makefile.am patch)


On Thu, 18 May 2000, Nick Clifton wrote:

> Hi Hans-Peter,
> 
> : Over to the real issue:
> : I'd like to make it simple to generate both a.out and ELF from
> : the same compiler-tools installation, using command-line options.
> : 
> : I believe having a single gas would simplify this greatly.  I
> : didn't think it was possible, but it looks like I can actually
> : make a single gas executable target both ELF and a.out (i386 and
> : mips currently), but there's not a peep about it in
> : internals.texi.  Perhaps it's work in progress or I've
> : misunderstood something.
> : 
> : Does anyone have any experience with trying this?
> : Alan? (Modra, the last person touching this, the ChangeLog tells.)

It works OK for x86 anyway.  You can set an env var, AS_EMULATION, to
select the output format.  Alternatively, you can select the output format
by giving gas --em=i386elf, --em=i386aout, or --em=i386coff  This assumes
of course that you have compiled gas with the correct --enable-targets.

It was relatively easy to enable this support for x86, and probably could 
be done for other targets too.  I take it from your question that you
weren't thinking about a gas that assembles for more than one
architecture, eg. m68k coff and x86 coff.  If you were, then that would be
a major undertaking.

-- 
Linuxcare.  Support for the Revolution.



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