Bah, would help even more if I pushed the right patch

This commit is contained in:
Chris Roberts
2013-10-30 17:17:57 -06:00
parent f0200344a5
commit c3aa39521b
2 changed files with 68 additions and 27 deletions

View File

@@ -1,27 +0,0 @@
diff -up c-ares-1.10.0/ares.h.orig c-ares-1.10.0/ares.h
--- c-ares-1.10.0/ares.h.orig 2013-10-30 14:59:47.195297280 -0600
+++ c-ares-1.10.0/ares.h 2013-10-30 15:00:19.284950528 -0600
@@ -38,7 +38,7 @@
require it! */
#if defined(_AIX) || defined(__NOVELL_LIBC__) || defined(__NetBSD__) || \
defined(__minix) || defined(__SYMBIAN32__) || defined(__INTEGRITY) || \
- defined(ANDROID) || defined(__ANDROID__)
+ defined(ANDROID) || defined(__ANDROID__) || defined(__HAIKU__)
#include <sys/select.h>
#endif
#if (defined(NETWARE) && !defined(__NOVELL_LIBC__))
diff -up c-ares-1.10.0/ares_private.h.orig c-ares-1.10.0/ares_private.h
--- c-ares-1.10.0/ares_private.h.orig 2013-02-13 06:58:04.034078720 -0700
+++ c-ares-1.10.0/ares_private.h 2013-10-30 14:59:30.440664064 -0600
@@ -65,6 +65,11 @@
#define PATH_HOSTS "InetDBase:Hosts"
+#elif defined(__HAIKU__)
+
+#define PATH_RESOLV_CONF "/boot/system/settings/network/resolv.conf"
+#define PATH_HOSTS "/boot/system/settings/network/hosts"
+
#else
#define PATH_RESOLV_CONF "/etc/resolv.conf"

View File

@@ -0,0 +1,68 @@
From 0c1419ef8f9f44505eb183e8548d90542ddc7de1 Mon Sep 17 00:00:00 2001
From: Chris Roberts <cpr420@gmail.com>
Date: Wed, 30 Oct 2013 15:41:17 -0600
Subject: applying patch c_ares-1.10.0.patch
diff --git a/ares.h b/ares.h
index 9b3f376..b871032 100644
--- a/ares.h
+++ b/ares.h
@@ -38,7 +38,7 @@
require it! */
#if defined(_AIX) || defined(__NOVELL_LIBC__) || defined(__NetBSD__) || \
defined(__minix) || defined(__SYMBIAN32__) || defined(__INTEGRITY) || \
- defined(ANDROID) || defined(__ANDROID__)
+ defined(ANDROID) || defined(__ANDROID__) || defined(__HAIKU__)
#include <sys/select.h>
#endif
#if (defined(NETWARE) && !defined(__NOVELL_LIBC__))
diff --git a/ares_private.h b/ares_private.h
index ab5be5a..b884fda 100644
--- a/ares_private.h
+++ b/ares_private.h
@@ -65,6 +65,11 @@
#define PATH_HOSTS "InetDBase:Hosts"
+#elif defined(__HAIKU__)
+
+#define PATH_RESOLV_CONF "/boot/system/settings/network/resolv.conf"
+#define PATH_HOSTS "/boot/system/settings/network/hosts"
+
#else
#define PATH_RESOLV_CONF "/etc/resolv.conf"
--
1.8.3.4
From 3287466624c281088ae83001e96e9391d0f5b97d Mon Sep 17 00:00:00 2001
From: Chris Roberts <cpr420@gmail.com>
Date: Wed, 30 Oct 2013 15:52:39 -0600
Subject: Search for libnetwork
diff --git a/configure.ac b/configure.ac
index 5c02450..423ce64 100644
--- a/configure.ac
+++ b/configure.ac
@@ -222,6 +222,15 @@ then
])
fi
+if test "$HAVE_GETHOSTBYNAME" != "1"
+then
+ dnl gethostbyname in the network lib?
+ AC_CHECK_LIB(network, gethostbyname,
+ [HAVE_GETHOSTBYNAME="1"
+ LIBS="$LIBS -lnetwork"
+ ])
+fi
+
dnl At least one system has been identified to require BOTH nsl and socket
dnl libs at the same time to link properly.
if test "$HAVE_GETHOSTBYNAME" != "1"
--
1.8.3.4