summary refs log tree commit diff
diff options
context:
space:
mode:
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>2020-05-18 17:41:25 -0300
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2020-07-07 15:02:57 -0300
commit325081b9eb2035f8f025255206889208f330b590 (patch)
tree43a32de8fdd6777e290d7310795b41ea86df12b6
parentbfe05aa289054744b68f136b701705cfd242c4de (diff)
downloadglibc-325081b9eb2035f8f025255206889208f330b590.tar.gz
glibc-325081b9eb2035f8f025255206889208f330b590.tar.xz
glibc-325081b9eb2035f8f025255206889208f330b590.zip
string: Add strerrorname_np and strerrordesc_np
The strerrorname_np returns error number name (e.g. "EINVAL" for EINVAL)
while strerrordesc_np returns string describing error number (e.g
"Invalid argument" for EINVAL).  Different than strerror,
strerrordesc_np does not attempt to translate the return description,
both functions return NULL for an invalid error number.

They should be used instead of sys_errlist and sys_nerr, both are
thread and async-signal safe.  These functions are GNU extensions.

Checked on x86-64-linux-gnu, i686-linux-gnu, powerpc64le-linux-gnu,
and s390x-linux-gnu.

Tested-by: Carlos O'Donell <carlos@redhat.com>
Reviewed-by: Carlos O'Donell <carlos@redhat.com>
-rw-r--r--NEWS10
-rw-r--r--include/stdio.h1
-rw-r--r--manual/errno.texi23
-rw-r--r--stdio-common/errlist.c33
-rw-r--r--stdio-common/test-strerr.c65
-rw-r--r--string/Makefile3
-rw-r--r--string/Versions1
-rw-r--r--string/strerrordesc_np.c26
-rw-r--r--string/strerrorname_np.c25
-rw-r--r--string/string.h7
-rw-r--r--sysdeps/mach/hurd/i386/libc.abilist2
-rw-r--r--sysdeps/mach/hurd/test-err_np.c4
-rw-r--r--sysdeps/unix/sysv/linux/aarch64/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/alpha/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/arm/be/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/arm/le/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/csky/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/hppa/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/i386/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/ia64/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/m68k/coldfire/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/m68k/m680x0/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/microblaze/be/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/microblaze/le/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/mips/mips32/fpu/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/mips/mips32/nofpu/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/mips/mips64/n32/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/mips/mips64/n64/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/nios2/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc64/be/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/powerpc/powerpc64/le/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/riscv/rv64/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/s390/s390-32/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/s390/s390-64/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/sh/be/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/sh/le/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/sparc/sparc32/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/sparc/sparc64/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/x86_64/64/libc.abilist2
-rw-r--r--sysdeps/unix/sysv/linux/x86_64/x32/libc.abilist2
42 files changed, 259 insertions, 1 deletions
diff --git a/NEWS b/NEWS
index d673531dc5..03e82d8adc 100644
--- a/NEWS
+++ b/NEWS
@@ -57,6 +57,16 @@ Major new features:
   They should be used instead of sys_siglist or sys_sigabbrev and they
   are both thread and async-signal safe.  These functions are GNU extensions.
 
+* The functions strerrorname_np and strerrordesc_np have been added.  The
+  strerroname_np returns error number name (e.g. "EINVAL" for EINVAL) while
+  strerrordesc_np returns string describing error number
+  (e.g "Invalid argument" for EINVAL).  Different than strerror,
+  strerrordesc_np does not attempt to translate the return description, both
+  functions return NULL for an invalid error number.
+
+  They should be used instead of sys_errlist and sys_nerr, both are
+  thread and async-signal safe.  These functions are GNU extensions.
+
 Deprecated and removed features, and other changes affecting compatibility:
 
 * The deprecated <sys/sysctl.h> header and the sysctl function have been
diff --git a/include/stdio.h b/include/stdio.h
index 9e3bf6fe42..bc67d020d4 100644
--- a/include/stdio.h
+++ b/include/stdio.h
@@ -187,6 +187,7 @@ libc_hidden_proto (__libc_readline_unlocked);
 
 extern const char *const _sys_errlist_internal[] attribute_hidden;
 extern const char *__get_errlist (int) attribute_hidden;
+extern const char *__get_errname (int) attribute_hidden;
 
 libc_hidden_ldbl_proto (__asprintf)
 
diff --git a/manual/errno.texi b/manual/errno.texi
index 8cb4ce8b48..1834339220 100644
--- a/manual/errno.texi
+++ b/manual/errno.texi
@@ -1207,6 +1207,29 @@ to @code{errno}.
 The function @code{perror} is declared in @file{stdio.h}.
 @end deftypefun
 
+@deftypefun void strerrorname_np (int @var{errnum})
+@standards{GNU, string.h}
+@safety{@prelim{}@mtsafe{}@assafe{}@acsafe{}}
+This function returns the name describing the error @var{errnum} or
+@code{NULL} if there is no known constant with this value (e.g "EINVAL"
+for @code{EINVAL}).
+
+@pindex string.h
+This function is a GNU extension, declared in the header file @file{string.h}.
+@end deftypefun
+
+@deftypefun void strerrordesc_np (int @var{errnum})
+@standards{GNU, string.h}
+@safety{@prelim{}@mtsafe{}@assafe{}@acsafe{}}
+This function returns the message describing the error @var{errnum} or
+@code{NULL} if there is no known constant with this value (e.g "Invalid
+argument" for @code{EINVAL}).  Different than @code{strerror} the returned
+description is not translated.
+
+@pindex string.h
+This function is a GNU extension, declared in the header file @file{string.h}.
+@end deftypefun
+
 @code{strerror} and @code{perror} produce the exact same message for any
 given error code; the precise text varies from system to system.  With
 @theglibc{}, the messages are fairly short; there are no multi-line
diff --git a/stdio-common/errlist.c b/stdio-common/errlist.c
index df52356066..d15f13a22a 100644
--- a/stdio-common/errlist.c
+++ b/stdio-common/errlist.c
@@ -35,4 +35,37 @@ __get_errlist (int errnum)
   return NULL;
 }
 
+static const union sys_errname_t
+{
+  struct
+  {
+#define MSGSTRFIELD1(line) str##line
+#define MSGSTRFIELD(line)  MSGSTRFIELD1(line)
+#define _S(n, str)         char MSGSTRFIELD(__LINE__)[sizeof(str)];
+#include <errlist.h>
+#undef _S
+  };
+  char str[0];
+} _sys_errname = { {
+#define _S(n, s) s,
+#include <errlist.h>
+#undef _S
+} };
+
+static const unsigned short _sys_errnameidx[] =
+{
+#define _S(n, s) [n] = offsetof(union sys_errname_t, MSGSTRFIELD(__LINE__)),
+#include <errlist.h>
+#undef _S
+};
+
+const char *
+__get_errname (int errnum)
+{
+  if (errnum < 0 || errnum >= array_length (_sys_errnameidx)
+      || (errnum > 0 && _sys_errnameidx[errnum] == 0))
+    return NULL;
+  return _sys_errname.str + _sys_errnameidx[errnum];
+}
+
 #include <errlist-compat.c>
diff --git a/stdio-common/test-strerr.c b/stdio-common/test-strerr.c
new file mode 100644
index 0000000000..fded208118
--- /dev/null
+++ b/stdio-common/test-strerr.c
@@ -0,0 +1,65 @@
+/* Test strerrorname_np and strerrordesc_np.
+   Copyright (C) 2020 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Lesser General Public
+   License as published by the Free Software Foundation; either
+   version 2.1 of the License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public
+   License along with the GNU C Library; if not, see
+   <https://www.gnu.org/licenses/>.  */
+
+#include <string.h>
+#include <errno.h>
+#include <array_length.h>
+
+#include <support/support.h>
+#include <support/check.h>
+
+#define N_(name)      name
+
+static const char *const errlist[] =
+  {
+/* This file is auto-generated from errlist.def.  */
+#include <errlist.h>
+  };
+
+#define MSGSTR_T errname_t
+#define MSGSTR   errname
+#define MSGIDX   errnameidx
+#include <errlist-name.h>
+#undef MSGSTR
+#undef MSGIDX
+
+static int
+do_test (void)
+{
+  TEST_VERIFY (strerrordesc_np (-1) == NULL);
+  TEST_VERIFY (strerrordesc_np (array_length (errlist)) == NULL);
+  for (size_t i = 0; i < array_length (errlist); i++)
+    {
+      if (errlist[i] == NULL)
+        continue;
+      TEST_COMPARE_STRING (strerrordesc_np (i), errlist[i]);
+    }
+
+  TEST_VERIFY (strerrorname_np (-1) == NULL);
+  TEST_VERIFY (strerrorname_np (array_length (errlist)) == NULL);
+  for (size_t i = 0; i < array_length (errlist); i++)
+    {
+      if (errlist[i] == NULL)
+        continue;
+      TEST_COMPARE_STRING (strerrorname_np (i), errname.str + errnameidx[i]);
+    }
+
+  return 0;
+}
+
+#include <support/test-driver.c>
diff --git a/string/Makefile b/string/Makefile
index 8fe7e17fe2..f8d3104e16 100644
--- a/string/Makefile
+++ b/string/Makefile
@@ -45,7 +45,8 @@ routines	:= strcat strchr strcmp strcoll strcpy strcspn		\
 		   envz basename					\
 		   strcoll_l strxfrm_l string-inlines memrchr		\
 		   xpg-strerror strerror_l explicit_bzero		\
-		   sigdescr_np sigabbrev_np
+		   sigdescr_np sigabbrev_np strerrorname_np		\
+		   strerrordesc_np
 
 strop-tests	:= memchr memcmp memcpy memmove mempcpy memset memccpy	\
 		   stpcpy stpncpy strcat strchr strcmp strcpy strcspn	\
diff --git a/string/Versions b/string/Versions
index 6f8dd2d372..298ecd401a 100644
--- a/string/Versions
+++ b/string/Versions
@@ -87,5 +87,6 @@ libc {
   }
   GLIBC_2.32 {
     sigdescr_np; sigabbrev_np;
+    strerrordesc_np; strerrorname_np;
   }
 }
diff --git a/string/strerrordesc_np.c b/string/strerrordesc_np.c
new file mode 100644
index 0000000000..cdaf3a7f44
--- /dev/null
+++ b/string/strerrordesc_np.c
@@ -0,0 +1,26 @@
+/* Return string describing error number.
+   Copyright (C) 2020 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Lesser General Public
+   License as published by the Free Software Foundation; either
+   version 2.1 of the License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public
+   License along with the GNU C Library; if not, see
+   <https://www.gnu.org/licenses/>.  */
+
+#include <stdio.h>
+
+const char *
+__strerrordesc_np (int errnum)
+{
+  return __get_errlist (errnum);
+}
+weak_alias (__strerrordesc_np, strerrordesc_np)
diff --git a/string/strerrorname_np.c b/string/strerrorname_np.c
new file mode 100644
index 0000000000..bc337d20c2
--- /dev/null
+++ b/string/strerrorname_np.c
@@ -0,0 +1,25 @@
+/* Return string describing errno name.
+   Copyright (C) 2020 Free Software Foundation, Inc.
+   This file is part of the GNU C Library.
+
+   The GNU C Library is free software; you can redistribute it and/or
+   modify it under the terms of the GNU Lesser General Public
+   License as published by the Free Software Foundation; either
+   version 2.1 of the License, or (at your option) any later version.
+
+   The GNU C Library is distributed in the hope that it will be useful,
+   but WITHOUT ANY WARRANTY; without even the implied warranty of
+   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+   Lesser General Public License for more details.
+
+   You should have received a copy of the GNU Lesser General Public
+   License along with the GNU C Library; if not, see
+   <https://www.gnu.org/licenses/>.  */
+
+#include <stdio.h>
+
+const char *
+strerrorname_np (int errnum)
+{
+  return __get_errname (errnum);
+}
diff --git a/string/string.h b/string/string.h
index 0119d7f45d..b0be00c0f7 100644
--- a/string/string.h
+++ b/string/string.h
@@ -428,6 +428,13 @@ extern int __xpg_strerror_r (int __errnum, char *__buf, size_t __buflen)
 extern char *strerror_r (int __errnum, char *__buf, size_t __buflen)
      __THROW __nonnull ((2)) __wur  __attr_access ((__write_only__, 2, 3));
 # endif
+
+# ifdef __USE_GNU
+/* Return a string describing the meaning of tthe error in ERR.  */
+extern const char *strerrordesc_np (int __err) __THROW;
+/* Return a string with the error name in ERR.  */
+extern const char *strerrorname_np (int __err) __THROW;
+# endif
 #endif
 
 #ifdef __USE_XOPEN2K8
diff --git a/sysdeps/mach/hurd/i386/libc.abilist b/sysdeps/mach/hurd/i386/libc.abilist
index 881b689788..5f6154d518 100644
--- a/sysdeps/mach/hurd/i386/libc.abilist
+++ b/sysdeps/mach/hurd/i386/libc.abilist
@@ -2186,6 +2186,8 @@ GLIBC_2.32 mach_print F
 GLIBC_2.32 mremap F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.32 thrd_current F
 GLIBC_2.32 thrd_equal F
 GLIBC_2.32 thrd_sleep F
diff --git a/sysdeps/mach/hurd/test-err_np.c b/sysdeps/mach/hurd/test-err_np.c
new file mode 100644
index 0000000000..3127141128
--- /dev/null
+++ b/sysdeps/mach/hurd/test-err_np.c
@@ -0,0 +1,4 @@
+#include <mach/error.h>
+
+#define ERR_MAP(value) err_get_code (value)
+#include <stdio-common/test-err_np.c>
diff --git a/sysdeps/unix/sysv/linux/aarch64/libc.abilist b/sysdeps/unix/sysv/linux/aarch64/libc.abilist
index 0158b8ae02..008a6c8e52 100644
--- a/sysdeps/unix/sysv/linux/aarch64/libc.abilist
+++ b/sysdeps/unix/sysv/linux/aarch64/libc.abilist
@@ -2159,3 +2159,5 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
diff --git a/sysdeps/unix/sysv/linux/alpha/libc.abilist b/sysdeps/unix/sysv/linux/alpha/libc.abilist
index 86ebaa643d..2cfc5733ed 100644
--- a/sysdeps/unix/sysv/linux/alpha/libc.abilist
+++ b/sysdeps/unix/sysv/linux/alpha/libc.abilist
@@ -2241,6 +2241,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 _IO_fprintf F
 GLIBC_2.4 _IO_printf F
 GLIBC_2.4 _IO_sprintf F
diff --git a/sysdeps/unix/sysv/linux/arm/be/libc.abilist b/sysdeps/unix/sysv/linux/arm/be/libc.abilist
index d93ef6ba13..0e1677b5a0 100644
--- a/sysdeps/unix/sysv/linux/arm/be/libc.abilist
+++ b/sysdeps/unix/sysv/linux/arm/be/libc.abilist
@@ -143,6 +143,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 _Exit F
 GLIBC_2.4 _IO_2_1_stderr_ D 0xa0
 GLIBC_2.4 _IO_2_1_stdin_ D 0xa0
diff --git a/sysdeps/unix/sysv/linux/arm/le/libc.abilist b/sysdeps/unix/sysv/linux/arm/le/libc.abilist
index b78291a88b..e544ed75a4 100644
--- a/sysdeps/unix/sysv/linux/arm/le/libc.abilist
+++ b/sysdeps/unix/sysv/linux/arm/le/libc.abilist
@@ -140,6 +140,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 _Exit F
 GLIBC_2.4 _IO_2_1_stderr_ D 0xa0
 GLIBC_2.4 _IO_2_1_stdin_ D 0xa0
diff --git a/sysdeps/unix/sysv/linux/csky/libc.abilist b/sysdeps/unix/sysv/linux/csky/libc.abilist
index 0305dfe243..6bb8042657 100644
--- a/sysdeps/unix/sysv/linux/csky/libc.abilist
+++ b/sysdeps/unix/sysv/linux/csky/libc.abilist
@@ -2103,3 +2103,5 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
diff --git a/sysdeps/unix/sysv/linux/hppa/libc.abilist b/sysdeps/unix/sysv/linux/hppa/libc.abilist
index 0ffa0fbceb..e0f8f29c40 100644
--- a/sysdeps/unix/sysv/linux/hppa/libc.abilist
+++ b/sysdeps/unix/sysv/linux/hppa/libc.abilist
@@ -2062,6 +2062,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 __confstr_chk F
 GLIBC_2.4 __fgets_chk F
 GLIBC_2.4 __fgets_unlocked_chk F
diff --git a/sysdeps/unix/sysv/linux/i386/libc.abilist b/sysdeps/unix/sysv/linux/i386/libc.abilist
index 91a1ad63f1..155dd51e0d 100644
--- a/sysdeps/unix/sysv/linux/i386/libc.abilist
+++ b/sysdeps/unix/sysv/linux/i386/libc.abilist
@@ -2228,6 +2228,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 __confstr_chk F
 GLIBC_2.4 __fgets_chk F
 GLIBC_2.4 __fgets_unlocked_chk F
diff --git a/sysdeps/unix/sysv/linux/ia64/libc.abilist b/sysdeps/unix/sysv/linux/ia64/libc.abilist
index e94fc37acb..8cc12aa326 100644
--- a/sysdeps/unix/sysv/linux/ia64/libc.abilist
+++ b/sysdeps/unix/sysv/linux/ia64/libc.abilist
@@ -2094,6 +2094,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 __confstr_chk F
 GLIBC_2.4 __fgets_chk F
 GLIBC_2.4 __fgets_unlocked_chk F
diff --git a/sysdeps/unix/sysv/linux/m68k/coldfire/libc.abilist b/sysdeps/unix/sysv/linux/m68k/coldfire/libc.abilist
index 9565a76b1b..e02a61591c 100644
--- a/sysdeps/unix/sysv/linux/m68k/coldfire/libc.abilist
+++ b/sysdeps/unix/sysv/linux/m68k/coldfire/libc.abilist
@@ -144,6 +144,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 _Exit F
 GLIBC_2.4 _IO_2_1_stderr_ D 0x98
 GLIBC_2.4 _IO_2_1_stdin_ D 0x98
diff --git a/sysdeps/unix/sysv/linux/m68k/m680x0/libc.abilist b/sysdeps/unix/sysv/linux/m68k/m680x0/libc.abilist
index 9391092151..8e90d9744a 100644
--- a/sysdeps/unix/sysv/linux/m68k/m680x0/libc.abilist
+++ b/sysdeps/unix/sysv/linux/m68k/m680x0/libc.abilist
@@ -2174,6 +2174,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 __confstr_chk F
 GLIBC_2.4 __fgets_chk F
 GLIBC_2.4 __fgets_unlocked_chk F
diff --git a/sysdeps/unix/sysv/linux/microblaze/be/libc.abilist b/sysdeps/unix/sysv/linux/microblaze/be/libc.abilist
index 37f1f58b7f..76e402cbf5 100644
--- a/sysdeps/unix/sysv/linux/microblaze/be/libc.abilist
+++ b/sysdeps/unix/sysv/linux/microblaze/be/libc.abilist
@@ -2154,3 +2154,5 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
diff --git a/sysdeps/unix/sysv/linux/microblaze/le/libc.abilist b/sysdeps/unix/sysv/linux/microblaze/le/libc.abilist
index 8a3508d64e..8528547aa2 100644
--- a/sysdeps/unix/sysv/linux/microblaze/le/libc.abilist
+++ b/sysdeps/unix/sysv/linux/microblaze/le/libc.abilist
@@ -2151,3 +2151,5 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
diff --git a/sysdeps/unix/sysv/linux/mips/mips32/fpu/libc.abilist b/sysdeps/unix/sysv/linux/mips/mips32/fpu/libc.abilist
index 7fce235f44..2b838c0c8e 100644
--- a/sysdeps/unix/sysv/linux/mips/mips32/fpu/libc.abilist
+++ b/sysdeps/unix/sysv/linux/mips/mips32/fpu/libc.abilist
@@ -2145,6 +2145,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 __confstr_chk F
 GLIBC_2.4 __fgets_chk F
 GLIBC_2.4 __fgets_unlocked_chk F
diff --git a/sysdeps/unix/sysv/linux/mips/mips32/nofpu/libc.abilist b/sysdeps/unix/sysv/linux/mips/mips32/nofpu/libc.abilist
index e31fff7fd2..9cde04785c 100644
--- a/sysdeps/unix/sysv/linux/mips/mips32/nofpu/libc.abilist
+++ b/sysdeps/unix/sysv/linux/mips/mips32/nofpu/libc.abilist
@@ -2143,6 +2143,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 __confstr_chk F
 GLIBC_2.4 __fgets_chk F
 GLIBC_2.4 __fgets_unlocked_chk F
diff --git a/sysdeps/unix/sysv/linux/mips/mips64/n32/libc.abilist b/sysdeps/unix/sysv/linux/mips/mips64/n32/libc.abilist
index 4395989439..be180e71cf 100644
--- a/sysdeps/unix/sysv/linux/mips/mips64/n32/libc.abilist
+++ b/sysdeps/unix/sysv/linux/mips/mips64/n32/libc.abilist
@@ -2151,6 +2151,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 __confstr_chk F
 GLIBC_2.4 __fgets_chk F
 GLIBC_2.4 __fgets_unlocked_chk F
diff --git a/sysdeps/unix/sysv/linux/mips/mips64/n64/libc.abilist b/sysdeps/unix/sysv/linux/mips/mips64/n64/libc.abilist
index 3ed5b95118..8569cfb6cb 100644
--- a/sysdeps/unix/sysv/linux/mips/mips64/n64/libc.abilist
+++ b/sysdeps/unix/sysv/linux/mips/mips64/n64/libc.abilist
@@ -2145,6 +2145,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 __confstr_chk F
 GLIBC_2.4 __fgets_chk F
 GLIBC_2.4 __fgets_unlocked_chk F
diff --git a/sysdeps/unix/sysv/linux/nios2/libc.abilist b/sysdeps/unix/sysv/linux/nios2/libc.abilist
index e940ebcf7f..bce6c79b9b 100644
--- a/sysdeps/unix/sysv/linux/nios2/libc.abilist
+++ b/sysdeps/unix/sysv/linux/nios2/libc.abilist
@@ -2192,3 +2192,5 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/libc.abilist b/sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/libc.abilist
index 34a84b4eb9..1d0158a08e 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/libc.abilist
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu/libc.abilist
@@ -2201,6 +2201,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 _IO_fprintf F
 GLIBC_2.4 _IO_printf F
 GLIBC_2.4 _IO_sprintf F
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/libc.abilist b/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/libc.abilist
index 2caf08d819..f65772cf8a 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/libc.abilist
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc32/nofpu/libc.abilist
@@ -2234,6 +2234,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 _IO_fprintf F
 GLIBC_2.4 _IO_printf F
 GLIBC_2.4 _IO_sprintf F
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/be/libc.abilist b/sysdeps/unix/sysv/linux/powerpc/powerpc64/be/libc.abilist
index efa4cef913..cfe526b916 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/be/libc.abilist
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/be/libc.abilist
@@ -2064,6 +2064,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 _IO_fprintf F
 GLIBC_2.4 _IO_printf F
 GLIBC_2.4 _IO_sprintf F
diff --git a/sysdeps/unix/sysv/linux/powerpc/powerpc64/le/libc.abilist b/sysdeps/unix/sysv/linux/powerpc/powerpc64/le/libc.abilist
index 80bc0369cb..cbe0cf3d7e 100644
--- a/sysdeps/unix/sysv/linux/powerpc/powerpc64/le/libc.abilist
+++ b/sysdeps/unix/sysv/linux/powerpc/powerpc64/le/libc.abilist
@@ -2354,3 +2354,5 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
diff --git a/sysdeps/unix/sysv/linux/riscv/rv64/libc.abilist b/sysdeps/unix/sysv/linux/riscv/rv64/libc.abilist
index 665fa4293f..b361308505 100644
--- a/sysdeps/unix/sysv/linux/riscv/rv64/libc.abilist
+++ b/sysdeps/unix/sysv/linux/riscv/rv64/libc.abilist
@@ -2121,3 +2121,5 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
diff --git a/sysdeps/unix/sysv/linux/s390/s390-32/libc.abilist b/sysdeps/unix/sysv/linux/s390/s390-32/libc.abilist
index 979908d1bc..37e313a1b0 100644
--- a/sysdeps/unix/sysv/linux/s390/s390-32/libc.abilist
+++ b/sysdeps/unix/sysv/linux/s390/s390-32/libc.abilist
@@ -2199,6 +2199,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 _IO_fprintf F
 GLIBC_2.4 _IO_printf F
 GLIBC_2.4 _IO_sprintf F
diff --git a/sysdeps/unix/sysv/linux/s390/s390-64/libc.abilist b/sysdeps/unix/sysv/linux/s390/s390-64/libc.abilist
index 891c4928ce..5ff64d8a0a 100644
--- a/sysdeps/unix/sysv/linux/s390/s390-64/libc.abilist
+++ b/sysdeps/unix/sysv/linux/s390/s390-64/libc.abilist
@@ -2100,6 +2100,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 _IO_fprintf F
 GLIBC_2.4 _IO_printf F
 GLIBC_2.4 _IO_sprintf F
diff --git a/sysdeps/unix/sysv/linux/sh/be/libc.abilist b/sysdeps/unix/sysv/linux/sh/be/libc.abilist
index ea3f915821..7e65b3e317 100644
--- a/sysdeps/unix/sysv/linux/sh/be/libc.abilist
+++ b/sysdeps/unix/sysv/linux/sh/be/libc.abilist
@@ -2069,6 +2069,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 __confstr_chk F
 GLIBC_2.4 __fgets_chk F
 GLIBC_2.4 __fgets_unlocked_chk F
diff --git a/sysdeps/unix/sysv/linux/sh/le/libc.abilist b/sysdeps/unix/sysv/linux/sh/le/libc.abilist
index c6a9643a49..6a3eeed921 100644
--- a/sysdeps/unix/sysv/linux/sh/le/libc.abilist
+++ b/sysdeps/unix/sysv/linux/sh/le/libc.abilist
@@ -2066,6 +2066,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 __confstr_chk F
 GLIBC_2.4 __fgets_chk F
 GLIBC_2.4 __fgets_unlocked_chk F
diff --git a/sysdeps/unix/sysv/linux/sparc/sparc32/libc.abilist b/sysdeps/unix/sysv/linux/sparc/sparc32/libc.abilist
index 7bb54cc2bd..196f7f2543 100644
--- a/sysdeps/unix/sysv/linux/sparc/sparc32/libc.abilist
+++ b/sysdeps/unix/sysv/linux/sparc/sparc32/libc.abilist
@@ -2190,6 +2190,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 _IO_fprintf F
 GLIBC_2.4 _IO_printf F
 GLIBC_2.4 _IO_sprintf F
diff --git a/sysdeps/unix/sysv/linux/sparc/sparc64/libc.abilist b/sysdeps/unix/sysv/linux/sparc/sparc64/libc.abilist
index bcf36910ab..2ca03d7062 100644
--- a/sysdeps/unix/sysv/linux/sparc/sparc64/libc.abilist
+++ b/sysdeps/unix/sysv/linux/sparc/sparc64/libc.abilist
@@ -2117,6 +2117,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 __confstr_chk F
 GLIBC_2.4 __fgets_chk F
 GLIBC_2.4 __fgets_unlocked_chk F
diff --git a/sysdeps/unix/sysv/linux/x86_64/64/libc.abilist b/sysdeps/unix/sysv/linux/x86_64/64/libc.abilist
index a077414c66..86a481be42 100644
--- a/sysdeps/unix/sysv/linux/x86_64/64/libc.abilist
+++ b/sysdeps/unix/sysv/linux/x86_64/64/libc.abilist
@@ -2075,6 +2075,8 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F
 GLIBC_2.4 __confstr_chk F
 GLIBC_2.4 __fgets_chk F
 GLIBC_2.4 __fgets_unlocked_chk F
diff --git a/sysdeps/unix/sysv/linux/x86_64/x32/libc.abilist b/sysdeps/unix/sysv/linux/x86_64/x32/libc.abilist
index e2b881542c..056de03ae3 100644
--- a/sysdeps/unix/sysv/linux/x86_64/x32/libc.abilist
+++ b/sysdeps/unix/sysv/linux/x86_64/x32/libc.abilist
@@ -2172,3 +2172,5 @@ GLIBC_2.32 pthread_getattr_np F
 GLIBC_2.32 pthread_sigmask F
 GLIBC_2.32 sigabbrev_np F
 GLIBC_2.32 sigdescr_np F
+GLIBC_2.32 strerrordesc_np F
+GLIBC_2.32 strerrorname_np F