This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: How to write a SPEC function that gets all arguments passed?
- From: Ian Lance Taylor <iant at google dot com>
- To: Georg Lay <avr at gjlay dot de>
- Cc: gcc at gcc dot gnu dot org
- Date: Tue, 07 Sep 2010 17:23:13 -0700
- Subject: Re: How to write a SPEC function that gets all arguments passed?
- References: <4C7FB183.1070008@gjlay.de>
Georg Lay <avr@gjlay.de> writes:
> Moreover, there will be a problem because the C function that actually
> implements my_record_switches must return a string starting with '-',
> there is no way to return "" or NULL to indicate that the function won't
> produce anything.
I would consider writing something like
-frecorded-gcc-switches=%(cc1_options)
to override the default behaviour. It seems to me that it should be
possible to get to where you want, although it might be a little painful
to get it all correct.
Ian