public inbox for libc-hacker@sourceware.org
 help / color / mirror / Atom feed
* bits/libc-lock.h and _LIBC
@ 2002-10-22  6:51 Thorsten Kukuk
  2002-11-04  1:29 ` Ulrich Drepper
  2002-11-08  9:57 ` Roland McGrath
  0 siblings, 2 replies; 5+ messages in thread
From: Thorsten Kukuk @ 2002-10-22  6:51 UTC (permalink / raw)
  To: libc-hacker; +Cc: drepper


Hi,

We install libc-lock.h into /usr/include/bits. But libc-lock.h is
only useable, if it is compiled with -D_LIBC, which breaks now with
libio.h.

I suggest the following patch, or is there any reason for the
ifdef _LIBC around __libc_lock_t ? We don't do this for __libc_key_t
and all the other definitions.

2002-10-17  Thorsten Kukuk  <kukuk@suse.de>

	* sysdeps/pthread/bits/libc-lock.h: Don't protect __libc_lock_t
	with _LIBC.

diff -u -r1.23 libc-lock.h
--- ./linuxthreads/sysdeps/pthread/bits/libc-lock.h
+++ ./linuxthreads/sysdeps/pthread/bits/libc-lock.h
@@ -24,19 +24,9 @@
 #include <pthread.h>
 
 /* Mutex type.  */
-#if defined(_LIBC) || defined(_IO_MTSAFE_IO)
 typedef pthread_mutex_t __libc_lock_t;
 typedef struct { pthread_mutex_t mutex; } __libc_lock_recursive_t;
-# ifdef __USE_UNIX98
 typedef pthread_rwlock_t __libc_rwlock_t;
-# else
-typedef struct __libc_rwlock_opaque__ __libc_rwlock_t;
-# endif
-#else
-typedef struct __libc_lock_opaque__ __libc_lock_t;
-typedef struct __libc_lock_recursive_opaque__ __libc_lock_recursive_t;
-typedef struct __libc_rwlock_opaque__ __libc_rwlock_t;
-#endif
 
 /* Type for key to thread-specific data.  */
 typedef pthread_key_t __libc_key_t;


-- 
Thorsten Kukuk       http://www.suse.de/~kukuk/        kukuk@suse.de
SuSE Linux AG        Deutschherrnstr. 15-19        D-90429 Nuernberg
--------------------------------------------------------------------    
Key fingerprint = A368 676B 5E1B 3E46 CFCE  2D97 F8FD 4E23 56C6 FB4B

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2002-11-08 17:57 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-10-22  6:51 bits/libc-lock.h and _LIBC Thorsten Kukuk
2002-11-04  1:29 ` Ulrich Drepper
2002-11-04  1:32   ` Thorsten Kukuk
2002-11-04  1:46     ` Ulrich Drepper
2002-11-08  9:57 ` Roland McGrath

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).