xref: /freebsd/contrib/ntp/configure (revision 23f282aa31e9b6fceacd449020e936e98d6f2298)
1#! /bin/sh
2
3# Guess values for system-dependent variables and create Makefiles.
4# Generated automatically using autoconf version 2.13
5# Copyright (C) 1992, 93, 94, 95, 96 Free Software Foundation, Inc.
6#
7# This configure script is free software; the Free Software Foundation
8# gives unlimited permission to copy, distribute and modify it.
9
10# Defaults:
11ac_help=
12ac_default_prefix=/usr/local
13# Any additions from configure.in:
14ac_help="$ac_help
15  --disable-dependency-tracking Speeds up one-time builds
16  --enable-dependency-tracking  Do not reject slow dependency extractors"
17ac_help="$ac_help
18  --enable-debugging      + include debugging code"
19ac_help="$ac_help
20  --enable-dst-minutes=60 + minutes per DST adjustment"
21ac_help="$ac_help
22  --enable-md5            + include support for MD5 keys"
23ac_help="$ac_help
24  --enable-BANCOMM        - Datum/Bancomm bc635/VME interface"
25ac_help="$ac_help
26  --enable-GPSVME         - TrueTime GPS receiver/VME interface"
27ac_help="$ac_help
28  --enable-SHM            - SHM clock attached thru shared memory"
29ac_help="$ac_help
30  --enable-all-clocks     + include all suitable non-PARSE clocks:"
31ac_help="$ac_help
32  --enable-ACTS           + ACTS modem service"
33ac_help="$ac_help
34  --enable-ARBITER        + Arbiter 1088A/B GPS receiver"
35ac_help="$ac_help
36  --enable-ARCRON-MSF     + Arcron MSF receiver"
37ac_help="$ac_help
38  --enable-AS2201         + Austron 2200A/2201A GPS receiver"
39ac_help="$ac_help
40  --enable-ATOM           + PPS interface"
41ac_help="$ac_help
42  --enable-CHU            - CHU modem/decoder"
43ac_help="$ac_help
44  --enable-AUDIO-CHU      s CHU audio/decoder"
45ac_help="$ac_help
46  --enable-DATUM          s Datum Programmable Time System"
47ac_help="$ac_help
48  --enable-FG             + Forum Graphic GPS"
49ac_help="$ac_help
50  --enable-HEATH          s Heath GC-1000 WWV/WWVH receiver"
51ac_help="$ac_help
52  --enable-HPGPS          + HP 58503A GPS receiver"
53ac_help="$ac_help
54  --enable-IRIG           s Sun IRIG audio decoder"
55ac_help="$ac_help
56  --enable-LEITCH         + Leitch CSD 5300 Master Clock System Driver"
57ac_help="$ac_help
58  --enable-LOCAL-CLOCK    + local clock reference"
59ac_help="$ac_help
60  --enable-MSFEES         + EES M201 MSF receiver"
61ac_help="$ac_help
62  --enable-MX4200         s Magnavox MX4200 GPS receiver"
63ac_help="$ac_help
64  --enable-NMEA           + NMEA GPS receiver"
65ac_help="$ac_help
66  --enable-ONCORE         + Motorola VP/UT Oncore GPS receiver"
67ac_help="$ac_help
68  --enable-PALISADE       + Palisade clock"
69ac_help="$ac_help
70  --enable-PST            + PST/Traconex 1020 WWV/WWVH receiver"
71ac_help="$ac_help
72  --enable-JUPITER        s Rockwell Jupiter GPS receiver"
73ac_help="$ac_help
74  --enable-PTBACTS        s PTB modem service"
75ac_help="$ac_help
76  --enable-TPRO           s KSI/Odetics TPRO/S GPS receiver/IRIG interface"
77ac_help="$ac_help
78  --enable-TRAK           + TRAK 8810 GPS receiver"
79ac_help="$ac_help
80  --enable-CHRONOLOG      + Chrono-log K-series WWVB receiver"
81ac_help="$ac_help
82  --enable-DUMBCLOCK      + Dumb generic hh:mm:ss local clock"
83ac_help="$ac_help
84  --enable-PCF            + Conrad parallel port radio clock"
85ac_help="$ac_help
86  --enable-SPECTRACOM     + Spectracom 8170/Netclock/2 WWVB receiver"
87ac_help="$ac_help
88  --enable-TRUETIME       s Kinemetrics/TrueTime receivers"
89ac_help="$ac_help
90  --enable-ULINK          + Ultralink WWVB receiver"
91ac_help="$ac_help
92  --enable-WWV            + WWV Audio receiver"
93ac_help="$ac_help
94  --enable-USNO           s USNO modem service"
95ac_help="$ac_help
96  --enable-parse-clocks   - include all suitable PARSE clocks:"
97ac_help="$ac_help
98  --enable-COMPUTIME      s Diem Computime Radio Clock"
99ac_help="$ac_help
100  --enable-DCF7000        s ELV/DCF7000 clock"
101ac_help="$ac_help
102  --enable-HOPF6021       s HOPF 6021 clock"
103ac_help="$ac_help
104  --enable-MEINBERG       s Meinberg clocks"
105ac_help="$ac_help
106  --enable-RAWDCF         s DCF77 raw time code"
107ac_help="$ac_help
108  --enable-RCC8000        s RCC 8000 clock"
109ac_help="$ac_help
110  --enable-SCHMID         s Schmid DCF77 clock"
111ac_help="$ac_help
112  --enable-TRIMTAIP       s Trimble GPS receiver/TAIP protocol"
113ac_help="$ac_help
114  --enable-TRIMTSIP       s Trimble GPS receiver/TSIP protocol"
115ac_help="$ac_help
116  --enable-WHARTON        s WHARTON 400A Series clock"
117ac_help="$ac_help
118  --enable-VARITEXT       s VARITEXT clock"
119ac_help="$ac_help
120  --enable-kmem           s read /dev/kmem for tick and/or tickadj"
121ac_help="$ac_help
122  --enable-accurate-adjtime
123                          s the adjtime() call is accurate"
124ac_help="$ac_help
125  --enable-tick=VALUE     s force a value for 'tick'"
126ac_help="$ac_help
127  --enable-tickadj=VALUE  s force a value for 'tickadj'"
128ac_help="$ac_help
129  --enable-udp-wildcard   s use UDP wildcard delivery"
130ac_help="$ac_help
131  --enable-slew-always    s always slew the time"
132ac_help="$ac_help
133  --enable-step-slew      s step and slew the time"
134ac_help="$ac_help
135  --enable-ntpdate-step   s if ntpdate should step the time"
136ac_help="$ac_help
137  --enable-hourly-todr-sync
138                          s if we should sync TODR hourly"
139ac_help="$ac_help
140  --enable-kernel-fll-bug s if we should avoid a kernel FLL bug"
141
142# Initialize some variables set by options.
143# The variables have the same names as the options, with
144# dashes changed to underlines.
145build=NONE
146cache_file=./config.cache
147exec_prefix=NONE
148host=NONE
149no_create=
150nonopt=NONE
151no_recursion=
152prefix=NONE
153program_prefix=NONE
154program_suffix=NONE
155program_transform_name=s,x,x,
156silent=
157site=
158srcdir=
159target=NONE
160verbose=
161x_includes=NONE
162x_libraries=NONE
163bindir='${exec_prefix}/bin'
164sbindir='${exec_prefix}/sbin'
165libexecdir='${exec_prefix}/libexec'
166datadir='${prefix}/share'
167sysconfdir='${prefix}/etc'
168sharedstatedir='${prefix}/com'
169localstatedir='${prefix}/var'
170libdir='${exec_prefix}/lib'
171includedir='${prefix}/include'
172oldincludedir='/usr/include'
173infodir='${prefix}/info'
174mandir='${prefix}/man'
175
176# Initialize some other variables.
177subdirs=
178MFLAGS= MAKEFLAGS=
179SHELL=${CONFIG_SHELL-/bin/sh}
180# Maximum number of lines to put in a shell here document.
181ac_max_here_lines=12
182
183ac_prev=
184for ac_option
185do
186
187  # If the previous option needs an argument, assign it.
188  if test -n "$ac_prev"; then
189    eval "$ac_prev=\$ac_option"
190    ac_prev=
191    continue
192  fi
193
194  case "$ac_option" in
195  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
196  *) ac_optarg= ;;
197  esac
198
199  # Accept the important Cygnus configure options, so we can diagnose typos.
200
201  case "$ac_option" in
202
203  -bindir | --bindir | --bindi | --bind | --bin | --bi)
204    ac_prev=bindir ;;
205  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
206    bindir="$ac_optarg" ;;
207
208  -build | --build | --buil | --bui | --bu)
209    ac_prev=build ;;
210  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
211    build="$ac_optarg" ;;
212
213  -cache-file | --cache-file | --cache-fil | --cache-fi \
214  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
215    ac_prev=cache_file ;;
216  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
217  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
218    cache_file="$ac_optarg" ;;
219
220  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
221    ac_prev=datadir ;;
222  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
223  | --da=*)
224    datadir="$ac_optarg" ;;
225
226  -disable-* | --disable-*)
227    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
228    # Reject names that are not valid shell variable names.
229    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
230      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
231    fi
232    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
233    eval "enable_${ac_feature}=no" ;;
234
235  -enable-* | --enable-*)
236    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
237    # Reject names that are not valid shell variable names.
238    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
239      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
240    fi
241    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
242    case "$ac_option" in
243      *=*) ;;
244      *) ac_optarg=yes ;;
245    esac
246    eval "enable_${ac_feature}='$ac_optarg'" ;;
247
248  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
249  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
250  | --exec | --exe | --ex)
251    ac_prev=exec_prefix ;;
252  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
253  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
254  | --exec=* | --exe=* | --ex=*)
255    exec_prefix="$ac_optarg" ;;
256
257  -gas | --gas | --ga | --g)
258    # Obsolete; use --with-gas.
259    with_gas=yes ;;
260
261  -help | --help | --hel | --he)
262    # Omit some internal or obsolete options to make the list less imposing.
263    # This message is too long to be a string in the A/UX 3.1 sh.
264    cat << EOF
265Usage: configure [options] [host]
266Options: [defaults in brackets after descriptions]
267Configuration:
268  --cache-file=FILE       cache test results in FILE
269  --help                  print this message
270  --no-create             do not create output files
271  --quiet, --silent       do not print \`checking...' messages
272  --version               print the version of autoconf that created configure
273Directory and file names:
274  --prefix=PREFIX         install architecture-independent files in PREFIX
275                          [$ac_default_prefix]
276  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
277                          [same as prefix]
278  --bindir=DIR            user executables in DIR [EPREFIX/bin]
279  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
280  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
281  --datadir=DIR           read-only architecture-independent data in DIR
282                          [PREFIX/share]
283  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
284  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
285                          [PREFIX/com]
286  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
287  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
288  --includedir=DIR        C header files in DIR [PREFIX/include]
289  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
290  --infodir=DIR           info documentation in DIR [PREFIX/info]
291  --mandir=DIR            man documentation in DIR [PREFIX/man]
292  --srcdir=DIR            find the sources in DIR [configure dir or ..]
293  --program-prefix=PREFIX prepend PREFIX to installed program names
294  --program-suffix=SUFFIX append SUFFIX to installed program names
295  --program-transform-name=PROGRAM
296                          run sed PROGRAM on installed program names
297EOF
298    cat << EOF
299Host type:
300  --build=BUILD           configure for building on BUILD [BUILD=HOST]
301  --host=HOST             configure for HOST [guessed]
302  --target=TARGET         configure for TARGET [TARGET=HOST]
303Features and packages:
304  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
305  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
306  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
307  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
308  --x-includes=DIR        X include files are in DIR
309  --x-libraries=DIR       X library files are in DIR
310EOF
311    if test -n "$ac_help"; then
312      echo "--enable and --with options recognized:$ac_help"
313    fi
314    exit 0 ;;
315
316  -host | --host | --hos | --ho)
317    ac_prev=host ;;
318  -host=* | --host=* | --hos=* | --ho=*)
319    host="$ac_optarg" ;;
320
321  -includedir | --includedir | --includedi | --included | --include \
322  | --includ | --inclu | --incl | --inc)
323    ac_prev=includedir ;;
324  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
325  | --includ=* | --inclu=* | --incl=* | --inc=*)
326    includedir="$ac_optarg" ;;
327
328  -infodir | --infodir | --infodi | --infod | --info | --inf)
329    ac_prev=infodir ;;
330  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
331    infodir="$ac_optarg" ;;
332
333  -libdir | --libdir | --libdi | --libd)
334    ac_prev=libdir ;;
335  -libdir=* | --libdir=* | --libdi=* | --libd=*)
336    libdir="$ac_optarg" ;;
337
338  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
339  | --libexe | --libex | --libe)
340    ac_prev=libexecdir ;;
341  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
342  | --libexe=* | --libex=* | --libe=*)
343    libexecdir="$ac_optarg" ;;
344
345  -localstatedir | --localstatedir | --localstatedi | --localstated \
346  | --localstate | --localstat | --localsta | --localst \
347  | --locals | --local | --loca | --loc | --lo)
348    ac_prev=localstatedir ;;
349  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
350  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
351  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
352    localstatedir="$ac_optarg" ;;
353
354  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
355    ac_prev=mandir ;;
356  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
357    mandir="$ac_optarg" ;;
358
359  -nfp | --nfp | --nf)
360    # Obsolete; use --without-fp.
361    with_fp=no ;;
362
363  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
364  | --no-cr | --no-c)
365    no_create=yes ;;
366
367  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
368  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
369    no_recursion=yes ;;
370
371  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
372  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
373  | --oldin | --oldi | --old | --ol | --o)
374    ac_prev=oldincludedir ;;
375  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
376  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
377  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
378    oldincludedir="$ac_optarg" ;;
379
380  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
381    ac_prev=prefix ;;
382  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
383    prefix="$ac_optarg" ;;
384
385  -program-prefix | --program-prefix | --program-prefi | --program-pref \
386  | --program-pre | --program-pr | --program-p)
387    ac_prev=program_prefix ;;
388  -program-prefix=* | --program-prefix=* | --program-prefi=* \
389  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
390    program_prefix="$ac_optarg" ;;
391
392  -program-suffix | --program-suffix | --program-suffi | --program-suff \
393  | --program-suf | --program-su | --program-s)
394    ac_prev=program_suffix ;;
395  -program-suffix=* | --program-suffix=* | --program-suffi=* \
396  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
397    program_suffix="$ac_optarg" ;;
398
399  -program-transform-name | --program-transform-name \
400  | --program-transform-nam | --program-transform-na \
401  | --program-transform-n | --program-transform- \
402  | --program-transform | --program-transfor \
403  | --program-transfo | --program-transf \
404  | --program-trans | --program-tran \
405  | --progr-tra | --program-tr | --program-t)
406    ac_prev=program_transform_name ;;
407  -program-transform-name=* | --program-transform-name=* \
408  | --program-transform-nam=* | --program-transform-na=* \
409  | --program-transform-n=* | --program-transform-=* \
410  | --program-transform=* | --program-transfor=* \
411  | --program-transfo=* | --program-transf=* \
412  | --program-trans=* | --program-tran=* \
413  | --progr-tra=* | --program-tr=* | --program-t=*)
414    program_transform_name="$ac_optarg" ;;
415
416  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
417  | -silent | --silent | --silen | --sile | --sil)
418    silent=yes ;;
419
420  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
421    ac_prev=sbindir ;;
422  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
423  | --sbi=* | --sb=*)
424    sbindir="$ac_optarg" ;;
425
426  -sharedstatedir | --sharedstatedir | --sharedstatedi \
427  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
428  | --sharedst | --shareds | --shared | --share | --shar \
429  | --sha | --sh)
430    ac_prev=sharedstatedir ;;
431  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
432  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
433  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
434  | --sha=* | --sh=*)
435    sharedstatedir="$ac_optarg" ;;
436
437  -site | --site | --sit)
438    ac_prev=site ;;
439  -site=* | --site=* | --sit=*)
440    site="$ac_optarg" ;;
441
442  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
443    ac_prev=srcdir ;;
444  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
445    srcdir="$ac_optarg" ;;
446
447  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
448  | --syscon | --sysco | --sysc | --sys | --sy)
449    ac_prev=sysconfdir ;;
450  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
451  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
452    sysconfdir="$ac_optarg" ;;
453
454  -target | --target | --targe | --targ | --tar | --ta | --t)
455    ac_prev=target ;;
456  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
457    target="$ac_optarg" ;;
458
459  -v | -verbose | --verbose | --verbos | --verbo | --verb)
460    verbose=yes ;;
461
462  -version | --version | --versio | --versi | --vers)
463    echo "configure generated by autoconf version 2.13"
464    exit 0 ;;
465
466  -with-* | --with-*)
467    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
468    # Reject names that are not valid shell variable names.
469    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
470      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
471    fi
472    ac_package=`echo $ac_package| sed 's/-/_/g'`
473    case "$ac_option" in
474      *=*) ;;
475      *) ac_optarg=yes ;;
476    esac
477    eval "with_${ac_package}='$ac_optarg'" ;;
478
479  -without-* | --without-*)
480    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
481    # Reject names that are not valid shell variable names.
482    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
483      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
484    fi
485    ac_package=`echo $ac_package| sed 's/-/_/g'`
486    eval "with_${ac_package}=no" ;;
487
488  --x)
489    # Obsolete; use --with-x.
490    with_x=yes ;;
491
492  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
493  | --x-incl | --x-inc | --x-in | --x-i)
494    ac_prev=x_includes ;;
495  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
496  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
497    x_includes="$ac_optarg" ;;
498
499  -x-libraries | --x-libraries | --x-librarie | --x-librari \
500  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
501    ac_prev=x_libraries ;;
502  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
503  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
504    x_libraries="$ac_optarg" ;;
505
506  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
507    ;;
508
509  *)
510    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
511      echo "configure: warning: $ac_option: invalid host type" 1>&2
512    fi
513    if test "x$nonopt" != xNONE; then
514      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
515    fi
516    nonopt="$ac_option"
517    ;;
518
519  esac
520done
521
522if test -n "$ac_prev"; then
523  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
524fi
525
526trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
527
528# File descriptor usage:
529# 0 standard input
530# 1 file creation
531# 2 errors and warnings
532# 3 some systems may open it to /dev/tty
533# 4 used on the Kubota Titan
534# 6 checking for... messages and results
535# 5 compiler messages saved in config.log
536if test "$silent" = yes; then
537  exec 6>/dev/null
538else
539  exec 6>&1
540fi
541exec 5>./config.log
542
543echo "\
544This file contains any messages produced by compilers while
545running configure, to aid debugging if configure makes a mistake.
546" 1>&5
547
548# Strip out --no-create and --no-recursion so they do not pile up.
549# Also quote any args containing shell metacharacters.
550ac_configure_args=
551for ac_arg
552do
553  case "$ac_arg" in
554  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
555  | --no-cr | --no-c) ;;
556  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
557  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
558  *" "*|*"	"*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
559  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
560  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
561  esac
562done
563
564# NLS nuisances.
565# Only set these to C if already set.  These must not be set unconditionally
566# because not all systems understand e.g. LANG=C (notably SCO).
567# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
568# Non-C LC_CTYPE values break the ctype check.
569if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
570if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
571if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
572if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
573
574# confdefs.h avoids OS command line length limits that DEFS can exceed.
575rm -rf conftest* confdefs.h
576# AIX cpp loses on an empty file, so make sure it contains at least a newline.
577echo > confdefs.h
578
579# A filename unique to this package, relative to the directory that
580# configure is in, which we can look for to find out if srcdir is correct.
581ac_unique_file=ntpd/ntp_refclock.c
582
583# Find the source files, if location was not specified.
584if test -z "$srcdir"; then
585  ac_srcdir_defaulted=yes
586  # Try the directory containing this script, then its parent.
587  ac_prog=$0
588  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
589  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
590  srcdir=$ac_confdir
591  if test ! -r $srcdir/$ac_unique_file; then
592    srcdir=..
593  fi
594else
595  ac_srcdir_defaulted=no
596fi
597if test ! -r $srcdir/$ac_unique_file; then
598  if test "$ac_srcdir_defaulted" = yes; then
599    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
600  else
601    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
602  fi
603fi
604srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
605
606# Prefer explicitly selected file to automatically selected ones.
607if test -z "$CONFIG_SITE"; then
608  if test "x$prefix" != xNONE; then
609    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
610  else
611    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
612  fi
613fi
614for ac_site_file in $CONFIG_SITE; do
615  if test -r "$ac_site_file"; then
616    echo "loading site script $ac_site_file"
617    . "$ac_site_file"
618  fi
619done
620
621if test -r "$cache_file"; then
622  echo "loading cache $cache_file"
623  . $cache_file
624else
625  echo "creating cache $cache_file"
626  > $cache_file
627fi
628
629ac_ext=c
630# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
631ac_cpp='$CPP $CPPFLAGS'
632ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
633ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
634cross_compiling=$ac_cv_prog_cc_cross
635
636ac_exeext=
637ac_objext=o
638if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
639  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
640  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
641    ac_n= ac_c='
642' ac_t='	'
643  else
644    ac_n=-n ac_c= ac_t=
645  fi
646else
647  ac_n= ac_c='\c' ac_t=
648fi
649
650
651ac_aux_dir=
652for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
653  if test -f $ac_dir/install-sh; then
654    ac_aux_dir=$ac_dir
655    ac_install_sh="$ac_aux_dir/install-sh -c"
656    break
657  elif test -f $ac_dir/install.sh; then
658    ac_aux_dir=$ac_dir
659    ac_install_sh="$ac_aux_dir/install.sh -c"
660    break
661  fi
662done
663if test -z "$ac_aux_dir"; then
664  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
665fi
666ac_config_guess=$ac_aux_dir/config.guess
667ac_config_sub=$ac_aux_dir/config.sub
668ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
669
670
671# Do some error checking and defaulting for the host and target type.
672# The inputs are:
673#    configure --host=HOST --target=TARGET --build=BUILD NONOPT
674#
675# The rules are:
676# 1. You are not allowed to specify --host, --target, and nonopt at the
677#    same time.
678# 2. Host defaults to nonopt.
679# 3. If nonopt is not specified, then host defaults to the current host,
680#    as determined by config.guess.
681# 4. Target and build default to nonopt.
682# 5. If nonopt is not specified, then target and build default to host.
683
684# The aliases save the names the user supplied, while $host etc.
685# will get canonicalized.
686case $host---$target---$nonopt in
687NONE---*---* | *---NONE---* | *---*---NONE) ;;
688*) { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; } ;;
689esac
690
691
692# Make sure we can run config.sub.
693if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
694else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
695fi
696
697echo $ac_n "checking host system type""... $ac_c" 1>&6
698echo "configure:699: checking host system type" >&5
699
700host_alias=$host
701case "$host_alias" in
702NONE)
703  case $nonopt in
704  NONE)
705    if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
706    else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
707    fi ;;
708  *) host_alias=$nonopt ;;
709  esac ;;
710esac
711
712host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
713host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
714host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
715host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
716echo "$ac_t""$host" 1>&6
717
718echo $ac_n "checking target system type""... $ac_c" 1>&6
719echo "configure:720: checking target system type" >&5
720
721target_alias=$target
722case "$target_alias" in
723NONE)
724  case $nonopt in
725  NONE) target_alias=$host_alias ;;
726  *) target_alias=$nonopt ;;
727  esac ;;
728esac
729
730target=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $target_alias`
731target_cpu=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
732target_vendor=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
733target_os=`echo $target | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
734echo "$ac_t""$target" 1>&6
735
736echo $ac_n "checking build system type""... $ac_c" 1>&6
737echo "configure:738: checking build system type" >&5
738
739build_alias=$build
740case "$build_alias" in
741NONE)
742  case $nonopt in
743  NONE) build_alias=$host_alias ;;
744  *) build_alias=$nonopt ;;
745  esac ;;
746esac
747
748build=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $build_alias`
749build_cpu=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
750build_vendor=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
751build_os=`echo $build | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
752echo "$ac_t""$build" 1>&6
753
754test "$host_alias" != "$target_alias" &&
755  test "$program_prefix$program_suffix$program_transform_name" = \
756    NONENONEs,x,x, &&
757  program_prefix=${target_alias}-
758
759cat >> confdefs.h <<EOF
760#define STR_SYSTEM "$target"
761EOF
762
763
764
765
766if test "$program_transform_name" = s,x,x,; then
767  program_transform_name=
768else
769  # Double any \ or $.  echo might interpret backslashes.
770  cat <<\EOF_SED > conftestsed
771s,\\,\\\\,g; s,\$,$$,g
772EOF_SED
773  program_transform_name="`echo $program_transform_name|sed -f conftestsed`"
774  rm -f conftestsed
775fi
776test "$program_prefix" != NONE &&
777  program_transform_name="s,^,${program_prefix},; $program_transform_name"
778# Use a double $ so make ignores it.
779test "$program_suffix" != NONE &&
780  program_transform_name="s,\$\$,${program_suffix},; $program_transform_name"
781
782# sed with no file args requires a program.
783test "$program_transform_name" = "" && program_transform_name="s,x,x,"
784
785# Find a good install program.  We prefer a C program (faster),
786# so one script is as good as another.  But avoid the broken or
787# incompatible versions:
788# SysV /etc/install, /usr/sbin/install
789# SunOS /usr/etc/install
790# IRIX /sbin/install
791# AIX /bin/install
792# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
793# AFS /usr/afsws/bin/install, which mishandles nonexistent args
794# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
795# ./install, which can be erroneously created by make from ./install.sh.
796echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
797echo "configure:798: checking for a BSD compatible install" >&5
798if test -z "$INSTALL"; then
799if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
800  echo $ac_n "(cached) $ac_c" 1>&6
801else
802    IFS="${IFS= 	}"; ac_save_IFS="$IFS"; IFS=":"
803  for ac_dir in $PATH; do
804    # Account for people who put trailing slashes in PATH elements.
805    case "$ac_dir/" in
806    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
807    *)
808      # OSF1 and SCO ODT 3.0 have their own names for install.
809      # Don't use installbsd from OSF since it installs stuff as root
810      # by default.
811      for ac_prog in ginstall scoinst install; do
812        if test -f $ac_dir/$ac_prog; then
813	  if test $ac_prog = install &&
814            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
815	    # AIX install.  It has an incompatible calling convention.
816	    :
817	  else
818	    ac_cv_path_install="$ac_dir/$ac_prog -c"
819	    break 2
820	  fi
821	fi
822      done
823      ;;
824    esac
825  done
826  IFS="$ac_save_IFS"
827
828fi
829  if test "${ac_cv_path_install+set}" = set; then
830    INSTALL="$ac_cv_path_install"
831  else
832    # As a last resort, use the slow shell script.  We don't cache a
833    # path for INSTALL within a source directory, because that will
834    # break other packages using the cache if that directory is
835    # removed, or if the path is relative.
836    INSTALL="$ac_install_sh"
837  fi
838fi
839echo "$ac_t""$INSTALL" 1>&6
840
841# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
842# It thinks the first close brace ends the variable substitution.
843test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
844
845test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
846
847test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
848
849echo $ac_n "checking whether build environment is sane""... $ac_c" 1>&6
850echo "configure:851: checking whether build environment is sane" >&5
851# Just in case
852sleep 1
853echo timestamp > conftestfile
854# Do `set' in a subshell so we don't clobber the current shell's
855# arguments.  Must try -L first in case configure is actually a
856# symlink; some systems play weird games with the mod time of symlinks
857# (eg FreeBSD returns the mod time of the symlink's containing
858# directory).
859if (
860   set X `ls -Lt $srcdir/configure conftestfile 2> /dev/null`
861   if test "$*" = "X"; then
862      # -L didn't work.
863      set X `ls -t $srcdir/configure conftestfile`
864   fi
865   if test "$*" != "X $srcdir/configure conftestfile" \
866      && test "$*" != "X conftestfile $srcdir/configure"; then
867
868      # If neither matched, then we have a broken ls.  This can happen
869      # if, for instance, CONFIG_SHELL is bash and it inherits a
870      # broken ls alias from the environment.  This has actually
871      # happened.  Such a system could not be considered "sane".
872      { echo "configure: error: ls -t appears to fail.  Make sure there is not a broken
873alias in your environment" 1>&2; exit 1; }
874   fi
875
876   test "$2" = conftestfile
877   )
878then
879   # Ok.
880   :
881else
882   { echo "configure: error: newly created file is older than distributed files!
883Check your system clock" 1>&2; exit 1; }
884fi
885rm -f conftest*
886echo "$ac_t""yes" 1>&6
887
888test x"${MISSING+set}" = xset || \
889  MISSING="\${SHELL} `CDPATH=: && cd $ac_aux_dir && pwd`/missing"
890if eval "$MISSING --run :"; then
891  am_missing_run="$MISSING --run "
892else
893  am_missing_run=
894  echo "configure: warning: \`missing' script is too old or missing" 1>&2
895fi
896
897for ac_prog in mawk gawk nawk awk
898do
899# Extract the first word of "$ac_prog", so it can be a program name with args.
900set dummy $ac_prog; ac_word=$2
901echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
902echo "configure:903: checking for $ac_word" >&5
903if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
904  echo $ac_n "(cached) $ac_c" 1>&6
905else
906  if test -n "$AWK"; then
907  ac_cv_prog_AWK="$AWK" # Let the user override the test.
908else
909  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
910  ac_dummy="$PATH"
911  for ac_dir in $ac_dummy; do
912    test -z "$ac_dir" && ac_dir=.
913    if test -f $ac_dir/$ac_word; then
914      ac_cv_prog_AWK="$ac_prog"
915      break
916    fi
917  done
918  IFS="$ac_save_ifs"
919fi
920fi
921AWK="$ac_cv_prog_AWK"
922if test -n "$AWK"; then
923  echo "$ac_t""$AWK" 1>&6
924else
925  echo "$ac_t""no" 1>&6
926fi
927
928test -n "$AWK" && break
929done
930
931echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
932echo "configure:933: checking whether ${MAKE-make} sets \${MAKE}" >&5
933set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
934if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
935  echo $ac_n "(cached) $ac_c" 1>&6
936else
937  cat > conftestmake <<\EOF
938all:
939	@echo 'ac_maketemp="${MAKE}"'
940EOF
941# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
942eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
943if test -n "$ac_maketemp"; then
944  eval ac_cv_prog_make_${ac_make}_set=yes
945else
946  eval ac_cv_prog_make_${ac_make}_set=no
947fi
948rm -f conftestmake
949fi
950if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
951  echo "$ac_t""yes" 1>&6
952  SET_MAKE=
953else
954  echo "$ac_t""no" 1>&6
955  SET_MAKE="MAKE=${MAKE-make}"
956fi
957
958
959# Check whether --enable-dependency-tracking or --disable-dependency-tracking was given.
960if test "${enable_dependency_tracking+set}" = set; then
961  enableval="$enable_dependency_tracking"
962  :
963fi
964
965if test "x$enable_dependency_tracking" = xno; then
966  AMDEP="#"
967else
968  am_depcomp="$ac_aux_dir/depcomp"
969  if test ! -f "$am_depcomp"; then
970    AMDEP="#"
971  else
972    AMDEP=
973  fi
974fi
975
976if test -z "$AMDEP"; then
977  AMDEPBACKSLASH='\'
978else
979  AMDEPBACKSLASH=
980fi
981
982
983
984
985
986if test -d .deps || mkdir .deps 2> /dev/null || test -d .deps; then
987  DEPDIR=.deps
988else
989  DEPDIR=_deps
990fi
991
992
993
994
995PACKAGE=ntp
996
997VERSION=4.0.99b
998
999if test "`CDPATH=: && cd $srcdir && pwd`" != "`pwd`" &&
1000   test -f $srcdir/config.status; then
1001  { echo "configure: error: source directory already configured; run "make distclean" there first" 1>&2; exit 1; }
1002fi
1003cat >> confdefs.h <<EOF
1004#define PACKAGE "$PACKAGE"
1005EOF
1006
1007cat >> confdefs.h <<EOF
1008#define VERSION "$VERSION"
1009EOF
1010
1011
1012
1013
1014
1015ACLOCAL=${ACLOCAL-"${am_missing_run}aclocal"}
1016
1017
1018
1019AUTOCONF=${AUTOCONF-"${am_missing_run}autoconf"}
1020
1021
1022
1023AUTOMAKE=${AUTOMAKE-"${am_missing_run}automake"}
1024
1025
1026
1027AUTOHEADER=${AUTOHEADER-"${am_missing_run}autoheader"}
1028
1029
1030
1031MAKEINFO=${MAKEINFO-"${am_missing_run}makeinfo"}
1032
1033
1034
1035AMTAR=${AMTAR-"${am_missing_run}tar"}
1036
1037
1038
1039if test -z "$install_sh"; then
1040   install_sh="$ac_aux_dir/install-sh"
1041   test -f "$install_sh" || install_sh="$ac_aux_dir/install.sh"
1042   test -f "$install_sh" || install_sh="${am_missing_run}${ac_auxdir}/install-sh"
1043         install_sh="`echo $install_sh | sed -e 's/\${SHELL}//'`"
1044fi
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057ac_cv_var_oncore_ok=no
1058
1059iCFLAGS="$CFLAGS"
1060
1061# Extract the first word of "gcc", so it can be a program name with args.
1062set dummy gcc; ac_word=$2
1063echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1064echo "configure:1065: checking for $ac_word" >&5
1065if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1066  echo $ac_n "(cached) $ac_c" 1>&6
1067else
1068  if test -n "$CC"; then
1069  ac_cv_prog_CC="$CC" # Let the user override the test.
1070else
1071  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
1072  ac_dummy="$PATH"
1073  for ac_dir in $ac_dummy; do
1074    test -z "$ac_dir" && ac_dir=.
1075    if test -f $ac_dir/$ac_word; then
1076      ac_cv_prog_CC="gcc"
1077      break
1078    fi
1079  done
1080  IFS="$ac_save_ifs"
1081fi
1082fi
1083CC="$ac_cv_prog_CC"
1084if test -n "$CC"; then
1085  echo "$ac_t""$CC" 1>&6
1086else
1087  echo "$ac_t""no" 1>&6
1088fi
1089
1090if test -z "$CC"; then
1091  # Extract the first word of "cc", so it can be a program name with args.
1092set dummy cc; ac_word=$2
1093echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1094echo "configure:1095: checking for $ac_word" >&5
1095if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1096  echo $ac_n "(cached) $ac_c" 1>&6
1097else
1098  if test -n "$CC"; then
1099  ac_cv_prog_CC="$CC" # Let the user override the test.
1100else
1101  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
1102  ac_prog_rejected=no
1103  ac_dummy="$PATH"
1104  for ac_dir in $ac_dummy; do
1105    test -z "$ac_dir" && ac_dir=.
1106    if test -f $ac_dir/$ac_word; then
1107      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
1108        ac_prog_rejected=yes
1109	continue
1110      fi
1111      ac_cv_prog_CC="cc"
1112      break
1113    fi
1114  done
1115  IFS="$ac_save_ifs"
1116if test $ac_prog_rejected = yes; then
1117  # We found a bogon in the path, so make sure we never use it.
1118  set dummy $ac_cv_prog_CC
1119  shift
1120  if test $# -gt 0; then
1121    # We chose a different compiler from the bogus one.
1122    # However, it has the same basename, so the bogon will be chosen
1123    # first if we set CC to just the basename; use the full file name.
1124    shift
1125    set dummy "$ac_dir/$ac_word" "$@"
1126    shift
1127    ac_cv_prog_CC="$@"
1128  fi
1129fi
1130fi
1131fi
1132CC="$ac_cv_prog_CC"
1133if test -n "$CC"; then
1134  echo "$ac_t""$CC" 1>&6
1135else
1136  echo "$ac_t""no" 1>&6
1137fi
1138
1139  if test -z "$CC"; then
1140    case "`uname -s`" in
1141    *win32* | *WIN32*)
1142      # Extract the first word of "cl", so it can be a program name with args.
1143set dummy cl; ac_word=$2
1144echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1145echo "configure:1146: checking for $ac_word" >&5
1146if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
1147  echo $ac_n "(cached) $ac_c" 1>&6
1148else
1149  if test -n "$CC"; then
1150  ac_cv_prog_CC="$CC" # Let the user override the test.
1151else
1152  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
1153  ac_dummy="$PATH"
1154  for ac_dir in $ac_dummy; do
1155    test -z "$ac_dir" && ac_dir=.
1156    if test -f $ac_dir/$ac_word; then
1157      ac_cv_prog_CC="cl"
1158      break
1159    fi
1160  done
1161  IFS="$ac_save_ifs"
1162fi
1163fi
1164CC="$ac_cv_prog_CC"
1165if test -n "$CC"; then
1166  echo "$ac_t""$CC" 1>&6
1167else
1168  echo "$ac_t""no" 1>&6
1169fi
1170 ;;
1171    esac
1172  fi
1173  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
1174fi
1175
1176echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
1177echo "configure:1178: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
1178
1179ac_ext=c
1180# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1181ac_cpp='$CPP $CPPFLAGS'
1182ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1183ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1184cross_compiling=$ac_cv_prog_cc_cross
1185
1186cat > conftest.$ac_ext << EOF
1187
1188#line 1189 "configure"
1189#include "confdefs.h"
1190
1191main(){return(0);}
1192EOF
1193if { (eval echo configure:1194: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1194  ac_cv_prog_cc_works=yes
1195  # If we can't run a trivial program, we are probably using a cross compiler.
1196  if (./conftest; exit) 2>/dev/null; then
1197    ac_cv_prog_cc_cross=no
1198  else
1199    ac_cv_prog_cc_cross=yes
1200  fi
1201else
1202  echo "configure: failed program was:" >&5
1203  cat conftest.$ac_ext >&5
1204  ac_cv_prog_cc_works=no
1205fi
1206rm -fr conftest*
1207ac_ext=c
1208# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
1209ac_cpp='$CPP $CPPFLAGS'
1210ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
1211ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
1212cross_compiling=$ac_cv_prog_cc_cross
1213
1214echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
1215if test $ac_cv_prog_cc_works = no; then
1216  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
1217fi
1218echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
1219echo "configure:1220: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
1220echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
1221cross_compiling=$ac_cv_prog_cc_cross
1222
1223echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
1224echo "configure:1225: checking whether we are using GNU C" >&5
1225if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
1226  echo $ac_n "(cached) $ac_c" 1>&6
1227else
1228  cat > conftest.c <<EOF
1229#ifdef __GNUC__
1230  yes;
1231#endif
1232EOF
1233if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:1234: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
1234  ac_cv_prog_gcc=yes
1235else
1236  ac_cv_prog_gcc=no
1237fi
1238fi
1239
1240echo "$ac_t""$ac_cv_prog_gcc" 1>&6
1241
1242if test $ac_cv_prog_gcc = yes; then
1243  GCC=yes
1244else
1245  GCC=
1246fi
1247
1248ac_test_CFLAGS="${CFLAGS+set}"
1249ac_save_CFLAGS="$CFLAGS"
1250CFLAGS=
1251echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
1252echo "configure:1253: checking whether ${CC-cc} accepts -g" >&5
1253if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
1254  echo $ac_n "(cached) $ac_c" 1>&6
1255else
1256  echo 'void f(){}' > conftest.c
1257if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
1258  ac_cv_prog_cc_g=yes
1259else
1260  ac_cv_prog_cc_g=no
1261fi
1262rm -f conftest*
1263
1264fi
1265
1266echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1267if test "$ac_test_CFLAGS" = set; then
1268  CFLAGS="$ac_save_CFLAGS"
1269elif test $ac_cv_prog_cc_g = yes; then
1270  if test "$GCC" = yes; then
1271    CFLAGS="-g -O2"
1272  else
1273    CFLAGS="-g"
1274  fi
1275else
1276  if test "$GCC" = yes; then
1277    CFLAGS="-O2"
1278  else
1279    CFLAGS=
1280  fi
1281fi
1282
1283
1284echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1285echo "configure:1286: checking how to run the C preprocessor" >&5
1286# On Suns, sometimes $CPP names a directory.
1287if test -n "$CPP" && test -d "$CPP"; then
1288  CPP=
1289fi
1290if test -z "$CPP"; then
1291if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1292  echo $ac_n "(cached) $ac_c" 1>&6
1293else
1294    # This must be in double quotes, not single quotes, because CPP may get
1295  # substituted into the Makefile and "${CC-cc}" will confuse make.
1296  CPP="${CC-cc} -E"
1297  # On the NeXT, cc -E runs the code through the compiler's parser,
1298  # not just through cpp.
1299  cat > conftest.$ac_ext <<EOF
1300#line 1301 "configure"
1301#include "confdefs.h"
1302#include <assert.h>
1303Syntax Error
1304EOF
1305ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1306{ (eval echo configure:1307: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1307ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1308if test -z "$ac_err"; then
1309  :
1310else
1311  echo "$ac_err" >&5
1312  echo "configure: failed program was:" >&5
1313  cat conftest.$ac_ext >&5
1314  rm -rf conftest*
1315  CPP="${CC-cc} -E -traditional-cpp"
1316  cat > conftest.$ac_ext <<EOF
1317#line 1318 "configure"
1318#include "confdefs.h"
1319#include <assert.h>
1320Syntax Error
1321EOF
1322ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1323{ (eval echo configure:1324: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1324ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1325if test -z "$ac_err"; then
1326  :
1327else
1328  echo "$ac_err" >&5
1329  echo "configure: failed program was:" >&5
1330  cat conftest.$ac_ext >&5
1331  rm -rf conftest*
1332  CPP="${CC-cc} -nologo -E"
1333  cat > conftest.$ac_ext <<EOF
1334#line 1335 "configure"
1335#include "confdefs.h"
1336#include <assert.h>
1337Syntax Error
1338EOF
1339ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1340{ (eval echo configure:1341: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1341ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1342if test -z "$ac_err"; then
1343  :
1344else
1345  echo "$ac_err" >&5
1346  echo "configure: failed program was:" >&5
1347  cat conftest.$ac_ext >&5
1348  rm -rf conftest*
1349  CPP=/lib/cpp
1350fi
1351rm -f conftest*
1352fi
1353rm -f conftest*
1354fi
1355rm -f conftest*
1356  ac_cv_prog_CPP="$CPP"
1357fi
1358  CPP="$ac_cv_prog_CPP"
1359else
1360  ac_cv_prog_CPP="$CPP"
1361fi
1362echo "$ac_t""$CPP" 1>&6
1363
1364
1365
1366
1367
1368
1369
1370depcc="$CC"
1371depcpp="$CPP"
1372echo $ac_n "checking dependency style of $depcc""... $ac_c" 1>&6
1373echo "configure:1374: checking dependency style of $depcc" >&5
1374if eval "test \"`echo '$''{'am_cv_CC_dependencies_compiler_type'+set}'`\" = set"; then
1375  echo $ac_n "(cached) $ac_c" 1>&6
1376else
1377
1378if test -z "$AMDEP"; then
1379  echo '#include "conftest.h"' > conftest.c
1380  echo 'int i;' > conftest.h
1381
1382  am_cv_CC_dependencies_compiler_type=none
1383  for depmode in `sed -n 's/^#*\([a-zA-Z0-9]*\))$/\1/p' < "$am_depcomp"`; do
1384    case "$depmode" in
1385    nosideeffect)
1386      # after this tag, mechanisms are not by side-effect, so they'll
1387      # only be used when explicitly requested
1388      if test "x$enable_dependency_tracking" = xyes; then
1389	continue
1390      else
1391	break
1392      fi
1393      ;;
1394    none) break ;;
1395    esac
1396    if depmode="$depmode" \
1397       source=conftest.c object=conftest.o \
1398       depfile=conftest.Po tmpdepfile=conftest.TPo \
1399       $SHELL $am_depcomp $depcc -c conftest.c 2>/dev/null &&
1400       grep conftest.h conftest.Po > /dev/null 2>&1; then
1401      am_cv_CC_dependencies_compiler_type="$depmode"
1402      break
1403    fi
1404  done
1405
1406  rm -f conftest.*
1407else
1408  am_cv_CC_dependencies_compiler_type=none
1409fi
1410
1411fi
1412
1413echo "$ac_t""$am_cv_CC_dependencies_compiler_type" 1>&6
1414CCDEPMODE="depmode=$am_cv_CC_dependencies_compiler_type"
1415
1416
1417echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1418echo "configure:1419: checking how to run the C preprocessor" >&5
1419# On Suns, sometimes $CPP names a directory.
1420if test -n "$CPP" && test -d "$CPP"; then
1421  CPP=
1422fi
1423if test -z "$CPP"; then
1424if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1425  echo $ac_n "(cached) $ac_c" 1>&6
1426else
1427    # This must be in double quotes, not single quotes, because CPP may get
1428  # substituted into the Makefile and "${CC-cc}" will confuse make.
1429  CPP="${CC-cc} -E"
1430  # On the NeXT, cc -E runs the code through the compiler's parser,
1431  # not just through cpp.
1432  cat > conftest.$ac_ext <<EOF
1433#line 1434 "configure"
1434#include "confdefs.h"
1435#include <assert.h>
1436Syntax Error
1437EOF
1438ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1439{ (eval echo configure:1440: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1440ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1441if test -z "$ac_err"; then
1442  :
1443else
1444  echo "$ac_err" >&5
1445  echo "configure: failed program was:" >&5
1446  cat conftest.$ac_ext >&5
1447  rm -rf conftest*
1448  CPP="${CC-cc} -E -traditional-cpp"
1449  cat > conftest.$ac_ext <<EOF
1450#line 1451 "configure"
1451#include "confdefs.h"
1452#include <assert.h>
1453Syntax Error
1454EOF
1455ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1456{ (eval echo configure:1457: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1457ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1458if test -z "$ac_err"; then
1459  :
1460else
1461  echo "$ac_err" >&5
1462  echo "configure: failed program was:" >&5
1463  cat conftest.$ac_ext >&5
1464  rm -rf conftest*
1465  CPP="${CC-cc} -nologo -E"
1466  cat > conftest.$ac_ext <<EOF
1467#line 1468 "configure"
1468#include "confdefs.h"
1469#include <assert.h>
1470Syntax Error
1471EOF
1472ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1473{ (eval echo configure:1474: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1474ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1475if test -z "$ac_err"; then
1476  :
1477else
1478  echo "$ac_err" >&5
1479  echo "configure: failed program was:" >&5
1480  cat conftest.$ac_ext >&5
1481  rm -rf conftest*
1482  CPP=/lib/cpp
1483fi
1484rm -f conftest*
1485fi
1486rm -f conftest*
1487fi
1488rm -f conftest*
1489  ac_cv_prog_CPP="$CPP"
1490fi
1491  CPP="$ac_cv_prog_CPP"
1492else
1493  ac_cv_prog_CPP="$CPP"
1494fi
1495echo "$ac_t""$CPP" 1>&6
1496
1497
1498case "$target" in
1499 *-pc-cygwin*)
1500    CFLAGS="$CFLAGS -DSYS_CYGWIN32"
1501    ;;
1502 i386-sequent-sysv4)
1503    case "$CC" in
1504     cc)
1505	CFLAGS="$CFLAGS -Wc,+Abi-socket"
1506	;;
1507    esac
1508    ;;
1509 alpha*-dec-osf*)
1510    case "$CC" in
1511     cc)
1512	CFLAGS="$CFLAGS -std1"
1513	;;
1514    esac
1515    ;;
1516esac
1517
1518case "$host" in
1519 $target)
1520    ;;
1521 *) case "$target" in
1522     *-*-vxworks*)
1523	# Quick and dirty sanity check
1524	case "$VX_KERNEL" in
1525	 '') { echo "configure: error: Please follow the directions in html/vxworks.html!" 1>&2; exit 1; }
1526	    ;;
1527	esac
1528        CFLAGS="$CFLAGS -DSYS_VXWORKS"
1529        ;;
1530    esac
1531    ;;
1532esac
1533
1534for ac_prog in mawk gawk nawk awk
1535do
1536# Extract the first word of "$ac_prog", so it can be a program name with args.
1537set dummy $ac_prog; ac_word=$2
1538echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1539echo "configure:1540: checking for $ac_word" >&5
1540if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
1541  echo $ac_n "(cached) $ac_c" 1>&6
1542else
1543  if test -n "$AWK"; then
1544  ac_cv_prog_AWK="$AWK" # Let the user override the test.
1545else
1546  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
1547  ac_dummy="$PATH"
1548  for ac_dir in $ac_dummy; do
1549    test -z "$ac_dir" && ac_dir=.
1550    if test -f $ac_dir/$ac_word; then
1551      ac_cv_prog_AWK="$ac_prog"
1552      break
1553    fi
1554  done
1555  IFS="$ac_save_ifs"
1556fi
1557fi
1558AWK="$ac_cv_prog_AWK"
1559if test -n "$AWK"; then
1560  echo "$ac_t""$AWK" 1>&6
1561else
1562  echo "$ac_t""no" 1>&6
1563fi
1564
1565test -n "$AWK" && break
1566done
1567
1568echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
1569echo "configure:1570: checking whether ${MAKE-make} sets \${MAKE}" >&5
1570set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
1571if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
1572  echo $ac_n "(cached) $ac_c" 1>&6
1573else
1574  cat > conftestmake <<\EOF
1575all:
1576	@echo 'ac_maketemp="${MAKE}"'
1577EOF
1578# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
1579eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
1580if test -n "$ac_maketemp"; then
1581  eval ac_cv_prog_make_${ac_make}_set=yes
1582else
1583  eval ac_cv_prog_make_${ac_make}_set=no
1584fi
1585rm -f conftestmake
1586fi
1587if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1588  echo "$ac_t""yes" 1>&6
1589  SET_MAKE=
1590else
1591  echo "$ac_t""no" 1>&6
1592  SET_MAKE="MAKE=${MAKE-make}"
1593fi
1594
1595
1596rm -f conftest*
1597
1598case "$GCC" in
1599 yes)
1600    CFLAGS="$CFLAGS -Wall"
1601    # CFLAGS="$CFLAGS -Wtraditional"
1602    CFLAGS="$CFLAGS -Wshadow"
1603    # CFLAGS="$CFLAGS -Wwrite-strings"
1604    CFLAGS="$CFLAGS -Wconversion"
1605    CFLAGS="$CFLAGS -Wpointer-arith"
1606    CFLAGS="$CFLAGS -Wcast-qual"
1607    # CFLAGS="$CFLAGS -Wcast-align"
1608    CFLAGS="$CFLAGS -Wstrict-prototypes"
1609
1610    echo $ac_n "checking whether ${CC-cc} -pipe works""... $ac_c" 1>&6
1611echo "configure:1612: checking whether ${CC-cc} -pipe works" >&5
1612if eval "test \"`echo '$''{'ac_cv_prog_cc_pipe'+set}'`\" = set"; then
1613  echo $ac_n "(cached) $ac_c" 1>&6
1614else
1615  echo 'void f(){}' > conftest.c
1616    if test -z "`${CC-cc} -pipe -c conftest.c 2>&1`" -a -s conftest.o; then
1617      ac_cv_prog_cc_pipe=yes
1618    else
1619      ac_cv_prog_cc_pipe=no
1620    fi
1621    rm -f conftest*
1622
1623fi
1624
1625echo "$ac_t""$ac_cv_prog_cc_pipe" 1>&6
1626
1627    case "$ac_cv_prog_cc_pipe" in
1628     yes)
1629	CFLAGS="$CFLAGS -pipe"
1630	;;
1631    esac
1632    ;;
1633esac
1634
1635ac_busted_vpath_in_make=no
1636
1637case "$target" in
1638 *-*-irix6.1*)	# 64 bit only
1639    ;;
1640 *-*-irix6*)	# 6.2 (and later?)
1641    ac_busted_vpath_in_make=yes
1642    # don't pass -n32 to gcc, it cannot handle and doesn't need it
1643    if test "$GCC" != yes; then
1644      case "$CFLAGS" in
1645       *-n32*) ;;
1646       *-n64*) ;;
1647       *) case "$iCFLAGS" in
1648	   '') CFLAGS="-O2 -g3 -n32" ;;
1649	   *)  CFLAGS="$CFLAGS -n32" ;;
1650	  esac
1651	  ;;
1652      esac
1653      case "$LDFLAGS" in
1654       *-n32*) ;;
1655       *-n64*) ;;
1656       *) LDFLAGS="$LDFLAGS -n32" ;;
1657      esac
1658    fi
1659    ;;
1660 *-next-nextstep3)
1661    CFLAGS="$CFLAGS -posix" ;;
1662 *-*-solaris2.5.1)
1663    ac_busted_vpath_in_make=yes
1664    ;;
1665esac
1666
1667case "$ac_busted_vpath_in_make$srcdir" in
1668 no*) ;;
1669 yes.) ;;
1670 *) case "`${MAKE-make} -v -f /dev/null 2>/dev/null | sed -e 's/GNU Make version \(1-9.]*\).*/\1/' -e q`" in
1671     '')
1672	{ echo "configure: error: building outside of the main directory requires GNU make" 1>&2; exit 1; }
1673	;;
1674     *) ;;
1675    esac
1676    ;;
1677esac
1678
1679
1680echo $ac_n "checking whether ln -s works""... $ac_c" 1>&6
1681echo "configure:1682: checking whether ln -s works" >&5
1682if eval "test \"`echo '$''{'ac_cv_prog_LN_S'+set}'`\" = set"; then
1683  echo $ac_n "(cached) $ac_c" 1>&6
1684else
1685  rm -f conftestdata
1686if ln -s X conftestdata 2>/dev/null
1687then
1688  rm -f conftestdata
1689  ac_cv_prog_LN_S="ln -s"
1690else
1691  ac_cv_prog_LN_S=ln
1692fi
1693fi
1694LN_S="$ac_cv_prog_LN_S"
1695if test "$ac_cv_prog_LN_S" = "ln -s"; then
1696  echo "$ac_t""yes" 1>&6
1697else
1698  echo "$ac_t""no" 1>&6
1699fi
1700
1701if test $ac_cv_prog_gcc = yes; then
1702    echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6
1703echo "configure:1704: checking whether ${CC-cc} needs -traditional" >&5
1704if eval "test \"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then
1705  echo $ac_n "(cached) $ac_c" 1>&6
1706else
1707    ac_pattern="Autoconf.*'x'"
1708  cat > conftest.$ac_ext <<EOF
1709#line 1710 "configure"
1710#include "confdefs.h"
1711#include <sgtty.h>
1712Autoconf TIOCGETP
1713EOF
1714if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1715  egrep "$ac_pattern" >/dev/null 2>&1; then
1716  rm -rf conftest*
1717  ac_cv_prog_gcc_traditional=yes
1718else
1719  rm -rf conftest*
1720  ac_cv_prog_gcc_traditional=no
1721fi
1722rm -f conftest*
1723
1724
1725  if test $ac_cv_prog_gcc_traditional = no; then
1726    cat > conftest.$ac_ext <<EOF
1727#line 1728 "configure"
1728#include "confdefs.h"
1729#include <termio.h>
1730Autoconf TCGETA
1731EOF
1732if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1733  egrep "$ac_pattern" >/dev/null 2>&1; then
1734  rm -rf conftest*
1735  ac_cv_prog_gcc_traditional=yes
1736fi
1737rm -f conftest*
1738
1739  fi
1740fi
1741
1742echo "$ac_t""$ac_cv_prog_gcc_traditional" 1>&6
1743  if test $ac_cv_prog_gcc_traditional = yes; then
1744    CC="$CC -traditional"
1745  fi
1746fi
1747
1748echo $ac_n "checking for AIX""... $ac_c" 1>&6
1749echo "configure:1750: checking for AIX" >&5
1750cat > conftest.$ac_ext <<EOF
1751#line 1752 "configure"
1752#include "confdefs.h"
1753#ifdef _AIX
1754  yes
1755#endif
1756
1757EOF
1758if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1759  egrep "yes" >/dev/null 2>&1; then
1760  rm -rf conftest*
1761  echo "$ac_t""yes" 1>&6; cat >> confdefs.h <<\EOF
1762#define _ALL_SOURCE 1
1763EOF
1764
1765else
1766  rm -rf conftest*
1767  echo "$ac_t""no" 1>&6
1768fi
1769rm -f conftest*
1770
1771
1772ac_safe=`echo "minix/config.h" | sed 'y%./+-%__p_%'`
1773echo $ac_n "checking for minix/config.h""... $ac_c" 1>&6
1774echo "configure:1775: checking for minix/config.h" >&5
1775if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1776  echo $ac_n "(cached) $ac_c" 1>&6
1777else
1778  cat > conftest.$ac_ext <<EOF
1779#line 1780 "configure"
1780#include "confdefs.h"
1781#include <minix/config.h>
1782EOF
1783ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1784{ (eval echo configure:1785: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1785ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1786if test -z "$ac_err"; then
1787  rm -rf conftest*
1788  eval "ac_cv_header_$ac_safe=yes"
1789else
1790  echo "$ac_err" >&5
1791  echo "configure: failed program was:" >&5
1792  cat conftest.$ac_ext >&5
1793  rm -rf conftest*
1794  eval "ac_cv_header_$ac_safe=no"
1795fi
1796rm -f conftest*
1797fi
1798if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1799  echo "$ac_t""yes" 1>&6
1800  MINIX=yes
1801else
1802  echo "$ac_t""no" 1>&6
1803MINIX=
1804fi
1805
1806if test "$MINIX" = yes; then
1807  cat >> confdefs.h <<\EOF
1808#define _POSIX_SOURCE 1
1809EOF
1810
1811  cat >> confdefs.h <<\EOF
1812#define _POSIX_1_SOURCE 2
1813EOF
1814
1815  cat >> confdefs.h <<\EOF
1816#define _MINIX 1
1817EOF
1818
1819fi
1820
1821echo $ac_n "checking for POSIXized ISC""... $ac_c" 1>&6
1822echo "configure:1823: checking for POSIXized ISC" >&5
1823if test -d /etc/conf/kconfig.d &&
1824  grep _POSIX_VERSION /usr/include/sys/unistd.h >/dev/null 2>&1
1825then
1826  echo "$ac_t""yes" 1>&6
1827  ISC=yes # If later tests want to check for ISC.
1828  cat >> confdefs.h <<\EOF
1829#define _POSIX_SOURCE 1
1830EOF
1831
1832  if test "$GCC" = yes; then
1833    CC="$CC -posix"
1834  else
1835    CC="$CC -Xp"
1836  fi
1837else
1838  echo "$ac_t""no" 1>&6
1839  ISC=
1840fi
1841
1842# Extract the first word of "ranlib", so it can be a program name with args.
1843set dummy ranlib; ac_word=$2
1844echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1845echo "configure:1846: checking for $ac_word" >&5
1846if eval "test \"`echo '$''{'ac_cv_prog_RANLIB'+set}'`\" = set"; then
1847  echo $ac_n "(cached) $ac_c" 1>&6
1848else
1849  if test -n "$RANLIB"; then
1850  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1851else
1852  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
1853  ac_dummy="$PATH"
1854  for ac_dir in $ac_dummy; do
1855    test -z "$ac_dir" && ac_dir=.
1856    if test -f $ac_dir/$ac_word; then
1857      ac_cv_prog_RANLIB="ranlib"
1858      break
1859    fi
1860  done
1861  IFS="$ac_save_ifs"
1862  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1863fi
1864fi
1865RANLIB="$ac_cv_prog_RANLIB"
1866if test -n "$RANLIB"; then
1867  echo "$ac_t""$RANLIB" 1>&6
1868else
1869  echo "$ac_t""no" 1>&6
1870fi
1871
1872# Extract the first word of "sh", so it can be a program name with args.
1873set dummy sh; ac_word=$2
1874echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1875echo "configure:1876: checking for $ac_word" >&5
1876if eval "test \"`echo '$''{'ac_cv_path_PATH_SH'+set}'`\" = set"; then
1877  echo $ac_n "(cached) $ac_c" 1>&6
1878else
1879  case "$PATH_SH" in
1880  /*)
1881  ac_cv_path_PATH_SH="$PATH_SH" # Let the user override the test with a path.
1882  ;;
1883  ?:/*)
1884  ac_cv_path_PATH_SH="$PATH_SH" # Let the user override the test with a dos path.
1885  ;;
1886  *)
1887  IFS="${IFS= 	}"; ac_save_ifs="$IFS"; IFS=":"
1888  ac_dummy="$PATH"
1889  for ac_dir in $ac_dummy; do
1890    test -z "$ac_dir" && ac_dir=.
1891    if test -f $ac_dir/$ac_word; then
1892      ac_cv_path_PATH_SH="$ac_dir/$ac_word"
1893      break
1894    fi
1895  done
1896  IFS="$ac_save_ifs"
1897  ;;
1898esac
1899fi
1900PATH_SH="$ac_cv_path_PATH_SH"
1901if test -n "$PATH_SH"; then
1902  echo "$ac_t""$PATH_SH" 1>&6
1903else
1904  echo "$ac_t""no" 1>&6
1905fi
1906
1907
1908case "$target" in
1909 *-*-vxworks*)
1910    ac_link="$ac_link $VX_KERNEL"
1911    ;;
1912esac
1913
1914# Find a good install program.  We prefer a C program (faster),
1915# so one script is as good as another.  But avoid the broken or
1916# incompatible versions:
1917# SysV /etc/install, /usr/sbin/install
1918# SunOS /usr/etc/install
1919# IRIX /sbin/install
1920# AIX /bin/install
1921# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1922# AFS /usr/afsws/bin/install, which mishandles nonexistent args
1923# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1924# ./install, which can be erroneously created by make from ./install.sh.
1925echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
1926echo "configure:1927: checking for a BSD compatible install" >&5
1927if test -z "$INSTALL"; then
1928if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
1929  echo $ac_n "(cached) $ac_c" 1>&6
1930else
1931    IFS="${IFS= 	}"; ac_save_IFS="$IFS"; IFS=":"
1932  for ac_dir in $PATH; do
1933    # Account for people who put trailing slashes in PATH elements.
1934    case "$ac_dir/" in
1935    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1936    *)
1937      # OSF1 and SCO ODT 3.0 have their own names for install.
1938      # Don't use installbsd from OSF since it installs stuff as root
1939      # by default.
1940      for ac_prog in ginstall scoinst install; do
1941        if test -f $ac_dir/$ac_prog; then
1942	  if test $ac_prog = install &&
1943            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1944	    # AIX install.  It has an incompatible calling convention.
1945	    :
1946	  else
1947	    ac_cv_path_install="$ac_dir/$ac_prog -c"
1948	    break 2
1949	  fi
1950	fi
1951      done
1952      ;;
1953    esac
1954  done
1955  IFS="$ac_save_IFS"
1956
1957fi
1958  if test "${ac_cv_path_install+set}" = set; then
1959    INSTALL="$ac_cv_path_install"
1960  else
1961    # As a last resort, use the slow shell script.  We don't cache a
1962    # path for INSTALL within a source directory, because that will
1963    # break other packages using the cache if that directory is
1964    # removed, or if the path is relative.
1965    INSTALL="$ac_install_sh"
1966  fi
1967fi
1968echo "$ac_t""$INSTALL" 1>&6
1969
1970# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1971# It thinks the first close brace ends the variable substitution.
1972test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1973
1974test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
1975
1976test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1977
1978
1979case "$target" in
1980 *-pc-cygwin*)
1981    echo $ac_n "checking for main in -ladvapi32""... $ac_c" 1>&6
1982echo "configure:1983: checking for main in -ladvapi32" >&5
1983ac_lib_var=`echo advapi32'_'main | sed 'y%./+-%__p_%'`
1984if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1985  echo $ac_n "(cached) $ac_c" 1>&6
1986else
1987  ac_save_LIBS="$LIBS"
1988LIBS="-ladvapi32  $LIBS"
1989cat > conftest.$ac_ext <<EOF
1990#line 1991 "configure"
1991#include "confdefs.h"
1992
1993int main() {
1994main()
1995; return 0; }
1996EOF
1997if { (eval echo configure:1998: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1998  rm -rf conftest*
1999  eval "ac_cv_lib_$ac_lib_var=yes"
2000else
2001  echo "configure: failed program was:" >&5
2002  cat conftest.$ac_ext >&5
2003  rm -rf conftest*
2004  eval "ac_cv_lib_$ac_lib_var=no"
2005fi
2006rm -f conftest*
2007LIBS="$ac_save_LIBS"
2008
2009fi
2010if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2011  echo "$ac_t""yes" 1>&6
2012    ac_tr_lib=HAVE_LIB`echo advapi32 | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2013    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2014  cat >> confdefs.h <<EOF
2015#define $ac_tr_lib 1
2016EOF
2017
2018  LIBS="-ladvapi32 $LIBS"
2019
2020else
2021  echo "$ac_t""no" 1>&6
2022fi
2023
2024    ;;
2025esac
2026echo $ac_n "checking for nlist in -lelf""... $ac_c" 1>&6
2027echo "configure:2028: checking for nlist in -lelf" >&5
2028ac_lib_var=`echo elf'_'nlist | sed 'y%./+-%__p_%'`
2029if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2030  echo $ac_n "(cached) $ac_c" 1>&6
2031else
2032  ac_save_LIBS="$LIBS"
2033LIBS="-lelf  $LIBS"
2034cat > conftest.$ac_ext <<EOF
2035#line 2036 "configure"
2036#include "confdefs.h"
2037/* Override any gcc2 internal prototype to avoid an error.  */
2038/* We use char because int might match the return type of a gcc2
2039    builtin and then its argument prototype would still apply.  */
2040char nlist();
2041
2042int main() {
2043nlist()
2044; return 0; }
2045EOF
2046if { (eval echo configure:2047: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2047  rm -rf conftest*
2048  eval "ac_cv_lib_$ac_lib_var=yes"
2049else
2050  echo "configure: failed program was:" >&5
2051  cat conftest.$ac_ext >&5
2052  rm -rf conftest*
2053  eval "ac_cv_lib_$ac_lib_var=no"
2054fi
2055rm -f conftest*
2056LIBS="$ac_save_LIBS"
2057
2058fi
2059if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2060  echo "$ac_t""yes" 1>&6
2061    ac_tr_lib=HAVE_LIB`echo elf | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2062    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2063  cat >> confdefs.h <<EOF
2064#define $ac_tr_lib 1
2065EOF
2066
2067  LIBS="-lelf $LIBS"
2068
2069else
2070  echo "$ac_t""no" 1>&6
2071fi
2072
2073echo $ac_n "checking for main in -lkvm""... $ac_c" 1>&6
2074echo "configure:2075: checking for main in -lkvm" >&5
2075ac_lib_var=`echo kvm'_'main | sed 'y%./+-%__p_%'`
2076if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2077  echo $ac_n "(cached) $ac_c" 1>&6
2078else
2079  ac_save_LIBS="$LIBS"
2080LIBS="-lkvm  $LIBS"
2081cat > conftest.$ac_ext <<EOF
2082#line 2083 "configure"
2083#include "confdefs.h"
2084
2085int main() {
2086main()
2087; return 0; }
2088EOF
2089if { (eval echo configure:2090: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2090  rm -rf conftest*
2091  eval "ac_cv_lib_$ac_lib_var=yes"
2092else
2093  echo "configure: failed program was:" >&5
2094  cat conftest.$ac_ext >&5
2095  rm -rf conftest*
2096  eval "ac_cv_lib_$ac_lib_var=no"
2097fi
2098rm -f conftest*
2099LIBS="$ac_save_LIBS"
2100
2101fi
2102if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2103  echo "$ac_t""yes" 1>&6
2104    ac_tr_lib=HAVE_LIB`echo kvm | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2105    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2106  cat >> confdefs.h <<EOF
2107#define $ac_tr_lib 1
2108EOF
2109
2110  LIBS="-lkvm $LIBS"
2111
2112else
2113  echo "$ac_t""no" 1>&6
2114fi
2115		echo $ac_n "checking for nlist in -lld""... $ac_c" 1>&6
2116echo "configure:2117: checking for nlist in -lld" >&5
2117ac_lib_var=`echo ld'_'nlist | sed 'y%./+-%__p_%'`
2118if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2119  echo $ac_n "(cached) $ac_c" 1>&6
2120else
2121  ac_save_LIBS="$LIBS"
2122LIBS="-lld  $LIBS"
2123cat > conftest.$ac_ext <<EOF
2124#line 2125 "configure"
2125#include "confdefs.h"
2126/* Override any gcc2 internal prototype to avoid an error.  */
2127/* We use char because int might match the return type of a gcc2
2128    builtin and then its argument prototype would still apply.  */
2129char nlist();
2130
2131int main() {
2132nlist()
2133; return 0; }
2134EOF
2135if { (eval echo configure:2136: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2136  rm -rf conftest*
2137  eval "ac_cv_lib_$ac_lib_var=yes"
2138else
2139  echo "configure: failed program was:" >&5
2140  cat conftest.$ac_ext >&5
2141  rm -rf conftest*
2142  eval "ac_cv_lib_$ac_lib_var=no"
2143fi
2144rm -f conftest*
2145LIBS="$ac_save_LIBS"
2146
2147fi
2148if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2149  echo "$ac_t""yes" 1>&6
2150    ac_tr_lib=HAVE_LIB`echo ld | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2151    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2152  cat >> confdefs.h <<EOF
2153#define $ac_tr_lib 1
2154EOF
2155
2156  LIBS="-lld $LIBS"
2157
2158else
2159  echo "$ac_t""no" 1>&6
2160fi
2161
2162echo $ac_n "checking for nlist in -lmld""... $ac_c" 1>&6
2163echo "configure:2164: checking for nlist in -lmld" >&5
2164ac_lib_var=`echo mld'_'nlist | sed 'y%./+-%__p_%'`
2165if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2166  echo $ac_n "(cached) $ac_c" 1>&6
2167else
2168  ac_save_LIBS="$LIBS"
2169LIBS="-lmld  $LIBS"
2170cat > conftest.$ac_ext <<EOF
2171#line 2172 "configure"
2172#include "confdefs.h"
2173/* Override any gcc2 internal prototype to avoid an error.  */
2174/* We use char because int might match the return type of a gcc2
2175    builtin and then its argument prototype would still apply.  */
2176char nlist();
2177
2178int main() {
2179nlist()
2180; return 0; }
2181EOF
2182if { (eval echo configure:2183: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2183  rm -rf conftest*
2184  eval "ac_cv_lib_$ac_lib_var=yes"
2185else
2186  echo "configure: failed program was:" >&5
2187  cat conftest.$ac_ext >&5
2188  rm -rf conftest*
2189  eval "ac_cv_lib_$ac_lib_var=no"
2190fi
2191rm -f conftest*
2192LIBS="$ac_save_LIBS"
2193
2194fi
2195if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2196  echo "$ac_t""yes" 1>&6
2197    ac_tr_lib=HAVE_LIB`echo mld | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2198    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2199  cat >> confdefs.h <<EOF
2200#define $ac_tr_lib 1
2201EOF
2202
2203  LIBS="-lmld $LIBS"
2204
2205else
2206  echo "$ac_t""no" 1>&6
2207fi
2208
2209echo $ac_n "checking for gethostent""... $ac_c" 1>&6
2210echo "configure:2211: checking for gethostent" >&5
2211if eval "test \"`echo '$''{'ac_cv_func_gethostent'+set}'`\" = set"; then
2212  echo $ac_n "(cached) $ac_c" 1>&6
2213else
2214  cat > conftest.$ac_ext <<EOF
2215#line 2216 "configure"
2216#include "confdefs.h"
2217/* System header to define __stub macros and hopefully few prototypes,
2218    which can conflict with char gethostent(); below.  */
2219#include <assert.h>
2220/* Override any gcc2 internal prototype to avoid an error.  */
2221/* We use char because int might match the return type of a gcc2
2222    builtin and then its argument prototype would still apply.  */
2223char gethostent();
2224
2225int main() {
2226
2227/* The GNU C library defines this for functions which it implements
2228    to always fail with ENOSYS.  Some functions are actually named
2229    something starting with __ and the normal name is an alias.  */
2230#if defined (__stub_gethostent) || defined (__stub___gethostent)
2231choke me
2232#else
2233gethostent();
2234#endif
2235
2236; return 0; }
2237EOF
2238if { (eval echo configure:2239: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2239  rm -rf conftest*
2240  eval "ac_cv_func_gethostent=yes"
2241else
2242  echo "configure: failed program was:" >&5
2243  cat conftest.$ac_ext >&5
2244  rm -rf conftest*
2245  eval "ac_cv_func_gethostent=no"
2246fi
2247rm -f conftest*
2248fi
2249
2250if eval "test \"`echo '$ac_cv_func_'gethostent`\" = yes"; then
2251  echo "$ac_t""yes" 1>&6
2252  :
2253else
2254  echo "$ac_t""no" 1>&6
2255echo $ac_n "checking for gethostent in -lnsl""... $ac_c" 1>&6
2256echo "configure:2257: checking for gethostent in -lnsl" >&5
2257ac_lib_var=`echo nsl'_'gethostent | sed 'y%./+-%__p_%'`
2258if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2259  echo $ac_n "(cached) $ac_c" 1>&6
2260else
2261  ac_save_LIBS="$LIBS"
2262LIBS="-lnsl -lsocket $LIBS"
2263cat > conftest.$ac_ext <<EOF
2264#line 2265 "configure"
2265#include "confdefs.h"
2266/* Override any gcc2 internal prototype to avoid an error.  */
2267/* We use char because int might match the return type of a gcc2
2268    builtin and then its argument prototype would still apply.  */
2269char gethostent();
2270
2271int main() {
2272gethostent()
2273; return 0; }
2274EOF
2275if { (eval echo configure:2276: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2276  rm -rf conftest*
2277  eval "ac_cv_lib_$ac_lib_var=yes"
2278else
2279  echo "configure: failed program was:" >&5
2280  cat conftest.$ac_ext >&5
2281  rm -rf conftest*
2282  eval "ac_cv_lib_$ac_lib_var=no"
2283fi
2284rm -f conftest*
2285LIBS="$ac_save_LIBS"
2286
2287fi
2288if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2289  echo "$ac_t""yes" 1>&6
2290    ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/^a-zA-Z0-9_/_/g' \
2291    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2292  cat >> confdefs.h <<EOF
2293#define $ac_tr_lib 1
2294EOF
2295
2296  LIBS="-lnsl $LIBS"
2297
2298else
2299  echo "$ac_t""no" 1>&6
2300fi
2301
2302fi
2303
2304echo $ac_n "checking for openlog""... $ac_c" 1>&6
2305echo "configure:2306: checking for openlog" >&5
2306if eval "test \"`echo '$''{'ac_cv_func_openlog'+set}'`\" = set"; then
2307  echo $ac_n "(cached) $ac_c" 1>&6
2308else
2309  cat > conftest.$ac_ext <<EOF
2310#line 2311 "configure"
2311#include "confdefs.h"
2312/* System header to define __stub macros and hopefully few prototypes,
2313    which can conflict with char openlog(); below.  */
2314#include <assert.h>
2315/* Override any gcc2 internal prototype to avoid an error.  */
2316/* We use char because int might match the return type of a gcc2
2317    builtin and then its argument prototype would still apply.  */
2318char openlog();
2319
2320int main() {
2321
2322/* The GNU C library defines this for functions which it implements
2323    to always fail with ENOSYS.  Some functions are actually named
2324    something starting with __ and the normal name is an alias.  */
2325#if defined (__stub_openlog) || defined (__stub___openlog)
2326choke me
2327#else
2328openlog();
2329#endif
2330
2331; return 0; }
2332EOF
2333if { (eval echo configure:2334: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2334  rm -rf conftest*
2335  eval "ac_cv_func_openlog=yes"
2336else
2337  echo "configure: failed program was:" >&5
2338  cat conftest.$ac_ext >&5
2339  rm -rf conftest*
2340  eval "ac_cv_func_openlog=no"
2341fi
2342rm -f conftest*
2343fi
2344
2345if eval "test \"`echo '$ac_cv_func_'openlog`\" = yes"; then
2346  echo "$ac_t""yes" 1>&6
2347  :
2348else
2349  echo "$ac_t""no" 1>&6
2350echo $ac_n "checking for openlog in -lgen""... $ac_c" 1>&6
2351echo "configure:2352: checking for openlog in -lgen" >&5
2352ac_lib_var=`echo gen'_'openlog | sed 'y%./+-%__p_%'`
2353if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2354  echo $ac_n "(cached) $ac_c" 1>&6
2355else
2356  ac_save_LIBS="$LIBS"
2357LIBS="-lgen  $LIBS"
2358cat > conftest.$ac_ext <<EOF
2359#line 2360 "configure"
2360#include "confdefs.h"
2361/* Override any gcc2 internal prototype to avoid an error.  */
2362/* We use char because int might match the return type of a gcc2
2363    builtin and then its argument prototype would still apply.  */
2364char openlog();
2365
2366int main() {
2367openlog()
2368; return 0; }
2369EOF
2370if { (eval echo configure:2371: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2371  rm -rf conftest*
2372  eval "ac_cv_lib_$ac_lib_var=yes"
2373else
2374  echo "configure: failed program was:" >&5
2375  cat conftest.$ac_ext >&5
2376  rm -rf conftest*
2377  eval "ac_cv_lib_$ac_lib_var=no"
2378fi
2379rm -f conftest*
2380LIBS="$ac_save_LIBS"
2381
2382fi
2383if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2384  echo "$ac_t""yes" 1>&6
2385    ac_tr_lib=HAVE_LIB`echo gen | sed -e 's/^a-zA-Z0-9_/_/g' \
2386    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2387  cat >> confdefs.h <<EOF
2388#define $ac_tr_lib 1
2389EOF
2390
2391  LIBS="-lgen $LIBS"
2392
2393else
2394  echo "$ac_t""no" 1>&6
2395fi
2396
2397fi
2398
2399
2400echo $ac_n "checking for sched_setscheduler in -lrt""... $ac_c" 1>&6
2401echo "configure:2402: checking for sched_setscheduler in -lrt" >&5
2402ac_lib_var=`echo rt'_'sched_setscheduler | sed 'y%./+-%__p_%'`
2403if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2404  echo $ac_n "(cached) $ac_c" 1>&6
2405else
2406  ac_save_LIBS="$LIBS"
2407LIBS="-lrt  $LIBS"
2408cat > conftest.$ac_ext <<EOF
2409#line 2410 "configure"
2410#include "confdefs.h"
2411/* Override any gcc2 internal prototype to avoid an error.  */
2412/* We use char because int might match the return type of a gcc2
2413    builtin and then its argument prototype would still apply.  */
2414char sched_setscheduler();
2415
2416int main() {
2417sched_setscheduler()
2418; return 0; }
2419EOF
2420if { (eval echo configure:2421: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2421  rm -rf conftest*
2422  eval "ac_cv_lib_$ac_lib_var=yes"
2423else
2424  echo "configure: failed program was:" >&5
2425  cat conftest.$ac_ext >&5
2426  rm -rf conftest*
2427  eval "ac_cv_lib_$ac_lib_var=no"
2428fi
2429rm -f conftest*
2430LIBS="$ac_save_LIBS"
2431
2432fi
2433if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2434  echo "$ac_t""yes" 1>&6
2435    ac_tr_lib=HAVE_LIB`echo rt | sed -e 's/[^a-zA-Z0-9_]/_/g' \
2436    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2437  cat >> confdefs.h <<EOF
2438#define $ac_tr_lib 1
2439EOF
2440
2441  LIBS="-lrt $LIBS"
2442
2443else
2444  echo "$ac_t""no" 1>&6
2445echo $ac_n "checking for sched_setscheduler in -lposix4""... $ac_c" 1>&6
2446echo "configure:2447: checking for sched_setscheduler in -lposix4" >&5
2447ac_lib_var=`echo posix4'_'sched_setscheduler | sed 'y%./+-%__p_%'`
2448if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2449  echo $ac_n "(cached) $ac_c" 1>&6
2450else
2451  ac_save_LIBS="$LIBS"
2452LIBS="-lposix4  $LIBS"
2453cat > conftest.$ac_ext <<EOF
2454#line 2455 "configure"
2455#include "confdefs.h"
2456/* Override any gcc2 internal prototype to avoid an error.  */
2457/* We use char because int might match the return type of a gcc2
2458    builtin and then its argument prototype would still apply.  */
2459char sched_setscheduler();
2460
2461int main() {
2462sched_setscheduler()
2463; return 0; }
2464EOF
2465if { (eval echo configure:2466: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2466  rm -rf conftest*
2467  eval "ac_cv_lib_$ac_lib_var=yes"
2468else
2469  echo "configure: failed program was:" >&5
2470  cat conftest.$ac_ext >&5
2471  rm -rf conftest*
2472  eval "ac_cv_lib_$ac_lib_var=no"
2473fi
2474rm -f conftest*
2475LIBS="$ac_save_LIBS"
2476
2477fi
2478if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2479  echo "$ac_t""yes" 1>&6
2480    ac_tr_lib=HAVE_LIB`echo posix4 | sed -e 's/^a-zA-Z0-9_/_/g' \
2481    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2482  cat >> confdefs.h <<EOF
2483#define $ac_tr_lib 1
2484EOF
2485
2486  LIBS="-lposix4 $LIBS"
2487
2488else
2489  echo "$ac_t""no" 1>&6
2490fi
2491
2492fi
2493
2494echo $ac_n "checking for setsockopt""... $ac_c" 1>&6
2495echo "configure:2496: checking for setsockopt" >&5
2496if eval "test \"`echo '$''{'ac_cv_func_setsockopt'+set}'`\" = set"; then
2497  echo $ac_n "(cached) $ac_c" 1>&6
2498else
2499  cat > conftest.$ac_ext <<EOF
2500#line 2501 "configure"
2501#include "confdefs.h"
2502/* System header to define __stub macros and hopefully few prototypes,
2503    which can conflict with char setsockopt(); below.  */
2504#include <assert.h>
2505/* Override any gcc2 internal prototype to avoid an error.  */
2506/* We use char because int might match the return type of a gcc2
2507    builtin and then its argument prototype would still apply.  */
2508char setsockopt();
2509
2510int main() {
2511
2512/* The GNU C library defines this for functions which it implements
2513    to always fail with ENOSYS.  Some functions are actually named
2514    something starting with __ and the normal name is an alias.  */
2515#if defined (__stub_setsockopt) || defined (__stub___setsockopt)
2516choke me
2517#else
2518setsockopt();
2519#endif
2520
2521; return 0; }
2522EOF
2523if { (eval echo configure:2524: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2524  rm -rf conftest*
2525  eval "ac_cv_func_setsockopt=yes"
2526else
2527  echo "configure: failed program was:" >&5
2528  cat conftest.$ac_ext >&5
2529  rm -rf conftest*
2530  eval "ac_cv_func_setsockopt=no"
2531fi
2532rm -f conftest*
2533fi
2534
2535if eval "test \"`echo '$ac_cv_func_'setsockopt`\" = yes"; then
2536  echo "$ac_t""yes" 1>&6
2537  :
2538else
2539  echo "$ac_t""no" 1>&6
2540echo $ac_n "checking for setsockopt in -lsocket""... $ac_c" 1>&6
2541echo "configure:2542: checking for setsockopt in -lsocket" >&5
2542ac_lib_var=`echo socket'_'setsockopt | sed 'y%./+-%__p_%'`
2543if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2544  echo $ac_n "(cached) $ac_c" 1>&6
2545else
2546  ac_save_LIBS="$LIBS"
2547LIBS="-lsocket  $LIBS"
2548cat > conftest.$ac_ext <<EOF
2549#line 2550 "configure"
2550#include "confdefs.h"
2551/* Override any gcc2 internal prototype to avoid an error.  */
2552/* We use char because int might match the return type of a gcc2
2553    builtin and then its argument prototype would still apply.  */
2554char setsockopt();
2555
2556int main() {
2557setsockopt()
2558; return 0; }
2559EOF
2560if { (eval echo configure:2561: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2561  rm -rf conftest*
2562  eval "ac_cv_lib_$ac_lib_var=yes"
2563else
2564  echo "configure: failed program was:" >&5
2565  cat conftest.$ac_ext >&5
2566  rm -rf conftest*
2567  eval "ac_cv_lib_$ac_lib_var=no"
2568fi
2569rm -f conftest*
2570LIBS="$ac_save_LIBS"
2571
2572fi
2573if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2574  echo "$ac_t""yes" 1>&6
2575    ac_tr_lib=HAVE_LIB`echo socket | sed -e 's/^a-zA-Z0-9_/_/g' \
2576    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2577  cat >> confdefs.h <<EOF
2578#define $ac_tr_lib 1
2579EOF
2580
2581  LIBS="-lsocket $LIBS"
2582
2583else
2584  echo "$ac_t""no" 1>&6
2585fi
2586
2587fi
2588
2589
2590echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
2591echo "configure:2592: checking for ANSI C header files" >&5
2592if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
2593  echo $ac_n "(cached) $ac_c" 1>&6
2594else
2595  cat > conftest.$ac_ext <<EOF
2596#line 2597 "configure"
2597#include "confdefs.h"
2598#include <stdlib.h>
2599#include <stdarg.h>
2600#include <string.h>
2601#include <float.h>
2602EOF
2603ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2604{ (eval echo configure:2605: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2605ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2606if test -z "$ac_err"; then
2607  rm -rf conftest*
2608  ac_cv_header_stdc=yes
2609else
2610  echo "$ac_err" >&5
2611  echo "configure: failed program was:" >&5
2612  cat conftest.$ac_ext >&5
2613  rm -rf conftest*
2614  ac_cv_header_stdc=no
2615fi
2616rm -f conftest*
2617
2618if test $ac_cv_header_stdc = yes; then
2619  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
2620cat > conftest.$ac_ext <<EOF
2621#line 2622 "configure"
2622#include "confdefs.h"
2623#include <string.h>
2624EOF
2625if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2626  egrep "memchr" >/dev/null 2>&1; then
2627  :
2628else
2629  rm -rf conftest*
2630  ac_cv_header_stdc=no
2631fi
2632rm -f conftest*
2633
2634fi
2635
2636if test $ac_cv_header_stdc = yes; then
2637  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
2638cat > conftest.$ac_ext <<EOF
2639#line 2640 "configure"
2640#include "confdefs.h"
2641#include <stdlib.h>
2642EOF
2643if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2644  egrep "free" >/dev/null 2>&1; then
2645  :
2646else
2647  rm -rf conftest*
2648  ac_cv_header_stdc=no
2649fi
2650rm -f conftest*
2651
2652fi
2653
2654if test $ac_cv_header_stdc = yes; then
2655  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
2656if test "$cross_compiling" = yes; then
2657  :
2658else
2659  cat > conftest.$ac_ext <<EOF
2660#line 2661 "configure"
2661#include "confdefs.h"
2662#include <ctype.h>
2663#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
2664#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
2665#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
2666int main () { int i; for (i = 0; i < 256; i++)
2667if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
2668exit (0); }
2669
2670EOF
2671if { (eval echo configure:2672: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2672then
2673  :
2674else
2675  echo "configure: failed program was:" >&5
2676  cat conftest.$ac_ext >&5
2677  rm -fr conftest*
2678  ac_cv_header_stdc=no
2679fi
2680rm -fr conftest*
2681fi
2682
2683fi
2684fi
2685
2686echo "$ac_t""$ac_cv_header_stdc" 1>&6
2687if test $ac_cv_header_stdc = yes; then
2688  cat >> confdefs.h <<\EOF
2689#define STDC_HEADERS 1
2690EOF
2691
2692fi
2693
2694for ac_hdr in bstring.h errno.h fcntl.h memory.h netdb.h poll.h resolv.h
2695do
2696ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2697echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2698echo "configure:2699: checking for $ac_hdr" >&5
2699if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2700  echo $ac_n "(cached) $ac_c" 1>&6
2701else
2702  cat > conftest.$ac_ext <<EOF
2703#line 2704 "configure"
2704#include "confdefs.h"
2705#include <$ac_hdr>
2706EOF
2707ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2708{ (eval echo configure:2709: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2709ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2710if test -z "$ac_err"; then
2711  rm -rf conftest*
2712  eval "ac_cv_header_$ac_safe=yes"
2713else
2714  echo "$ac_err" >&5
2715  echo "configure: failed program was:" >&5
2716  cat conftest.$ac_ext >&5
2717  rm -rf conftest*
2718  eval "ac_cv_header_$ac_safe=no"
2719fi
2720rm -f conftest*
2721fi
2722if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2723  echo "$ac_t""yes" 1>&6
2724    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2725  cat >> confdefs.h <<EOF
2726#define $ac_tr_hdr 1
2727EOF
2728
2729else
2730  echo "$ac_t""no" 1>&6
2731fi
2732done
2733
2734for ac_hdr in sched.h sgtty.h stdlib.h string.h termio.h termios.h
2735do
2736ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2737echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2738echo "configure:2739: checking for $ac_hdr" >&5
2739if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2740  echo $ac_n "(cached) $ac_c" 1>&6
2741else
2742  cat > conftest.$ac_ext <<EOF
2743#line 2744 "configure"
2744#include "confdefs.h"
2745#include <$ac_hdr>
2746EOF
2747ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2748{ (eval echo configure:2749: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2749ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2750if test -z "$ac_err"; then
2751  rm -rf conftest*
2752  eval "ac_cv_header_$ac_safe=yes"
2753else
2754  echo "$ac_err" >&5
2755  echo "configure: failed program was:" >&5
2756  cat conftest.$ac_ext >&5
2757  rm -rf conftest*
2758  eval "ac_cv_header_$ac_safe=no"
2759fi
2760rm -f conftest*
2761fi
2762if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2763  echo "$ac_t""yes" 1>&6
2764    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2765  cat >> confdefs.h <<EOF
2766#define $ac_tr_hdr 1
2767EOF
2768
2769else
2770  echo "$ac_t""no" 1>&6
2771fi
2772done
2773
2774for ac_hdr in timepps.h timex.h unistd.h utmp.h utmpx.h
2775do
2776ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2777echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2778echo "configure:2779: checking for $ac_hdr" >&5
2779if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2780  echo $ac_n "(cached) $ac_c" 1>&6
2781else
2782  cat > conftest.$ac_ext <<EOF
2783#line 2784 "configure"
2784#include "confdefs.h"
2785#include <$ac_hdr>
2786EOF
2787ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2788{ (eval echo configure:2789: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2789ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2790if test -z "$ac_err"; then
2791  rm -rf conftest*
2792  eval "ac_cv_header_$ac_safe=yes"
2793else
2794  echo "$ac_err" >&5
2795  echo "configure: failed program was:" >&5
2796  cat conftest.$ac_ext >&5
2797  rm -rf conftest*
2798  eval "ac_cv_header_$ac_safe=no"
2799fi
2800rm -f conftest*
2801fi
2802if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2803  echo "$ac_t""yes" 1>&6
2804    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2805  cat >> confdefs.h <<EOF
2806#define $ac_tr_hdr 1
2807EOF
2808
2809else
2810  echo "$ac_t""no" 1>&6
2811fi
2812done
2813
2814for ac_hdr in arpa/nameser.h net/if.h netinet/in_systm.h netinet/in.h
2815do
2816ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2817echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2818echo "configure:2819: checking for $ac_hdr" >&5
2819if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2820  echo $ac_n "(cached) $ac_c" 1>&6
2821else
2822  cat > conftest.$ac_ext <<EOF
2823#line 2824 "configure"
2824#include "confdefs.h"
2825#include <$ac_hdr>
2826EOF
2827ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2828{ (eval echo configure:2829: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2829ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2830if test -z "$ac_err"; then
2831  rm -rf conftest*
2832  eval "ac_cv_header_$ac_safe=yes"
2833else
2834  echo "$ac_err" >&5
2835  echo "configure: failed program was:" >&5
2836  cat conftest.$ac_ext >&5
2837  rm -rf conftest*
2838  eval "ac_cv_header_$ac_safe=no"
2839fi
2840rm -f conftest*
2841fi
2842if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2843  echo "$ac_t""yes" 1>&6
2844    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2845  cat >> confdefs.h <<EOF
2846#define $ac_tr_hdr 1
2847EOF
2848
2849else
2850  echo "$ac_t""no" 1>&6
2851fi
2852done
2853
2854for ac_hdr in netinfo/ni.h
2855do
2856ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2857echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2858echo "configure:2859: checking for $ac_hdr" >&5
2859if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2860  echo $ac_n "(cached) $ac_c" 1>&6
2861else
2862  cat > conftest.$ac_ext <<EOF
2863#line 2864 "configure"
2864#include "confdefs.h"
2865#include <$ac_hdr>
2866EOF
2867ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2868{ (eval echo configure:2869: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2869ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2870if test -z "$ac_err"; then
2871  rm -rf conftest*
2872  eval "ac_cv_header_$ac_safe=yes"
2873else
2874  echo "$ac_err" >&5
2875  echo "configure: failed program was:" >&5
2876  cat conftest.$ac_ext >&5
2877  rm -rf conftest*
2878  eval "ac_cv_header_$ac_safe=no"
2879fi
2880rm -f conftest*
2881fi
2882if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2883  echo "$ac_t""yes" 1>&6
2884    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2885  cat >> confdefs.h <<EOF
2886#define $ac_tr_hdr 1
2887EOF
2888 cat >> confdefs.h <<\EOF
2889#define HAVE_NETINFO 1
2890EOF
2891
2892else
2893  echo "$ac_t""no" 1>&6
2894fi
2895done
2896
2897for ac_hdr in sun/audioio.h sys/audioio.h
2898do
2899ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2900echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2901echo "configure:2902: checking for $ac_hdr" >&5
2902if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2903  echo $ac_n "(cached) $ac_c" 1>&6
2904else
2905  cat > conftest.$ac_ext <<EOF
2906#line 2907 "configure"
2907#include "confdefs.h"
2908#include <$ac_hdr>
2909EOF
2910ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2911{ (eval echo configure:2912: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2912ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2913if test -z "$ac_err"; then
2914  rm -rf conftest*
2915  eval "ac_cv_header_$ac_safe=yes"
2916else
2917  echo "$ac_err" >&5
2918  echo "configure: failed program was:" >&5
2919  cat conftest.$ac_ext >&5
2920  rm -rf conftest*
2921  eval "ac_cv_header_$ac_safe=no"
2922fi
2923rm -f conftest*
2924fi
2925if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2926  echo "$ac_t""yes" 1>&6
2927    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2928  cat >> confdefs.h <<EOF
2929#define $ac_tr_hdr 1
2930EOF
2931
2932else
2933  echo "$ac_t""no" 1>&6
2934fi
2935done
2936
2937for ac_hdr in sys/clkdefs.h sys/file.h
2938do
2939ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2940echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2941echo "configure:2942: checking for $ac_hdr" >&5
2942if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2943  echo $ac_n "(cached) $ac_c" 1>&6
2944else
2945  cat > conftest.$ac_ext <<EOF
2946#line 2947 "configure"
2947#include "confdefs.h"
2948#include <$ac_hdr>
2949EOF
2950ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2951{ (eval echo configure:2952: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2952ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2953if test -z "$ac_err"; then
2954  rm -rf conftest*
2955  eval "ac_cv_header_$ac_safe=yes"
2956else
2957  echo "$ac_err" >&5
2958  echo "configure: failed program was:" >&5
2959  cat conftest.$ac_ext >&5
2960  rm -rf conftest*
2961  eval "ac_cv_header_$ac_safe=no"
2962fi
2963rm -f conftest*
2964fi
2965if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2966  echo "$ac_t""yes" 1>&6
2967    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
2968  cat >> confdefs.h <<EOF
2969#define $ac_tr_hdr 1
2970EOF
2971
2972else
2973  echo "$ac_t""no" 1>&6
2974fi
2975done
2976
2977case "$target" in
2978 *-*-sunos4*) ;;
2979 *) for ac_hdr in sys/ioctl.h
2980do
2981ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
2982echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
2983echo "configure:2984: checking for $ac_hdr" >&5
2984if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2985  echo $ac_n "(cached) $ac_c" 1>&6
2986else
2987  cat > conftest.$ac_ext <<EOF
2988#line 2989 "configure"
2989#include "confdefs.h"
2990#include <$ac_hdr>
2991EOF
2992ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2993{ (eval echo configure:2994: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2994ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2995if test -z "$ac_err"; then
2996  rm -rf conftest*
2997  eval "ac_cv_header_$ac_safe=yes"
2998else
2999  echo "$ac_err" >&5
3000  echo "configure: failed program was:" >&5
3001  cat conftest.$ac_ext >&5
3002  rm -rf conftest*
3003  eval "ac_cv_header_$ac_safe=no"
3004fi
3005rm -f conftest*
3006fi
3007if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3008  echo "$ac_t""yes" 1>&6
3009    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3010  cat >> confdefs.h <<EOF
3011#define $ac_tr_hdr 1
3012EOF
3013
3014else
3015  echo "$ac_t""no" 1>&6
3016fi
3017done
3018
3019    ;;
3020esac
3021for ac_hdr in sys/lock.h sys/mman.h sys/modem.h sys/param.h sys/ppsclock.h
3022do
3023ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3024echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3025echo "configure:3026: checking for $ac_hdr" >&5
3026if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3027  echo $ac_n "(cached) $ac_c" 1>&6
3028else
3029  cat > conftest.$ac_ext <<EOF
3030#line 3031 "configure"
3031#include "confdefs.h"
3032#include <$ac_hdr>
3033EOF
3034ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3035{ (eval echo configure:3036: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3036ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3037if test -z "$ac_err"; then
3038  rm -rf conftest*
3039  eval "ac_cv_header_$ac_safe=yes"
3040else
3041  echo "$ac_err" >&5
3042  echo "configure: failed program was:" >&5
3043  cat conftest.$ac_ext >&5
3044  rm -rf conftest*
3045  eval "ac_cv_header_$ac_safe=no"
3046fi
3047rm -f conftest*
3048fi
3049if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3050  echo "$ac_t""yes" 1>&6
3051    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3052  cat >> confdefs.h <<EOF
3053#define $ac_tr_hdr 1
3054EOF
3055
3056else
3057  echo "$ac_t""no" 1>&6
3058fi
3059done
3060
3061for ac_hdr in sys/ppstime.h sys/proc.h sys/resource.h sys/sched.h
3062do
3063ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3064echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3065echo "configure:3066: checking for $ac_hdr" >&5
3066if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3067  echo $ac_n "(cached) $ac_c" 1>&6
3068else
3069  cat > conftest.$ac_ext <<EOF
3070#line 3071 "configure"
3071#include "confdefs.h"
3072#include <$ac_hdr>
3073EOF
3074ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3075{ (eval echo configure:3076: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3076ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3077if test -z "$ac_err"; then
3078  rm -rf conftest*
3079  eval "ac_cv_header_$ac_safe=yes"
3080else
3081  echo "$ac_err" >&5
3082  echo "configure: failed program was:" >&5
3083  cat conftest.$ac_ext >&5
3084  rm -rf conftest*
3085  eval "ac_cv_header_$ac_safe=no"
3086fi
3087rm -f conftest*
3088fi
3089if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3090  echo "$ac_t""yes" 1>&6
3091    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3092  cat >> confdefs.h <<EOF
3093#define $ac_tr_hdr 1
3094EOF
3095
3096else
3097  echo "$ac_t""no" 1>&6
3098fi
3099done
3100
3101case "$target" in
3102 *-*-sco*)
3103    for ac_hdr in sys/sio.h
3104do
3105ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3106echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3107echo "configure:3108: checking for $ac_hdr" >&5
3108if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3109  echo $ac_n "(cached) $ac_c" 1>&6
3110else
3111  cat > conftest.$ac_ext <<EOF
3112#line 3113 "configure"
3113#include "confdefs.h"
3114#include <$ac_hdr>
3115EOF
3116ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3117{ (eval echo configure:3118: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3118ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3119if test -z "$ac_err"; then
3120  rm -rf conftest*
3121  eval "ac_cv_header_$ac_safe=yes"
3122else
3123  echo "$ac_err" >&5
3124  echo "configure: failed program was:" >&5
3125  cat conftest.$ac_ext >&5
3126  rm -rf conftest*
3127  eval "ac_cv_header_$ac_safe=no"
3128fi
3129rm -f conftest*
3130fi
3131if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3132  echo "$ac_t""yes" 1>&6
3133    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3134  cat >> confdefs.h <<EOF
3135#define $ac_tr_hdr 1
3136EOF
3137
3138else
3139  echo "$ac_t""no" 1>&6
3140fi
3141done
3142
3143    ;;
3144esac
3145for ac_hdr in sys/select.h sys/sockio.h sys/stat.h sys/stream.h
3146do
3147ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3148echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3149echo "configure:3150: checking for $ac_hdr" >&5
3150if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3151  echo $ac_n "(cached) $ac_c" 1>&6
3152else
3153  cat > conftest.$ac_ext <<EOF
3154#line 3155 "configure"
3155#include "confdefs.h"
3156#include <$ac_hdr>
3157EOF
3158ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3159{ (eval echo configure:3160: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3160ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3161if test -z "$ac_err"; then
3162  rm -rf conftest*
3163  eval "ac_cv_header_$ac_safe=yes"
3164else
3165  echo "$ac_err" >&5
3166  echo "configure: failed program was:" >&5
3167  cat conftest.$ac_ext >&5
3168  rm -rf conftest*
3169  eval "ac_cv_header_$ac_safe=no"
3170fi
3171rm -f conftest*
3172fi
3173if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3174  echo "$ac_t""yes" 1>&6
3175    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3176  cat >> confdefs.h <<EOF
3177#define $ac_tr_hdr 1
3178EOF
3179
3180else
3181  echo "$ac_t""no" 1>&6
3182fi
3183done
3184
3185for ac_hdr in sys/stropts.h sys/sysctl.h sys/syssgi.h sys/termios.h
3186do
3187ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3188echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3189echo "configure:3190: checking for $ac_hdr" >&5
3190if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3191  echo $ac_n "(cached) $ac_c" 1>&6
3192else
3193  cat > conftest.$ac_ext <<EOF
3194#line 3195 "configure"
3195#include "confdefs.h"
3196#include <$ac_hdr>
3197EOF
3198ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3199{ (eval echo configure:3200: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3200ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3201if test -z "$ac_err"; then
3202  rm -rf conftest*
3203  eval "ac_cv_header_$ac_safe=yes"
3204else
3205  echo "$ac_err" >&5
3206  echo "configure: failed program was:" >&5
3207  cat conftest.$ac_ext >&5
3208  rm -rf conftest*
3209  eval "ac_cv_header_$ac_safe=no"
3210fi
3211rm -f conftest*
3212fi
3213if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3214  echo "$ac_t""yes" 1>&6
3215    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3216  cat >> confdefs.h <<EOF
3217#define $ac_tr_hdr 1
3218EOF
3219
3220else
3221  echo "$ac_t""no" 1>&6
3222fi
3223done
3224
3225for ac_hdr in sys/time.h
3226do
3227ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3228echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3229echo "configure:3230: checking for $ac_hdr" >&5
3230if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3231  echo $ac_n "(cached) $ac_c" 1>&6
3232else
3233  cat > conftest.$ac_ext <<EOF
3234#line 3235 "configure"
3235#include "confdefs.h"
3236#include <$ac_hdr>
3237EOF
3238ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3239{ (eval echo configure:3240: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3240ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3241if test -z "$ac_err"; then
3242  rm -rf conftest*
3243  eval "ac_cv_header_$ac_safe=yes"
3244else
3245  echo "$ac_err" >&5
3246  echo "configure: failed program was:" >&5
3247  cat conftest.$ac_ext >&5
3248  rm -rf conftest*
3249  eval "ac_cv_header_$ac_safe=no"
3250fi
3251rm -f conftest*
3252fi
3253if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3254  echo "$ac_t""yes" 1>&6
3255    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3256  cat >> confdefs.h <<EOF
3257#define $ac_tr_hdr 1
3258EOF
3259
3260else
3261  echo "$ac_t""no" 1>&6
3262fi
3263done
3264
3265cat > conftest.$ac_ext <<EOF
3266#line 3267 "configure"
3267#include "confdefs.h"
3268#include <sys/timepps.h>
3269#ifdef PPS_API_VERS_1
3270yes
3271#endif
3272
3273EOF
3274if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3275  egrep "yes" >/dev/null 2>&1; then
3276  rm -rf conftest*
3277  for ac_hdr in sys/timepps.h
3278do
3279ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3280echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3281echo "configure:3282: checking for $ac_hdr" >&5
3282if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3283  echo $ac_n "(cached) $ac_c" 1>&6
3284else
3285  cat > conftest.$ac_ext <<EOF
3286#line 3287 "configure"
3287#include "confdefs.h"
3288#include <$ac_hdr>
3289EOF
3290ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3291{ (eval echo configure:3292: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3292ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3293if test -z "$ac_err"; then
3294  rm -rf conftest*
3295  eval "ac_cv_header_$ac_safe=yes"
3296else
3297  echo "$ac_err" >&5
3298  echo "configure: failed program was:" >&5
3299  cat conftest.$ac_ext >&5
3300  rm -rf conftest*
3301  eval "ac_cv_header_$ac_safe=no"
3302fi
3303rm -f conftest*
3304fi
3305if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3306  echo "$ac_t""yes" 1>&6
3307    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3308  cat >> confdefs.h <<EOF
3309#define $ac_tr_hdr 1
3310EOF
3311
3312else
3313  echo "$ac_t""no" 1>&6
3314fi
3315done
3316
3317fi
3318rm -f conftest*
3319
3320for ac_hdr in sys/timers.h sys/timex.h sys/tpro.h sys/types.h sys/wait.h
3321do
3322ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3323echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3324echo "configure:3325: checking for $ac_hdr" >&5
3325if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3326  echo $ac_n "(cached) $ac_c" 1>&6
3327else
3328  cat > conftest.$ac_ext <<EOF
3329#line 3330 "configure"
3330#include "confdefs.h"
3331#include <$ac_hdr>
3332EOF
3333ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3334{ (eval echo configure:3335: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3335ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3336if test -z "$ac_err"; then
3337  rm -rf conftest*
3338  eval "ac_cv_header_$ac_safe=yes"
3339else
3340  echo "$ac_err" >&5
3341  echo "configure: failed program was:" >&5
3342  cat conftest.$ac_ext >&5
3343  rm -rf conftest*
3344  eval "ac_cv_header_$ac_safe=no"
3345fi
3346rm -f conftest*
3347fi
3348if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3349  echo "$ac_t""yes" 1>&6
3350    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3351  cat >> confdefs.h <<EOF
3352#define $ac_tr_hdr 1
3353EOF
3354
3355else
3356  echo "$ac_t""no" 1>&6
3357fi
3358done
3359
3360echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
3361echo "configure:3362: checking whether time.h and sys/time.h may both be included" >&5
3362if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
3363  echo $ac_n "(cached) $ac_c" 1>&6
3364else
3365  cat > conftest.$ac_ext <<EOF
3366#line 3367 "configure"
3367#include "confdefs.h"
3368#include <sys/types.h>
3369#include <sys/time.h>
3370#include <time.h>
3371int main() {
3372struct tm *tp;
3373; return 0; }
3374EOF
3375if { (eval echo configure:3376: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3376  rm -rf conftest*
3377  ac_cv_header_time=yes
3378else
3379  echo "configure: failed program was:" >&5
3380  cat conftest.$ac_ext >&5
3381  rm -rf conftest*
3382  ac_cv_header_time=no
3383fi
3384rm -f conftest*
3385fi
3386
3387echo "$ac_t""$ac_cv_header_time" 1>&6
3388if test $ac_cv_header_time = yes; then
3389  cat >> confdefs.h <<\EOF
3390#define TIME_WITH_SYS_TIME 1
3391EOF
3392
3393fi
3394
3395case "$target" in
3396*-convex-*)
3397  for ac_hdr in /sys/sync/queue.h /sys/sync/sema.h
3398do
3399ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3400echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3401echo "configure:3402: checking for $ac_hdr" >&5
3402if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3403  echo $ac_n "(cached) $ac_c" 1>&6
3404else
3405  cat > conftest.$ac_ext <<EOF
3406#line 3407 "configure"
3407#include "confdefs.h"
3408#include <$ac_hdr>
3409EOF
3410ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3411{ (eval echo configure:3412: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3412ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3413if test -z "$ac_err"; then
3414  rm -rf conftest*
3415  eval "ac_cv_header_$ac_safe=yes"
3416else
3417  echo "$ac_err" >&5
3418  echo "configure: failed program was:" >&5
3419  cat conftest.$ac_ext >&5
3420  rm -rf conftest*
3421  eval "ac_cv_header_$ac_safe=no"
3422fi
3423rm -f conftest*
3424fi
3425if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3426  echo "$ac_t""yes" 1>&6
3427    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3428  cat >> confdefs.h <<EOF
3429#define $ac_tr_hdr 1
3430EOF
3431
3432else
3433  echo "$ac_t""no" 1>&6
3434fi
3435done
3436
3437  ;;
3438*-*-bsdi*)
3439  for ac_hdr in machine/inline.h sys/pcl720.h sys/i8253.h
3440do
3441ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3442echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3443echo "configure:3444: checking for $ac_hdr" >&5
3444if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3445  echo $ac_n "(cached) $ac_c" 1>&6
3446else
3447  cat > conftest.$ac_ext <<EOF
3448#line 3449 "configure"
3449#include "confdefs.h"
3450#include <$ac_hdr>
3451EOF
3452ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3453{ (eval echo configure:3454: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3454ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3455if test -z "$ac_err"; then
3456  rm -rf conftest*
3457  eval "ac_cv_header_$ac_safe=yes"
3458else
3459  echo "$ac_err" >&5
3460  echo "configure: failed program was:" >&5
3461  cat conftest.$ac_ext >&5
3462  rm -rf conftest*
3463  eval "ac_cv_header_$ac_safe=no"
3464fi
3465rm -f conftest*
3466fi
3467if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3468  echo "$ac_t""yes" 1>&6
3469    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3470  cat >> confdefs.h <<EOF
3471#define $ac_tr_hdr 1
3472EOF
3473
3474else
3475  echo "$ac_t""no" 1>&6
3476fi
3477done
3478
3479  ;;
3480esac
3481
3482ac_safe=`echo "nlist.h" | sed 'y%./+-%__p_%'`
3483echo $ac_n "checking for nlist.h""... $ac_c" 1>&6
3484echo "configure:3485: checking for nlist.h" >&5
3485if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3486  echo $ac_n "(cached) $ac_c" 1>&6
3487else
3488  cat > conftest.$ac_ext <<EOF
3489#line 3490 "configure"
3490#include "confdefs.h"
3491#include <nlist.h>
3492EOF
3493ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3494{ (eval echo configure:3495: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3495ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3496if test -z "$ac_err"; then
3497  rm -rf conftest*
3498  eval "ac_cv_header_$ac_safe=yes"
3499else
3500  echo "$ac_err" >&5
3501  echo "configure: failed program was:" >&5
3502  cat conftest.$ac_ext >&5
3503  rm -rf conftest*
3504  eval "ac_cv_header_$ac_safe=no"
3505fi
3506rm -f conftest*
3507fi
3508if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3509  echo "$ac_t""yes" 1>&6
3510  cat >> confdefs.h <<\EOF
3511#define NLIST_STRUCT 1
3512EOF
3513
3514echo $ac_n "checking for n_un in struct nlist""... $ac_c" 1>&6
3515echo "configure:3516: checking for n_un in struct nlist" >&5
3516if eval "test \"`echo '$''{'ac_cv_struct_nlist_n_un'+set}'`\" = set"; then
3517  echo $ac_n "(cached) $ac_c" 1>&6
3518else
3519  cat > conftest.$ac_ext <<EOF
3520#line 3521 "configure"
3521#include "confdefs.h"
3522#include <nlist.h>
3523int main() {
3524struct nlist n; n.n_un.n_name = 0;
3525; return 0; }
3526EOF
3527if { (eval echo configure:3528: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3528  rm -rf conftest*
3529  ac_cv_struct_nlist_n_un=yes
3530else
3531  echo "configure: failed program was:" >&5
3532  cat conftest.$ac_ext >&5
3533  rm -rf conftest*
3534  ac_cv_struct_nlist_n_un=no
3535fi
3536rm -f conftest*
3537fi
3538
3539echo "$ac_t""$ac_cv_struct_nlist_n_un" 1>&6
3540if test $ac_cv_struct_nlist_n_un = yes; then
3541  cat >> confdefs.h <<\EOF
3542#define NLIST_NAME_UNION 1
3543EOF
3544
3545fi
3546
3547else
3548  echo "$ac_t""no" 1>&6
3549fi
3550
3551echo $ac_n "checking for basic volatile support""... $ac_c" 1>&6
3552echo "configure:3553: checking for basic volatile support" >&5
3553if eval "test \"`echo '$''{'ac_cv_c_volatile'+set}'`\" = set"; then
3554  echo $ac_n "(cached) $ac_c" 1>&6
3555else
3556  cat > conftest.$ac_ext <<EOF
3557#line 3558 "configure"
3558#include "confdefs.h"
3559
3560int main() {
3561
3562volatile int x;
3563; return 0; }
3564EOF
3565if { (eval echo configure:3566: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3566  rm -rf conftest*
3567  ac_cv_c_volatile=yes
3568else
3569  echo "configure: failed program was:" >&5
3570  cat conftest.$ac_ext >&5
3571  rm -rf conftest*
3572  ac_cv_c_volatile=no
3573fi
3574rm -f conftest*
3575
3576fi
3577
3578echo "$ac_t""$ac_cv_c_volatile" 1>&6
3579case "$ac_cv_c_volatile" in
3580 yes)
3581    ;;
3582 *) cat >> confdefs.h <<\EOF
3583#define volatile
3584EOF
3585
3586    ;;
3587esac
3588
3589case "$target" in
3590 sparc-*-solaris2*)
3591    # Assume that solaris2 is Ansi C...
3592    ;;
3593 *)
3594
3595
3596
3597echo $ac_n "checking for ${CC-cc} option to accept ANSI C""... $ac_c" 1>&6
3598echo "configure:3599: checking for ${CC-cc} option to accept ANSI C" >&5
3599if eval "test \"`echo '$''{'am_cv_prog_cc_stdc'+set}'`\" = set"; then
3600  echo $ac_n "(cached) $ac_c" 1>&6
3601else
3602  am_cv_prog_cc_stdc=no
3603ac_save_CC="$CC"
3604# Don't try gcc -ansi; that turns off useful extensions and
3605# breaks some systems' header files.
3606# AIX			-qlanglvl=ansi
3607# Ultrix and OSF/1	-std1
3608# HP-UX 10.20 and later	-Ae
3609# HP-UX older versions	-Aa -D_HPUX_SOURCE
3610# SVR4			-Xc -D__EXTENSIONS__
3611for ac_arg in "" -qlanglvl=ansi -std1 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3612do
3613  CC="$ac_save_CC $ac_arg"
3614  cat > conftest.$ac_ext <<EOF
3615#line 3616 "configure"
3616#include "confdefs.h"
3617#include <stdarg.h>
3618#include <stdio.h>
3619#include <sys/types.h>
3620#include <sys/stat.h>
3621/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3622struct buf { int x; };
3623FILE * (*rcsopen) (struct buf *, struct stat *, int);
3624static char *e (p, i)
3625     char **p;
3626     int i;
3627{
3628  return p[i];
3629}
3630static char *f (char * (*g) (char **, int), char **p, ...)
3631{
3632  char *s;
3633  va_list v;
3634  va_start (v,p);
3635  s = g (p, va_arg (v,int));
3636  va_end (v);
3637  return s;
3638}
3639int test (int i, double x);
3640struct s1 {int (*f) (int a);};
3641struct s2 {int (*f) (double a);};
3642int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3643int argc;
3644char **argv;
3645
3646int main() {
3647
3648return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3649
3650; return 0; }
3651EOF
3652if { (eval echo configure:3653: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3653  rm -rf conftest*
3654  am_cv_prog_cc_stdc="$ac_arg"; break
3655else
3656  echo "configure: failed program was:" >&5
3657  cat conftest.$ac_ext >&5
3658fi
3659rm -f conftest*
3660done
3661CC="$ac_save_CC"
3662
3663fi
3664
3665if test -z "$am_cv_prog_cc_stdc"; then
3666  echo "$ac_t""none needed" 1>&6
3667else
3668  echo "$ac_t""$am_cv_prog_cc_stdc" 1>&6
3669fi
3670case "x$am_cv_prog_cc_stdc" in
3671  x|xno) ;;
3672  *) CC="$CC $am_cv_prog_cc_stdc" ;;
3673esac
3674
3675
3676
3677echo $ac_n "checking for function prototypes""... $ac_c" 1>&6
3678echo "configure:3679: checking for function prototypes" >&5
3679if test "$am_cv_prog_cc_stdc" != no; then
3680  echo "$ac_t""yes" 1>&6
3681  cat >> confdefs.h <<\EOF
3682#define PROTOTYPES 1
3683EOF
3684
3685  U= ANSI2KNR=
3686else
3687  echo "$ac_t""no" 1>&6
3688  U=_ ANSI2KNR=./ansi2knr
3689  # Ensure some checks needed by ansi2knr itself.
3690  echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
3691echo "configure:3692: checking for ANSI C header files" >&5
3692if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
3693  echo $ac_n "(cached) $ac_c" 1>&6
3694else
3695  cat > conftest.$ac_ext <<EOF
3696#line 3697 "configure"
3697#include "confdefs.h"
3698#include <stdlib.h>
3699#include <stdarg.h>
3700#include <string.h>
3701#include <float.h>
3702EOF
3703ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3704{ (eval echo configure:3705: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3705ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3706if test -z "$ac_err"; then
3707  rm -rf conftest*
3708  ac_cv_header_stdc=yes
3709else
3710  echo "$ac_err" >&5
3711  echo "configure: failed program was:" >&5
3712  cat conftest.$ac_ext >&5
3713  rm -rf conftest*
3714  ac_cv_header_stdc=no
3715fi
3716rm -f conftest*
3717
3718if test $ac_cv_header_stdc = yes; then
3719  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3720cat > conftest.$ac_ext <<EOF
3721#line 3722 "configure"
3722#include "confdefs.h"
3723#include <string.h>
3724EOF
3725if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3726  egrep "memchr" >/dev/null 2>&1; then
3727  :
3728else
3729  rm -rf conftest*
3730  ac_cv_header_stdc=no
3731fi
3732rm -f conftest*
3733
3734fi
3735
3736if test $ac_cv_header_stdc = yes; then
3737  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3738cat > conftest.$ac_ext <<EOF
3739#line 3740 "configure"
3740#include "confdefs.h"
3741#include <stdlib.h>
3742EOF
3743if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3744  egrep "free" >/dev/null 2>&1; then
3745  :
3746else
3747  rm -rf conftest*
3748  ac_cv_header_stdc=no
3749fi
3750rm -f conftest*
3751
3752fi
3753
3754if test $ac_cv_header_stdc = yes; then
3755  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3756if test "$cross_compiling" = yes; then
3757  :
3758else
3759  cat > conftest.$ac_ext <<EOF
3760#line 3761 "configure"
3761#include "confdefs.h"
3762#include <ctype.h>
3763#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3764#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3765#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3766int main () { int i; for (i = 0; i < 256; i++)
3767if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
3768exit (0); }
3769
3770EOF
3771if { (eval echo configure:3772: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
3772then
3773  :
3774else
3775  echo "configure: failed program was:" >&5
3776  cat conftest.$ac_ext >&5
3777  rm -fr conftest*
3778  ac_cv_header_stdc=no
3779fi
3780rm -fr conftest*
3781fi
3782
3783fi
3784fi
3785
3786echo "$ac_t""$ac_cv_header_stdc" 1>&6
3787if test $ac_cv_header_stdc = yes; then
3788  cat >> confdefs.h <<\EOF
3789#define STDC_HEADERS 1
3790EOF
3791
3792fi
3793
3794  for ac_hdr in string.h
3795do
3796ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
3797echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
3798echo "configure:3799: checking for $ac_hdr" >&5
3799if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
3800  echo $ac_n "(cached) $ac_c" 1>&6
3801else
3802  cat > conftest.$ac_ext <<EOF
3803#line 3804 "configure"
3804#include "confdefs.h"
3805#include <$ac_hdr>
3806EOF
3807ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
3808{ (eval echo configure:3809: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
3809ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
3810if test -z "$ac_err"; then
3811  rm -rf conftest*
3812  eval "ac_cv_header_$ac_safe=yes"
3813else
3814  echo "$ac_err" >&5
3815  echo "configure: failed program was:" >&5
3816  cat conftest.$ac_ext >&5
3817  rm -rf conftest*
3818  eval "ac_cv_header_$ac_safe=no"
3819fi
3820rm -f conftest*
3821fi
3822if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
3823  echo "$ac_t""yes" 1>&6
3824    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
3825  cat >> confdefs.h <<EOF
3826#define $ac_tr_hdr 1
3827EOF
3828
3829else
3830  echo "$ac_t""no" 1>&6
3831fi
3832done
3833
3834fi
3835
3836    ;;
3837esac
3838echo $ac_n "checking if C compiler permits function prototypes""... $ac_c" 1>&6
3839echo "configure:3840: checking if C compiler permits function prototypes" >&5
3840if eval "test \"`echo '$''{'ac_cv_have_prototypes'+set}'`\" = set"; then
3841  echo $ac_n "(cached) $ac_c" 1>&6
3842else
3843  cat > conftest.$ac_ext <<EOF
3844#line 3845 "configure"
3845#include "confdefs.h"
3846
3847extern int foo (short);
3848int foo(short i) { return i; }
3849int main() {
3850
3851int i;
3852; return 0; }
3853EOF
3854if { (eval echo configure:3855: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3855  rm -rf conftest*
3856  ac_cv_have_prototypes=yes
3857else
3858  echo "configure: failed program was:" >&5
3859  cat conftest.$ac_ext >&5
3860  rm -rf conftest*
3861  ac_cv_have_prototypes=no
3862fi
3863rm -f conftest*
3864
3865fi
3866
3867echo "$ac_t""$ac_cv_have_prototypes" 1>&6
3868if test "$ac_cv_have_prototypes" = yes; then
3869  cat >> confdefs.h <<\EOF
3870#define HAVE_PROTOTYPES 1
3871EOF
3872
3873fi
3874
3875echo $ac_n "checking for working const""... $ac_c" 1>&6
3876echo "configure:3877: checking for working const" >&5
3877if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
3878  echo $ac_n "(cached) $ac_c" 1>&6
3879else
3880  cat > conftest.$ac_ext <<EOF
3881#line 3882 "configure"
3882#include "confdefs.h"
3883
3884int main() {
3885
3886/* Ultrix mips cc rejects this.  */
3887typedef int charset[2]; const charset x;
3888/* SunOS 4.1.1 cc rejects this.  */
3889char const *const *ccp;
3890char **p;
3891/* NEC SVR4.0.2 mips cc rejects this.  */
3892struct point {int x, y;};
3893static struct point const zero = {0,0};
3894/* AIX XL C 1.02.0.0 rejects this.
3895   It does not let you subtract one const X* pointer from another in an arm
3896   of an if-expression whose if-part is not a constant expression */
3897const char *g = "string";
3898ccp = &g + (g ? g-g : 0);
3899/* HPUX 7.0 cc rejects these. */
3900++ccp;
3901p = (char**) ccp;
3902ccp = (char const *const *) p;
3903{ /* SCO 3.2v4 cc rejects this.  */
3904  char *t;
3905  char const *s = 0 ? (char *) 0 : (char const *) 0;
3906
3907  *t++ = 0;
3908}
3909{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
3910  int x[] = {25, 17};
3911  const int *foo = &x[0];
3912  ++foo;
3913}
3914{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
3915  typedef const int *iptr;
3916  iptr p = 0;
3917  ++p;
3918}
3919{ /* AIX XL C 1.02.0.0 rejects this saying
3920     "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
3921  struct s { int j; const int *ap[3]; };
3922  struct s *b; b->j = 5;
3923}
3924{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
3925  const int foo = 10;
3926}
3927
3928; return 0; }
3929EOF
3930if { (eval echo configure:3931: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3931  rm -rf conftest*
3932  ac_cv_c_const=yes
3933else
3934  echo "configure: failed program was:" >&5
3935  cat conftest.$ac_ext >&5
3936  rm -rf conftest*
3937  ac_cv_c_const=no
3938fi
3939rm -f conftest*
3940fi
3941
3942echo "$ac_t""$ac_cv_c_const" 1>&6
3943if test $ac_cv_c_const = no; then
3944  cat >> confdefs.h <<\EOF
3945#define const
3946EOF
3947
3948fi
3949
3950case "$host" in
3951 $target)
3952    echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
3953echo "configure:3954: checking whether byte ordering is bigendian" >&5
3954if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
3955  echo $ac_n "(cached) $ac_c" 1>&6
3956else
3957  ac_cv_c_bigendian=unknown
3958# See if sys/param.h defines the BYTE_ORDER macro.
3959cat > conftest.$ac_ext <<EOF
3960#line 3961 "configure"
3961#include "confdefs.h"
3962#include <sys/types.h>
3963#include <sys/param.h>
3964int main() {
3965
3966#if !BYTE_ORDER || !BIG_ENDIAN || !LITTLE_ENDIAN
3967 bogus endian macros
3968#endif
3969; return 0; }
3970EOF
3971if { (eval echo configure:3972: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3972  rm -rf conftest*
3973  # It does; now see whether it defined to BIG_ENDIAN or not.
3974cat > conftest.$ac_ext <<EOF
3975#line 3976 "configure"
3976#include "confdefs.h"
3977#include <sys/types.h>
3978#include <sys/param.h>
3979int main() {
3980
3981#if BYTE_ORDER != BIG_ENDIAN
3982 not big endian
3983#endif
3984; return 0; }
3985EOF
3986if { (eval echo configure:3987: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3987  rm -rf conftest*
3988  ac_cv_c_bigendian=yes
3989else
3990  echo "configure: failed program was:" >&5
3991  cat conftest.$ac_ext >&5
3992  rm -rf conftest*
3993  ac_cv_c_bigendian=no
3994fi
3995rm -f conftest*
3996else
3997  echo "configure: failed program was:" >&5
3998  cat conftest.$ac_ext >&5
3999fi
4000rm -f conftest*
4001if test $ac_cv_c_bigendian = unknown; then
4002if test "$cross_compiling" = yes; then
4003    { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
4004else
4005  cat > conftest.$ac_ext <<EOF
4006#line 4007 "configure"
4007#include "confdefs.h"
4008main () {
4009  /* Are we little or big endian?  From Harbison&Steele.  */
4010  union
4011  {
4012    long l;
4013    char c[sizeof (long)];
4014  } u;
4015  u.l = 1;
4016  exit (u.c[sizeof (long) - 1] == 1);
4017}
4018EOF
4019if { (eval echo configure:4020: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
4020then
4021  ac_cv_c_bigendian=no
4022else
4023  echo "configure: failed program was:" >&5
4024  cat conftest.$ac_ext >&5
4025  rm -fr conftest*
4026  ac_cv_c_bigendian=yes
4027fi
4028rm -fr conftest*
4029fi
4030
4031fi
4032fi
4033
4034echo "$ac_t""$ac_cv_c_bigendian" 1>&6
4035if test $ac_cv_c_bigendian = yes; then
4036  cat >> confdefs.h <<\EOF
4037#define WORDS_BIGENDIAN 1
4038EOF
4039
4040fi
4041
4042    ;;
4043 *) case "$target" in
4044     i*86-*-vxworks*)
4045	# LITTLEENDIAN
4046	;;
4047     *-*-vxworks*)
4048	cat >> confdefs.h <<\EOF
4049#define WORDS_BIGENDIAN 1
4050EOF
4051
4052	;;
4053     *) { echo "configure: error: Cross-compiling needs explicit byte order" 1>&2; exit 1; }
4054	;;
4055    esac
4056    ;;
4057esac
4058echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
4059echo "configure:4060: checking return type of signal handlers" >&5
4060if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
4061  echo $ac_n "(cached) $ac_c" 1>&6
4062else
4063  cat > conftest.$ac_ext <<EOF
4064#line 4065 "configure"
4065#include "confdefs.h"
4066#include <sys/types.h>
4067#include <signal.h>
4068#ifdef signal
4069#undef signal
4070#endif
4071#ifdef __cplusplus
4072extern "C" void (*signal (int, void (*)(int)))(int);
4073#else
4074void (*signal ()) ();
4075#endif
4076
4077int main() {
4078int i;
4079; return 0; }
4080EOF
4081if { (eval echo configure:4082: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4082  rm -rf conftest*
4083  ac_cv_type_signal=void
4084else
4085  echo "configure: failed program was:" >&5
4086  cat conftest.$ac_ext >&5
4087  rm -rf conftest*
4088  ac_cv_type_signal=int
4089fi
4090rm -f conftest*
4091fi
4092
4093echo "$ac_t""$ac_cv_type_signal" 1>&6
4094cat >> confdefs.h <<EOF
4095#define RETSIGTYPE $ac_cv_type_signal
4096EOF
4097
4098
4099echo $ac_n "checking for off_t""... $ac_c" 1>&6
4100echo "configure:4101: checking for off_t" >&5
4101if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
4102  echo $ac_n "(cached) $ac_c" 1>&6
4103else
4104  cat > conftest.$ac_ext <<EOF
4105#line 4106 "configure"
4106#include "confdefs.h"
4107#include <sys/types.h>
4108#if STDC_HEADERS
4109#include <stdlib.h>
4110#include <stddef.h>
4111#endif
4112EOF
4113if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4114  egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
4115  rm -rf conftest*
4116  ac_cv_type_off_t=yes
4117else
4118  rm -rf conftest*
4119  ac_cv_type_off_t=no
4120fi
4121rm -f conftest*
4122
4123fi
4124echo "$ac_t""$ac_cv_type_off_t" 1>&6
4125if test $ac_cv_type_off_t = no; then
4126  cat >> confdefs.h <<\EOF
4127#define off_t long
4128EOF
4129
4130fi
4131
4132echo $ac_n "checking for size_t""... $ac_c" 1>&6
4133echo "configure:4134: checking for size_t" >&5
4134if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
4135  echo $ac_n "(cached) $ac_c" 1>&6
4136else
4137  cat > conftest.$ac_ext <<EOF
4138#line 4139 "configure"
4139#include "confdefs.h"
4140#include <sys/types.h>
4141#if STDC_HEADERS
4142#include <stdlib.h>
4143#include <stddef.h>
4144#endif
4145EOF
4146if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4147  egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
4148  rm -rf conftest*
4149  ac_cv_type_size_t=yes
4150else
4151  rm -rf conftest*
4152  ac_cv_type_size_t=no
4153fi
4154rm -f conftest*
4155
4156fi
4157echo "$ac_t""$ac_cv_type_size_t" 1>&6
4158if test $ac_cv_type_size_t = no; then
4159  cat >> confdefs.h <<\EOF
4160#define size_t unsigned
4161EOF
4162
4163fi
4164
4165echo $ac_n "checking for time_t""... $ac_c" 1>&6
4166echo "configure:4167: checking for time_t" >&5
4167if eval "test \"`echo '$''{'ac_cv_type_time_t'+set}'`\" = set"; then
4168  echo $ac_n "(cached) $ac_c" 1>&6
4169else
4170  cat > conftest.$ac_ext <<EOF
4171#line 4172 "configure"
4172#include "confdefs.h"
4173#include <sys/types.h>
4174#if STDC_HEADERS
4175#include <stdlib.h>
4176#include <stddef.h>
4177#endif
4178EOF
4179if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4180  egrep "(^|[^a-zA-Z_0-9])time_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
4181  rm -rf conftest*
4182  ac_cv_type_time_t=yes
4183else
4184  rm -rf conftest*
4185  ac_cv_type_time_t=no
4186fi
4187rm -f conftest*
4188
4189fi
4190echo "$ac_t""$ac_cv_type_time_t" 1>&6
4191if test $ac_cv_type_time_t = no; then
4192  cat >> confdefs.h <<\EOF
4193#define time_t long
4194EOF
4195
4196fi
4197
4198echo $ac_n "checking whether struct tm is in sys/time.h or time.h""... $ac_c" 1>&6
4199echo "configure:4200: checking whether struct tm is in sys/time.h or time.h" >&5
4200if eval "test \"`echo '$''{'ac_cv_struct_tm'+set}'`\" = set"; then
4201  echo $ac_n "(cached) $ac_c" 1>&6
4202else
4203  cat > conftest.$ac_ext <<EOF
4204#line 4205 "configure"
4205#include "confdefs.h"
4206#include <sys/types.h>
4207#include <time.h>
4208int main() {
4209struct tm *tp; tp->tm_sec;
4210; return 0; }
4211EOF
4212if { (eval echo configure:4213: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4213  rm -rf conftest*
4214  ac_cv_struct_tm=time.h
4215else
4216  echo "configure: failed program was:" >&5
4217  cat conftest.$ac_ext >&5
4218  rm -rf conftest*
4219  ac_cv_struct_tm=sys/time.h
4220fi
4221rm -f conftest*
4222fi
4223
4224echo "$ac_t""$ac_cv_struct_tm" 1>&6
4225if test $ac_cv_struct_tm = sys/time.h; then
4226  cat >> confdefs.h <<\EOF
4227#define TM_IN_SYS_TIME 1
4228EOF
4229
4230fi
4231
4232
4233echo $ac_n "checking for a fallback value for HZ""... $ac_c" 1>&6
4234echo "configure:4235: checking for a fallback value for HZ" >&5
4235if eval "test \"`echo '$''{'ac_cv_var_default_hz'+set}'`\" = set"; then
4236  echo $ac_n "(cached) $ac_c" 1>&6
4237else
4238  ac_cv_var_default_hz=100
4239case "$target" in
4240 alpha*-dec-osf4*|alpha*-dec-osf5*)
4241    ac_cv_var_default_hz=1024
4242    ;;
4243 mips-dec-ultrix4*)
4244    ac_cv_var_default_hz=256
4245    ;;
4246esac
4247fi
4248
4249echo "$ac_t""$ac_cv_var_default_hz" 1>&6
4250cat >> confdefs.h <<EOF
4251#define DEFAULT_HZ $ac_cv_var_default_hz
4252EOF
4253
4254
4255echo $ac_n "checking if we need to override the system's value for HZ""... $ac_c" 1>&6
4256echo "configure:4257: checking if we need to override the system's value for HZ" >&5
4257if eval "test \"`echo '$''{'ac_cv_var_override_hz'+set}'`\" = set"; then
4258  echo $ac_n "(cached) $ac_c" 1>&6
4259else
4260  ac_cv_var_override_hz=no
4261case "$target" in
4262 alpha*-dec-osf4*|alpha*-dec-osf5*)
4263    ac_cv_var_override_hz=yes
4264    ;;
4265 mips-dec-ultrix4*)
4266    ac_cv_var_override_hz=yes
4267    ;;
4268 *-*-freebsd*)
4269    ac_cv_var_override_hz=yes
4270    ;;
4271 *-*-sunos4*)
4272    ac_cv_var_override_hz=yes
4273    ;;
4274esac
4275fi
4276
4277echo "$ac_t""$ac_cv_var_override_hz" 1>&6
4278case "$ac_cv_var_override_hz" in
4279 yes)
4280    cat >> confdefs.h <<\EOF
4281#define OVERRIDE_HZ 1
4282EOF
4283
4284    ;;
4285esac
4286
4287
4288
4289echo $ac_n "checking struct sigaction for sa_sigaction""... $ac_c" 1>&6
4290echo "configure:4291: checking struct sigaction for sa_sigaction" >&5
4291if eval "test \"`echo '$''{'ac_cv_struct_sigaction_has_sa_sigaction'+set}'`\" = set"; then
4292  echo $ac_n "(cached) $ac_c" 1>&6
4293else
4294
4295    cat > conftest.$ac_ext <<EOF
4296#line 4297 "configure"
4297#include "confdefs.h"
4298#include <signal.h>
4299int main() {
4300struct sigaction act; act.sa_sigaction = 0;
4301; return 0; }
4302EOF
4303if { (eval echo configure:4304: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4304  rm -rf conftest*
4305  ac_cv_struct_sigaction_has_sa_sigaction=yes
4306else
4307  echo "configure: failed program was:" >&5
4308  cat conftest.$ac_ext >&5
4309  rm -rf conftest*
4310  ac_cv_struct_sigaction_has_sa_sigaction=no
4311
4312fi
4313rm -f conftest*
4314
4315
4316fi
4317
4318echo "$ac_t""$ac_cv_struct_sigaction_has_sa_sigaction" 1>&6
4319if test $ac_cv_struct_sigaction_has_sa_sigaction = yes; then
4320  cat >> confdefs.h <<\EOF
4321#define HAVE_SA_SIGACTION_IN_STRUCT_SIGACTION 1
4322EOF
4323
4324fi
4325
4326echo $ac_n "checking for struct ppsclockev""... $ac_c" 1>&6
4327echo "configure:4328: checking for struct ppsclockev" >&5
4328if eval "test \"`echo '$''{'ac_cv_struct_ppsclockev'+set}'`\" = set"; then
4329  echo $ac_n "(cached) $ac_c" 1>&6
4330else
4331  cat > conftest.$ac_ext <<EOF
4332#line 4333 "configure"
4333#include "confdefs.h"
4334
4335#include <sys/types.h>
4336#ifdef HAVE_SYS_TERMIOS_H
4337# include <sys/termios.h>
4338#endif
4339#ifdef HAVE_SYS_TIME_H
4340# include <sys/time.h>
4341#endif
4342#ifdef HAVE_SYS_PPSCLOCK_H
4343# include <sys/ppsclock.h>
4344#endif
4345int main() {
4346
4347extern struct ppsclockev *pce;
4348return pce->serial;
4349; return 0; }
4350EOF
4351if { (eval echo configure:4352: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4352  rm -rf conftest*
4353  ac_cv_struct_ppsclockev=yes
4354else
4355  echo "configure: failed program was:" >&5
4356  cat conftest.$ac_ext >&5
4357  rm -rf conftest*
4358  ac_cv_struct_ppsclockev=no
4359fi
4360rm -f conftest*
4361
4362fi
4363
4364echo "$ac_t""$ac_cv_struct_ppsclockev" 1>&6
4365if test $ac_cv_struct_ppsclockev = yes; then
4366    cat >> confdefs.h <<\EOF
4367#define HAVE_STRUCT_PPSCLOCKEV 1
4368EOF
4369
4370fi
4371
4372echo $ac_n "checking struct sockaddr for sa_len""... $ac_c" 1>&6
4373echo "configure:4374: checking struct sockaddr for sa_len" >&5
4374if eval "test \"`echo '$''{'ac_cv_struct_sockaddr_has_sa_len'+set}'`\" = set"; then
4375  echo $ac_n "(cached) $ac_c" 1>&6
4376else
4377  cat > conftest.$ac_ext <<EOF
4378#line 4379 "configure"
4379#include "confdefs.h"
4380
4381#include <sys/types.h>
4382#include <sys/socket.h>
4383int main() {
4384
4385extern struct sockaddr *ps;
4386return ps->sa_len;
4387; return 0; }
4388EOF
4389if { (eval echo configure:4390: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4390  rm -rf conftest*
4391  ac_cv_struct_sockaddr_has_sa_len=yes
4392else
4393  echo "configure: failed program was:" >&5
4394  cat conftest.$ac_ext >&5
4395  rm -rf conftest*
4396  ac_cv_struct_sockaddr_has_sa_len=no
4397fi
4398rm -f conftest*
4399
4400fi
4401
4402echo "$ac_t""$ac_cv_struct_sockaddr_has_sa_len" 1>&6
4403if test $ac_cv_struct_sockaddr_has_sa_len = yes; then
4404    cat >> confdefs.h <<\EOF
4405#define HAVE_SA_LEN_IN_STRUCT_SOCKADDR 1
4406EOF
4407
4408fi
4409
4410echo $ac_n "checking struct clockinfo for hz""... $ac_c" 1>&6
4411echo "configure:4412: checking struct clockinfo for hz" >&5
4412if eval "test \"`echo '$''{'ac_cv_struct_clockinfo_has_hz'+set}'`\" = set"; then
4413  echo $ac_n "(cached) $ac_c" 1>&6
4414else
4415  cat > conftest.$ac_ext <<EOF
4416#line 4417 "configure"
4417#include "confdefs.h"
4418
4419#include <sys/time.h>
4420int main() {
4421
4422extern struct clockinfo *pc;
4423return pc->hz;
4424; return 0; }
4425EOF
4426if { (eval echo configure:4427: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4427  rm -rf conftest*
4428  ac_cv_struct_clockinfo_has_hz=yes
4429else
4430  echo "configure: failed program was:" >&5
4431  cat conftest.$ac_ext >&5
4432  rm -rf conftest*
4433  ac_cv_struct_clockinfo_has_hz=no
4434fi
4435rm -f conftest*
4436
4437fi
4438
4439echo "$ac_t""$ac_cv_struct_clockinfo_has_hz" 1>&6
4440if test $ac_cv_struct_clockinfo_has_hz = yes; then
4441    cat >> confdefs.h <<\EOF
4442#define HAVE_HZ_IN_STRUCT_CLOCKINFO 1
4443EOF
4444
4445fi
4446
4447echo $ac_n "checking struct clockinfo for tickadj""... $ac_c" 1>&6
4448echo "configure:4449: checking struct clockinfo for tickadj" >&5
4449if eval "test \"`echo '$''{'ac_cv_struct_clockinfo_has_tickadj'+set}'`\" = set"; then
4450  echo $ac_n "(cached) $ac_c" 1>&6
4451else
4452  cat > conftest.$ac_ext <<EOF
4453#line 4454 "configure"
4454#include "confdefs.h"
4455
4456#include <sys/time.h>
4457int main() {
4458
4459extern struct clockinfo *pc;
4460return pc->tickadj;
4461; return 0; }
4462EOF
4463if { (eval echo configure:4464: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4464  rm -rf conftest*
4465  ac_cv_struct_clockinfo_has_tickadj=yes
4466else
4467  echo "configure: failed program was:" >&5
4468  cat conftest.$ac_ext >&5
4469  rm -rf conftest*
4470  ac_cv_struct_clockinfo_has_tickadj=no
4471fi
4472rm -f conftest*
4473
4474fi
4475
4476echo "$ac_t""$ac_cv_struct_clockinfo_has_tickadj" 1>&6
4477if test $ac_cv_struct_clockinfo_has_tickadj = yes; then
4478    cat >> confdefs.h <<\EOF
4479#define HAVE_TICKADJ_IN_STRUCT_CLOCKINFO 1
4480EOF
4481
4482fi
4483
4484echo $ac_n "checking for struct ntptimeval""... $ac_c" 1>&6
4485echo "configure:4486: checking for struct ntptimeval" >&5
4486if eval "test \"`echo '$''{'ac_cv_struct_ntptimeval'+set}'`\" = set"; then
4487  echo $ac_n "(cached) $ac_c" 1>&6
4488else
4489  cat > conftest.$ac_ext <<EOF
4490#line 4491 "configure"
4491#include "confdefs.h"
4492
4493#include <sys/time.h>
4494#include <sys/timex.h>
4495int main() {
4496struct ntptimeval n;
4497; return 0; }
4498EOF
4499if { (eval echo configure:4500: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4500  rm -rf conftest*
4501  ac_cv_struct_ntptimeval=yes
4502else
4503  echo "configure: failed program was:" >&5
4504  cat conftest.$ac_ext >&5
4505  rm -rf conftest*
4506  ac_cv_struct_ntptimeval=no
4507fi
4508rm -f conftest*
4509fi
4510
4511echo "$ac_t""$ac_cv_struct_ntptimeval" 1>&6
4512if test $ac_cv_struct_ntptimeval = yes; then
4513  cat >> confdefs.h <<\EOF
4514#define HAVE_STRUCT_NTPTIMEVAL 1
4515EOF
4516
4517fi
4518
4519echo $ac_n "checking struct ntptimeval for time.tv_nsec""... $ac_c" 1>&6
4520echo "configure:4521: checking struct ntptimeval for time.tv_nsec" >&5
4521if eval "test \"`echo '$''{'ac_cv_struct_ntptimeval_tv_nsec'+set}'`\" = set"; then
4522  echo $ac_n "(cached) $ac_c" 1>&6
4523else
4524  cat > conftest.$ac_ext <<EOF
4525#line 4526 "configure"
4526#include "confdefs.h"
4527
4528#ifdef HAVE_SYS_TIME_H
4529#include <sys/time.h>
4530#else
4531# ifdef HAVE_TIME_H
4532# include <time.h>
4533# endif
4534#endif
4535#ifdef HAVE_SYS_TIMEX_H
4536#include <sys/timex.h>
4537#else
4538# ifdef HAVE_TIMEX_H
4539# include <timex.h>
4540# endif
4541#endif
4542int main() {
4543
4544extern struct ntptimeval *ntv;
4545return ntv->time.tv_nsec;
4546; return 0; }
4547EOF
4548if { (eval echo configure:4549: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4549  rm -rf conftest*
4550  ac_cv_struct_ntptimeval_tv_nsec=yes
4551else
4552  echo "configure: failed program was:" >&5
4553  cat conftest.$ac_ext >&5
4554  rm -rf conftest*
4555  ac_cv_struct_ntptimeval_tv_nsec=no
4556fi
4557rm -f conftest*
4558
4559fi
4560
4561echo "$ac_t""$ac_cv_struct_ntptimeval_tv_nsec" 1>&6
4562if test "$ac_cv_struct_ntptimeval_tv_nsec" = "yes"; then
4563	cat >> confdefs.h <<\EOF
4564#define HAVE_TV_NSEC_IN_NTPTIMEVAL 1
4565EOF
4566
4567fi
4568
4569echo $ac_n "checking for struct timespec in struct ntptimeval""... $ac_c" 1>&6
4570echo "configure:4571: checking for struct timespec in struct ntptimeval" >&5
4571if eval "test \"`echo '$''{'ac_cv_struct_ntptimeval_timespec'+set}'`\" = set"; then
4572  echo $ac_n "(cached) $ac_c" 1>&6
4573else
4574  cat > conftest.$ac_ext <<EOF
4575#line 4576 "configure"
4576#include "confdefs.h"
4577#include <sys/time.h>
4578#include <sys/timex.h>
4579int main() {
4580struct ntptimeval n; n.time.tv_nsec = 0;
4581; return 0; }
4582EOF
4583if { (eval echo configure:4584: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4584  rm -rf conftest*
4585  ac_cv_struct_ntptimeval_timespec=yes
4586else
4587  echo "configure: failed program was:" >&5
4588  cat conftest.$ac_ext >&5
4589  rm -rf conftest*
4590  ac_cv_struct_ntptimeval_timespec=no
4591fi
4592rm -f conftest*
4593fi
4594
4595echo "$ac_t""$ac_cv_struct_ntptimeval_timespec" 1>&6
4596if test $ac_cv_struct_ntptimeval_timespec = yes; then
4597  cat >> confdefs.h <<\EOF
4598#define TIMESPEC_IN_NTPTIMEVAL 1
4599EOF
4600
4601fi
4602
4603echo $ac_n "checking for inline""... $ac_c" 1>&6
4604echo "configure:4605: checking for inline" >&5
4605if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
4606  echo $ac_n "(cached) $ac_c" 1>&6
4607else
4608  ac_cv_c_inline=no
4609for ac_kw in inline __inline__ __inline; do
4610  cat > conftest.$ac_ext <<EOF
4611#line 4612 "configure"
4612#include "confdefs.h"
4613
4614int main() {
4615} $ac_kw foo() {
4616; return 0; }
4617EOF
4618if { (eval echo configure:4619: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
4619  rm -rf conftest*
4620  ac_cv_c_inline=$ac_kw; break
4621else
4622  echo "configure: failed program was:" >&5
4623  cat conftest.$ac_ext >&5
4624fi
4625rm -f conftest*
4626done
4627
4628fi
4629
4630echo "$ac_t""$ac_cv_c_inline" 1>&6
4631case "$ac_cv_c_inline" in
4632  inline | yes) ;;
4633  no) cat >> confdefs.h <<\EOF
4634#define inline
4635EOF
4636 ;;
4637  *)  cat >> confdefs.h <<EOF
4638#define inline $ac_cv_c_inline
4639EOF
4640 ;;
4641esac
4642
4643echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6
4644echo "configure:4645: checking whether char is unsigned" >&5
4645if eval "test \"`echo '$''{'ac_cv_c_char_unsigned'+set}'`\" = set"; then
4646  echo $ac_n "(cached) $ac_c" 1>&6
4647else
4648  if test "$GCC" = yes; then
4649  # GCC predefines this symbol on systems where it applies.
4650cat > conftest.$ac_ext <<EOF
4651#line 4652 "configure"
4652#include "confdefs.h"
4653#ifdef __CHAR_UNSIGNED__
4654  yes
4655#endif
4656
4657EOF
4658if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4659  egrep "yes" >/dev/null 2>&1; then
4660  rm -rf conftest*
4661  ac_cv_c_char_unsigned=yes
4662else
4663  rm -rf conftest*
4664  ac_cv_c_char_unsigned=no
4665fi
4666rm -f conftest*
4667
4668else
4669if test "$cross_compiling" = yes; then
4670    { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
4671else
4672  cat > conftest.$ac_ext <<EOF
4673#line 4674 "configure"
4674#include "confdefs.h"
4675/* volatile prevents gcc2 from optimizing the test away on sparcs.  */
4676#if !defined(__STDC__) || __STDC__ != 1
4677#define volatile
4678#endif
4679main() {
4680  volatile char c = 255; exit(c < 0);
4681}
4682EOF
4683if { (eval echo configure:4684: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
4684then
4685  ac_cv_c_char_unsigned=yes
4686else
4687  echo "configure: failed program was:" >&5
4688  cat conftest.$ac_ext >&5
4689  rm -fr conftest*
4690  ac_cv_c_char_unsigned=no
4691fi
4692rm -fr conftest*
4693fi
4694
4695fi
4696fi
4697
4698echo "$ac_t""$ac_cv_c_char_unsigned" 1>&6
4699if test $ac_cv_c_char_unsigned = yes && test "$GCC" != yes; then
4700  cat >> confdefs.h <<\EOF
4701#define __CHAR_UNSIGNED__ 1
4702EOF
4703
4704fi
4705		case "$host" in
4706 $target)
4707    echo $ac_n "checking size of signed char""... $ac_c" 1>&6
4708echo "configure:4709: checking size of signed char" >&5
4709if eval "test \"`echo '$''{'ac_cv_sizeof_signed_char'+set}'`\" = set"; then
4710  echo $ac_n "(cached) $ac_c" 1>&6
4711else
4712  if test "$cross_compiling" = yes; then
4713    { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
4714else
4715  cat > conftest.$ac_ext <<EOF
4716#line 4717 "configure"
4717#include "confdefs.h"
4718#include <stdio.h>
4719main()
4720{
4721  FILE *f=fopen("conftestval", "w");
4722  if (!f) exit(1);
4723  fprintf(f, "%d\n", sizeof(signed char));
4724  exit(0);
4725}
4726EOF
4727if { (eval echo configure:4728: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
4728then
4729  ac_cv_sizeof_signed_char=`cat conftestval`
4730else
4731  echo "configure: failed program was:" >&5
4732  cat conftest.$ac_ext >&5
4733  rm -fr conftest*
4734  ac_cv_sizeof_signed_char=0
4735fi
4736rm -fr conftest*
4737fi
4738
4739fi
4740echo "$ac_t""$ac_cv_sizeof_signed_char" 1>&6
4741cat >> confdefs.h <<EOF
4742#define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char
4743EOF
4744
4745
4746    ;;
4747 *) case "$target" in
4748     *-*-vxworks*)
4749	echo $ac_n "checking size of signed char""... $ac_c" 1>&6
4750echo "configure:4751: checking size of signed char" >&5
4751if eval "test \"`echo '$''{'ac_cv_sizeof_signed_char'+set}'`\" = set"; then
4752  echo $ac_n "(cached) $ac_c" 1>&6
4753else
4754  if test "$cross_compiling" = yes; then
4755  ac_cv_sizeof_signed_char=1
4756else
4757  cat > conftest.$ac_ext <<EOF
4758#line 4759 "configure"
4759#include "confdefs.h"
4760#include <stdio.h>
4761main()
4762{
4763  FILE *f=fopen("conftestval", "w");
4764  if (!f) exit(1);
4765  fprintf(f, "%d\n", sizeof(signed char));
4766  exit(0);
4767}
4768EOF
4769if { (eval echo configure:4770: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
4770then
4771  ac_cv_sizeof_signed_char=`cat conftestval`
4772else
4773  echo "configure: failed program was:" >&5
4774  cat conftest.$ac_ext >&5
4775  rm -fr conftest*
4776  ac_cv_sizeof_signed_char=0
4777fi
4778rm -fr conftest*
4779fi
4780
4781fi
4782echo "$ac_t""$ac_cv_sizeof_signed_char" 1>&6
4783cat >> confdefs.h <<EOF
4784#define SIZEOF_SIGNED_CHAR $ac_cv_sizeof_signed_char
4785EOF
4786
4787
4788	;;
4789     *) { echo "configure: error: Cross-compiling needs explicit SIZEOF_SIGNED_LONG" 1>&2; exit 1; }
4790        ;;
4791    esac
4792    ;;
4793esac
4794
4795case "$host" in
4796 $target)
4797    echo $ac_n "checking size of int""... $ac_c" 1>&6
4798echo "configure:4799: checking size of int" >&5
4799if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
4800  echo $ac_n "(cached) $ac_c" 1>&6
4801else
4802  if test "$cross_compiling" = yes; then
4803    { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
4804else
4805  cat > conftest.$ac_ext <<EOF
4806#line 4807 "configure"
4807#include "confdefs.h"
4808#include <stdio.h>
4809main()
4810{
4811  FILE *f=fopen("conftestval", "w");
4812  if (!f) exit(1);
4813  fprintf(f, "%d\n", sizeof(int));
4814  exit(0);
4815}
4816EOF
4817if { (eval echo configure:4818: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
4818then
4819  ac_cv_sizeof_int=`cat conftestval`
4820else
4821  echo "configure: failed program was:" >&5
4822  cat conftest.$ac_ext >&5
4823  rm -fr conftest*
4824  ac_cv_sizeof_int=0
4825fi
4826rm -fr conftest*
4827fi
4828
4829fi
4830echo "$ac_t""$ac_cv_sizeof_int" 1>&6
4831cat >> confdefs.h <<EOF
4832#define SIZEOF_INT $ac_cv_sizeof_int
4833EOF
4834
4835
4836    ;;
4837 *) case "$target" in
4838     *-*-vxworks*)
4839	echo $ac_n "checking size of int""... $ac_c" 1>&6
4840echo "configure:4841: checking size of int" >&5
4841if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
4842  echo $ac_n "(cached) $ac_c" 1>&6
4843else
4844  if test "$cross_compiling" = yes; then
4845  ac_cv_sizeof_int=4
4846else
4847  cat > conftest.$ac_ext <<EOF
4848#line 4849 "configure"
4849#include "confdefs.h"
4850#include <stdio.h>
4851main()
4852{
4853  FILE *f=fopen("conftestval", "w");
4854  if (!f) exit(1);
4855  fprintf(f, "%d\n", sizeof(int));
4856  exit(0);
4857}
4858EOF
4859if { (eval echo configure:4860: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
4860then
4861  ac_cv_sizeof_int=`cat conftestval`
4862else
4863  echo "configure: failed program was:" >&5
4864  cat conftest.$ac_ext >&5
4865  rm -fr conftest*
4866  ac_cv_sizeof_int=0
4867fi
4868rm -fr conftest*
4869fi
4870
4871fi
4872echo "$ac_t""$ac_cv_sizeof_int" 1>&6
4873cat >> confdefs.h <<EOF
4874#define SIZEOF_INT $ac_cv_sizeof_int
4875EOF
4876
4877
4878        ;;
4879     *) { echo "configure: error: Cross-compiling needs explicit SIZEOF_INT" 1>&2; exit 1; }
4880	;;
4881    esac
4882    ;;
4883esac
4884
4885case "$host" in
4886 $target)
4887    echo $ac_n "checking size of long""... $ac_c" 1>&6
4888echo "configure:4889: checking size of long" >&5
4889if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
4890  echo $ac_n "(cached) $ac_c" 1>&6
4891else
4892  if test "$cross_compiling" = yes; then
4893    { echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
4894else
4895  cat > conftest.$ac_ext <<EOF
4896#line 4897 "configure"
4897#include "confdefs.h"
4898#include <stdio.h>
4899main()
4900{
4901  FILE *f=fopen("conftestval", "w");
4902  if (!f) exit(1);
4903  fprintf(f, "%d\n", sizeof(long));
4904  exit(0);
4905}
4906EOF
4907if { (eval echo configure:4908: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
4908then
4909  ac_cv_sizeof_long=`cat conftestval`
4910else
4911  echo "configure: failed program was:" >&5
4912  cat conftest.$ac_ext >&5
4913  rm -fr conftest*
4914  ac_cv_sizeof_long=0
4915fi
4916rm -fr conftest*
4917fi
4918
4919fi
4920echo "$ac_t""$ac_cv_sizeof_long" 1>&6
4921cat >> confdefs.h <<EOF
4922#define SIZEOF_LONG $ac_cv_sizeof_long
4923EOF
4924
4925
4926    ;;
4927 *) case "$target" in
4928     *-*-vxworks*)
4929	echo $ac_n "checking size of long""... $ac_c" 1>&6
4930echo "configure:4931: checking size of long" >&5
4931if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
4932  echo $ac_n "(cached) $ac_c" 1>&6
4933else
4934  if test "$cross_compiling" = yes; then
4935  ac_cv_sizeof_long=4
4936else
4937  cat > conftest.$ac_ext <<EOF
4938#line 4939 "configure"
4939#include "confdefs.h"
4940#include <stdio.h>
4941main()
4942{
4943  FILE *f=fopen("conftestval", "w");
4944  if (!f) exit(1);
4945  fprintf(f, "%d\n", sizeof(long));
4946  exit(0);
4947}
4948EOF
4949if { (eval echo configure:4950: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
4950then
4951  ac_cv_sizeof_long=`cat conftestval`
4952else
4953  echo "configure: failed program was:" >&5
4954  cat conftest.$ac_ext >&5
4955  rm -fr conftest*
4956  ac_cv_sizeof_long=0
4957fi
4958rm -fr conftest*
4959fi
4960
4961fi
4962echo "$ac_t""$ac_cv_sizeof_long" 1>&6
4963cat >> confdefs.h <<EOF
4964#define SIZEOF_LONG $ac_cv_sizeof_long
4965EOF
4966
4967
4968        ;;
4969     *) { echo "configure: error: Cross-compiling needs explicit SIZEOF_LONG" 1>&2; exit 1; }
4970	;;
4971    esac
4972    ;;
4973esac
4974
4975echo $ac_n "checking for s_char""... $ac_c" 1>&6
4976echo "configure:4977: checking for s_char" >&5
4977if eval "test \"`echo '$''{'ac_cv_type_s_char'+set}'`\" = set"; then
4978  echo $ac_n "(cached) $ac_c" 1>&6
4979else
4980  cat > conftest.$ac_ext <<EOF
4981#line 4982 "configure"
4982#include "confdefs.h"
4983#include <sys/types.h>
4984#if STDC_HEADERS
4985#include <stdlib.h>
4986#include <stddef.h>
4987#endif
4988EOF
4989if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
4990  egrep "(^|[^a-zA-Z_0-9])s_char[^a-zA-Z_0-9]" >/dev/null 2>&1; then
4991  rm -rf conftest*
4992  ac_cv_type_s_char=yes
4993else
4994  rm -rf conftest*
4995  ac_cv_type_s_char=no
4996fi
4997rm -f conftest*
4998
4999fi
5000echo "$ac_t""$ac_cv_type_s_char" 1>&6
5001if test $ac_cv_type_s_char = no; then
5002  cat >> confdefs.h <<\EOF
5003#define s_char signed char
5004EOF
5005
5006fi
5007
5008case "$ac_cv_c_char_unsigned$ac_cv_sizeof_signed_char$ac_cv_type_s_char" in
5009 *yes)
5010    # We have a typedef for s_char.  Might as well believe it...
5011    ;;
5012 no0no)
5013    # We have signed chars, can't say 'signed char', no s_char typedef.
5014    cat >> confdefs.h <<\EOF
5015#define NEED_S_CHAR_TYPEDEF 1
5016EOF
5017
5018    ;;
5019 no1no)
5020    # We have signed chars, can say 'signed char', no s_char typedef.
5021    cat >> confdefs.h <<\EOF
5022#define NEED_S_CHAR_TYPEDEF 1
5023EOF
5024
5025    ;;
5026 yes0no)
5027    # We have unsigned chars, can't say 'signed char', no s_char typedef.
5028    { echo "configure: error: No way to specify a signed character!" 1>&2; exit 1; }
5029    ;;
5030 yes1no)
5031    # We have unsigned chars, can say 'signed char', no s_char typedef.
5032    cat >> confdefs.h <<\EOF
5033#define NEED_S_CHAR_TYPEDEF 1
5034EOF
5035
5036    ;;
5037esac
5038echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
5039echo "configure:5040: checking for uid_t in sys/types.h" >&5
5040if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
5041  echo $ac_n "(cached) $ac_c" 1>&6
5042else
5043  cat > conftest.$ac_ext <<EOF
5044#line 5045 "configure"
5045#include "confdefs.h"
5046#include <sys/types.h>
5047EOF
5048if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5049  egrep "uid_t" >/dev/null 2>&1; then
5050  rm -rf conftest*
5051  ac_cv_type_uid_t=yes
5052else
5053  rm -rf conftest*
5054  ac_cv_type_uid_t=no
5055fi
5056rm -f conftest*
5057
5058fi
5059
5060echo "$ac_t""$ac_cv_type_uid_t" 1>&6
5061if test $ac_cv_type_uid_t = no; then
5062  cat >> confdefs.h <<\EOF
5063#define uid_t int
5064EOF
5065
5066  cat >> confdefs.h <<\EOF
5067#define gid_t int
5068EOF
5069
5070fi
5071
5072
5073case "$target" in
5074 *-*-linux*)
5075    for ac_func in __adjtimex __ntp_gettime
5076do
5077echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5078echo "configure:5079: checking for $ac_func" >&5
5079if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5080  echo $ac_n "(cached) $ac_c" 1>&6
5081else
5082  cat > conftest.$ac_ext <<EOF
5083#line 5084 "configure"
5084#include "confdefs.h"
5085/* System header to define __stub macros and hopefully few prototypes,
5086    which can conflict with char $ac_func(); below.  */
5087#include <assert.h>
5088/* Override any gcc2 internal prototype to avoid an error.  */
5089/* We use char because int might match the return type of a gcc2
5090    builtin and then its argument prototype would still apply.  */
5091char $ac_func();
5092
5093int main() {
5094
5095/* The GNU C library defines this for functions which it implements
5096    to always fail with ENOSYS.  Some functions are actually named
5097    something starting with __ and the normal name is an alias.  */
5098#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5099choke me
5100#else
5101$ac_func();
5102#endif
5103
5104; return 0; }
5105EOF
5106if { (eval echo configure:5107: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5107  rm -rf conftest*
5108  eval "ac_cv_func_$ac_func=yes"
5109else
5110  echo "configure: failed program was:" >&5
5111  cat conftest.$ac_ext >&5
5112  rm -rf conftest*
5113  eval "ac_cv_func_$ac_func=no"
5114fi
5115rm -f conftest*
5116fi
5117
5118if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5119  echo "$ac_t""yes" 1>&6
5120    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5121  cat >> confdefs.h <<EOF
5122#define $ac_tr_func 1
5123EOF
5124
5125else
5126  echo "$ac_t""no" 1>&6
5127fi
5128done
5129
5130    ;;
5131esac
5132case "$target" in
5133 *-*-aix4*)
5134	# (prr) aix 4.1 doesn't have clock_settime, but in aix 4.3 it's a stub
5135	# (returning ENOSYS).  I didn't check 4.2.  If, in the future,
5136	# IBM pulls its thumbs out long enough to implement clock_settime,
5137	# this conditional will need to change.  Maybe use AC_TRY_RUN
5138	# instead to try to set the time to itself and check errno.
5139    ;;
5140 *) for ac_func in clock_settime
5141do
5142echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5143echo "configure:5144: checking for $ac_func" >&5
5144if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5145  echo $ac_n "(cached) $ac_c" 1>&6
5146else
5147  cat > conftest.$ac_ext <<EOF
5148#line 5149 "configure"
5149#include "confdefs.h"
5150/* System header to define __stub macros and hopefully few prototypes,
5151    which can conflict with char $ac_func(); below.  */
5152#include <assert.h>
5153/* Override any gcc2 internal prototype to avoid an error.  */
5154/* We use char because int might match the return type of a gcc2
5155    builtin and then its argument prototype would still apply.  */
5156char $ac_func();
5157
5158int main() {
5159
5160/* The GNU C library defines this for functions which it implements
5161    to always fail with ENOSYS.  Some functions are actually named
5162    something starting with __ and the normal name is an alias.  */
5163#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5164choke me
5165#else
5166$ac_func();
5167#endif
5168
5169; return 0; }
5170EOF
5171if { (eval echo configure:5172: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5172  rm -rf conftest*
5173  eval "ac_cv_func_$ac_func=yes"
5174else
5175  echo "configure: failed program was:" >&5
5176  cat conftest.$ac_ext >&5
5177  rm -rf conftest*
5178  eval "ac_cv_func_$ac_func=no"
5179fi
5180rm -f conftest*
5181fi
5182
5183if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5184  echo "$ac_t""yes" 1>&6
5185    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5186  cat >> confdefs.h <<EOF
5187#define $ac_tr_func 1
5188EOF
5189
5190else
5191  echo "$ac_t""no" 1>&6
5192fi
5193done
5194
5195    ;;
5196esac
5197for ac_func in daemon getbootfile getdtablesize getrusage
5198do
5199echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5200echo "configure:5201: checking for $ac_func" >&5
5201if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5202  echo $ac_n "(cached) $ac_c" 1>&6
5203else
5204  cat > conftest.$ac_ext <<EOF
5205#line 5206 "configure"
5206#include "confdefs.h"
5207/* System header to define __stub macros and hopefully few prototypes,
5208    which can conflict with char $ac_func(); below.  */
5209#include <assert.h>
5210/* Override any gcc2 internal prototype to avoid an error.  */
5211/* We use char because int might match the return type of a gcc2
5212    builtin and then its argument prototype would still apply.  */
5213char $ac_func();
5214
5215int main() {
5216
5217/* The GNU C library defines this for functions which it implements
5218    to always fail with ENOSYS.  Some functions are actually named
5219    something starting with __ and the normal name is an alias.  */
5220#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5221choke me
5222#else
5223$ac_func();
5224#endif
5225
5226; return 0; }
5227EOF
5228if { (eval echo configure:5229: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5229  rm -rf conftest*
5230  eval "ac_cv_func_$ac_func=yes"
5231else
5232  echo "configure: failed program was:" >&5
5233  cat conftest.$ac_ext >&5
5234  rm -rf conftest*
5235  eval "ac_cv_func_$ac_func=no"
5236fi
5237rm -f conftest*
5238fi
5239
5240if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5241  echo "$ac_t""yes" 1>&6
5242    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5243  cat >> confdefs.h <<EOF
5244#define $ac_tr_func 1
5245EOF
5246
5247else
5248  echo "$ac_t""no" 1>&6
5249fi
5250done
5251
5252for ac_func in gettimeofday
5253do
5254echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5255echo "configure:5256: checking for $ac_func" >&5
5256if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5257  echo $ac_n "(cached) $ac_c" 1>&6
5258else
5259  cat > conftest.$ac_ext <<EOF
5260#line 5261 "configure"
5261#include "confdefs.h"
5262/* System header to define __stub macros and hopefully few prototypes,
5263    which can conflict with char $ac_func(); below.  */
5264#include <assert.h>
5265/* Override any gcc2 internal prototype to avoid an error.  */
5266/* We use char because int might match the return type of a gcc2
5267    builtin and then its argument prototype would still apply.  */
5268char $ac_func();
5269
5270int main() {
5271
5272/* The GNU C library defines this for functions which it implements
5273    to always fail with ENOSYS.  Some functions are actually named
5274    something starting with __ and the normal name is an alias.  */
5275#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5276choke me
5277#else
5278$ac_func();
5279#endif
5280
5281; return 0; }
5282EOF
5283if { (eval echo configure:5284: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5284  rm -rf conftest*
5285  eval "ac_cv_func_$ac_func=yes"
5286else
5287  echo "configure: failed program was:" >&5
5288  cat conftest.$ac_ext >&5
5289  rm -rf conftest*
5290  eval "ac_cv_func_$ac_func=no"
5291fi
5292rm -f conftest*
5293fi
5294
5295if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5296  echo "$ac_t""yes" 1>&6
5297    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5298  cat >> confdefs.h <<EOF
5299#define $ac_tr_func 1
5300EOF
5301
5302else
5303  echo "$ac_t""no" 1>&6
5304fi
5305done
5306
5307case "$target" in
5308 *-pc-cygwin*)
5309    ;;
5310 *) for ac_func in getuid
5311do
5312echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5313echo "configure:5314: checking for $ac_func" >&5
5314if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5315  echo $ac_n "(cached) $ac_c" 1>&6
5316else
5317  cat > conftest.$ac_ext <<EOF
5318#line 5319 "configure"
5319#include "confdefs.h"
5320/* System header to define __stub macros and hopefully few prototypes,
5321    which can conflict with char $ac_func(); below.  */
5322#include <assert.h>
5323/* Override any gcc2 internal prototype to avoid an error.  */
5324/* We use char because int might match the return type of a gcc2
5325    builtin and then its argument prototype would still apply.  */
5326char $ac_func();
5327
5328int main() {
5329
5330/* The GNU C library defines this for functions which it implements
5331    to always fail with ENOSYS.  Some functions are actually named
5332    something starting with __ and the normal name is an alias.  */
5333#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5334choke me
5335#else
5336$ac_func();
5337#endif
5338
5339; return 0; }
5340EOF
5341if { (eval echo configure:5342: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5342  rm -rf conftest*
5343  eval "ac_cv_func_$ac_func=yes"
5344else
5345  echo "configure: failed program was:" >&5
5346  cat conftest.$ac_ext >&5
5347  rm -rf conftest*
5348  eval "ac_cv_func_$ac_func=no"
5349fi
5350rm -f conftest*
5351fi
5352
5353if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5354  echo "$ac_t""yes" 1>&6
5355    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5356  cat >> confdefs.h <<EOF
5357#define $ac_tr_func 1
5358EOF
5359
5360else
5361  echo "$ac_t""no" 1>&6
5362fi
5363done
5364
5365    ;;
5366esac
5367for ac_func in K_open kvm_open memcpy memmove memset
5368do
5369echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5370echo "configure:5371: checking for $ac_func" >&5
5371if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5372  echo $ac_n "(cached) $ac_c" 1>&6
5373else
5374  cat > conftest.$ac_ext <<EOF
5375#line 5376 "configure"
5376#include "confdefs.h"
5377/* System header to define __stub macros and hopefully few prototypes,
5378    which can conflict with char $ac_func(); below.  */
5379#include <assert.h>
5380/* Override any gcc2 internal prototype to avoid an error.  */
5381/* We use char because int might match the return type of a gcc2
5382    builtin and then its argument prototype would still apply.  */
5383char $ac_func();
5384
5385int main() {
5386
5387/* The GNU C library defines this for functions which it implements
5388    to always fail with ENOSYS.  Some functions are actually named
5389    something starting with __ and the normal name is an alias.  */
5390#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5391choke me
5392#else
5393$ac_func();
5394#endif
5395
5396; return 0; }
5397EOF
5398if { (eval echo configure:5399: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5399  rm -rf conftest*
5400  eval "ac_cv_func_$ac_func=yes"
5401else
5402  echo "configure: failed program was:" >&5
5403  cat conftest.$ac_ext >&5
5404  rm -rf conftest*
5405  eval "ac_cv_func_$ac_func=no"
5406fi
5407rm -f conftest*
5408fi
5409
5410if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5411  echo "$ac_t""yes" 1>&6
5412    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5413  cat >> confdefs.h <<EOF
5414#define $ac_tr_func 1
5415EOF
5416
5417else
5418  echo "$ac_t""no" 1>&6
5419fi
5420done
5421
5422case "$target" in
5423 *-*-sco3.2v5.0.*)
5424    # Just stubs.  Idiots.
5425    ;;
5426 *) for ac_func in mkstemp
5427do
5428echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5429echo "configure:5430: checking for $ac_func" >&5
5430if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5431  echo $ac_n "(cached) $ac_c" 1>&6
5432else
5433  cat > conftest.$ac_ext <<EOF
5434#line 5435 "configure"
5435#include "confdefs.h"
5436/* System header to define __stub macros and hopefully few prototypes,
5437    which can conflict with char $ac_func(); below.  */
5438#include <assert.h>
5439/* Override any gcc2 internal prototype to avoid an error.  */
5440/* We use char because int might match the return type of a gcc2
5441    builtin and then its argument prototype would still apply.  */
5442char $ac_func();
5443
5444int main() {
5445
5446/* The GNU C library defines this for functions which it implements
5447    to always fail with ENOSYS.  Some functions are actually named
5448    something starting with __ and the normal name is an alias.  */
5449#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5450choke me
5451#else
5452$ac_func();
5453#endif
5454
5455; return 0; }
5456EOF
5457if { (eval echo configure:5458: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5458  rm -rf conftest*
5459  eval "ac_cv_func_$ac_func=yes"
5460else
5461  echo "configure: failed program was:" >&5
5462  cat conftest.$ac_ext >&5
5463  rm -rf conftest*
5464  eval "ac_cv_func_$ac_func=no"
5465fi
5466rm -f conftest*
5467fi
5468
5469if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5470  echo "$ac_t""yes" 1>&6
5471    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5472  cat >> confdefs.h <<EOF
5473#define $ac_tr_func 1
5474EOF
5475
5476else
5477  echo "$ac_t""no" 1>&6
5478fi
5479done
5480
5481    ;;
5482esac
5483for ac_func in mktime
5484do
5485echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5486echo "configure:5487: checking for $ac_func" >&5
5487if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5488  echo $ac_n "(cached) $ac_c" 1>&6
5489else
5490  cat > conftest.$ac_ext <<EOF
5491#line 5492 "configure"
5492#include "confdefs.h"
5493/* System header to define __stub macros and hopefully few prototypes,
5494    which can conflict with char $ac_func(); below.  */
5495#include <assert.h>
5496/* Override any gcc2 internal prototype to avoid an error.  */
5497/* We use char because int might match the return type of a gcc2
5498    builtin and then its argument prototype would still apply.  */
5499char $ac_func();
5500
5501int main() {
5502
5503/* The GNU C library defines this for functions which it implements
5504    to always fail with ENOSYS.  Some functions are actually named
5505    something starting with __ and the normal name is an alias.  */
5506#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5507choke me
5508#else
5509$ac_func();
5510#endif
5511
5512; return 0; }
5513EOF
5514if { (eval echo configure:5515: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5515  rm -rf conftest*
5516  eval "ac_cv_func_$ac_func=yes"
5517else
5518  echo "configure: failed program was:" >&5
5519  cat conftest.$ac_ext >&5
5520  rm -rf conftest*
5521  eval "ac_cv_func_$ac_func=no"
5522fi
5523rm -f conftest*
5524fi
5525
5526if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5527  echo "$ac_t""yes" 1>&6
5528    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5529  cat >> confdefs.h <<EOF
5530#define $ac_tr_func 1
5531EOF
5532
5533else
5534  echo "$ac_t""no" 1>&6
5535LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
5536fi
5537done
5538
5539
5540case "$target" in
5541 *-*-aix4*)
5542    # Just a stub.  Idiots.
5543    ;;
5544 *-*-irix*)
5545    # Just stubs in Irix.  Idiots.
5546    ;;
5547 *-*-sco3.2v5.0.*)
5548    # Just stubs.  Idiots.
5549    ;;
5550 alpha*-dec-osf4*|alpha*-dec-osf5*)
5551    # mlockall is there, as a #define calling memlk via <sys/mman.h>
5552    # Not easy to test for - cheat.
5553    for ac_func in memlk
5554do
5555echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5556echo "configure:5557: checking for $ac_func" >&5
5557if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5558  echo $ac_n "(cached) $ac_c" 1>&6
5559else
5560  cat > conftest.$ac_ext <<EOF
5561#line 5562 "configure"
5562#include "confdefs.h"
5563/* System header to define __stub macros and hopefully few prototypes,
5564    which can conflict with char $ac_func(); below.  */
5565#include <assert.h>
5566/* Override any gcc2 internal prototype to avoid an error.  */
5567/* We use char because int might match the return type of a gcc2
5568    builtin and then its argument prototype would still apply.  */
5569char $ac_func();
5570
5571int main() {
5572
5573/* The GNU C library defines this for functions which it implements
5574    to always fail with ENOSYS.  Some functions are actually named
5575    something starting with __ and the normal name is an alias.  */
5576#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5577choke me
5578#else
5579$ac_func();
5580#endif
5581
5582; return 0; }
5583EOF
5584if { (eval echo configure:5585: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5585  rm -rf conftest*
5586  eval "ac_cv_func_$ac_func=yes"
5587else
5588  echo "configure: failed program was:" >&5
5589  cat conftest.$ac_ext >&5
5590  rm -rf conftest*
5591  eval "ac_cv_func_$ac_func=no"
5592fi
5593rm -f conftest*
5594fi
5595
5596if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5597  echo "$ac_t""yes" 1>&6
5598    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5599  cat >> confdefs.h <<EOF
5600#define $ac_tr_func 1
5601EOF
5602 ac_cv_func_mlockall='yes'
5603else
5604  echo "$ac_t""no" 1>&6
5605fi
5606done
5607
5608    for ac_func in mlockall
5609do
5610echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5611echo "configure:5612: checking for $ac_func" >&5
5612if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5613  echo $ac_n "(cached) $ac_c" 1>&6
5614else
5615  cat > conftest.$ac_ext <<EOF
5616#line 5617 "configure"
5617#include "confdefs.h"
5618/* System header to define __stub macros and hopefully few prototypes,
5619    which can conflict with char $ac_func(); below.  */
5620#include <assert.h>
5621/* Override any gcc2 internal prototype to avoid an error.  */
5622/* We use char because int might match the return type of a gcc2
5623    builtin and then its argument prototype would still apply.  */
5624char $ac_func();
5625
5626int main() {
5627
5628/* The GNU C library defines this for functions which it implements
5629    to always fail with ENOSYS.  Some functions are actually named
5630    something starting with __ and the normal name is an alias.  */
5631#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5632choke me
5633#else
5634$ac_func();
5635#endif
5636
5637; return 0; }
5638EOF
5639if { (eval echo configure:5640: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5640  rm -rf conftest*
5641  eval "ac_cv_func_$ac_func=yes"
5642else
5643  echo "configure: failed program was:" >&5
5644  cat conftest.$ac_ext >&5
5645  rm -rf conftest*
5646  eval "ac_cv_func_$ac_func=no"
5647fi
5648rm -f conftest*
5649fi
5650
5651if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5652  echo "$ac_t""yes" 1>&6
5653    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5654  cat >> confdefs.h <<EOF
5655#define $ac_tr_func 1
5656EOF
5657
5658else
5659  echo "$ac_t""no" 1>&6
5660fi
5661done
5662
5663    ;;
5664 *) for ac_func in mlockall
5665do
5666echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5667echo "configure:5668: checking for $ac_func" >&5
5668if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5669  echo $ac_n "(cached) $ac_c" 1>&6
5670else
5671  cat > conftest.$ac_ext <<EOF
5672#line 5673 "configure"
5673#include "confdefs.h"
5674/* System header to define __stub macros and hopefully few prototypes,
5675    which can conflict with char $ac_func(); below.  */
5676#include <assert.h>
5677/* Override any gcc2 internal prototype to avoid an error.  */
5678/* We use char because int might match the return type of a gcc2
5679    builtin and then its argument prototype would still apply.  */
5680char $ac_func();
5681
5682int main() {
5683
5684/* The GNU C library defines this for functions which it implements
5685    to always fail with ENOSYS.  Some functions are actually named
5686    something starting with __ and the normal name is an alias.  */
5687#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5688choke me
5689#else
5690$ac_func();
5691#endif
5692
5693; return 0; }
5694EOF
5695if { (eval echo configure:5696: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5696  rm -rf conftest*
5697  eval "ac_cv_func_$ac_func=yes"
5698else
5699  echo "configure: failed program was:" >&5
5700  cat conftest.$ac_ext >&5
5701  rm -rf conftest*
5702  eval "ac_cv_func_$ac_func=no"
5703fi
5704rm -f conftest*
5705fi
5706
5707if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5708  echo "$ac_t""yes" 1>&6
5709    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5710  cat >> confdefs.h <<EOF
5711#define $ac_tr_func 1
5712EOF
5713
5714else
5715  echo "$ac_t""no" 1>&6
5716fi
5717done
5718
5719    ;;
5720esac
5721for ac_func in nice nlist
5722do
5723echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5724echo "configure:5725: checking for $ac_func" >&5
5725if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5726  echo $ac_n "(cached) $ac_c" 1>&6
5727else
5728  cat > conftest.$ac_ext <<EOF
5729#line 5730 "configure"
5730#include "confdefs.h"
5731/* System header to define __stub macros and hopefully few prototypes,
5732    which can conflict with char $ac_func(); below.  */
5733#include <assert.h>
5734/* Override any gcc2 internal prototype to avoid an error.  */
5735/* We use char because int might match the return type of a gcc2
5736    builtin and then its argument prototype would still apply.  */
5737char $ac_func();
5738
5739int main() {
5740
5741/* The GNU C library defines this for functions which it implements
5742    to always fail with ENOSYS.  Some functions are actually named
5743    something starting with __ and the normal name is an alias.  */
5744#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5745choke me
5746#else
5747$ac_func();
5748#endif
5749
5750; return 0; }
5751EOF
5752if { (eval echo configure:5753: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5753  rm -rf conftest*
5754  eval "ac_cv_func_$ac_func=yes"
5755else
5756  echo "configure: failed program was:" >&5
5757  cat conftest.$ac_ext >&5
5758  rm -rf conftest*
5759  eval "ac_cv_func_$ac_func=no"
5760fi
5761rm -f conftest*
5762fi
5763
5764if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5765  echo "$ac_t""yes" 1>&6
5766    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5767  cat >> confdefs.h <<EOF
5768#define $ac_tr_func 1
5769EOF
5770
5771else
5772  echo "$ac_t""no" 1>&6
5773fi
5774done
5775
5776case "$target" in
5777 *-*-solaris2.6)
5778    # Broken...
5779    ;;
5780 *) for ac_func in ntp_adjtime ntp_gettime
5781do
5782echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5783echo "configure:5784: checking for $ac_func" >&5
5784if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5785  echo $ac_n "(cached) $ac_c" 1>&6
5786else
5787  cat > conftest.$ac_ext <<EOF
5788#line 5789 "configure"
5789#include "confdefs.h"
5790/* System header to define __stub macros and hopefully few prototypes,
5791    which can conflict with char $ac_func(); below.  */
5792#include <assert.h>
5793/* Override any gcc2 internal prototype to avoid an error.  */
5794/* We use char because int might match the return type of a gcc2
5795    builtin and then its argument prototype would still apply.  */
5796char $ac_func();
5797
5798int main() {
5799
5800/* The GNU C library defines this for functions which it implements
5801    to always fail with ENOSYS.  Some functions are actually named
5802    something starting with __ and the normal name is an alias.  */
5803#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5804choke me
5805#else
5806$ac_func();
5807#endif
5808
5809; return 0; }
5810EOF
5811if { (eval echo configure:5812: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5812  rm -rf conftest*
5813  eval "ac_cv_func_$ac_func=yes"
5814else
5815  echo "configure: failed program was:" >&5
5816  cat conftest.$ac_ext >&5
5817  rm -rf conftest*
5818  eval "ac_cv_func_$ac_func=no"
5819fi
5820rm -f conftest*
5821fi
5822
5823if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5824  echo "$ac_t""yes" 1>&6
5825    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5826  cat >> confdefs.h <<EOF
5827#define $ac_tr_func 1
5828EOF
5829
5830else
5831  echo "$ac_t""no" 1>&6
5832fi
5833done
5834
5835    ;;
5836esac
5837for ac_func in plock pututline pututxline rtprio
5838do
5839echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5840echo "configure:5841: checking for $ac_func" >&5
5841if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5842  echo $ac_n "(cached) $ac_c" 1>&6
5843else
5844  cat > conftest.$ac_ext <<EOF
5845#line 5846 "configure"
5846#include "confdefs.h"
5847/* System header to define __stub macros and hopefully few prototypes,
5848    which can conflict with char $ac_func(); below.  */
5849#include <assert.h>
5850/* Override any gcc2 internal prototype to avoid an error.  */
5851/* We use char because int might match the return type of a gcc2
5852    builtin and then its argument prototype would still apply.  */
5853char $ac_func();
5854
5855int main() {
5856
5857/* The GNU C library defines this for functions which it implements
5858    to always fail with ENOSYS.  Some functions are actually named
5859    something starting with __ and the normal name is an alias.  */
5860#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5861choke me
5862#else
5863$ac_func();
5864#endif
5865
5866; return 0; }
5867EOF
5868if { (eval echo configure:5869: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5869  rm -rf conftest*
5870  eval "ac_cv_func_$ac_func=yes"
5871else
5872  echo "configure: failed program was:" >&5
5873  cat conftest.$ac_ext >&5
5874  rm -rf conftest*
5875  eval "ac_cv_func_$ac_func=no"
5876fi
5877rm -f conftest*
5878fi
5879
5880if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5881  echo "$ac_t""yes" 1>&6
5882    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5883  cat >> confdefs.h <<EOF
5884#define $ac_tr_func 1
5885EOF
5886
5887else
5888  echo "$ac_t""no" 1>&6
5889fi
5890done
5891
5892for ac_func in random srandom mrand48 srand48
5893do
5894echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5895echo "configure:5896: checking for $ac_func" >&5
5896if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5897  echo $ac_n "(cached) $ac_c" 1>&6
5898else
5899  cat > conftest.$ac_ext <<EOF
5900#line 5901 "configure"
5901#include "confdefs.h"
5902/* System header to define __stub macros and hopefully few prototypes,
5903    which can conflict with char $ac_func(); below.  */
5904#include <assert.h>
5905/* Override any gcc2 internal prototype to avoid an error.  */
5906/* We use char because int might match the return type of a gcc2
5907    builtin and then its argument prototype would still apply.  */
5908char $ac_func();
5909
5910int main() {
5911
5912/* The GNU C library defines this for functions which it implements
5913    to always fail with ENOSYS.  Some functions are actually named
5914    something starting with __ and the normal name is an alias.  */
5915#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5916choke me
5917#else
5918$ac_func();
5919#endif
5920
5921; return 0; }
5922EOF
5923if { (eval echo configure:5924: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5924  rm -rf conftest*
5925  eval "ac_cv_func_$ac_func=yes"
5926else
5927  echo "configure: failed program was:" >&5
5928  cat conftest.$ac_ext >&5
5929  rm -rf conftest*
5930  eval "ac_cv_func_$ac_func=no"
5931fi
5932rm -f conftest*
5933fi
5934
5935if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5936  echo "$ac_t""yes" 1>&6
5937    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
5938  cat >> confdefs.h <<EOF
5939#define $ac_tr_func 1
5940EOF
5941
5942else
5943  echo "$ac_t""no" 1>&6
5944fi
5945done
5946
5947case "$target" in
5948 *-*-aix4*)
5949    # Just a stub in AIX 4.  Idiots.
5950    ;;
5951 *-*-solaris2.5*)
5952    # Just stubs in solaris2.5.  Idiots.
5953    ;;
5954 *) for ac_func in sched_setscheduler
5955do
5956echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
5957echo "configure:5958: checking for $ac_func" >&5
5958if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
5959  echo $ac_n "(cached) $ac_c" 1>&6
5960else
5961  cat > conftest.$ac_ext <<EOF
5962#line 5963 "configure"
5963#include "confdefs.h"
5964/* System header to define __stub macros and hopefully few prototypes,
5965    which can conflict with char $ac_func(); below.  */
5966#include <assert.h>
5967/* Override any gcc2 internal prototype to avoid an error.  */
5968/* We use char because int might match the return type of a gcc2
5969    builtin and then its argument prototype would still apply.  */
5970char $ac_func();
5971
5972int main() {
5973
5974/* The GNU C library defines this for functions which it implements
5975    to always fail with ENOSYS.  Some functions are actually named
5976    something starting with __ and the normal name is an alias.  */
5977#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
5978choke me
5979#else
5980$ac_func();
5981#endif
5982
5983; return 0; }
5984EOF
5985if { (eval echo configure:5986: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
5986  rm -rf conftest*
5987  eval "ac_cv_func_$ac_func=yes"
5988else
5989  echo "configure: failed program was:" >&5
5990  cat conftest.$ac_ext >&5
5991  rm -rf conftest*
5992  eval "ac_cv_func_$ac_func=no"
5993fi
5994rm -f conftest*
5995fi
5996
5997if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
5998  echo "$ac_t""yes" 1>&6
5999    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6000  cat >> confdefs.h <<EOF
6001#define $ac_tr_func 1
6002EOF
6003
6004else
6005  echo "$ac_t""no" 1>&6
6006fi
6007done
6008
6009    ;;
6010esac
6011for ac_func in setlinebuf
6012do
6013echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6014echo "configure:6015: checking for $ac_func" >&5
6015if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6016  echo $ac_n "(cached) $ac_c" 1>&6
6017else
6018  cat > conftest.$ac_ext <<EOF
6019#line 6020 "configure"
6020#include "confdefs.h"
6021/* System header to define __stub macros and hopefully few prototypes,
6022    which can conflict with char $ac_func(); below.  */
6023#include <assert.h>
6024/* Override any gcc2 internal prototype to avoid an error.  */
6025/* We use char because int might match the return type of a gcc2
6026    builtin and then its argument prototype would still apply.  */
6027char $ac_func();
6028
6029int main() {
6030
6031/* The GNU C library defines this for functions which it implements
6032    to always fail with ENOSYS.  Some functions are actually named
6033    something starting with __ and the normal name is an alias.  */
6034#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6035choke me
6036#else
6037$ac_func();
6038#endif
6039
6040; return 0; }
6041EOF
6042if { (eval echo configure:6043: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6043  rm -rf conftest*
6044  eval "ac_cv_func_$ac_func=yes"
6045else
6046  echo "configure: failed program was:" >&5
6047  cat conftest.$ac_ext >&5
6048  rm -rf conftest*
6049  eval "ac_cv_func_$ac_func=no"
6050fi
6051rm -f conftest*
6052fi
6053
6054if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6055  echo "$ac_t""yes" 1>&6
6056    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6057  cat >> confdefs.h <<EOF
6058#define $ac_tr_func 1
6059EOF
6060
6061else
6062  echo "$ac_t""no" 1>&6
6063fi
6064done
6065
6066for ac_func in setpgid setpriority setsid settimeofday setvbuf sigaction
6067do
6068echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6069echo "configure:6070: checking for $ac_func" >&5
6070if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6071  echo $ac_n "(cached) $ac_c" 1>&6
6072else
6073  cat > conftest.$ac_ext <<EOF
6074#line 6075 "configure"
6075#include "confdefs.h"
6076/* System header to define __stub macros and hopefully few prototypes,
6077    which can conflict with char $ac_func(); below.  */
6078#include <assert.h>
6079/* Override any gcc2 internal prototype to avoid an error.  */
6080/* We use char because int might match the return type of a gcc2
6081    builtin and then its argument prototype would still apply.  */
6082char $ac_func();
6083
6084int main() {
6085
6086/* The GNU C library defines this for functions which it implements
6087    to always fail with ENOSYS.  Some functions are actually named
6088    something starting with __ and the normal name is an alias.  */
6089#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6090choke me
6091#else
6092$ac_func();
6093#endif
6094
6095; return 0; }
6096EOF
6097if { (eval echo configure:6098: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6098  rm -rf conftest*
6099  eval "ac_cv_func_$ac_func=yes"
6100else
6101  echo "configure: failed program was:" >&5
6102  cat conftest.$ac_ext >&5
6103  rm -rf conftest*
6104  eval "ac_cv_func_$ac_func=no"
6105fi
6106rm -f conftest*
6107fi
6108
6109if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6110  echo "$ac_t""yes" 1>&6
6111    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6112  cat >> confdefs.h <<EOF
6113#define $ac_tr_func 1
6114EOF
6115
6116else
6117  echo "$ac_t""no" 1>&6
6118fi
6119done
6120
6121for ac_func in sigvec sigset sigsuspend stime strchr sysconf sysctl
6122do
6123echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6124echo "configure:6125: checking for $ac_func" >&5
6125if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6126  echo $ac_n "(cached) $ac_c" 1>&6
6127else
6128  cat > conftest.$ac_ext <<EOF
6129#line 6130 "configure"
6130#include "confdefs.h"
6131/* System header to define __stub macros and hopefully few prototypes,
6132    which can conflict with char $ac_func(); below.  */
6133#include <assert.h>
6134/* Override any gcc2 internal prototype to avoid an error.  */
6135/* We use char because int might match the return type of a gcc2
6136    builtin and then its argument prototype would still apply.  */
6137char $ac_func();
6138
6139int main() {
6140
6141/* The GNU C library defines this for functions which it implements
6142    to always fail with ENOSYS.  Some functions are actually named
6143    something starting with __ and the normal name is an alias.  */
6144#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6145choke me
6146#else
6147$ac_func();
6148#endif
6149
6150; return 0; }
6151EOF
6152if { (eval echo configure:6153: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6153  rm -rf conftest*
6154  eval "ac_cv_func_$ac_func=yes"
6155else
6156  echo "configure: failed program was:" >&5
6157  cat conftest.$ac_ext >&5
6158  rm -rf conftest*
6159  eval "ac_cv_func_$ac_func=no"
6160fi
6161rm -f conftest*
6162fi
6163
6164if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6165  echo "$ac_t""yes" 1>&6
6166    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6167  cat >> confdefs.h <<EOF
6168#define $ac_tr_func 1
6169EOF
6170
6171else
6172  echo "$ac_t""no" 1>&6
6173fi
6174done
6175
6176for ac_func in strerror
6177do
6178echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6179echo "configure:6180: checking for $ac_func" >&5
6180if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6181  echo $ac_n "(cached) $ac_c" 1>&6
6182else
6183  cat > conftest.$ac_ext <<EOF
6184#line 6185 "configure"
6185#include "confdefs.h"
6186/* System header to define __stub macros and hopefully few prototypes,
6187    which can conflict with char $ac_func(); below.  */
6188#include <assert.h>
6189/* Override any gcc2 internal prototype to avoid an error.  */
6190/* We use char because int might match the return type of a gcc2
6191    builtin and then its argument prototype would still apply.  */
6192char $ac_func();
6193
6194int main() {
6195
6196/* The GNU C library defines this for functions which it implements
6197    to always fail with ENOSYS.  Some functions are actually named
6198    something starting with __ and the normal name is an alias.  */
6199#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6200choke me
6201#else
6202$ac_func();
6203#endif
6204
6205; return 0; }
6206EOF
6207if { (eval echo configure:6208: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6208  rm -rf conftest*
6209  eval "ac_cv_func_$ac_func=yes"
6210else
6211  echo "configure: failed program was:" >&5
6212  cat conftest.$ac_ext >&5
6213  rm -rf conftest*
6214  eval "ac_cv_func_$ac_func=no"
6215fi
6216rm -f conftest*
6217fi
6218
6219if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6220  echo "$ac_t""yes" 1>&6
6221    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6222  cat >> confdefs.h <<EOF
6223#define $ac_tr_func 1
6224EOF
6225
6226else
6227  echo "$ac_t""no" 1>&6
6228LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
6229fi
6230done
6231
6232
6233case "$target" in
6234 *-*-aix4*)
6235    # Just stubs.  Idiots.
6236    ;;
6237 *-*-netbsd*)
6238    # Just stubs.  Idiots.
6239    ;;
6240 *-*-openbsd*)
6241    # Just stubs.  Idiots.
6242    ;;
6243 *) for ac_func in timer_create timer_settime
6244do
6245echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6246echo "configure:6247: checking for $ac_func" >&5
6247if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6248  echo $ac_n "(cached) $ac_c" 1>&6
6249else
6250  cat > conftest.$ac_ext <<EOF
6251#line 6252 "configure"
6252#include "confdefs.h"
6253/* System header to define __stub macros and hopefully few prototypes,
6254    which can conflict with char $ac_func(); below.  */
6255#include <assert.h>
6256/* Override any gcc2 internal prototype to avoid an error.  */
6257/* We use char because int might match the return type of a gcc2
6258    builtin and then its argument prototype would still apply.  */
6259char $ac_func();
6260
6261int main() {
6262
6263/* The GNU C library defines this for functions which it implements
6264    to always fail with ENOSYS.  Some functions are actually named
6265    something starting with __ and the normal name is an alias.  */
6266#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6267choke me
6268#else
6269$ac_func();
6270#endif
6271
6272; return 0; }
6273EOF
6274if { (eval echo configure:6275: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6275  rm -rf conftest*
6276  eval "ac_cv_func_$ac_func=yes"
6277else
6278  echo "configure: failed program was:" >&5
6279  cat conftest.$ac_ext >&5
6280  rm -rf conftest*
6281  eval "ac_cv_func_$ac_func=no"
6282fi
6283rm -f conftest*
6284fi
6285
6286if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6287  echo "$ac_t""yes" 1>&6
6288    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6289  cat >> confdefs.h <<EOF
6290#define $ac_tr_func 1
6291EOF
6292
6293else
6294  echo "$ac_t""no" 1>&6
6295fi
6296done
6297
6298    ;;
6299esac
6300case "$target" in
6301 *-pc-cygwin*)
6302    # I have no idea...
6303    ;;
6304 *) for ac_func in umask
6305do
6306echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6307echo "configure:6308: checking for $ac_func" >&5
6308if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6309  echo $ac_n "(cached) $ac_c" 1>&6
6310else
6311  cat > conftest.$ac_ext <<EOF
6312#line 6313 "configure"
6313#include "confdefs.h"
6314/* System header to define __stub macros and hopefully few prototypes,
6315    which can conflict with char $ac_func(); below.  */
6316#include <assert.h>
6317/* Override any gcc2 internal prototype to avoid an error.  */
6318/* We use char because int might match the return type of a gcc2
6319    builtin and then its argument prototype would still apply.  */
6320char $ac_func();
6321
6322int main() {
6323
6324/* The GNU C library defines this for functions which it implements
6325    to always fail with ENOSYS.  Some functions are actually named
6326    something starting with __ and the normal name is an alias.  */
6327#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6328choke me
6329#else
6330$ac_func();
6331#endif
6332
6333; return 0; }
6334EOF
6335if { (eval echo configure:6336: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6336  rm -rf conftest*
6337  eval "ac_cv_func_$ac_func=yes"
6338else
6339  echo "configure: failed program was:" >&5
6340  cat conftest.$ac_ext >&5
6341  rm -rf conftest*
6342  eval "ac_cv_func_$ac_func=no"
6343fi
6344rm -f conftest*
6345fi
6346
6347if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6348  echo "$ac_t""yes" 1>&6
6349    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6350  cat >> confdefs.h <<EOF
6351#define $ac_tr_func 1
6352EOF
6353
6354else
6355  echo "$ac_t""no" 1>&6
6356fi
6357done
6358
6359    ;;
6360esac
6361for ac_func in uname updwtmp updwtmpx vsprintf
6362do
6363echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
6364echo "configure:6365: checking for $ac_func" >&5
6365if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
6366  echo $ac_n "(cached) $ac_c" 1>&6
6367else
6368  cat > conftest.$ac_ext <<EOF
6369#line 6370 "configure"
6370#include "confdefs.h"
6371/* System header to define __stub macros and hopefully few prototypes,
6372    which can conflict with char $ac_func(); below.  */
6373#include <assert.h>
6374/* Override any gcc2 internal prototype to avoid an error.  */
6375/* We use char because int might match the return type of a gcc2
6376    builtin and then its argument prototype would still apply.  */
6377char $ac_func();
6378
6379int main() {
6380
6381/* The GNU C library defines this for functions which it implements
6382    to always fail with ENOSYS.  Some functions are actually named
6383    something starting with __ and the normal name is an alias.  */
6384#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
6385choke me
6386#else
6387$ac_func();
6388#endif
6389
6390; return 0; }
6391EOF
6392if { (eval echo configure:6393: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
6393  rm -rf conftest*
6394  eval "ac_cv_func_$ac_func=yes"
6395else
6396  echo "configure: failed program was:" >&5
6397  cat conftest.$ac_ext >&5
6398  rm -rf conftest*
6399  eval "ac_cv_func_$ac_func=no"
6400fi
6401rm -f conftest*
6402fi
6403
6404if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
6405  echo "$ac_t""yes" 1>&6
6406    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
6407  cat >> confdefs.h <<EOF
6408#define $ac_tr_func 1
6409EOF
6410
6411else
6412  echo "$ac_t""no" 1>&6
6413fi
6414done
6415
6416
6417echo $ac_n "checking number of arguments to gettimeofday()""... $ac_c" 1>&6
6418echo "configure:6419: checking number of arguments to gettimeofday()" >&5
6419if eval "test \"`echo '$''{'ac_cv_func_Xettimeofday_nargs'+set}'`\" = set"; then
6420  echo $ac_n "(cached) $ac_c" 1>&6
6421else
6422  cat > conftest.$ac_ext <<EOF
6423#line 6424 "configure"
6424#include "confdefs.h"
6425#include <sys/time.h>
6426int main() {
6427
6428gettimeofday((struct timeval*)0,(struct timezone*)0);
6429settimeofday((struct timeval*)0,(struct timezone*)0);
6430
6431; return 0; }
6432EOF
6433if { (eval echo configure:6434: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6434  rm -rf conftest*
6435  ac_cv_func_Xettimeofday_nargs=2
6436else
6437  echo "configure: failed program was:" >&5
6438  cat conftest.$ac_ext >&5
6439  rm -rf conftest*
6440  ac_cv_func_Xettimeofday_nargs=1
6441fi
6442rm -f conftest*
6443
6444fi
6445
6446echo "$ac_t""$ac_cv_func_Xettimeofday_nargs" 1>&6
6447if test $ac_cv_func_Xettimeofday_nargs = 1; then
6448	cat >> confdefs.h <<\EOF
6449#define SYSV_TIMEOFDAY 1
6450EOF
6451
6452fi
6453
6454echo $ac_n "checking number of arguments taken by setpgrp()""... $ac_c" 1>&6
6455echo "configure:6456: checking number of arguments taken by setpgrp()" >&5
6456if eval "test \"`echo '$''{'ac_cv_func_setpgrp_nargs'+set}'`\" = set"; then
6457  echo $ac_n "(cached) $ac_c" 1>&6
6458else
6459  cat > conftest.$ac_ext <<EOF
6460#line 6461 "configure"
6461#include "confdefs.h"
6462
6463#ifdef HAVE_SYS_TYPES_H
6464# include <sys/types.h>
6465#endif
6466#ifdef HAVE_UNISTD_H
6467# include <unistd.h>
6468#endif
6469
6470int main() {
6471setpgrp(0,0);
6472; return 0; }
6473EOF
6474if { (eval echo configure:6475: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6475  rm -rf conftest*
6476  ac_cv_func_setpgrp_nargs=2
6477else
6478  echo "configure: failed program was:" >&5
6479  cat conftest.$ac_ext >&5
6480  rm -rf conftest*
6481  ac_cv_func_setpgrp_nargs=0
6482fi
6483rm -f conftest*
6484
6485fi
6486
6487echo "$ac_t""$ac_cv_func_setpgrp_nargs" 1>&6
6488if test $ac_cv_func_setpgrp_nargs = 0; then
6489        cat >> confdefs.h <<\EOF
6490#define HAVE_SETPGRP_0 1
6491EOF
6492
6493fi
6494
6495save_CFLAGS=$CFLAGS
6496CFLAGS="$CFLAGS -I$srcdir/include"
6497
6498echo $ac_n "checking argument pointer type of qsort()'s compare function and base""... $ac_c" 1>&6
6499echo "configure:6500: checking argument pointer type of qsort()'s compare function and base" >&5
6500if eval "test \"`echo '$''{'ac_cv_func_qsort_argtype'+set}'`\" = set"; then
6501  echo $ac_n "(cached) $ac_c" 1>&6
6502else
6503  cat > conftest.$ac_ext <<EOF
6504#line 6505 "configure"
6505#include "confdefs.h"
6506
6507#include "l_stdlib.h"
6508
6509#ifdef HAVE_PROTOTYPES
6510#define P(x) x
6511#else
6512#define P(x) ()
6513#endif
6514
6515extern void *base;
6516extern sortfunc P((const void *, const void *));
6517int sortfunc(a, b)
6518  const void *a;
6519  const void *b; { return 0; }
6520
6521int main() {
6522
6523qsort(base, 2, sizeof(char *), sortfunc);
6524
6525; return 0; }
6526EOF
6527if { (eval echo configure:6528: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6528  rm -rf conftest*
6529  ac_cv_func_qsort_argtype=void
6530else
6531  echo "configure: failed program was:" >&5
6532  cat conftest.$ac_ext >&5
6533  rm -rf conftest*
6534  ac_cv_func_qsort_argtype=char
6535fi
6536rm -f conftest*
6537
6538fi
6539
6540echo "$ac_t""$ac_cv_func_qsort_argtype" 1>&6
6541case "$ac_cv_func_qsort_argtype" in
6542 void)
6543    cat >> confdefs.h <<\EOF
6544#define QSORT_USES_VOID_P 1
6545EOF
6546
6547    ;;
6548esac
6549
6550CFLAGS=$save_CFLAGS
6551
6552echo $ac_n "checking if we need to declare 'errno'""... $ac_c" 1>&6
6553echo "configure:6554: checking if we need to declare 'errno'" >&5
6554if eval "test \"`echo '$''{'ac_cv_decl_errno'+set}'`\" = set"; then
6555  echo $ac_n "(cached) $ac_c" 1>&6
6556else
6557  cat > conftest.$ac_ext <<EOF
6558#line 6559 "configure"
6559#include "confdefs.h"
6560#ifdef HAVE_ERRNO_H
6561#include <errno.h>
6562#endif
6563int main() {
6564errno = 0;
6565; return 0; }
6566EOF
6567if { (eval echo configure:6568: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6568  rm -rf conftest*
6569  ac_cv_decl_errno=no
6570else
6571  echo "configure: failed program was:" >&5
6572  cat conftest.$ac_ext >&5
6573  rm -rf conftest*
6574  ac_cv_decl_errno=yes
6575fi
6576rm -f conftest*
6577fi
6578
6579echo "$ac_t""$ac_cv_decl_errno" 1>&6
6580case "$ac_cv_decl_errno" in
6581 yes) cat >> confdefs.h <<\EOF
6582#define DECL_ERRNO 1
6583EOF
6584 ;;
6585esac
6586
6587echo $ac_n "checking if we may declare 'h_errno'""... $ac_c" 1>&6
6588echo "configure:6589: checking if we may declare 'h_errno'" >&5
6589if eval "test \"`echo '$''{'ac_cv_decl_h_errno'+set}'`\" = set"; then
6590  echo $ac_n "(cached) $ac_c" 1>&6
6591else
6592  cat > conftest.$ac_ext <<EOF
6593#line 6594 "configure"
6594#include "confdefs.h"
6595#include <sys/types.h>
6596#ifdef HAVE_NETINET_IN_H
6597#include <netinet/in.h>
6598#endif
6599#ifdef HAVE_ARPA_NAMESER_H
6600#include <arpa/nameser.h>
6601#endif
6602#ifdef HAVE_NETDB_H
6603#include <netdb.h>
6604#endif
6605#ifdef HAVE_RESOLV_H
6606#include <resolv.h>
6607#endif
6608int main() {
6609extern int h_errno;
6610; return 0; }
6611EOF
6612if { (eval echo configure:6613: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6613  rm -rf conftest*
6614  ac_cv_decl_h_errno=yes
6615else
6616  echo "configure: failed program was:" >&5
6617  cat conftest.$ac_ext >&5
6618  rm -rf conftest*
6619  ac_cv_decl_h_errno=no
6620fi
6621rm -f conftest*
6622fi
6623
6624echo "$ac_t""$ac_cv_decl_h_errno" 1>&6
6625case "$ac_cv_decl_h_errno" in
6626 yes) cat >> confdefs.h <<\EOF
6627#define DECL_H_ERRNO 1
6628EOF
6629 ;;
6630esac
6631
6632echo $ac_n "checking if declaring 'char *sys_errlist[]' is ok""... $ac_c" 1>&6
6633echo "configure:6634: checking if declaring 'char *sys_errlist[]' is ok" >&5
6634if eval "test \"`echo '$''{'ac_cv_decl_sys_errlist'+set}'`\" = set"; then
6635  echo $ac_n "(cached) $ac_c" 1>&6
6636else
6637  cat > conftest.$ac_ext <<EOF
6638#line 6639 "configure"
6639#include "confdefs.h"
6640#include <stdio.h>
6641#ifdef HAVE_ERRNO_H
6642#include <errno.h>
6643#endif
6644int main() {
6645  extern char *sys_errlist[];
6646  
6647; return 0; }
6648EOF
6649if { (eval echo configure:6650: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6650  rm -rf conftest*
6651  ac_cv_decl_sys_errlist=yes
6652else
6653  echo "configure: failed program was:" >&5
6654  cat conftest.$ac_ext >&5
6655  rm -rf conftest*
6656  ac_cv_decl_sys_errlist=no
6657fi
6658rm -f conftest*
6659fi
6660
6661echo "$ac_t""$ac_cv_decl_sys_errlist" 1>&6
6662case "$ac_cv_decl_sys_errlist" in
6663 yes) cat >> confdefs.h <<\EOF
6664#define CHAR_SYS_ERRLIST 1
6665EOF
6666 ;;
6667esac
6668
6669echo $ac_n "checking if declaring 'syscall()' is ok""... $ac_c" 1>&6
6670echo "configure:6671: checking if declaring 'syscall()' is ok" >&5
6671if eval "test \"`echo '$''{'ac_cv_decl_syscall'+set}'`\" = set"; then
6672  echo $ac_n "(cached) $ac_c" 1>&6
6673else
6674  cat > conftest.$ac_ext <<EOF
6675#line 6676 "configure"
6676#include "confdefs.h"
6677
6678#ifdef HAVE_SYS_TYPES_H
6679# include <sys/types.h>
6680#endif
6681#ifdef HAVE_UNISTD_H
6682# include <unistd.h>
6683#endif
6684#ifdef HAVE_PROTOTYPES
6685#define P(x) x
6686#else
6687#define P(x) ()
6688#endif
6689
6690int main() {
6691extern int syscall P((int, ...));
6692; return 0; }
6693EOF
6694if { (eval echo configure:6695: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
6695  rm -rf conftest*
6696  ac_cv_decl_syscall=yes
6697else
6698  echo "configure: failed program was:" >&5
6699  cat conftest.$ac_ext >&5
6700  rm -rf conftest*
6701  ac_cv_decl_syscall=no
6702fi
6703rm -f conftest*
6704fi
6705
6706echo "$ac_t""$ac_cv_decl_syscall" 1>&6
6707case "$ac_cv_decl_syscall" in
6708 yes) cat >> confdefs.h <<\EOF
6709#define DECL_SYSCALL 1
6710EOF
6711 ;;
6712esac
6713
6714case "$target" in
6715 *-*-osf[45]*)
6716    cat >> confdefs.h <<\EOF
6717#define DECL_PLOCK_0 1
6718EOF
6719
6720    cat >> confdefs.h <<\EOF
6721#define DECL_STIME_1 1
6722EOF
6723
6724    ;;
6725 *-*-riscos4*)
6726    cat >> confdefs.h <<\EOF
6727#define DECL_ADJTIME_0 1
6728EOF
6729
6730    cat >> confdefs.h <<\EOF
6731#define DECL_BZERO_0 1
6732EOF
6733
6734    cat >> confdefs.h <<\EOF
6735#define DECL_IOCTL_0 1
6736EOF
6737
6738    cat >> confdefs.h <<\EOF
6739#define DECL_IPC_0 1
6740EOF
6741
6742    cat >> confdefs.h <<\EOF
6743#define DECL_MEMMOVE_0 1
6744EOF
6745
6746    cat >> confdefs.h <<\EOF
6747#define DECL_MKTEMP_0 1
6748EOF
6749
6750    cat >> confdefs.h <<\EOF
6751#define DECL_RENAME_0 1
6752EOF
6753
6754    cat >> confdefs.h <<\EOF
6755#define DECL_SELECT_0 1
6756EOF
6757
6758    cat >> confdefs.h <<\EOF
6759#define DECL_SETITIMER_0 1
6760EOF
6761
6762    cat >> confdefs.h <<\EOF
6763#define DECL_SETPRIORITY_0 1
6764EOF
6765
6766    cat >> confdefs.h <<\EOF
6767#define DECL_STDIO_0 1
6768EOF
6769
6770    cat >> confdefs.h <<\EOF
6771#define DECL_STRTOL_0 1
6772EOF
6773
6774    cat >> confdefs.h <<\EOF
6775#define DECL_SYSLOG_0 1
6776EOF
6777
6778    cat >> confdefs.h <<\EOF
6779#define DECL_TIME_0 1
6780EOF
6781
6782    cat >> confdefs.h <<\EOF
6783#define DECL_TIMEOFDAY_0 1
6784EOF
6785
6786    cat >> confdefs.h <<\EOF
6787#define DECL_TOLOWER_0 1
6788EOF
6789
6790    ;;
6791 *-*-solaris2*)
6792    cat >> confdefs.h <<\EOF
6793#define DECL_MKSTEMP_0 1
6794EOF
6795
6796    cat >> confdefs.h <<\EOF
6797#define DECL_SETPRIORITY_1 1
6798EOF
6799
6800    case "$target" in
6801     *-*-solaris2.4)
6802        cat >> confdefs.h <<\EOF
6803#define DECL_TIMEOFDAY_0 1
6804EOF
6805
6806	;;
6807    esac
6808    ;;
6809 *-*-sunos4*)
6810    cat >> confdefs.h <<\EOF
6811#define DECL_ADJTIME_0 1
6812EOF
6813
6814    cat >> confdefs.h <<\EOF
6815#define DECL_BCOPY_0 1
6816EOF
6817
6818    cat >> confdefs.h <<\EOF
6819#define DECL_BZERO_0 1
6820EOF
6821
6822    cat >> confdefs.h <<\EOF
6823#define DECL_IOCTL_0 1
6824EOF
6825
6826    cat >> confdefs.h <<\EOF
6827#define DECL_IPC_0 1
6828EOF
6829
6830    cat >> confdefs.h <<\EOF
6831#define DECL_MEMMOVE_0 1
6832EOF
6833
6834    cat >> confdefs.h <<\EOF
6835#define DECL_MKTEMP_0 1
6836EOF
6837
6838    cat >> confdefs.h <<\EOF
6839#define DECL_MKSTEMP_0 1
6840EOF
6841
6842    cat >> confdefs.h <<\EOF
6843#define DECL_MRAND48_0 1
6844EOF
6845
6846    cat >> confdefs.h <<\EOF
6847#define DECL_RENAME_0 1
6848EOF
6849
6850    cat >> confdefs.h <<\EOF
6851#define DECL_SELECT_0 1
6852EOF
6853
6854    cat >> confdefs.h <<\EOF
6855#define DECL_SETITIMER_0 1
6856EOF
6857
6858    cat >> confdefs.h <<\EOF
6859#define DECL_SETPRIORITY_0 1
6860EOF
6861
6862    cat >> confdefs.h <<\EOF
6863#define DECL_SIGVEC_0 1
6864EOF
6865
6866    cat >> confdefs.h <<\EOF
6867#define DECL_SRAND48_0 1
6868EOF
6869
6870    case "`basename $ac_cv_prog_CC`" in
6871     acc*) ;;
6872     *) cat >> confdefs.h <<\EOF
6873#define DECL_STDIO_0 1
6874EOF
6875
6876	;;
6877    esac
6878    cat >> confdefs.h <<\EOF
6879#define DECL_STRTOL_0 1
6880EOF
6881
6882    cat >> confdefs.h <<\EOF
6883#define DECL_SYSLOG_0 1
6884EOF
6885
6886    cat >> confdefs.h <<\EOF
6887#define DECL_TIME_0 1
6888EOF
6889
6890    cat >> confdefs.h <<\EOF
6891#define DECL_TIMEOFDAY_0 1
6892EOF
6893
6894    cat >> confdefs.h <<\EOF
6895#define DECL_TOLOWER_0 1
6896EOF
6897
6898    cat >> confdefs.h <<\EOF
6899#define DECL_TOUPPER_0 1
6900EOF
6901
6902    ;;
6903 *-*-ultrix4*)
6904    cat >> confdefs.h <<\EOF
6905#define DECL_ADJTIME_0 1
6906EOF
6907
6908    cat >> confdefs.h <<\EOF
6909#define DECL_BZERO_0 1
6910EOF
6911
6912    cat >> confdefs.h <<\EOF
6913#define DECL_CFSETISPEED_0 1
6914EOF
6915
6916    cat >> confdefs.h <<\EOF
6917#define DECL_IOCTL_0 1
6918EOF
6919
6920    cat >> confdefs.h <<\EOF
6921#define DECL_IPC_0 1
6922EOF
6923
6924    cat >> confdefs.h <<\EOF
6925#define DECL_MKTEMP_0 1
6926EOF
6927
6928    cat >> confdefs.h <<\EOF
6929#define DECL_MRAND48_0 1
6930EOF
6931
6932    cat >> confdefs.h <<\EOF
6933#define DECL_NLIST_0 1
6934EOF
6935
6936    cat >> confdefs.h <<\EOF
6937#define DECL_PLOCK_0 1
6938EOF
6939
6940    cat >> confdefs.h <<\EOF
6941#define DECL_SELECT_0 1
6942EOF
6943
6944    cat >> confdefs.h <<\EOF
6945#define DECL_SETITIMER_0 1
6946EOF
6947
6948    cat >> confdefs.h <<\EOF
6949#define DECL_SETPRIORITY_0 1
6950EOF
6951
6952    cat >> confdefs.h <<\EOF
6953#define DECL_SRAND48_0 1
6954EOF
6955
6956    cat >> confdefs.h <<\EOF
6957#define DECL_STIME_0 1
6958EOF
6959
6960    cat >> confdefs.h <<\EOF
6961#define DECL_SYSLOG_0 1
6962EOF
6963
6964    cat >> confdefs.h <<\EOF
6965#define DECL_TIMEOFDAY_0 1
6966EOF
6967
6968    ;;
6969esac
6970
6971case "$target" in
6972 *-*-sco3.2*)
6973    cat >> confdefs.h <<\EOF
6974#define TERMIOS_NEEDS__SVID3 1
6975EOF
6976
6977    ;;
6978esac
6979
6980echo $ac_n "checking if we should use a streams device for ifconfig""... $ac_c" 1>&6
6981echo "configure:6982: checking if we should use a streams device for ifconfig" >&5
6982if eval "test \"`echo '$''{'ac_cv_var_use_streams_device_for_ifconfig'+set}'`\" = set"; then
6983  echo $ac_n "(cached) $ac_c" 1>&6
6984else
6985  ac_cv_var_use_streams_device_for_ifconfig=no
6986fi
6987
6988echo "$ac_t""$ac_cv_var_use_streams_device_for_ifconfig" 1>&6
6989
6990echo $ac_n "checking if we need extra room for SO_RCVBUF""... $ac_c" 1>&6
6991echo "configure:6992: checking if we need extra room for SO_RCVBUF" >&5
6992if eval "test \"`echo '$''{'ac_cv_var_rcvbuf_slop'+set}'`\" = set"; then
6993  echo $ac_n "(cached) $ac_c" 1>&6
6994else
6995  ans=no
6996case "$target" in
6997 *-*-hpux[567]*)
6998    ans=yes
6999    ;;
7000esac
7001ac_cv_var_rcvbuf_slop=$ans
7002fi
7003
7004echo "$ac_t""$ac_cv_var_rcvbuf_slop" 1>&6
7005case "$ac_cv_var_rcvbuf_slop" in
7006 yes) cat >> confdefs.h <<\EOF
7007#define NEED_RCVBUF_SLOP 1
7008EOF
7009 ;;
7010esac
7011
7012echo $ac_n "checking if we will open the broadcast socket""... $ac_c" 1>&6
7013echo "configure:7014: checking if we will open the broadcast socket" >&5
7014if eval "test \"`echo '$''{'ac_cv_var_open_bcast_socket'+set}'`\" = set"; then
7015  echo $ac_n "(cached) $ac_c" 1>&6
7016else
7017  ans=yes
7018case "$target" in
7019 *-*-domainos)
7020    ans=no
7021    ;;
7022 *-*-linux*)
7023    ans=no
7024    ;;
7025esac
7026ac_cv_var_open_bcast_socket=$ans
7027fi
7028
7029echo "$ac_t""$ac_cv_var_open_bcast_socket" 1>&6
7030case "$ac_cv_var_open_bcast_socket" in
7031 yes) cat >> confdefs.h <<\EOF
7032#define OPEN_BCAST_SOCKET 1
7033EOF
7034 ;;
7035esac
7036
7037echo $ac_n "checking if we want the HPUX version of FindConfig()""... $ac_c" 1>&6
7038echo "configure:7039: checking if we want the HPUX version of FindConfig()" >&5
7039if eval "test \"`echo '$''{'ac_cv_var_hpux_findconfig'+set}'`\" = set"; then
7040  echo $ac_n "(cached) $ac_c" 1>&6
7041else
7042  ans=no
7043case "$target" in
7044 *-*-hpux*)
7045    ans=yes
7046    ;;
7047esac
7048ac_cv_var_hpux_findconfig=$ans
7049fi
7050
7051echo "$ac_t""$ac_cv_var_hpux_findconfig" 1>&6
7052case "$ac_cv_var_hpux_findconfig" in
7053 yes) cat >> confdefs.h <<\EOF
7054#define NEED_HPUX_FINDCONFIG 1
7055EOF
7056 ;;
7057esac
7058
7059echo $ac_n "checking if process groups are set with -pid""... $ac_c" 1>&6
7060echo "configure:7061: checking if process groups are set with -pid" >&5
7061if eval "test \"`echo '$''{'ac_cv_arg_setpgrp_negpid'+set}'`\" = set"; then
7062  echo $ac_n "(cached) $ac_c" 1>&6
7063else
7064  case "$target" in
7065 *-*-hpux[567]*)
7066    ans=no
7067    ;;
7068 *-*-hpux*)
7069    ans=yes
7070    ;;
7071 *-*-linux*)
7072    ans=yes
7073    ;;
7074 *-*-sunos3*)
7075    ans=yes
7076    ;;
7077 *-*-ultrix2*)
7078    ans=yes
7079    ;;
7080 *)
7081    ans=no
7082    ;;
7083esac
7084ac_cv_arg_setpgrp_negpid=$ans
7085fi
7086
7087echo "$ac_t""$ac_cv_arg_setpgrp_negpid" 1>&6
7088case "$ac_cv_arg_setpgrp_negpid" in
7089 yes) cat >> confdefs.h <<\EOF
7090#define UDP_BACKWARDS_SETOWN 1
7091EOF
7092 ;;
7093esac
7094
7095echo $ac_n "checking if we need a ctty for F_SETOWN""... $ac_c" 1>&6
7096echo "configure:7097: checking if we need a ctty for F_SETOWN" >&5
7097if eval "test \"`echo '$''{'ac_cv_func_ctty_for_f_setown'+set}'`\" = set"; then
7098  echo $ac_n "(cached) $ac_c" 1>&6
7099else
7100  case "$target" in
7101 *-*-bsdi2*)
7102    ans=yes
7103    ;;
7104 *-*-freebsd*)
7105    ans=yes
7106    ;;
7107 *-*-netbsd*)
7108    ans=yes
7109    ;;
7110 *-*-osf*)
7111    ans=yes
7112    ;;
7113 *) ans=no
7114    ;;
7115esac
7116ac_cv_func_ctty_for_f_setown=$ans
7117fi
7118
7119echo "$ac_t""$ac_cv_func_ctty_for_f_setown" 1>&6
7120case "$ac_cv_func_ctty_for_f_setown" in
7121 yes) cat >> confdefs.h <<\EOF
7122#define USE_FSETOWNCTTY 1
7123EOF
7124 ;;
7125esac
7126
7127ntp_warning='GRONK'
7128echo $ac_n "checking if we'll use clock_settime or settimeofday or stime""... $ac_c" 1>&6
7129echo "configure:7130: checking if we'll use clock_settime or settimeofday or stime" >&5
7130case "$ac_cv_func_clock_settime$ac_cv_func_settimeofday$ac_cv_func_stime" in
7131 yes*)
7132    ntp_warning=''
7133    ans='clock_settime()'
7134    ;;
7135 noyes*)
7136    ntp_warning='But clock_settime() would be better (if we had it)'
7137    ans='settimeofday()'
7138    ;;
7139 nonoyes)
7140    ntp_warning='Which is the worst of the three'
7141    ans='stime()'
7142    ;;
7143 *)
7144    case "$host" in
7145     $target) ntp_warning='Which leaves us with nothing to use!'
7146    ans=none
7147    ;;
7148esac
7149esac
7150echo "$ac_t""$ans" 1>&6
7151case "$ntp_warning" in
7152 '') ;;
7153 *) echo "configure: warning: *** $ntp_warning ***" 1>&2
7154    ;;
7155esac
7156
7157echo $ac_n "checking if we have a losing syscall()""... $ac_c" 1>&6
7158echo "configure:7159: checking if we have a losing syscall()" >&5
7159if eval "test \"`echo '$''{'ac_cv_var_syscall_bug'+set}'`\" = set"; then
7160  echo $ac_n "(cached) $ac_c" 1>&6
7161else
7162  case "$target" in
7163 *-*-solaris2.4*)
7164    ans=yes
7165    ;;
7166 *) ans=no
7167    ;;
7168esac
7169ac_cv_var_syscall_bug=$ans
7170fi
7171
7172echo "$ac_t""$ac_cv_var_syscall_bug" 1>&6
7173case "$ac_cv_var_syscall_bug" in
7174 yes) cat >> confdefs.h <<\EOF
7175#define SYSCALL_BUG 1
7176EOF
7177 ;;
7178esac
7179
7180echo $ac_n "checking for Streams/TLI""... $ac_c" 1>&6
7181echo "configure:7182: checking for Streams/TLI" >&5
7182if eval "test \"`echo '$''{'ac_cv_var_streams_tli'+set}'`\" = set"; then
7183  echo $ac_n "(cached) $ac_c" 1>&6
7184else
7185   case "$ac_cv_header_sys_stropts_h" in
7186  yes)
7187     ans=no
7188     # There must be a better way...
7189     case "$target" in
7190      *-*-ptx*)
7191         ans=yes
7192         ;;
7193     esac
7194     ;;
7195 esac
7196 ac_cv_var_streams_tli=$ans
7197fi
7198
7199echo "$ac_t""$ac_cv_var_streams_tli" 1>&6
7200case "$ac_cv_var_streams_tli" in
7201 yes)
7202    cat >> confdefs.h <<\EOF
7203#define STREAMS_TLI 1
7204EOF
7205
7206    ;;
7207esac
7208
7209echo $ac_n "checking for SIGIO""... $ac_c" 1>&6
7210echo "configure:7211: checking for SIGIO" >&5
7211if eval "test \"`echo '$''{'ac_cv_hdr_def_sigio'+set}'`\" = set"; then
7212  echo $ac_n "(cached) $ac_c" 1>&6
7213else
7214  cat > conftest.$ac_ext <<EOF
7215#line 7216 "configure"
7216#include "confdefs.h"
7217#include <signal.h>
7218#ifdef SIGIO
7219   yes
7220#endif
7221  
7222EOF
7223if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7224  egrep "yes" >/dev/null 2>&1; then
7225  rm -rf conftest*
7226  ac_cv_hdr_def_sigio=yes
7227else
7228  rm -rf conftest*
7229  ac_cv_hdr_def_sigio=no
7230fi
7231rm -f conftest*
7232
7233fi
7234
7235echo "$ac_t""$ac_cv_hdr_def_sigio" 1>&6
7236
7237echo $ac_n "checking if we want to use signalled IO""... $ac_c" 1>&6
7238echo "configure:7239: checking if we want to use signalled IO" >&5
7239if eval "test \"`echo '$''{'ac_cv_var_signalled_io'+set}'`\" = set"; then
7240  echo $ac_n "(cached) $ac_c" 1>&6
7241else
7242  ans=no
7243case "$ac_cv_hdr_def_sigio" in
7244 yes)
7245    ans=yes
7246    case "$target" in
7247     alpha*-dec-osf4*|alpha*-dec-osf5*)
7248        ans=no
7249        ;;
7250     *-convex-*)
7251        ans=no
7252        ;;
7253     *-dec-*)
7254        ans=no
7255        ;;
7256     *-pc-cygwin*)
7257	ans=no
7258	;;
7259     *-sni-sysv*)
7260        ans=no
7261        ;;
7262     *-univel-sysv*)
7263        ans=no
7264	;;
7265     *-*-irix6*)
7266	ans=no
7267	;;
7268     *-*-freebsd*)
7269	ans=no
7270	;;
7271     *-*-linux*)
7272	ans=no
7273	;;
7274    esac
7275    ;;
7276esac
7277ac_cv_var_signalled_io=$ans
7278fi
7279
7280echo "$ac_t""$ac_cv_var_signalled_io" 1>&6
7281case "$ac_cv_var_signalled_io" in
7282 yes) cat >> confdefs.h <<\EOF
7283#define HAVE_SIGNALED_IO 1
7284EOF
7285 ;;
7286esac
7287
7288echo $ac_n "checking for SIGPOLL""... $ac_c" 1>&6
7289echo "configure:7290: checking for SIGPOLL" >&5
7290if eval "test \"`echo '$''{'ac_cv_hdr_def_sigpoll'+set}'`\" = set"; then
7291  echo $ac_n "(cached) $ac_c" 1>&6
7292else
7293  cat > conftest.$ac_ext <<EOF
7294#line 7295 "configure"
7295#include "confdefs.h"
7296#include <signal.h>
7297#ifdef SIGPOLL
7298  yes
7299#endif
7300 
7301EOF
7302if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7303  egrep "yes" >/dev/null 2>&1; then
7304  rm -rf conftest*
7305  ac_cv_hdr_def_sigpoll=yes
7306else
7307  rm -rf conftest*
7308  ac_cv_hdr_def_sigpoll=no
7309fi
7310rm -f conftest*
7311
7312fi
7313
7314echo "$ac_t""$ac_cv_hdr_def_sigpoll" 1>&6
7315
7316echo $ac_n "checking for SIGSYS""... $ac_c" 1>&6
7317echo "configure:7318: checking for SIGSYS" >&5
7318if eval "test \"`echo '$''{'ac_cv_hdr_def_sigsys'+set}'`\" = set"; then
7319  echo $ac_n "(cached) $ac_c" 1>&6
7320else
7321  cat > conftest.$ac_ext <<EOF
7322#line 7323 "configure"
7323#include "confdefs.h"
7324#include <signal.h>
7325#ifdef SIGSYS
7326  yes
7327#endif
7328 
7329EOF
7330if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7331  egrep "yes" >/dev/null 2>&1; then
7332  rm -rf conftest*
7333  ac_cv_hdr_def_sigsys=yes
7334else
7335  rm -rf conftest*
7336  ac_cv_hdr_def_sigsys=no
7337fi
7338rm -f conftest*
7339
7340fi
7341
7342echo "$ac_t""$ac_cv_hdr_def_sigsys" 1>&6
7343
7344echo $ac_n "checking if we can use SIGPOLL for UDP I/O""... $ac_c" 1>&6
7345echo "configure:7346: checking if we can use SIGPOLL for UDP I/O" >&5
7346if eval "test \"`echo '$''{'ac_cv_var_use_udp_sigpoll'+set}'`\" = set"; then
7347  echo $ac_n "(cached) $ac_c" 1>&6
7348else
7349  ans=no
7350case "$ac_cv_hdr_def_sigpoll" in
7351 yes)
7352        case "$target" in
7353     mips-sgi-irix*)
7354	ans=no
7355	;;
7356     vax-dec-bsd)
7357        ans=no
7358        ;;
7359     *-pc-cygwin*)
7360	ans=no
7361	;;
7362     *-sni-sysv*)
7363        ans=no
7364        ;;
7365     *-*-aix4*)
7366        ans=no
7367        ;;
7368     *-*-hpux*)
7369        ans=no
7370        ;;
7371     *-*-linux*)
7372	ans=no
7373	;;
7374     *-*-osf*)
7375        ans=no
7376        ;;
7377     *-*-sunos*)
7378	ans=no
7379	;;
7380     *-*-ultrix*)
7381        ans=no
7382        ;;
7383     *) ans=yes
7384        ;;
7385    esac
7386        ;;
7387esac
7388ac_cv_var_use_udp_sigpoll=$ans
7389fi
7390
7391echo "$ac_t""$ac_cv_var_use_udp_sigpoll" 1>&6
7392case "$ac_cv_var_use_udp_sigpoll" in
7393 yes) cat >> confdefs.h <<\EOF
7394#define USE_UDP_SIGPOLL 1
7395EOF
7396 ;;
7397esac
7398
7399echo $ac_n "checking if we can use SIGPOLL for TTY I/O""... $ac_c" 1>&6
7400echo "configure:7401: checking if we can use SIGPOLL for TTY I/O" >&5
7401if eval "test \"`echo '$''{'ac_cv_var_use_tty_sigpoll'+set}'`\" = set"; then
7402  echo $ac_n "(cached) $ac_c" 1>&6
7403else
7404  ans=no
7405case "$ac_cv_hdr_def_sigpoll" in
7406 yes)
7407    case "$target" in
7408     mips-sgi-irix*)
7409        ans=no
7410        ;;
7411     vax-dec-bsd)
7412        ans=no
7413        ;;
7414     *-pc-cygwin*)
7415	ans=no
7416	;;
7417     *-sni-sysv*)
7418        ans=no
7419        ;;
7420     *-*-aix4*)
7421	ans=no
7422	;;
7423     *-*-hpux*)
7424        ans=no
7425        ;;
7426     *-*-linux*)
7427	ans=no
7428	;;
7429     *-*-osf*)
7430        ans=no
7431        ;;
7432     *-*-sunos*)
7433	ans=no
7434	;;
7435     *-*-ultrix*)
7436        ans=no
7437        ;;
7438     *) ans=yes
7439        ;;
7440    esac
7441    ;;
7442esac
7443ac_cv_var_use_tty_sigpoll=$ans
7444fi
7445
7446echo "$ac_t""$ac_cv_var_use_tty_sigpoll" 1>&6
7447case "$ac_cv_var_use_tty_sigpoll" in
7448 yes) cat >> confdefs.h <<\EOF
7449#define USE_TTY_SIGPOLL 1
7450EOF
7451 ;;
7452esac
7453
7454case "$ac_cv_header_sys_sio_h" in
7455 yes)
7456    echo $ac_n "checking sys/sio.h for TIOCDCDTIMESTAMP""... $ac_c" 1>&6
7457echo "configure:7458: checking sys/sio.h for TIOCDCDTIMESTAMP" >&5
7458if eval "test \"`echo '$''{'ac_cv_hdr_def_tiocdcdtimestamp'+set}'`\" = set"; then
7459  echo $ac_n "(cached) $ac_c" 1>&6
7460else
7461  cat > conftest.$ac_ext <<EOF
7462#line 7463 "configure"
7463#include "confdefs.h"
7464#include <sys/sio.h>
7465#ifdef TIOCDCDTIMESTAMP
7466  yes
7467#endif
7468     
7469EOF
7470if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7471  egrep "yes" >/dev/null 2>&1; then
7472  rm -rf conftest*
7473  ac_cv_hdr_def_tiocdcdtimestamp=yes
7474else
7475  rm -rf conftest*
7476  ac_cv_hdr_def_tiocdcdtimestamp=no
7477fi
7478rm -f conftest*
7479
7480fi
7481
7482echo "$ac_t""$ac_cv_hdr_def_tiocdcdtimestamp" 1>&6
7483    ;;
7484esac
7485
7486case "$ac_cv_hdr_def_tiocdcdtimestamp" in
7487 yes)
7488    ac_cv_var_oncore_ok=yes
7489    ;;
7490esac
7491
7492echo $ac_n "checking if nlist() values might require extra indirection""... $ac_c" 1>&6
7493echo "configure:7494: checking if nlist() values might require extra indirection" >&5
7494if eval "test \"`echo '$''{'ac_cv_var_nlist_extra_indirection'+set}'`\" = set"; then
7495  echo $ac_n "(cached) $ac_c" 1>&6
7496else
7497  ans=no
7498case "$target" in
7499 *-*-aix*)
7500    ans=yes
7501    ;;
7502esac
7503ac_cv_var_nlist_extra_indirection=$ans
7504fi
7505
7506echo "$ac_t""$ac_cv_var_nlist_extra_indirection" 1>&6
7507case "$ac_cv_var_nlist_extra_indirection" in
7508 yes) cat >> confdefs.h <<\EOF
7509#define NLIST_EXTRA_INDIRECTION 1
7510EOF
7511 ;;
7512esac
7513
7514echo $ac_n "checking for a minimum recommended value of tickadj""... $ac_c" 1>&6
7515echo "configure:7516: checking for a minimum recommended value of tickadj" >&5
7516if eval "test \"`echo '$''{'ac_cv_var_min_rec_tickadj'+set}'`\" = set"; then
7517  echo $ac_n "(cached) $ac_c" 1>&6
7518else
7519  ans=no
7520case "$target" in
7521 *-*-aix*)
7522    ans=40
7523    ;;
7524esac
7525ac_cv_var_min_rec_tickadj=$ans
7526fi
7527
7528echo "$ac_t""$ac_cv_var_min_rec_tickadj" 1>&6
7529case "$ac_cv_var_min_rec_tickadj" in
7530 ''|no) ;;
7531 *) cat >> confdefs.h <<EOF
7532#define MIN_REC_TICKADJ $ac_cv_var_min_rec_tickadj
7533EOF
7534 ;;
7535esac
7536
7537echo $ac_n "checking if the TTY code permits PARENB and IGNPAR""... $ac_c" 1>&6
7538echo "configure:7539: checking if the TTY code permits PARENB and IGNPAR" >&5
7539if eval "test \"`echo '$''{'ac_cv_var_no_parenb_ignpar'+set}'`\" = set"; then
7540  echo $ac_n "(cached) $ac_c" 1>&6
7541else
7542  ans=no
7543case "$target" in
7544 i?86-*-linux*)
7545    ans=yes
7546    ;;
7547 mips-sgi-irix*)
7548    ans=yes
7549    ;;
7550esac
7551ac_cv_var_no_parenb_ignpar=$ans
7552fi
7553
7554echo "$ac_t""$ac_cv_var_no_parenb_ignpar" 1>&6
7555case "$ac_cv_var_no_parenb_ignpar" in
7556 yes) cat >> confdefs.h <<\EOF
7557#define NO_PARENB_IGNPAR 1
7558EOF
7559 ;;
7560esac
7561
7562echo $ac_n "checking if we're including debugging code""... $ac_c" 1>&6
7563echo "configure:7564: checking if we're including debugging code" >&5
7564# Check whether --enable-debugging or --disable-debugging was given.
7565if test "${enable_debugging+set}" = set; then
7566  enableval="$enable_debugging"
7567  ntp_ok=$enableval
7568else
7569  ntp_ok=yes
7570fi
7571
7572if test "$ntp_ok" = "yes"; then
7573    cat >> confdefs.h <<\EOF
7574#define DEBUG 1
7575EOF
7576
7577fi
7578echo "$ac_t""$ntp_ok" 1>&6
7579
7580echo $ac_n "checking for a the number of minutes in a DST adjustment""... $ac_c" 1>&6
7581echo "configure:7582: checking for a the number of minutes in a DST adjustment" >&5
7582# Check whether --enable-dst_minutes or --disable-dst_minutes was given.
7583if test "${enable_dst_minutes+set}" = set; then
7584  enableval="$enable_dst_minutes"
7585  ans=$enableval
7586else
7587  ans=60
7588fi
7589
7590cat >> confdefs.h <<EOF
7591#define DSTMINUTES $ans
7592EOF
7593
7594echo "$ac_t""$ans" 1>&6
7595
7596echo $ac_n "checking if we have the tty_clk line discipline/streams module""... $ac_c" 1>&6
7597echo "configure:7598: checking if we have the tty_clk line discipline/streams module" >&5
7598if eval "test \"`echo '$''{'ac_cv_var_tty_clk'+set}'`\" = set"; then
7599  echo $ac_n "(cached) $ac_c" 1>&6
7600else
7601  case "$ac_cv_header_sys_clkdefs_h$ac_cv_hdr_def_tiocdcdtimestamp" in
7602  *yes*) ac_cv_var_tty_clk=yes ;;
7603 esac
7604fi
7605
7606echo "$ac_t""$ac_cv_var_tty_clk" 1>&6
7607case "$ac_cv_var_tty_clk" in
7608 yes) cat >> confdefs.h <<\EOF
7609#define TTYCLK 1
7610EOF
7611 ;;
7612esac
7613
7614echo $ac_n "checking for the ppsclock streams module""... $ac_c" 1>&6
7615echo "configure:7616: checking for the ppsclock streams module" >&5
7616if eval "test \"`echo '$''{'ac_cv_var_ppsclock'+set}'`\" = set"; then
7617  echo $ac_n "(cached) $ac_c" 1>&6
7618else
7619  ac_cv_var_ppsclock=$ac_cv_struct_ppsclockev
7620fi
7621
7622echo "$ac_t""$ac_cv_var_ppsclock" 1>&6
7623case "$ac_cv_var_ppsclock" in
7624 yes) cat >> confdefs.h <<\EOF
7625#define PPS 1
7626EOF
7627 ;;
7628esac
7629
7630echo $ac_n "checking for kernel multicast support""... $ac_c" 1>&6
7631echo "configure:7632: checking for kernel multicast support" >&5
7632if eval "test \"`echo '$''{'ac_cv_var_mcast'+set}'`\" = set"; then
7633  echo $ac_n "(cached) $ac_c" 1>&6
7634else
7635  ac_cv_var_mcast=no
7636  case "$target" in
7637   i386-sequent-sysv4) ;;
7638   *) cat > conftest.$ac_ext <<EOF
7639#line 7640 "configure"
7640#include "confdefs.h"
7641#include <netinet/in.h>
7642#ifdef IP_ADD_MEMBERSHIP
7643   yes
7644#endif
7645  
7646EOF
7647if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7648  egrep "yes" >/dev/null 2>&1; then
7649  rm -rf conftest*
7650  ac_cv_var_mcast=yes
7651fi
7652rm -f conftest*
7653 ;;
7654  esac
7655fi
7656
7657echo "$ac_t""$ac_cv_var_mcast" 1>&6
7658case "$ac_cv_var_mcast" in
7659 yes) cat >> confdefs.h <<\EOF
7660#define MCAST 1
7661EOF
7662 ;;
7663esac
7664
7665echo $ac_n "checking availability of ntp_{adj,get}time()""... $ac_c" 1>&6
7666echo "configure:7667: checking availability of ntp_{adj,get}time()" >&5
7667if eval "test \"`echo '$''{'ac_cv_var_ntp_syscalls'+set}'`\" = set"; then
7668  echo $ac_n "(cached) $ac_c" 1>&6
7669else
7670  ac_cv_var_ntp_syscalls=no
7671 case "$ac_cv_func___adjtimex" in
7672  yes)
7673    ac_cv_var_ntp_syscalls=libc
7674    ;;
7675  *) case "$ac_cv_func_ntp_adjtime$ac_cv_func_ntp_gettime" in
7676      yesyes)
7677        ac_cv_var_ntp_syscalls=libc
7678        ;;
7679      *) cat > conftest.$ac_ext <<EOF
7680#line 7681 "configure"
7681#include "confdefs.h"
7682#include <sys/syscall.h>
7683#if defined(SYS_ntp_gettime) && defined(SYS_ntp_adjtime)
7684           yes
7685#endif
7686          
7687EOF
7688if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7689  egrep "yes" >/dev/null 2>&1; then
7690  rm -rf conftest*
7691  ac_cv_var_ntp_syscalls=kernel
7692fi
7693rm -f conftest*
7694
7695         ;;
7696     esac
7697     ;;
7698 esac
7699fi
7700
7701echo "$ac_t""$ac_cv_var_ntp_syscalls" 1>&6
7702case "$ac_cv_var_ntp_syscalls" in
7703 libc)
7704    cat >> confdefs.h <<\EOF
7705#define NTP_SYSCALLS_LIBC 1
7706EOF
7707
7708    ;;
7709 kernel)
7710    cat >> confdefs.h <<\EOF
7711#define NTP_SYSCALLS_STD 1
7712EOF
7713
7714    ;;
7715 *)
7716    ;;
7717esac
7718
7719echo $ac_n "checking if sys/timex.h has STA_FLL""... $ac_c" 1>&6
7720echo "configure:7721: checking if sys/timex.h has STA_FLL" >&5
7721if eval "test \"`echo '$''{'ac_cv_var_sta_fll'+set}'`\" = set"; then
7722  echo $ac_n "(cached) $ac_c" 1>&6
7723else
7724  cat > conftest.$ac_ext <<EOF
7725#line 7726 "configure"
7726#include "confdefs.h"
7727#include <sys/timex.h>
7728#ifdef STA_FLL
7729    yes
7730#endif
7731    
7732EOF
7733if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7734  egrep "yes" >/dev/null 2>&1; then
7735  rm -rf conftest*
7736  ac_cv_var_sta_fll=yes
7737else
7738  rm -rf conftest*
7739  ac_cv_var_sta_fll=no
7740fi
7741rm -f conftest*
7742
7743fi
7744
7745echo "$ac_t""$ac_cv_var_sta_fll" 1>&6
7746
7747echo $ac_n "checking if we have kernel PLL support""... $ac_c" 1>&6
7748echo "configure:7749: checking if we have kernel PLL support" >&5
7749if eval "test \"`echo '$''{'ac_cv_var_kernel_pll'+set}'`\" = set"; then
7750  echo $ac_n "(cached) $ac_c" 1>&6
7751else
7752  case "$ac_cv_header_sys_timex_h$ac_cv_struct_ntptimeval$ac_cv_var_sta_fll$ac_cv_var_ntp_syscalls" in
7753 *no*)
7754    ac_cv_var_kernel_pll=no
7755    ;;
7756 *) ac_cv_var_kernel_pll=yes
7757    ;;
7758esac
7759fi
7760
7761echo "$ac_t""$ac_cv_var_kernel_pll" 1>&6
7762case "$ac_cv_var_kernel_pll" in
7763 yes)
7764    cat >> confdefs.h <<\EOF
7765#define KERNEL_PLL 1
7766EOF
7767
7768    ;;
7769esac
7770
7771echo $ac_n "checking if SIOCGIFCONF returns buffer size in the buffer""... $ac_c" 1>&6
7772echo "configure:7773: checking if SIOCGIFCONF returns buffer size in the buffer" >&5
7773if eval "test \"`echo '$''{'ac_cv_var_size_returned_in_buffer'+set}'`\" = set"; then
7774  echo $ac_n "(cached) $ac_c" 1>&6
7775else
7776  ans=no
7777  case "$target" in
7778   *-fujitsu-uxp*)
7779      ans=yes
7780      ;;
7781   *-ncr-sysv4*)
7782      ans=yes
7783      ;;
7784   *-univel-sysv*)
7785      ans=yes
7786      ;;
7787  esac
7788  ac_cv_var_size_returned_in_buffer=$ans
7789fi
7790
7791echo "$ac_t""$ac_cv_var_size_returned_in_buffer" 1>&6
7792case "$ac_cv_var_size_returned_in_buffer" in
7793 yes) cat >> confdefs.h <<\EOF
7794#define SIZE_RETURNED_IN_BUFFER 1
7795EOF
7796 ;;
7797esac
7798
7799
7800echo $ac_n "checking if we want to use MD5 authentication""... $ac_c" 1>&6
7801echo "configure:7802: checking if we want to use MD5 authentication" >&5
7802if eval "test \"`echo '$''{'ac_cv_var_use_md5'+set}'`\" = set"; then
7803  echo $ac_n "(cached) $ac_c" 1>&6
7804else
7805  # Check whether --enable-md5 or --disable-md5 was given.
7806if test "${enable_md5+set}" = set; then
7807  enableval="$enable_md5"
7808  ans=$enableval
7809else
7810  ans=yes
7811fi
7812
7813ac_cv_var_use_md5=$ans
7814fi
7815
7816echo "$ac_t""$ac_cv_var_use_md5" 1>&6
7817case "$ac_cv_var_use_md5" in
7818 yes) cat >> confdefs.h <<\EOF
7819#define MD5 1
7820EOF
7821 ;;
7822esac
7823
7824# Check for ioctls TIOCGPPSEV
7825echo $ac_n "checking ioctl TIOCGPPSEV""... $ac_c" 1>&6
7826echo "configure:7827: checking ioctl TIOCGPPSEV" >&5
7827if test "$ac_cv_header_termios_h" = "yes"; then
7828    cat > conftest.$ac_ext <<EOF
7829#line 7830 "configure"
7830#include "confdefs.h"
7831#include <termios.h>
7832#ifdef TIOCGPPSEV
7833         yes
7834#endif
7835	 
7836EOF
7837if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7838  egrep "yes" >/dev/null 2>&1; then
7839  rm -rf conftest*
7840  ntp_ok=yes
7841else
7842  rm -rf conftest*
7843  ntp_ok=no
7844fi
7845rm -f conftest*
7846
7847else
7848ntp_ok=no
7849fi
7850if test "$ntp_ok" = "yes"; then
7851    cat >> confdefs.h <<\EOF
7852#define HAVE_TIOCGPPSEV 1
7853EOF
7854
7855    ac_cv_var_oncore_ok=yes
7856fi
7857echo "$ac_t""$ntp_ok" 1>&6
7858
7859# Check for ioctls TIOCSPPS
7860echo $ac_n "checking ioctl TIOCSPPS""... $ac_c" 1>&6
7861echo "configure:7862: checking ioctl TIOCSPPS" >&5
7862if test "$ac_cv_header_termios_h" = "yes"; then
7863    cat > conftest.$ac_ext <<EOF
7864#line 7865 "configure"
7865#include "confdefs.h"
7866#include <termios.h>
7867#ifdef TIOCSPPS
7868         yes
7869#endif
7870	 
7871EOF
7872if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7873  egrep "yes" >/dev/null 2>&1; then
7874  rm -rf conftest*
7875  ntp_ok=yes
7876else
7877  rm -rf conftest*
7878  ntp_ok=no
7879fi
7880rm -f conftest*
7881
7882else
7883    ntp_ok=no
7884fi
7885
7886if test "$ntp_ok" = "yes"; then
7887    cat >> confdefs.h <<\EOF
7888#define HAVE_TIOCSPPS 1
7889EOF
7890
7891fi
7892echo "$ac_t""$ntp_ok" 1>&6
7893
7894# Check for ioctls CIOGETEV
7895echo $ac_n "checking ioctl CIOGETEV""... $ac_c" 1>&6
7896echo "configure:7897: checking ioctl CIOGETEV" >&5
7897if test "$ac_cv_header_sys_ppsclock_h" = "yes"; then
7898    cat > conftest.$ac_ext <<EOF
7899#line 7900 "configure"
7900#include "confdefs.h"
7901#include <sys/ppsclock.h>
7902#ifdef CIOGETEV
7903         yes
7904#endif
7905	 
7906EOF
7907if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
7908  egrep "yes" >/dev/null 2>&1; then
7909  rm -rf conftest*
7910  ntp_ok=yes
7911else
7912  rm -rf conftest*
7913  ntp_ok=no
7914fi
7915rm -f conftest*
7916
7917else
7918ntp_ok=no
7919fi
7920if test "$ntp_ok" = "yes"; then
7921    ac_cv_var_oncore_ok=yes
7922    cat >> confdefs.h <<\EOF
7923#define HAVE_CIOGETEV 1
7924EOF
7925
7926fi
7927echo "$ac_t""$ntp_ok" 1>&6
7928
7929# Check for header timepps.h, if found then we have PPS API (Draft RFC) stuff.
7930# there is NO way that I can tell to tell if a given OS is using timespec or
7931# timeval so just set it here for the one case that is KNOWN to use timespec.
7932
7933case "$ac_cv_header_timepps_h$ac_cv_header_sys_timepps_h" in
7934 *yes*)
7935    cat >> confdefs.h <<\EOF
7936#define HAVE_PPSAPI 1
7937EOF
7938
7939    ac_cv_var_oncore_ok=yes
7940    cat >> confdefs.h <<\EOF
7941#define HAVE_TIMESPEC 1
7942EOF
7943
7944    ;;
7945esac
7946
7947# Check for ioctls TIOCGSERIAL, TIOCSSERIAL, ASYNC_PPS_CD_POS, ASYNC_PPS_CD_NEG
7948ac_safe=`echo "linux/serial.h" | sed 'y%./+-%__p_%'`
7949echo $ac_n "checking for linux/serial.h""... $ac_c" 1>&6
7950echo "configure:7951: checking for linux/serial.h" >&5
7951if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
7952  echo $ac_n "(cached) $ac_c" 1>&6
7953else
7954  cat > conftest.$ac_ext <<EOF
7955#line 7956 "configure"
7956#include "confdefs.h"
7957#include <linux/serial.h>
7958EOF
7959ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
7960{ (eval echo configure:7961: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
7961ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
7962if test -z "$ac_err"; then
7963  rm -rf conftest*
7964  eval "ac_cv_header_$ac_safe=yes"
7965else
7966  echo "$ac_err" >&5
7967  echo "configure: failed program was:" >&5
7968  cat conftest.$ac_ext >&5
7969  rm -rf conftest*
7970  eval "ac_cv_header_$ac_safe=no"
7971fi
7972rm -f conftest*
7973fi
7974if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
7975  echo "$ac_t""yes" 1>&6
7976  :
7977else
7978  echo "$ac_t""no" 1>&6
7979fi
7980
7981echo $ac_n "checking ioctl TIOCGSERIAL""... $ac_c" 1>&6
7982echo "configure:7983: checking ioctl TIOCGSERIAL" >&5
7983case "$ac_cv_header_sys_ppsclock_h$ac_cv_header_linux_serial_h" in
7984  yesyes)
7985    cat > conftest.$ac_ext <<EOF
7986#line 7987 "configure"
7987#include "confdefs.h"
7988#include <sys/time.h>
7989typedef int u_int;
7990
7991#include <sys/ppsclock.h>
7992#include <linux/serial.h>
7993
7994#ifdef TIOCGSERIAL
7995#ifdef TIOCSSERIAL
7996#ifdef ASYNC_PPS_CD_POS
7997#ifdef ASYNC_PPS_CD_NEG
7998#ifdef CIOGETEV
7999         yes
8000#endif
8001#endif
8002#endif
8003#endif
8004#endif
8005	 
8006EOF
8007if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8008  egrep "yes" >/dev/null 2>&1; then
8009  rm -rf conftest*
8010  ntp_ok=yes
8011fi
8012rm -f conftest*
8013
8014	;;
8015  *)
8016	ntp_ok=no
8017	;;
8018esac
8019if test "$ntp_ok" = "yes"; then
8020    cat >> confdefs.h <<\EOF
8021#define HAVE_TIO_SERIAL_STUFF 1
8022EOF
8023
8024fi
8025echo "$ac_t""$ntp_ok" 1>&6
8026
8027# Check for SHMEM_STATUS support
8028echo $ac_n "checking SHMEM_STATUS support""... $ac_c" 1>&6
8029echo "configure:8030: checking SHMEM_STATUS support" >&5
8030case "$ac_cv_header_sys_mman_h" in
8031 yes) ntp_ok=yes ;;
8032 *)   ntp_ok=no  ;;
8033esac
8034if test "$ntp_ok" = "yes"; then
8035    cat >> confdefs.h <<\EOF
8036#define ONCORE_SHMEM_STATUS 1
8037EOF
8038
8039fi
8040echo "$ac_t""$ntp_ok" 1>&6
8041
8042
8043ntp_refclock=no
8044
8045# HPUX only, and by explicit request
8046echo $ac_n "checking Datum/Bancomm bc635/VME interface""... $ac_c" 1>&6
8047echo "configure:8048: checking Datum/Bancomm bc635/VME interface" >&5
8048# Check whether --enable-BANCOMM or --disable-BANCOMM was given.
8049if test "${enable_BANCOMM+set}" = set; then
8050  enableval="$enable_BANCOMM"
8051  ntp_ok=$enableval
8052else
8053  ntp_ok=no
8054fi
8055
8056if test "$ntp_ok" = "yes"; then
8057    ntp_refclock=yes
8058    cat >> confdefs.h <<\EOF
8059#define CLOCK_BANC 1
8060EOF
8061
8062fi
8063echo "$ac_t""$ntp_ok" 1>&6
8064case "$ntp_ok$target" in
8065 yes*-*-hpux*) ;;
8066 yes*) echo "configure: warning: *** But the expected answer is... no ***" 1>&2 ;;
8067esac
8068
8069#HPUX only, and only by explicit request
8070echo $ac_n "checking TrueTime GPS receiver/VME interface""... $ac_c" 1>&6
8071echo "configure:8072: checking TrueTime GPS receiver/VME interface" >&5
8072# Check whether --enable-GPSVME or --disable-GPSVME was given.
8073if test "${enable_GPSVME+set}" = set; then
8074  enableval="$enable_GPSVME"
8075  ntp_ok=$enableval
8076else
8077  ntp_ok=no
8078fi
8079
8080if test "$ntp_ok" = "yes"; then
8081    ntp_refclock=yes
8082    cat >> confdefs.h <<\EOF
8083#define CLOCK_GPSVME 1
8084EOF
8085
8086fi
8087echo "$ac_t""$ntp_ok" 1>&6
8088case "$ntp_ok$target" in
8089 yes*-*-hpux*) ;;
8090 yes*) echo "configure: warning: *** But the expected answer is... no ***" 1>&2 ;;
8091esac
8092
8093echo $ac_n "checking for PCL720 clock support""... $ac_c" 1>&6
8094echo "configure:8095: checking for PCL720 clock support" >&5
8095case "$ac_cv_header_machine_inline_h$ac_cv_header_sys_pcl720_h$ac_cv_header_sys_i8253_h" in
8096 yesyesyes)
8097    cat >> confdefs.h <<\EOF
8098#define CLOCK_PPS720 1
8099EOF
8100
8101    ans=yes
8102    ;;
8103 *)
8104    ans=no
8105    ;;
8106esac
8107echo "$ac_t""$ans" 1>&6
8108
8109echo $ac_n "checking for SHM clock attached thru shared memory""... $ac_c" 1>&6
8110echo "configure:8111: checking for SHM clock attached thru shared memory" >&5
8111# Check whether --enable-SHM or --disable-SHM was given.
8112if test "${enable_SHM+set}" = set; then
8113  enableval="$enable_SHM"
8114  ntp_ok=$enableval
8115else
8116  ntp_ok=no
8117fi
8118
8119if test "$ntp_ok" = "yes"; then
8120    ntp_refclock=yes
8121    cat >> confdefs.h <<\EOF
8122#define CLOCK_SHM 1
8123EOF
8124
8125fi
8126echo "$ac_t""$ntp_ok" 1>&6
8127
8128echo $ac_n "checking for default inclusion of all suitable non-PARSE clocks""... $ac_c" 1>&6
8129echo "configure:8130: checking for default inclusion of all suitable non-PARSE clocks" >&5
8130# Check whether --enable-all-clocks or --disable-all-clocks was given.
8131if test "${enable_all_clocks+set}" = set; then
8132  enableval="$enable_all_clocks"
8133  ntp_eac=$enableval
8134else
8135  ntp_eac=yes
8136fi
8137
8138echo "$ac_t""$ntp_eac" 1>&6
8139
8140echo $ac_n "checking if we have support for PARSE clocks""... $ac_c" 1>&6
8141echo "configure:8142: checking if we have support for PARSE clocks" >&5
8142case "$ac_cv_header_termio_h$ac_cv_header_termios_h" in
8143 *yes*)
8144    ntp_canparse=yes
8145    ;;
8146 *) ntp_canparse=no
8147    ;;
8148esac
8149echo "$ac_t""$ntp_canparse" 1>&6
8150
8151echo $ac_n "checking if we have support for audio clocks""... $ac_c" 1>&6
8152echo "configure:8153: checking if we have support for audio clocks" >&5
8153case "$ac_cv_header_sun_audioio_h$ac_cv_header_sys_audioio_h" in
8154 *yes*)	ntp_canaudio=yes ;;
8155 *)	ntp_canaudio=no  ;;
8156esac
8157echo "$ac_t""$ntp_canaudio" 1>&6
8158
8159# Requires modem control
8160echo $ac_n "checking ACTS modem service""... $ac_c" 1>&6
8161echo "configure:8162: checking ACTS modem service" >&5
8162# Check whether --enable-ACTS or --disable-ACTS was given.
8163if test "${enable_ACTS+set}" = set; then
8164  enableval="$enable_ACTS"
8165  ntp_ok=$enableval
8166else
8167  cat > conftest.$ac_ext <<EOF
8168#line 8169 "configure"
8169#include "confdefs.h"
8170#include <termios.h>
8171#ifdef HAVE_SYS_IOCTL_H
8172#include <sys/ioctl.h>
8173#endif
8174#ifdef TIOCMBIS
8175         yes
8176#endif
8177         
8178EOF
8179if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8180  egrep "yes" >/dev/null 2>&1; then
8181  rm -rf conftest*
8182  ntp_ok=$ntp_eac
8183else
8184  rm -rf conftest*
8185  ntp_ok=no
8186fi
8187rm -f conftest*
8188
8189fi
8190
8191if test "$ntp_ok" = "yes"; then
8192    ntp_refclock=yes
8193    cat >> confdefs.h <<\EOF
8194#define CLOCK_ACTS 1
8195EOF
8196
8197fi
8198echo "$ac_t""$ntp_ok" 1>&6
8199
8200echo $ac_n "checking Arbiter 1088A/B GPS receiver""... $ac_c" 1>&6
8201echo "configure:8202: checking Arbiter 1088A/B GPS receiver" >&5
8202# Check whether --enable-ARBITER or --disable-ARBITER was given.
8203if test "${enable_ARBITER+set}" = set; then
8204  enableval="$enable_ARBITER"
8205  ntp_ok=$enableval
8206else
8207  ntp_ok=$ntp_eac
8208fi
8209
8210if test "$ntp_ok" = "yes"; then
8211    ntp_refclock=yes
8212    cat >> confdefs.h <<\EOF
8213#define CLOCK_ARBITER 1
8214EOF
8215
8216fi
8217echo "$ac_t""$ntp_ok" 1>&6
8218
8219echo $ac_n "checking Arcron MSF receiver""... $ac_c" 1>&6
8220echo "configure:8221: checking Arcron MSF receiver" >&5
8221# Check whether --enable-ARCRON_MSF or --disable-ARCRON_MSF was given.
8222if test "${enable_ARCRON_MSF+set}" = set; then
8223  enableval="$enable_ARCRON_MSF"
8224  ntp_ok=$enableval
8225else
8226  ntp_ok=$ntp_eac
8227fi
8228
8229if test "$ntp_ok" = "yes"; then
8230    ntp_refclock=yes
8231    cat >> confdefs.h <<\EOF
8232#define CLOCK_ARCRON_MSF 1
8233EOF
8234
8235fi
8236echo "$ac_t""$ntp_ok" 1>&6
8237
8238echo $ac_n "checking Austron 2200A/2201A GPS receiver""... $ac_c" 1>&6
8239echo "configure:8240: checking Austron 2200A/2201A GPS receiver" >&5
8240# Check whether --enable-AS2201 or --disable-AS2201 was given.
8241if test "${enable_AS2201+set}" = set; then
8242  enableval="$enable_AS2201"
8243  ntp_ok=$enableval
8244else
8245  ntp_ok=$ntp_eac
8246fi
8247
8248if test "$ntp_ok" = "yes"; then
8249    ntp_refclock=yes
8250    cat >> confdefs.h <<\EOF
8251#define CLOCK_AS2201 1
8252EOF
8253
8254fi
8255echo "$ac_t""$ntp_ok" 1>&6
8256
8257echo $ac_n "checking PPS interface""... $ac_c" 1>&6
8258echo "configure:8259: checking PPS interface" >&5
8259# Check whether --enable-ATOM or --disable-ATOM was given.
8260if test "${enable_ATOM+set}" = set; then
8261  enableval="$enable_ATOM"
8262  ntp_ok=$enableval
8263else
8264  ntp_ok=$ntp_eac
8265fi
8266
8267if test "$ntp_ok" = "yes"; then
8268    ntp_refclock=yes
8269    cat >> confdefs.h <<\EOF
8270#define CLOCK_ATOM 1
8271EOF
8272
8273fi
8274echo "$ac_t""$ntp_ok" 1>&6
8275
8276echo $ac_n "checking CHU modem/decoder""... $ac_c" 1>&6
8277echo "configure:8278: checking CHU modem/decoder" >&5
8278# Check whether --enable-CHU or --disable-CHU was given.
8279if test "${enable_CHU+set}" = set; then
8280  enableval="$enable_CHU"
8281  ntp_ok=$enableval
8282else
8283  ntp_ok=$ntp_eac
8284fi
8285
8286if test "$ntp_ok" = "yes"; then
8287    ntp_refclock=yes
8288    cat >> confdefs.h <<\EOF
8289#define CLOCK_CHU 1
8290EOF
8291
8292fi
8293echo "$ac_t""$ntp_ok" 1>&6
8294ac_refclock_chu=$ntp_ok
8295
8296echo $ac_n "checking CHU audio/decoder""... $ac_c" 1>&6
8297echo "configure:8298: checking CHU audio/decoder" >&5
8298# Check whether --enable-AUDIO-CHU or --disable-AUDIO-CHU was given.
8299if test "${enable_AUDIO_CHU+set}" = set; then
8300  enableval="$enable_AUDIO_CHU"
8301  ntp_ok=$enableval
8302else
8303  case "$ntp_eac$ac_refclock_chu$ntp_canaudio" in
8304 *no*)	ntp_ok=no  ;;
8305 *)	ntp_ok=yes ;;
8306esac
8307fi
8308
8309if test "$ntp_ok" = "yes"; then
8310    cat >> confdefs.h <<\EOF
8311#define AUDIO_CHU 1
8312EOF
8313
8314fi
8315echo "$ac_t""$ntp_ok" 1>&6
8316# We used to check for sunos/solaris target...
8317case "$ntp_ok$ac_refclock_chu$ntp_canaudio" in
8318 yes*no*) echo "configure: warning: *** But the expected answer is...no ***" 1>&2 ;;
8319esac
8320
8321# Not under HP-UX
8322echo $ac_n "checking Datum Programmable Time System""... $ac_c" 1>&6
8323echo "configure:8324: checking Datum Programmable Time System" >&5
8324# Check whether --enable-DATUM or --disable-DATUM was given.
8325if test "${enable_DATUM+set}" = set; then
8326  enableval="$enable_DATUM"
8327  ntp_ok=$enableval
8328else
8329  case "$ac_cv_header_termios_h" in
8330    yes)
8331        ntp_ok=$ntp_eac
8332        ;;
8333    *) ntp_ok=no
8334        ;;
8335    esac
8336fi
8337
8338if test "$ntp_ok" = "yes"; then
8339    ntp_refclock=yes
8340    cat >> confdefs.h <<\EOF
8341#define CLOCK_DATUM 1
8342EOF
8343
8344fi
8345echo "$ac_t""$ntp_ok" 1>&6
8346
8347echo $ac_n "checking Forum Graphic GPS""... $ac_c" 1>&6
8348echo "configure:8349: checking Forum Graphic GPS" >&5
8349# Check whether --enable-FG or --disable-FG was given.
8350if test "${enable_FG+set}" = set; then
8351  enableval="$enable_FG"
8352  ntp_ok=$enableval
8353else
8354  ntp_ok=$ntp_eac
8355fi
8356
8357if test "$ntp_ok" = "yes"; then
8358    ntp_refclock=yes
8359    cat >> confdefs.h <<\EOF
8360#define CLOCK_FG 1
8361EOF
8362
8363fi
8364echo "$ac_t""$ntp_ok" 1>&6
8365
8366# Requires modem control
8367echo $ac_n "checking Heath GC-1000 WWV/WWVH receiver""... $ac_c" 1>&6
8368echo "configure:8369: checking Heath GC-1000 WWV/WWVH receiver" >&5
8369# Check whether --enable-HEATH or --disable-HEATH was given.
8370if test "${enable_HEATH+set}" = set; then
8371  enableval="$enable_HEATH"
8372  ntp_ok=$enableval
8373else
8374  cat > conftest.$ac_ext <<EOF
8375#line 8376 "configure"
8376#include "confdefs.h"
8377#include <termios.h>
8378#ifdef HAVE_SYS_IOCTL_H
8379#include <sys/ioctl.h>
8380#endif
8381#ifdef TIOCMBIS
8382         yes
8383#endif
8384         
8385EOF
8386if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8387  egrep "yes" >/dev/null 2>&1; then
8388  rm -rf conftest*
8389  ntp_ok=$ntp_eac
8390else
8391  rm -rf conftest*
8392  ntp_ok=no
8393fi
8394rm -f conftest*
8395
8396fi
8397
8398if test "$ntp_ok" = "yes"; then
8399    ntp_refclock=yes
8400    cat >> confdefs.h <<\EOF
8401#define CLOCK_HEATH 1
8402EOF
8403
8404fi
8405echo "$ac_t""$ntp_ok" 1>&6
8406
8407echo $ac_n "checking HP 58503A GPS receiver""... $ac_c" 1>&6
8408echo "configure:8409: checking HP 58503A GPS receiver" >&5
8409# Check whether --enable-HPGPS or --disable-HPGPS was given.
8410if test "${enable_HPGPS+set}" = set; then
8411  enableval="$enable_HPGPS"
8412  ntp_ok=$enableval
8413else
8414  ntp_ok=$ntp_eac
8415fi
8416
8417if test "$ntp_ok" = "yes"; then
8418    ntp_refclock=yes
8419    cat >> confdefs.h <<\EOF
8420#define CLOCK_HPGPS 1
8421EOF
8422
8423fi
8424echo "$ac_t""$ntp_ok" 1>&6
8425
8426echo $ac_n "checking Sun IRIG audio decoder""... $ac_c" 1>&6
8427echo "configure:8428: checking Sun IRIG audio decoder" >&5
8428# Check whether --enable-IRIG or --disable-IRIG was given.
8429if test "${enable_IRIG+set}" = set; then
8430  enableval="$enable_IRIG"
8431  ntp_ok=$enableval
8432else
8433  case "$ntp_eac$ntp_canaudio" in
8434     *no*)	ntp_ok=no  ;;
8435     *)		ntp_ok=yes ;;
8436    esac
8437fi
8438
8439if test "$ntp_ok" = "yes"; then
8440    ntp_refclock=yes
8441    cat >> confdefs.h <<\EOF
8442#define CLOCK_IRIG 1
8443EOF
8444
8445fi
8446echo "$ac_t""$ntp_ok" 1>&6
8447case "$ntp_ok$ntp_canaudio" in
8448 yesno) echo "configure: warning: *** But the expected answer is... no ***" 1>&2 ;;
8449esac
8450
8451echo $ac_n "checking Leitch CSD 5300 Master Clock System Driver""... $ac_c" 1>&6
8452echo "configure:8453: checking Leitch CSD 5300 Master Clock System Driver" >&5
8453# Check whether --enable-LEITCH or --disable-LEITCH was given.
8454if test "${enable_LEITCH+set}" = set; then
8455  enableval="$enable_LEITCH"
8456  ntp_ok=$enableval
8457else
8458  ntp_ok=$ntp_eac
8459fi
8460
8461if test "$ntp_ok" = "yes"; then
8462    ntp_refclock=yes
8463    cat >> confdefs.h <<\EOF
8464#define CLOCK_LEITCH 1
8465EOF
8466
8467fi
8468echo "$ac_t""$ntp_ok" 1>&6
8469
8470echo $ac_n "checking local clock reference""... $ac_c" 1>&6
8471echo "configure:8472: checking local clock reference" >&5
8472# Check whether --enable-LOCAL-CLOCK or --disable-LOCAL-CLOCK was given.
8473if test "${enable_LOCAL_CLOCK+set}" = set; then
8474  enableval="$enable_LOCAL_CLOCK"
8475  ntp_ok=$enableval
8476else
8477  ntp_ok=$ntp_eac
8478fi
8479
8480if test "$ntp_ok" = "yes"; then
8481    ntp_refclock=yes
8482    cat >> confdefs.h <<\EOF
8483#define CLOCK_LOCAL 1
8484EOF
8485
8486fi
8487echo "$ac_t""$ntp_ok" 1>&6
8488
8489echo $ac_n "checking EES M201 MSF receiver""... $ac_c" 1>&6
8490echo "configure:8491: checking EES M201 MSF receiver" >&5
8491# Check whether --enable-MSFEES or --disable-MSFEES was given.
8492if test "${enable_MSFEES+set}" = set; then
8493  enableval="$enable_MSFEES"
8494  ntp_ok=$enableval
8495else
8496  ntp_ok=$ntp_eac
8497fi
8498
8499if test "$ntp_ok" = "yes"; then
8500    ntp_refclock=yes
8501    cat >> confdefs.h <<\EOF
8502#define CLOCK_MSFEES 1
8503EOF
8504
8505fi
8506echo "$ac_t""$ntp_ok" 1>&6
8507
8508# Not Ultrix
8509echo $ac_n "checking Magnavox MX4200 GPS receiver""... $ac_c" 1>&6
8510echo "configure:8511: checking Magnavox MX4200 GPS receiver" >&5
8511# Check whether --enable-MX4200 or --disable-MX4200 was given.
8512if test "${enable_MX4200+set}" = set; then
8513  enableval="$enable_MX4200"
8514  ntp_ok=$enableval
8515else
8516  case "$ac_cv_var_ppsclock" in
8517     yes) ntp_ok=$ntp_eac
8518        ;;
8519     *) ntp_ok=no
8520        ;;
8521    esac
8522fi
8523
8524if test "$ntp_ok" = "yes"; then
8525    ntp_refclock=yes
8526    cat >> confdefs.h <<\EOF
8527#define CLOCK_MX4200 1
8528EOF
8529
8530fi
8531echo "$ac_t""$ntp_ok" 1>&6
8532case "$ntp_ok$target" in
8533 yes*-*-ultrix*) echo "configure: warning: *** But the expected answer is... no ***" 1>&2 ;;
8534esac
8535
8536echo $ac_n "checking NMEA GPS receiver""... $ac_c" 1>&6
8537echo "configure:8538: checking NMEA GPS receiver" >&5
8538# Check whether --enable-NMEA or --disable-NMEA was given.
8539if test "${enable_NMEA+set}" = set; then
8540  enableval="$enable_NMEA"
8541  ntp_ok=$enableval
8542else
8543  ntp_ok=$ntp_eac
8544fi
8545
8546if test "$ntp_ok" = "yes"; then
8547    ntp_refclock=yes
8548    cat >> confdefs.h <<\EOF
8549#define CLOCK_NMEA 1
8550EOF
8551
8552fi
8553echo "$ac_t""$ntp_ok" 1>&6
8554
8555echo $ac_n "checking for ONCORE Motorola VP/UT Oncore GPS""... $ac_c" 1>&6
8556echo "configure:8557: checking for ONCORE Motorola VP/UT Oncore GPS" >&5
8557# Check whether --enable-ONCORE or --disable-ONCORE was given.
8558if test "${enable_ONCORE+set}" = set; then
8559  enableval="$enable_ONCORE"
8560  ntp_ok=$enableval
8561else
8562  ntp_ok=$ntp_eac
8563fi
8564
8565case "$ac_cv_var_oncore_ok" in
8566 no) ntp_ok=no ;;
8567esac
8568if test "$ntp_ok" = "yes"; then
8569    ntp_refclock=yes
8570    cat >> confdefs.h <<\EOF
8571#define CLOCK_ONCORE 1
8572EOF
8573
8574fi
8575echo "$ac_t""$ntp_ok" 1>&6
8576
8577echo $ac_n "checking for Palisade clock""... $ac_c" 1>&6
8578echo "configure:8579: checking for Palisade clock" >&5
8579# Check whether --enable-PALISADE or --disable-PALISADE was given.
8580if test "${enable_PALISADE+set}" = set; then
8581  enableval="$enable_PALISADE"
8582  ntp_ok=$enableval
8583else
8584  case "$ac_cv_header_termios_h" in
8585    yes)
8586        ntp_ok=$ntp_eac
8587        ;;
8588    *) ntp_ok=no
8589        ;;
8590    esac
8591fi
8592
8593
8594if test "$ntp_ok" = "yes"; then
8595    ntp_refclock=yes
8596    cat >> confdefs.h <<\EOF
8597#define CLOCK_PALISADE 1
8598EOF
8599
8600fi
8601echo "$ac_t""$ntp_ok" 1>&6
8602
8603echo $ac_n "checking PST/Traconex 1020 WWV/WWVH receiver""... $ac_c" 1>&6
8604echo "configure:8605: checking PST/Traconex 1020 WWV/WWVH receiver" >&5
8605# Check whether --enable-PST or --disable-PST was given.
8606if test "${enable_PST+set}" = set; then
8607  enableval="$enable_PST"
8608  ntp_ok=$enableval
8609else
8610  ntp_ok=$ntp_eac
8611fi
8612
8613if test "$ntp_ok" = "yes"; then
8614    ntp_refclock=yes
8615    cat >> confdefs.h <<\EOF
8616#define CLOCK_PST 1
8617EOF
8618
8619fi
8620echo "$ac_t""$ntp_ok" 1>&6
8621
8622# Not Ultrix
8623echo $ac_n "checking Rockwell Jupiter GPS receiver""... $ac_c" 1>&6
8624echo "configure:8625: checking Rockwell Jupiter GPS receiver" >&5
8625# Check whether --enable-JUPITER or --disable-JUPITER was given.
8626if test "${enable_JUPITER+set}" = set; then
8627  enableval="$enable_JUPITER"
8628  ntp_ok=$enableval
8629else
8630  case "$ac_cv_var_ppsclock" in
8631#     yes) ntp_ok=$ntp_eac
8632#        ;;
8633     *) ntp_ok=no
8634        ;;
8635    esac
8636fi
8637
8638if test "$ntp_ok" = "yes"; then
8639    ntp_refclock=yes
8640    cat >> confdefs.h <<\EOF
8641#define CLOCK_JUPITER 1
8642EOF
8643
8644fi
8645echo "$ac_t""$ntp_ok" 1>&6
8646case "$ntp_ok$target" in
8647 yes*-*-ultrix*) echo "configure: warning: *** But the expected answer is... no ***" 1>&2 ;;
8648esac
8649
8650# Requires modem control
8651echo $ac_n "checking PTB modem service""... $ac_c" 1>&6
8652echo "configure:8653: checking PTB modem service" >&5
8653# Check whether --enable-PTBACTS or --disable-PTBACTS was given.
8654if test "${enable_PTBACTS+set}" = set; then
8655  enableval="$enable_PTBACTS"
8656  ntp_ok=$enableval
8657else
8658  cat > conftest.$ac_ext <<EOF
8659#line 8660 "configure"
8660#include "confdefs.h"
8661#include <termios.h>
8662#ifdef HAVE_SYS_IOCTL_H
8663#include <sys/ioctl.h>
8664#endif
8665#ifdef TIOCMBIS
8666         yes
8667#endif
8668         
8669EOF
8670if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8671  egrep "yes" >/dev/null 2>&1; then
8672  rm -rf conftest*
8673  ntp_ok=$ntp_eac
8674else
8675  rm -rf conftest*
8676  ntp_ok=no
8677fi
8678rm -f conftest*
8679
8680fi
8681
8682if test "$ntp_ok" = "yes"; then
8683    ntp_refclock=yes
8684    cat >> confdefs.h <<\EOF
8685#define CLOCK_PTBACTS 1
8686EOF
8687
8688fi
8689echo "$ac_t""$ntp_ok" 1>&6
8690
8691echo $ac_n "checking KSI/Odetics TPRO/S GPS receiver/IRIG interface""... $ac_c" 1>&6
8692echo "configure:8693: checking KSI/Odetics TPRO/S GPS receiver/IRIG interface" >&5
8693# Check whether --enable-TPRO or --disable-TPRO was given.
8694if test "${enable_TPRO+set}" = set; then
8695  enableval="$enable_TPRO"
8696  ntp_ok=$enableval
8697else
8698  case "$ac_cv_header_sys_tpro_h" in
8699     yes)
8700	ntp_ok=$ntp_eac
8701	;;
8702     *)	ntp_ok=no
8703	;;
8704    esac
8705fi
8706
8707if test "$ntp_ok" = "yes"; then
8708    ntp_refclock=yes
8709    cat >> confdefs.h <<\EOF
8710#define CLOCK_TPRO 1
8711EOF
8712
8713fi
8714echo "$ac_t""$ntp_ok" 1>&6
8715case "$ntp_ok$ac_cv_header_sys_tpro" in
8716 yesno) echo "configure: warning: *** But the expected answer is... no ***" 1>&2 ;;
8717esac
8718
8719echo $ac_n "checking TRAK 8810 GPS receiver""... $ac_c" 1>&6
8720echo "configure:8721: checking TRAK 8810 GPS receiver" >&5
8721# Check whether --enable-TRAK or --disable-TRAK was given.
8722if test "${enable_TRAK+set}" = set; then
8723  enableval="$enable_TRAK"
8724  ntp_ok=$enableval
8725else
8726  ntp_ok=$ntp_eac
8727fi
8728
8729if test "$ntp_ok" = "yes"; then
8730    ntp_refclock=yes
8731    cat >> confdefs.h <<\EOF
8732#define CLOCK_TRAK 1
8733EOF
8734
8735fi
8736echo "$ac_t""$ntp_ok" 1>&6
8737
8738echo $ac_n "checking Chrono-log K-series WWVB receiver""... $ac_c" 1>&6
8739echo "configure:8740: checking Chrono-log K-series WWVB receiver" >&5
8740# Check whether --enable-CHRONOLOG or --disable-CHRONOLOG was given.
8741if test "${enable_CHRONOLOG+set}" = set; then
8742  enableval="$enable_CHRONOLOG"
8743  ntp_ok=$enableval
8744else
8745  ntp_ok=$ntp_eac
8746fi
8747
8748if test "$ntp_ok" = "yes"; then
8749    ntp_refclock=yes
8750    cat >> confdefs.h <<\EOF
8751#define CLOCK_CHRONOLOG 1
8752EOF
8753
8754fi
8755echo "$ac_t""$ntp_ok" 1>&6
8756
8757echo $ac_n "checking Dumb generic hh:mm:ss local clock""... $ac_c" 1>&6
8758echo "configure:8759: checking Dumb generic hh:mm:ss local clock" >&5
8759# Check whether --enable-DUMBCLOCK or --disable-DUMBCLOCK was given.
8760if test "${enable_DUMBCLOCK+set}" = set; then
8761  enableval="$enable_DUMBCLOCK"
8762  ntp_ok=$enableval
8763else
8764  ntp_ok=$ntp_eac
8765fi
8766
8767if test "$ntp_ok" = "yes"; then
8768    ntp_refclock=yes
8769    cat >> confdefs.h <<\EOF
8770#define CLOCK_DUMBCLOCK 1
8771EOF
8772
8773fi
8774echo "$ac_t""$ntp_ok" 1>&6
8775
8776echo $ac_n "checking Conrad parallel port radio clock""... $ac_c" 1>&6
8777echo "configure:8778: checking Conrad parallel port radio clock" >&5
8778# Check whether --enable-PCF or --disable-PCF was given.
8779if test "${enable_PCF+set}" = set; then
8780  enableval="$enable_PCF"
8781  ntp_ok=$enableval
8782else
8783  ntp_ok=$ntp_eac
8784fi
8785
8786if test "$ntp_ok" = "yes"; then
8787    ntp_refclock=yes
8788    cat >> confdefs.h <<\EOF
8789#define CLOCK_PCF 1
8790EOF
8791
8792fi
8793echo "$ac_t""$ntp_ok" 1>&6
8794
8795echo $ac_n "checking Spectracom 8170/Netclock/2 WWVB receiver""... $ac_c" 1>&6
8796echo "configure:8797: checking Spectracom 8170/Netclock/2 WWVB receiver" >&5
8797# Check whether --enable-SPECTRACOM or --disable-SPECTRACOM was given.
8798if test "${enable_SPECTRACOM+set}" = set; then
8799  enableval="$enable_SPECTRACOM"
8800  ntp_ok=$enableval
8801else
8802  ntp_ok=$ntp_eac
8803fi
8804
8805if test "$ntp_ok" = "yes"; then
8806    ntp_refclock=yes
8807    cat >> confdefs.h <<\EOF
8808#define CLOCK_SPECTRACOM 1
8809EOF
8810
8811fi
8812echo "$ac_t""$ntp_ok" 1>&6
8813
8814# Not on a vax-dec-bsd
8815echo $ac_n "checking Kinemetrics/TrueTime receivers""... $ac_c" 1>&6
8816echo "configure:8817: checking Kinemetrics/TrueTime receivers" >&5
8817# Check whether --enable-TRUETIME or --disable-TRUETIME was given.
8818if test "${enable_TRUETIME+set}" = set; then
8819  enableval="$enable_TRUETIME"
8820  ntp_ok=$enableval
8821else
8822  case "$target" in
8823     vax-dec-bsd)
8824	ntp_ok=no
8825	;;
8826     *)
8827	ntp_ok=$ntp_eac
8828	;;
8829    esac
8830fi
8831
8832if test "$ntp_ok" = "yes"; then
8833    ntp_refclock=yes
8834    cat >> confdefs.h <<\EOF
8835#define CLOCK_TRUETIME 1
8836EOF
8837
8838fi
8839echo "$ac_t""$ntp_ok" 1>&6
8840case "$ntp_ok$target" in
8841 yesvax-dec-bsd) echo "configure: warning: *** But the expected answer is... no ***" 1>&2 ;;
8842esac
8843
8844echo $ac_n "checking Ultralink M320 WWVB receiver""... $ac_c" 1>&6
8845echo "configure:8846: checking Ultralink M320 WWVB receiver" >&5
8846# Check whether --enable-ULINK or --disable-ULINK was given.
8847if test "${enable_ULINK+set}" = set; then
8848  enableval="$enable_ULINK"
8849  ntp_ok=$enableval
8850else
8851  ntp_ok=$ntp_eac
8852fi
8853
8854if test "$ntp_ok" = "yes"; then
8855    ntp_refclock=yes
8856    cat >> confdefs.h <<\EOF
8857#define CLOCK_ULINK 1
8858EOF
8859
8860fi
8861echo "$ac_t""$ntp_ok" 1>&6
8862
8863echo $ac_n "checking WWV receiver""... $ac_c" 1>&6
8864echo "configure:8865: checking WWV receiver" >&5
8865# Check whether --enable-WWV or --disable-WWV was given.
8866if test "${enable_WWV+set}" = set; then
8867  enableval="$enable_WWV"
8868  ntp_ok=$enableval
8869else
8870  case "$ntp_eac$ntp_canaudio" in
8871     *no*)	ntp_ok=no  ;;
8872     *)		ntp_ok=yes ;;
8873    esac
8874fi
8875
8876if test "$ntp_ok" = "yes"; then
8877    ntp_refclock=yes
8878    cat >> confdefs.h <<\EOF
8879#define CLOCK_WWV 1
8880EOF
8881
8882fi
8883echo "$ac_t""$ntp_ok" 1>&6
8884case "$ntp_ok$ntp_canaudio" in
8885 yesno) echo "configure: warning: *** But the expected answer is... no ***" 1>&2 ;;
8886esac
8887
8888# Requires modem control
8889echo $ac_n "checking USNO modem service""... $ac_c" 1>&6
8890echo "configure:8891: checking USNO modem service" >&5
8891# Check whether --enable-USNO or --disable-USNO was given.
8892if test "${enable_USNO+set}" = set; then
8893  enableval="$enable_USNO"
8894  ntp_ok=$enableval
8895else
8896  cat > conftest.$ac_ext <<EOF
8897#line 8898 "configure"
8898#include "confdefs.h"
8899#include <termios.h>
8900#ifdef HAVE_SYS_IOCTL_H
8901#include <sys/ioctl.h>
8902#endif
8903#ifdef TIOCMBIS
8904         yes
8905#endif
8906         
8907EOF
8908if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8909  egrep "yes" >/dev/null 2>&1; then
8910  rm -rf conftest*
8911  ntp_ok=$ntp_eac
8912else
8913  rm -rf conftest*
8914  ntp_ok=no
8915fi
8916rm -f conftest*
8917
8918fi
8919
8920if test "$ntp_ok" = "yes"; then
8921    ntp_refclock=yes
8922    cat >> confdefs.h <<\EOF
8923#define CLOCK_USNO 1
8924EOF
8925
8926fi
8927echo "$ac_t""$ntp_ok" 1>&6
8928
8929echo $ac_n "checking for default inclusion of all suitable PARSE clocks""... $ac_c" 1>&6
8930echo "configure:8931: checking for default inclusion of all suitable PARSE clocks" >&5
8931# Check whether --enable-parse-clocks or --disable-parse-clocks was given.
8932if test "${enable_parse_clocks+set}" = set; then
8933  enableval="$enable_parse_clocks"
8934  ntp_eapc=$enableval
8935else
8936  case "$ntp_eac" in
8937     yes) ntp_eapc=$ntp_canparse ;;
8938     *) ntp_eapc=no ;;
8939    esac
8940    ntp_eapc=no
8941fi
8942
8943echo "$ac_t""$ntp_eapc" 1>&6
8944
8945case "$ntp_eac$ntp_eapc$ntp_canparse" in
8946 noyes*)
8947    { echo "configure: error: "--enable-parse-clocks" requires "--enable-all-clocks"." 1>&2; exit 1; }
8948    ;;
8949 yesyesno)
8950    { echo "configure: error: You said "--enable-parse-clocks" but PARSE isn't supported on this platform!" 1>&2; exit 1; }
8951    ;;
8952 *) ;;
8953esac
8954
8955ntp_libparse=no
8956ntp_parseutil=no
8957ntp_rawdcf=no
8958
8959echo $ac_n "checking Diem Computime Radio Clock""... $ac_c" 1>&6
8960echo "configure:8961: checking Diem Computime Radio Clock" >&5
8961# Check whether --enable-COMPUTIME or --disable-COMPUTIME was given.
8962if test "${enable_COMPUTIME+set}" = set; then
8963  enableval="$enable_COMPUTIME"
8964  ntp_ok=$enableval
8965else
8966  ntp_ok=$ntp_eapc
8967fi
8968
8969if test "$ntp_ok" = "yes"; then
8970    ntp_libparse=yes
8971    ntp_refclock=yes
8972    cat >> confdefs.h <<\EOF
8973#define CLOCK_COMPUTIME 1
8974EOF
8975
8976fi
8977echo "$ac_t""$ntp_ok" 1>&6
8978case "$ntp_ok$ntp_canparse" in
8979 yesno)
8980    { echo "configure: error: That's a parse clock and this system doesn't support it!" 1>&2; exit 1; }
8981    ;;
8982esac
8983
8984echo $ac_n "checking ELV/DCF7000 clock""... $ac_c" 1>&6
8985echo "configure:8986: checking ELV/DCF7000 clock" >&5
8986# Check whether --enable-DCF7000 or --disable-DCF7000 was given.
8987if test "${enable_DCF7000+set}" = set; then
8988  enableval="$enable_DCF7000"
8989  ntp_ok=$enableval
8990else
8991  ntp_ok=$ntp_eapc
8992fi
8993
8994if test "$ntp_ok" = "yes"; then
8995    ntp_libparse=yes
8996    ntp_refclock=yes
8997    cat >> confdefs.h <<\EOF
8998#define CLOCK_DCF7000 1
8999EOF
9000
9001fi
9002echo "$ac_t""$ntp_ok" 1>&6
9003case "$ntp_ok$ntp_canparse" in
9004 yesno)
9005    { echo "configure: error: That's a parse clock and this system doesn't support it!" 1>&2; exit 1; }
9006    ;;
9007esac
9008
9009echo $ac_n "checking HOPF 6021 clock""... $ac_c" 1>&6
9010echo "configure:9011: checking HOPF 6021 clock" >&5
9011# Check whether --enable-HOPF6021 or --disable-HOPF6021 was given.
9012if test "${enable_HOPF6021+set}" = set; then
9013  enableval="$enable_HOPF6021"
9014  ntp_ok=$enableval
9015else
9016  ntp_ok=$ntp_eapc
9017fi
9018
9019if test "$ntp_ok" = "yes"; then
9020    ntp_libparse=yes
9021    ntp_refclock=yes
9022    cat >> confdefs.h <<\EOF
9023#define CLOCK_HOPF6021 1
9024EOF
9025
9026fi
9027echo "$ac_t""$ntp_ok" 1>&6
9028case "$ntp_ok$ntp_canparse" in
9029 yesno)
9030    { echo "configure: error: That's a parse clock and this system doesn't support it!" 1>&2; exit 1; }
9031    ;;
9032esac
9033
9034echo $ac_n "checking Meinberg clocks""... $ac_c" 1>&6
9035echo "configure:9036: checking Meinberg clocks" >&5
9036# Check whether --enable-MEINBERG or --disable-MEINBERG was given.
9037if test "${enable_MEINBERG+set}" = set; then
9038  enableval="$enable_MEINBERG"
9039  ntp_ok=$enableval
9040else
9041  ntp_ok=$ntp_eapc
9042fi
9043
9044if test "$ntp_ok" = "yes"; then
9045    ntp_libparse=yes
9046    ntp_refclock=yes
9047    cat >> confdefs.h <<\EOF
9048#define CLOCK_MEINBERG 1
9049EOF
9050
9051fi
9052echo "$ac_t""$ntp_ok" 1>&6
9053case "$ntp_ok$ntp_canparse" in
9054 yesno)
9055    { echo "configure: error: That's a parse clock and this system doesn't support it!" 1>&2; exit 1; }
9056    ;;
9057esac
9058
9059echo $ac_n "checking DCF77 raw time code""... $ac_c" 1>&6
9060echo "configure:9061: checking DCF77 raw time code" >&5
9061# Check whether --enable-RAWDCF or --disable-RAWDCF was given.
9062if test "${enable_RAWDCF+set}" = set; then
9063  enableval="$enable_RAWDCF"
9064  ntp_ok=$enableval
9065else
9066  ntp_ok=$ntp_eapc
9067fi
9068
9069if test "$ntp_ok" = "yes"; then
9070    ntp_libparse=yes
9071    ntp_parseutil=yes
9072    ntp_refclock=yes
9073    ntp_rawdcf=yes
9074    cat >> confdefs.h <<\EOF
9075#define CLOCK_RAWDCF 1
9076EOF
9077
9078fi
9079echo "$ac_t""$ntp_ok" 1>&6
9080case "$ntp_ok$ntp_canparse" in
9081 yesno)
9082    { echo "configure: error: That's a parse clock and this system doesn't support it!" 1>&2; exit 1; }
9083    ;;
9084esac
9085
9086case "$ntp_rawdcf" in
9087 yes)
9088    echo $ac_n "checking if we must enable parity for RAWDCF""... $ac_c" 1>&6
9089echo "configure:9090: checking if we must enable parity for RAWDCF" >&5
9090if eval "test \"`echo '$''{'ac_cv_var_rawdcf_parity'+set}'`\" = set"; then
9091  echo $ac_n "(cached) $ac_c" 1>&6
9092else
9093  ans=no
9094    case "$target" in
9095     *-*-linux*)
9096        ans=yes
9097        ;;
9098    esac
9099    ac_cv_var_rawdcf_parity=$ans
9100fi
9101
9102echo "$ac_t""$ac_cv_var_rawdcf_parity" 1>&6
9103    case "$ac_cv_var_rawdcf_parity" in
9104     yes) cat >> confdefs.h <<\EOF
9105#define RAWDCF_NO_IGNPAR 1
9106EOF
9107 ;;
9108    esac
9109    ;;
9110
9111 *) # HMS: Is this a good idea?
9112    ac_cv_var_rawdcf_parity=no
9113    ;;
9114esac
9115
9116echo $ac_n "checking RCC 8000 clock""... $ac_c" 1>&6
9117echo "configure:9118: checking RCC 8000 clock" >&5
9118# Check whether --enable-RCC8000 or --disable-RCC8000 was given.
9119if test "${enable_RCC8000+set}" = set; then
9120  enableval="$enable_RCC8000"
9121  ntp_ok=$enableval
9122else
9123  ntp_ok=$ntp_eapc
9124fi
9125
9126if test "$ntp_ok" = "yes"; then
9127    ntp_libparse=yes
9128    ntp_refclock=yes
9129    cat >> confdefs.h <<\EOF
9130#define CLOCK_RCC8000 1
9131EOF
9132
9133fi
9134echo "$ac_t""$ntp_ok" 1>&6
9135case "$ntp_ok$ntp_canparse" in
9136 yesno)
9137    { echo "configure: error: That's a parse clock and this system doesn't support it!" 1>&2; exit 1; }
9138    ;;
9139esac
9140
9141echo $ac_n "checking Schmid DCF77 clock""... $ac_c" 1>&6
9142echo "configure:9143: checking Schmid DCF77 clock" >&5
9143# Check whether --enable-SCHMID or --disable-SCHMID was given.
9144if test "${enable_SCHMID+set}" = set; then
9145  enableval="$enable_SCHMID"
9146  ntp_ok=$enableval
9147else
9148  ntp_ok=$ntp_eapc
9149fi
9150
9151if test "$ntp_ok" = "yes"; then
9152    ntp_libparse=yes
9153    ntp_refclock=yes
9154    cat >> confdefs.h <<\EOF
9155#define CLOCK_SCHMID 1
9156EOF
9157
9158fi
9159echo "$ac_t""$ntp_ok" 1>&6
9160case "$ntp_ok$ntp_canparse" in
9161 yesno)
9162    { echo "configure: error: That's a parse clock and this system doesn't support it!" 1>&2; exit 1; }
9163    ;;
9164esac
9165
9166echo $ac_n "checking Trimble GPS receiver/TAIP protocol""... $ac_c" 1>&6
9167echo "configure:9168: checking Trimble GPS receiver/TAIP protocol" >&5
9168# Check whether --enable-TRIMTAIP or --disable-TRIMTAIP was given.
9169if test "${enable_TRIMTAIP+set}" = set; then
9170  enableval="$enable_TRIMTAIP"
9171  ntp_ok=$enableval
9172else
9173  ntp_ok=$ntp_eapc
9174fi
9175
9176if test "$ntp_ok" = "yes"; then
9177    ntp_libparse=yes
9178    ntp_refclock=yes
9179    cat >> confdefs.h <<\EOF
9180#define CLOCK_TRIMTAIP 1
9181EOF
9182
9183fi
9184echo "$ac_t""$ntp_ok" 1>&6
9185case "$ntp_ok$ntp_canparse" in
9186 yesno)
9187    { echo "configure: error: That's a parse clock and this system doesn't support it!" 1>&2; exit 1; }
9188    ;;
9189esac
9190
9191echo $ac_n "checking Trimble GPS receiver/TSIP protocol""... $ac_c" 1>&6
9192echo "configure:9193: checking Trimble GPS receiver/TSIP protocol" >&5
9193# Check whether --enable-TRIMTSIP or --disable-TRIMTSIP was given.
9194if test "${enable_TRIMTSIP+set}" = set; then
9195  enableval="$enable_TRIMTSIP"
9196  ntp_ok=$enableval
9197else
9198  ntp_ok=$ntp_eapc
9199fi
9200
9201if test "$ntp_ok" = "yes"; then
9202    ntp_libparse=yes
9203    ntp_refclock=yes
9204    cat >> confdefs.h <<\EOF
9205#define CLOCK_TRIMTSIP 1
9206EOF
9207
9208fi
9209echo "$ac_t""$ntp_ok" 1>&6
9210case "$ntp_ok$ntp_canparse" in
9211 yesno)
9212    { echo "configure: error: That's a parse clock and this system doesn't support it!" 1>&2; exit 1; }
9213    ;;
9214esac
9215
9216echo $ac_n "checking WHARTON 400A Series clock""... $ac_c" 1>&6
9217echo "configure:9218: checking WHARTON 400A Series clock" >&5
9218# Check whether --enable-WHARTON or --disable-WHARTON was given.
9219if test "${enable_WHARTON+set}" = set; then
9220  enableval="$enable_WHARTON"
9221  ntp_ok=$enableval
9222else
9223  ntp_ok=$ntp_eapc
9224fi
9225
9226if test "$ntp_ok" = "yes"; then
9227    ntp_libparse=yes
9228    ntp_refclock=yes
9229    cat >> confdefs.h <<\EOF
9230#define CLOCK_WHARTON_400A 1
9231EOF
9232
9233fi
9234echo "$ac_t""$ntp_ok" 1>&6
9235case "$ntp_ok$ntp_canparse" in
9236 yesno)
9237    { echo "configure: error: That's a parse clock and this system doesn't support it!" 1>&2; exit 1; }
9238    ;;
9239esac
9240
9241echo $ac_n "checking VARITEXT clock""... $ac_c" 1>&6
9242echo "configure:9243: checking VARITEXT clock" >&5
9243# Check whether --enable-VARITEXT or --disable-VARITEXT was given.
9244if test "${enable_VARITEXT+set}" = set; then
9245  enableval="$enable_VARITEXT"
9246  ntp_ok=$enableval
9247else
9248  ntp_ok=$ntp_eapc
9249fi
9250
9251if test "$ntp_ok" = "yes"; then
9252    ntp_libparse=yes
9253    ntp_refclock=yes
9254    cat >> confdefs.h <<\EOF
9255#define CLOCK_VARITEXT 1
9256EOF
9257
9258fi
9259echo "$ac_t""$ntp_ok" 1>&6
9260case "$ntp_ok$ntp_canparse" in
9261 yesno)
9262    { echo "configure: error: That's a parse clock and this system doesn't support it!" 1>&2; exit 1; }
9263    ;;
9264esac
9265
9266
9267
9268
9269echo $ac_n "checking if we need to make and use the parse libraries""... $ac_c" 1>&6
9270echo "configure:9271: checking if we need to make and use the parse libraries" >&5
9271ans=no
9272case "$ntp_libparse" in
9273 yes)
9274    ans=yes
9275    cat >> confdefs.h <<\EOF
9276#define CLOCK_PARSE 1
9277EOF
9278
9279    LIBPARSE=../libparse/libparse.a
9280    MAKE_LIBPARSE=libparse.a
9281    MAKE_CHECK_Y2K=check_y2k
9282    cat >> confdefs.h <<\EOF
9283#define PPS_SAMPLE 1
9284EOF
9285
9286    cat >> confdefs.h <<\EOF
9287#define CLOCK_ATOM 1
9288EOF
9289
9290    ;;
9291esac
9292echo "$ac_t""$ans" 1>&6
9293
9294
9295
9296
9297echo $ac_n "checking if we need to make and use the RSAREF library""... $ac_c" 1>&6
9298echo "configure:9299: checking if we need to make and use the RSAREF library" >&5
9299ans=no
9300if test -f $srcdir/rsaref2/source/rsa.c
9301then
9302    ans=yes
9303    LIBRSAREF=../librsaref/librsaref.a
9304    MAKE_LIBRSAREF=librsaref.a
9305    cat >> confdefs.h <<\EOF
9306#define DES 1
9307EOF
9308
9309fi
9310echo "$ac_t""$ans" 1>&6
9311
9312
9313
9314
9315echo $ac_n "checking if we can make dcf parse utilities""... $ac_c" 1>&6
9316echo "configure:9317: checking if we can make dcf parse utilities" >&5
9317ans=no
9318if test "$ntp_parseutil" = "yes"; then
9319    case "$target" in
9320     *-*-sunos4*|*-*-solaris2*|*-*-linux*)
9321	ans="dcfd testdcf"
9322	DCFD=dcfd
9323        TESTDCF=testdcf
9324	;;
9325    esac
9326fi
9327echo "$ac_t""$ans" 1>&6
9328
9329
9330echo $ac_n "checking if we can build kernel streams modules for parse""... $ac_c" 1>&6
9331echo "configure:9332: checking if we can build kernel streams modules for parse" >&5
9332ans=no
9333case "$ntp_parseutil$ac_cv_header_sys_stropts_h" in
9334 yesyes)
9335    case "$target" in
9336     sparc-*-sunos4*)
9337        case "$ac_cv_var_kernel_pll" in
9338	yes)
9339	    cat >> confdefs.h <<\EOF
9340#define PPS_SYNC 1
9341EOF
9342
9343	    ;;
9344	esac
9345	ans=parsestreams
9346	MAKE_PARSEKMODULE=parsestreams.loadable_module.o
9347	;;
9348     sparc-*-solaris2*)
9349	ans=parsesolaris
9350	MAKE_PARSEKMODULE=parse
9351	;;
9352    esac
9353    ;;
9354esac
9355echo "$ac_t""$ans" 1>&6
9356
9357echo $ac_n "checking if we need basic refclock support""... $ac_c" 1>&6
9358echo "configure:9359: checking if we need basic refclock support" >&5
9359if test "$ntp_refclock" = "yes"; then
9360    cat >> confdefs.h <<\EOF
9361#define REFCLOCK 1
9362EOF
9363
9364fi
9365echo "$ac_t""$ntp_refclock" 1>&6
9366
9367
9368
9369echo $ac_n "checking if we want HP-UX adjtimed support""... $ac_c" 1>&6
9370echo "configure:9371: checking if we want HP-UX adjtimed support" >&5
9371case "$target" in
9372 *-*-hpux[56789]*)
9373    ans=yes
9374    ;;
9375 *) ans=no
9376    ;;
9377esac
9378if test "$ans" = "yes"; then
9379    MAKE_ADJTIMED=adjtimed
9380    cat >> confdefs.h <<\EOF
9381#define NEED_HPUX_ADJTIME 1
9382EOF
9383
9384fi
9385echo "$ac_t""$ans" 1>&6
9386
9387echo $ac_n "checking if we can read kmem""... $ac_c" 1>&6
9388echo "configure:9389: checking if we can read kmem" >&5
9389if eval "test \"`echo '$''{'ac_cv_var_can_kmem'+set}'`\" = set"; then
9390  echo $ac_n "(cached) $ac_c" 1>&6
9391else
9392  # Check whether --enable-kmem or --disable-kmem was given.
9393if test "${enable_kmem+set}" = set; then
9394  enableval="$enable_kmem"
9395  ans=$enableval
9396else
9397      case "$ac_cv_func_nlist$ac_cv_func_K_open$ac_cv_func_kvm_open" in
9398     *yes*)
9399	ans=yes
9400	;;
9401     *) ans=no
9402	;;
9403    esac
9404    case "$target" in
9405     *-*-aix*)
9406	#ans=no
9407	;;
9408     *-*-domainos)	# Won't be found...
9409	ans=no
9410	;;
9411     *-*-hpux*)
9412	#ans=no
9413	;;
9414     *-*-irix[456]*)
9415	ans=no
9416	;;
9417     *-*-linux*)
9418	ans=no
9419	;;
9420     *-*-winnt3.5)
9421	ans=no
9422	;;
9423    esac
9424
9425fi
9426
9427ac_cv_var_can_kmem=$ans
9428fi
9429
9430echo "$ac_t""$ac_cv_var_can_kmem" 1>&6
9431
9432case "$ac_cv_var_can_kmem" in
9433 *yes*) ;;
9434 *) cat >> confdefs.h <<\EOF
9435#define NOKMEM 1
9436EOF
9437 ;;
9438esac
9439
9440echo $ac_n "checking if adjtime is accurate""... $ac_c" 1>&6
9441echo "configure:9442: checking if adjtime is accurate" >&5
9442if eval "test \"`echo '$''{'ac_cv_var_adjtime_is_accurate'+set}'`\" = set"; then
9443  echo $ac_n "(cached) $ac_c" 1>&6
9444else
9445  # Check whether --enable-accurate-adjtime or --disable-accurate-adjtime was given.
9446if test "${enable_accurate_adjtime+set}" = set; then
9447  enableval="$enable_accurate_adjtime"
9448  ans=$enableval
9449else
9450      case "$target" in
9451      i386-sequent-ptx*)
9452	 ans=no
9453	 ;;
9454      i386-unknown-osf1*)
9455	 ans=yes
9456	 ;;
9457      mips-sgi-irix[456]*)
9458	 ans=yes
9459	 ;;
9460      *-fujitsu-uxp*)
9461	 ans=yes
9462	 ;;
9463      *-ibm-aix4*)
9464	 ans=yes
9465	 ;;
9466      *-*-linux*)
9467	 ans=yes
9468	 ;;
9469      *-*-solaris2.[01]*)
9470	 ans=no
9471	 ;;
9472      *-*-solaris2*)
9473         ans=yes
9474         ;;
9475      *) ans=no
9476	 ;;
9477     esac
9478
9479fi
9480
9481ac_cv_var_adjtime_is_accurate=$ans
9482fi
9483
9484echo "$ac_t""$ac_cv_var_adjtime_is_accurate" 1>&6
9485case "$ac_cv_var_adjtime_is_accurate" in
9486 yes) cat >> confdefs.h <<\EOF
9487#define ADJTIME_IS_ACCURATE 1
9488EOF
9489 ;;
9490esac
9491
9492echo $ac_n "checking the name of 'tick' in the kernel""... $ac_c" 1>&6
9493echo "configure:9494: checking the name of 'tick' in the kernel" >&5
9494if eval "test \"`echo '$''{'ac_cv_var_nlist_tick'+set}'`\" = set"; then
9495  echo $ac_n "(cached) $ac_c" 1>&6
9496else
9497  ans=_tick
9498case "$target" in
9499 m68*-hp-hpux*) # HP9000/300?
9500    ans=_old_tick
9501    ;;
9502 *-apple-aux[23]*)
9503    ans=tick
9504    ;;
9505 *-hp-hpux*)
9506    ans=old_tick
9507    ;;
9508 *-ibm-aix[34]*)
9509    ans=no
9510    ;;
9511 *-*-ptx*)
9512    ans=tick
9513    ;;
9514 *-*-sco3.2v[45]*)
9515    ans=no
9516    ;;
9517 *-*-solaris2*)
9518    ans=nsec_per_tick
9519    ;;
9520 *-*-sysv4*)
9521    ans=tick
9522    ;;
9523esac
9524ac_cv_var_nlist_tick=$ans
9525fi
9526
9527echo "$ac_t""$ac_cv_var_nlist_tick" 1>&6
9528case "$ac_cv_var_nlist_tick" in
9529 ''|no) ;;	# HMS: I think we can only get 'no' here...
9530 *) cat >> confdefs.h <<EOF
9531#define K_TICK_NAME "$ac_cv_var_nlist_tick"
9532EOF
9533 ;;
9534esac
9535#
9536echo $ac_n "checking for the units of 'tick'""... $ac_c" 1>&6
9537echo "configure:9538: checking for the units of 'tick'" >&5
9538if eval "test \"`echo '$''{'ac_cv_var_tick_nano'+set}'`\" = set"; then
9539  echo $ac_n "(cached) $ac_c" 1>&6
9540else
9541  ans=usec
9542case "$target" in
9543 *-*-solaris2*)
9544    ans=nsec
9545    ;;
9546esac
9547ac_cv_var_tick_nano=$ans
9548fi
9549
9550echo "$ac_t""$ac_cv_var_tick_nano" 1>&6
9551case "$ac_cv_var_tick_nano" in
9552 nsec)
9553    cat >> confdefs.h <<\EOF
9554#define TICK_NANO 1
9555EOF
9556
9557    ;;
9558esac
9559#
9560echo $ac_n "checking the name of 'tickadj' in the kernel""... $ac_c" 1>&6
9561echo "configure:9562: checking the name of 'tickadj' in the kernel" >&5
9562if eval "test \"`echo '$''{'ac_cv_var_nlist_tickadj'+set}'`\" = set"; then
9563  echo $ac_n "(cached) $ac_c" 1>&6
9564else
9565  ans=_tickadj
9566case "$target" in
9567 m68*-hp-hpux*) # HP9000/300?
9568    ans=_tickadj
9569    ;;
9570 *-apple-aux[23]*)
9571    ans=tickadj
9572    ;;
9573 *-hp-hpux10*)
9574    ans=no
9575    ;;
9576 *-hp-hpux9*)
9577    ans=no
9578    ;;
9579 *-hp-hpux*)
9580    ans=tickadj
9581    ;;
9582 *-*-aix*)
9583    ans=tickadj
9584    ;;
9585 *-*-ptx*)
9586    ans=tickadj
9587    ;;
9588 *-*-sco3.2v4*)
9589    ans=no
9590    ;;
9591 *-*-sco3.2v5.0*)
9592    ans=clock_drift
9593    ;;
9594 *-*-solaris2*)
9595    ans=no	# hrestime_adj
9596    ;;
9597 *-*-sysv4*)
9598    ans=tickadj
9599    ;;
9600esac
9601ac_cv_var_nlist_tickadj=$ans
9602fi
9603
9604echo "$ac_t""$ac_cv_var_nlist_tickadj" 1>&6
9605case "$ac_cv_var_nlist_tickadj" in
9606 ''|no) ;;	# HMS: I think we can only get 'no' here...
9607 *) cat >> confdefs.h <<EOF
9608#define K_TICKADJ_NAME "$ac_cv_var_nlist_tickadj"
9609EOF
9610 ;;
9611esac
9612#
9613echo $ac_n "checking for the units of 'tickadj'""... $ac_c" 1>&6
9614echo "configure:9615: checking for the units of 'tickadj'" >&5
9615if eval "test \"`echo '$''{'ac_cv_var_tickadj_nano'+set}'`\" = set"; then
9616  echo $ac_n "(cached) $ac_c" 1>&6
9617else
9618  ans=usec
9619case "$target" in
9620 *-*-solaris2*)
9621    ans=nsec
9622    ;;
9623esac
9624ac_cv_var_tickadj_nano=$ans
9625fi
9626
9627echo "$ac_t""$ac_cv_var_tickadj_nano" 1>&6
9628case "$ac_cv_var_tickadj_nano" in
9629 nsec)
9630    cat >> confdefs.h <<\EOF
9631#define TICKADJ_NANO 1
9632EOF
9633
9634    ;;
9635esac
9636#
9637echo $ac_n "checking half-heartedly for 'dosynctodr' in the kernel""... $ac_c" 1>&6
9638echo "configure:9639: checking half-heartedly for 'dosynctodr' in the kernel" >&5
9639if eval "test \"`echo '$''{'ac_cv_var_nlist_dosynctodr'+set}'`\" = set"; then
9640  echo $ac_n "(cached) $ac_c" 1>&6
9641else
9642  case "$target" in
9643 *-apple-aux[23]*)
9644    ans=no
9645    ;;
9646 *-sni-sysv*)
9647    ans=dosynctodr
9648    ;;
9649 *-*-aix*)
9650    ans=dosynctodr
9651    ;;
9652 *-*-hpux*)
9653    ans=no
9654    ;;
9655 *-*-nextstep*)
9656    ans=_dosynctodr
9657    ;;
9658 *-*-ptx*)
9659    ans=doresettodr
9660    ;;
9661 *-*-sco3.2v4*)
9662    ans=no
9663    ;;
9664 *-*-sco3.2v5*)
9665    ans=track_rtc
9666    ;;
9667 *-*-solaris2*)
9668    ans=dosynctodr
9669    ;;
9670 *-*-sysv4*)
9671    ans=doresettodr
9672    ;;
9673 *)
9674    ans=_dosynctodr
9675    ;;
9676esac
9677ac_cv_var_nlist_dosynctodr=$ans
9678fi
9679
9680echo "$ac_t""$ac_cv_var_nlist_dosynctodr" 1>&6
9681case "$ac_cv_var_nlist_dosynctodr" in
9682 no) ;;
9683 *)  cat >> confdefs.h <<EOF
9684#define K_DOSYNCTODR_NAME "$ac_cv_var_nlist_dosynctodr"
9685EOF
9686
9687     ;;
9688esac
9689#
9690echo $ac_n "checking half-heartedly for 'noprintf' in the kernel""... $ac_c" 1>&6
9691echo "configure:9692: checking half-heartedly for 'noprintf' in the kernel" >&5
9692if eval "test \"`echo '$''{'ac_cv_var_nlist_noprintf'+set}'`\" = set"; then
9693  echo $ac_n "(cached) $ac_c" 1>&6
9694else
9695  case "$target" in
9696 *-apple-aux[23]*)
9697    ans=no
9698    ;;
9699 *-sni-sysv*)
9700    ans=noprintf
9701    ;;
9702 *-*-aix*)
9703    ans=noprintf
9704    ;;
9705 *-*-hpux*)
9706    ans=no
9707    ;;
9708 *-*-ptx*)
9709    ans=noprintf
9710    ;;
9711 *-*-nextstep*)
9712    ans=_noprintf
9713    ;;
9714 *-*-solaris2*)
9715    ans=noprintf
9716    ;;
9717 *-*-sysv4*)
9718    ans=noprintf
9719    ;;
9720 *)
9721    ans=_noprintf
9722    ;;
9723esac
9724ac_cv_var_nlist_noprintf=$ans
9725fi
9726
9727echo "$ac_t""$ac_cv_var_nlist_noprintf" 1>&6
9728case "$ac_cv_var_nlist_noprintf" in
9729 no) ;;
9730 *)  cat >> confdefs.h <<EOF
9731#define K_NOPRINTF_NAME "$ac_cv_var_nlist_noprintf"
9732EOF
9733
9734     ;;
9735esac
9736
9737
9738
9739
9740echo $ac_n "checking for a default value for 'tick'""... $ac_c" 1>&6
9741echo "configure:9742: checking for a default value for 'tick'" >&5
9742if eval "test \"`echo '$''{'ac_cv_var_tick'+set}'`\" = set"; then
9743  echo $ac_n "(cached) $ac_c" 1>&6
9744else
9745  # Check whether --enable-tick or --disable-tick was given.
9746if test "${enable_tick+set}" = set; then
9747  enableval="$enable_tick"
9748  ans=$enableval
9749else
9750  ans=no
9751     case "$target" in
9752      XXX-*-pc-cygwin*)
9753	 ;;
9754      *-univel-sysv*)
9755	 ans=10000
9756	 ;;
9757      *-*-irix*)
9758	 ans=10000
9759	 ;;
9760      *-*-linux*)
9761	 ans=txc.tick
9762	 ;;
9763      *-*-winnt3.5)
9764	 ans='(every / 10)'
9765	 ;;
9766      *)
9767	 ans='1000000L/hz'
9768	 ;;
9769     esac
9770fi
9771
9772ac_cv_var_tick=$ans
9773fi
9774
9775echo "$ac_t""$ac_cv_var_tick" 1>&6
9776case "$ac_cv_var_tick" in
9777 ''|no) ;;	# HMS: I think we can only get 'no' here...
9778 *) cat >> confdefs.h <<EOF
9779#define PRESET_TICK $ac_cv_var_tick
9780EOF
9781 ;;
9782esac
9783
9784echo $ac_n "checking for a default value for 'tickadj'""... $ac_c" 1>&6
9785echo "configure:9786: checking for a default value for 'tickadj'" >&5
9786if eval "test \"`echo '$''{'ac_cv_var_tickadj'+set}'`\" = set"; then
9787  echo $ac_n "(cached) $ac_c" 1>&6
9788else
9789  # Check whether --enable-tickadj or --disable-tickadj was given.
9790if test "${enable_tickadj+set}" = set; then
9791  enableval="$enable_tickadj"
9792  ans=$enableval
9793else
9794  ans='500/hz'
9795  case "$target" in
9796   *-fujitsu-uxp*)
9797      case "$ac_cv_var_adjtime_is_accurate" in
9798       yes) ans='tick/16' ;;
9799      esac
9800      ;;
9801   XXX-*-pc-cygwin*)
9802      ans=no
9803      ;;
9804   *-univel-sysv*)
9805      ans=80
9806      ;;
9807   *-*-aix*)
9808      case "$ac_cv_var_can_kmem" in
9809       no) ans=1000 ;;
9810      esac
9811      ;;
9812   *-*-domainos)	# Skippy: won't be found...
9813      case "$ac_cv_var_can_kmem" in
9814       no) ans=668 ;;
9815      esac
9816      ;;
9817   *-*-hpux*)
9818      case "$ac_cv_var_adjtime_is_accurate" in
9819       yes) ans='tick/16' ;;
9820      esac
9821      ;;
9822   *-*-irix*)
9823      ans=150
9824      ;;
9825   *-*-sco3.2v5.0*)
9826      ans=10000L/hz
9827      ;;
9828   *-*-solaris2*)
9829      case "$ac_cv_var_adjtime_is_accurate" in
9830       yes)
9831          #ans='tick/16'
9832	  ;;
9833      esac
9834      ;;
9835   *-*-winnt3.5)
9836      ans=50
9837      ;;
9838  esac
9839fi
9840
9841ac_cv_var_tickadj=$ans
9842fi
9843
9844echo "$ac_t""$ac_cv_var_tickadj" 1>&6
9845case "$ac_cv_var_tickadj" in
9846 ''|no) ;;	# HMS: I think we can only get 'no' here...
9847 *) cat >> confdefs.h <<EOF
9848#define PRESET_TICKADJ $ac_cv_var_tickadj
9849EOF
9850 ;;
9851esac
9852
9853# Newer versions of ReliantUNIX round adjtime() values down to
9854# 1/100s (system tick). Sigh ...
9855# Unfortunately, there is no easy way to know if particular release
9856# has this "feature" or any obvious way to test for it.
9857case "$target" in
9858 mips-sni-sysv4*) cat >> confdefs.h <<\EOF
9859#define RELIANTUNIX_CLOCK 1
9860EOF
9861 ;;
9862esac
9863
9864case "$target" in
9865 *-*-sco3.2v5*) cat >> confdefs.h <<\EOF
9866#define SCO5_CLOCK 1
9867EOF
9868 ;;
9869esac
9870
9871ac_cv_make_tickadj=yes
9872case "$ac_cv_var_can_kmem$ac_cv_var_tick$ac_cv_var_tickadj" in
9873 nonono)	# Don't read KMEM, no presets.  Bogus.
9874    echo "configure: warning: Can't read kmem" 1>&2
9875    ac_cv_make_tickadj=no
9876    ;;
9877 nono*)		# Don't read KMEM, no PRESET_TICK but PRESET_TICKADJ.  Bogus.
9878    echo "configure: warning: Can't read kmem but no PRESET_TICK.  No tickadj." 1>&2
9879    ac_cv_make_tickadj=no
9880    ;;
9881 no*no)		# Don't read KMEM, PRESET_TICK but no PRESET_TICKADJ.  Bogus.
9882    echo "configure: warning: Can't read kmem but no PRESET_TICKADJ.  No tickadj." 1>&2
9883    ac_cv_make_tickadj=no
9884    ;;
9885 no*)		# Don't read KMEM, PRESET_TICK and PRESET_TICKADJ.  Cool.
9886    ;;
9887 yesnono)	# Read KMEM, no presets.  Cool.
9888    ;;
9889 yesno*)	# Read KMEM, no PRESET_TICK but PRESET_TICKADJ.  Bogus.
9890    echo "configure: warning: PRESET_TICKADJ is defined but not PRESET_TICK.  Please report this." 1>&2
9891    ;;
9892 yes*no)	# Read KMEM, PRESET_TICK but no PRESET_TICKADJ.  Cool.
9893    ;;
9894 yes*)		# READ KMEM, PRESET_TICK and PRESET_TICKADJ.
9895    ;;
9896 *)		# Generally bogus.
9897    { echo "configure: error: This shouldn't happen." 1>&2; exit 1; }
9898    ;;
9899esac
9900
9901case "$target" in
9902 mips-sni-sysv4*)
9903    # tickadj is pretty useless on newer versions of ReliantUNIX
9904    # Do not bother
9905    ac_cv_make_tickadj=no
9906 ;;
9907 *-*-solaris2*)
9908    # DLM says tickadj is a no-no starting with solaris2.5
9909    case "$target" in
9910     *-*-solaris2.0-4*) ;;
9911     *) ac_cv_make_tickadj=no ;;
9912    esac
9913 ;;
9914esac
9915
9916
9917echo $ac_n "checking if we want and can make the tickadj utility""... $ac_c" 1>&6
9918echo "configure:9919: checking if we want and can make the tickadj utility" >&5
9919if eval "test \"`echo '$''{'ac_cv_make_tickadj'+set}'`\" = set"; then
9920  echo $ac_n "(cached) $ac_c" 1>&6
9921else
9922  ac_cv_make_tickadj=yes
9923fi
9924
9925echo "$ac_t""$ac_cv_make_tickadj" 1>&6
9926case "$ac_cv_make_tickadj" in
9927 yes)
9928    MAKE_TICKADJ=tickadj
9929    ;;
9930esac
9931
9932
9933echo $ac_n "checking if we want and can make the ntptime utility""... $ac_c" 1>&6
9934echo "configure:9935: checking if we want and can make the ntptime utility" >&5
9935if eval "test \"`echo '$''{'ac_cv_make_ntptime'+set}'`\" = set"; then
9936  echo $ac_n "(cached) $ac_c" 1>&6
9937else
9938  case "$target" in
9939 *) case "$ac_cv_struct_ntptimeval$ac_cv_var_kernel_pll" in
9940     yesyes)
9941	ans=yes
9942	;;
9943     *)
9944	ans=no
9945	;;
9946    esac
9947    ;;
9948esac
9949ac_cv_make_ntptime=$ans
9950fi
9951
9952echo "$ac_t""$ac_cv_make_ntptime" 1>&6
9953case "$ac_cv_make_ntptime" in
9954 yes)
9955    MAKE_NTPTIME=ntptime
9956    ;;
9957esac
9958
9959echo $ac_n "checking if we want UDP wildcard delivery""... $ac_c" 1>&6
9960echo "configure:9961: checking if we want UDP wildcard delivery" >&5
9961if eval "test \"`echo '$''{'ac_cv_var_udp_wildcard_delivery'+set}'`\" = set"; then
9962  echo $ac_n "(cached) $ac_c" 1>&6
9963else
9964  # Check whether --enable-udp-wildcard or --disable-udp-wildcard was given.
9965if test "${enable_udp_wildcard+set}" = set; then
9966  enableval="$enable_udp_wildcard"
9967  ans=$enableval
9968else
9969  ans=no
9970     case "$target" in
9971      *-fujitsu-uxp*)
9972	 ans=yes
9973	 ;;
9974      *-univel-sysv*)
9975	 ans=yes
9976	 ;;
9977      *-*-aix3.2*)
9978	 ans=yes
9979	 ;;
9980      *-*-aix4*)
9981	 ans=yes
9982	 ;;
9983      *-*-bsdi*)
9984	 ans=yes
9985	 ;;
9986      *-*-domainos)
9987	 ans=yes
9988	 ;;
9989      *-*-freebsd*)
9990	ans=yes
9991	;;
9992      *-*-hpux*)
9993	 ans=yes
9994	 ;;
9995      *-*-irix6*)
9996	 ans=yes
9997	 ;;
9998      *-*-linux*)
9999	 ans=yes
10000	 ;;
10001      *-*-osf*)
10002	 ans=yes
10003	 ;;
10004      *-*-ptx*)
10005	 ans=yes
10006	 ;;
10007      *-*-solaris2*)
10008	 ans=yes
10009	 ;;
10010      *-*-sunos4*)
10011	 ans=yes
10012	 ;;
10013     esac
10014fi
10015
10016ac_cv_var_udp_wildcard_delivery=$ans
10017fi
10018
10019echo "$ac_t""$ac_cv_var_udp_wildcard_delivery" 1>&6
10020case "$ac_cv_var_udp_wildcard_delivery" in
10021 yes) cat >> confdefs.h <<\EOF
10022#define UDP_WILDCARD_DELIVERY 1
10023EOF
10024 ;;
10025esac
10026
10027case "$host" in
10028 $target)
10029    ;;
10030 *) case "$target" in
10031     *-*-vxworks*)
10032        LDFLAGS="$LDFLAGS -r"
10033        ;;
10034    esac
10035    ;;
10036esac
10037
10038echo $ac_n "checking if we should always slew the time""... $ac_c" 1>&6
10039echo "configure:10040: checking if we should always slew the time" >&5
10040if eval "test \"`echo '$''{'ac_cv_var_slew_always'+set}'`\" = set"; then
10041  echo $ac_n "(cached) $ac_c" 1>&6
10042else
10043  # Check whether --enable-slew-always or --disable-slew-always was given.
10044if test "${enable_slew_always+set}" = set; then
10045  enableval="$enable_slew_always"
10046  ans=$enableval
10047else
10048      case "$target" in
10049      *-apple-aux[23]*)
10050	 ans=yes
10051	 ;;
10052      *-*-bsdi[012]*)
10053	 ans=no
10054	 ;;
10055      *-*-bsdi*)
10056	 ans=yes
10057	 ;;
10058      *-*-openvms*)	# HMS: won't be found
10059	 ans=yes
10060	 ;;
10061      *) ans=no
10062	 ;;
10063     esac
10064
10065fi
10066
10067ac_cv_var_slew_always=$ans
10068fi
10069
10070echo "$ac_t""$ac_cv_var_slew_always" 1>&6
10071case "$ac_cv_var_slew_always" in
10072 yes) cat >> confdefs.h <<\EOF
10073#define SLEWALWAYS 1
10074EOF
10075 ;;
10076esac
10077
10078echo $ac_n "checking if we should step and slew the time""... $ac_c" 1>&6
10079echo "configure:10080: checking if we should step and slew the time" >&5
10080if eval "test \"`echo '$''{'ac_cv_var_step_slew'+set}'`\" = set"; then
10081  echo $ac_n "(cached) $ac_c" 1>&6
10082else
10083  # Check whether --enable-step-slew or --disable-step-slew was given.
10084if test "${enable_step_slew+set}" = set; then
10085  enableval="$enable_step_slew"
10086  ans=$enableval
10087else
10088      case "$target" in
10089      *-sni-sysv*)
10090	 ans=yes
10091	 ;;
10092      *-univel-sysv*)
10093	 ans=no
10094	 ;;
10095      *-*-ptx*)
10096	 ans=yes
10097	 ;;
10098      *-*-solaris2.[012]*)
10099	 ans=yes
10100	 ;;
10101      *-*-sysv4*)	# HMS: Does this catch Fujitsu UXP?
10102	 ans=yes
10103	 ;;
10104      *) ans=no
10105	 ;;
10106     esac
10107
10108fi
10109
10110ac_cv_var_step_slew=$ans
10111fi
10112
10113echo "$ac_t""$ac_cv_var_step_slew" 1>&6
10114case "$ac_cv_var_step_slew" in
10115 yes) cat >> confdefs.h <<\EOF
10116#define STEP_SLEW 1
10117EOF
10118 ;;
10119esac
10120
10121echo $ac_n "checking if ntpdate should step the time""... $ac_c" 1>&6
10122echo "configure:10123: checking if ntpdate should step the time" >&5
10123if eval "test \"`echo '$''{'ac_cv_var_ntpdate_step'+set}'`\" = set"; then
10124  echo $ac_n "(cached) $ac_c" 1>&6
10125else
10126  # Check whether --enable-ntpdate-step or --disable-ntpdate-step was given.
10127if test "${enable_ntpdate_step+set}" = set; then
10128  enableval="$enable_ntpdate_step"
10129  ans=$enableval
10130else
10131      case "$target" in
10132      *-apple-aux[23]*)
10133	 ans=yes
10134	 ;;
10135      *) ans=no
10136	 ;;
10137     esac
10138
10139fi
10140
10141ac_cv_var_ntpdate_step=$ans
10142fi
10143
10144echo "$ac_t""$ac_cv_var_ntpdate_step" 1>&6
10145case "$ac_cv_var_ntpdate_step" in
10146 yes) cat >> confdefs.h <<\EOF
10147#define FORCE_NTPDATE_STEP 1
10148EOF
10149 ;;
10150esac
10151
10152echo $ac_n "checking if we should sync TODR clock every hour""... $ac_c" 1>&6
10153echo "configure:10154: checking if we should sync TODR clock every hour" >&5
10154if eval "test \"`echo '$''{'ac_cv_var_sync_todr'+set}'`\" = set"; then
10155  echo $ac_n "(cached) $ac_c" 1>&6
10156else
10157  # Check whether --enable-hourly-todr-sync or --disable-hourly-todr-sync was given.
10158if test "${enable_hourly_todr_sync+set}" = set; then
10159  enableval="$enable_hourly_todr_sync"
10160  ans=$enableval
10161else
10162  case "$target" in
10163      *-*-nextstep*)
10164	 ans=yes
10165	 ;;
10166      *-*-openvms*)	# HMS: won't be found
10167	 ans=yes
10168	 ;;
10169      *) ans=no
10170	 ;;
10171     esac
10172fi
10173
10174ac_cv_var_sync_todr=$ans
10175fi
10176
10177echo "$ac_t""$ac_cv_var_sync_todr" 1>&6
10178case "$ac_cv_var_sync_todr" in
10179 yes) cat >> confdefs.h <<\EOF
10180#define DOSYNCTODR 1
10181EOF
10182 ;;
10183esac
10184
10185echo $ac_n "checking if we should avoid kernel FLL bug""... $ac_c" 1>&6
10186echo "configure:10187: checking if we should avoid kernel FLL bug" >&5
10187if eval "test \"`echo '$''{'ac_cv_var_kernel_fll_bug'+set}'`\" = set"; then
10188  echo $ac_n "(cached) $ac_c" 1>&6
10189else
10190  # Check whether --enable-kernel-fll-bug or --disable-kernel-fll-bug was given.
10191if test "${enable_kernel_fll_bug+set}" = set; then
10192  enableval="$enable_kernel_fll_bug"
10193  ans=$enableval
10194else
10195      case "$target" in
10196     *-*-solaris2.6)
10197	 ans=yes
10198	 ;;
10199     *-*-solaris2.7)
10200	 case "`uname -v`" in
10201	  Generic_106541-07)
10202	     ans=no
10203	     ;;
10204	  *) ans=yes
10205	     ;;
10206	 esac
10207	 ;;
10208     *) ans=no
10209	 ;;
10210    esac
10211
10212fi
10213
10214ac_cv_var_kernel_fll_bug=$ans
10215fi
10216
10217echo "$ac_t""$ac_cv_var_kernel_fll_bug" 1>&6
10218case "$ac_cv_var_kernel_fll_bug" in
10219 yes) cat >> confdefs.h <<\EOF
10220#define KERNEL_FLL_BUG 1
10221EOF
10222 ;;
10223esac
10224
10225case "$host" in
10226 $target)
10227    ;;
10228 *) case "$target" in
10229     *-*-vxworks*)
10230        LDFLAGS="$LDFLAGS -r"
10231        ;;
10232    esac
10233    ;;
10234esac
10235
10236# This is necessary so that .o files in LIBOBJS are also built via
10237# the ANSI2KNR-filtering rules.
10238LIBOBJS=`echo $LIBOBJS|sed 's/\.o /\$U.o /g;s/\.o$/\$U.o/'`
10239
10240trap '' 1 2 15
10241cat > confcache <<\EOF
10242# This file is a shell script that caches the results of configure
10243# tests run on this system so they can be shared between configure
10244# scripts and configure runs.  It is not useful on other systems.
10245# If it contains results you don't want to keep, you may remove or edit it.
10246#
10247# By default, configure uses ./config.cache as the cache file,
10248# creating it if it does not exist already.  You can give configure
10249# the --cache-file=FILE option to use a different cache file; that is
10250# what configure does when it calls configure scripts in
10251# subdirectories, so they share the cache.
10252# Giving --cache-file=/dev/null disables caching, for debugging configure.
10253# config.status only pays attention to the cache file if you give it the
10254# --recheck option to rerun configure.
10255#
10256EOF
10257# The following way of writing the cache mishandles newlines in values,
10258# but we know of no workaround that is simple, portable, and efficient.
10259# So, don't put newlines in cache variables' values.
10260# Ultrix sh set writes to stderr and can't be redirected directly,
10261# and sets the high bit in the cache file unless we assign to the vars.
10262(set) 2>&1 |
10263  case `(ac_space=' '; set | grep ac_space) 2>&1` in
10264  *ac_space=\ *)
10265    # `set' does not quote correctly, so add quotes (double-quote substitution
10266    # turns \\\\ into \\, and sed turns \\ into \).
10267    sed -n \
10268      -e "s/'/'\\\\''/g" \
10269      -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
10270    ;;
10271  *)
10272    # `set' quotes correctly as required by POSIX, so do not add quotes.
10273    sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
10274    ;;
10275  esac >> confcache
10276if cmp -s $cache_file confcache; then
10277  :
10278else
10279  if test -w $cache_file; then
10280    echo "updating cache $cache_file"
10281    cat confcache > $cache_file
10282  else
10283    echo "not updating unwritable cache $cache_file"
10284  fi
10285fi
10286rm -f confcache
10287
10288trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
10289
10290test "x$prefix" = xNONE && prefix=$ac_default_prefix
10291# Let make expand exec_prefix.
10292test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
10293
10294# Any assignment to VPATH causes Sun make to only execute
10295# the first set of double-colon rules, so remove it if not needed.
10296# If there is a colon in the path, we need to keep it.
10297if test "x$srcdir" = x.; then
10298  ac_vpsub='/^[ 	]*VPATH[ 	]*=[^:]*$/d'
10299fi
10300
10301trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
10302
10303DEFS=-DHAVE_CONFIG_H
10304
10305# Without the "./", some shells look in PATH for config.status.
10306: ${CONFIG_STATUS=./config.status}
10307
10308echo creating $CONFIG_STATUS
10309rm -f $CONFIG_STATUS
10310cat > $CONFIG_STATUS <<EOF
10311#! /bin/sh
10312# Generated automatically by configure.
10313# Run this file to recreate the current configuration.
10314# This directory was configured as follows,
10315# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
10316#
10317# $0 $ac_configure_args
10318#
10319# Compiler output produced by configure, useful for debugging
10320# configure, is in ./config.log if it exists.
10321
10322ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
10323for ac_option
10324do
10325  case "\$ac_option" in
10326  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
10327    echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
10328    exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
10329  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
10330    echo "$CONFIG_STATUS generated by autoconf version 2.13"
10331    exit 0 ;;
10332  -help | --help | --hel | --he | --h)
10333    echo "\$ac_cs_usage"; exit 0 ;;
10334  *) echo "\$ac_cs_usage"; exit 1 ;;
10335  esac
10336done
10337
10338ac_given_srcdir=$srcdir
10339ac_given_INSTALL="$INSTALL"
10340
10341trap 'rm -fr `echo "Makefile adjtimed/Makefile clockstuff/Makefile \
10342include/Makefile kernel/Makefile kernel/sys/Makefile libntp/Makefile \
10343libparse/Makefile librsaref/Makefile ntpd/Makefile ntpdc/Makefile \
10344ntpdate/Makefile ntpq/Makefile ntptrace/Makefile parseutil/Makefile \
10345scripts/Makefile scripts/mkver scripts/ntpver util/Makefile config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
10346EOF
10347cat >> $CONFIG_STATUS <<EOF
10348
10349# Protect against being on the right side of a sed subst in config.status.
10350sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
10351 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
10352$ac_vpsub
10353$extrasub
10354s%@SHELL@%$SHELL%g
10355s%@CFLAGS@%$CFLAGS%g
10356s%@CPPFLAGS@%$CPPFLAGS%g
10357s%@CXXFLAGS@%$CXXFLAGS%g
10358s%@FFLAGS@%$FFLAGS%g
10359s%@DEFS@%$DEFS%g
10360s%@LDFLAGS@%$LDFLAGS%g
10361s%@LIBS@%$LIBS%g
10362s%@exec_prefix@%$exec_prefix%g
10363s%@prefix@%$prefix%g
10364s%@program_transform_name@%$program_transform_name%g
10365s%@bindir@%$bindir%g
10366s%@sbindir@%$sbindir%g
10367s%@libexecdir@%$libexecdir%g
10368s%@datadir@%$datadir%g
10369s%@sysconfdir@%$sysconfdir%g
10370s%@sharedstatedir@%$sharedstatedir%g
10371s%@localstatedir@%$localstatedir%g
10372s%@libdir@%$libdir%g
10373s%@includedir@%$includedir%g
10374s%@oldincludedir@%$oldincludedir%g
10375s%@infodir@%$infodir%g
10376s%@mandir@%$mandir%g
10377s%@host@%$host%g
10378s%@host_alias@%$host_alias%g
10379s%@host_cpu@%$host_cpu%g
10380s%@host_vendor@%$host_vendor%g
10381s%@host_os@%$host_os%g
10382s%@target@%$target%g
10383s%@target_alias@%$target_alias%g
10384s%@target_cpu@%$target_cpu%g
10385s%@target_vendor@%$target_vendor%g
10386s%@target_os@%$target_os%g
10387s%@build@%$build%g
10388s%@build_alias@%$build_alias%g
10389s%@build_cpu@%$build_cpu%g
10390s%@build_vendor@%$build_vendor%g
10391s%@build_os@%$build_os%g
10392s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
10393s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
10394s%@INSTALL_DATA@%$INSTALL_DATA%g
10395s%@PACKAGE@%$PACKAGE%g
10396s%@VERSION@%$VERSION%g
10397s%@ACLOCAL@%$ACLOCAL%g
10398s%@AUTOCONF@%$AUTOCONF%g
10399s%@AUTOMAKE@%$AUTOMAKE%g
10400s%@AUTOHEADER@%$AUTOHEADER%g
10401s%@MAKEINFO@%$MAKEINFO%g
10402s%@AMTAR@%$AMTAR%g
10403s%@install_sh@%$install_sh%g
10404s%@AWK@%$AWK%g
10405s%@SET_MAKE@%$SET_MAKE%g
10406s%@AMDEP@%$AMDEP%g
10407s%@AMDEPBACKSLASH@%$AMDEPBACKSLASH%g
10408s%@DEPDIR@%$DEPDIR%g
10409s%@CC@%$CC%g
10410s%@CPP@%$CPP%g
10411s%@CCDEPMODE@%$CCDEPMODE%g
10412s%@LN_S@%$LN_S%g
10413s%@RANLIB@%$RANLIB%g
10414s%@PATH_SH@%$PATH_SH%g
10415s%@U@%$U%g
10416s%@ANSI2KNR@%$ANSI2KNR%g
10417s%@LIBOBJS@%$LIBOBJS%g
10418s%@LIBPARSE@%$LIBPARSE%g
10419s%@MAKE_LIBPARSE@%$MAKE_LIBPARSE%g
10420s%@MAKE_LIBPARSE_KERNEL@%$MAKE_LIBPARSE_KERNEL%g
10421s%@MAKE_CHECK_Y2K@%$MAKE_CHECK_Y2K%g
10422s%@RSAREF@%$RSAREF%g
10423s%@LIBRSAREF@%$LIBRSAREF%g
10424s%@MAKE_LIBRSAREF@%$MAKE_LIBRSAREF%g
10425s%@TESTDCF@%$TESTDCF%g
10426s%@DCFD@%$DCFD%g
10427s%@MAKE_PARSEKMODULE@%$MAKE_PARSEKMODULE%g
10428s%@PROPDELAY@%$PROPDELAY%g
10429s%@CHUTEST@%$CHUTEST%g
10430s%@CLKTEST@%$CLKTEST%g
10431s%@MAKE_ADJTIMED@%$MAKE_ADJTIMED%g
10432s%@MAKE_TICKADJ@%$MAKE_TICKADJ%g
10433s%@MAKE_NTPTIME@%$MAKE_NTPTIME%g
10434
10435CEOF
10436EOF
10437
10438cat >> $CONFIG_STATUS <<\EOF
10439
10440# Split the substitutions into bite-sized pieces for seds with
10441# small command number limits, like on Digital OSF/1 and HP-UX.
10442ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
10443ac_file=1 # Number of current file.
10444ac_beg=1 # First line for current file.
10445ac_end=$ac_max_sed_cmds # Line after last line for current file.
10446ac_more_lines=:
10447ac_sed_cmds=""
10448while $ac_more_lines; do
10449  if test $ac_beg -gt 1; then
10450    sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
10451  else
10452    sed "${ac_end}q" conftest.subs > conftest.s$ac_file
10453  fi
10454  if test ! -s conftest.s$ac_file; then
10455    ac_more_lines=false
10456    rm -f conftest.s$ac_file
10457  else
10458    if test -z "$ac_sed_cmds"; then
10459      ac_sed_cmds="sed -f conftest.s$ac_file"
10460    else
10461      ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
10462    fi
10463    ac_file=`expr $ac_file + 1`
10464    ac_beg=$ac_end
10465    ac_end=`expr $ac_end + $ac_max_sed_cmds`
10466  fi
10467done
10468if test -z "$ac_sed_cmds"; then
10469  ac_sed_cmds=cat
10470fi
10471EOF
10472
10473cat >> $CONFIG_STATUS <<EOF
10474
10475CONFIG_FILES=\${CONFIG_FILES-"Makefile adjtimed/Makefile clockstuff/Makefile \
10476include/Makefile kernel/Makefile kernel/sys/Makefile libntp/Makefile \
10477libparse/Makefile librsaref/Makefile ntpd/Makefile ntpdc/Makefile \
10478ntpdate/Makefile ntpq/Makefile ntptrace/Makefile parseutil/Makefile \
10479scripts/Makefile scripts/mkver scripts/ntpver util/Makefile"}
10480EOF
10481cat >> $CONFIG_STATUS <<\EOF
10482for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
10483  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
10484  case "$ac_file" in
10485  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
10486       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
10487  *) ac_file_in="${ac_file}.in" ;;
10488  esac
10489
10490  # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
10491
10492  # Remove last slash and all that follows it.  Not all systems have dirname.
10493  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
10494  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
10495    # The file is in a subdirectory.
10496    test ! -d "$ac_dir" && mkdir "$ac_dir"
10497    ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
10498    # A "../" for each directory in $ac_dir_suffix.
10499    ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
10500  else
10501    ac_dir_suffix= ac_dots=
10502  fi
10503
10504  case "$ac_given_srcdir" in
10505  .)  srcdir=.
10506      if test -z "$ac_dots"; then top_srcdir=.
10507      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
10508  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
10509  *) # Relative path.
10510    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
10511    top_srcdir="$ac_dots$ac_given_srcdir" ;;
10512  esac
10513
10514  case "$ac_given_INSTALL" in
10515  [/$]*) INSTALL="$ac_given_INSTALL" ;;
10516  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
10517  esac
10518
10519  echo creating "$ac_file"
10520  rm -f "$ac_file"
10521  configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
10522  case "$ac_file" in
10523  *Makefile*) ac_comsub="1i\\
10524# $configure_input" ;;
10525  *) ac_comsub= ;;
10526  esac
10527
10528  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
10529  sed -e "$ac_comsub
10530s%@configure_input@%$configure_input%g
10531s%@srcdir@%$srcdir%g
10532s%@top_srcdir@%$top_srcdir%g
10533s%@INSTALL@%$INSTALL%g
10534" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
10535fi; done
10536rm -f conftest.s*
10537
10538# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
10539# NAME is the cpp macro being defined and VALUE is the value it is being given.
10540#
10541# ac_d sets the value in "#define NAME VALUE" lines.
10542ac_dA='s%^\([ 	]*\)#\([ 	]*define[ 	][ 	]*\)'
10543ac_dB='\([ 	][ 	]*\)[^ 	]*%\1#\2'
10544ac_dC='\3'
10545ac_dD='%g'
10546# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
10547ac_uA='s%^\([ 	]*\)#\([ 	]*\)undef\([ 	][ 	]*\)'
10548ac_uB='\([ 	]\)%\1#\2define\3'
10549ac_uC=' '
10550ac_uD='\4%g'
10551# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
10552ac_eA='s%^\([ 	]*\)#\([ 	]*\)undef\([ 	][ 	]*\)'
10553ac_eB='$%\1#\2define\3'
10554ac_eC=' '
10555ac_eD='%g'
10556
10557if test "${CONFIG_HEADERS+set}" != set; then
10558EOF
10559cat >> $CONFIG_STATUS <<EOF
10560  CONFIG_HEADERS="config.h"
10561EOF
10562cat >> $CONFIG_STATUS <<\EOF
10563fi
10564for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
10565  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
10566  case "$ac_file" in
10567  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
10568       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
10569  *) ac_file_in="${ac_file}.in" ;;
10570  esac
10571
10572  echo creating $ac_file
10573
10574  rm -f conftest.frag conftest.in conftest.out
10575  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
10576  cat $ac_file_inputs > conftest.in
10577
10578EOF
10579
10580# Transform confdefs.h into a sed script conftest.vals that substitutes
10581# the proper values into config.h.in to produce config.h.  And first:
10582# Protect against being on the right side of a sed subst in config.status.
10583# Protect against being in an unquoted here document in config.status.
10584rm -f conftest.vals
10585cat > conftest.hdr <<\EOF
10586s/[\\&%]/\\&/g
10587s%[\\$`]%\\&%g
10588s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
10589s%ac_d%ac_u%gp
10590s%ac_u%ac_e%gp
10591EOF
10592sed -n -f conftest.hdr confdefs.h > conftest.vals
10593rm -f conftest.hdr
10594
10595# This sed command replaces #undef with comments.  This is necessary, for
10596# example, in the case of _POSIX_SOURCE, which is predefined and required
10597# on some systems where configure will not decide to define it.
10598cat >> conftest.vals <<\EOF
10599s%^[ 	]*#[ 	]*undef[ 	][ 	]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
10600EOF
10601
10602# Break up conftest.vals because some shells have a limit on
10603# the size of here documents, and old seds have small limits too.
10604
10605rm -f conftest.tail
10606while :
10607do
10608  ac_lines=`grep -c . conftest.vals`
10609  # grep -c gives empty output for an empty file on some AIX systems.
10610  if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
10611  # Write a limited-size here document to conftest.frag.
10612  echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
10613  sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
10614  echo 'CEOF
10615  sed -f conftest.frag conftest.in > conftest.out
10616  rm -f conftest.in
10617  mv conftest.out conftest.in
10618' >> $CONFIG_STATUS
10619  sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
10620  rm -f conftest.vals
10621  mv conftest.tail conftest.vals
10622done
10623rm -f conftest.vals
10624
10625cat >> $CONFIG_STATUS <<\EOF
10626  rm -f conftest.frag conftest.h
10627  echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
10628  cat conftest.in >> conftest.h
10629  rm -f conftest.in
10630  if cmp -s $ac_file conftest.h 2>/dev/null; then
10631    echo "$ac_file is unchanged"
10632    rm -f conftest.h
10633  else
10634    # Remove last slash and all that follows it.  Not all systems have dirname.
10635      ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
10636      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
10637      # The file is in a subdirectory.
10638      test ! -d "$ac_dir" && mkdir "$ac_dir"
10639    fi
10640    rm -f $ac_file
10641    mv conftest.h $ac_file
10642  fi
10643fi; done
10644
10645EOF
10646cat >> $CONFIG_STATUS <<EOF
10647
10648AMDEP="$AMDEP"
10649ac_aux_dir="$ac_aux_dir"
10650
10651EOF
10652cat >> $CONFIG_STATUS <<\EOF
10653test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h
10654
10655test x"$AMDEP" != x"" ||
10656for mf in $CONFIG_FILES; do
10657  case "$mf" in
10658  Makefile) dirpart=.;;
10659  */Makefile) dirpart=`echo "$mf" | sed -e 's|/[^/]*$||'`;;
10660  *) continue;;
10661  esac
10662  grep '^DEP_FILES *= *[^ #]' < "$mf" > /dev/null || continue
10663  # Extract the definition of DEP_FILES from the Makefile without
10664  # running `make'.
10665  DEPDIR=`sed -n -e '/^DEPDIR = / s///p' < "$mf"`
10666  test -z "$DEPDIR" && continue
10667  # When using ansi2knr, U may be empty or an underscore; expand it
10668  U=`sed -n -e '/^U = / s///p' < "$mf"`
10669  test -d "$dirpart/$DEPDIR" || mkdir "$dirpart/$DEPDIR"
10670  # We invoke sed twice because it is the simplest approach to
10671  # changing $(DEPDIR) to its actual value in the expansion.
10672  for file in `sed -n -e '
10673    /^DEP_FILES = .*\\\\$/ {
10674      s/^DEP_FILES = //
10675      :loop
10676	s/\\\\$//
10677	p
10678	n
10679	/\\\\$/ b loop
10680      p
10681    }
10682    /^DEP_FILES = / s/^DEP_FILES = //p' < "$mf" | \
10683       sed -e 's/\$(DEPDIR)/'"$DEPDIR"'/g' -e 's/\$U/'"$U"'/g'`; do
10684    # Make sure the directory exists.
10685    test -f "$dirpart/$file" && continue
10686    fdir=`echo "$file" | sed -e 's|/[^/]*$||'`
10687    $ac_aux_dir/mkinstalldirs "$dirpart/$fdir" > /dev/null 2>&1
10688    # echo "creating $dirpart/$file"
10689    echo '# dummy' > "$dirpart/$file"
10690  done
10691done
10692
10693chmod +x scripts/ntpver scripts/mkver
10694exit 0
10695EOF
10696chmod +x $CONFIG_STATUS
10697rm -fr confdefs* $ac_clean_files
10698test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
10699
10700#test -z "$CONFIG_HEADERS" || echo timestamp > stamp-h])
10701