[patch] cosmetics for configure* in gcc

Andreas Schwab schwab@suse.de
Tue Sep 2 14:31:00 GMT 2008


Paolo Bonzini <bonzini@gnu.org> writes:

>>> +ACX_PROG_CC_WARNING_OPTS(
>>> +	[m4_do([-W -Wall -Wwrite-strings -Wstrict-prototypes ],
>>> +	       [-Wmissing-prototypes -Wcast-qual])], [loose_warn])
>>> +ACX_PROG_CC_WARNING_OPTS(
>>> +	[m4_do([-Wold-style-definition -Wc++-compat ], 
>>> +	       [-Wmissing-format-attribute])], [strict_warn])
>>> +ACX_PROG_CC_WARNING_ALMOST_PEDANTIC(
>>> +	[m4_do([-Wno-long-long -Wno-variadic-macros ], 
>>> +	       [-Wno-overlength-strings])], [strict_warn])
>> 
>> I don't think the m4_do call should be quoted.  In the last case this
>> results in a weird cache variable
>> (acx_cv_prog_cc_pedantic_m4_do__Wno_long_long__Wno_variadic_macros_____________Wno_overlength_strings_)
>> because ACX_PROG_CC_WARNING_ALMOST_PEDANTIC does not expand the first
>> argument when constructing it (which I think is correct).
>
> I think the safest option would be m4_quote(m4_do(...)).  Otherwise, the
> day someone adds -Wno-dnl you might be screwed. :-)

Good point, although autoconf wouldn't allow the word dnl to appear in
the output anyway.

Andreas.

-- 
Andreas Schwab, SuSE Labs, schwab@suse.de
SuSE Linux Products GmbH, Maxfeldstraße 5, 90409 Nürnberg, Germany
PGP key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."



More information about the Gcc-patches mailing list