htl: move pthread_attr_destroy into libc.

Signed-off-by: gfleury <gfleury@disroot.org>
This commit is contained in:
gfleury 2024-11-18 13:21:33 +02:00 committed by Samuel Thibault
parent ce13ab5033
commit 736befab6c
9 changed files with 9 additions and 10 deletions

View File

@ -26,7 +26,6 @@ LCLHDRS :=
libpthread-routines := \
pt-attr \
pt-attr-destroy \
pt-attr-getguardsize \
pt-attr-getscope \
pt-attr-getstack \
@ -199,6 +198,7 @@ routines := \
forward \
htlfreeres \
libc_pthread_init \
pt-attr-destroy \
pt-attr-getdetachstate \
pt-attr-getinheritsched \
pt-attr-getschedparam \

View File

@ -13,6 +13,7 @@ libc {
pthread_equal;
pthread_getschedparam;
pthread_setschedparam;
pthread_attr_destroy;
}
GLIBC_2.21 {
@ -77,7 +78,6 @@ libpthread {
pthread_atfork;
pthread_attr_destroy;
pthread_attr_getguardsize;
pthread_attr_getscope; pthread_attr_getstack; pthread_attr_getstackaddr;
pthread_attr_getstacksize; pthread_attr_init;

View File

@ -53,8 +53,6 @@ name decl \
#define FORWARD(name, decl, params, defretval) \
FORWARD2 (name, int, decl, params, return defretval)
FORWARD (pthread_attr_destroy, (pthread_attr_t *attr), (attr), 0)
FORWARD (pthread_attr_init, (pthread_attr_t *attr), (attr), 0)
FORWARD (pthread_attr_setschedparam,

View File

@ -27,7 +27,6 @@
#if IS_IN (libpthread)
static const struct pthread_functions pthread_functions = {
.ptr_pthread_attr_destroy = __pthread_attr_destroy,
.ptr_pthread_attr_init = __pthread_attr_init,
.ptr_pthread_attr_setschedparam = __pthread_attr_setschedparam,
.ptr_pthread_attr_getscope = __pthread_attr_getscope,

View File

@ -17,6 +17,7 @@
<https://www.gnu.org/licenses/>. */
#include <pthread.h>
#include <shlib-compat.h>
#include <pt-internal.h>
int
@ -24,4 +25,8 @@ __pthread_attr_destroy (pthread_attr_t *attr)
{
return 0;
}
weak_alias (__pthread_attr_destroy, pthread_attr_destroy);
versioned_symbol (libc, __pthread_attr_destroy, pthread_attr_destroy, GLIBC_2_21);
#if OTHER_SHLIB_COMPAT (libpthread, GLIBC_2_12, GLIBC_2_21)
compat_symbol (libc, __pthread_attr_destroy, pthread_attr_destroy, GLIBC_2_12);
#endif

View File

@ -21,7 +21,6 @@
#include <pthread.h>
int __pthread_attr_destroy (pthread_attr_t *);
int __pthread_attr_init (pthread_attr_t *);
int __pthread_attr_setschedparam (pthread_attr_t *,
const struct sched_param *);
@ -64,7 +63,6 @@ int _cthreads_ftrylockfile (FILE *);
so if possible avoid breaking it and append new hooks to the end. */
struct pthread_functions
{
int (*ptr_pthread_attr_destroy) (pthread_attr_t *);
int (*ptr_pthread_attr_init) (pthread_attr_t *);
int (*ptr_pthread_attr_setschedparam) (pthread_attr_t *,
const struct sched_param *);

View File

@ -29,6 +29,7 @@ GLIBC_2.11 mkostemps64 F
GLIBC_2.11 mkstemps F
GLIBC_2.11 mkstemps64 F
GLIBC_2.12 __pthread_self F
GLIBC_2.12 pthread_attr_destroy F
GLIBC_2.12 pthread_attr_getdetachstate F
GLIBC_2.12 pthread_attr_getinheritsched F
GLIBC_2.12 pthread_attr_getschedparam F

View File

@ -22,7 +22,6 @@ GLIBC_2.12 flockfile F
GLIBC_2.12 ftrylockfile F
GLIBC_2.12 funlockfile F
GLIBC_2.12 pthread_atfork F
GLIBC_2.12 pthread_attr_destroy F
GLIBC_2.12 pthread_attr_getguardsize F
GLIBC_2.12 pthread_attr_getscope F
GLIBC_2.12 pthread_attr_getstack F

View File

@ -39,7 +39,6 @@ GLIBC_2.38 mtx_lock F
GLIBC_2.38 mtx_timedlock F
GLIBC_2.38 mtx_trylock F
GLIBC_2.38 mtx_unlock F
GLIBC_2.38 pthread_attr_destroy F
GLIBC_2.38 pthread_attr_getguardsize F
GLIBC_2.38 pthread_attr_getscope F
GLIBC_2.38 pthread_attr_getstack F