[Top][All Lists]

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

Re: [libmicrohttpd] Add 'manywarnings' module from Wget2

From: Evgeny Grin
Subject: Re: [libmicrohttpd] Add 'manywarnings' module from Wget2
Date: Mon, 19 Jun 2017 18:48:47 +0300
User-agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.8.0

On 18.06.2017 13:45, Tim Rühsen wrote:
> maybe you like this...
> "    Add m4/wget_manywarnings
>     This enables (if switched on) basically all warnings for gcc and clang.
>     Exceptions are explicitly controlled in
>     To enable by default: create a file '.manywarnings'
>     Enable explicitly : ./configure --enable-manywarnings
>     Disable explicitly: ./configure --disable-manywarnings
>     New warnings of new compiler versions are automatically added.
>     This module works much faster than the 'manywarnings' module from gnulib.
>     Created for developers and Continuous Integration."
> I just added the WARN_FLAGS to src/microhttpd/, but if you like it 
> add it also to the other
> It might need some further tuning in to enable/disable warnings 
> (I 
> just copied the code from Wget2 were we ignore certain warning).

Hi Tim,

While idea is generally looks good, proposed implementation do not suit
well from my point of view.

Code is not self-explainable, so it should be well-documented.
For compatibility with future versions, code should test compiler
acceptance for added flags. Otherwise software may fail to build with
some new GCC/clang version.

Test for "gcc" is not correct:
    case $CC in
      *gcc*) CCNAME="gcc";;
      *clang*) CCNAME="clang";;

This fail on Darwin (where 'gcc' is symlink for 'clang') and on any
other platform with such symlink.
Moreover, 'gcc' could match directory part. For example
CC='/opt/compilers/gcc-like/clang-4.0/bin/clang' will be detected as 'gcc'.

Best Wishes,
Evgeny Grin

Attachment: signature.asc
Description: OpenPGP digital signature

reply via email to

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