From 69565afab0be081211df57a245a222cbd3e43ed3 Mon Sep 17 00:00:00 2001 From: Yang Tse Date: Thu, 22 Feb 2007 02:51:54 +0000 Subject: Check for stdbool.h at configuration stage, and include it if available. Check for lowercase 'bool' type at configuration stage. If not available provide a suitable replacement with a type definition of 'unsigned char' in setup_once.h Move definitions of TRUE and FALSE to setup_once.h --- ares/configure.ac | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'ares/configure.ac') diff --git a/ares/configure.ac b/ares/configure.ac index 0165c5e90..e870d63d2 100644 --- a/ares/configure.ac +++ b/ares/configure.ac @@ -308,6 +308,8 @@ AC_CHECK_HEADERS( netdb.h \ netinet/in.h \ net/if.h \ + errno.h \ + stdbool.h \ arpa/nameser.h \ arpa/nameser_compat.h \ arpa/inet.h, @@ -369,6 +371,16 @@ fi AC_CHECK_TYPE(ssize_t, , AC_DEFINE(ssize_t, int, [the signed version of size_t])) +# check for bool type +AC_CHECK_TYPE([bool],[ + AC_DEFINE(HAVE_BOOL_T, 1, + [Define to 1 if bool is an available type.]) +], ,[ +#ifdef HAVE_STDBOOL_H +#include +#endif +]) + # Check for socklen_t or equivalent CURL_CHECK_TYPE_SOCKLEN_T -- cgit v1.2.3