From f47f1d91af985a9028fb399da21eab460d887a15 Mon Sep 17 00:00:00 2001 From: Florian Weimer Date: Fri, 21 May 2021 22:35:00 +0200 Subject: nptl: Move pthread_create, thrd_create into libc The symbols were moved using scripts/move-symbol-to-libc.py. The libpthread placeholder symbols need some changes because some symbol versions have gone away completely. But __errno_location@@GLIBC_2.0 still exists, so the GLIBC_2.0 version is still there. The internal __pthread_create symbol now points to the correct function, so the sysdeps/nptl/thrd_create.c override is no longer necessary. There was an issue how the hidden alias of pthread_getattr_default_np was defined, so this commit cleans up that aspects and removes the GLIBC_PRIVATE export altogether. Reviewed-by: Adhemerval Zanella --- nptl/libpthread-compat.c | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) (limited to 'nptl/libpthread-compat.c') diff --git a/nptl/libpthread-compat.c b/nptl/libpthread-compat.c index 7e3e7aa..2dcf175 100644 --- a/nptl/libpthread-compat.c +++ b/nptl/libpthread-compat.c @@ -28,14 +28,11 @@ __libpthread_version_placeholder_1 (void) } #endif -/* This is an unused compatibility symbol definition, to prevent ld - from creating a weak version definition for GLIBC_2.1.2. (__vfork - used to be defined at that version, but it is now provided by libc, - and there are no versions left in libpthread for that symbol - version.) If the ABI baseline for glibc is the GLIBC_2.2 symbol - version or later, the placeholder symbol is not needed because - there are plenty of other symbols which populate those later - versions. */ +#if (SHLIB_COMPAT (libpthread, GLIBC_2_1, GLIBC_2_2)) +compat_symbol (libpthread, __libpthread_version_placeholder_1, + __libpthread_version_placeholder, GLIBC_2_1); +#endif + #if (SHLIB_COMPAT (libpthread, GLIBC_2_1_1, GLIBC_2_1_2)) compat_symbol (libpthread, __libpthread_version_placeholder_1, __libpthread_version_placeholder, GLIBC_2_1_1); @@ -45,12 +42,8 @@ compat_symbol (libpthread, __libpthread_version_placeholder_1, __libpthread_version_placeholder, GLIBC_2_1_2); #endif -/* Do not create the placeholder symbol version if there are other - symbols left that keep the version around (because GLIBC_2.0 got - promoted to GLIBC_2.2). */ #if SHLIB_COMPAT (libpthread, GLIBC_2_2, GLIBC_2_2_3) \ - && ABI_libpthread_GLIBC_2_2 != ABI_libpthread_GLIBC_2_0 \ - && ABI_libpthread_GLIBC_2_2 != ABI_libpthread_GLIBC_2_1_3 + && ABI_libpthread_GLIBC_2_2 != ABI_libpthread_GLIBC_2_0 compat_symbol (libpthread, __libpthread_version_placeholder_1, __libpthread_version_placeholder, GLIBC_2_2); #endif @@ -101,6 +94,11 @@ compat_symbol (libpthread, __libpthread_version_placeholder_1, __libpthread_version_placeholder, GLIBC_2_18); #endif +#if (SHLIB_COMPAT (libpthread, GLIBC_2_28, GLIBC_2_29)) +compat_symbol (libpthread, __libpthread_version_placeholder_1, + __libpthread_version_placeholder, GLIBC_2_28); +#endif + #if (SHLIB_COMPAT (libpthread, GLIBC_2_30, GLIBC_2_31)) compat_symbol (libpthread, __libpthread_version_placeholder_1, __libpthread_version_placeholder, GLIBC_2_30); -- cgit v1.1