about summary refs log tree commit diff
path: root/bits/siginfo.h
diff options
context:
space:
mode:
Diffstat (limited to 'bits/siginfo.h')
-rw-r--r--bits/siginfo.h20
1 files changed, 14 insertions, 6 deletions
diff --git a/bits/siginfo.h b/bits/siginfo.h
index 31b0dde888..77a314b13c 100644
--- a/bits/siginfo.h
+++ b/bits/siginfo.h
@@ -1,5 +1,5 @@
 /* siginfo_t, sigevent and constants.  Stub version.
-   Copyright (C) 1997, 1998, 2000 Free Software Foundation, Inc.
+   Copyright (C) 1997, 1998, 2000, 2001 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -17,13 +17,15 @@
    write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
    Boston, MA 02111-1307, USA.  */
 
-#if !defined _SIGNAL_H && !defined __need_siginfo_t
+#if !defined _SIGNAL_H && !defined __need_siginfo_t \
+    && !defined __need_sigevent_t
 # error "Never include this file directly.  Use <signal.h> instead"
 #endif
 
-#if (!defined __have_siginfo_t \
-     && (defined _SIGNAL_H || defined __need_siginfo_t))
-# define __have_siginfo_t	1
+#if (!defined __have_sigval_t \
+     && (defined _SIGNAL_H || defined __need_siginfo_t \
+	 || defined __need_sigevent_t))
+# define __have_sigval_t 1
 
 /* Type for data associated with a signal.  */
 typedef union sigval
@@ -31,6 +33,11 @@ typedef union sigval
     int sival_int;
     void *sival_ptr;
   } sigval_t;
+#endif
+
+#if (!defined __have_siginfo_t \
+     && (defined _SIGNAL_H || defined __need_siginfo_t))
+# define __have_siginfo_t	1
 
 typedef struct siginfo
   {
@@ -173,7 +180,8 @@ enum
 #endif	/* !have siginfo_t && (have _SIGNAL_H || need siginfo_t).  */
 
 
-#if defined _SIGNAL_H && !defined __have_sigevent_t
+#if (defined _SIGNAL_H || defined __need_sigevent_t) \
+    && !defined __have_sigevent_t
 # define __have_sigevent_t	1
 
 /* Structure to transport application-defined values with signals.  */