diff --git a/libc3/types.h b/libc3/types.h
index 5363cdd..541d3d6 100644
--- a/libc3/types.h
+++ b/libc3/types.h
@@ -23,6 +23,10 @@
#include "sha1.h"
#include "../libtommath/tommath.h"
+#ifdef bool
+# undef bool
+#endif
+
/* Basic integer types. */
typedef char s8;
typedef int16_t s16;