aboutsummaryrefslogtreecommitdiff
path: root/linuxthreads/sysdeps
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>1998-11-18 17:02:37 +0000
committerUlrich Drepper <drepper@redhat.com>1998-11-18 17:02:37 +0000
commit97dac76c11e1317222fb09913d695bab51ba7b3c (patch)
tree8fd24c01d5f80e3ad8d97dbe8f261b250f7d7fef /linuxthreads/sysdeps
parentdfd2464b33ddfcd2706191a340d1737548c5ed19 (diff)
downloadglibc-97dac76c11e1317222fb09913d695bab51ba7b3c.tar
glibc-97dac76c11e1317222fb09913d695bab51ba7b3c.tar.gz
glibc-97dac76c11e1317222fb09913d695bab51ba7b3c.tar.bz2
glibc-97dac76c11e1317222fb09913d695bab51ba7b3c.zip
Update.
1998-11-18 Ulrich Drepper <drepper@cygnus.com> * Makefile (CFLAGS-mutex.c): Define as -D__NO_WEAK_PTHREAD_ALIASES. (CFLAGS-specific.c): Likewise. (CFLAGS-pthread.c): Likewise. (CFLAGS-ptfork.c): Likewise. (CFLAGS-cancel.c): Likewise. * sysdeps/pthread/bits/libc-lock.h: Don't mark __pthread_* functions as weak references if __NO_WEAK_PTHREAD_ALIASES is defined. * mutex.c (pthread_mutex_init): Define as strong symbol. (pthread_mutex_destroy): Likewise. (pthread_mutex_trylock): Likewise. (pthread_mutex_lock): Likewise. (pthread_mutex_unlock): Likewise. (pthread_mutexattr_init): Likewise. (pthread_mutexattr_destroy): Likewise. (pthread_once): Likewise. * ptfork.c (pthread_atfork): Likewise. * specific.c (pthread_key_create): Likewise. (pthread_setspecific): Likewise. (pthread_getspecific): Likewise.
Diffstat (limited to 'linuxthreads/sysdeps')
-rw-r--r--linuxthreads/sysdeps/pthread/bits/libc-lock.h42
1 files changed, 22 insertions, 20 deletions
diff --git a/linuxthreads/sysdeps/pthread/bits/libc-lock.h b/linuxthreads/sysdeps/pthread/bits/libc-lock.h
index 820d65aca8..1763a42cda 100644
--- a/linuxthreads/sysdeps/pthread/bits/libc-lock.h
+++ b/linuxthreads/sysdeps/pthread/bits/libc-lock.h
@@ -170,7 +170,8 @@ extern int __libc_internal_tsd_set __P ((enum __libc_tsd_key_t,
/* Make the pthread functions weak so that we can elide them from
single-threaded processes. */
-#ifdef weak_extern
+#ifndef __NO_WEAK_PTHREAD_ALIASES
+# ifdef weak_extern
weak_extern (__pthread_mutex_init)
weak_extern (__pthread_mutex_destroy)
weak_extern (__pthread_mutex_lock)
@@ -189,25 +190,26 @@ weak_extern (__pthread_initialize)
weak_extern (__pthread_atfork)
weak_extern (_pthread_cleanup_push_defer)
weak_extern (_pthread_cleanup_pop_restore)
-#else
-# pragma weak __pthread_mutex_init
-# pragma weak __pthread_mutex_destroy
-# pragma weak __pthread_mutex_lock
-# pragma weak __pthread_mutex_trylock
-# pragma weak __pthread_mutex_unlock
-# pragma weak __pthread_mutexattr_init
-# pragma weak __pthread_mutexattr_destroy
-# pragma weak __pthread_mutexattr_settype
-# pragma weak __pthread_key_create
-# pragma weak __pthread_setspecific
-# pragma weak __pthread_getspecific
-# pragma weak __libc_internal_tsd_get
-# pragma weak __libc_internal_tsd_set
-# pragma weak __pthread_once
-# pragma weak __pthread_initialize
-# pragma weak __pthread_atfork
-# pragma weak _pthread_cleanup_push_defer
-# pragma weak _pthread_cleanup_pop_restore
+# else
+# pragma weak __pthread_mutex_init
+# pragma weak __pthread_mutex_destroy
+# pragma weak __pthread_mutex_lock
+# pragma weak __pthread_mutex_trylock
+# pragma weak __pthread_mutex_unlock
+# pragma weak __pthread_mutexattr_init
+# pragma weak __pthread_mutexattr_destroy
+# pragma weak __pthread_mutexattr_settype
+# pragma weak __pthread_key_create
+# pragma weak __pthread_setspecific
+# pragma weak __pthread_getspecific
+# pragma weak __libc_internal_tsd_get
+# pragma weak __libc_internal_tsd_set
+# pragma weak __pthread_once
+# pragma weak __pthread_initialize
+# pragma weak __pthread_atfork
+# pragma weak _pthread_cleanup_push_defer
+# pragma weak _pthread_cleanup_pop_restore
+# endif
#endif
/* We need portable names for some functions. E.g., when they are