aboutsummaryrefslogtreecommitdiff
path: root/nptl/sem_clockwait.c
diff options
context:
space:
mode:
authorFlorian Weimer <fweimer@redhat.com>2021-05-05 17:15:57 +0200
committerFlorian Weimer <fweimer@redhat.com>2021-05-05 17:19:35 +0200
commit19cc20ef2e8b9e09429741a3108e55c50758a273 (patch)
treeb59c159eb256c08c4546a2c8d095f590ed31d1fd /nptl/sem_clockwait.c
parentce0b7961ae400e5aeff28d54dc14955199947b74 (diff)
downloadglibc-19cc20ef2e8b9e09429741a3108e55c50758a273.tar
glibc-19cc20ef2e8b9e09429741a3108e55c50758a273.tar.gz
glibc-19cc20ef2e8b9e09429741a3108e55c50758a273.tar.bz2
glibc-19cc20ef2e8b9e09429741a3108e55c50758a273.zip
nptl: Move sem_clockwait into libc
The symbol was moved using scripts/move-symbol-to-libc.py. A new placeholder version is added at version GLIBC_2.30, to preserve that version in libpthread.so.0. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Diffstat (limited to 'nptl/sem_clockwait.c')
-rw-r--r--nptl/sem_clockwait.c15
1 files changed, 10 insertions, 5 deletions
diff --git a/nptl/sem_clockwait.c b/nptl/sem_clockwait.c
index 3202b60564..2739799e26 100644
--- a/nptl/sem_clockwait.c
+++ b/nptl/sem_clockwait.c
@@ -23,7 +23,7 @@
#include "sem_waitcommon.c"
int
-__sem_clockwait64 (sem_t *sem, clockid_t clockid,
+___sem_clockwait64 (sem_t *sem, clockid_t clockid,
const struct __timespec64 *abstime)
{
/* Check that supplied clockid is one we support, even if we don't end up
@@ -46,15 +46,20 @@ __sem_clockwait64 (sem_t *sem, clockid_t clockid,
return __new_sem_wait_slow64 ((struct new_sem *) sem, clockid, abstime);
}
-#if __TIMESIZE != 64
-libpthread_hidden_def (__sem_clockwait64)
+#if __TIMESIZE == 64
+strong_alias (___sem_clockwait64, ___sem_clockwait)
+#else /* __TIMESPEC64 != 64 */
+libc_hidden_ver (___sem_clockwait64, __sem_clockwait64)
int
-__sem_clockwait (sem_t *sem, clockid_t clockid, const struct timespec *abstime)
+___sem_clockwait (sem_t *sem, clockid_t clockid, const struct timespec *abstime)
{
struct __timespec64 ts64 = valid_timespec_to_timespec64 (*abstime);
return __sem_clockwait64 (sem, clockid, &ts64);
}
+#endif /* __TIMESPEC64 != 64 */
+versioned_symbol (libc, ___sem_clockwait, sem_clockwait, GLIBC_2_34);
+#if OTHER_SHLIB_COMPAT (libpthread, GLIBC_2_30, GLIBC_2_34)
+compat_symbol (libpthread, ___sem_clockwait, sem_clockwait, GLIBC_2_30);
#endif
-weak_alias (__sem_clockwait, sem_clockwait)