PATCH: translate_options before -b processing

Geoff Keating geoffk@geoffk.org
Thu Oct 31 15:03:00 GMT 2002


Devang Patel <dpatel@apple.com> writes:

> This little patch allows to process translate_options()
> before processing -b and -V. Target like darwin has options
> that start with -b.
> 
> Bootstrapped and tested on powerpc-apple-darwin6.0
> 
> 2002-10-30  Devang Patel <dpatel@apple.com>
> 	* gcc.c (process_command): Translate options before processing
> 	-V and -b.
> 	
> OK?

The reason that -V and -b are processed first is that the results of
translate_options can vary by version and target.  For instance, what
happens if you install the Darwin compiler together with some other
compiler (let's say powerpc-eabisim), and write:

gcc -b powerpc-eabisim -static t.c

Won't this patch cause -static to be translated into "-static -Wa,-static",
and thus the compilation to fail?

-- 
- Geoffrey Keating <geoffk@geoffk.org>



More information about the Gcc-patches mailing list