STL and pthread
H.J. Lu
hjl@lucon.org
Sun Feb 1 17:12:00 GMT 1998
Hi,
The g++ STL may include <pthread.h>, which may use many non ANSI C++
stuff, like sigset_t. But the g++ test suite uses -ansi -pedantic-errors
in g++.brendan, g++.jason and g++.pt. It causes problems on glibc 2
since sigset_t won't be defined if -ansi is used.
I don't know what the correct way to fix it is. I tend to think
<pthread.h> in glibc 2 should check if the proper maros are defined
before using them.
Ulrich, it applies to both glibc 2.0 and glibc 2.1.
Thanks.
--
H.J. Lu (hjl@gnu.org)
---
--- /tmp/pthread.h Sun Feb 1 17:09:19 1998
+++ ./pthread.h Sun Feb 1 17:10:03 1998
@@ -442,8 +442,10 @@
/* Modify the signal mask for the calling thread. The arguments have
the same meaning as for sigprocmask(2). */
+#if __sigset_t_defined
extern int pthread_sigmask __P ((int __how, __const sigset_t *__newmask,
sigset_t *__oldmask));
+#endif
/* Send signal SIGNO to the given thread. */
More information about the Gcc
mailing list