autoconf
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: RFE: macro for warning at configure-time if CFLAGS includes -Werror


From: Eric Blake
Subject: Re: RFE: macro for warning at configure-time if CFLAGS includes -Werror
Date: Wed, 19 Sep 2012 16:56:45 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:15.0) Gecko/20120828 Thunderbird/15.0

On 09/19/2012 04:49 PM, Bob Friesenhahn wrote:
> On Thu, 20 Sep 2012, Adrian Bunk wrote:
>>
>> IMHO the best solution for both package maintainers and people compiling
>> software would be:
>> - AC_PROG_CC always filters out -Werror
>> - when -Werror was filtered out, configure prints a message like
>>  "filtering out -Werror during configure"
>> - when -Werror was filtered out, AC_OUTPUT re-adds it
> 
> If this is done, there will be a compilation error when there is a
> warning, regardless of the cause of the warning.  That is what was
> requested but it might not be what was desired if a system header
> produces the warning.  The result might fail immediately.

Yes, but it would fail at make time _because_ the user requested
-Werror, and has buggy system headers; we honored the user's request, to
the point that the user's request is possible, without getting false
results during configure.  And, as has been pointed out elsewhere in the
flag, if there is an ability to do a per-compile undo of the filtering,
it will even be possible to write configure tests to detect such buggy
system headers in advance.

-- 
Eric Blake   address@hidden    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]