This patch helps build error.c without warnings on glibc.
error: Fix -Wundef warnings in glibc
* lib/error.c [_LIBC]: Define default macros for
glibc.
(print_errno_message) [defined HAVE_STRERROR_R || _LIBC]:
Check _LIBC before STRERROR_R_CHAR_P.
2014-07-10 Siddhesh Poyarekar <siddhesh@redhat.com>
+ error: Fix -Wundef warnings in glibc
+ * lib/error.c [_LIBC]: Define default macros for
+ glibc.
+ (print_errno_message) [defined HAVE_STRERROR_R || _LIBC]:
+ Check _LIBC before STRERROR_R_CHAR_P.
+
error: Sync from glibc master
* lib/error.c [_LIBC]: Remove INTUSE usage.
(error_tail): Remove unused macro ALLOCA_LIMIT.
# include <stdint.h>
# include <wchar.h>
# define mbsrtowcs __mbsrtowcs
+# define USE_UNLOCKED_IO 0
+# define _GL_ATTRIBUTE_FORMAT_PRINTF(a, b)
+# define _GL_ARG_NONNULL(a)
#endif
#if USE_UNLOCKED_IO
#if defined HAVE_STRERROR_R || _LIBC
char errbuf[1024];
-# if STRERROR_R_CHAR_P || _LIBC
+# if _LIBC || STRERROR_R_CHAR_P
s = __strerror_r (errnum, errbuf, sizeof errbuf);
# else
if (__strerror_r (errnum, errbuf, sizeof errbuf) == 0)