http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48524
--- Comment #3 from joseph at codesourcery dot com <joseph at codesourcery dot
com> 2011-04-10 00:27:28 UTC ---
On Sat, 9 Apr 2011, dirtyepic at gentoo dot org wrote:
> Sorry, i just wanted a trivial example. The actual rule we use is
>
> %{!D_FORTIFY_SOURCE:%{!D_FORTIFY_SOURCE=*:%{!U_FORTIFY_SOURCE:-D_FORTIFY_SOURCE=2}}}
>
> but this is just one example of several. The reason we use specs instead of
> just changing the default is so we can easily bypass them at runtime. This
> allows us, for example, to have a single compiler for both normal and hardened
> profiles.
>
> I understand what you're saying, but it still seems like an omission to me to
> not have a way to match switches with separate arguments. Surely this isn't
> the only case where this is useful?
The same principle applies that if you wish to submit a patch to add such
a feature it is desirable to have a (properly functional) use case in FSF
GCC, as code with no such use case is liable to be removed in cleanups.