diff options
author | Florian Weimer <fweimer@redhat.com> | 2021-05-05 17:15:57 +0200 |
---|---|---|
committer | Florian Weimer <fweimer@redhat.com> | 2021-05-05 17:19:45 +0200 |
commit | 1ae60ae74ff43cf7a28bace42d91cb6281bd50fc (patch) | |
tree | fd54e1e6d4119363c2e6fc263524c3c2b5e49791 /nptl | |
parent | 61878689c228cdf324d609b98db3314d8a81f24d (diff) | |
download | glibc-1ae60ae74ff43cf7a28bace42d91cb6281bd50fc.tar.gz glibc-1ae60ae74ff43cf7a28bace42d91cb6281bd50fc.tar.xz glibc-1ae60ae74ff43cf7a28bace42d91cb6281bd50fc.zip |
nptl: Move sem_init into libc
The symbol was moved using scripts/move-symbol-to-libc.py. Reviewed-by: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Diffstat (limited to 'nptl')
-rw-r--r-- | nptl/Makefile | 2 | ||||
-rw-r--r-- | nptl/Versions | 5 | ||||
-rw-r--r-- | nptl/sem_init.c | 8 |
3 files changed, 9 insertions, 6 deletions
diff --git a/nptl/Makefile b/nptl/Makefile index 8c32937d82..d0410f6827 100644 --- a/nptl/Makefile +++ b/nptl/Makefile @@ -154,6 +154,7 @@ routines = \ sem_close \ sem_destroy \ sem_getvalue \ + sem_init \ sem_open \ sem_routines \ tpp \ @@ -207,7 +208,6 @@ libpthread-routines = \ pthread_sigqueue \ pthread_timedjoin \ pthread_tryjoin \ - sem_init \ sem_post \ sem_timedwait \ sem_unlink \ diff --git a/nptl/Versions b/nptl/Versions index dd1c1c7e9e..428cb43c9d 100644 --- a/nptl/Versions +++ b/nptl/Versions @@ -64,6 +64,7 @@ libc { pthread_testcancel; sem_destroy; sem_getvalue; + sem_init; } GLIBC_2.1 { pthread_attr_init; @@ -84,6 +85,7 @@ libc { pthread_rwlockattr_setpshared; sem_destroy; sem_getvalue; + sem_init; } GLIBC_2.1.1 { sem_close; @@ -260,6 +262,7 @@ libc { sem_close; sem_destroy; sem_getvalue; + sem_init; sem_open; thrd_exit; tss_create; @@ -326,7 +329,6 @@ libpthread { pthread_detach; pthread_join; pthread_sigmask; - sem_init; sem_post; sem_trywait; sem_wait; @@ -342,7 +344,6 @@ libpthread { pthread_create; pthread_getconcurrency; pthread_setconcurrency; - sem_init; sem_post; sem_trywait; sem_wait; diff --git a/nptl/sem_init.c b/nptl/sem_init.c index ea2ff7b85c..39fe76b92b 100644 --- a/nptl/sem_init.c +++ b/nptl/sem_init.c @@ -61,11 +61,13 @@ __new_sem_init (sem_t *sem, int pshared, unsigned int value) return 0; } -versioned_symbol (libpthread, __new_sem_init, sem_init, GLIBC_2_1); - +versioned_symbol (libc, __new_sem_init, sem_init, GLIBC_2_34); +#if OTHER_SHLIB_COMPAT(libpthread, GLIBC_2_1, GLIBC_2_34) +compat_symbol (libpthread, __new_sem_init, sem_init, GLIBC_2_1); +#endif -#if SHLIB_COMPAT(libpthread, GLIBC_2_0, GLIBC_2_1) +#if OTHER_SHLIB_COMPAT(libpthread, GLIBC_2_0, GLIBC_2_1) int attribute_compat_text_section __old_sem_init (sem_t *sem, int pshared, unsigned int value) |