summaryrefslogtreecommitdiff
path: root/net/dante/patches/patch-ab
blob: 77cf0012ecf71b03884de35578eb2de0c73daf97 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
$NetBSD: patch-ab,v 1.7 2006/01/19 18:53:00 joerg Exp $

--- configure.orig	2005-07-14 13:22:39.000000000 +0200
+++ configure
@@ -19864,7 +19864,6 @@ else
 echo "${ECHO_T}no" >&6
     #autoconf_compflags is set to "-g -O2" with GCC
     #override CFLAGS when running configure to avoid this
-    CFLAGS="$CFLAGS $autoconf_compflags"
 fi
 
 #-Wall ?
@@ -25309,8 +25308,13 @@ cat >>conftest.$ac_ext <<_ACEOF
 #include <netdb.h>
 #include <unistd.h>
 
+#if defined(__DragonFly__)
 struct hostent *
 gethostbyaddr( const char *, int, int
+#else
+struct hostent *
+gethostbyaddr( const char *, socklen_t, int
+#endif
 );
 int
 main ()
@@ -25351,9 +25355,18 @@ cat >>confdefs.h <<_ACEOF
 #define HAVE_PROT_GETHOSTBYADDR_1 const char *
 _ACEOF
 
-cat >>confdefs.h <<_ACEOF
+case "$host_os" in
+dragonfly*)
+	cat >>confdefs.h <<_ACEOF
 #define HAVE_PROT_GETHOSTBYADDR_2 int
 _ACEOF
+;;
+*)
+	cat >>confdefs.h <<_ACEOF
+#define HAVE_PROT_GETHOSTBYADDR_2 socklen_t
+_ACEOF
+;;
+esac
 
 cat >>confdefs.h <<_ACEOF
 #define HAVE_PROT_GETHOSTBYADDR_3 int