about summary refs log tree commit diff
path: root/nptl
diff options
context:
space:
mode:
authorFlorian Weimer <fweimer@redhat.com>2021-04-23 09:48:09 +0200
committerFlorian Weimer <fweimer@redhat.com>2021-04-23 09:51:57 +0200
commit8a229ee93c17cf5d0aff9ba81a3acfa146f1dae0 (patch)
treedfbbd845ec25b62352f05927dc1980b9958c05e1 /nptl
parent241ac38c333ae2539182f214dc641d0956f6ff6d (diff)
downloadglibc-8a229ee93c17cf5d0aff9ba81a3acfa146f1dae0.tar.gz
glibc-8a229ee93c17cf5d0aff9ba81a3acfa146f1dae0.tar.xz
glibc-8a229ee93c17cf5d0aff9ba81a3acfa146f1dae0.zip
nptl: Move pthread_mutexattr_setpshared into libc
The symbol was moved using scripts/move-symbol-to-libc.py.
Diffstat (limited to 'nptl')
-rw-r--r--nptl/Makefile2
-rw-r--r--nptl/Versions3
-rw-r--r--nptl/pthread_mutexattr_setpshared.c11
3 files changed, 12 insertions, 4 deletions
diff --git a/nptl/Makefile b/nptl/Makefile
index 96a01e1c0d..1565beb84f 100644
--- a/nptl/Makefile
+++ b/nptl/Makefile
@@ -112,6 +112,7 @@ routines = \
   pthread_mutexattr_init \
   pthread_mutexattr_setprioceiling \
   pthread_mutexattr_setprotocol \
+  pthread_mutexattr_setpshared \
   pthread_once \
   pthread_rwlock_rdlock \
   pthread_rwlock_unlock \
@@ -171,7 +172,6 @@ libpthread-routines = \
   pthread_getname \
   pthread_join \
   pthread_join_common \
-  pthread_mutexattr_setpshared \
   pthread_mutexattr_setrobust \
   pthread_mutexattr_settype \
   pthread_rwlock_clockrdlock \
diff --git a/nptl/Versions b/nptl/Versions
index 8dc6d3a4ff..e2909143e7 100644
--- a/nptl/Versions
+++ b/nptl/Versions
@@ -73,6 +73,7 @@ libc {
     __pthread_rwlock_wrlock;
     pthread_mutex_timedlock;
     pthread_mutexattr_getpshared;
+    pthread_mutexattr_setpshared;
   }
   GLIBC_2.2.3 {
     pthread_getattr_np;
@@ -156,6 +157,7 @@ libc {
     pthread_mutexattr_init;
     pthread_mutexattr_setprioceiling;
     pthread_mutexattr_setprotocol;
+    pthread_mutexattr_setpshared;
     pthread_once;
     pthread_rwlock_rdlock;
     pthread_rwlock_unlock;
@@ -295,7 +297,6 @@ libpthread {
     pthread_condattr_getpshared;
     pthread_condattr_setpshared;
     pthread_getcpuclockid;
-    pthread_mutexattr_setpshared;
     pthread_rwlock_timedrdlock;
     pthread_rwlock_timedwrlock;
     pthread_spin_destroy;
diff --git a/nptl/pthread_mutexattr_setpshared.c b/nptl/pthread_mutexattr_setpshared.c
index 8f21594019..f3d52ff9d9 100644
--- a/nptl/pthread_mutexattr_setpshared.c
+++ b/nptl/pthread_mutexattr_setpshared.c
@@ -19,10 +19,10 @@
 #include <errno.h>
 #include <pthreadP.h>
 #include <futex-internal.h>
-
+#include <shlib-compat.h>
 
 int
-pthread_mutexattr_setpshared (pthread_mutexattr_t *attr, int pshared)
+__pthread_mutexattr_setpshared (pthread_mutexattr_t *attr, int pshared)
 {
   struct pthread_mutexattr *iattr;
 
@@ -39,3 +39,10 @@ pthread_mutexattr_setpshared (pthread_mutexattr_t *attr, int pshared)
 
   return 0;
 }
+versioned_symbol (libc, __pthread_mutexattr_setpshared,
+                  pthread_mutexattr_setpshared, GLIBC_2_34);
+
+#if OTHER_SHLIB_COMPAT (libpthread, GLIBC_2_2, GLIBC_2_34)
+compat_symbol (libpthread, __pthread_mutexattr_setpshared,
+               pthread_mutexattr_setpshared, GLIBC_2_2);
+#endif