summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNeal H. Walfield <neal@gnu.org>2005-05-31 17:34:36 +0000
committerNeal H. Walfield <neal@gnu.org>2005-05-31 17:34:36 +0000
commit8e18e678afebb38e4208680ae7d7d23172116b41 (patch)
tree3b5ea998ed04e4bd7203da7995f08ebe6f923e29
parentad327ba4bdcccdfaccde64ba4852220ec99d7b79 (diff)
libpthread/
2005-05-31 Neal H. Walfield <neal@gnu.org> * include/pthread/pthread.h: If clockid_t is still not defined after including <time.h>, define it manually.
-rw-r--r--ChangeLog5
-rw-r--r--include/pthread/pthread.h10
2 files changed, 15 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 3de3f47..98fcfc9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2005-05-31 Neal H. Walfield <neal@gnu.org>
+
+ * include/pthread/pthread.h: If clockid_t is still not defined
+ after including <time.h>, define it manually.
+
2005-05-17 Neal H. Walfield <neal@gnu.org>
* include/pthread/pthread.h: Define __need_clockid_t before
diff --git a/include/pthread/pthread.h b/include/pthread/pthread.h
index 23a5ff4..891ed32 100644
--- a/include/pthread/pthread.h
+++ b/include/pthread/pthread.h
@@ -29,6 +29,16 @@
#define __need_clockid_t
#include <time.h>
+/* If we are in a mode where clockid_t is not automatically defined
+ and another header has already included <time.h> then defining
+ __need_clockid_t was not enough. */
+#ifndef __clockid_t_defined
+# define __clockid_t_defined 1
+# include <bits/types.h>
+/* Clock ID used in clock and timer functions. */
+typedef __clockid_t clockid_t;
+#endif
+
__BEGIN_DECLS
#include <bits/pthread.h>