summaryrefslogtreecommitdiff
path: root/nss
diff options
context:
space:
mode:
Diffstat (limited to 'nss')
-rw-r--r--nss/getXXbyYY.c2
-rw-r--r--nss/getXXbyYY_r.c2
-rw-r--r--nss/getXXent.c2
-rw-r--r--nss/getXXent_r.c6
-rw-r--r--nss/nsswitch.h8
5 files changed, 14 insertions, 6 deletions
diff --git a/nss/getXXbyYY.c b/nss/getXXbyYY.c
index 336676ad55..c308a70b93 100644
--- a/nss/getXXbyYY.c
+++ b/nss/getXXbyYY.c
@@ -151,4 +151,4 @@ done:
return result;
}
-static_link_warning (FUNCTION_NAME)
+nss_interface_function (FUNCTION_NAME)
diff --git a/nss/getXXbyYY_r.c b/nss/getXXbyYY_r.c
index f296ed1f42..8b3b61b663 100644
--- a/nss/getXXbyYY_r.c
+++ b/nss/getXXbyYY_r.c
@@ -349,4 +349,4 @@ do_default_symbol_version (NEW (REENTRANT_NAME),
REENTRANT_NAME, GLIBC_2_1_2);
#endif
-static_link_warning (REENTRANT_NAME)
+nss_interface_function (REENTRANT_NAME)
diff --git a/nss/getXXent.c b/nss/getXXent.c
index 008851e597..152798f0c2 100644
--- a/nss/getXXent.c
+++ b/nss/getXXent.c
@@ -91,4 +91,4 @@ GETFUNC_NAME (void)
return result;
}
-static_link_warning (GETFUNC_NAME)
+nss_interface_function (GETFUNC_NAME)
diff --git a/nss/getXXent_r.c b/nss/getXXent_r.c
index f1036058ff..6c52d27cb2 100644
--- a/nss/getXXent_r.c
+++ b/nss/getXXent_r.c
@@ -207,6 +207,6 @@ do_default_symbol_version (NEW (REENTRANT_GETNAME),
REENTRANT_GETNAME, GLIBC_2_1_2);
#endif
-static_link_warning (SETFUNC_NAME)
-static_link_warning (ENDFUNC_NAME)
-static_link_warning (REENTRANT_GETNAME)
+nss_interface_function (SETFUNC_NAME)
+nss_interface_function (ENDFUNC_NAME)
+nss_interface_function (REENTRANT_GETNAME)
diff --git a/nss/nsswitch.h b/nss/nsswitch.h
index 047a9e5858..0cf67ff025 100644
--- a/nss/nsswitch.h
+++ b/nss/nsswitch.h
@@ -107,6 +107,14 @@ enum
/* Flags whether custom rules for database is set. */
extern bool __nss_database_custom[NSS_DBSIDX_max];
+/* Warning for NSS functions, which don't require dlopen if glibc
+ was built with --enable-static-nss. */
+#ifdef DO_STATIC_NSS
+# define nss_interface_function(name)
+#else
+# define nss_interface_function(name) static_link_warning (name)
+#endif
+
/* Interface functions for NSS. */