summaryrefslogtreecommitdiff
path: root/dns/idnkit/files/patch-configure
blob: 1443b00b0d0e6e46535cb9a7e16dd4815a430e59 (plain) (blame)
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
--- configure.orig	2003-03-10 23:53:20 UTC
+++ configure
@@ -762,14 +762,14 @@ yes)
 	libiconv=$prefix
     fi
     ICONVINC="-I$libiconv/include"
-    ICONVLIB="-L$libiconv/lib -R$libiconv/lib -liconv"
+    ICONVLIB="-L$libiconv/lib -liconv"
     ;;
 *)
     if test "$liteonly" = yes ; then
 	{ echo "configure: error: you can't set iconv options at all when you set value \"yes\" to --enable-liteonly, because lite library does not have iconv support." 1>&2; exit 1; }
     fi
     ICONVINC="-I$libiconv/include"
-    ICONVLIB="-L$libiconv/lib -R$libiconv/lib -liconv"
+    ICONVLIB="-L$libiconv/lib -liconv"
     ;;
 esac
 
@@ -1082,7 +1082,7 @@ cat > conftest.$ac_ext << EOF
 #line 1083 "configure"
 #include "confdefs.h"
 
-main(){return(0);}
+int main(){return(0);}
 EOF
 if { (eval echo configure:1088: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
   ac_cv_prog_cc_works=yes
@@ -2633,13 +2633,43 @@ fi
   ac_cv_flavor_gethostbyaddr=unknown
 else
   cat > conftest.$ac_ext <<EOF
-#line 2637 "configure"
+#line 2648 "configure"
 #include "confdefs.h"
 
     #include <stddef.h>
     #include <sys/types.h>
     #include <sys/socket.h>
     #include <netdb.h>
+    struct hostent *gethostbyaddr(const void *addr, int len, int type) {
+	return NULL;
+    }
+    int main() {
+	(void)gethostbyaddr(NULL, 0, 0);
+	return 0;
+    }
+    
+EOF
+if { (eval echo configure:2664: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
+then
+  ac_cv_flavor_gethostbyaddr=freebsd6
+else
+  echo "configure: failed program was:" >&5
+  cat conftest.$ac_ext >&5
+fi
+rm -fr conftest*
+fi
+
+    if test "$cross_compiling" = yes; then
+  ac_cv_flavor_gethostbyaddr=unknown
+else
+  cat > conftest.$ac_ext <<EOF
+#line 2678 "configure"
+#include "confdefs.h"
+
+    #include <stddef.h>
+    #include <sys/types.h>
+    #include <sys/socket.h>
+    #include <netdb.h>
     struct hostent *gethostbyaddr(const char *addr, int len, int type) {
 	return NULL;
     }
@@ -2675,6 +2705,10 @@ echo "$ac_t""$ac_cv_flavor_gethostbyaddr" 1>&6
 	ac_cv_type_ghba_addr_t='const char *'
 	ac_cv_type_ghba_addrlen_t='size_t'
 	;;
+    freebsd6)
+	ac_cv_type_ghba_addr_t='const void *'
+	ac_cv_type_ghba_addrlen_t='int'
+	;;
     traditional | none)
 	ac_cv_type_ghba_addr_t='const char *'
 	ac_cv_type_ghba_addrlen_t='int'
@@ -2712,7 +2746,7 @@ else
     int getnameinfo(const struct sockaddr *sa, socklen_t salen, char *host,
                     socklen_t hostlen, char *serv, socklen_t servlen,
                     unsigned int flags) {
-	return NULL;
+	return 0;
     }
     int main() {
 	(void)getnameinfo(NULL, 0, NULL, 0, NULL, 0, 0);
@@ -2744,7 +2778,7 @@ else
     int getnameinfo(const struct sockaddr *sa, socklen_t salen, char *host,
                     socklen_t hostlen, char *serv, socklen_t servlen,
                     int flags) {
-	return NULL;
+	return 0;
     }
     int main() {
 	(void)getnameinfo(NULL, 0, NULL, 0, NULL, 0, 0);
@@ -2775,7 +2809,7 @@ else
     #include <netdb.h>
     int getnameinfo(const struct sockaddr *sa, socklen_t salen, char *host,
                     size_t hostlen, char *serv, size_t servlen, int flags) {
-	return NULL;
+	return 0;
     }
     int main() {
 	(void)getnameinfo(NULL, 0, NULL, 0, NULL, 0, 0);
@@ -2806,7 +2840,7 @@ else
     #include <netdb.h>
     int getnameinfo(const struct sockaddr *sa, size_t salen, char *host,
                     size_t hostlen, char *serv, size_t servlen, int flags) {
-	return NULL;
+	return 0;
     }
     int main() {
 	(void)getnameinfo(NULL, 0, NULL, 0, NULL, 0, 0);