This is the mail archive of the
mailing list for the glibc project.
Re: [WIP] Fix HAVE_CONFIG_H -Wundef warnings.
- From: Paul Eggert <eggert at cs dot ucla dot edu>
- To: Will Newton <will dot newton at linaro dot org>, Carlos O'Donell <carlos at redhat dot com>
- Cc: GNU C Library <libc-alpha at sourceware dot org>, Roland McGrath <roland at hack dot frob dot com>
- Date: Fri, 02 May 2014 12:18:04 -0700
- Subject: Re: [WIP] Fix HAVE_CONFIG_H -Wundef warnings.
- Authentication-results: sourceware.org; auth=none
- References: <5363562D dot 6030902 at redhat dot com> <CANu=Dmi8ce2zyto7Sv+Z-WB8yyf9n1CmAz8CK+tFC0UnG2451g at mail dot gmail dot com>
On 05/02/2014 01:28 AM, Will Newton wrote:
gnulib versions of the files have in some cases switched to use
#ifndef _LIBC instead of #if HAVE_CONFIG_H but I haven't delved into
why that is yet.
Some years ago gnulib changed, and it now assumes that <config.h> always
exists. We surround the include with "#ifndef _LIBC" only for files
shared with glibc. If glibc is also going to assume config.h exists, I
suggest getting rid of the #if, and using "#include <config.h>"
unconditionally; that's simplest.