Some distributions'* X headers seem to cause conflicts that our current
checks weren't catching. It sucks that we have this conflicting type
name and that they are of different types in the first place, but what
are you gonna do...
Anyway, checking upstream's version of Xdefs.h, it seems to check for
_XTYPEDEF_BOOL when defining the type. So both check for that before
defining our type, and define it so that Xdefs.h won't try to re-define
it.
* See:
http://sourceforge.net/tracker/?func=detail&atid=989708&aid=
3118268&group_id=204462
Signed-off-by: Marcelo Vanzin <mvanzin@vmware.com>
#include "includeCheck.h"
/* STRICT ANSI means the Xserver build and X defines Bool differently. */
-#if !defined(__STRICT_ANSI__) || defined(__FreeBSD__) || defined(__MINGW32__)
+#if !defined(_XTYPEDEF_BOOL) && \
+ (!defined(__STRICT_ANSI__) || defined(__FreeBSD__) || defined(__MINGW32__))
+#define _XTYPEDEF_BOOL
typedef char Bool;
#endif