From dbfa12e201529d7006477d192a6f340e696744a1 Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Mon, 3 May 2021 09:10:57 +0200 Subject: nptl: Move pthread_rwlockattr_init into libc The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Carlos O'Donell Tested-by: Carlos O'Donell --- nptl/Makefile | 2 +- nptl/Versions | 3 ++- nptl/pthread_rwlockattr_init.c | 11 +++++++++-- 3 files changed, 12 insertions(+), 4 deletions(-) (limited to 'nptl') diff --git a/nptl/Makefile b/nptl/Makefile index 7724bed844..d6920dfb25 100644 --- a/nptl/Makefile +++ b/nptl/Makefile @@ -134,6 +134,7 @@ routines = \ pthread_rwlockattr_destroy \ pthread_rwlockattr_getkind_np \ pthread_rwlockattr_getpshared \ + pthread_rwlockattr_init \ pthread_self \ pthread_setcancelstate \ pthread_setcanceltype \ @@ -189,7 +190,6 @@ libpthread-routines = \ pthread_getname \ pthread_join \ pthread_join_common \ - pthread_rwlockattr_init \ pthread_rwlockattr_setkind_np \ pthread_rwlockattr_setpshared \ pthread_setaffinity \ diff --git a/nptl/Versions b/nptl/Versions index 1ca7c7782e..bc0a9c826a 100644 --- a/nptl/Versions +++ b/nptl/Versions @@ -76,6 +76,7 @@ libc { pthread_rwlockattr_destroy; pthread_rwlockattr_getkind_np; pthread_rwlockattr_getpshared; + pthread_rwlockattr_init; } GLIBC_2.2 { __pthread_rwlock_destroy; @@ -232,6 +233,7 @@ libc { pthread_rwlockattr_destroy; pthread_rwlockattr_getkind_np; pthread_rwlockattr_getpshared; + pthread_rwlockattr_init; pthread_setspecific; pthread_spin_destroy; pthread_spin_init; @@ -318,7 +320,6 @@ libpthread { pthread_attr_setstacksize; pthread_create; pthread_getconcurrency; - pthread_rwlockattr_init; pthread_rwlockattr_setkind_np; pthread_rwlockattr_setpshared; pthread_setconcurrency; diff --git a/nptl/pthread_rwlockattr_init.c b/nptl/pthread_rwlockattr_init.c index 0df2ddbcd2..3949a0698d 100644 --- a/nptl/pthread_rwlockattr_init.c +++ b/nptl/pthread_rwlockattr_init.c @@ -17,10 +17,10 @@ . */ #include "pthreadP.h" - +#include int -pthread_rwlockattr_init (pthread_rwlockattr_t *attr) +__pthread_rwlockattr_init (pthread_rwlockattr_t *attr) { ASSERT_TYPE_SIZE (pthread_rwlockattr_t, __SIZEOF_PTHREAD_RWLOCKATTR_T); ASSERT_PTHREAD_INTERNAL_SIZE (pthread_rwlockattr_t, @@ -35,3 +35,10 @@ pthread_rwlockattr_init (pthread_rwlockattr_t *attr) return 0; } +versioned_symbol (libc, __pthread_rwlockattr_init, + pthread_rwlockattr_init, GLIBC_2_34); + +#if OTHER_SHLIB_COMPAT (libpthread, GLIBC_2_1, GLIBC_2_34) +compat_symbol (libpthread, __pthread_rwlockattr_init, + pthread_rwlockattr_init, GLIBC_2_1); +#endif -- cgit v1.2.3