aboutsummaryrefslogtreecommitdiff
path: root/ares_setup.h
diff options
context:
space:
mode:
Diffstat (limited to 'ares_setup.h')
-rw-r--r--ares_setup.h22
1 files changed, 21 insertions, 1 deletions
diff --git a/ares_setup.h b/ares_setup.h
index a46c510..4df7961 100644
--- a/ares_setup.h
+++ b/ares_setup.h
@@ -2,7 +2,7 @@
#define HEADER_CARES_SETUP_H
-/* Copyright (C) 2004 - 2009 by Daniel Stenberg et al
+/* Copyright (C) 2004 - 2012 by Daniel Stenberg et al
*
* Permission to use, copy, modify, and distribute this software and its
* documentation for any purpose and without fee is hereby granted, provided
@@ -157,6 +157,18 @@
#endif /* HAVE_CONFIG_H */
+/*
+ * Arg 2 type for gethostname in case it hasn't been defined in config file.
+ */
+
+#ifndef GETHOSTNAME_TYPE_ARG2
+# ifdef USE_WINSOCK
+# define GETHOSTNAME_TYPE_ARG2 int
+# else
+# define GETHOSTNAME_TYPE_ARG2 size_t
+# endif
+#endif
+
#ifdef __POCC__
# include <sys/types.h>
# include <unistd.h>
@@ -164,6 +176,14 @@
#endif
/*
+ * Android does have the arpa/nameser.h header which is detected by configure
+ * but it appears to be empty with recent NDK r7b / r7c, so we undefine here.
+ */
+#if (defined(ANDROID) || defined(__ANDROID__)) && defined(HAVE_ARPA_NAMESER_H)
+# undef HAVE_ARPA_NAMESER_H
+#endif
+
+/*
* Recent autoconf versions define these symbols in ares_config.h. We don't
* want them (since they collide with the libcurl ones when we build
* --enable-debug) so we undef them again here.