aboutsummaryrefslogtreecommitdiffstats
path: root/configure.in
diff options
context:
space:
mode:
authorJP Rosevear <jpr@ximian.com>2001-04-12 00:10:30 +0800
committerJP Rosevear <jpr@src.gnome.org>2001-04-12 00:10:30 +0800
commitf132c28d7f50f16f0d1fe5c93a68eb17ba6d55ac (patch)
tree9a2a78d068638605353988662cad84b7828ef37d /configure.in
parent028643bccfc06f2e070c7bf5b7ee582c26c5d650 (diff)
downloadgsoc2013-evolution-f132c28d7f50f16f0d1fe5c93a68eb17ba6d55ac.tar.gz
gsoc2013-evolution-f132c28d7f50f16f0d1fe5c93a68eb17ba6d55ac.tar.zst
gsoc2013-evolution-f132c28d7f50f16f0d1fe5c93a68eb17ba6d55ac.zip
Check if gethostbyname_r take five params
2001-04-11 JP Rosevear <jpr@ximian.com> * configure.in: Check if gethostbyname_r take five params * acconfig.h: add GETHOSTBYNAME_R_FIVE_ARGS 2001-04-11 JP Rosevear <jpr@ximian.com> * providers/imap/Makefile.am: user GNOME_INCLUDEDIR since gnome files are included in the top level camel headers and the gtk include dir is now versioned and such * providers/local/Makefile.am: ditto * providers/pop3/Makefile.am: ditto * providers/smtp/Makefile.am: ditto * providers/sendmail/Makefile.am: ditto * camel-service.c: use five arg version of gethostbyname_r if appropriate (camel_get_host_byname): check if msg->herr is non-zero instead of checking if msg->hp is null since we may not always have msg->hp svn path=/trunk/; revision=9239
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in32
1 files changed, 32 insertions, 0 deletions
diff --git a/configure.in b/configure.in
index c861ef90c7..b94f36e309 100644
--- a/configure.in
+++ b/configure.in
@@ -151,6 +151,38 @@ if test x"$ac_cv_ctime_r_three_args" = xyes ; then
fi
dnl **************************************************
+dnl gethostbyname_r prototype
+dnl **************************************************
+
+AC_CACHE_CHECK([if gethostbyname_r wants five arguments], ac_cv_gethostbyname_r_five_args,
+[
+ AC_TRY_COMPILE([
+ #include "confdefs.h"
+ #include <sys/types.h>
+ #include <sys/socket.h>
+ #include <netinet/in.h>
+ #include <netdb.h>
+
+ #define BUFSIZE (sizeof(struct hostent)+10)
+ ],[
+ struct hostent hent;
+ char buffer[BUFSIZE];
+ int bufsize=BUFSIZE;
+ int h_errno;
+
+ (void)gethostbyname_r( "www.ximian.com", &hent, buffer, bufsize, &h_errno);
+ ],[
+ ac_cv_gethostbyname_r_five_args=yes
+ ],[
+ ac_cv_gethostbyname_r_five_args=no
+ ])
+])
+
+if test x"$ac_cv_gethostbyname_r_five_args" = xyes ; then
+ AC_DEFINE(GETHOSTBYNAME_R_FIVE_ARGS)
+fi
+
+dnl **************************************************
dnl * pas-backend-file stuff.
dnl * check for db_185.h. if it's there, we use it.
dnl * otherwise, we use db.h (since it'll be 185).