public inbox for glibc-cvs@sourceware.org
help / color / mirror / Atom feed
* [glibc/maskray/grte] Disable static linking warning for dlopen and dlmopen, and disable linking warning for sys_errlist a
@ 2021-08-27 23:24 Fangrui Song
  0 siblings, 0 replies; only message in thread
From: Fangrui Song @ 2021-08-27 23:24 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=8eb1716c9108c987004e886e37d33296032d8663

commit 8eb1716c9108c987004e886e37d33296032d8663
Author: Paul Pluzhnikov <ppluzhnikov@google.com>
Date:   Fri Feb 28 16:51:12 2014 -0800

    Disable static linking warning for dlopen and dlmopen, and disable linking warning for sys_errlist and sys_nerr.

Diff:
---
 dlfcn/dlmopen.c                | 2 ++
 dlfcn/dlopen.c                 | 2 ++
 sysdeps/gnu/errlist-compat.awk | 7 ++++++-
 3 files changed, 10 insertions(+), 1 deletion(-)

diff --git a/dlfcn/dlmopen.c b/dlfcn/dlmopen.c
index 87ba290464..2be13195fe 100644
--- a/dlfcn/dlmopen.c
+++ b/dlfcn/dlmopen.c
@@ -30,7 +30,9 @@ dlmopen (Lmid_t nsid, const char *file, int mode)
 {
   return __dlmopen (nsid, file, mode, RETURN_ADDRESS (0));
 }
+#if 0  // Google-local
 static_link_warning (dlmopen)
+#endif
 
 #else
 
diff --git a/dlfcn/dlopen.c b/dlfcn/dlopen.c
index 95bc62b6b5..c62ca2305a 100644
--- a/dlfcn/dlopen.c
+++ b/dlfcn/dlopen.c
@@ -29,7 +29,9 @@ dlopen (const char *file, int mode)
 {
   return __dlopen (file, mode, RETURN_ADDRESS (0));
 }
+#if 0  // Google-local
 static_link_warning (dlopen)
+#endif
 
 #else
 
diff --git a/sysdeps/gnu/errlist-compat.awk b/sysdeps/gnu/errlist-compat.awk
index ba1257ffab..a33ee503da 100644
--- a/sysdeps/gnu/errlist-compat.awk
+++ b/sysdeps/gnu/errlist-compat.awk
@@ -126,8 +126,13 @@ versioned_symbol (libc, __sys_nerr_internal, _sys_nerr, %s);\n", \
     lastv, lastv, lastv, lastv;
 
   print "\n\
+/* Google-local:\n\
+   Disable deprecation warnings; they're emitted even if referenced\n\
+   only by debug info. */\n\
+#if 0\n\
 link_warning (sys_errlist, \"\
 `sys_errlist' is deprecated; use `strerror' or `strerror_r' instead\")\n\
 link_warning (sys_nerr, \"\
-`sys_nerr' is deprecated; use `strerror' or `strerror_r' instead\")";
+`sys_nerr' is deprecated; use `strerror' or `strerror_r' instead\")\n\
+#endif";
 }


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-08-27 23:24 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-27 23:24 [glibc/maskray/grte] Disable static linking warning for dlopen and dlmopen, and disable linking warning for sys_errlist a Fangrui Song

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).