~andreserl/ubuntu/lucid/bind9/bind9-apport-533601

« back to all changes in this revision

Viewing changes to lib/bind/configure.in

  • Committer: Bazaar Package Importer
  • Author(s): LaMont Jones, LaMont Jones, Internet Software Consortium, Inc, localization folks
  • Date: 2008-08-02 14:20:20 UTC
  • mfrom: (1.2.1 upstream) (6.1.24 intrepid)
  • Revision ID: james.westby@ubuntu.com-20080802142020-l1hon9jy8lbbjxmg
[LaMont Jones]

* default to using resolvconf if it is installed
* fix sonames and dependencies.  Closes: #149259, #492418
* Do not build-depend libcap2-dev on non-linux.  Closes: #493392
* drop unused query-loc manpage.  Closes: #492564
* lwresd: Deliver /etc/bind directory.  Closes: #490027
* fix query-source comment in default install

[Internet Software Consortium, Inc]

* 9.5.0-P2.  Closes: #492949

[localization folks]

* l10n: Spanish debconf translation.  Closes: #492425 (Ignacio Mondino)
* l10n: Swedish debconf templates.  Closes: #491369 (Martin Ågren)
* l10n: Japanese debconf translations.  Closes: #492048 (Hideki Yamane
  (Debian-JP))
* l10n: Finnish translation.  Closes: #490630 (Esko Arajärvi)
* l10n: Italian debconf translations.  Closes: #492587 (Alessandro Vietta)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2004, 2005  Internet Systems Consortium, Inc. ("ISC")
2
 
# Copyright (C) 2001  Internet Software Consortium.
 
1
# Copyright (C) 2004-2008  Internet Systems Consortium, Inc. ("ISC")
 
2
# Copyright (C) 2001, 2003  Internet Software Consortium.
3
3
#
4
 
# Permission to use, copy, modify, and distribute this software for any
 
4
# Permission to use, copy, modify, and/or distribute this software for any
5
5
# purpose with or without fee is hereby granted, provided that the above
6
6
# copyright notice and this permission notice appear in all copies.
7
7
#
13
13
# OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
14
14
# PERFORMANCE OF THIS SOFTWARE.
15
15
 
16
 
AC_REVISION($Revision: 1.83.2.5.2.22 $)
 
16
AC_REVISION($Revision: 1.128.128.7.4.1 $)
17
17
 
18
18
AC_INIT(resolv/herror.c)
19
19
AC_PREREQ(2.13)
169
169
AC_HEADER_STDC
170
170
 
171
171
 
172
 
AC_CHECK_HEADERS(fcntl.h db.h paths.h sys/time.h unistd.h sys/sockio.h sys/select.h sys/timers.h stropts.h)
 
172
AC_CHECK_HEADERS(fcntl.h db.h paths.h sys/time.h unistd.h sys/sockio.h sys/select.h sys/timers.h stropts.h memory.h)
173
173
 
174
174
AC_C_CONST
175
175
AC_C_INLINE
176
176
AC_TYPE_SIZE_T
 
177
AC_CHECK_TYPE(ssize_t,signed)
177
178
AC_CHECK_TYPE(uintptr_t,unsigned long)
178
179
AC_HEADER_TIME
179
180
#
319
320
 
320
321
if $use_threads
321
322
then
 
323
        if test "X$GCC" = "Xyes"; then
 
324
                case "$host" in
 
325
                *-freebsd*)
 
326
                        CC="$CC -pthread"
 
327
                        CCOPT="$CCOPT -pthread"
 
328
                        STD_CDEFINES="$STD_CDEFINES -D_THREAD_SAFE"
 
329
                        ;;
 
330
                *-openbsd*)
 
331
                        CC="$CC -pthread"
 
332
                        CCOPT="$CCOPT -pthread"
 
333
                        ;;
 
334
                *-solaris*)
 
335
                        LIBS="$LIBS -lthread"
 
336
                        ;;
 
337
                *-ibm-aix*)
 
338
                        STD_CDEFINES="$STD_CDEFINES -D_THREAD_SAFE"
 
339
                        ;;
 
340
                esac
 
341
        else
 
342
                case $host in
 
343
                *-dec-osf*)
 
344
                        CC="$CC -pthread"
 
345
                        CCOPT="$CCOPT -pthread"
 
346
                        ;;
 
347
                *-solaris*)
 
348
                        CC="$CC -mt"
 
349
                        CCOPT="$CCOPT -mt"
 
350
                        ;;
 
351
                *-ibm-aix*)
 
352
                        STD_CDEFINES="$STD_CDEFINES -D_THREAD_SAFE"
 
353
                        ;;
 
354
                *-UnixWare*)
 
355
                        CC="$CC -Kthread"
 
356
                        CCOPT="$CCOPT -Kthread"
 
357
                        ;;
 
358
                esac
 
359
        fi
 
360
        AC_DEFINE(_REENTRANT)
 
361
        ALWAYS_DEFINES="-D_REENTRANT"
 
362
        DO_PTHREADS="#define DO_PTHREADS 1"
 
363
        WANT_IRS_THREADSGR_OBJS="\${WANT_IRS_THREADSGR_OBJS}"
 
364
        WANT_IRS_THREADSPW_OBJS="\${WANT_IRS_THREADSPW_OBJS}"
 
365
        case $host in
 
366
        ia64-hp-hpux11.*)
 
367
                WANT_IRS_THREADS_OBJS="";;
 
368
        *)
 
369
                WANT_IRS_THREADS_OBJS="\${WANT_IRS_THREADS_OBJS}";;
 
370
        esac
 
371
        WANT_THREADS_OBJS="\${WANT_THREADS_OBJS}"
 
372
        thread_dir=pthreads
 
373
 
322
374
        #
323
375
        # We'd like to use sigwait() too
324
376
        #
325
 
        AC_CHECK_LIB(c, sigwait,
326
 
                     AC_DEFINE(HAVE_SIGWAIT),
327
 
                     AC_CHECK_LIB(pthread, sigwait,
328
 
                                  AC_DEFINE(HAVE_SIGWAIT),
329
 
                                  AC_CHECK_LIB(pthread, _Psigwait,
330
 
                                               AC_DEFINE(HAVE_SIGWAIT),))
331
 
        )
 
377
        AC_CHECK_FUNC(sigwait,
 
378
                      AC_DEFINE(HAVE_SIGWAIT),
 
379
                      AC_CHECK_LIB(c, sigwait,
 
380
                      AC_DEFINE(HAVE_SIGWAIT),
 
381
                      AC_CHECK_LIB(pthread, sigwait,
 
382
                                   AC_DEFINE(HAVE_SIGWAIT),
 
383
                                   AC_CHECK_LIB(pthread, _Psigwait,
 
384
                                                AC_DEFINE(HAVE_SIGWAIT),))))
332
385
 
333
386
        AC_CHECK_FUNC(pthread_attr_getstacksize,
334
387
                      AC_DEFINE(HAVE_PTHREAD_ATTR_GETSTACKSIZE),)
388
441
        #
389
442
        AC_CHECK_FUNC(sysconf, AC_DEFINE(HAVE_SYSCONF),)
390
443
 
391
 
        if test "X$GCC" = "Xyes"; then
392
 
                case "$host" in
393
 
                *-freebsd*)
394
 
                        CC="$CC -pthread"
395
 
                        CCOPT="$CCOPT -pthread"
396
 
                        STD_CDEFINES="$STD_CDEFINES -D_THREAD_SAFE"
397
 
                        ;;
398
 
                *-openbsd*)
399
 
                        CC="$CC -pthread"
400
 
                        CCOPT="$CCOPT -pthread"
401
 
                        ;;
402
 
                *-solaris*)
403
 
                        LIBS="$LIBS -lthread"
404
 
                        ;;
405
 
                *-ibm-aix*)
406
 
                        STD_CDEFINES="$STD_CDEFINES -D_THREAD_SAFE"
407
 
                        ;;
408
 
                esac
409
 
        else
410
 
                case $host in
411
 
                *-dec-osf*)
412
 
                        CC="$CC -pthread"
413
 
                        CCOPT="$CCOPT -pthread"
414
 
                        ;;
415
 
                *-solaris*)
416
 
                        CC="$CC -mt"
417
 
                        CCOPT="$CCOPT -mt"
418
 
                        ;;
419
 
                *-ibm-aix*)
420
 
                        STD_CDEFINES="$STD_CDEFINES -D_THREAD_SAFE"
421
 
                        ;;
422
 
                *-UnixWare*)
423
 
                        CC="$CC -Kthread"
424
 
                        CCOPT="$CCOPT -Kthread"
425
 
                        ;;
426
 
                esac
427
 
        fi
428
 
        AC_DEFINE(_REENTRANT)
429
 
        ALWAYS_DEFINES="-D_REENTRANT"
430
 
        DO_PTHREADS="#define DO_PTHREADS 1"
431
 
        WANT_IRS_THREADSGR_OBJS="\${WANT_IRS_THREADSGR_OBJS}"
432
 
        WANT_IRS_THREADSPW_OBJS="\${WANT_IRS_THREADSPW_OBJS}"
433
 
        case $host in
434
 
        ia64-hp-hpux11.*)
435
 
                WANT_IRS_THREADS_OBJS="";;
436
 
        *)
437
 
                WANT_IRS_THREADS_OBJS="\${WANT_IRS_THREADS_OBJS}";;
438
 
        esac
439
 
        WANT_THREADS_OBJS="\${WANT_THREADS_OBJS}"
440
 
        thread_dir=pthreads
441
444
else
442
445
        ALWAYS_DEFINES=""
443
446
        DO_PTHREADS="#undef DO_PTHREADS"
456
459
AC_SUBST(WANT_THREADS_OBJS)
457
460
 
458
461
AC_CHECK_FUNC(strlcat, AC_DEFINE(HAVE_STRLCAT))
 
462
AC_CHECK_FUNC(memmove, AC_DEFINE(HAVE_MEMMOVE))
 
463
AC_CHECK_FUNC(memchr, AC_DEFINE(HAVE_MEMCHR))
 
464
AC_CHECK_FUNC(strtoul, , AC_DEFINE(NEED_STRTOUL))
459
465
 
460
466
AC_CHECK_FUNC(if_nametoindex,
461
467
        [USE_IFNAMELINKID="#define USE_IFNAMELINKID 1"],
485
491
[NEED_STRERROR="#define NEED_STRERROR 1"])
486
492
AC_SUBST(NEED_STRERROR)
487
493
 
 
494
if test -n "$NEED_STRERROR"
 
495
then
 
496
        AC_MSG_CHECKING([for extern char * sys_errlist[]])
 
497
        AC_TRY_LINK([ extern int sys_nerr; extern char *sys_errlist[]; ],
 
498
                    [ const char *p = sys_errlist[0]; ],
 
499
                    AC_MSG_RESULT(yes)
 
500
                    AC_DEFINE(USE_SYSERROR_LIST),
 
501
                    AC_MSG_RESULT(no))
 
502
fi
 
503
 
488
504
#
489
505
# flockfile is usually provided by pthreads, but we may want to use it
490
506
# even if compiled with --disable-threads.
513
529
IRIX_DNSSEC_WARNINGS_HACK=""
514
530
 
515
531
if test "X$GCC" = "Xyes"; then
516
 
        STD_CWARNINGS="$STD_CWARNINGS -W -Wall -Wmissing-prototypes -Wcast-qual -Wwrite-strings"
 
532
        AC_MSG_CHECKING(if "$CC" supports -fno-strict-aliasing)
 
533
        SAVE_CFLAGS=$CFLAGS
 
534
        CFLAGS=-fno-strict-aliasing
 
535
        AC_TRY_COMPILE(,, [FNOSTRICTALIASING=yes],[FNOSTRICTALIASING=no])
 
536
        CFLAGS=$SAVE_CFLAGS
 
537
        if test "$FNOSTRICTALIASING" = "yes"; then
 
538
                AC_MSG_RESULT(yes)
 
539
                STD_CWARNINGS="$STD_CWARNINGS -W -Wall -Wmissing-prototypes -Wcast-qual -Wwrite-strings -Wformat -Wpointer-arith -fno-strict-aliasing"
 
540
        else
 
541
                AC_MSG_RESULT(no)
 
542
                STD_CWARNINGS="$STD_CWARNINGS -W -Wall -Wmissing-prototypes -Wcast-qual -Wwrite-strings -Wformat -Wpointer-arith"
 
543
        fi
517
544
else
518
545
        case $host in
519
546
        *-dec-osf*)
650
677
#
651
678
# GNU libtool support
652
679
#
 
680
case $host in
 
681
sunos*)
 
682
    # Just set the maximum command line length for sunos as it otherwise
 
683
    # takes a exceptionally long time to work it out. Required for libtool.
 
684
    lt_cv_sys_max_cmd_len=4096;
 
685
    ;;
 
686
esac
 
687
 
653
688
AC_ARG_WITH(libtool,
654
689
            [  --with-libtool   use GNU libtool (following indented options supported)],
655
690
            use_libtool="$withval", use_libtool="no")
866
901
                         ISC_PLATFORM_HAVEIN6PKTINFO="#define ISC_PLATFORM_HAVEIN6PKTINFO 1"],
867
902
                        [AC_MSG_RESULT(no -- disabling runtime ipv6 support)
868
903
                         ISC_PLATFORM_HAVEIN6PKTINFO="#undef ISC_PLATFORM_HAVEIN6PKTINFO"])
869
 
 
870
 
                AC_MSG_CHECKING(for sockaddr_storage)
871
 
                AC_TRY_COMPILE([
872
 
#include <sys/types.h>
873
 
#include <sys/socket.h>
874
 
#include <netinet/in.h>
875
 
$isc_netinetin6_hack
876
 
$isc_netinet6in6_hack
877
 
],
878
 
                [struct sockaddr_storage xyzzy; return (0);],
879
 
                        [AC_MSG_RESULT(yes)
880
 
                         HAVE_SOCKADDR_STORAGE="#define HAVE_SOCKADDR_STORAGE 1"],
881
 
                        [AC_MSG_RESULT(no)
882
 
                         HAVE_SOCKADDR_STORAGE="#undef HAVE_SOCKADDR_STORAGE"])
883
904
                ;;
884
905
        no)
885
906
                HAS_INET6_STRUCTS="#undef HAS_INET6_STRUCTS"
886
907
                NEED_IN6ADDR_ANY="#undef NEED_IN6ADDR_ANY"
887
908
                ISC_PLATFORM_HAVEIN6PKTINFO="#undef ISC_PLATFORM_HAVEIN6PKTINFO"
888
909
                HAVE_SIN6_SCOPE_ID="#define HAVE_SIN6_SCOPE_ID 1"
889
 
                HAVE_SOCKADDR_STORAGE="#undef HAVE_SOCKADDR_STORAGE"
890
910
                ISC_IPV6_H="ipv6.h"
891
911
                ISC_IPV6_O="ipv6.$O"
892
912
                ISC_ISCIPV6_O="unix/ipv6.$O"
894
914
                ;;
895
915
esac
896
916
 
 
917
AC_MSG_CHECKING(for sockaddr_storage)
 
918
AC_TRY_COMPILE([
 
919
#include <sys/types.h>
 
920
#include <sys/socket.h>
 
921
#include <netinet/in.h>
 
922
],
 
923
[struct sockaddr_storage xyzzy; return (0);],
 
924
        [AC_MSG_RESULT(yes)
 
925
         HAVE_SOCKADDR_STORAGE="#define HAVE_SOCKADDR_STORAGE 1"],
 
926
        [AC_MSG_RESULT(no)
 
927
         HAVE_SOCKADDR_STORAGE="#undef HAVE_SOCKADDR_STORAGE"])
 
928
 
897
929
AC_SUBST(HAS_INET6_STRUCTS)
898
930
AC_SUBST(ISC_PLATFORM_NEEDNETINETIN6H)
899
931
AC_SUBST(ISC_PLATFORM_NEEDNETINET6IN6H)
963
995
#
964
996
case "$host" in
965
997
        *-dec-osf*)
 
998
                # Tru64 broke send() by defining it to send_OBSOLETE
 
999
                AC_DEFINE(REENABLE_SEND)
966
1000
                # Turn on 4.4BSD style sa_len support.
967
1001
                AC_DEFINE(_SOCKADDR_LEN)
968
1002
                ;;
1037
1071
        *-qnx*)         PORT_DIR="port/qnx";;
1038
1072
        *-rhapsody*)    PORT_DIR="port/rhapsody";;
1039
1073
        *-sunos4*)
 
1074
                        AC_DEFINE(NEED_SUN4PROTOS)
1040
1075
                        PORT_NONBLOCK="#define PORT_NONBLOCK O_NDELAY"
1041
1076
                        PORT_DIR="port/sunos";;
1042
1077
        *-solaris2.[[01234]])
1104
1139
        ISC_PLATFORM_NEEDPORTT="#define ISC_PLATFORM_NEEDPORTT 1"])
1105
1140
AC_SUBST(ISC_PLATFORM_NEEDPORTT)
1106
1141
 
 
1142
AC_MSG_CHECKING(for struct timespec)
 
1143
AC_TRY_COMPILE([
 
1144
#include <sys/types.h>
 
1145
#include <time.h>],
 
1146
[struct timespec ts = { 0, 0 }; return (0);],
 
1147
        [AC_MSG_RESULT(yes)
 
1148
        ISC_PLATFORM_NEEDTIMESPEC="#undef ISC_PLATFORM_NEEDTIMESPEC"],
 
1149
        [AC_MSG_RESULT(no)
 
1150
        ISC_PLATFORM_NEEDTIMESPEC="#define ISC_PLATFORM_NEEDTIMESPEC 1"])
 
1151
AC_SUBST(ISC_PLATFORM_NEEDTIMESPEC)
 
1152
 
1107
1153
#
1108
1154
# Check for addrinfo
1109
1155
#
1222
1268
AC_CHECK_FUNC(strsep,
1223
1269
        [ISC_PLATFORM_NEEDSTRSEP="#undef ISC_PLATFORM_NEEDSTRSEP"],
1224
1270
        [ISC_PLATFORM_NEEDSTRSEP="#define ISC_PLATFORM_NEEDSTRSEP 1"])
 
1271
 
 
1272
 
 
1273
AC_MSG_CHECKING(for char *sprintf)
 
1274
AC_TRY_COMPILE([
 
1275
#include <stdio.h>
 
1276
],
 
1277
[ char buf[2]; return(*sprintf(buf,"x"));],
 
1278
AC_DEFINE(SPRINTF_CHAR)
 
1279
AC_MSG_RESULT(yes)
 
1280
,
 
1281
AC_MSG_RESULT(no)
 
1282
)
 
1283
 
 
1284
AC_MSG_CHECKING(for char *vsprintf)
 
1285
case $host in
 
1286
*sunos4*) # not decared in any header file.
 
1287
AC_DEFINE(VSPRINTF_CHAR)
 
1288
AC_MSG_RESULT(yes)
 
1289
;;
 
1290
*)
 
1291
AC_TRY_COMPILE([
 
1292
#include <stdio.h>
 
1293
],
 
1294
[ char buf[2]; return(*vsprintf(buf,"x"));],
 
1295
AC_DEFINE(VSPRINTF_CHAR)
 
1296
AC_MSG_RESULT(yes)
 
1297
,
 
1298
AC_MSG_RESULT(no)
 
1299
)
 
1300
;;
 
1301
esac
 
1302
 
1225
1303
AC_CHECK_FUNC(vsnprintf,
1226
1304
        [ISC_PLATFORM_NEEDVSNPRINTF="#undef ISC_PLATFORM_NEEDVSNPRINTF"],
1227
1305
        [ISC_EXTRA_OBJS="$ISC_EXTRA_OBJS print.$O"
1232
1310
 
1233
1311
AC_SUBST(ISC_EXTRA_OBJS)
1234
1312
AC_SUBST(ISC_EXTRA_SRCS)
1235
 
AC_CHECK_FUNC(strerror,
1236
 
        [USE_SYSERROR_LIST="#undef USE_SYSERROR_LIST"],
1237
 
        [USE_SYSERROR_LIST="#define USE_SYSERROR_LIST 1"])
1238
 
AC_SUBST(USE_SYSERROR_LIST)
1239
1313
 
1240
 
#
1241
1314
# Determine the printf format characters to use when printing
1242
1315
# values of type isc_int64_t.  We make the assumption that platforms
1243
1316
# where a "long long" is the same size as a "long" (e.g., Alpha/OSF1)
1397
1470
#undef __USE_MISC
1398
1471
#define __USE_MISC
1399
1472
[#include <netdb.h>
 
1473
int getnetbyaddr_r (in_addr_t, int, struct netent *, struct netent_data *);
 
1474
],
 
1475
[return (0)],
 
1476
[
 
1477
NET_R_ARGS="#define NET_R_ARGS struct netent_data *ndptr"
 
1478
NET_R_BAD="#define NET_R_BAD (-1)"
 
1479
NET_R_COPY="#define NET_R_COPY ndptr"
 
1480
NET_R_COPY_ARGS="#define NET_R_COPY_ARGS struct netent_data *ndptr"
 
1481
NET_R_OK="#define NET_R_OK 0"
 
1482
NET_R_SETANSWER="#undef NET_R_SETANSWER"
 
1483
NET_R_RETURN="#define NET_R_RETURN int"
 
1484
GETNETBYADDR_ADDR_T="#define GETNETBYADDR_ADDR_T long"
 
1485
NETENT_DATA="#define NETENT_DATA 1"
 
1486
],
 
1487
AC_TRY_COMPILE(
 
1488
#undef __USE_MISC
 
1489
#define __USE_MISC
 
1490
[#include <netdb.h>
1400
1491
int getnetbyaddr_r (long, int, struct netent *, struct netent_data *);
1401
1492
],
1402
1493
[return (0)],
1435
1526
)
1436
1527
)
1437
1528
)
 
1529
)
1438
1530
,
1439
1531
NET_R_ARGS="#define NET_R_ARGS char *buf, int buflen"
1440
1532
NET_R_BAD="#define NET_R_BAD NULL"
1822
1914
 
1823
1915
case $host in
1824
1916
ia64-hp-hpux11.*)
1825
 
;;
 
1917
NGR_R_CONST="#define NGR_R_CONST"
 
1918
;;
 
1919
*-hp-hpux11.*)
 
1920
#
 
1921
# HPUX doesn't have a prototype for getnetgrent_r().
 
1922
#
 
1923
NGR_R_CONST="#define NGR_R_CONST"
 
1924
NGR_R_ARGS="#define NGR_R_ARGS char *buf, int buflen"
 
1925
NGR_R_BAD="#define NGR_R_BAD (0)"
 
1926
NGR_R_COPY="#define NGR_R_COPY buf, buflen"
 
1927
NGR_R_COPY_ARGS="#define NGR_R_COPY_ARGS NGR_R_ARGS"
 
1928
NGR_R_OK="#define NGR_R_OK 1"
 
1929
NGR_R_RETURN="#define NGR_R_RETURN int"
 
1930
;;
 
1931
 
1826
1932
*)
1827
1933
AC_CHECK_FUNC(getnetgrent_r,
1828
1934
AC_TRY_COMPILE(
1829
1935
[
1830
1936
#undef __USE_MISC
1831
1937
#define __USE_MISC
 
1938
#undef _REEENTRANT
 
1939
#define _REEENTRANT
1832
1940
#include <netdb.h>
 
1941
#include <unistd.h>
1833
1942
int getnetgrent_r(char **m, char **u, char **d, char *b, int l) {}
1834
1943
]
1835
1944
,
1836
1945
[return (0);],
1837
1946
[
 
1947
NGR_R_CONST="#define NGR_R_CONST"
1838
1948
NGR_R_ARGS="#define NGR_R_ARGS char *buf, int buflen"
1839
1949
NGR_R_BAD="#define NGR_R_BAD (0)"
1840
1950
NGR_R_COPY="#define NGR_R_COPY buf, buflen"
1847
1957
[
1848
1958
#undef __USE_MISC
1849
1959
#define __USE_MISC
 
1960
#undef _REEENTRANT
 
1961
#define _REEENTRANT
1850
1962
#include <netdb.h>
 
1963
#include <unistd.h>
1851
1964
int getnetgrent_r(char **m, char **u, char **d, char *b, size_t l) {}
1852
1965
]
1853
1966
,
1854
1967
[return (0);],
1855
1968
[
 
1969
NGR_R_CONST="#define NGR_R_CONST"
1856
1970
NGR_R_ARGS="#define NGR_R_ARGS char *buf, size_t buflen"
1857
1971
NGR_R_BAD="#define NGR_R_BAD (0)"
1858
1972
NGR_R_COPY="#define NGR_R_COPY buf, buflen"
1865
1979
[
1866
1980
#undef __USE_MISC
1867
1981
#define __USE_MISC
 
1982
#undef _REEENTRANT
 
1983
#define _REEENTRANT
1868
1984
#include <netdb.h>
1869
 
extern int getnetgrent_r( char **, char **, char **, void **);
 
1985
#include <unistd.h>
 
1986
extern int getnetgrent_r(char **, char **, char **, void **);
1870
1987
]
1871
1988
,
1872
1989
[return (0);],
1873
1990
[
 
1991
NGR_R_CONST="#define NGR_R_CONST"
1874
1992
NGR_R_ARGS="#define NGR_R_ARGS void **buf"
1875
1993
NGR_R_BAD="#define NGR_R_BAD (0)"
1876
1994
NGR_R_COPY="#define NGR_R_COPY buf"
1880
1998
NGR_R_PRIVATE="#define NGR_R_PRIVATE 1"
1881
1999
]
1882
2000
,
1883
 
)
1884
 
)
1885
 
)
1886
 
,
 
2001
AC_TRY_COMPILE(
 
2002
[
 
2003
#undef __USE_MISC
 
2004
#define __USE_MISC
 
2005
#undef _REEENTRANT
 
2006
#define _REEENTRANT
 
2007
#include <netdb.h>
 
2008
#include <unistd.h>
 
2009
extern int getnetgrent_r(const char **, const char **, const char **, void *);
 
2010
]
 
2011
,
 
2012
[return (0);],
 
2013
[
 
2014
NGR_R_CONST="#define NGR_R_CONST const"
 
2015
NGR_R_ARGS="#define NGR_R_ARGS void *buf"
 
2016
NGR_R_BAD="#define NGR_R_BAD (0)"
 
2017
NGR_R_COPY="#define NGR_R_COPY buf"
 
2018
NGR_R_COPY_ARGS="#define NGR_R_COPY_ARGS NGR_R_ARGS"
 
2019
NGR_R_OK="#define NGR_R_OK 1"
 
2020
NGR_R_RETURN="#define NGR_R_RETURN int"
 
2021
NGR_R_PRIVATE="#define NGR_R_PRIVATE 2"
 
2022
]
 
2023
,
 
2024
)
 
2025
)
 
2026
)
 
2027
)
 
2028
,
 
2029
NGR_R_CONST="#define NGR_R_CONST"
1887
2030
NGR_R_ARGS="#define NGR_R_ARGS char *buf, int buflen"
1888
2031
NGR_R_BAD="#define NGR_R_BAD (0)"
1889
2032
NGR_R_COPY="#define NGR_R_COPY buf, buflen"
1892
2035
NGR_R_RETURN="#define NGR_R_RETURN int"
1893
2036
)
1894
2037
esac
 
2038
AC_SUBST(NGR_R_CONST)
1895
2039
AC_SUBST(NGR_R_ARGS)
1896
2040
AC_SUBST(NGR_R_BAD)
1897
2041
AC_SUBST(NGR_R_COPY)
1901
2045
AC_SUBST(NGR_R_PRIVATE)
1902
2046
 
1903
2047
AC_CHECK_FUNC(endnetgrent_r,
 
2048
AC_TRY_COMPILE(
 
2049
[
 
2050
#undef __USE_MISC
 
2051
#define __USE_MISC
 
2052
#undef _REEENTRANT
 
2053
#define _REEENTRANT
 
2054
#include <netdb.h>
 
2055
#include <unistd.h>
 
2056
void endnetgrent_r(void **ptr);
 
2057
]
 
2058
,
 
2059
[return (0);]
 
2060
,
 
2061
[
 
2062
NGR_R_END_RESULT="#define NGR_R_END_RESULT(x)  /* empty */"
 
2063
NGR_R_END_RETURN="#define NGR_R_END_RETURN void"
 
2064
NGR_R_END_ARGS="#define NGR_R_END_ARGS NGR_R_ARGS"
 
2065
]
 
2066
,
 
2067
AC_TRY_COMPILE(
 
2068
[
 
2069
#undef __USE_MISC
 
2070
#define __USE_MISC
 
2071
#undef _REEENTRANT
 
2072
#define _REEENTRANT
 
2073
#include <netdb.h>
 
2074
#include <unistd.h>
 
2075
void endnetgrent_r(void *ptr);
 
2076
]
 
2077
,
 
2078
[return (0);]
 
2079
,
 
2080
[
 
2081
NGR_R_END_RESULT="#define NGR_R_END_RESULT(x)  /* empty */"
 
2082
NGR_R_END_RETURN="#define NGR_R_END_RETURN void"
 
2083
NGR_R_END_ARGS="#define NGR_R_END_ARGS void *buf"
 
2084
]
 
2085
,
 
2086
[
1904
2087
NGR_R_END_RESULT="#define NGR_R_END_RESULT(x)  return (x)"
1905
2088
NGR_R_END_RETURN="#define NGR_R_END_RETURN int"
1906
 
NGR_R_ENT_ARGS="#define NGR_R_ENT_ARGS NGR_R_ARGS"
 
2089
NGR_R_END_ARGS="#define NGR_R_END_ARGS NGR_R_ARGS"
 
2090
]
 
2091
)
 
2092
)
1907
2093
,
1908
2094
NGR_R_END_RESULT="#define NGR_R_END_RESULT(x)  /*empty*/"
1909
2095
NGR_R_END_RETURN="#define NGR_R_END_RETURN void"
1910
 
NGR_R_ENT_ARGS="#undef NGR_R_ENT_ARGS /*empty*/"
 
2096
NGR_R_END_ARGS="#undef NGR_R_END_ARGS /*empty*/"
1911
2097
AC_DEFINE(NEED_ENDNETGRENT_R)
1912
2098
)
1913
2099
AC_SUBST(NGR_R_END_RESULT)
1914
2100
AC_SUBST(NGR_R_END_RETURN)
1915
 
AC_SUBST(NGR_R_ENT_ARGS)
 
2101
AC_SUBST(NGR_R_END_ARGS)
1916
2102
 
1917
2103
AC_CHECK_FUNC(setnetgrent_r,
1918
2104
[
1919
2105
case "$host" in
1920
2106
*bsdi*)
 
2107
        #
 
2108
        # No prototype
 
2109
        #
1921
2110
        NGR_R_SET_RESULT="#undef NGR_R_SET_RESULT /*empty*/"
1922
2111
        NGR_R_SET_RETURN="#define NGR_R_SET_RETURN void"
 
2112
        NGR_R_SET_ARGS="#define NGR_R_SET_ARGS NGR_R_ARGS"
 
2113
        NGR_R_SET_CONST="#define NGR_R_SET_CONST"
1923
2114
        ;;
1924
 
*)
 
2115
*hpux*)
 
2116
        #
 
2117
        # No prototype
 
2118
        #
1925
2119
        NGR_R_SET_RESULT="#define NGR_R_SET_RESULT NGR_R_OK"
1926
2120
        NGR_R_SET_RETURN="#define NGR_R_SET_RETURN int"
 
2121
        NGR_R_SET_ARGS="#undef NGR_R_SET_ARGS /* empty */"
 
2122
        NGR_R_SET_CONST="#define NGR_R_SET_CONST"
1927
2123
        ;;
 
2124
*)
 
2125
AC_TRY_COMPILE(
 
2126
[
 
2127
#undef __USE_MISC
 
2128
#define __USE_MISC
 
2129
#undef _REEENTRANT
 
2130
#define _REEENTRANT
 
2131
#include <netdb.h>
 
2132
#include <unistd.h>
 
2133
void setnetgrent_r(void **ptr);
 
2134
]
 
2135
,
 
2136
[return (0);]
 
2137
,
 
2138
[
 
2139
NGR_R_SET_RESULT="#undef NGR_R_SET_RESULT /* empty */"
 
2140
NGR_R_SET_RETURN="#define NGR_R_SET_RETURN void"
 
2141
NGR_R_SET_ARGS="#define NGR_R_SET_ARGS void **buf"
 
2142
NGR_R_SET_CONST="#define NGR_R_SET_CONST"
 
2143
]
 
2144
,
 
2145
AC_TRY_COMPILE(
 
2146
[
 
2147
#undef __USE_MISC
 
2148
#define __USE_MISC
 
2149
#undef _REEENTRANT
 
2150
#define _REEENTRANT
 
2151
#include <netdb.h>
 
2152
#include <unistd.h>
 
2153
extern int setnetgrent_r(char *, void **);
 
2154
]
 
2155
,
 
2156
[return (0);]
 
2157
,
 
2158
[
 
2159
NGR_R_SET_RESULT="#define NGR_R_SET_RESULT NGR_R_OK"
 
2160
NGR_R_SET_RETURN="#define NGR_R_SET_RETURN int"
 
2161
NGR_R_SET_ARGS="#define NGR_R_SET_ARGS void **buf"
 
2162
NGR_R_SET_CONST="#define NGR_R_SET_CONST"
 
2163
]
 
2164
,
 
2165
[
 
2166
NGR_R_SET_RESULT="#define NGR_R_SET_RESULT NGR_R_OK"
 
2167
NGR_R_SET_RETURN="#define NGR_R_SET_RETURN int"
 
2168
NGR_R_SET_ARGS="#undef NGR_R_SET_ARGS"
 
2169
NGR_R_SET_CONST="#define NGR_R_SET_CONST const"
 
2170
]
 
2171
))
 
2172
;;
1928
2173
esac
1929
2174
]
1930
2175
,
1931
2176
NGR_R_SET_RESULT="#undef NGR_R_SET_RESULT /*empty*/"
1932
2177
NGR_R_SET_RETURN="#define NGR_R_SET_RETURN void"
 
2178
NGR_R_SET_ARGS="#undef NGR_R_SET_ARGS"
 
2179
NGR_R_SET_CONST="#define NGR_R_SET_CONST const"
1933
2180
)
 
2181
 
1934
2182
AC_SUBST(NGR_R_SET_RESULT)
1935
2183
AC_SUBST(NGR_R_SET_RETURN)
 
2184
AC_SUBST(NGR_R_SET_ARGS)
 
2185
AC_SUBST(NGR_R_SET_CONST)
1936
2186
 
1937
2187
AC_CHECK_FUNC(innetgr_r,,AC_DEFINE(NEED_INNETGR_R))
1938
2188
 
1960
2210
PROTO_R_OK="#define PROTO_R_OK pptr"
1961
2211
PROTO_R_SETANSWER="#undef PROTO_R_SETANSWER"
1962
2212
PROTO_R_RETURN="#define PROTO_R_RETURN struct protoent *"
 
2213
PROTOENT_DATA="#undef PROTOENT_DATA"
1963
2214
]
1964
2215
,
1965
2216
AC_TRY_COMPILE(
1981
2232
PROTO_R_OK="#define PROTO_R_OK 0"
1982
2233
PROTO_R_SETANSWER="#define PROTO_R_SETANSWER 1"
1983
2234
PROTO_R_RETURN="#define PROTO_R_RETURN int"
1984
 
]
1985
 
,
 
2235
PROTOENT_DATA="#undef PROTOENT_DATA"
 
2236
]
 
2237
,
 
2238
AC_TRY_COMPILE(
 
2239
[
 
2240
#undef __USE_MISC
 
2241
#define __USE_MISC
 
2242
#include <netdb.h>
 
2243
int getprotoent_r (struct protoent *, struct protoent_data *prot_data);
 
2244
 
 
2245
]
 
2246
,
 
2247
[return (0);]
 
2248
,
 
2249
[
 
2250
PROTO_R_ARGS="#define PROTO_R_ARGS struct protoent_data *prot_data"
 
2251
PROTO_R_BAD="#define PROTO_R_BAD (-1)"
 
2252
PROTO_R_COPY="#define PROTO_R_COPY prot_data"
 
2253
PROTO_R_COPY_ARGS="#define PROTO_R_COPY_ARGS struct protoent_data *pdptr"
 
2254
PROTO_R_OK="#define PROTO_R_OK 0"
 
2255
PROTO_R_SETANSWER="#undef PROTO_R_SETANSWER"
 
2256
PROTO_R_RETURN="#define PROTO_R_RETURN int"
 
2257
PROTOENT_DATA="#define PROTOENT_DATA 1"
 
2258
]
 
2259
,
 
2260
)
1986
2261
)
1987
2262
)
1988
2263
,
1993
2268
PROTO_R_OK="#define PROTO_R_OK pptr"
1994
2269
PROTO_R_SETANSWER="#undef PROTO_R_SETANSWER"
1995
2270
PROTO_R_RETURN="#define PROTO_R_RETURN struct protoent *"
 
2271
PROTOENT_DATA="#undef PROTOENT_DATA"
1996
2272
)
 
2273
;;
1997
2274
esac
1998
2275
AC_SUBST(PROTO_R_ARGS)
1999
2276
AC_SUBST(PROTO_R_BAD)
2002
2279
AC_SUBST(PROTO_R_OK)
2003
2280
AC_SUBST(PROTO_R_SETANSWER)
2004
2281
AC_SUBST(PROTO_R_RETURN)
 
2282
AC_SUBST(PROTOENT_DATA)
2005
2283
 
2006
2284
case $host in
2007
2285
ia64-hp-hpux11.*)
2022
2300
PROTO_R_END_RESULT="#define PROTO_R_END_RESULT(x) /*empty*/"
2023
2301
PROTO_R_END_RETURN="#define PROTO_R_END_RETURN void"
2024
2302
PROTO_R_ENT_ARGS="#undef PROTO_R_ENT_ARGS"
2025
 
]
2026
 
,
 
2303
PROTO_R_ENT_UNUSED="#undef PROTO_R_ENT_UNUSED"
 
2304
]
 
2305
,
 
2306
AC_TRY_COMPILE(
 
2307
[
 
2308
#undef _REENTRANT
 
2309
#define _REENTRANT
 
2310
#undef __USE_MISC
 
2311
#define __USE_MISC
 
2312
#include <netdb.h>
 
2313
void endprotoent_r(struct protoent_data *);
 
2314
]
 
2315
,,
 
2316
[
 
2317
PROTO_R_END_RESULT="#define PROTO_R_END_RESULT(x) /*empty*/"
 
2318
PROTO_R_END_RETURN="#define PROTO_R_END_RETURN void"
 
2319
PROTO_R_ENT_ARGS="#define PROTO_R_ENT_ARGS struct protoent_data *proto_data"
 
2320
PROTO_R_ENT_UNUSED="#define PROTO_R_ENT_UNUSED UNUSED(proto_data)"
 
2321
]
 
2322
,
 
2323
AC_TRY_COMPILE(
 
2324
[
 
2325
#undef _REENTRANT
 
2326
#define _REENTRANT
 
2327
#undef __USE_MISC
 
2328
#define __USE_MISC
 
2329
#include <netdb.h>
 
2330
int endprotoent_r(struct protoent_data *);
 
2331
]
 
2332
,,
 
2333
[
 
2334
PROTO_R_END_RESULT="#define PROTO_R_END_RESULT(x) return(0)"
 
2335
PROTO_R_END_RETURN="#define PROTO_R_END_RETURN int"
 
2336
PROTO_R_ENT_ARGS="#define PROTO_R_ENT_ARGS struct protoent_data *proto_data"
 
2337
PROTO_R_ENT_UNUSED="#define PROTO_R_ENT_UNUSED UNUSED(proto_data)"
 
2338
]
 
2339
,
 
2340
)
 
2341
)
2027
2342
)
2028
2343
,
2029
2344
PROTO_R_END_RESULT="#define PROTO_R_END_RESULT(x) /*empty*/"
2030
2345
PROTO_R_END_RETURN="#define PROTO_R_END_RETURN void"
2031
2346
PROTO_R_ENT_ARGS="#undef PROTO_R_ENT_ARGS /*empty*/"
 
2347
PROTO_R_ENT_UNUSED="#undef PROTO_R_ENT_UNUSED"
2032
2348
)
2033
2349
esac
2034
2350
AC_SUBST(PROTO_R_END_RESULT)
2035
2351
AC_SUBST(PROTO_R_END_RETURN)
2036
2352
AC_SUBST(PROTO_R_ENT_ARGS)
 
2353
AC_SUBST(PROTO_R_ENT_UNUSED)
2037
2354
 
2038
2355
case $host in
2039
2356
ia64-hp-hpux11.*)
2052
2369
PROTO_R_SET_RESULT="#undef PROTO_R_SET_RESULT"
2053
2370
PROTO_R_SET_RETURN="#define PROTO_R_SET_RETURN void"
2054
2371
,
 
2372
AC_TRY_COMPILE(
 
2373
[
 
2374
#undef _REENTRANT
 
2375
#define _REENTRANT
 
2376
#undef __USE_MISC
 
2377
#define __USE_MISC
 
2378
#include <netdb.h>
 
2379
int setprotoent_r (int, struct protoent_data *);
 
2380
],[],
 
2381
PROTO_R_SET_RESULT="#define PROTO_R_SET_RESULT (0)"
 
2382
PROTO_R_SET_RETURN="#define PROTO_R_SET_RETURN int"
 
2383
,
 
2384
)
2055
2385
)
2056
2386
,
2057
2387
PROTO_R_SET_RESULT="#undef PROTO_R_SET_RESULT"
2186
2516
SERV_R_RETURN="#define SERV_R_RETURN int"
2187
2517
]
2188
2518
,
 
2519
AC_TRY_COMPILE([
 
2520
#undef __USE_MISC
 
2521
#define __USE_MISC
 
2522
#include <netdb.h>
 
2523
int
 
2524
getservent_r (struct servent *, struct servent_data *serv_data);
 
2525
],[return (0);],
 
2526
[
 
2527
SERV_R_ARGS="#define SERV_R_ARGS struct servent_data *serv_data"
 
2528
SERV_R_BAD="#define SERV_R_BAD (-1)"
 
2529
SERV_R_COPY="#define SERV_R_COPY serv_data"
 
2530
SERV_R_COPY_ARGS="#define SERV_R_COPY_ARGS struct servent_data *sdptr"
 
2531
SERV_R_OK="#define SERV_R_OK (0)"
 
2532
SERV_R_SETANSWER="#undef SERV_R_SETANSWER"
 
2533
SERV_R_RETURN="#define SERV_R_RETURN int"
 
2534
SERVENT_DATA="#define SERVENT_DATA 1"
 
2535
]
 
2536
,
 
2537
)
2189
2538
)
2190
2539
)
2191
2540
,
2205
2554
AC_SUBST(SERV_R_OK)
2206
2555
AC_SUBST(SERV_R_SETANSWER)
2207
2556
AC_SUBST(SERV_R_RETURN)
 
2557
AC_SUBST(SERVENT_DATA)
2208
2558
 
2209
2559
case $host in
2210
2560
ia64-hp-hpux11.*)
2226
2576
SERV_R_END_RESULT="#define SERV_R_END_RESULT(x) /*empty*/"
2227
2577
SERV_R_END_RETURN="#define SERV_R_END_RETURN void "
2228
2578
SERV_R_ENT_ARGS="#undef SERV_R_ENT_ARGS /*empty*/"
2229
 
]
2230
 
,
 
2579
SERV_R_ENT_UNUSED="#undef SERV_R_ENT_UNUSED /*empty*/"
 
2580
]
 
2581
,
 
2582
AC_TRY_COMPILE(
 
2583
[
 
2584
#undef _REENTRANT
 
2585
#define _REENTRANT
 
2586
#undef __USE_MISC
 
2587
#define __USE_MISC
 
2588
#include <netdb.h>
 
2589
void endservent_r(struct servent_data *serv_data);
 
2590
]
 
2591
,
 
2592
,
 
2593
[
 
2594
SERV_R_END_RESULT="#define SERV_R_END_RESULT(x) /*empty*/"
 
2595
SERV_R_END_RETURN="#define SERV_R_END_RETURN void "
 
2596
SERV_R_ENT_ARGS="#define SERV_R_ENT_ARGS struct servent_data *serv_data"
 
2597
SERV_R_ENT_UNUSED="#define SERV_R_ENT_UNUSED UNUSED(serv_data)"
 
2598
]
 
2599
,
 
2600
AC_TRY_COMPILE(
 
2601
[
 
2602
#undef _REENTRANT
 
2603
#define _REENTRANT
 
2604
#undef __USE_MISC
 
2605
#define __USE_MISC
 
2606
#include <netdb.h>
 
2607
int endservent_r(struct servent_data *serv_data);
 
2608
]
 
2609
,
 
2610
,
 
2611
[
 
2612
SERV_R_END_RESULT="#define SERV_R_END_RESULT(x) return(x)"
 
2613
SERV_R_END_RETURN="#define SERV_R_END_RETURN int "
 
2614
SERV_R_ENT_ARGS="#define SERV_R_ENT_ARGS struct servent_data *serv_data"
 
2615
SERV_R_ENT_UNUSED="#define SERV_R_ENT_UNUSED UNUSED(serv_data)"
 
2616
]
 
2617
,
 
2618
)
 
2619
)
2231
2620
)
2232
2621
,
2233
2622
SERV_R_END_RESULT="#define SERV_R_END_RESULT(x) /*empty*/"
2234
2623
SERV_R_END_RETURN="#define SERV_R_END_RETURN void "
2235
2624
SERV_R_ENT_ARGS="#undef SERV_R_ENT_ARGS /*empty*/"
 
2625
SERV_R_ENT_UNUSED="#undef SERV_R_ENT_UNUSED /*empty*/"
2236
2626
)
2237
2627
esac
2238
2628
AC_SUBST(SERV_R_END_RESULT)
2239
2629
AC_SUBST(SERV_R_END_RETURN)
2240
2630
AC_SUBST(SERV_R_ENT_ARGS)
 
2631
AC_SUBST(SERV_R_ENT_UNUSED)
2241
2632
 
2242
2633
case $host in
2243
2634
ia64-hp-hpux11.*)
2251
2642
#undef __USE_MISC
2252
2643
#define __USE_MISC
2253
2644
#include <netdb.h>
2254
 
void            setservent_r(int);
 
2645
void setservent_r(int);
2255
2646
]
2256
2647
,,
2257
2648
[
2259
2650
SERV_R_SET_RETURN="#define SERV_R_SET_RETURN void"
2260
2651
]
2261
2652
,
 
2653
AC_TRY_COMPILE(
 
2654
[
 
2655
#undef _REENTRANT
 
2656
#define _REENTRANT
 
2657
#undef __USE_MISC
 
2658
#define __USE_MISC
 
2659
#include <netdb.h>
 
2660
int setservent_r(int, struct servent_data *);
 
2661
]
 
2662
,,
 
2663
[
 
2664
SERV_R_SET_RESULT="#define SERV_R_SET_RESULT (0)"
 
2665
SERV_R_SET_RETURN="#define SERV_R_SET_RETURN int"
 
2666
]
 
2667
,
 
2668
)
2262
2669
)
2263
2670
,
2264
2671
SERV_R_SET_RESULT="#undef SERV_R_SET_RESULT"
2345
2752
                hack_shutup_pthreadmutexinit=yes
2346
2753
                hack_shutup_in6addr_init_macros=yes
2347
2754
                ;;
 
2755
        *-aix5.[[23]].*)
 
2756
                hack_shutup_in6addr_init_macros=yes
 
2757
                ;;
2348
2758
        *-bsdi3.1*)
2349
2759
                hack_shutup_sputaux=yes
2350
2760
                ;;
2368
2778
        *-solaris2.9)
2369
2779
                hack_shutup_in6addr_init_macros=yes
2370
2780
                ;;
 
2781
        *-solaris2.1[0-9])
 
2782
                hack_shutup_in6addr_init_macros=yes
 
2783
                ;;
2371
2784
esac
2372
2785
 
2373
2786
case "$hack_shutup_pthreadmutexinit" in
2409
2822
 
2410
2823
case "$hack_shutup_in6addr_init_macros" in
2411
2824
        yes)
2412
 
                AC_DEFINE(BROKEN_IN6ADDR_INIT_MACROS)
 
2825
                AC_DEFINE(BROKEN_IN6ADDR_INIT_MACROS, 1, [Defined if IN6ADDR_ANY_INIT and IN6ADDR_LOOPBACK_INIT need to be redefined.] )
2413
2826
                ;;
2414
2827
esac
2415
2828
 
2450
2863
        port/Makefile
2451
2864
        ${PORT_DIR}/Makefile
2452
2865
        ${PORT_INCLUDE}/Makefile
 
2866
        include/isc/platform.h
2453
2867
)
2454
2868
 
2455
2869
# Tell Emacs to edit this file in shell mode.