summaryrefslogtreecommitdiffstats
path: root/src/include
diff options
context:
space:
mode:
authorMichael Brown2017-04-10 17:11:50 +0200
committerMichael Brown2017-04-10 17:12:53 +0200
commitffb5fe4ced74712393e9659c8271292f0698020f (patch)
treee7120bf6b0392cc551c80e3d19f3729bd94b016d /src/include
parent[thunderx] Use ThunderxConfigProtocol to obtain board configuration (diff)
downloadipxe-ffb5fe4ced74712393e9659c8271292f0698020f.tar.gz
ipxe-ffb5fe4ced74712393e9659c8271292f0698020f.tar.xz
ipxe-ffb5fe4ced74712393e9659c8271292f0698020f.zip
[libc] Add stdbool.h standard header
Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/include')
-rw-r--r--src/include/curses.h2
-rw-r--r--src/include/stdbool.h10
2 files changed, 11 insertions, 1 deletions
diff --git a/src/include/curses.h b/src/include/curses.h
index 1f6fe029..cf8cc53c 100644
--- a/src/include/curses.h
+++ b/src/include/curses.h
@@ -2,6 +2,7 @@
#define CURSES_H
#include <stdint.h>
+#include <stdbool.h>
#include <stdarg.h>
#include <ipxe/console.h>
@@ -25,7 +26,6 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
#undef TRUE
#define TRUE (1)
-typedef int bool;
typedef uint32_t chtype;
typedef uint32_t attr_t;
diff --git a/src/include/stdbool.h b/src/include/stdbool.h
new file mode 100644
index 00000000..c49a7f19
--- /dev/null
+++ b/src/include/stdbool.h
@@ -0,0 +1,10 @@
+#ifndef _STDBOOL_H
+#define _STDBOOL_H
+
+FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL );
+
+#define bool _Bool
+#define true 1
+#define false 0
+
+#endif /* _STDBOOL_H */