1 ?RCS: $Id: d_gethostbyaddr_r.U,v 0RCS:
2 ?RCS: Copyright (c) 2002 Jarkko Hietaniemi
4 ?RCS: You may distribute under the terms of either the GNU General Public
5 ?RCS: License or the Artistic License, as specified in the README file.
7 ?RCS: Generated by the reentr.pl from the Perl 5.8 distribution.
9 ?MAKE:d_gethostbyaddr_r gethostbyaddr_r_proto: Inlibc Protochk Hasproto i_systypes i_systime i_netdb usethreads i_pthread
10 ?MAKE: -pick add $@ %<
12 ?S: This variable conditionally defines the HAS_GETHOSTBYADDR_R symbol,
13 ?S: which indicates to the C program that the gethostbyaddr_r()
14 ?S: routine is available.
16 ?S:gethostbyaddr_r_proto:
17 ?S: This variable encodes the prototype of gethostbyaddr_r.
19 ?C:HAS_GETHOSTBYADDR_R:
20 ?C: This symbol, if defined, indicates that the gethostbyaddr_r routine
21 ?C: is available to gethostbyaddr re-entrantly.
23 ?C:GETHOSTBYADDR_R_PROTO:
24 ?C: This symbol encodes the prototype of gethostbyaddr_r.
26 ?H:#$d_gethostbyaddr_r HAS_GETHOSTBYADDR_R /**/
27 ?H:#define GETHOSTBYADDR_R_PROTO $gethostbyaddr_r_proto /**/
29 ?T:try hdrs d_gethostbyaddr_r_proto
30 ?LINT:set d_gethostbyaddr_r
31 ?LINT:set gethostbyaddr_r_proto
32 : see if gethostbyaddr_r exists
33 set gethostbyaddr_r d_gethostbyaddr_r
35 case "$d_gethostbyaddr_r" in
37 hdrs="$i_systypes sys/types.h define stdio.h $i_netdb netdb.h"
38 case "$d_gethostbyaddr_r_proto:$usethreads" in
39 ":define") d_gethostbyaddr_r_proto=define
40 set d_gethostbyaddr_r_proto gethostbyaddr_r $hdrs
44 case "$d_gethostbyaddr_r_proto" in
46 case "$gethostbyaddr_r_proto" in
47 ''|0) try='int gethostbyaddr_r(const char*, size_t, int, struct hostent*, char*, size_t, struct hostent**, int*);'
48 ./protochk "extern $try" $hdrs && gethostbyaddr_r_proto=I_CWISBWRE ;;
50 case "$gethostbyaddr_r_proto" in
51 ''|0) try='struct hostent* gethostbyaddr_r(const char*, size_t, int, struct hostent*, char*, size_t, int, int*);'
52 ./protochk "extern $try" $hdrs && gethostbyaddr_r_proto=S_CWISBWIE ;;
54 case "$gethostbyaddr_r_proto" in
55 ''|0) try='struct hostent* gethostbyaddr_r(const char*, size_t, int, struct hostent*, char*, int, int*);'
56 ./protochk "extern $try" $hdrs && gethostbyaddr_r_proto=S_CWISBIE ;;
58 case "$gethostbyaddr_r_proto" in
59 ''|0) try='struct hostent* gethostbyaddr_r(const void*, size_t, int, struct hostent*, char*, int, int*);'
60 ./protochk "extern $try" $hdrs && gethostbyaddr_r_proto=S_TWISBIE ;;
62 case "$gethostbyaddr_r_proto" in
63 ''|0) try='struct hostent* gethostbyaddr_r(const char*, int, int, struct hostent*, char*, int, int*);'
64 ./protochk "extern $try" $hdrs && gethostbyaddr_r_proto=S_CIISBIE ;;
66 case "$gethostbyaddr_r_proto" in
67 ''|0) try='struct hostent* gethostbyaddr_r(const char*, struct hostent*, char*, int, int*);'
68 ./protochk "extern $try" $hdrs && gethostbyaddr_r_proto=S_CSBIE ;;
70 case "$gethostbyaddr_r_proto" in
71 ''|0) try='struct hostent* gethostbyaddr_r(const void*, struct hostent*, char*, int, int*);'
72 ./protochk "extern $try" $hdrs && gethostbyaddr_r_proto=S_TSBIE ;;
74 case "$gethostbyaddr_r_proto" in
75 ''|0) try='int gethostbyaddr_r(const char*, size_t, int, struct hostent*, struct hostent_data*);'
76 ./protochk "extern $try" $hdrs && gethostbyaddr_r_proto=I_CWISD ;;
78 case "$gethostbyaddr_r_proto" in
79 ''|0) try='int gethostbyaddr_r(const char*, int, int, struct hostent*, struct hostent_data*);'
80 ./protochk "extern $try" $hdrs && gethostbyaddr_r_proto=I_CIISD ;;
82 case "$gethostbyaddr_r_proto" in
83 ''|0) try='int gethostbyaddr_r(const char*, int, int);'
84 ./protochk "extern $try" $hdrs && gethostbyaddr_r_proto=I_CII ;;
86 case "$gethostbyaddr_r_proto" in
87 ''|0) d_gethostbyaddr_r=undef
88 gethostbyaddr_r_proto=0
89 echo "Disabling gethostbyaddr_r, cannot determine prototype." >&4 ;;
90 * ) case "$gethostbyaddr_r_proto" in
92 *) gethostbyaddr_r_proto="REENTRANT_PROTO_$gethostbyaddr_r_proto" ;;
94 echo "Prototype: $try" ;;
97 *) case "$usethreads" in
98 define) echo "gethostbyaddr_r has no prototype, not using it." >&4 ;;
100 d_gethostbyaddr_r=undef
101 gethostbyaddr_r_proto=0
105 *) gethostbyaddr_r_proto=0