diff options
author | Florian Weimer <fweimer@redhat.com> | 2021-04-23 09:49:00 +0200 |
---|---|---|
committer | Florian Weimer <fweimer@redhat.com> | 2021-04-23 09:51:57 +0200 |
commit | b76c066d092d78124deeba9b687f5b10924e97de (patch) | |
tree | f08d660e36637680cf8fd9bdada0263c94e54185 /nptl/pthread_mutexattr_settype.c | |
parent | 1ec4cd5ab42d6b16a81176b7051384a2221159e3 (diff) | |
download | glibc-b76c066d092d78124deeba9b687f5b10924e97de.tar glibc-b76c066d092d78124deeba9b687f5b10924e97de.tar.gz glibc-b76c066d092d78124deeba9b687f5b10924e97de.tar.bz2 glibc-b76c066d092d78124deeba9b687f5b10924e97de.zip |
nptl: Move pthread_mutexattr_settype, __pthread_mutexattr_settype into libc
And pthread_mutexattr_setkind_np as a compatibility symbol.
__pthread_mutexattr_settype is used in mtx_init from libpthread,
so this commit adds a GLIBC_2.34 symbol version for it.
The symbols were moved using scripts/move-symbol-to-libc.py.
Diffstat (limited to 'nptl/pthread_mutexattr_settype.c')
-rw-r--r-- | nptl/pthread_mutexattr_settype.c | 23 |
1 files changed, 18 insertions, 5 deletions
diff --git a/nptl/pthread_mutexattr_settype.c b/nptl/pthread_mutexattr_settype.c index a275dec9d5..df03def8bd 100644 --- a/nptl/pthread_mutexattr_settype.c +++ b/nptl/pthread_mutexattr_settype.c @@ -18,10 +18,10 @@ #include <errno.h> #include <pthreadP.h> - +#include <shlib-compat.h> int -__pthread_mutexattr_settype (pthread_mutexattr_t *attr, int kind) +___pthread_mutexattr_settype (pthread_mutexattr_t *attr, int kind) { struct pthread_mutexattr *iattr; @@ -39,6 +39,19 @@ __pthread_mutexattr_settype (pthread_mutexattr_t *attr, int kind) return 0; } -weak_alias (__pthread_mutexattr_settype, pthread_mutexattr_setkind_np) -weak_alias (__pthread_mutexattr_settype, pthread_mutexattr_settype) -hidden_def (__pthread_mutexattr_settype) +versioned_symbol (libc, ___pthread_mutexattr_settype, + pthread_mutexattr_settype, GLIBC_2_34); +versioned_symbol (libc, ___pthread_mutexattr_settype, + __pthread_mutexattr_settype, GLIBC_2_34); + +#if OTHER_SHLIB_COMPAT (libpthread, GLIBC_2_0, GLIBC_2_34) +compat_symbol (libpthread, ___pthread_mutexattr_settype, + pthread_mutexattr_setkind_np, GLIBC_2_0); +compat_symbol (libpthread, ___pthread_mutexattr_settype, + __pthread_mutexattr_settype, GLIBC_2_0); +#endif + +#if OTHER_SHLIB_COMPAT (libpthread, GLIBC_2_1, GLIBC_2_34) +compat_symbol (libpthread, ___pthread_mutexattr_settype, + pthread_mutexattr_settype, GLIBC_2_1); +#endif |