This is the mail archive of the mailing list for the glibc project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Status of undef warnings fix?

On 04/28/2014 03:24 AM, Will Newton wrote:
> On 25 April 2014 21:25, Steve Ellcey <> wrote:
>> On Fri, 2014-04-25 at 20:06 +0100, Will Newton wrote:
>>> On 25 April 2014 19:03, Steve Ellcey <> wrote:
>>>> I was wondering what the status of the patches to fix the various
>>>> undef warnings in the glibc build was.  I.e.:
>>>> ../sysdeps/generic/ldsodefs.h:536:24: warning: "HP_SMALL_TIMING_AVAIL" is not defined [-Wundef]
>>>> I am getting 1665 of them during one build of glibc.
>>>> I see a set of patches that were submitted last month by Will Newton,
>>>> for
>>>> example.  But it doesn't look like they have been checked in yet.
>>> I reverted the patches as they were not the correct approach.
>>> Unfortunately for the majority of the warnings nobody has stepped up
>>> to implement the correct approach.
>> Do you have a pointer to what is considered 'the correct approach'.  I
>> tried reading through the email to find it but got lost in a maze of
>> twisty replies.
> My understanding is we want to use #if rather than #ifdef as far as
> possible so if someone typos a #define then the #if will cause a
> compile time warning rather than silently being treated as undefined.
> This means that rather than having a preprocessor symbol defined or
> not defined by an architecture to enable a feature the symbol should
> be defined to either 1 or 0 in every architecture. So to fix some of
> these warnings correctly involves cross-architecture patches and
> knowledge of how sysdeps works which I think partly explains why they
> are taking so long to fix.

I'm working to try fix some of these warnings, but it's slow progress.

They are indeed hard to fix in some cases.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]