Blame SOURCES/glibc-rh1505492-undef-21.patch

c6d234
commit eb1ed03dafcd9a7ea6e95b958413342e20b35968
c6d234
Author: Roland McGrath <roland@hack.frob.com>
c6d234
Date:   Mon May 5 13:06:18 2014 -0700
c6d234
c6d234
    Fix -Wundef issues in generated errlist.c.
c6d234
c6d234
Conflicts:
c6d234
	sysdeps/gnu/errlist.awk
c6d234
	sysdeps/gnu/errlist.c
c6d234
c6d234
Due to IS_IN backport in glibc-rh1256317-2.patch.
c6d234
c6d234
diff --git a/sysdeps/gnu/errlist.awk b/sysdeps/gnu/errlist.awk
c6d234
index 8bad43199cd9e1c4..ebae2a6398c2697e 100644
c6d234
--- a/sysdeps/gnu/errlist.awk
c6d234
+++ b/sysdeps/gnu/errlist.awk
c6d234
@@ -52,6 +52,7 @@ BEGIN {
c6d234
     print "#ifdef ERR_MAX";
c6d234
     print "# define ERRLIST_SIZE ERR_MAX + 1";
c6d234
     print "#else"
c6d234
+    print "# define ERR_MAX 0";
c6d234
     print "# define ERRLIST_SIZE";
c6d234
     print "#endif";
c6d234
 
c6d234
@@ -109,7 +110,7 @@ END {
c6d234
   print "  (sizeof _sys_errlist_internal / sizeof _sys_errlist_internal [0])";
c6d234
   print "const int _sys_nerr_internal = NERR;"
c6d234
   print "";
c6d234
-  print "#if IS_IN (libc) && !ERRLIST_NO_COMPAT";
c6d234
+  print "#if IS_IN (libc) && !defined ERRLIST_NO_COMPAT";
c6d234
   print "# include <errlist-compat.c>";
c6d234
   print "#endif";
c6d234
   print "";
c6d234
diff --git a/sysdeps/gnu/errlist.c b/sysdeps/gnu/errlist.c
c6d234
index 278f7998b592e92a..4551249d723f47a6 100644
c6d234
--- a/sysdeps/gnu/errlist.c
c6d234
+++ b/sysdeps/gnu/errlist.c
c6d234
@@ -13,6 +13,7 @@
c6d234
 #ifdef ERR_MAX
c6d234
 # define ERRLIST_SIZE ERR_MAX + 1
c6d234
 #else
c6d234
+# define ERR_MAX 0
c6d234
 # define ERRLIST_SIZE
c6d234
 #endif
c6d234
 const char *const _sys_errlist_internal[ERRLIST_SIZE] =
c6d234
@@ -1479,7 +1480,7 @@ TRANS error; @pxref{Cancel AIO Operations}. */
c6d234
   (sizeof _sys_errlist_internal / sizeof _sys_errlist_internal [0])
c6d234
 const int _sys_nerr_internal = NERR;
c6d234
 
c6d234
-#if IS_IN (libc) && !ERRLIST_NO_COMPAT
c6d234
+#if IS_IN (libc) && !defined ERRLIST_NO_COMPAT
c6d234
 # include <errlist-compat.c>
c6d234
 #endif
c6d234