aboutsummaryrefslogtreecommitdiff
path: root/nptl/pthread_mutexattr_init.c
diff options
context:
space:
mode:
authorFlorian Weimer <fweimer@redhat.com>2021-04-23 09:46:57 +0200
committerFlorian Weimer <fweimer@redhat.com>2021-04-23 09:51:56 +0200
commit506385d30ec67279b21929f117b292bbbe8f5e7b (patch)
tree603077d778d62228809989072ae011869b5e9dd4 /nptl/pthread_mutexattr_init.c
parent2a23e899e255f9ce2b4024d4ec029ce57af518bd (diff)
downloadglibc-506385d30ec67279b21929f117b292bbbe8f5e7b.zip
glibc-506385d30ec67279b21929f117b292bbbe8f5e7b.tar.gz
glibc-506385d30ec67279b21929f117b292bbbe8f5e7b.tar.bz2
nptl: Move pthread_mutexattr_init, __pthread_mutexattr_init into libc
__pthread_mutexattr_init cannot be be made a compat symbol because it is used in mtx_init, which is still in libpthread. The symbols were moved using scripts/move-symbol-to-libc.py.
Diffstat (limited to 'nptl/pthread_mutexattr_init.c')
-rw-r--r--nptl/pthread_mutexattr_init.c17
1 files changed, 13 insertions, 4 deletions
diff --git a/nptl/pthread_mutexattr_init.c b/nptl/pthread_mutexattr_init.c
index 945d434..ca0c5e9 100644
--- a/nptl/pthread_mutexattr_init.c
+++ b/nptl/pthread_mutexattr_init.c
@@ -18,10 +18,10 @@
#include <string.h>
#include <pthreadP.h>
-
+#include <shlib-compat.h>
int
-__pthread_mutexattr_init (pthread_mutexattr_t *attr)
+___pthread_mutexattr_init (pthread_mutexattr_t *attr)
{
ASSERT_TYPE_SIZE (pthread_mutexattr_t, __SIZEOF_PTHREAD_MUTEXATTR_T);
ASSERT_PTHREAD_INTERNAL_SIZE (pthread_mutexattr_t,
@@ -37,5 +37,14 @@ __pthread_mutexattr_init (pthread_mutexattr_t *attr)
return 0;
}
-weak_alias (__pthread_mutexattr_init, pthread_mutexattr_init)
-hidden_def (__pthread_mutexattr_init)
+versioned_symbol (libc, ___pthread_mutexattr_init,
+ pthread_mutexattr_init, GLIBC_2_34);
+versioned_symbol (libc, ___pthread_mutexattr_init,
+ __pthread_mutexattr_init, GLIBC_2_34);
+
+#if OTHER_SHLIB_COMPAT (libpthread, GLIBC_2_0, GLIBC_2_34)
+compat_symbol (libpthread, ___pthread_mutexattr_init,
+ pthread_mutexattr_init, GLIBC_2_0);
+compat_symbol (libpthread, ___pthread_mutexattr_init,
+ __pthread_mutexattr_init, GLIBC_2_0);
+#endif