source: trunk/third/nmh/configure @ 19073

Revision 19073, 117.3 KB checked in by ghudson, 21 years ago (diff)
Red Hat 8.1's ndbm interface requires -ldb.
  • Property svn:executable set to *
Line 
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  --with-mts=MTS          specify the mail transport agent"
16ac_help="$ac_help
17  --with-editor=EDITOR    specify the default editor"
18ac_help="$ac_help
19  --with-pager=PAGER      specify the default pager"
20ac_help="$ac_help
21  --enable-nmh-mhe        enable mhe support (DEFAULT)"
22ac_help="$ac_help
23  --enable-nmh-pop        enable client-side support for pop"
24ac_help="$ac_help
25  --with-krb4=PREFIX      specify location of Kerberos V4 for kpop support"
26ac_help="$ac_help
27  --with-hesiod=PREFIX    specify location of Hesiod"
28ac_help="$ac_help
29  --enable-nmh-debug      enable nmh code debugging"
30ac_default_prefix=/usr/local/nmh
31
32# Initialize some variables set by options.
33# The variables have the same names as the options, with
34# dashes changed to underlines.
35build=NONE
36cache_file=./config.cache
37exec_prefix=NONE
38host=NONE
39no_create=
40nonopt=NONE
41no_recursion=
42prefix=NONE
43program_prefix=NONE
44program_suffix=NONE
45program_transform_name=s,x,x,
46silent=
47site=
48srcdir=
49target=NONE
50verbose=
51x_includes=NONE
52x_libraries=NONE
53bindir='${exec_prefix}/bin'
54sbindir='${exec_prefix}/sbin'
55libexecdir='${exec_prefix}/libexec'
56datadir='${prefix}/share'
57sysconfdir='${prefix}/etc'
58sharedstatedir='${prefix}/com'
59localstatedir='${prefix}/var'
60libdir='${exec_prefix}/lib'
61includedir='${prefix}/include'
62oldincludedir='/usr/include'
63infodir='${prefix}/info'
64mandir='${prefix}/man'
65
66# Initialize some other variables.
67subdirs=
68MFLAGS= MAKEFLAGS=
69SHELL=${CONFIG_SHELL-/bin/sh}
70# Maximum number of lines to put in a shell here document.
71ac_max_here_lines=12
72
73ac_prev=
74for ac_option
75do
76
77  # If the previous option needs an argument, assign it.
78  if test -n "$ac_prev"; then
79    eval "$ac_prev=\$ac_option"
80    ac_prev=
81    continue
82  fi
83
84  case "$ac_option" in
85  -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
86  *) ac_optarg= ;;
87  esac
88
89  # Accept the important Cygnus configure options, so we can diagnose typos.
90
91  case "$ac_option" in
92
93  -bindir | --bindir | --bindi | --bind | --bin | --bi)
94    ac_prev=bindir ;;
95  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
96    bindir="$ac_optarg" ;;
97
98  -build | --build | --buil | --bui | --bu)
99    ac_prev=build ;;
100  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
101    build="$ac_optarg" ;;
102
103  -cache-file | --cache-file | --cache-fil | --cache-fi \
104  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
105    ac_prev=cache_file ;;
106  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
107  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
108    cache_file="$ac_optarg" ;;
109
110  -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
111    ac_prev=datadir ;;
112  -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
113  | --da=*)
114    datadir="$ac_optarg" ;;
115
116  -disable-* | --disable-*)
117    ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
118    # Reject names that are not valid shell variable names.
119    if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
120      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
121    fi
122    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
123    eval "enable_${ac_feature}=no" ;;
124
125  -enable-* | --enable-*)
126    ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
127    # Reject names that are not valid shell variable names.
128    if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
129      { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
130    fi
131    ac_feature=`echo $ac_feature| sed 's/-/_/g'`
132    case "$ac_option" in
133      *=*) ;;
134      *) ac_optarg=yes ;;
135    esac
136    eval "enable_${ac_feature}='$ac_optarg'" ;;
137
138  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
139  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
140  | --exec | --exe | --ex)
141    ac_prev=exec_prefix ;;
142  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
143  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
144  | --exec=* | --exe=* | --ex=*)
145    exec_prefix="$ac_optarg" ;;
146
147  -gas | --gas | --ga | --g)
148    # Obsolete; use --with-gas.
149    with_gas=yes ;;
150
151  -help | --help | --hel | --he)
152    # Omit some internal or obsolete options to make the list less imposing.
153    # This message is too long to be a string in the A/UX 3.1 sh.
154    cat << EOF
155Usage: configure [options] [host]
156Options: [defaults in brackets after descriptions]
157Configuration:
158  --cache-file=FILE       cache test results in FILE
159  --help                  print this message
160  --no-create             do not create output files
161  --quiet, --silent       do not print \`checking...' messages
162  --version               print the version of autoconf that created configure
163Directory and file names:
164  --prefix=PREFIX         install architecture-independent files in PREFIX
165                          [$ac_default_prefix]
166  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
167                          [same as prefix]
168  --bindir=DIR            user executables in DIR [EPREFIX/bin]
169  --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
170  --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
171  --datadir=DIR           read-only architecture-independent data in DIR
172                          [PREFIX/share]
173  --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
174  --sharedstatedir=DIR    modifiable architecture-independent data in DIR
175                          [PREFIX/com]
176  --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
177  --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
178  --includedir=DIR        C header files in DIR [PREFIX/include]
179  --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
180  --infodir=DIR           info documentation in DIR [PREFIX/info]
181  --mandir=DIR            man documentation in DIR [PREFIX/man]
182  --srcdir=DIR            find the sources in DIR [configure dir or ..]
183  --program-prefix=PREFIX prepend PREFIX to installed program names
184  --program-suffix=SUFFIX append SUFFIX to installed program names
185  --program-transform-name=PROGRAM
186                          run sed PROGRAM on installed program names
187EOF
188    cat << EOF
189Host type:
190  --build=BUILD           configure for building on BUILD [BUILD=HOST]
191  --host=HOST             configure for HOST [guessed]
192  --target=TARGET         configure for TARGET [TARGET=HOST]
193Features and packages:
194  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
195  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
196  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
197  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
198  --x-includes=DIR        X include files are in DIR
199  --x-libraries=DIR       X library files are in DIR
200EOF
201    if test -n "$ac_help"; then
202      echo "--enable and --with options recognized:$ac_help"
203    fi
204    exit 0 ;;
205
206  -host | --host | --hos | --ho)
207    ac_prev=host ;;
208  -host=* | --host=* | --hos=* | --ho=*)
209    host="$ac_optarg" ;;
210
211  -includedir | --includedir | --includedi | --included | --include \
212  | --includ | --inclu | --incl | --inc)
213    ac_prev=includedir ;;
214  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
215  | --includ=* | --inclu=* | --incl=* | --inc=*)
216    includedir="$ac_optarg" ;;
217
218  -infodir | --infodir | --infodi | --infod | --info | --inf)
219    ac_prev=infodir ;;
220  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
221    infodir="$ac_optarg" ;;
222
223  -libdir | --libdir | --libdi | --libd)
224    ac_prev=libdir ;;
225  -libdir=* | --libdir=* | --libdi=* | --libd=*)
226    libdir="$ac_optarg" ;;
227
228  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
229  | --libexe | --libex | --libe)
230    ac_prev=libexecdir ;;
231  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
232  | --libexe=* | --libex=* | --libe=*)
233    libexecdir="$ac_optarg" ;;
234
235  -localstatedir | --localstatedir | --localstatedi | --localstated \
236  | --localstate | --localstat | --localsta | --localst \
237  | --locals | --local | --loca | --loc | --lo)
238    ac_prev=localstatedir ;;
239  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
240  | --localstate=* | --localstat=* | --localsta=* | --localst=* \
241  | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
242    localstatedir="$ac_optarg" ;;
243
244  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
245    ac_prev=mandir ;;
246  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
247    mandir="$ac_optarg" ;;
248
249  -nfp | --nfp | --nf)
250    # Obsolete; use --without-fp.
251    with_fp=no ;;
252
253  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
254  | --no-cr | --no-c)
255    no_create=yes ;;
256
257  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
258  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
259    no_recursion=yes ;;
260
261  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
262  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
263  | --oldin | --oldi | --old | --ol | --o)
264    ac_prev=oldincludedir ;;
265  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
266  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
267  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
268    oldincludedir="$ac_optarg" ;;
269
270  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
271    ac_prev=prefix ;;
272  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
273    prefix="$ac_optarg" ;;
274
275  -program-prefix | --program-prefix | --program-prefi | --program-pref \
276  | --program-pre | --program-pr | --program-p)
277    ac_prev=program_prefix ;;
278  -program-prefix=* | --program-prefix=* | --program-prefi=* \
279  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
280    program_prefix="$ac_optarg" ;;
281
282  -program-suffix | --program-suffix | --program-suffi | --program-suff \
283  | --program-suf | --program-su | --program-s)
284    ac_prev=program_suffix ;;
285  -program-suffix=* | --program-suffix=* | --program-suffi=* \
286  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
287    program_suffix="$ac_optarg" ;;
288
289  -program-transform-name | --program-transform-name \
290  | --program-transform-nam | --program-transform-na \
291  | --program-transform-n | --program-transform- \
292  | --program-transform | --program-transfor \
293  | --program-transfo | --program-transf \
294  | --program-trans | --program-tran \
295  | --progr-tra | --program-tr | --program-t)
296    ac_prev=program_transform_name ;;
297  -program-transform-name=* | --program-transform-name=* \
298  | --program-transform-nam=* | --program-transform-na=* \
299  | --program-transform-n=* | --program-transform-=* \
300  | --program-transform=* | --program-transfor=* \
301  | --program-transfo=* | --program-transf=* \
302  | --program-trans=* | --program-tran=* \
303  | --progr-tra=* | --program-tr=* | --program-t=*)
304    program_transform_name="$ac_optarg" ;;
305
306  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
307  | -silent | --silent | --silen | --sile | --sil)
308    silent=yes ;;
309
310  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
311    ac_prev=sbindir ;;
312  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
313  | --sbi=* | --sb=*)
314    sbindir="$ac_optarg" ;;
315
316  -sharedstatedir | --sharedstatedir | --sharedstatedi \
317  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
318  | --sharedst | --shareds | --shared | --share | --shar \
319  | --sha | --sh)
320    ac_prev=sharedstatedir ;;
321  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
322  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
323  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
324  | --sha=* | --sh=*)
325    sharedstatedir="$ac_optarg" ;;
326
327  -site | --site | --sit)
328    ac_prev=site ;;
329  -site=* | --site=* | --sit=*)
330    site="$ac_optarg" ;;
331
332  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
333    ac_prev=srcdir ;;
334  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
335    srcdir="$ac_optarg" ;;
336
337  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
338  | --syscon | --sysco | --sysc | --sys | --sy)
339    ac_prev=sysconfdir ;;
340  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
341  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
342    sysconfdir="$ac_optarg" ;;
343
344  -target | --target | --targe | --targ | --tar | --ta | --t)
345    ac_prev=target ;;
346  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
347    target="$ac_optarg" ;;
348
349  -v | -verbose | --verbose | --verbos | --verbo | --verb)
350    verbose=yes ;;
351
352  -version | --version | --versio | --versi | --vers)
353    echo "configure generated by autoconf version 2.13"
354    exit 0 ;;
355
356  -with-* | --with-*)
357    ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
358    # Reject names that are not valid shell variable names.
359    if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
360      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
361    fi
362    ac_package=`echo $ac_package| sed 's/-/_/g'`
363    case "$ac_option" in
364      *=*) ;;
365      *) ac_optarg=yes ;;
366    esac
367    eval "with_${ac_package}='$ac_optarg'" ;;
368
369  -without-* | --without-*)
370    ac_package=`echo $ac_option|sed -e 's/-*without-//'`
371    # Reject names that are not valid shell variable names.
372    if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
373      { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
374    fi
375    ac_package=`echo $ac_package| sed 's/-/_/g'`
376    eval "with_${ac_package}=no" ;;
377
378  --x)
379    # Obsolete; use --with-x.
380    with_x=yes ;;
381
382  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
383  | --x-incl | --x-inc | --x-in | --x-i)
384    ac_prev=x_includes ;;
385  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
386  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
387    x_includes="$ac_optarg" ;;
388
389  -x-libraries | --x-libraries | --x-librarie | --x-librari \
390  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
391    ac_prev=x_libraries ;;
392  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
393  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
394    x_libraries="$ac_optarg" ;;
395
396  -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
397    ;;
398
399  *)
400    if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
401      echo "configure: warning: $ac_option: invalid host type" 1>&2
402    fi
403    if test "x$nonopt" != xNONE; then
404      { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
405    fi
406    nonopt="$ac_option"
407    ;;
408
409  esac
410done
411
412if test -n "$ac_prev"; then
413  { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
414fi
415
416trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
417
418# File descriptor usage:
419# 0 standard input
420# 1 file creation
421# 2 errors and warnings
422# 3 some systems may open it to /dev/tty
423# 4 used on the Kubota Titan
424# 6 checking for... messages and results
425# 5 compiler messages saved in config.log
426if test "$silent" = yes; then
427  exec 6>/dev/null
428else
429  exec 6>&1
430fi
431exec 5>./config.log
432
433echo "\
434This file contains any messages produced by compilers while
435running configure, to aid debugging if configure makes a mistake.
436" 1>&5
437
438# Strip out --no-create and --no-recursion so they do not pile up.
439# Also quote any args containing shell metacharacters.
440ac_configure_args=
441for ac_arg
442do
443  case "$ac_arg" in
444  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
445  | --no-cr | --no-c) ;;
446  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
447  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
448  *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
449  ac_configure_args="$ac_configure_args '$ac_arg'" ;;
450  *) ac_configure_args="$ac_configure_args $ac_arg" ;;
451  esac
452done
453
454# NLS nuisances.
455# Only set these to C if already set.  These must not be set unconditionally
456# because not all systems understand e.g. LANG=C (notably SCO).
457# Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
458# Non-C LC_CTYPE values break the ctype check.
459if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
460if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
461if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
462if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
463
464# confdefs.h avoids OS command line length limits that DEFS can exceed.
465rm -rf conftest* confdefs.h
466# AIX cpp loses on an empty file, so make sure it contains at least a newline.
467echo > confdefs.h
468
469# A filename unique to this package, relative to the directory that
470# configure is in, which we can look for to find out if srcdir is correct.
471ac_unique_file=h/nmh.h
472
473# Find the source files, if location was not specified.
474if test -z "$srcdir"; then
475  ac_srcdir_defaulted=yes
476  # Try the directory containing this script, then its parent.
477  ac_prog=$0
478  ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
479  test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
480  srcdir=$ac_confdir
481  if test ! -r $srcdir/$ac_unique_file; then
482    srcdir=..
483  fi
484else
485  ac_srcdir_defaulted=no
486fi
487if test ! -r $srcdir/$ac_unique_file; then
488  if test "$ac_srcdir_defaulted" = yes; then
489    { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
490  else
491    { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
492  fi
493fi
494srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
495
496# Prefer explicitly selected file to automatically selected ones.
497if test -z "$CONFIG_SITE"; then
498  if test "x$prefix" != xNONE; then
499    CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
500  else
501    CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
502  fi
503fi
504for ac_site_file in $CONFIG_SITE; do
505  if test -r "$ac_site_file"; then
506    echo "loading site script $ac_site_file"
507    . "$ac_site_file"
508  fi
509done
510
511if test -r "$cache_file"; then
512  echo "loading cache $cache_file"
513  . $cache_file
514else
515  echo "creating cache $cache_file"
516  > $cache_file
517fi
518
519ac_ext=c
520# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
521ac_cpp='$CPP $CPPFLAGS'
522ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
523ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
524cross_compiling=$ac_cv_prog_cc_cross
525
526ac_exeext=
527ac_objext=o
528if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
529  # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
530  if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
531    ac_n= ac_c='
532' ac_t='        '
533  else
534    ac_n=-n ac_c= ac_t=
535  fi
536else
537  ac_n= ac_c='\c' ac_t=
538fi
539
540
541
542
543VERSION=`sed -e 's/nmh-//' ${srcdir}/VERSION`
544echo "configuring for nmh-$VERSION"
545
546# Check whether --with-mts or --without-mts was given.
547if test "${with_mts+set}" = set; then
548  withval="$with_mts"
549  :
550fi
551
552
553if test x$with_mts = xsmtp; then
554  MTS="smtp"
555  MTSLIB="mts/smtp/libsmtp.a"
556  cat >> confdefs.h <<\EOF
557#define SMTPMTS 1
558EOF
559elif test x$with_mts = xsendmail; then
560  MTS="sendmail"
561  MTSLIB="mts/sendmail/libsend.a"
562  cat >> confdefs.h <<\EOF
563#define SENDMTS 1
564EOF
565else
566  MTS="smtp"
567  MTSLIB="mts/smtp/libsmtp.a"
568  cat >> confdefs.h <<\EOF
569#define SMTPMTS 1
570EOF
571fi
572
573
574
575
576# Check whether --with-editor or --without-editor was given.
577if test "${with_editor+set}" = set; then
578  withval="$with_editor"
579  :
580fi
581
582
583if test -n "$with_editor"; then
584  editorpath="$with_editor"
585fi
586
587# Check whether --with-pager or --without-pager was given.
588if test "${with_pager+set}" = set; then
589  withval="$with_pager"
590  :
591fi
592
593
594if test -n "$with_pager"; then
595  pagerpath="$with_pager"
596fi
597
598# Check whether --enable-nmh-mhe or --disable-nmh-mhe was given.
599if test "${enable_nmh_mhe+set}" = set; then
600  enableval="$enable_nmh_mhe"
601  :
602fi
603
604
605if test x$enable_nmh_mhe != xno; then
606  cat >> confdefs.h <<\EOF
607#define MHE 1
608EOF
609fi
610
611# Check whether --enable-nmh-pop or --disable-nmh-pop was given.
612if test "${enable_nmh_pop+set}" = set; then
613  enableval="$enable_nmh_pop"
614  :
615fi
616
617if test x$enable_nmh_pop = xyes; then
618  cat >> confdefs.h <<\EOF
619#define POP 1
620EOF
621  POPLIB=popsbr.o
622  POPSED='/^%nmhbeginpop%/d;/^%nmhendpop%/d'
623else
624  POPSED='/^%nmhbeginpop%/,/^%nmhendpop%/d'
625fi
626
627# Check whether --with-krb4 or --without-krb4 was given.
628if test "${with_krb4+set}" = set; then
629  withval="$with_krb4"
630  :
631fi
632
633if test x$with_krb4 != x -a x$with_krb4 != xno; then
634  cat >> confdefs.h <<\EOF
635#define KPOP 1
636EOF
637  cat >> confdefs.h <<\EOF
638#define KPOP_PRINCIPAL "pop"
639EOF
640fi
641
642# Check whether --with-hesiod or --without-hesiod was given.
643if test "${with_hesiod+set}" = set; then
644  withval="$with_hesiod"
645  :
646fi
647
648if test x$with_hesiod != x -a x$with_hesiod != xno; then
649  cat >> confdefs.h <<\EOF
650#define HESIOD 1
651EOF
652fi
653
654# Check whether --enable-nmh-debug or --disable-nmh-debug was given.
655if test "${enable_nmh_debug+set}" = set; then
656  enableval="$enable_nmh_debug"
657  :
658fi
659
660
661
662
663test -z "$CFLAGS" && CFLAGS= auto_cflags=1
664if test x$enable_nmh_debug = xyes; then
665  test -z "$LDFLAGS" && LDFLAGS=-g
666fi
667
668# Extract the first word of "gcc", so it can be a program name with args.
669set dummy gcc; ac_word=$2
670echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
671echo "configure:672: checking for $ac_word" >&5
672if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
673  echo $ac_n "(cached) $ac_c" 1>&6
674else
675  if test -n "$CC"; then
676  ac_cv_prog_CC="$CC" # Let the user override the test.
677else
678  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
679  ac_dummy="$PATH"
680  for ac_dir in $ac_dummy; do
681    test -z "$ac_dir" && ac_dir=.
682    if test -f $ac_dir/$ac_word; then
683      ac_cv_prog_CC="gcc"
684      break
685    fi
686  done
687  IFS="$ac_save_ifs"
688fi
689fi
690CC="$ac_cv_prog_CC"
691if test -n "$CC"; then
692  echo "$ac_t""$CC" 1>&6
693else
694  echo "$ac_t""no" 1>&6
695fi
696
697if test -z "$CC"; then
698  # Extract the first word of "cc", so it can be a program name with args.
699set dummy cc; ac_word=$2
700echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
701echo "configure:702: checking for $ac_word" >&5
702if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
703  echo $ac_n "(cached) $ac_c" 1>&6
704else
705  if test -n "$CC"; then
706  ac_cv_prog_CC="$CC" # Let the user override the test.
707else
708  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
709  ac_prog_rejected=no
710  ac_dummy="$PATH"
711  for ac_dir in $ac_dummy; do
712    test -z "$ac_dir" && ac_dir=.
713    if test -f $ac_dir/$ac_word; then
714      if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
715        ac_prog_rejected=yes
716        continue
717      fi
718      ac_cv_prog_CC="cc"
719      break
720    fi
721  done
722  IFS="$ac_save_ifs"
723if test $ac_prog_rejected = yes; then
724  # We found a bogon in the path, so make sure we never use it.
725  set dummy $ac_cv_prog_CC
726  shift
727  if test $# -gt 0; then
728    # We chose a different compiler from the bogus one.
729    # However, it has the same basename, so the bogon will be chosen
730    # first if we set CC to just the basename; use the full file name.
731    shift
732    set dummy "$ac_dir/$ac_word" "$@"
733    shift
734    ac_cv_prog_CC="$@"
735  fi
736fi
737fi
738fi
739CC="$ac_cv_prog_CC"
740if test -n "$CC"; then
741  echo "$ac_t""$CC" 1>&6
742else
743  echo "$ac_t""no" 1>&6
744fi
745
746  if test -z "$CC"; then
747    case "`uname -s`" in
748    *win32* | *WIN32*)
749      # Extract the first word of "cl", so it can be a program name with args.
750set dummy cl; ac_word=$2
751echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
752echo "configure:753: checking for $ac_word" >&5
753if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
754  echo $ac_n "(cached) $ac_c" 1>&6
755else
756  if test -n "$CC"; then
757  ac_cv_prog_CC="$CC" # Let the user override the test.
758else
759  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
760  ac_dummy="$PATH"
761  for ac_dir in $ac_dummy; do
762    test -z "$ac_dir" && ac_dir=.
763    if test -f $ac_dir/$ac_word; then
764      ac_cv_prog_CC="cl"
765      break
766    fi
767  done
768  IFS="$ac_save_ifs"
769fi
770fi
771CC="$ac_cv_prog_CC"
772if test -n "$CC"; then
773  echo "$ac_t""$CC" 1>&6
774else
775  echo "$ac_t""no" 1>&6
776fi
777 ;;
778    esac
779  fi
780  test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
781fi
782
783echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
784echo "configure:785: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
785
786ac_ext=c
787# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
788ac_cpp='$CPP $CPPFLAGS'
789ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
790ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
791cross_compiling=$ac_cv_prog_cc_cross
792
793cat > conftest.$ac_ext << EOF
794
795#line 796 "configure"
796#include "confdefs.h"
797
798main(){return(0);}
799EOF
800if { (eval echo configure:801: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
801  ac_cv_prog_cc_works=yes
802  # If we can't run a trivial program, we are probably using a cross compiler.
803  if (./conftest; exit) 2>/dev/null; then
804    ac_cv_prog_cc_cross=no
805  else
806    ac_cv_prog_cc_cross=yes
807  fi
808else
809  echo "configure: failed program was:" >&5
810  cat conftest.$ac_ext >&5
811  ac_cv_prog_cc_works=no
812fi
813rm -fr conftest*
814ac_ext=c
815# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
816ac_cpp='$CPP $CPPFLAGS'
817ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
818ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
819cross_compiling=$ac_cv_prog_cc_cross
820
821echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
822if test $ac_cv_prog_cc_works = no; then
823  { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
824fi
825echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
826echo "configure:827: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
827echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
828cross_compiling=$ac_cv_prog_cc_cross
829
830echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
831echo "configure:832: checking whether we are using GNU C" >&5
832if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
833  echo $ac_n "(cached) $ac_c" 1>&6
834else
835  cat > conftest.c <<EOF
836#ifdef __GNUC__
837  yes;
838#endif
839EOF
840if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:841: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
841  ac_cv_prog_gcc=yes
842else
843  ac_cv_prog_gcc=no
844fi
845fi
846
847echo "$ac_t""$ac_cv_prog_gcc" 1>&6
848
849if test $ac_cv_prog_gcc = yes; then
850  GCC=yes
851else
852  GCC=
853fi
854
855ac_test_CFLAGS="${CFLAGS+set}"
856ac_save_CFLAGS="$CFLAGS"
857CFLAGS=
858echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
859echo "configure:860: checking whether ${CC-cc} accepts -g" >&5
860if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
861  echo $ac_n "(cached) $ac_c" 1>&6
862else
863  echo 'void f(){}' > conftest.c
864if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
865  ac_cv_prog_cc_g=yes
866else
867  ac_cv_prog_cc_g=no
868fi
869rm -f conftest*
870
871fi
872
873echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
874if test "$ac_test_CFLAGS" = set; then
875  CFLAGS="$ac_save_CFLAGS"
876elif test $ac_cv_prog_cc_g = yes; then
877  if test "$GCC" = yes; then
878    CFLAGS="-g -O2"
879  else
880    CFLAGS="-g"
881  fi
882else
883  if test "$GCC" = yes; then
884    CFLAGS="-O2"
885  else
886    CFLAGS=
887  fi
888fi
889
890
891if test -n "$auto_cflags"; then
892  if test x$enable_nmh_debug = xyes; then
893    if test -n "$GCC"; then
894      test -z "$CFLAGS" && CFLAGS="-Wall -g" || CFLAGS="$CFLAGS -Wall -g"
895    else
896      test -z "$CFLAGS" && CFLAGS=-g || CFLAGS="$CFLAGS -g"
897    fi
898  else
899    test -z "$LDFLAGS" && LDFLAGS=-s
900    if test -n "$GCC"; then
901      test -z "$CFLAGS" && CFLAGS=-O2 || CFLAGS="$CFLAGS -O2"
902    else
903      test -z "$CFLAGS" && CFLAGS=-O  || CFLAGS="$CFLAGS -O"
904    fi
905  fi
906fi
907
908echo $ac_n "checking for working const""... $ac_c" 1>&6
909echo "configure:910: checking for working const" >&5
910if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
911  echo $ac_n "(cached) $ac_c" 1>&6
912else
913  cat > conftest.$ac_ext <<EOF
914#line 915 "configure"
915#include "confdefs.h"
916
917int main() {
918
919/* Ultrix mips cc rejects this.  */
920typedef int charset[2]; const charset x;
921/* SunOS 4.1.1 cc rejects this.  */
922char const *const *ccp;
923char **p;
924/* NEC SVR4.0.2 mips cc rejects this.  */
925struct point {int x, y;};
926static struct point const zero = {0,0};
927/* AIX XL C 1.02.0.0 rejects this.
928   It does not let you subtract one const X* pointer from another in an arm
929   of an if-expression whose if-part is not a constant expression */
930const char *g = "string";
931ccp = &g + (g ? g-g : 0);
932/* HPUX 7.0 cc rejects these. */
933++ccp;
934p = (char**) ccp;
935ccp = (char const *const *) p;
936{ /* SCO 3.2v4 cc rejects this.  */
937  char *t;
938  char const *s = 0 ? (char *) 0 : (char const *) 0;
939
940  *t++ = 0;
941}
942{ /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
943  int x[] = {25, 17};
944  const int *foo = &x[0];
945  ++foo;
946}
947{ /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
948  typedef const int *iptr;
949  iptr p = 0;
950  ++p;
951}
952{ /* AIX XL C 1.02.0.0 rejects this saying
953     "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
954  struct s { int j; const int *ap[3]; };
955  struct s *b; b->j = 5;
956}
957{ /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
958  const int foo = 10;
959}
960
961; return 0; }
962EOF
963if { (eval echo configure:964: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
964  rm -rf conftest*
965  ac_cv_c_const=yes
966else
967  echo "configure: failed program was:" >&5
968  cat conftest.$ac_ext >&5
969  rm -rf conftest*
970  ac_cv_c_const=no
971fi
972rm -f conftest*
973fi
974
975echo "$ac_t""$ac_cv_c_const" 1>&6
976if test $ac_cv_c_const = no; then
977  cat >> confdefs.h <<\EOF
978#define const
979EOF
980
981fi
982             
983echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
984echo "configure:985: checking whether ${MAKE-make} sets \${MAKE}" >&5
985set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
986if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
987  echo $ac_n "(cached) $ac_c" 1>&6
988else
989  cat > conftestmake <<\EOF
990all:
991        @echo 'ac_maketemp="${MAKE}"'
992EOF
993# GNU make sometimes prints "make[1]: Entering...", which would confuse us.
994eval `${MAKE-make} -f conftestmake 2>/dev/null | grep temp=`
995if test -n "$ac_maketemp"; then
996  eval ac_cv_prog_make_${ac_make}_set=yes
997else
998  eval ac_cv_prog_make_${ac_make}_set=no
999fi
1000rm -f conftestmake
1001fi
1002if eval "test \"`echo '$ac_cv_prog_make_'${ac_make}_set`\" = yes"; then
1003  echo "$ac_t""yes" 1>&6
1004  SET_MAKE=
1005else
1006  echo "$ac_t""no" 1>&6
1007  SET_MAKE="MAKE=${MAKE-make}"
1008fi
1009        ac_aux_dir=
1010for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
1011  if test -f $ac_dir/install-sh; then
1012    ac_aux_dir=$ac_dir
1013    ac_install_sh="$ac_aux_dir/install-sh -c"
1014    break
1015  elif test -f $ac_dir/install.sh; then
1016    ac_aux_dir=$ac_dir
1017    ac_install_sh="$ac_aux_dir/install.sh -c"
1018    break
1019  fi
1020done
1021if test -z "$ac_aux_dir"; then
1022  { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
1023fi
1024ac_config_guess=$ac_aux_dir/config.guess
1025ac_config_sub=$ac_aux_dir/config.sub
1026ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
1027
1028# Find a good install program.  We prefer a C program (faster),
1029# so one script is as good as another.  But avoid the broken or
1030# incompatible versions:
1031# SysV /etc/install, /usr/sbin/install
1032# SunOS /usr/etc/install
1033# IRIX /sbin/install
1034# AIX /bin/install
1035# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
1036# AFS /usr/afsws/bin/install, which mishandles nonexistent args
1037# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
1038# ./install, which can be erroneously created by make from ./install.sh.
1039echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
1040echo "configure:1041: checking for a BSD compatible install" >&5
1041if test -z "$INSTALL"; then
1042if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
1043  echo $ac_n "(cached) $ac_c" 1>&6
1044else
1045    IFS="${IFS=         }"; ac_save_IFS="$IFS"; IFS=":"
1046  for ac_dir in $PATH; do
1047    # Account for people who put trailing slashes in PATH elements.
1048    case "$ac_dir/" in
1049    /|./|.//|/etc/*|/usr/sbin/*|/usr/etc/*|/sbin/*|/usr/afsws/bin/*|/usr/ucb/*) ;;
1050    *)
1051      # OSF1 and SCO ODT 3.0 have their own names for install.
1052      # Don't use installbsd from OSF since it installs stuff as root
1053      # by default.
1054      for ac_prog in ginstall scoinst install; do
1055        if test -f $ac_dir/$ac_prog; then
1056          if test $ac_prog = install &&
1057            grep dspmsg $ac_dir/$ac_prog >/dev/null 2>&1; then
1058            # AIX install.  It has an incompatible calling convention.
1059            :
1060          else
1061            ac_cv_path_install="$ac_dir/$ac_prog -c"
1062            break 2
1063          fi
1064        fi
1065      done
1066      ;;
1067    esac
1068  done
1069  IFS="$ac_save_IFS"
1070
1071fi
1072  if test "${ac_cv_path_install+set}" = set; then
1073    INSTALL="$ac_cv_path_install"
1074  else
1075    # As a last resort, use the slow shell script.  We don't cache a
1076    # path for INSTALL within a source directory, because that will
1077    # break other packages using the cache if that directory is
1078    # removed, or if the path is relative.
1079    INSTALL="$ac_install_sh"
1080  fi
1081fi
1082echo "$ac_t""$INSTALL" 1>&6
1083
1084# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
1085# It thinks the first close brace ends the variable substitution.
1086test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
1087
1088test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL_PROGRAM}'
1089
1090test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
1091                # Extract the first word of "ranlib", so it can be a program name with args.
1092set dummy ranlib; 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_RANLIB'+set}'`\" = set"; then
1096  echo $ac_n "(cached) $ac_c" 1>&6
1097else
1098  if test -n "$RANLIB"; then
1099  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
1100else
1101  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1102  ac_dummy="$PATH"
1103  for ac_dir in $ac_dummy; do
1104    test -z "$ac_dir" && ac_dir=.
1105    if test -f $ac_dir/$ac_word; then
1106      ac_cv_prog_RANLIB="ranlib"
1107      break
1108    fi
1109  done
1110  IFS="$ac_save_ifs"
1111  test -z "$ac_cv_prog_RANLIB" && ac_cv_prog_RANLIB=":"
1112fi
1113fi
1114RANLIB="$ac_cv_prog_RANLIB"
1115if test -n "$RANLIB"; then
1116  echo "$ac_t""$RANLIB" 1>&6
1117else
1118  echo "$ac_t""no" 1>&6
1119fi
1120                for ac_prog in mawk gawk nawk awk
1121do
1122# Extract the first word of "$ac_prog", so it can be a program name with args.
1123set dummy $ac_prog; ac_word=$2
1124echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1125echo "configure:1126: checking for $ac_word" >&5
1126if eval "test \"`echo '$''{'ac_cv_prog_AWK'+set}'`\" = set"; then
1127  echo $ac_n "(cached) $ac_c" 1>&6
1128else
1129  if test -n "$AWK"; then
1130  ac_cv_prog_AWK="$AWK" # Let the user override the test.
1131else
1132  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1133  ac_dummy="$PATH"
1134  for ac_dir in $ac_dummy; do
1135    test -z "$ac_dir" && ac_dir=.
1136    if test -f $ac_dir/$ac_word; then
1137      ac_cv_prog_AWK="$ac_prog"
1138      break
1139    fi
1140  done
1141  IFS="$ac_save_ifs"
1142fi
1143fi
1144AWK="$ac_cv_prog_AWK"
1145if test -n "$AWK"; then
1146  echo "$ac_t""$AWK" 1>&6
1147else
1148  echo "$ac_t""no" 1>&6
1149fi
1150
1151test -n "$AWK" && break
1152done
1153             # Extract the first word of "flex", so it can be a program name with args.
1154set dummy flex; ac_word=$2
1155echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1156echo "configure:1157: checking for $ac_word" >&5
1157if eval "test \"`echo '$''{'ac_cv_prog_LEX'+set}'`\" = set"; then
1158  echo $ac_n "(cached) $ac_c" 1>&6
1159else
1160  if test -n "$LEX"; then
1161  ac_cv_prog_LEX="$LEX" # Let the user override the test.
1162else
1163  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1164  ac_dummy="$PATH"
1165  for ac_dir in $ac_dummy; do
1166    test -z "$ac_dir" && ac_dir=.
1167    if test -f $ac_dir/$ac_word; then
1168      ac_cv_prog_LEX="flex"
1169      break
1170    fi
1171  done
1172  IFS="$ac_save_ifs"
1173  test -z "$ac_cv_prog_LEX" && ac_cv_prog_LEX="lex"
1174fi
1175fi
1176LEX="$ac_cv_prog_LEX"
1177if test -n "$LEX"; then
1178  echo "$ac_t""$LEX" 1>&6
1179else
1180  echo "$ac_t""no" 1>&6
1181fi
1182
1183if test -z "$LEXLIB"
1184then
1185  case "$LEX" in
1186  flex*) ac_lib=fl ;;
1187  *) ac_lib=l ;;
1188  esac
1189  echo $ac_n "checking for yywrap in -l$ac_lib""... $ac_c" 1>&6
1190echo "configure:1191: checking for yywrap in -l$ac_lib" >&5
1191ac_lib_var=`echo $ac_lib'_'yywrap | sed 'y%./+-%__p_%'`
1192if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1193  echo $ac_n "(cached) $ac_c" 1>&6
1194else
1195  ac_save_LIBS="$LIBS"
1196LIBS="-l$ac_lib  $LIBS"
1197cat > conftest.$ac_ext <<EOF
1198#line 1199 "configure"
1199#include "confdefs.h"
1200/* Override any gcc2 internal prototype to avoid an error.  */
1201/* We use char because int might match the return type of a gcc2
1202    builtin and then its argument prototype would still apply.  */
1203char yywrap();
1204
1205int main() {
1206yywrap()
1207; return 0; }
1208EOF
1209if { (eval echo configure:1210: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1210  rm -rf conftest*
1211  eval "ac_cv_lib_$ac_lib_var=yes"
1212else
1213  echo "configure: failed program was:" >&5
1214  cat conftest.$ac_ext >&5
1215  rm -rf conftest*
1216  eval "ac_cv_lib_$ac_lib_var=no"
1217fi
1218rm -f conftest*
1219LIBS="$ac_save_LIBS"
1220
1221fi
1222if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1223  echo "$ac_t""yes" 1>&6
1224  LEXLIB="-l$ac_lib"
1225else
1226  echo "$ac_t""no" 1>&6
1227fi
1228
1229fi
1230             
1231# Extract the first word of "lorder", so it can be a program name with args.
1232set dummy lorder; ac_word=$2
1233echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1234echo "configure:1235: checking for $ac_word" >&5
1235if eval "test \"`echo '$''{'ac_cv_prog_LORDER'+set}'`\" = set"; then
1236  echo $ac_n "(cached) $ac_c" 1>&6
1237else
1238  if test -n "$LORDER"; then
1239  ac_cv_prog_LORDER="$LORDER" # Let the user override the test.
1240else
1241  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1242  ac_dummy="$PATH"
1243  for ac_dir in $ac_dummy; do
1244    test -z "$ac_dir" && ac_dir=.
1245    if test -f $ac_dir/$ac_word; then
1246      ac_cv_prog_LORDER="lorder"
1247      break
1248    fi
1249  done
1250  IFS="$ac_save_ifs"
1251  test -z "$ac_cv_prog_LORDER" && ac_cv_prog_LORDER="no"
1252fi
1253fi
1254LORDER="$ac_cv_prog_LORDER"
1255if test -n "$LORDER"; then
1256  echo "$ac_t""$LORDER" 1>&6
1257else
1258  echo "$ac_t""no" 1>&6
1259fi
1260# Extract the first word of "tsort", so it can be a program name with args.
1261set dummy tsort; ac_word=$2
1262echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1263echo "configure:1264: checking for $ac_word" >&5
1264if eval "test \"`echo '$''{'ac_cv_prog_TSORT'+set}'`\" = set"; then
1265  echo $ac_n "(cached) $ac_c" 1>&6
1266else
1267  if test -n "$TSORT"; then
1268  ac_cv_prog_TSORT="$TSORT" # Let the user override the test.
1269else
1270  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1271  ac_dummy="$PATH"
1272  for ac_dir in $ac_dummy; do
1273    test -z "$ac_dir" && ac_dir=.
1274    if test -f $ac_dir/$ac_word; then
1275      ac_cv_prog_TSORT="tsort"
1276      break
1277    fi
1278  done
1279  IFS="$ac_save_ifs"
1280  test -z "$ac_cv_prog_TSORT" && ac_cv_prog_TSORT="no"
1281fi
1282fi
1283TSORT="$ac_cv_prog_TSORT"
1284if test -n "$TSORT"; then
1285  echo "$ac_t""$TSORT" 1>&6
1286else
1287  echo "$ac_t""no" 1>&6
1288fi
1289
1290if test x$ac_cv_prog_LORDER != xlorder -o x$ac_cv_prog_TSORT != xtsort; then
1291  LORDER=echo
1292  TSORT=cat
1293    fi
1294
1295pathtmp=/usr/lib:/usr/sbin:/usr/etc:/usr/ucblib:/usr/bin:/bin
1296# Extract the first word of "sendmail", so it can be a program name with args.
1297set dummy sendmail; ac_word=$2
1298echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1299echo "configure:1300: checking for $ac_word" >&5
1300if eval "test \"`echo '$''{'ac_cv_path_sendmailpath'+set}'`\" = set"; then
1301  echo $ac_n "(cached) $ac_c" 1>&6
1302else
1303  case "$sendmailpath" in
1304  /*)
1305  ac_cv_path_sendmailpath="$sendmailpath" # Let the user override the test with a path.
1306  ;;
1307  ?:/*)                 
1308  ac_cv_path_sendmailpath="$sendmailpath" # Let the user override the test with a dos path.
1309  ;;
1310  *)
1311  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1312  ac_dummy="$pathtmp"
1313  for ac_dir in $ac_dummy; do
1314    test -z "$ac_dir" && ac_dir=.
1315    if test -f $ac_dir/$ac_word; then
1316      ac_cv_path_sendmailpath="$ac_dir/$ac_word"
1317      break
1318    fi
1319  done
1320  IFS="$ac_save_ifs"
1321  test -z "$ac_cv_path_sendmailpath" && ac_cv_path_sendmailpath="no"
1322  ;;
1323esac
1324fi
1325sendmailpath="$ac_cv_path_sendmailpath"
1326if test -n "$sendmailpath"; then
1327  echo "$ac_t""$sendmailpath" 1>&6
1328else
1329  echo "$ac_t""no" 1>&6
1330fi
1331
1332
1333pathtmp=/usr/bin:/bin:/usr/ucb:/usr/local/bin
1334# Extract the first word of "more", so it can be a program name with args.
1335set dummy more; ac_word=$2
1336echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1337echo "configure:1338: checking for $ac_word" >&5
1338if eval "test \"`echo '$''{'ac_cv_path_morepath'+set}'`\" = set"; then
1339  echo $ac_n "(cached) $ac_c" 1>&6
1340else
1341  case "$morepath" in
1342  /*)
1343  ac_cv_path_morepath="$morepath" # Let the user override the test with a path.
1344  ;;
1345  ?:/*)                 
1346  ac_cv_path_morepath="$morepath" # Let the user override the test with a dos path.
1347  ;;
1348  *)
1349  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1350  ac_dummy="$pathtmp"
1351  for ac_dir in $ac_dummy; do
1352    test -z "$ac_dir" && ac_dir=.
1353    if test -f $ac_dir/$ac_word; then
1354      ac_cv_path_morepath="$ac_dir/$ac_word"
1355      break
1356    fi
1357  done
1358  IFS="$ac_save_ifs"
1359  test -z "$ac_cv_path_morepath" && ac_cv_path_morepath="no"
1360  ;;
1361esac
1362fi
1363morepath="$ac_cv_path_morepath"
1364if test -n "$morepath"; then
1365  echo "$ac_t""$morepath" 1>&6
1366else
1367  echo "$ac_t""no" 1>&6
1368fi
1369
1370
1371if test -z "$pagerpath"; then
1372  pagerpath="$morepath"
1373fi
1374
1375pathtmp=/usr/bin:/bin:/usr/ucb:/usr/local/bin
1376# Extract the first word of "vi", so it can be a program name with args.
1377set dummy vi; ac_word=$2
1378echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
1379echo "configure:1380: checking for $ac_word" >&5
1380if eval "test \"`echo '$''{'ac_cv_path_vipath'+set}'`\" = set"; then
1381  echo $ac_n "(cached) $ac_c" 1>&6
1382else
1383  case "$vipath" in
1384  /*)
1385  ac_cv_path_vipath="$vipath" # Let the user override the test with a path.
1386  ;;
1387  ?:/*)                 
1388  ac_cv_path_vipath="$vipath" # Let the user override the test with a dos path.
1389  ;;
1390  *)
1391  IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
1392  ac_dummy="$pathtmp"
1393  for ac_dir in $ac_dummy; do
1394    test -z "$ac_dir" && ac_dir=.
1395    if test -f $ac_dir/$ac_word; then
1396      ac_cv_path_vipath="$ac_dir/$ac_word"
1397      break
1398    fi
1399  done
1400  IFS="$ac_save_ifs"
1401  test -z "$ac_cv_path_vipath" && ac_cv_path_vipath="no"
1402  ;;
1403esac
1404fi
1405vipath="$ac_cv_path_vipath"
1406if test -n "$vipath"; then
1407  echo "$ac_t""$vipath" 1>&6
1408else
1409  echo "$ac_t""no" 1>&6
1410fi
1411
1412
1413if test -z "$editorpath"; then
1414  editorpath="$vipath"
1415fi
1416
1417echo $ac_n "checking for broken vi""... $ac_c" 1>&6
1418echo "configure:1419: checking for broken vi" >&5
1419if eval "test \"`echo '$''{'nmh_cv_attvibug'+set}'`\" = set"; then
1420  echo $ac_n "(cached) $ac_c" 1>&6
1421else
1422  if echo 'r /nonexist-file
1423q' | ex > /dev/null 2>&1
1424then
1425        nmh_cv_attvibug=no
1426else
1427        nmh_cv_attvibug=yes
1428fi
1429fi
1430
1431echo "$ac_t""$nmh_cv_attvibug" 1>&6
1432 
1433if test "$nmh_cv_attvibug" = yes; then
1434  cat >> confdefs.h <<\EOF
1435#define ATTVIBUG 1
1436EOF
1437
1438fi
1439
1440echo $ac_n "checking where mail spool is located""... $ac_c" 1>&6
1441echo "configure:1442: checking where mail spool is located" >&5
1442if eval "test \"`echo '$''{'nmh_cv_mailspool'+set}'`\" = set"; then
1443  echo $ac_n "(cached) $ac_c" 1>&6
1444else
1445  for mailspool in /var/mail                          /var/spool/mail                    /usr/spool/mail                    /dev/null;       do
1446  test -d $mailspool && break
1447done
1448nmh_cv_mailspool=$mailspool
1449
1450fi
1451
1452echo "$ac_t""$nmh_cv_mailspool" 1>&6
1453mailspool=$nmh_cv_mailspool
1454
1455ac_header_dirent=no
1456for ac_hdr in dirent.h sys/ndir.h sys/dir.h ndir.h
1457do
1458ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1459echo $ac_n "checking for $ac_hdr that defines DIR""... $ac_c" 1>&6
1460echo "configure:1461: checking for $ac_hdr that defines DIR" >&5
1461if eval "test \"`echo '$''{'ac_cv_header_dirent_$ac_safe'+set}'`\" = set"; then
1462  echo $ac_n "(cached) $ac_c" 1>&6
1463else
1464  cat > conftest.$ac_ext <<EOF
1465#line 1466 "configure"
1466#include "confdefs.h"
1467#include <sys/types.h>
1468#include <$ac_hdr>
1469int main() {
1470DIR *dirp = 0;
1471; return 0; }
1472EOF
1473if { (eval echo configure:1474: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1474  rm -rf conftest*
1475  eval "ac_cv_header_dirent_$ac_safe=yes"
1476else
1477  echo "configure: failed program was:" >&5
1478  cat conftest.$ac_ext >&5
1479  rm -rf conftest*
1480  eval "ac_cv_header_dirent_$ac_safe=no"
1481fi
1482rm -f conftest*
1483fi
1484if eval "test \"`echo '$ac_cv_header_dirent_'$ac_safe`\" = yes"; then
1485  echo "$ac_t""yes" 1>&6
1486    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1487  cat >> confdefs.h <<EOF
1488#define $ac_tr_hdr 1
1489EOF
1490 ac_header_dirent=$ac_hdr; break
1491else
1492  echo "$ac_t""no" 1>&6
1493fi
1494done
1495# Two versions of opendir et al. are in -ldir and -lx on SCO Xenix.
1496if test $ac_header_dirent = dirent.h; then
1497echo $ac_n "checking for opendir in -ldir""... $ac_c" 1>&6
1498echo "configure:1499: checking for opendir in -ldir" >&5
1499ac_lib_var=`echo dir'_'opendir | sed 'y%./+-%__p_%'`
1500if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1501  echo $ac_n "(cached) $ac_c" 1>&6
1502else
1503  ac_save_LIBS="$LIBS"
1504LIBS="-ldir  $LIBS"
1505cat > conftest.$ac_ext <<EOF
1506#line 1507 "configure"
1507#include "confdefs.h"
1508/* Override any gcc2 internal prototype to avoid an error.  */
1509/* We use char because int might match the return type of a gcc2
1510    builtin and then its argument prototype would still apply.  */
1511char opendir();
1512
1513int main() {
1514opendir()
1515; return 0; }
1516EOF
1517if { (eval echo configure:1518: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1518  rm -rf conftest*
1519  eval "ac_cv_lib_$ac_lib_var=yes"
1520else
1521  echo "configure: failed program was:" >&5
1522  cat conftest.$ac_ext >&5
1523  rm -rf conftest*
1524  eval "ac_cv_lib_$ac_lib_var=no"
1525fi
1526rm -f conftest*
1527LIBS="$ac_save_LIBS"
1528
1529fi
1530if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1531  echo "$ac_t""yes" 1>&6
1532  LIBS="$LIBS -ldir"
1533else
1534  echo "$ac_t""no" 1>&6
1535fi
1536
1537else
1538echo $ac_n "checking for opendir in -lx""... $ac_c" 1>&6
1539echo "configure:1540: checking for opendir in -lx" >&5
1540ac_lib_var=`echo x'_'opendir | sed 'y%./+-%__p_%'`
1541if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1542  echo $ac_n "(cached) $ac_c" 1>&6
1543else
1544  ac_save_LIBS="$LIBS"
1545LIBS="-lx  $LIBS"
1546cat > conftest.$ac_ext <<EOF
1547#line 1548 "configure"
1548#include "confdefs.h"
1549/* Override any gcc2 internal prototype to avoid an error.  */
1550/* We use char because int might match the return type of a gcc2
1551    builtin and then its argument prototype would still apply.  */
1552char opendir();
1553
1554int main() {
1555opendir()
1556; return 0; }
1557EOF
1558if { (eval echo configure:1559: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1559  rm -rf conftest*
1560  eval "ac_cv_lib_$ac_lib_var=yes"
1561else
1562  echo "configure: failed program was:" >&5
1563  cat conftest.$ac_ext >&5
1564  rm -rf conftest*
1565  eval "ac_cv_lib_$ac_lib_var=no"
1566fi
1567rm -f conftest*
1568LIBS="$ac_save_LIBS"
1569
1570fi
1571if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1572  echo "$ac_t""yes" 1>&6
1573  LIBS="$LIBS -lx"
1574else
1575  echo "$ac_t""no" 1>&6
1576fi
1577
1578fi
1579
1580echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1581echo "configure:1582: checking how to run the C preprocessor" >&5
1582# On Suns, sometimes $CPP names a directory.
1583if test -n "$CPP" && test -d "$CPP"; then
1584  CPP=
1585fi
1586if test -z "$CPP"; then
1587if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1588  echo $ac_n "(cached) $ac_c" 1>&6
1589else
1590    # This must be in double quotes, not single quotes, because CPP may get
1591  # substituted into the Makefile and "${CC-cc}" will confuse make.
1592  CPP="${CC-cc} -E"
1593  # On the NeXT, cc -E runs the code through the compiler's parser,
1594  # not just through cpp.
1595  cat > conftest.$ac_ext <<EOF
1596#line 1597 "configure"
1597#include "confdefs.h"
1598#include <assert.h>
1599Syntax Error
1600EOF
1601ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1602{ (eval echo configure:1603: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1603ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1604if test -z "$ac_err"; then
1605  :
1606else
1607  echo "$ac_err" >&5
1608  echo "configure: failed program was:" >&5
1609  cat conftest.$ac_ext >&5
1610  rm -rf conftest*
1611  CPP="${CC-cc} -E -traditional-cpp"
1612  cat > conftest.$ac_ext <<EOF
1613#line 1614 "configure"
1614#include "confdefs.h"
1615#include <assert.h>
1616Syntax Error
1617EOF
1618ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1619{ (eval echo configure:1620: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1620ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1621if test -z "$ac_err"; then
1622  :
1623else
1624  echo "$ac_err" >&5
1625  echo "configure: failed program was:" >&5
1626  cat conftest.$ac_ext >&5
1627  rm -rf conftest*
1628  CPP="${CC-cc} -nologo -E"
1629  cat > conftest.$ac_ext <<EOF
1630#line 1631 "configure"
1631#include "confdefs.h"
1632#include <assert.h>
1633Syntax Error
1634EOF
1635ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1636{ (eval echo configure:1637: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1637ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1638if test -z "$ac_err"; then
1639  :
1640else
1641  echo "$ac_err" >&5
1642  echo "configure: failed program was:" >&5
1643  cat conftest.$ac_ext >&5
1644  rm -rf conftest*
1645  CPP=/lib/cpp
1646fi
1647rm -f conftest*
1648fi
1649rm -f conftest*
1650fi
1651rm -f conftest*
1652  ac_cv_prog_CPP="$CPP"
1653fi
1654  CPP="$ac_cv_prog_CPP"
1655else
1656  ac_cv_prog_CPP="$CPP"
1657fi
1658echo "$ac_t""$CPP" 1>&6
1659
1660echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
1661echo "configure:1662: checking for ANSI C header files" >&5
1662if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
1663  echo $ac_n "(cached) $ac_c" 1>&6
1664else
1665  cat > conftest.$ac_ext <<EOF
1666#line 1667 "configure"
1667#include "confdefs.h"
1668#include <stdlib.h>
1669#include <stdarg.h>
1670#include <string.h>
1671#include <float.h>
1672EOF
1673ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1674{ (eval echo configure:1675: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1675ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1676if test -z "$ac_err"; then
1677  rm -rf conftest*
1678  ac_cv_header_stdc=yes
1679else
1680  echo "$ac_err" >&5
1681  echo "configure: failed program was:" >&5
1682  cat conftest.$ac_ext >&5
1683  rm -rf conftest*
1684  ac_cv_header_stdc=no
1685fi
1686rm -f conftest*
1687
1688if test $ac_cv_header_stdc = yes; then
1689  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
1690cat > conftest.$ac_ext <<EOF
1691#line 1692 "configure"
1692#include "confdefs.h"
1693#include <string.h>
1694EOF
1695if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1696  egrep "memchr" >/dev/null 2>&1; then
1697  :
1698else
1699  rm -rf conftest*
1700  ac_cv_header_stdc=no
1701fi
1702rm -f conftest*
1703
1704fi
1705
1706if test $ac_cv_header_stdc = yes; then
1707  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
1708cat > conftest.$ac_ext <<EOF
1709#line 1710 "configure"
1710#include "confdefs.h"
1711#include <stdlib.h>
1712EOF
1713if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1714  egrep "free" >/dev/null 2>&1; then
1715  :
1716else
1717  rm -rf conftest*
1718  ac_cv_header_stdc=no
1719fi
1720rm -f conftest*
1721
1722fi
1723
1724if test $ac_cv_header_stdc = yes; then
1725  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
1726if test "$cross_compiling" = yes; then
1727  :
1728else
1729  cat > conftest.$ac_ext <<EOF
1730#line 1731 "configure"
1731#include "confdefs.h"
1732#include <ctype.h>
1733#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
1734#define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
1735#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
1736int main () { int i; for (i = 0; i < 256; i++)
1737if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
1738exit (0); }
1739
1740EOF
1741if { (eval echo configure:1742: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
1742then
1743  :
1744else
1745  echo "configure: failed program was:" >&5
1746  cat conftest.$ac_ext >&5
1747  rm -fr conftest*
1748  ac_cv_header_stdc=no
1749fi
1750rm -fr conftest*
1751fi
1752
1753fi
1754fi
1755
1756echo "$ac_t""$ac_cv_header_stdc" 1>&6
1757if test $ac_cv_header_stdc = yes; then
1758  cat >> confdefs.h <<\EOF
1759#define STDC_HEADERS 1
1760EOF
1761
1762fi
1763
1764echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
1765echo "configure:1766: checking whether time.h and sys/time.h may both be included" >&5
1766if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
1767  echo $ac_n "(cached) $ac_c" 1>&6
1768else
1769  cat > conftest.$ac_ext <<EOF
1770#line 1771 "configure"
1771#include "confdefs.h"
1772#include <sys/types.h>
1773#include <sys/time.h>
1774#include <time.h>
1775int main() {
1776struct tm *tp;
1777; return 0; }
1778EOF
1779if { (eval echo configure:1780: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1780  rm -rf conftest*
1781  ac_cv_header_time=yes
1782else
1783  echo "configure: failed program was:" >&5
1784  cat conftest.$ac_ext >&5
1785  rm -rf conftest*
1786  ac_cv_header_time=no
1787fi
1788rm -f conftest*
1789fi
1790
1791echo "$ac_t""$ac_cv_header_time" 1>&6
1792if test $ac_cv_header_time = yes; then
1793  cat >> confdefs.h <<\EOF
1794#define TIME_WITH_SYS_TIME 1
1795EOF
1796
1797fi
1798
1799echo $ac_n "checking for sys/wait.h that is POSIX.1 compatible""... $ac_c" 1>&6
1800echo "configure:1801: checking for sys/wait.h that is POSIX.1 compatible" >&5
1801if eval "test \"`echo '$''{'ac_cv_header_sys_wait_h'+set}'`\" = set"; then
1802  echo $ac_n "(cached) $ac_c" 1>&6
1803else
1804  cat > conftest.$ac_ext <<EOF
1805#line 1806 "configure"
1806#include "confdefs.h"
1807#include <sys/types.h>
1808#include <sys/wait.h>
1809#ifndef WEXITSTATUS
1810#define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
1811#endif
1812#ifndef WIFEXITED
1813#define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
1814#endif
1815int main() {
1816int s;
1817wait (&s);
1818s = WIFEXITED (s) ? WEXITSTATUS (s) : 1;
1819; return 0; }
1820EOF
1821if { (eval echo configure:1822: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1822  rm -rf conftest*
1823  ac_cv_header_sys_wait_h=yes
1824else
1825  echo "configure: failed program was:" >&5
1826  cat conftest.$ac_ext >&5
1827  rm -rf conftest*
1828  ac_cv_header_sys_wait_h=no
1829fi
1830rm -f conftest*
1831fi
1832
1833echo "$ac_t""$ac_cv_header_sys_wait_h" 1>&6
1834if test $ac_cv_header_sys_wait_h = yes; then
1835  cat >> confdefs.h <<\EOF
1836#define HAVE_SYS_WAIT_H 1
1837EOF
1838
1839fi
1840
1841echo $ac_n "checking whether stat file-mode macros are broken""... $ac_c" 1>&6
1842echo "configure:1843: checking whether stat file-mode macros are broken" >&5
1843if eval "test \"`echo '$''{'ac_cv_header_stat_broken'+set}'`\" = set"; then
1844  echo $ac_n "(cached) $ac_c" 1>&6
1845else
1846  cat > conftest.$ac_ext <<EOF
1847#line 1848 "configure"
1848#include "confdefs.h"
1849#include <sys/types.h>
1850#include <sys/stat.h>
1851
1852#if defined(S_ISBLK) && defined(S_IFDIR)
1853# if S_ISBLK (S_IFDIR)
1854You lose.
1855# endif
1856#endif
1857
1858#if defined(S_ISBLK) && defined(S_IFCHR)
1859# if S_ISBLK (S_IFCHR)
1860You lose.
1861# endif
1862#endif
1863
1864#if defined(S_ISLNK) && defined(S_IFREG)
1865# if S_ISLNK (S_IFREG)
1866You lose.
1867# endif
1868#endif
1869
1870#if defined(S_ISSOCK) && defined(S_IFREG)
1871# if S_ISSOCK (S_IFREG)
1872You lose.
1873# endif
1874#endif
1875
1876EOF
1877if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1878  egrep "You lose" >/dev/null 2>&1; then
1879  rm -rf conftest*
1880  ac_cv_header_stat_broken=yes
1881else
1882  rm -rf conftest*
1883  ac_cv_header_stat_broken=no
1884fi
1885rm -f conftest*
1886
1887fi
1888
1889echo "$ac_t""$ac_cv_header_stat_broken" 1>&6
1890if test $ac_cv_header_stat_broken = yes; then
1891  cat >> confdefs.h <<\EOF
1892#define STAT_MACROS_BROKEN 1
1893EOF
1894
1895fi
1896
1897for ac_hdr in string.h memory.h stdlib.h unistd.h errno.h fcntl.h \
1898                 limits.h crypt.h termcap.h termio.h termios.h locale.h \
1899                 sys/param.h sys/time.h sys/utsname.h arpa/inet.h \
1900                 arpa/ftp.h ndbm.h db.h
1901do
1902ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
1903echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
1904echo "configure:1905: checking for $ac_hdr" >&5
1905if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
1906  echo $ac_n "(cached) $ac_c" 1>&6
1907else
1908  cat > conftest.$ac_ext <<EOF
1909#line 1910 "configure"
1910#include "confdefs.h"
1911#include <$ac_hdr>
1912EOF
1913ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1914{ (eval echo configure:1915: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1915ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1916if test -z "$ac_err"; then
1917  rm -rf conftest*
1918  eval "ac_cv_header_$ac_safe=yes"
1919else
1920  echo "$ac_err" >&5
1921  echo "configure: failed program was:" >&5
1922  cat conftest.$ac_ext >&5
1923  rm -rf conftest*
1924  eval "ac_cv_header_$ac_safe=no"
1925fi
1926rm -f conftest*
1927fi
1928if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
1929  echo "$ac_t""yes" 1>&6
1930    ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
1931  cat >> confdefs.h <<EOF
1932#define $ac_tr_hdr 1
1933EOF
1934 
1935else
1936  echo "$ac_t""no" 1>&6
1937fi
1938done
1939
1940
1941echo $ac_n "checking POSIX termios""... $ac_c" 1>&6
1942echo "configure:1943: checking POSIX termios" >&5
1943if eval "test \"`echo '$''{'nmh_cv_sys_posix_termios'+set}'`\" = set"; then
1944  echo $ac_n "(cached) $ac_c" 1>&6
1945else
1946  cat > conftest.$ac_ext <<EOF
1947#line 1948 "configure"
1948#include "confdefs.h"
1949#include <sys/types.h>
1950#include <unistd.h>
1951#include <termios.h>
1952int main() {
1953/* SunOS 4.0.3 has termios.h but not the library calls.  */
1954tcgetattr(0, 0);
1955; return 0; }
1956EOF
1957if { (eval echo configure:1958: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1958  rm -rf conftest*
1959  nmh_cv_sys_posix_termios=yes
1960else
1961  echo "configure: failed program was:" >&5
1962  cat conftest.$ac_ext >&5
1963  rm -rf conftest*
1964  nmh_cv_sys_posix_termios=no
1965fi
1966rm -f conftest*
1967fi
1968
1969echo "$ac_t""$nmh_cv_sys_posix_termios" 1>&6
1970 
1971if test $nmh_cv_sys_posix_termios = yes; then
1972  echo $ac_n "checking TIOCGWINSZ in termios.h""... $ac_c" 1>&6
1973echo "configure:1974: checking TIOCGWINSZ in termios.h" >&5
1974if eval "test \"`echo '$''{'nmh_cv_header_termios_h_tiocgwinsz'+set}'`\" = set"; then
1975  echo $ac_n "(cached) $ac_c" 1>&6
1976else
1977  cat > conftest.$ac_ext <<EOF
1978#line 1979 "configure"
1979#include "confdefs.h"
1980#include <sys/types.h>
1981#include <termios.h>
1982int main() {
1983int x = TIOCGWINSZ;
1984; return 0; }
1985EOF
1986if { (eval echo configure:1987: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1987  rm -rf conftest*
1988  nmh_cv_header_termios_h_tiocgwinsz=yes
1989else
1990  echo "configure: failed program was:" >&5
1991  cat conftest.$ac_ext >&5
1992  rm -rf conftest*
1993  nmh_cv_header_termios_h_tiocgwinsz=no
1994fi
1995rm -f conftest*
1996fi
1997
1998echo "$ac_t""$nmh_cv_header_termios_h_tiocgwinsz" 1>&6
1999else
2000  nmh_cv_header_termios_h_tiocgwinsz=no
2001fi
2002 
2003if test $nmh_cv_header_termios_h_tiocgwinsz = no; then
2004  echo $ac_n "checking TIOCGWINSZ in sys/ioctl.h""... $ac_c" 1>&6
2005echo "configure:2006: checking TIOCGWINSZ in sys/ioctl.h" >&5
2006if eval "test \"`echo '$''{'nmh_cv_header_sys_ioctl_h_tiocgwinsz'+set}'`\" = set"; then
2007  echo $ac_n "(cached) $ac_c" 1>&6
2008else
2009  cat > conftest.$ac_ext <<EOF
2010#line 2011 "configure"
2011#include "confdefs.h"
2012#include <sys/types.h>
2013#include <sys/ioctl.h>
2014int main() {
2015int x = TIOCGWINSZ;
2016; return 0; }
2017EOF
2018if { (eval echo configure:2019: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2019  rm -rf conftest*
2020  nmh_cv_header_sys_ioctl_h_tiocgwinsz=yes
2021else
2022  echo "configure: failed program was:" >&5
2023  cat conftest.$ac_ext >&5
2024  rm -rf conftest*
2025  nmh_cv_header_sys_ioctl_h_tiocgwinsz=no
2026fi
2027rm -f conftest*
2028fi
2029
2030echo "$ac_t""$nmh_cv_header_sys_ioctl_h_tiocgwinsz" 1>&6
2031  if test $nmh_cv_header_sys_ioctl_h_tiocgwinsz = yes; then
2032    cat >> confdefs.h <<\EOF
2033#define GWINSZ_IN_SYS_IOCTL 1
2034EOF
2035
2036  fi
2037fi
2038 
2039ac_safe=`echo "sys/ptem.h" | sed 'y%./+-%__p_%'`
2040echo $ac_n "checking for sys/ptem.h""... $ac_c" 1>&6
2041echo "configure:2042: checking for sys/ptem.h" >&5
2042if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2043  echo $ac_n "(cached) $ac_c" 1>&6
2044else
2045  cat > conftest.$ac_ext <<EOF
2046#line 2047 "configure"
2047#include "confdefs.h"
2048#include <sys/ptem.h>
2049EOF
2050ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2051{ (eval echo configure:2052: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2052ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2053if test -z "$ac_err"; then
2054  rm -rf conftest*
2055  eval "ac_cv_header_$ac_safe=yes"
2056else
2057  echo "$ac_err" >&5
2058  echo "configure: failed program was:" >&5
2059  cat conftest.$ac_ext >&5
2060  rm -rf conftest*
2061  eval "ac_cv_header_$ac_safe=no"
2062fi
2063rm -f conftest*
2064fi
2065if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2066  echo "$ac_t""yes" 1>&6
2067  cat >> confdefs.h <<\EOF
2068#define WINSIZE_IN_PTEM 1
2069EOF
2070
2071else
2072  echo "$ac_t""no" 1>&6
2073fi
2074
2075
2076echo $ac_n "checking for pid_t""... $ac_c" 1>&6
2077echo "configure:2078: checking for pid_t" >&5
2078if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
2079  echo $ac_n "(cached) $ac_c" 1>&6
2080else
2081  cat > conftest.$ac_ext <<EOF
2082#line 2083 "configure"
2083#include "confdefs.h"
2084#include <sys/types.h>
2085#if STDC_HEADERS
2086#include <stdlib.h>
2087#include <stddef.h>
2088#endif
2089EOF
2090if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
2091  egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
2092  rm -rf conftest*
2093  ac_cv_type_pid_t=yes
2094else
2095  rm -rf conftest*
2096  ac_cv_type_pid_t=no
2097fi
2098rm -f conftest*
2099
2100fi
2101echo "$ac_t""$ac_cv_type_pid_t" 1>&6
2102if test $ac_cv_type_pid_t = no; then
2103  cat >> confdefs.h <<\EOF
2104#define pid_t int
2105EOF
2106
2107fi
2108
2109ac_safe=`echo "vfork.h" | sed 'y%./+-%__p_%'`
2110echo $ac_n "checking for vfork.h""... $ac_c" 1>&6
2111echo "configure:2112: checking for vfork.h" >&5
2112if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
2113  echo $ac_n "(cached) $ac_c" 1>&6
2114else
2115  cat > conftest.$ac_ext <<EOF
2116#line 2117 "configure"
2117#include "confdefs.h"
2118#include <vfork.h>
2119EOF
2120ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
2121{ (eval echo configure:2122: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
2122ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
2123if test -z "$ac_err"; then
2124  rm -rf conftest*
2125  eval "ac_cv_header_$ac_safe=yes"
2126else
2127  echo "$ac_err" >&5
2128  echo "configure: failed program was:" >&5
2129  cat conftest.$ac_ext >&5
2130  rm -rf conftest*
2131  eval "ac_cv_header_$ac_safe=no"
2132fi
2133rm -f conftest*
2134fi
2135if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
2136  echo "$ac_t""yes" 1>&6
2137  cat >> confdefs.h <<\EOF
2138#define HAVE_VFORK_H 1
2139EOF
2140
2141else
2142  echo "$ac_t""no" 1>&6
2143fi
2144
2145echo $ac_n "checking for working vfork""... $ac_c" 1>&6
2146echo "configure:2147: checking for working vfork" >&5
2147if eval "test \"`echo '$''{'ac_cv_func_vfork_works'+set}'`\" = set"; then
2148  echo $ac_n "(cached) $ac_c" 1>&6
2149else
2150  if test "$cross_compiling" = yes; then
2151  echo $ac_n "checking for vfork""... $ac_c" 1>&6
2152echo "configure:2153: checking for vfork" >&5
2153if eval "test \"`echo '$''{'ac_cv_func_vfork'+set}'`\" = set"; then
2154  echo $ac_n "(cached) $ac_c" 1>&6
2155else
2156  cat > conftest.$ac_ext <<EOF
2157#line 2158 "configure"
2158#include "confdefs.h"
2159/* System header to define __stub macros and hopefully few prototypes,
2160    which can conflict with char vfork(); below.  */
2161#include <assert.h>
2162/* Override any gcc2 internal prototype to avoid an error.  */
2163/* We use char because int might match the return type of a gcc2
2164    builtin and then its argument prototype would still apply.  */
2165char vfork();
2166
2167int main() {
2168
2169/* The GNU C library defines this for functions which it implements
2170    to always fail with ENOSYS.  Some functions are actually named
2171    something starting with __ and the normal name is an alias.  */
2172#if defined (__stub_vfork) || defined (__stub___vfork)
2173choke me
2174#else
2175vfork();
2176#endif
2177
2178; return 0; }
2179EOF
2180if { (eval echo configure:2181: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2181  rm -rf conftest*
2182  eval "ac_cv_func_vfork=yes"
2183else
2184  echo "configure: failed program was:" >&5
2185  cat conftest.$ac_ext >&5
2186  rm -rf conftest*
2187  eval "ac_cv_func_vfork=no"
2188fi
2189rm -f conftest*
2190fi
2191
2192if eval "test \"`echo '$ac_cv_func_'vfork`\" = yes"; then
2193  echo "$ac_t""yes" 1>&6
2194  :
2195else
2196  echo "$ac_t""no" 1>&6
2197fi
2198
2199ac_cv_func_vfork_works=$ac_cv_func_vfork
2200else
2201  cat > conftest.$ac_ext <<EOF
2202#line 2203 "configure"
2203#include "confdefs.h"
2204/* Thanks to Paul Eggert for this test.  */
2205#include <stdio.h>
2206#include <sys/types.h>
2207#include <sys/stat.h>
2208#ifdef HAVE_UNISTD_H
2209#include <unistd.h>
2210#endif
2211#ifdef HAVE_VFORK_H
2212#include <vfork.h>
2213#endif
2214/* On some sparc systems, changes by the child to local and incoming
2215   argument registers are propagated back to the parent.
2216   The compiler is told about this with #include <vfork.h>,
2217   but some compilers (e.g. gcc -O) don't grok <vfork.h>.
2218   Test for this by using a static variable whose address
2219   is put into a register that is clobbered by the vfork.  */
2220static
2221#ifdef __cplusplus
2222sparc_address_test (int arg)
2223#else
2224sparc_address_test (arg) int arg;
2225#endif
2226{
2227  static pid_t child;
2228  if (!child) {
2229    child = vfork ();
2230    if (child < 0) {
2231      perror ("vfork");
2232      _exit(2);
2233    }
2234    if (!child) {
2235      arg = getpid();
2236      write(-1, "", 0);
2237      _exit (arg);
2238    }
2239  }
2240}
2241main() {
2242  pid_t parent = getpid ();
2243  pid_t child;
2244
2245  sparc_address_test ();
2246
2247  child = vfork ();
2248
2249  if (child == 0) {
2250    /* Here is another test for sparc vfork register problems.
2251       This test uses lots of local variables, at least
2252       as many local variables as main has allocated so far
2253       including compiler temporaries.  4 locals are enough for
2254       gcc 1.40.3 on a Solaris 4.1.3 sparc, but we use 8 to be safe.
2255       A buggy compiler should reuse the register of parent
2256       for one of the local variables, since it will think that
2257       parent can't possibly be used any more in this routine.
2258       Assigning to the local variable will thus munge parent
2259       in the parent process.  */
2260    pid_t
2261      p = getpid(), p1 = getpid(), p2 = getpid(), p3 = getpid(),
2262      p4 = getpid(), p5 = getpid(), p6 = getpid(), p7 = getpid();
2263    /* Convince the compiler that p..p7 are live; otherwise, it might
2264       use the same hardware register for all 8 local variables.  */
2265    if (p != p1 || p != p2 || p != p3 || p != p4
2266        || p != p5 || p != p6 || p != p7)
2267      _exit(1);
2268
2269    /* On some systems (e.g. IRIX 3.3),
2270       vfork doesn't separate parent from child file descriptors.
2271       If the child closes a descriptor before it execs or exits,
2272       this munges the parent's descriptor as well.
2273       Test for this by closing stdout in the child.  */
2274    _exit(close(fileno(stdout)) != 0);
2275  } else {
2276    int status;
2277    struct stat st;
2278
2279    while (wait(&status) != child)
2280      ;
2281    exit(
2282         /* Was there some problem with vforking?  */
2283         child < 0
2284
2285         /* Did the child fail?  (This shouldn't happen.)  */
2286         || status
2287
2288         /* Did the vfork/compiler bug occur?  */
2289         || parent != getpid()
2290
2291         /* Did the file descriptor bug occur?  */
2292         || fstat(fileno(stdout), &st) != 0
2293         );
2294  }
2295}
2296EOF
2297if { (eval echo configure:2298: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
2298then
2299  ac_cv_func_vfork_works=yes
2300else
2301  echo "configure: failed program was:" >&5
2302  cat conftest.$ac_ext >&5
2303  rm -fr conftest*
2304  ac_cv_func_vfork_works=no
2305fi
2306rm -fr conftest*
2307fi
2308
2309fi
2310
2311echo "$ac_t""$ac_cv_func_vfork_works" 1>&6
2312if test $ac_cv_func_vfork_works = no; then
2313  cat >> confdefs.h <<\EOF
2314#define vfork fork
2315EOF
2316
2317fi
2318
2319for ac_func in waitpid wait3 sigaction sigprocmask sigblock sigsetmask \
2320               sighold sigrelse writev lstat uname tzset killpg \
2321               sigsetjmp
2322do
2323echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2324echo "configure:2325: checking for $ac_func" >&5
2325if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2326  echo $ac_n "(cached) $ac_c" 1>&6
2327else
2328  cat > conftest.$ac_ext <<EOF
2329#line 2330 "configure"
2330#include "confdefs.h"
2331/* System header to define __stub macros and hopefully few prototypes,
2332    which can conflict with char $ac_func(); below.  */
2333#include <assert.h>
2334/* Override any gcc2 internal prototype to avoid an error.  */
2335/* We use char because int might match the return type of a gcc2
2336    builtin and then its argument prototype would still apply.  */
2337char $ac_func();
2338
2339int main() {
2340
2341/* The GNU C library defines this for functions which it implements
2342    to always fail with ENOSYS.  Some functions are actually named
2343    something starting with __ and the normal name is an alias.  */
2344#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2345choke me
2346#else
2347$ac_func();
2348#endif
2349
2350; return 0; }
2351EOF
2352if { (eval echo configure:2353: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2353  rm -rf conftest*
2354  eval "ac_cv_func_$ac_func=yes"
2355else
2356  echo "configure: failed program was:" >&5
2357  cat conftest.$ac_ext >&5
2358  rm -rf conftest*
2359  eval "ac_cv_func_$ac_func=no"
2360fi
2361rm -f conftest*
2362fi
2363
2364if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2365  echo "$ac_t""yes" 1>&6
2366    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2367  cat >> confdefs.h <<EOF
2368#define $ac_tr_func 1
2369EOF
2370 
2371else
2372  echo "$ac_t""no" 1>&6
2373fi
2374done
2375
2376
2377for ac_func in snprintf strerror strdup
2378do
2379echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
2380echo "configure:2381: checking for $ac_func" >&5
2381if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
2382  echo $ac_n "(cached) $ac_c" 1>&6
2383else
2384  cat > conftest.$ac_ext <<EOF
2385#line 2386 "configure"
2386#include "confdefs.h"
2387/* System header to define __stub macros and hopefully few prototypes,
2388    which can conflict with char $ac_func(); below.  */
2389#include <assert.h>
2390/* Override any gcc2 internal prototype to avoid an error.  */
2391/* We use char because int might match the return type of a gcc2
2392    builtin and then its argument prototype would still apply.  */
2393char $ac_func();
2394
2395int main() {
2396
2397/* The GNU C library defines this for functions which it implements
2398    to always fail with ENOSYS.  Some functions are actually named
2399    something starting with __ and the normal name is an alias.  */
2400#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
2401choke me
2402#else
2403$ac_func();
2404#endif
2405
2406; return 0; }
2407EOF
2408if { (eval echo configure:2409: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2409  rm -rf conftest*
2410  eval "ac_cv_func_$ac_func=yes"
2411else
2412  echo "configure: failed program was:" >&5
2413  cat conftest.$ac_ext >&5
2414  rm -rf conftest*
2415  eval "ac_cv_func_$ac_func=no"
2416fi
2417rm -f conftest*
2418fi
2419
2420if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then
2421  echo "$ac_t""yes" 1>&6
2422    ac_tr_func=HAVE_`echo $ac_func | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
2423  cat >> confdefs.h <<EOF
2424#define $ac_tr_func 1
2425EOF
2426 
2427else
2428  echo "$ac_t""no" 1>&6
2429LIBOBJS="$LIBOBJS ${ac_func}.${ac_objext}"
2430fi
2431done
2432
2433
2434
2435echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
2436echo "configure:2437: checking for gethostbyname" >&5
2437if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
2438  echo $ac_n "(cached) $ac_c" 1>&6
2439else
2440  cat > conftest.$ac_ext <<EOF
2441#line 2442 "configure"
2442#include "confdefs.h"
2443/* System header to define __stub macros and hopefully few prototypes,
2444    which can conflict with char gethostbyname(); below.  */
2445#include <assert.h>
2446/* Override any gcc2 internal prototype to avoid an error.  */
2447/* We use char because int might match the return type of a gcc2
2448    builtin and then its argument prototype would still apply.  */
2449char gethostbyname();
2450
2451int main() {
2452
2453/* The GNU C library defines this for functions which it implements
2454    to always fail with ENOSYS.  Some functions are actually named
2455    something starting with __ and the normal name is an alias.  */
2456#if defined (__stub_gethostbyname) || defined (__stub___gethostbyname)
2457choke me
2458#else
2459gethostbyname();
2460#endif
2461
2462; return 0; }
2463EOF
2464if { (eval echo configure:2465: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2465  rm -rf conftest*
2466  eval "ac_cv_func_gethostbyname=yes"
2467else
2468  echo "configure: failed program was:" >&5
2469  cat conftest.$ac_ext >&5
2470  rm -rf conftest*
2471  eval "ac_cv_func_gethostbyname=no"
2472fi
2473rm -f conftest*
2474fi
2475
2476if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
2477  echo "$ac_t""yes" 1>&6
2478  :
2479else
2480  echo "$ac_t""no" 1>&6
2481echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
2482echo "configure:2483: checking for gethostbyname in -lnsl" >&5
2483ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
2484if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2485  echo $ac_n "(cached) $ac_c" 1>&6
2486else
2487  ac_save_LIBS="$LIBS"
2488LIBS="-lnsl  $LIBS"
2489cat > conftest.$ac_ext <<EOF
2490#line 2491 "configure"
2491#include "confdefs.h"
2492/* Override any gcc2 internal prototype to avoid an error.  */
2493/* We use char because int might match the return type of a gcc2
2494    builtin and then its argument prototype would still apply.  */
2495char gethostbyname();
2496
2497int main() {
2498gethostbyname()
2499; return 0; }
2500EOF
2501if { (eval echo configure:2502: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2502  rm -rf conftest*
2503  eval "ac_cv_lib_$ac_lib_var=yes"
2504else
2505  echo "configure: failed program was:" >&5
2506  cat conftest.$ac_ext >&5
2507  rm -rf conftest*
2508  eval "ac_cv_lib_$ac_lib_var=no"
2509fi
2510rm -f conftest*
2511LIBS="$ac_save_LIBS"
2512
2513fi
2514if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2515  echo "$ac_t""yes" 1>&6
2516    ac_tr_lib=HAVE_LIB`echo nsl | sed -e 's/^a-zA-Z0-9_/_/g' \
2517    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2518  cat >> confdefs.h <<EOF
2519#define $ac_tr_lib 1
2520EOF
2521
2522  LIBS="-lnsl $LIBS"
2523
2524else
2525  echo "$ac_t""no" 1>&6
2526echo $ac_n "checking for gethostbyname in -lresolv""... $ac_c" 1>&6
2527echo "configure:2528: checking for gethostbyname in -lresolv" >&5
2528ac_lib_var=`echo resolv'_'gethostbyname | sed 'y%./+-%__p_%'`
2529if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2530  echo $ac_n "(cached) $ac_c" 1>&6
2531else
2532  ac_save_LIBS="$LIBS"
2533LIBS="-lresolv  $LIBS"
2534cat > conftest.$ac_ext <<EOF
2535#line 2536 "configure"
2536#include "confdefs.h"
2537/* Override any gcc2 internal prototype to avoid an error.  */
2538/* We use char because int might match the return type of a gcc2
2539    builtin and then its argument prototype would still apply.  */
2540char gethostbyname();
2541
2542int main() {
2543gethostbyname()
2544; return 0; }
2545EOF
2546if { (eval echo configure:2547: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2547  rm -rf conftest*
2548  eval "ac_cv_lib_$ac_lib_var=yes"
2549else
2550  echo "configure: failed program was:" >&5
2551  cat conftest.$ac_ext >&5
2552  rm -rf conftest*
2553  eval "ac_cv_lib_$ac_lib_var=no"
2554fi
2555rm -f conftest*
2556LIBS="$ac_save_LIBS"
2557
2558fi
2559if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2560  echo "$ac_t""yes" 1>&6
2561    ac_tr_lib=HAVE_LIB`echo resolv | sed -e 's/^a-zA-Z0-9_/_/g' \
2562    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2563  cat >> confdefs.h <<EOF
2564#define $ac_tr_lib 1
2565EOF
2566
2567  LIBS="-lresolv $LIBS"
2568
2569else
2570  echo "$ac_t""no" 1>&6
2571fi
2572
2573fi
2574
2575fi
2576
2577echo $ac_n "checking for socket""... $ac_c" 1>&6
2578echo "configure:2579: checking for socket" >&5
2579if eval "test \"`echo '$''{'ac_cv_func_socket'+set}'`\" = set"; then
2580  echo $ac_n "(cached) $ac_c" 1>&6
2581else
2582  cat > conftest.$ac_ext <<EOF
2583#line 2584 "configure"
2584#include "confdefs.h"
2585/* System header to define __stub macros and hopefully few prototypes,
2586    which can conflict with char socket(); below.  */
2587#include <assert.h>
2588/* Override any gcc2 internal prototype to avoid an error.  */
2589/* We use char because int might match the return type of a gcc2
2590    builtin and then its argument prototype would still apply.  */
2591char socket();
2592
2593int main() {
2594
2595/* The GNU C library defines this for functions which it implements
2596    to always fail with ENOSYS.  Some functions are actually named
2597    something starting with __ and the normal name is an alias.  */
2598#if defined (__stub_socket) || defined (__stub___socket)
2599choke me
2600#else
2601socket();
2602#endif
2603
2604; return 0; }
2605EOF
2606if { (eval echo configure:2607: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2607  rm -rf conftest*
2608  eval "ac_cv_func_socket=yes"
2609else
2610  echo "configure: failed program was:" >&5
2611  cat conftest.$ac_ext >&5
2612  rm -rf conftest*
2613  eval "ac_cv_func_socket=no"
2614fi
2615rm -f conftest*
2616fi
2617
2618if eval "test \"`echo '$ac_cv_func_'socket`\" = yes"; then
2619  echo "$ac_t""yes" 1>&6
2620  :
2621else
2622  echo "$ac_t""no" 1>&6
2623echo $ac_n "checking for socket in -lsocket""... $ac_c" 1>&6
2624echo "configure:2625: checking for socket in -lsocket" >&5
2625ac_lib_var=`echo socket'_'socket | sed 'y%./+-%__p_%'`
2626if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2627  echo $ac_n "(cached) $ac_c" 1>&6
2628else
2629  ac_save_LIBS="$LIBS"
2630LIBS="-lsocket  $LIBS"
2631cat > conftest.$ac_ext <<EOF
2632#line 2633 "configure"
2633#include "confdefs.h"
2634/* Override any gcc2 internal prototype to avoid an error.  */
2635/* We use char because int might match the return type of a gcc2
2636    builtin and then its argument prototype would still apply.  */
2637char socket();
2638
2639int main() {
2640socket()
2641; return 0; }
2642EOF
2643if { (eval echo configure:2644: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2644  rm -rf conftest*
2645  eval "ac_cv_lib_$ac_lib_var=yes"
2646else
2647  echo "configure: failed program was:" >&5
2648  cat conftest.$ac_ext >&5
2649  rm -rf conftest*
2650  eval "ac_cv_lib_$ac_lib_var=no"
2651fi
2652rm -f conftest*
2653LIBS="$ac_save_LIBS"
2654
2655fi
2656if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2657  echo "$ac_t""yes" 1>&6
2658    ac_tr_lib=HAVE_LIB`echo socket | sed -e 's/^a-zA-Z0-9_/_/g' \
2659    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2660  cat >> confdefs.h <<EOF
2661#define $ac_tr_lib 1
2662EOF
2663
2664  LIBS="-lsocket $LIBS"
2665
2666else
2667  echo "$ac_t""no" 1>&6
2668fi
2669
2670fi
2671
2672
2673
2674echo $ac_n "checking for ruserpass""... $ac_c" 1>&6
2675echo "configure:2676: checking for ruserpass" >&5
2676if eval "test \"`echo '$''{'ac_cv_func_ruserpass'+set}'`\" = set"; then
2677  echo $ac_n "(cached) $ac_c" 1>&6
2678else
2679  cat > conftest.$ac_ext <<EOF
2680#line 2681 "configure"
2681#include "confdefs.h"
2682/* System header to define __stub macros and hopefully few prototypes,
2683    which can conflict with char ruserpass(); below.  */
2684#include <assert.h>
2685/* Override any gcc2 internal prototype to avoid an error.  */
2686/* We use char because int might match the return type of a gcc2
2687    builtin and then its argument prototype would still apply.  */
2688char ruserpass();
2689
2690int main() {
2691
2692/* The GNU C library defines this for functions which it implements
2693    to always fail with ENOSYS.  Some functions are actually named
2694    something starting with __ and the normal name is an alias.  */
2695#if defined (__stub_ruserpass) || defined (__stub___ruserpass)
2696choke me
2697#else
2698ruserpass();
2699#endif
2700
2701; return 0; }
2702EOF
2703if { (eval echo configure:2704: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2704  rm -rf conftest*
2705  eval "ac_cv_func_ruserpass=yes"
2706else
2707  echo "configure: failed program was:" >&5
2708  cat conftest.$ac_ext >&5
2709  rm -rf conftest*
2710  eval "ac_cv_func_ruserpass=no"
2711fi
2712rm -f conftest*
2713fi
2714
2715if eval "test \"`echo '$ac_cv_func_'ruserpass`\" = yes"; then
2716  echo "$ac_t""yes" 1>&6
2717  :
2718else
2719  echo "$ac_t""no" 1>&6
2720echo $ac_n "checking for _ruserpass""... $ac_c" 1>&6
2721echo "configure:2722: checking for _ruserpass" >&5
2722if eval "test \"`echo '$''{'ac_cv_func__ruserpass'+set}'`\" = set"; then
2723  echo $ac_n "(cached) $ac_c" 1>&6
2724else
2725  cat > conftest.$ac_ext <<EOF
2726#line 2727 "configure"
2727#include "confdefs.h"
2728/* System header to define __stub macros and hopefully few prototypes,
2729    which can conflict with char _ruserpass(); below.  */
2730#include <assert.h>
2731/* Override any gcc2 internal prototype to avoid an error.  */
2732/* We use char because int might match the return type of a gcc2
2733    builtin and then its argument prototype would still apply.  */
2734char _ruserpass();
2735
2736int main() {
2737
2738/* The GNU C library defines this for functions which it implements
2739    to always fail with ENOSYS.  Some functions are actually named
2740    something starting with __ and the normal name is an alias.  */
2741#if defined (__stub__ruserpass) || defined (__stub____ruserpass)
2742choke me
2743#else
2744_ruserpass();
2745#endif
2746
2747; return 0; }
2748EOF
2749if { (eval echo configure:2750: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2750  rm -rf conftest*
2751  eval "ac_cv_func__ruserpass=yes"
2752else
2753  echo "configure: failed program was:" >&5
2754  cat conftest.$ac_ext >&5
2755  rm -rf conftest*
2756  eval "ac_cv_func__ruserpass=no"
2757fi
2758rm -f conftest*
2759fi
2760
2761if eval "test \"`echo '$ac_cv_func_'_ruserpass`\" = yes"; then
2762  echo "$ac_t""yes" 1>&6
2763  :
2764else
2765  echo "$ac_t""no" 1>&6
2766echo $ac_n "checking for _ruserpass in -lsocket""... $ac_c" 1>&6
2767echo "configure:2768: checking for _ruserpass in -lsocket" >&5
2768ac_lib_var=`echo socket'_'_ruserpass | sed 'y%./+-%__p_%'`
2769if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2770  echo $ac_n "(cached) $ac_c" 1>&6
2771else
2772  ac_save_LIBS="$LIBS"
2773LIBS="-lsocket  $LIBS"
2774cat > conftest.$ac_ext <<EOF
2775#line 2776 "configure"
2776#include "confdefs.h"
2777/* Override any gcc2 internal prototype to avoid an error.  */
2778/* We use char because int might match the return type of a gcc2
2779    builtin and then its argument prototype would still apply.  */
2780char _ruserpass();
2781
2782int main() {
2783_ruserpass()
2784; return 0; }
2785EOF
2786if { (eval echo configure:2787: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2787  rm -rf conftest*
2788  eval "ac_cv_lib_$ac_lib_var=yes"
2789else
2790  echo "configure: failed program was:" >&5
2791  cat conftest.$ac_ext >&5
2792  rm -rf conftest*
2793  eval "ac_cv_lib_$ac_lib_var=no"
2794fi
2795rm -f conftest*
2796LIBS="$ac_save_LIBS"
2797
2798fi
2799if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2800  echo "$ac_t""yes" 1>&6
2801    ac_tr_lib=HAVE_LIB`echo socket | sed -e 's/^a-zA-Z0-9_/_/g' \
2802    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2803  cat >> confdefs.h <<EOF
2804#define $ac_tr_lib 1
2805EOF
2806
2807  LIBS="-lsocket $LIBS"
2808
2809else
2810  echo "$ac_t""no" 1>&6
2811fi
2812
2813fi
2814
2815fi
2816
2817if test x$ac_cv_func_ruserpass = xno; then
2818  if test x$ac_cv_func__ruserpass = xyes -o x$ac_cv_lib_socket__ruserpass = xyes; then
2819    cat >> confdefs.h <<\EOF
2820#define ruserpass _ruserpass
2821EOF
2822
2823  else
2824    LIBOBJS="$LIBOBJS ruserpass.o"
2825  fi
2826fi
2827
2828
2829termcap_curses_order="termcap curses ncurses"
2830for lib in $termcap_curses_order; do
2831  echo $ac_n "checking for tgetent in -l${lib}""... $ac_c" 1>&6
2832echo "configure:2833: checking for tgetent in -l${lib}" >&5
2833ac_lib_var=`echo ${lib}'_'tgetent | sed 'y%./+-%__p_%'`
2834if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2835  echo $ac_n "(cached) $ac_c" 1>&6
2836else
2837  ac_save_LIBS="$LIBS"
2838LIBS="-l${lib}  $LIBS"
2839cat > conftest.$ac_ext <<EOF
2840#line 2841 "configure"
2841#include "confdefs.h"
2842/* Override any gcc2 internal prototype to avoid an error.  */
2843/* We use char because int might match the return type of a gcc2
2844    builtin and then its argument prototype would still apply.  */
2845char tgetent();
2846
2847int main() {
2848tgetent()
2849; return 0; }
2850EOF
2851if { (eval echo configure:2852: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2852  rm -rf conftest*
2853  eval "ac_cv_lib_$ac_lib_var=yes"
2854else
2855  echo "configure: failed program was:" >&5
2856  cat conftest.$ac_ext >&5
2857  rm -rf conftest*
2858  eval "ac_cv_lib_$ac_lib_var=no"
2859fi
2860rm -f conftest*
2861LIBS="$ac_save_LIBS"
2862
2863fi
2864if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2865  echo "$ac_t""yes" 1>&6
2866  TERMLIB="-l$lib"; break
2867else
2868  echo "$ac_t""no" 1>&6
2869fi
2870
2871done
2872
2873echo $ac_n "checking for dbm_open""... $ac_c" 1>&6
2874echo "configure:2875: checking for dbm_open" >&5
2875if eval "test \"`echo '$''{'ac_cv_func_dbm_open'+set}'`\" = set"; then
2876  echo $ac_n "(cached) $ac_c" 1>&6
2877else
2878  cat > conftest.$ac_ext <<EOF
2879#line 2880 "configure"
2880#include "confdefs.h"
2881/* System header to define __stub macros and hopefully few prototypes,
2882    which can conflict with char dbm_open(); below.  */
2883#include <assert.h>
2884/* Override any gcc2 internal prototype to avoid an error.  */
2885/* We use char because int might match the return type of a gcc2
2886    builtin and then its argument prototype would still apply.  */
2887char dbm_open();
2888
2889int main() {
2890
2891/* The GNU C library defines this for functions which it implements
2892    to always fail with ENOSYS.  Some functions are actually named
2893    something starting with __ and the normal name is an alias.  */
2894#if defined (__stub_dbm_open) || defined (__stub___dbm_open)
2895choke me
2896#else
2897dbm_open();
2898#endif
2899
2900; return 0; }
2901EOF
2902if { (eval echo configure:2903: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2903  rm -rf conftest*
2904  eval "ac_cv_func_dbm_open=yes"
2905else
2906  echo "configure: failed program was:" >&5
2907  cat conftest.$ac_ext >&5
2908  rm -rf conftest*
2909  eval "ac_cv_func_dbm_open=no"
2910fi
2911rm -f conftest*
2912fi
2913
2914if eval "test \"`echo '$ac_cv_func_'dbm_open`\" = yes"; then
2915  echo "$ac_t""yes" 1>&6
2916  :
2917else
2918  echo "$ac_t""no" 1>&6
2919echo $ac_n "checking for dbm_open in -lndbm""... $ac_c" 1>&6
2920echo "configure:2921: checking for dbm_open in -lndbm" >&5
2921ac_lib_var=`echo ndbm'_'dbm_open | sed 'y%./+-%__p_%'`
2922if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2923  echo $ac_n "(cached) $ac_c" 1>&6
2924else
2925  ac_save_LIBS="$LIBS"
2926LIBS="-lndbm  $LIBS"
2927cat > conftest.$ac_ext <<EOF
2928#line 2929 "configure"
2929#include "confdefs.h"
2930/* Override any gcc2 internal prototype to avoid an error.  */
2931/* We use char because int might match the return type of a gcc2
2932    builtin and then its argument prototype would still apply.  */
2933char dbm_open();
2934
2935int main() {
2936dbm_open()
2937; return 0; }
2938EOF
2939if { (eval echo configure:2940: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2940  rm -rf conftest*
2941  eval "ac_cv_lib_$ac_lib_var=yes"
2942else
2943  echo "configure: failed program was:" >&5
2944  cat conftest.$ac_ext >&5
2945  rm -rf conftest*
2946  eval "ac_cv_lib_$ac_lib_var=no"
2947fi
2948rm -f conftest*
2949LIBS="$ac_save_LIBS"
2950
2951fi
2952if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2953  echo "$ac_t""yes" 1>&6
2954    ac_tr_lib=HAVE_LIB`echo ndbm | sed -e 's/^a-zA-Z0-9_/_/g' \
2955    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
2956  cat >> confdefs.h <<EOF
2957#define $ac_tr_lib 1
2958EOF
2959
2960  LIBS="-lndbm $LIBS"
2961
2962else
2963  echo "$ac_t""no" 1>&6
2964echo $ac_n "checking for dbm_open in -ldbm""... $ac_c" 1>&6
2965echo "configure:2966: checking for dbm_open in -ldbm" >&5
2966ac_lib_var=`echo dbm'_'dbm_open | sed 'y%./+-%__p_%'`
2967if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
2968  echo $ac_n "(cached) $ac_c" 1>&6
2969else
2970  ac_save_LIBS="$LIBS"
2971LIBS="-ldbm  $LIBS"
2972cat > conftest.$ac_ext <<EOF
2973#line 2974 "configure"
2974#include "confdefs.h"
2975/* Override any gcc2 internal prototype to avoid an error.  */
2976/* We use char because int might match the return type of a gcc2
2977    builtin and then its argument prototype would still apply.  */
2978char dbm_open();
2979
2980int main() {
2981dbm_open()
2982; return 0; }
2983EOF
2984if { (eval echo configure:2985: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
2985  rm -rf conftest*
2986  eval "ac_cv_lib_$ac_lib_var=yes"
2987else
2988  echo "configure: failed program was:" >&5
2989  cat conftest.$ac_ext >&5
2990  rm -rf conftest*
2991  eval "ac_cv_lib_$ac_lib_var=no"
2992fi
2993rm -f conftest*
2994LIBS="$ac_save_LIBS"
2995
2996fi
2997if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
2998  echo "$ac_t""yes" 1>&6
2999    ac_tr_lib=HAVE_LIB`echo dbm | sed -e 's/^a-zA-Z0-9_/_/g' \
3000    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
3001  cat >> confdefs.h <<EOF
3002#define $ac_tr_lib 1
3003EOF
3004
3005  LIBS="-ldbm $LIBS"
3006
3007else
3008  echo "$ac_t""no" 1>&6
3009echo $ac_n "checking for __db_ndbm_open in -ldb""... $ac_c" 1>&6
3010echo "configure:3011: checking for __db_ndbm_open in -ldb" >&5
3011ac_lib_var=`echo db'_'__db_ndbm_open | sed 'y%./+-%__p_%'`
3012if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3013  echo $ac_n "(cached) $ac_c" 1>&6
3014else
3015  ac_save_LIBS="$LIBS"
3016LIBS="-ldb  $LIBS"
3017cat > conftest.$ac_ext <<EOF
3018#line 3019 "configure"
3019#include "confdefs.h"
3020/* Override any gcc2 internal prototype to avoid an error.  */
3021/* We use char because int might match the return type of a gcc2
3022    builtin and then its argument prototype would still apply.  */
3023char __db_ndbm_open();
3024
3025int main() {
3026__db_ndbm_open()
3027; return 0; }
3028EOF
3029if { (eval echo configure:3030: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3030  rm -rf conftest*
3031  eval "ac_cv_lib_$ac_lib_var=yes"
3032else
3033  echo "configure: failed program was:" >&5
3034  cat conftest.$ac_ext >&5
3035  rm -rf conftest*
3036  eval "ac_cv_lib_$ac_lib_var=no"
3037fi
3038rm -f conftest*
3039LIBS="$ac_save_LIBS"
3040
3041fi
3042if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3043  echo "$ac_t""yes" 1>&6
3044    ac_tr_lib=HAVE_LIB`echo db | sed -e 's/^a-zA-Z0-9_/_/g' \
3045    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
3046  cat >> confdefs.h <<EOF
3047#define $ac_tr_lib 1
3048EOF
3049
3050  LIBS="-ldb $LIBS"
3051
3052else
3053  echo "$ac_t""no" 1>&6
3054fi
3055
3056fi
3057
3058fi
3059
3060fi
3061
3062
3063if test x$with_hesiod != x -a x$with_hesiod != xno; then
3064  if test x$with_hesiod != xyes; then
3065    HESIOD_INCLUDES="-I$with_hesiod/include"
3066    HESIOD_LIBS="-L$with_hesiod/lib"
3067  fi
3068  echo $ac_n "checking for res_send""... $ac_c" 1>&6
3069echo "configure:3070: checking for res_send" >&5
3070if eval "test \"`echo '$''{'ac_cv_func_res_send'+set}'`\" = set"; then
3071  echo $ac_n "(cached) $ac_c" 1>&6
3072else
3073  cat > conftest.$ac_ext <<EOF
3074#line 3075 "configure"
3075#include "confdefs.h"
3076/* System header to define __stub macros and hopefully few prototypes,
3077    which can conflict with char res_send(); below.  */
3078#include <assert.h>
3079/* Override any gcc2 internal prototype to avoid an error.  */
3080/* We use char because int might match the return type of a gcc2
3081    builtin and then its argument prototype would still apply.  */
3082char res_send();
3083
3084int main() {
3085
3086/* The GNU C library defines this for functions which it implements
3087    to always fail with ENOSYS.  Some functions are actually named
3088    something starting with __ and the normal name is an alias.  */
3089#if defined (__stub_res_send) || defined (__stub___res_send)
3090choke me
3091#else
3092res_send();
3093#endif
3094
3095; return 0; }
3096EOF
3097if { (eval echo configure:3098: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3098  rm -rf conftest*
3099  eval "ac_cv_func_res_send=yes"
3100else
3101  echo "configure: failed program was:" >&5
3102  cat conftest.$ac_ext >&5
3103  rm -rf conftest*
3104  eval "ac_cv_func_res_send=no"
3105fi
3106rm -f conftest*
3107fi
3108
3109if eval "test \"`echo '$ac_cv_func_'res_send`\" = yes"; then
3110  echo "$ac_t""yes" 1>&6
3111  :
3112else
3113  echo "$ac_t""no" 1>&6
3114echo $ac_n "checking for res_send in -lresolv""... $ac_c" 1>&6
3115echo "configure:3116: checking for res_send in -lresolv" >&5
3116ac_lib_var=`echo resolv'_'res_send | sed 'y%./+-%__p_%'`
3117if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3118  echo $ac_n "(cached) $ac_c" 1>&6
3119else
3120  ac_save_LIBS="$LIBS"
3121LIBS="-lresolv  $LIBS"
3122cat > conftest.$ac_ext <<EOF
3123#line 3124 "configure"
3124#include "confdefs.h"
3125/* Override any gcc2 internal prototype to avoid an error.  */
3126/* We use char because int might match the return type of a gcc2
3127    builtin and then its argument prototype would still apply.  */
3128char res_send();
3129
3130int main() {
3131res_send()
3132; return 0; }
3133EOF
3134if { (eval echo configure:3135: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3135  rm -rf conftest*
3136  eval "ac_cv_lib_$ac_lib_var=yes"
3137else
3138  echo "configure: failed program was:" >&5
3139  cat conftest.$ac_ext >&5
3140  rm -rf conftest*
3141  eval "ac_cv_lib_$ac_lib_var=no"
3142fi
3143rm -f conftest*
3144LIBS="$ac_save_LIBS"
3145
3146fi
3147if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3148  echo "$ac_t""yes" 1>&6
3149    ac_tr_lib=HAVE_LIB`echo resolv | sed -e 's/^a-zA-Z0-9_/_/g' \
3150    -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'`
3151  cat >> confdefs.h <<EOF
3152#define $ac_tr_lib 1
3153EOF
3154
3155  LIBS="-lresolv $LIBS"
3156
3157else
3158  echo "$ac_t""no" 1>&6
3159fi
3160
3161fi
3162
3163  echo $ac_n "checking for hes_resolve in -lhesiod""... $ac_c" 1>&6
3164echo "configure:3165: checking for hes_resolve in -lhesiod" >&5
3165ac_lib_var=`echo hesiod'_'hes_resolve | sed 'y%./+-%__p_%'`
3166if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3167  echo $ac_n "(cached) $ac_c" 1>&6
3168else
3169  ac_save_LIBS="$LIBS"
3170LIBS="-lhesiod $HESIOD_LIBS $LIBS"
3171cat > conftest.$ac_ext <<EOF
3172#line 3173 "configure"
3173#include "confdefs.h"
3174/* Override any gcc2 internal prototype to avoid an error.  */
3175/* We use char because int might match the return type of a gcc2
3176    builtin and then its argument prototype would still apply.  */
3177char hes_resolve();
3178
3179int main() {
3180hes_resolve()
3181; return 0; }
3182EOF
3183if { (eval echo configure:3184: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3184  rm -rf conftest*
3185  eval "ac_cv_lib_$ac_lib_var=yes"
3186else
3187  echo "configure: failed program was:" >&5
3188  cat conftest.$ac_ext >&5
3189  rm -rf conftest*
3190  eval "ac_cv_lib_$ac_lib_var=no"
3191fi
3192rm -f conftest*
3193LIBS="$ac_save_LIBS"
3194
3195fi
3196if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3197  echo "$ac_t""yes" 1>&6
3198  HESIOD_LIBS="$HESIOD_LIBS -lhesiod"
3199else
3200  echo "$ac_t""no" 1>&6
3201{ echo "configure: error: Hesiod library not found" 1>&2; exit 1; }
3202fi
3203
3204fi
3205
3206if test x$with_krb4 != x -a x$with_krb4 != xno; then
3207  if test x$with_krb4 != xyes; then
3208    KRB4_INCLUDES="-I$with_krb4/include"
3209    if test -d "$with_krb4/include/kerberosIV"; then
3210      KRB4_INCLUDES="$KRB4_INCLUDES -I$with_krb4/include/kerberosIV"
3211    fi
3212    KRB4_LIBS="-L$with_krb4/lib"
3213  elif test -d /usr/include/kerberosIV; then
3214    KRB4_INCLUDES="-I/usr/include/kerberosIV"
3215  fi
3216  echo $ac_n "checking for krb_rd_req in -lkrb4""... $ac_c" 1>&6
3217echo "configure:3218: checking for krb_rd_req in -lkrb4" >&5
3218ac_lib_var=`echo krb4'_'krb_rd_req | sed 'y%./+-%__p_%'`
3219if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3220  echo $ac_n "(cached) $ac_c" 1>&6
3221else
3222  ac_save_LIBS="$LIBS"
3223LIBS="-lkrb4 $KRB4_LIBS -ldes425 -lkrb5 -lk5crypto -lcom_err $LIBS"
3224cat > conftest.$ac_ext <<EOF
3225#line 3226 "configure"
3226#include "confdefs.h"
3227/* Override any gcc2 internal prototype to avoid an error.  */
3228/* We use char because int might match the return type of a gcc2
3229    builtin and then its argument prototype would still apply.  */
3230char krb_rd_req();
3231
3232int main() {
3233krb_rd_req()
3234; return 0; }
3235EOF
3236if { (eval echo configure:3237: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3237  rm -rf conftest*
3238  eval "ac_cv_lib_$ac_lib_var=yes"
3239else
3240  echo "configure: failed program was:" >&5
3241  cat conftest.$ac_ext >&5
3242  rm -rf conftest*
3243  eval "ac_cv_lib_$ac_lib_var=no"
3244fi
3245rm -f conftest*
3246LIBS="$ac_save_LIBS"
3247
3248fi
3249if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3250  echo "$ac_t""yes" 1>&6
3251  KRB4_LIBS="$KRB4_LIBS -lkrb4 -ldes425 -lkrb5 -lk5crypto -lcom_err"
3252else
3253  echo "$ac_t""no" 1>&6
3254echo $ac_n "checking for krb_rd_req in -lkrb""... $ac_c" 1>&6
3255echo "configure:3256: checking for krb_rd_req in -lkrb" >&5
3256ac_lib_var=`echo krb'_'krb_rd_req | sed 'y%./+-%__p_%'`
3257if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
3258  echo $ac_n "(cached) $ac_c" 1>&6
3259else
3260  ac_save_LIBS="$LIBS"
3261LIBS="-lkrb $KRB4_LIBS -ldes $LIBS"
3262cat > conftest.$ac_ext <<EOF
3263#line 3264 "configure"
3264#include "confdefs.h"
3265/* Override any gcc2 internal prototype to avoid an error.  */
3266/* We use char because int might match the return type of a gcc2
3267    builtin and then its argument prototype would still apply.  */
3268char krb_rd_req();
3269
3270int main() {
3271krb_rd_req()
3272; return 0; }
3273EOF
3274if { (eval echo configure:3275: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3275  rm -rf conftest*
3276  eval "ac_cv_lib_$ac_lib_var=yes"
3277else
3278  echo "configure: failed program was:" >&5
3279  cat conftest.$ac_ext >&5
3280  rm -rf conftest*
3281  eval "ac_cv_lib_$ac_lib_var=no"
3282fi
3283rm -f conftest*
3284LIBS="$ac_save_LIBS"
3285
3286fi
3287if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
3288  echo "$ac_t""yes" 1>&6
3289  KRB4_LIBS="-lkrb -ldes"
3290else
3291  echo "$ac_t""no" 1>&6
3292{ echo "configure: error: Kerberos 4 libraries not found" 1>&2; exit 1; }
3293fi
3294
3295fi
3296
3297fi
3298
3299
3300nmh_save_LIBS="$LIBS"
3301LIBS="$TERMLIB $LIBS"
3302
3303echo $ac_n "checking if an include file defines ospeed""... $ac_c" 1>&6
3304echo "configure:3305: checking if an include file defines ospeed" >&5
3305if eval "test \"`echo '$''{'nmh_cv_decl_ospeed_include_defines'+set}'`\" = set"; then
3306  echo $ac_n "(cached) $ac_c" 1>&6
3307else
3308  cat > conftest.$ac_ext <<EOF
3309#line 3310 "configure"
3310#include "confdefs.h"
3311#include <sys/types.h>
3312#if HAVE_TERMIOS_H
3313#include <termios.h>
3314#endif
3315#if HAVE_TERMCAP_H
3316#include <termcap.h>
3317#endif
3318int main() {
3319ospeed = 0;
3320; return 0; }
3321EOF
3322if { (eval echo configure:3323: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3323  rm -rf conftest*
3324  nmh_cv_decl_ospeed_include_defines=yes
3325else
3326  echo "configure: failed program was:" >&5
3327  cat conftest.$ac_ext >&5
3328  rm -rf conftest*
3329  nmh_cv_decl_ospeed_include_defines=no
3330fi
3331rm -f conftest*
3332fi
3333
3334echo "$ac_t""$nmh_cv_decl_ospeed_include_defines" 1>&6
3335 
3336if test $nmh_cv_decl_ospeed_include_defines = no; then
3337  echo $ac_n "checking if you must define ospeed""... $ac_c" 1>&6
3338echo "configure:3339: checking if you must define ospeed" >&5
3339if eval "test \"`echo '$''{'nmh_cv_decl_ospeed_must_define'+set}'`\" = set"; then
3340  echo $ac_n "(cached) $ac_c" 1>&6
3341else
3342  cat > conftest.$ac_ext <<EOF
3343#line 3344 "configure"
3344#include "confdefs.h"
3345
3346int main() {
3347extern short ospeed; ospeed = 0;
3348; return 0; }
3349EOF
3350if { (eval echo configure:3351: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
3351  rm -rf conftest*
3352  nmh_cv_decl_ospeed_must_define=yes
3353else
3354  echo "configure: failed program was:" >&5
3355  cat conftest.$ac_ext >&5
3356  rm -rf conftest*
3357  nmh_cv_decl_ospeed_must_define=no
3358fi
3359rm -f conftest*
3360fi
3361
3362echo "$ac_t""$nmh_cv_decl_ospeed_must_define" 1>&6
3363fi
3364 
3365if test $nmh_cv_decl_ospeed_include_defines = yes; then
3366  cat >> confdefs.h <<\EOF
3367#define HAVE_OSPEED 1
3368EOF
3369
3370elif test $nmh_cv_decl_ospeed_must_define = yes; then
3371  cat >> confdefs.h <<\EOF
3372#define HAVE_OSPEED 1
3373EOF
3374
3375  cat >> confdefs.h <<\EOF
3376#define MUST_DEFINE_OSPEED 1
3377EOF
3378
3379fi
3380
3381
3382LIBS="$nmh_save_LIBS"
3383
3384echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
3385echo "configure:3386: checking return type of signal handlers" >&5
3386if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
3387  echo $ac_n "(cached) $ac_c" 1>&6
3388else
3389  cat > conftest.$ac_ext <<EOF
3390#line 3391 "configure"
3391#include "confdefs.h"
3392#include <sys/types.h>
3393#include <signal.h>
3394#ifdef signal
3395#undef signal
3396#endif
3397#ifdef __cplusplus
3398extern "C" void (*signal (int, void (*)(int)))(int);
3399#else
3400void (*signal ()) ();
3401#endif
3402
3403int main() {
3404int i;
3405; return 0; }
3406EOF
3407if { (eval echo configure:3408: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3408  rm -rf conftest*
3409  ac_cv_type_signal=void
3410else
3411  echo "configure: failed program was:" >&5
3412  cat conftest.$ac_ext >&5
3413  rm -rf conftest*
3414  ac_cv_type_signal=int
3415fi
3416rm -f conftest*
3417fi
3418
3419echo "$ac_t""$ac_cv_type_signal" 1>&6
3420cat >> confdefs.h <<EOF
3421#define RETSIGTYPE $ac_cv_type_signal
3422EOF
3423
3424
3425echo $ac_n "checking for pid_t""... $ac_c" 1>&6
3426echo "configure:3427: checking for pid_t" >&5
3427if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
3428  echo $ac_n "(cached) $ac_c" 1>&6
3429else
3430  cat > conftest.$ac_ext <<EOF
3431#line 3432 "configure"
3432#include "confdefs.h"
3433#include <sys/types.h>
3434#if STDC_HEADERS
3435#include <stdlib.h>
3436#include <stddef.h>
3437#endif
3438EOF
3439if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3440  egrep "(^|[^a-zA-Z_0-9])pid_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3441  rm -rf conftest*
3442  ac_cv_type_pid_t=yes
3443else
3444  rm -rf conftest*
3445  ac_cv_type_pid_t=no
3446fi
3447rm -f conftest*
3448
3449fi
3450echo "$ac_t""$ac_cv_type_pid_t" 1>&6
3451if test $ac_cv_type_pid_t = no; then
3452  cat >> confdefs.h <<\EOF
3453#define pid_t int
3454EOF
3455
3456fi
3457
3458echo $ac_n "checking for off_t""... $ac_c" 1>&6
3459echo "configure:3460: checking for off_t" >&5
3460if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
3461  echo $ac_n "(cached) $ac_c" 1>&6
3462else
3463  cat > conftest.$ac_ext <<EOF
3464#line 3465 "configure"
3465#include "confdefs.h"
3466#include <sys/types.h>
3467#if STDC_HEADERS
3468#include <stdlib.h>
3469#include <stddef.h>
3470#endif
3471EOF
3472if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3473  egrep "(^|[^a-zA-Z_0-9])off_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3474  rm -rf conftest*
3475  ac_cv_type_off_t=yes
3476else
3477  rm -rf conftest*
3478  ac_cv_type_off_t=no
3479fi
3480rm -f conftest*
3481
3482fi
3483echo "$ac_t""$ac_cv_type_off_t" 1>&6
3484if test $ac_cv_type_off_t = no; then
3485  cat >> confdefs.h <<\EOF
3486#define off_t long
3487EOF
3488
3489fi
3490
3491echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
3492echo "configure:3493: checking for uid_t in sys/types.h" >&5
3493if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
3494  echo $ac_n "(cached) $ac_c" 1>&6
3495else
3496  cat > conftest.$ac_ext <<EOF
3497#line 3498 "configure"
3498#include "confdefs.h"
3499#include <sys/types.h>
3500EOF
3501if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3502  egrep "uid_t" >/dev/null 2>&1; then
3503  rm -rf conftest*
3504  ac_cv_type_uid_t=yes
3505else
3506  rm -rf conftest*
3507  ac_cv_type_uid_t=no
3508fi
3509rm -f conftest*
3510
3511fi
3512
3513echo "$ac_t""$ac_cv_type_uid_t" 1>&6
3514if test $ac_cv_type_uid_t = no; then
3515  cat >> confdefs.h <<\EOF
3516#define uid_t int
3517EOF
3518
3519  cat >> confdefs.h <<\EOF
3520#define gid_t int
3521EOF
3522
3523fi
3524
3525echo $ac_n "checking for mode_t""... $ac_c" 1>&6
3526echo "configure:3527: checking for mode_t" >&5
3527if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then
3528  echo $ac_n "(cached) $ac_c" 1>&6
3529else
3530  cat > conftest.$ac_ext <<EOF
3531#line 3532 "configure"
3532#include "confdefs.h"
3533#include <sys/types.h>
3534#if STDC_HEADERS
3535#include <stdlib.h>
3536#include <stddef.h>
3537#endif
3538EOF
3539if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3540  egrep "(^|[^a-zA-Z_0-9])mode_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3541  rm -rf conftest*
3542  ac_cv_type_mode_t=yes
3543else
3544  rm -rf conftest*
3545  ac_cv_type_mode_t=no
3546fi
3547rm -f conftest*
3548
3549fi
3550echo "$ac_t""$ac_cv_type_mode_t" 1>&6
3551if test $ac_cv_type_mode_t = no; then
3552  cat >> confdefs.h <<\EOF
3553#define mode_t int
3554EOF
3555
3556fi
3557
3558echo $ac_n "checking for size_t""... $ac_c" 1>&6
3559echo "configure:3560: checking for size_t" >&5
3560if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
3561  echo $ac_n "(cached) $ac_c" 1>&6
3562else
3563  cat > conftest.$ac_ext <<EOF
3564#line 3565 "configure"
3565#include "confdefs.h"
3566#include <sys/types.h>
3567#if STDC_HEADERS
3568#include <stdlib.h>
3569#include <stddef.h>
3570#endif
3571EOF
3572if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3573  egrep "(^|[^a-zA-Z_0-9])size_t[^a-zA-Z_0-9]" >/dev/null 2>&1; then
3574  rm -rf conftest*
3575  ac_cv_type_size_t=yes
3576else
3577  rm -rf conftest*
3578  ac_cv_type_size_t=no
3579fi
3580rm -f conftest*
3581
3582fi
3583echo "$ac_t""$ac_cv_type_size_t" 1>&6
3584if test $ac_cv_type_size_t = no; then
3585  cat >> confdefs.h <<\EOF
3586#define size_t unsigned
3587EOF
3588
3589fi
3590
3591
3592echo $ac_n "checking for sigset_t""... $ac_c" 1>&6
3593echo "configure:3594: checking for sigset_t" >&5
3594if eval "test \"`echo '$''{'nmh_cv_type_sigset_t'+set}'`\" = set"; then
3595  echo $ac_n "(cached) $ac_c" 1>&6
3596else
3597  cat > conftest.$ac_ext <<EOF
3598#line 3599 "configure"
3599#include "confdefs.h"
3600#include <sys/types.h>
3601#include <signal.h>
3602int main() {
3603sigset_t tempsigset;
3604; return 0; }
3605EOF
3606if { (eval echo configure:3607: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3607  rm -rf conftest*
3608  nmh_cv_type_sigset_t=yes
3609else
3610  echo "configure: failed program was:" >&5
3611  cat conftest.$ac_ext >&5
3612  rm -rf conftest*
3613  nmh_cv_type_sigset_t=no
3614fi
3615rm -f conftest*
3616fi
3617
3618echo "$ac_t""$nmh_cv_type_sigset_t" 1>&6
3619if test $nmh_cv_type_sigset_t = no; then
3620  cat >> confdefs.h <<\EOF
3621#define sigset_t unsigned int
3622EOF
3623
3624fi
3625
3626echo $ac_n "checking for st_blksize in struct stat""... $ac_c" 1>&6
3627echo "configure:3628: checking for st_blksize in struct stat" >&5
3628if eval "test \"`echo '$''{'ac_cv_struct_st_blksize'+set}'`\" = set"; then
3629  echo $ac_n "(cached) $ac_c" 1>&6
3630else
3631  cat > conftest.$ac_ext <<EOF
3632#line 3633 "configure"
3633#include "confdefs.h"
3634#include <sys/types.h>
3635#include <sys/stat.h>
3636int main() {
3637struct stat s; s.st_blksize;
3638; return 0; }
3639EOF
3640if { (eval echo configure:3641: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3641  rm -rf conftest*
3642  ac_cv_struct_st_blksize=yes
3643else
3644  echo "configure: failed program was:" >&5
3645  cat conftest.$ac_ext >&5
3646  rm -rf conftest*
3647  ac_cv_struct_st_blksize=no
3648fi
3649rm -f conftest*
3650fi
3651
3652echo "$ac_t""$ac_cv_struct_st_blksize" 1>&6
3653if test $ac_cv_struct_st_blksize = yes; then
3654  cat >> confdefs.h <<\EOF
3655#define HAVE_ST_BLKSIZE 1
3656EOF
3657
3658fi
3659
3660
3661echo $ac_n "checking for tm_gmtoff in struct tm""... $ac_c" 1>&6
3662echo "configure:3663: checking for tm_gmtoff in struct tm" >&5
3663if eval "test \"`echo '$''{'nmh_cv_struct_tm_gmtoff'+set}'`\" = set"; then
3664  echo $ac_n "(cached) $ac_c" 1>&6
3665else
3666  cat > conftest.$ac_ext <<EOF
3667#line 3668 "configure"
3668#include "confdefs.h"
3669#ifdef TIME_WITH_SYS_TIME
3670# include <sys/time.h>
3671# include <time.h>
3672#else
3673# ifdef TM_IN_SYS_TIME
3674#  include <sys/time.h>
3675# else
3676#  include <time.h>
3677# endif
3678#endif
3679int main() {
3680struct tm temptm; temptm.tm_gmtoff = 0;
3681; return 0; }
3682EOF
3683if { (eval echo configure:3684: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
3684  rm -rf conftest*
3685  nmh_cv_struct_tm_gmtoff=yes
3686else
3687  echo "configure: failed program was:" >&5
3688  cat conftest.$ac_ext >&5
3689  rm -rf conftest*
3690  nmh_cv_struct_tm_gmtoff=no
3691fi
3692rm -f conftest*
3693fi
3694
3695echo "$ac_t""$nmh_cv_struct_tm_gmtoff" 1>&6
3696if test $nmh_cv_struct_tm_gmtoff = yes; then
3697  cat >> confdefs.h <<\EOF
3698#define HAVE_TM_GMTOFF 1
3699EOF
3700
3701fi
3702
3703echo $ac_n "checking what style of signals to use""... $ac_c" 1>&6
3704echo "configure:3705: checking what style of signals to use" >&5
3705if test $ac_cv_func_sigaction = yes -a $ac_cv_func_sigprocmask = yes; then
3706  signals_style=POSIX_SIGNALS
3707  cat >> confdefs.h <<\EOF
3708#define POSIX_SIGNALS 1
3709EOF
3710
3711  cat >> confdefs.h <<\EOF
3712#define RELIABLE_SIGNALS 1
3713EOF
3714
3715elif test $ac_cv_func_sigblock = yes -a $ac_cv_func_sigsetmask = yes; then
3716  signals_style=BSD_SIGNALS
3717  cat >> confdefs.h <<\EOF
3718#define BSD_SIGNALS 1
3719EOF
3720
3721  cat >> confdefs.h <<\EOF
3722#define RELIABLE_SIGNALS 1
3723EOF
3724
3725elif test $ac_cv_func_sighold = yes -a $ac_cv_func_sigrelse = yes; then
3726  signals_style=SYSV_SIGNALS
3727  cat >> confdefs.h <<\EOF
3728#define SYSV_SIGNALS 1
3729EOF
3730
3731else
3732  signals_style=NO_SIGNAL_BLOCKING
3733  cat >> confdefs.h <<\EOF
3734#define NO_SIGNAL_BLOCKING 1
3735EOF
3736
3737fi
3738
3739echo "$ac_t""$signals_style" 1>&6
3740
3741echo $ac_n "checking where signal.h is located""... $ac_c" 1>&6
3742echo "configure:3743: checking where signal.h is located" >&5
3743if eval "test \"`echo '$''{'nmh_cv_path_signal_h'+set}'`\" = set"; then
3744  echo $ac_n "(cached) $ac_c" 1>&6
3745else
3746  for SIGNAL_H in /usr/include/bsd/sys/signal.h                   /usr/include/asm/signal.h                       /usr/include/asm/signum.h                       /usr/include/linux/signal.h                     /usr/include/sys/signal.h                       /dev/null;                     do
3747  test -f $SIGNAL_H && \
3748  grep '#[      ]*define[       ][      ]*SIG[0-9A-Z]*[         ]*[0-9][0-9]*' $SIGNAL_H > /dev/null && \
3749  break
3750done
3751nmh_cv_path_signal_h=$SIGNAL_H
3752
3753fi
3754
3755echo "$ac_t""$nmh_cv_path_signal_h" 1>&6
3756SIGNAL_H=$nmh_cv_path_signal_h
3757
3758trap '' 1 2 15
3759cat > confcache <<\EOF
3760# This file is a shell script that caches the results of configure
3761# tests run on this system so they can be shared between configure
3762# scripts and configure runs.  It is not useful on other systems.
3763# If it contains results you don't want to keep, you may remove or edit it.
3764#
3765# By default, configure uses ./config.cache as the cache file,
3766# creating it if it does not exist already.  You can give configure
3767# the --cache-file=FILE option to use a different cache file; that is
3768# what configure does when it calls configure scripts in
3769# subdirectories, so they share the cache.
3770# Giving --cache-file=/dev/null disables caching, for debugging configure.
3771# config.status only pays attention to the cache file if you give it the
3772# --recheck option to rerun configure.
3773#
3774EOF
3775# The following way of writing the cache mishandles newlines in values,
3776# but we know of no workaround that is simple, portable, and efficient.
3777# So, don't put newlines in cache variables' values.
3778# Ultrix sh set writes to stderr and can't be redirected directly,
3779# and sets the high bit in the cache file unless we assign to the vars.
3780(set) 2>&1 |
3781  case `(ac_space=' '; set | grep ac_space) 2>&1` in
3782  *ac_space=\ *)
3783    # `set' does not quote correctly, so add quotes (double-quote substitution
3784    # turns \\\\ into \\, and sed turns \\ into \).
3785    sed -n \
3786      -e "s/'/'\\\\''/g" \
3787      -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
3788    ;;
3789  *)
3790    # `set' quotes correctly as required by POSIX, so do not add quotes.
3791    sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
3792    ;;
3793  esac >> confcache
3794if cmp -s $cache_file confcache; then
3795  :
3796else
3797  if test -w $cache_file; then
3798    echo "updating cache $cache_file"
3799    cat confcache > $cache_file
3800  else
3801    echo "not updating unwritable cache $cache_file"
3802  fi
3803fi
3804rm -f confcache
3805
3806trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
3807
3808test "x$prefix" = xNONE && prefix=$ac_default_prefix
3809# Let make expand exec_prefix.
3810test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
3811
3812# Any assignment to VPATH causes Sun make to only execute
3813# the first set of double-colon rules, so remove it if not needed.
3814# If there is a colon in the path, we need to keep it.
3815if test "x$srcdir" = x.; then
3816  ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
3817fi
3818
3819trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
3820
3821DEFS=-DHAVE_CONFIG_H
3822
3823# Without the "./", some shells look in PATH for config.status.
3824: ${CONFIG_STATUS=./config.status}
3825
3826echo creating $CONFIG_STATUS
3827rm -f $CONFIG_STATUS
3828cat > $CONFIG_STATUS <<EOF
3829#! /bin/sh
3830# Generated automatically by configure.
3831# Run this file to recreate the current configuration.
3832# This directory was configured as follows,
3833# on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
3834#
3835# $0 $ac_configure_args
3836#
3837# Compiler output produced by configure, useful for debugging
3838# configure, is in ./config.log if it exists.
3839
3840ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
3841for ac_option
3842do
3843  case "\$ac_option" in
3844  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
3845    echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
3846    exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
3847  -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
3848    echo "$CONFIG_STATUS generated by autoconf version 2.13"
3849    exit 0 ;;
3850  -help | --help | --hel | --he | --h)
3851    echo "\$ac_cs_usage"; exit 0 ;;
3852  *) echo "\$ac_cs_usage"; exit 1 ;;
3853  esac
3854done
3855
3856ac_given_srcdir=$srcdir
3857ac_given_INSTALL="$INSTALL"
3858
3859trap 'rm -fr `echo "Makefile config/Makefile h/Makefile sbr/Makefile uip/Makefile \
3860          zotnet/Makefile zotnet/mts/Makefile zotnet/tws/Makefile \
3861          zotnet/mf/Makefile zotnet/bboards/Makefile mts/Makefile \
3862          mts/smtp/Makefile mts/sendmail/Makefile mts/mmdf/Makefile \
3863          etc/Makefile man/Makefile config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
3864EOF
3865cat >> $CONFIG_STATUS <<EOF
3866
3867# Protect against being on the right side of a sed subst in config.status.
3868sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
3869 s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
3870$ac_vpsub
3871$extrasub
3872s%@SHELL@%$SHELL%g
3873s%@CFLAGS@%$CFLAGS%g
3874s%@CPPFLAGS@%$CPPFLAGS%g
3875s%@CXXFLAGS@%$CXXFLAGS%g
3876s%@FFLAGS@%$FFLAGS%g
3877s%@DEFS@%$DEFS%g
3878s%@LDFLAGS@%$LDFLAGS%g
3879s%@LIBS@%$LIBS%g
3880s%@exec_prefix@%$exec_prefix%g
3881s%@prefix@%$prefix%g
3882s%@program_transform_name@%$program_transform_name%g
3883s%@bindir@%$bindir%g
3884s%@sbindir@%$sbindir%g
3885s%@libexecdir@%$libexecdir%g
3886s%@datadir@%$datadir%g
3887s%@sysconfdir@%$sysconfdir%g
3888s%@sharedstatedir@%$sharedstatedir%g
3889s%@localstatedir@%$localstatedir%g
3890s%@libdir@%$libdir%g
3891s%@includedir@%$includedir%g
3892s%@oldincludedir@%$oldincludedir%g
3893s%@infodir@%$infodir%g
3894s%@mandir@%$mandir%g
3895s%@VERSION@%$VERSION%g
3896s%@MTS@%$MTS%g
3897s%@MTSLIB@%$MTSLIB%g
3898s%@POPLIB@%$POPLIB%g
3899s%@POPSED@%$POPSED%g
3900s%@CC@%$CC%g
3901s%@SET_MAKE@%$SET_MAKE%g
3902s%@INSTALL_PROGRAM@%$INSTALL_PROGRAM%g
3903s%@INSTALL_SCRIPT@%$INSTALL_SCRIPT%g
3904s%@INSTALL_DATA@%$INSTALL_DATA%g
3905s%@RANLIB@%$RANLIB%g
3906s%@AWK@%$AWK%g
3907s%@LEX@%$LEX%g
3908s%@LEXLIB@%$LEXLIB%g
3909s%@LORDER@%$LORDER%g
3910s%@TSORT@%$TSORT%g
3911s%@sendmailpath@%$sendmailpath%g
3912s%@morepath@%$morepath%g
3913s%@pagerpath@%$pagerpath%g
3914s%@vipath@%$vipath%g
3915s%@editorpath@%$editorpath%g
3916s%@mailspool@%$mailspool%g
3917s%@CPP@%$CPP%g
3918s%@LIBOBJS@%$LIBOBJS%g
3919s%@TERMLIB@%$TERMLIB%g
3920s%@HESIOD_INCLUDES@%$HESIOD_INCLUDES%g
3921s%@HESIOD_LIBS@%$HESIOD_LIBS%g
3922s%@KRB4_INCLUDES@%$KRB4_INCLUDES%g
3923s%@KRB4_LIBS@%$KRB4_LIBS%g
3924s%@SIGNAL_H@%$SIGNAL_H%g
3925
3926CEOF
3927EOF
3928
3929cat >> $CONFIG_STATUS <<\EOF
3930
3931# Split the substitutions into bite-sized pieces for seds with
3932# small command number limits, like on Digital OSF/1 and HP-UX.
3933ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
3934ac_file=1 # Number of current file.
3935ac_beg=1 # First line for current file.
3936ac_end=$ac_max_sed_cmds # Line after last line for current file.
3937ac_more_lines=:
3938ac_sed_cmds=""
3939while $ac_more_lines; do
3940  if test $ac_beg -gt 1; then
3941    sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
3942  else
3943    sed "${ac_end}q" conftest.subs > conftest.s$ac_file
3944  fi
3945  if test ! -s conftest.s$ac_file; then
3946    ac_more_lines=false
3947    rm -f conftest.s$ac_file
3948  else
3949    if test -z "$ac_sed_cmds"; then
3950      ac_sed_cmds="sed -f conftest.s$ac_file"
3951    else
3952      ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
3953    fi
3954    ac_file=`expr $ac_file + 1`
3955    ac_beg=$ac_end
3956    ac_end=`expr $ac_end + $ac_max_sed_cmds`
3957  fi
3958done
3959if test -z "$ac_sed_cmds"; then
3960  ac_sed_cmds=cat
3961fi
3962EOF
3963
3964cat >> $CONFIG_STATUS <<EOF
3965
3966CONFIG_FILES=\${CONFIG_FILES-"Makefile config/Makefile h/Makefile sbr/Makefile uip/Makefile \
3967          zotnet/Makefile zotnet/mts/Makefile zotnet/tws/Makefile \
3968          zotnet/mf/Makefile zotnet/bboards/Makefile mts/Makefile \
3969          mts/smtp/Makefile mts/sendmail/Makefile mts/mmdf/Makefile \
3970          etc/Makefile man/Makefile"}
3971EOF
3972cat >> $CONFIG_STATUS <<\EOF
3973for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
3974  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
3975  case "$ac_file" in
3976  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
3977       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
3978  *) ac_file_in="${ac_file}.in" ;;
3979  esac
3980
3981  # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
3982
3983  # Remove last slash and all that follows it.  Not all systems have dirname.
3984  ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
3985  if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
3986    # The file is in a subdirectory.
3987    test ! -d "$ac_dir" && mkdir "$ac_dir"
3988    ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
3989    # A "../" for each directory in $ac_dir_suffix.
3990    ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
3991  else
3992    ac_dir_suffix= ac_dots=
3993  fi
3994
3995  case "$ac_given_srcdir" in
3996  .)  srcdir=.
3997      if test -z "$ac_dots"; then top_srcdir=.
3998      else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
3999  /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
4000  *) # Relative path.
4001    srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
4002    top_srcdir="$ac_dots$ac_given_srcdir" ;;
4003  esac
4004
4005  case "$ac_given_INSTALL" in
4006  [/$]*) INSTALL="$ac_given_INSTALL" ;;
4007  *) INSTALL="$ac_dots$ac_given_INSTALL" ;;
4008  esac
4009
4010  echo creating "$ac_file"
4011  rm -f "$ac_file"
4012  configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
4013  case "$ac_file" in
4014  *Makefile*) ac_comsub="1i\\
4015# $configure_input" ;;
4016  *) ac_comsub= ;;
4017  esac
4018
4019  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
4020  sed -e "$ac_comsub
4021s%@configure_input@%$configure_input%g
4022s%@srcdir@%$srcdir%g
4023s%@top_srcdir@%$top_srcdir%g
4024s%@INSTALL@%$INSTALL%g
4025" $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
4026fi; done
4027rm -f conftest.s*
4028
4029# These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
4030# NAME is the cpp macro being defined and VALUE is the value it is being given.
4031#
4032# ac_d sets the value in "#define NAME VALUE" lines.
4033ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
4034ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
4035ac_dC='\3'
4036ac_dD='%g'
4037# ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
4038ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
4039ac_uB='\([      ]\)%\1#\2define\3'
4040ac_uC=' '
4041ac_uD='\4%g'
4042# ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
4043ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
4044ac_eB='$%\1#\2define\3'
4045ac_eC=' '
4046ac_eD='%g'
4047
4048if test "${CONFIG_HEADERS+set}" != set; then
4049EOF
4050cat >> $CONFIG_STATUS <<EOF
4051  CONFIG_HEADERS="config.h"
4052EOF
4053cat >> $CONFIG_STATUS <<\EOF
4054fi
4055for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
4056  # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
4057  case "$ac_file" in
4058  *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
4059       ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
4060  *) ac_file_in="${ac_file}.in" ;;
4061  esac
4062
4063  echo creating $ac_file
4064
4065  rm -f conftest.frag conftest.in conftest.out
4066  ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
4067  cat $ac_file_inputs > conftest.in
4068
4069EOF
4070
4071# Transform confdefs.h into a sed script conftest.vals that substitutes
4072# the proper values into config.h.in to produce config.h.  And first:
4073# Protect against being on the right side of a sed subst in config.status.
4074# Protect against being in an unquoted here document in config.status.
4075rm -f conftest.vals
4076cat > conftest.hdr <<\EOF
4077s/[\\&%]/\\&/g
4078s%[\\$`]%\\&%g
4079s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
4080s%ac_d%ac_u%gp
4081s%ac_u%ac_e%gp
4082EOF
4083sed -n -f conftest.hdr confdefs.h > conftest.vals
4084rm -f conftest.hdr
4085
4086# This sed command replaces #undef with comments.  This is necessary, for
4087# example, in the case of _POSIX_SOURCE, which is predefined and required
4088# on some systems where configure will not decide to define it.
4089cat >> conftest.vals <<\EOF
4090s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
4091EOF
4092
4093# Break up conftest.vals because some shells have a limit on
4094# the size of here documents, and old seds have small limits too.
4095
4096rm -f conftest.tail
4097while :
4098do
4099  ac_lines=`grep -c . conftest.vals`
4100  # grep -c gives empty output for an empty file on some AIX systems.
4101  if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
4102  # Write a limited-size here document to conftest.frag.
4103  echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
4104  sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
4105  echo 'CEOF
4106  sed -f conftest.frag conftest.in > conftest.out
4107  rm -f conftest.in
4108  mv conftest.out conftest.in
4109' >> $CONFIG_STATUS
4110  sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
4111  rm -f conftest.vals
4112  mv conftest.tail conftest.vals
4113done
4114rm -f conftest.vals
4115
4116cat >> $CONFIG_STATUS <<\EOF
4117  rm -f conftest.frag conftest.h
4118  echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
4119  cat conftest.in >> conftest.h
4120  rm -f conftest.in
4121  if cmp -s $ac_file conftest.h 2>/dev/null; then
4122    echo "$ac_file is unchanged"
4123    rm -f conftest.h
4124  else
4125    # Remove last slash and all that follows it.  Not all systems have dirname.
4126      ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
4127      if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
4128      # The file is in a subdirectory.
4129      test ! -d "$ac_dir" && mkdir "$ac_dir"
4130    fi
4131    rm -f $ac_file
4132    mv conftest.h $ac_file
4133  fi
4134fi; done
4135
4136EOF
4137cat >> $CONFIG_STATUS <<EOF
4138
4139EOF
4140cat >> $CONFIG_STATUS <<\EOF
4141\
4142          test -z "$CONFIG_HEADERS" || echo > stamp-h
4143exit 0
4144EOF
4145chmod +x $CONFIG_STATUS
4146rm -fr confdefs* $ac_clean_files
4147test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
4148
4149
4150eval "nmhbin=${bindir}";         eval "nmhbin2=${nmhbin}"
4151eval "nmhsysconf=${sysconfdir}"; eval "nmhsysconf2=${nmhsysconf}"
4152eval "nmhlib=${libdir}";         eval "nmhlib2=${nmhlib}"
4153eval "nmhman=${mandir}"
4154
4155echo "
4156nmh configuration
4157-----------------
4158nmh version               : ${VERSION}
4159compiler                  : ${CC}
4160compiler flags            : ${CFLAGS}
4161linker flags              : ${LDFLAGS}
4162source code location      : ${srcdir}
4163binary install path       : ${nmhbin2}
4164libary install path       : ${nmhlib2}
4165config files install path : ${nmhsysconf2}
4166man page install path     : ${nmhman}
4167transport system          : ${MTS}
4168default editor            : ${editorpath}
4169default pager             : ${pagerpath}"
4170echo ""
Note: See TracBrowser for help on using the repository browser.