[PATCH] libc-lock.h BP breakage
Jakub Jelinek
jakub@redhat.com
Mon Jul 3 01:14:00 GMT 2000
Hi!
libc-lock.h is public header, used by e.g. libstdc++. As such, it cannot use
a non-public header (bp-sym.h). I'm not sure what's the correct fix though,
this patch should make things working at least in the !__BOUNDED_POINTERS__
case. Other solutions might include distributing bp-sym.h (but in that case
I'd think it would be better not to polute namespace with BP_SYM).
2000-07-03 Jakub Jelinek <jakub@redhat.com>
* sysdeps/pthread/bits/libc-lock.h: Only include bp-sym.h if in
glibc, otherwise define BP_SYM(sym) to sym.
--- libc/linuxthreads/sysdeps/pthread/bits/libc-lock.h.jj Thu Jun 29 23:24:11 2000
+++ libc/linuxthreads/sysdeps/pthread/bits/libc-lock.h Mon Jul 3 09:58:46 2000
@@ -246,7 +246,11 @@ extern int __pthread_atfork (void (*__pr
/* Make the pthread functions weak so that we can elide them from
single-threaded processes. */
#ifndef __NO_WEAK_PTHREAD_ALIASES
-# include <bp-sym.h>
+# ifdef _LIBC
+# include <bp-sym.h>
+# else
+# define BP_SYM(sym) sym
+# endif
# ifdef weak_extern
weak_extern (BP_SYM (__pthread_mutex_init))
weak_extern (BP_SYM (__pthread_mutex_destroy))
Jakub
More information about the Libc-hacker
mailing list