Index: configure.in =================================================================== RCS file: /home/freeciv/CVS/freeciv/configure.in,v retrieving revision 1.205 diff -u -r1.205 configure.in --- configure.in 2002/11/30 20:42:01 1.205 +++ configure.in 2002/12/02 18:25:52 @@ -547,7 +547,8 @@ dnl Checks for header files. AC_HEADER_STDC -AC_CHECK_HEADERS(fcntl.h sys/time.h sys/types.h unistd.h sys/utsname.h) +AC_CHECK_HEADERS(fcntl.h sys/time.h sys/types.h unistd.h sys/utsname.h \ + stdbool.h) dnl Avoid including the unix emulation layer if we build mingw executables dnl There would be type conflicts between winsock and bsd/unix includes if test "x$MINGW32" != "xyes"; then Index: common/shared.h =================================================================== RCS file: /home/freeciv/CVS/freeciv/common/shared.h,v retrieving revision 1.106 diff -u -r1.106 shared.h --- common/shared.h 2002/11/21 13:35:31 1.106 +++ common/shared.h 2002/12/02 18:25:54 @@ -15,6 +15,24 @@ #include /* size_t */ +#if __BEOS__ +#include +#define __bool_true_false_are_defined 1 +#else +#ifdef HAVE_STDBOOL_H +#include +#else /* Implement ourselves */ +#undef bool +#undef true +#undef false +#undef __bool_true_false_are_defined +#define bool fc_bool +#define true 1 +#define false 0 +#define __bool_true_false_are_defined 1 +typedef unsigned int fc_bool; +#endif /* ! HAVE_STDBOOL_H */ +#endif /* ! __BEOS__ */ /* Want to use GCC's __attribute__ keyword to check variadic * parameters to printf-like functions, without upsetting other @@ -47,14 +64,16 @@ another unreachable condition. */ #define FC_INFINITY (1000 * 1000 * 1000) -#ifndef TRUE -#define TRUE (1) +#ifdef TRUE +#undef TRUE #endif -#ifndef FALSE -#define FALSE (0) + +#ifdef FALSE +#undef FALSE #endif -typedef int bool; +#define TRUE true +#define FALSE false #ifndef MAX #define MAX(x,y) (((x)>(y))?(x):(y))