diff --git a/src/include/Makefile b/src/include/Makefile index ba1164c3..e4e87ae8 100644 --- a/src/include/Makefile +++ b/src/include/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.70 1999/07/01 21:41:32 deraadt Exp $ +# $OpenBSD: Makefile,v 1.71 1999/09/24 22:33:10 espie Exp $ # $NetBSD: Makefile,v 1.59 1996/05/15 21:36:43 jtc Exp $ # @(#)Makefile 5.45.1.1 (Berkeley) 5/6/91 @@ -15,7 +15,7 @@ FILES= a.out.h ar.h assert.h bitstring.h blf.h bm.h cast.h cpio.h ctype.h \ memory.h mpool.h ndbm.h netdb.h netgroup.h nlist.h nl_types.h \ olf_abi.h paths.h poll.h pwd.h ranlib.h re_comp.h regex.h resolv.h \ rmd160.h search.h setjmp.h sgtty.h sha1.h skipjack.h signal.h stab.h \ - stddef.h stdio.h stdlib.h string.h strings.h struct.h sysexits.h \ + stdbool.h stddef.h stdio.h stdlib.h string.h strings.h struct.h sysexits.h \ tar.h time.h ttyent.h tzfile.h unistd.h utime.h utmp.h vis.h .if (${MACHINE_ARCH} != "alpha") && (${MACHINE_ARCH} != "mips") && \ diff --git a/src/include/stdbool.h b/src/include/stdbool.h new file mode 100644 index 00000000..f2cd0a27 --- /dev/null +++ b/src/include/stdbool.h @@ -0,0 +1,21 @@ +/* $OpenBSD: stdbool.h,v 1.1 1999/09/24 22:33:10 espie Exp $ */ +#ifndef _STDBOOL_H_ +#define _STDBOOL_H_ + +/* `_Bool' type must promote to `int' or `unsigned int'. */ +typedef enum { + false = 0, + true = 1 +} _Bool; + +/* And those constants must also be available as macros. */ +#define false false +#define true true + +/* User visible type `bool' is provided as a macro which may be redefined */ +#define bool _Bool + +/* Inform that everything is fine */ +#define __bool_true_false_are_defined 1 + +#endif /* _STDBOOL_H_ */