projects
/
tinc
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Replacement for stdbool.h
[tinc]
/
system.h
diff --git
a/system.h
b/system.h
index
c4dd0d1
..
0d7b318
100644
(file)
--- a/
system.h
+++ b/
system.h
@@
-27,7
+27,6
@@
#include <stdio.h>
#include <stdlib.h>
#include <stdio.h>
#include <stdlib.h>
-#include <stdbool.h>
#include <stdarg.h>
#include <string.h>
#include <ctype.h>
#include <stdarg.h>
#include <string.h>
#include <ctype.h>
@@
-35,7
+34,18
@@
#include <errno.h>
#include <fcntl.h>
#include <unistd.h>
#include <errno.h>
#include <fcntl.h>
#include <unistd.h>
+
+#ifdef HAVE_STDBOOL_H
+#include <stdbool.h>
+#else
+typedef int bool;
+#define true 1
+#define false 0
+#endif
+
+#ifdef HAVE_TERMIOS_H
#include <termios.h>
#include <termios.h>
+#endif
#ifdef HAVE_INTTYPES_H
#include <inttypes.h>
#ifdef HAVE_INTTYPES_H
#include <inttypes.h>
@@
-72,7
+82,7
@@
#endif
#ifdef HAVE_SYS_PARAM_H
#endif
#ifdef HAVE_SYS_PARAM_H
-#include <sys/
ioctl
.h>
+#include <sys/
param
.h>
#endif
/* SunOS really wants sys/socket.h BEFORE net/if.h,
#endif
/* SunOS really wants sys/socket.h BEFORE net/if.h,
@@
-112,7
+122,7
@@
#ifdef HAVE_MINGW
#include <windows.h>
#ifdef HAVE_MINGW
#include <windows.h>
-#include <winsock.h>
+#include <winsock
2
.h>
#endif
/* Include localisation support */
#endif
/* Include localisation support */