From 0197c1bc604e1d6357cfa07a75ab73bababa7f0f Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Wed, 5 May 2021 17:15:57 +0200 Subject: nptl: Move pthread_testcancel into libc The symbol was moved using scripts/move-symbol-to-libc.py. A temporary __pthread_testcancel@@GLIBC_PRIVATE export is created because it is needed by the semaphore implementation. Reviewed-by: Adhemerval Zanella --- nptl/pthread_testcancel.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'nptl/pthread_testcancel.c') diff --git a/nptl/pthread_testcancel.c b/nptl/pthread_testcancel.c index 8ed2370afa..a9e941ddb7 100644 --- a/nptl/pthread_testcancel.c +++ b/nptl/pthread_testcancel.c @@ -18,12 +18,18 @@ #include #include "pthreadP.h" - +#include void -__pthread_testcancel (void) +___pthread_testcancel (void) { CANCELLATION_P (THREAD_SELF); } -strong_alias (__pthread_testcancel, pthread_testcancel) -hidden_def (__pthread_testcancel) +versioned_symbol (libc, ___pthread_testcancel, pthread_testcancel, GLIBC_2_34); +versioned_symbol (libc, ___pthread_testcancel, __pthread_testcancel, + GLIBC_PRIVATE); +libc_hidden_ver (___pthread_testcancel, __pthread_testcancel) + +#if OTHER_SHLIB_COMPAT (libpthread, GLIBC_2_0, GLIBC_2_34) +compat_symbol (libc, ___pthread_testcancel, pthread_testcancel, GLIBC_2_0); +#endif -- cgit 1.4.1