Add SIGCKPT support to tcsh's built-in kill.
[dragonfly.git] / contrib / tcsh / configure
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:
11 ac_help=
12 ac_default_prefix=/usr/local
13 # Any additions from configure.in:
14 ac_help="$ac_help
15   --with-hesiod=PREFIX    Use Hesiod lookup for ~ expansion"
16
17 # Initialize some variables set by options.
18 # The variables have the same names as the options, with
19 # dashes changed to underlines.
20 build=NONE
21 cache_file=./config.cache
22 exec_prefix=NONE
23 host=NONE
24 no_create=
25 nonopt=NONE
26 no_recursion=
27 prefix=NONE
28 program_prefix=NONE
29 program_suffix=NONE
30 program_transform_name=s,x,x,
31 silent=
32 site=
33 srcdir=
34 target=NONE
35 verbose=
36 x_includes=NONE
37 x_libraries=NONE
38 bindir='${exec_prefix}/bin'
39 sbindir='${exec_prefix}/sbin'
40 libexecdir='${exec_prefix}/libexec'
41 datadir='${prefix}/share'
42 sysconfdir='${prefix}/etc'
43 sharedstatedir='${prefix}/com'
44 localstatedir='${prefix}/var'
45 libdir='${exec_prefix}/lib'
46 includedir='${prefix}/include'
47 oldincludedir='/usr/include'
48 infodir='${prefix}/info'
49 mandir='${prefix}/man'
50
51 # Initialize some other variables.
52 subdirs=
53 MFLAGS= MAKEFLAGS=
54 SHELL=${CONFIG_SHELL-/bin/sh}
55 # Maximum number of lines to put in a shell here document.
56 ac_max_here_lines=12
57
58 ac_prev=
59 for ac_option
60 do
61
62   # If the previous option needs an argument, assign it.
63   if test -n "$ac_prev"; then
64     eval "$ac_prev=\$ac_option"
65     ac_prev=
66     continue
67   fi
68
69   case "$ac_option" in
70   -*=*) ac_optarg=`echo "$ac_option" | sed 's/[-_a-zA-Z0-9]*=//'` ;;
71   *) ac_optarg= ;;
72   esac
73
74   # Accept the important Cygnus configure options, so we can diagnose typos.
75
76   case "$ac_option" in
77
78   -bindir | --bindir | --bindi | --bind | --bin | --bi)
79     ac_prev=bindir ;;
80   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
81     bindir="$ac_optarg" ;;
82
83   -build | --build | --buil | --bui | --bu)
84     ac_prev=build ;;
85   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
86     build="$ac_optarg" ;;
87
88   -cache-file | --cache-file | --cache-fil | --cache-fi \
89   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
90     ac_prev=cache_file ;;
91   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
92   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
93     cache_file="$ac_optarg" ;;
94
95   -datadir | --datadir | --datadi | --datad | --data | --dat | --da)
96     ac_prev=datadir ;;
97   -datadir=* | --datadir=* | --datadi=* | --datad=* | --data=* | --dat=* \
98   | --da=*)
99     datadir="$ac_optarg" ;;
100
101   -disable-* | --disable-*)
102     ac_feature=`echo $ac_option|sed -e 's/-*disable-//'`
103     # Reject names that are not valid shell variable names.
104     if test -n "`echo $ac_feature| sed 's/[-a-zA-Z0-9_]//g'`"; then
105       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
106     fi
107     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
108     eval "enable_${ac_feature}=no" ;;
109
110   -enable-* | --enable-*)
111     ac_feature=`echo $ac_option|sed -e 's/-*enable-//' -e 's/=.*//'`
112     # Reject names that are not valid shell variable names.
113     if test -n "`echo $ac_feature| sed 's/[-_a-zA-Z0-9]//g'`"; then
114       { echo "configure: error: $ac_feature: invalid feature name" 1>&2; exit 1; }
115     fi
116     ac_feature=`echo $ac_feature| sed 's/-/_/g'`
117     case "$ac_option" in
118       *=*) ;;
119       *) ac_optarg=yes ;;
120     esac
121     eval "enable_${ac_feature}='$ac_optarg'" ;;
122
123   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
124   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
125   | --exec | --exe | --ex)
126     ac_prev=exec_prefix ;;
127   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
128   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
129   | --exec=* | --exe=* | --ex=*)
130     exec_prefix="$ac_optarg" ;;
131
132   -gas | --gas | --ga | --g)
133     # Obsolete; use --with-gas.
134     with_gas=yes ;;
135
136   -help | --help | --hel | --he)
137     # Omit some internal or obsolete options to make the list less imposing.
138     # This message is too long to be a string in the A/UX 3.1 sh.
139     cat << EOF
140 Usage: configure [options] [host]
141 Options: [defaults in brackets after descriptions]
142 Configuration:
143   --cache-file=FILE       cache test results in FILE
144   --help                  print this message
145   --no-create             do not create output files
146   --quiet, --silent       do not print \`checking...' messages
147   --version               print the version of autoconf that created configure
148 Directory and file names:
149   --prefix=PREFIX         install architecture-independent files in PREFIX
150                           [$ac_default_prefix]
151   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
152                           [same as prefix]
153   --bindir=DIR            user executables in DIR [EPREFIX/bin]
154   --sbindir=DIR           system admin executables in DIR [EPREFIX/sbin]
155   --libexecdir=DIR        program executables in DIR [EPREFIX/libexec]
156   --datadir=DIR           read-only architecture-independent data in DIR
157                           [PREFIX/share]
158   --sysconfdir=DIR        read-only single-machine data in DIR [PREFIX/etc]
159   --sharedstatedir=DIR    modifiable architecture-independent data in DIR
160                           [PREFIX/com]
161   --localstatedir=DIR     modifiable single-machine data in DIR [PREFIX/var]
162   --libdir=DIR            object code libraries in DIR [EPREFIX/lib]
163   --includedir=DIR        C header files in DIR [PREFIX/include]
164   --oldincludedir=DIR     C header files for non-gcc in DIR [/usr/include]
165   --infodir=DIR           info documentation in DIR [PREFIX/info]
166   --mandir=DIR            man documentation in DIR [PREFIX/man]
167   --srcdir=DIR            find the sources in DIR [configure dir or ..]
168   --program-prefix=PREFIX prepend PREFIX to installed program names
169   --program-suffix=SUFFIX append SUFFIX to installed program names
170   --program-transform-name=PROGRAM
171                           run sed PROGRAM on installed program names
172 EOF
173     cat << EOF
174 Host type:
175   --build=BUILD           configure for building on BUILD [BUILD=HOST]
176   --host=HOST             configure for HOST [guessed]
177   --target=TARGET         configure for TARGET [TARGET=HOST]
178 Features and packages:
179   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
180   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
181   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
182   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
183   --x-includes=DIR        X include files are in DIR
184   --x-libraries=DIR       X library files are in DIR
185 EOF
186     if test -n "$ac_help"; then
187       echo "--enable and --with options recognized:$ac_help"
188     fi
189     exit 0 ;;
190
191   -host | --host | --hos | --ho)
192     ac_prev=host ;;
193   -host=* | --host=* | --hos=* | --ho=*)
194     host="$ac_optarg" ;;
195
196   -includedir | --includedir | --includedi | --included | --include \
197   | --includ | --inclu | --incl | --inc)
198     ac_prev=includedir ;;
199   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
200   | --includ=* | --inclu=* | --incl=* | --inc=*)
201     includedir="$ac_optarg" ;;
202
203   -infodir | --infodir | --infodi | --infod | --info | --inf)
204     ac_prev=infodir ;;
205   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
206     infodir="$ac_optarg" ;;
207
208   -libdir | --libdir | --libdi | --libd)
209     ac_prev=libdir ;;
210   -libdir=* | --libdir=* | --libdi=* | --libd=*)
211     libdir="$ac_optarg" ;;
212
213   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
214   | --libexe | --libex | --libe)
215     ac_prev=libexecdir ;;
216   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
217   | --libexe=* | --libex=* | --libe=*)
218     libexecdir="$ac_optarg" ;;
219
220   -localstatedir | --localstatedir | --localstatedi | --localstated \
221   | --localstate | --localstat | --localsta | --localst \
222   | --locals | --local | --loca | --loc | --lo)
223     ac_prev=localstatedir ;;
224   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
225   | --localstate=* | --localstat=* | --localsta=* | --localst=* \
226   | --locals=* | --local=* | --loca=* | --loc=* | --lo=*)
227     localstatedir="$ac_optarg" ;;
228
229   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
230     ac_prev=mandir ;;
231   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
232     mandir="$ac_optarg" ;;
233
234   -nfp | --nfp | --nf)
235     # Obsolete; use --without-fp.
236     with_fp=no ;;
237
238   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
239   | --no-cr | --no-c)
240     no_create=yes ;;
241
242   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
243   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
244     no_recursion=yes ;;
245
246   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
247   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
248   | --oldin | --oldi | --old | --ol | --o)
249     ac_prev=oldincludedir ;;
250   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
251   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
252   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
253     oldincludedir="$ac_optarg" ;;
254
255   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
256     ac_prev=prefix ;;
257   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
258     prefix="$ac_optarg" ;;
259
260   -program-prefix | --program-prefix | --program-prefi | --program-pref \
261   | --program-pre | --program-pr | --program-p)
262     ac_prev=program_prefix ;;
263   -program-prefix=* | --program-prefix=* | --program-prefi=* \
264   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
265     program_prefix="$ac_optarg" ;;
266
267   -program-suffix | --program-suffix | --program-suffi | --program-suff \
268   | --program-suf | --program-su | --program-s)
269     ac_prev=program_suffix ;;
270   -program-suffix=* | --program-suffix=* | --program-suffi=* \
271   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
272     program_suffix="$ac_optarg" ;;
273
274   -program-transform-name | --program-transform-name \
275   | --program-transform-nam | --program-transform-na \
276   | --program-transform-n | --program-transform- \
277   | --program-transform | --program-transfor \
278   | --program-transfo | --program-transf \
279   | --program-trans | --program-tran \
280   | --progr-tra | --program-tr | --program-t)
281     ac_prev=program_transform_name ;;
282   -program-transform-name=* | --program-transform-name=* \
283   | --program-transform-nam=* | --program-transform-na=* \
284   | --program-transform-n=* | --program-transform-=* \
285   | --program-transform=* | --program-transfor=* \
286   | --program-transfo=* | --program-transf=* \
287   | --program-trans=* | --program-tran=* \
288   | --progr-tra=* | --program-tr=* | --program-t=*)
289     program_transform_name="$ac_optarg" ;;
290
291   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
292   | -silent | --silent | --silen | --sile | --sil)
293     silent=yes ;;
294
295   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
296     ac_prev=sbindir ;;
297   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
298   | --sbi=* | --sb=*)
299     sbindir="$ac_optarg" ;;
300
301   -sharedstatedir | --sharedstatedir | --sharedstatedi \
302   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
303   | --sharedst | --shareds | --shared | --share | --shar \
304   | --sha | --sh)
305     ac_prev=sharedstatedir ;;
306   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
307   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
308   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
309   | --sha=* | --sh=*)
310     sharedstatedir="$ac_optarg" ;;
311
312   -site | --site | --sit)
313     ac_prev=site ;;
314   -site=* | --site=* | --sit=*)
315     site="$ac_optarg" ;;
316
317   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
318     ac_prev=srcdir ;;
319   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
320     srcdir="$ac_optarg" ;;
321
322   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
323   | --syscon | --sysco | --sysc | --sys | --sy)
324     ac_prev=sysconfdir ;;
325   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
326   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
327     sysconfdir="$ac_optarg" ;;
328
329   -target | --target | --targe | --targ | --tar | --ta | --t)
330     ac_prev=target ;;
331   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
332     target="$ac_optarg" ;;
333
334   -v | -verbose | --verbose | --verbos | --verbo | --verb)
335     verbose=yes ;;
336
337   -version | --version | --versio | --versi | --vers)
338     echo "configure generated by autoconf version 2.13"
339     exit 0 ;;
340
341   -with-* | --with-*)
342     ac_package=`echo $ac_option|sed -e 's/-*with-//' -e 's/=.*//'`
343     # Reject names that are not valid shell variable names.
344     if test -n "`echo $ac_package| sed 's/[-_a-zA-Z0-9]//g'`"; then
345       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
346     fi
347     ac_package=`echo $ac_package| sed 's/-/_/g'`
348     case "$ac_option" in
349       *=*) ;;
350       *) ac_optarg=yes ;;
351     esac
352     eval "with_${ac_package}='$ac_optarg'" ;;
353
354   -without-* | --without-*)
355     ac_package=`echo $ac_option|sed -e 's/-*without-//'`
356     # Reject names that are not valid shell variable names.
357     if test -n "`echo $ac_package| sed 's/[-a-zA-Z0-9_]//g'`"; then
358       { echo "configure: error: $ac_package: invalid package name" 1>&2; exit 1; }
359     fi
360     ac_package=`echo $ac_package| sed 's/-/_/g'`
361     eval "with_${ac_package}=no" ;;
362
363   --x)
364     # Obsolete; use --with-x.
365     with_x=yes ;;
366
367   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
368   | --x-incl | --x-inc | --x-in | --x-i)
369     ac_prev=x_includes ;;
370   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
371   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
372     x_includes="$ac_optarg" ;;
373
374   -x-libraries | --x-libraries | --x-librarie | --x-librari \
375   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
376     ac_prev=x_libraries ;;
377   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
378   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
379     x_libraries="$ac_optarg" ;;
380
381   -*) { echo "configure: error: $ac_option: invalid option; use --help to show usage" 1>&2; exit 1; }
382     ;;
383
384   *)
385     if test -n "`echo $ac_option| sed 's/[-a-z0-9.]//g'`"; then
386       echo "configure: warning: $ac_option: invalid host type" 1>&2
387     fi
388     if test "x$nonopt" != xNONE; then
389       { echo "configure: error: can only configure for one host and one target at a time" 1>&2; exit 1; }
390     fi
391     nonopt="$ac_option"
392     ;;
393
394   esac
395 done
396
397 if test -n "$ac_prev"; then
398   { echo "configure: error: missing argument to --`echo $ac_prev | sed 's/_/-/g'`" 1>&2; exit 1; }
399 fi
400
401 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
402
403 # File descriptor usage:
404 # 0 standard input
405 # 1 file creation
406 # 2 errors and warnings
407 # 3 some systems may open it to /dev/tty
408 # 4 used on the Kubota Titan
409 # 6 checking for... messages and results
410 # 5 compiler messages saved in config.log
411 if test "$silent" = yes; then
412   exec 6>/dev/null
413 else
414   exec 6>&1
415 fi
416 exec 5>./config.log
417
418 echo "\
419 This file contains any messages produced by compilers while
420 running configure, to aid debugging if configure makes a mistake.
421 " 1>&5
422
423 # Strip out --no-create and --no-recursion so they do not pile up.
424 # Also quote any args containing shell metacharacters.
425 ac_configure_args=
426 for ac_arg
427 do
428   case "$ac_arg" in
429   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
430   | --no-cr | --no-c) ;;
431   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
432   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) ;;
433   *" "*|*"      "*|*[\[\]\~\#\$\^\&\*\(\)\{\}\\\|\;\<\>\?]*)
434   ac_configure_args="$ac_configure_args '$ac_arg'" ;;
435   *) ac_configure_args="$ac_configure_args $ac_arg" ;;
436   esac
437 done
438
439 # NLS nuisances.
440 # Only set these to C if already set.  These must not be set unconditionally
441 # because not all systems understand e.g. LANG=C (notably SCO).
442 # Fixing LC_MESSAGES prevents Solaris sh from translating var values in `set'!
443 # Non-C LC_CTYPE values break the ctype check.
444 if test "${LANG+set}"   = set; then LANG=C;   export LANG;   fi
445 if test "${LC_ALL+set}" = set; then LC_ALL=C; export LC_ALL; fi
446 if test "${LC_MESSAGES+set}" = set; then LC_MESSAGES=C; export LC_MESSAGES; fi
447 if test "${LC_CTYPE+set}"    = set; then LC_CTYPE=C;    export LC_CTYPE;    fi
448
449 # confdefs.h avoids OS command line length limits that DEFS can exceed.
450 rm -rf conftest* confdefs.h
451 # AIX cpp loses on an empty file, so make sure it contains at least a newline.
452 echo > confdefs.h
453
454 # A filename unique to this package, relative to the directory that
455 # configure is in, which we can look for to find out if srcdir is correct.
456 ac_unique_file=tc.vers.c
457
458 # Find the source files, if location was not specified.
459 if test -z "$srcdir"; then
460   ac_srcdir_defaulted=yes
461   # Try the directory containing this script, then its parent.
462   ac_prog=$0
463   ac_confdir=`echo $ac_prog|sed 's%/[^/][^/]*$%%'`
464   test "x$ac_confdir" = "x$ac_prog" && ac_confdir=.
465   srcdir=$ac_confdir
466   if test ! -r $srcdir/$ac_unique_file; then
467     srcdir=..
468   fi
469 else
470   ac_srcdir_defaulted=no
471 fi
472 if test ! -r $srcdir/$ac_unique_file; then
473   if test "$ac_srcdir_defaulted" = yes; then
474     { echo "configure: error: can not find sources in $ac_confdir or .." 1>&2; exit 1; }
475   else
476     { echo "configure: error: can not find sources in $srcdir" 1>&2; exit 1; }
477   fi
478 fi
479 srcdir=`echo "${srcdir}" | sed 's%\([^/]\)/*$%\1%'`
480
481 # Prefer explicitly selected file to automatically selected ones.
482 if test -z "$CONFIG_SITE"; then
483   if test "x$prefix" != xNONE; then
484     CONFIG_SITE="$prefix/share/config.site $prefix/etc/config.site"
485   else
486     CONFIG_SITE="$ac_default_prefix/share/config.site $ac_default_prefix/etc/config.site"
487   fi
488 fi
489 for ac_site_file in $CONFIG_SITE; do
490   if test -r "$ac_site_file"; then
491     echo "loading site script $ac_site_file"
492     . "$ac_site_file"
493   fi
494 done
495
496 if test -r "$cache_file"; then
497   echo "loading cache $cache_file"
498   . $cache_file
499 else
500   echo "creating cache $cache_file"
501   > $cache_file
502 fi
503
504 ac_ext=c
505 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
506 ac_cpp='$CPP $CPPFLAGS'
507 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
508 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
509 cross_compiling=$ac_cv_prog_cc_cross
510
511 ac_exeext=
512 ac_objext=o
513 if (echo "testing\c"; echo 1,2,3) | grep c >/dev/null; then
514   # Stardent Vistra SVR4 grep lacks -e, says ghazi@caip.rutgers.edu.
515   if (echo -n testing; echo 1,2,3) | sed s/-n/xn/ | grep xn >/dev/null; then
516     ac_n= ac_c='
517 ' ac_t='        '
518   else
519     ac_n=-n ac_c= ac_t=
520   fi
521 else
522   ac_n= ac_c='\c' ac_t=
523 fi
524
525
526
527 ac_aux_dir=
528 for ac_dir in $srcdir $srcdir/.. $srcdir/../..; do
529   if test -f $ac_dir/install-sh; then
530     ac_aux_dir=$ac_dir
531     ac_install_sh="$ac_aux_dir/install-sh -c"
532     break
533   elif test -f $ac_dir/install.sh; then
534     ac_aux_dir=$ac_dir
535     ac_install_sh="$ac_aux_dir/install.sh -c"
536     break
537   fi
538 done
539 if test -z "$ac_aux_dir"; then
540   { echo "configure: error: can not find install-sh or install.sh in $srcdir $srcdir/.. $srcdir/../.." 1>&2; exit 1; }
541 fi
542 ac_config_guess=$ac_aux_dir/config.guess
543 ac_config_sub=$ac_aux_dir/config.sub
544 ac_configure=$ac_aux_dir/configure # This should be Cygnus configure.
545
546
547 # Make sure we can run config.sub.
548 if ${CONFIG_SHELL-/bin/sh} $ac_config_sub sun4 >/dev/null 2>&1; then :
549 else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
550 fi
551
552 echo $ac_n "checking host system type""... $ac_c" 1>&6
553 echo "configure:554: checking host system type" >&5
554
555 host_alias=$host
556 case "$host_alias" in
557 NONE)
558   case $nonopt in
559   NONE)
560     if host_alias=`${CONFIG_SHELL-/bin/sh} $ac_config_guess`; then :
561     else { echo "configure: error: can not guess host type; you must specify one" 1>&2; exit 1; }
562     fi ;;
563   *) host_alias=$nonopt ;;
564   esac ;;
565 esac
566
567 host=`${CONFIG_SHELL-/bin/sh} $ac_config_sub $host_alias`
568 host_cpu=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\1/'`
569 host_vendor=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\2/'`
570 host_os=`echo $host | sed 's/^\([^-]*\)-\([^-]*\)-\(.*\)$/\3/'`
571 echo "$ac_t""$host" 1>&6
572
573
574 echo $ac_n "checking cached host tuple""... $ac_c" 1>&6
575 echo "configure:576: checking cached host tuple" >&5
576 if { test x"${ac_cv_host_system_type+set}" = x"set" &&
577      test x"$ac_cv_host_system_type" != x"$host"; }; then
578   echo "$ac_t""different" 1>&6
579   { echo "configure: error: remove config.cache and re-run configure" 1>&2; exit 1; }
580 else
581   echo "$ac_t""ok" 1>&6
582 fi
583 ac_cv_host_system_type="$host"
584
585
586
587 case "${host}" in
588
589   ## Alpha (DEC) machines.
590   alpha*-dec-osf* )
591     tcsh_config_file=decosf1
592   ;;
593
594   ## Ultrix
595   *-dec-ultrix* )
596     tcsh_config_file=ultrix
597   ;;
598
599   ## DGUX
600   *-dg-dguxR4* )
601     tcsh_config_file=dgux5.4
602   ;;
603   m88k-dg-dgux5.4R* )
604     tcsh_config_file=dgux5.4
605   ;;
606
607   ## HP/UX
608   *-hp-hpux7* )
609     tcsh_config_file=hpux7
610   ;;
611   *-hp-hpux[89]* )
612     tcsh_config_file=hpux8
613   ;;
614   *-hp-hpux1[0-9]* )
615     tcsh_config_file=hpux11
616   ;;
617
618   ## IBM AIX systems
619   *-ibm-aix*)
620     tcsh_config_file=aix
621   ;;
622
623   ## SX-4
624   sx4-nec-*)
625     CC='cc -h0,ansi,novector,float0'
626     LDFLAGS='-Gsmall'
627     tcsh_config_file=superux8
628   ;;
629
630   ## IBM OS/390 systems
631   *-ibm-os390*)
632     CC='c89'
633     tcsh_config_file=os390
634   ;;
635
636   ## Linux
637   *-*-linux* )
638     tcsh_config_file=linux
639   ;;
640
641   ## Motorola systems
642   m68k-motorola-sysv* )
643     tcsh_config_file=sysV68
644   ;;
645   m88k-motorola-sysv3* )
646     tcsh_config_file=sysV88
647   ;;
648
649   ## NetBSD systems
650   *-*-netbsd*)
651     tcsh_config_file=bsd4.4
652   ;;
653
654   ## FreeBSD systems
655   *-*-freebsd*)
656     tcsh_config_file=bsd4.4
657   ;;
658
659   ## OpenBSD systems
660   *-*-openbsd*)
661     tcsh_config_file=bsd4.4
662   ;;
663
664   ## BSDI systems
665   *-*-bsdi*)
666     tcsh_config_file=bsd4.4
667   ;;
668
669   ## Mac OS X Server
670   *-*-rhapsody* )
671     tcsh_config_file=bsd4.4
672   ;;
673
674   ## Mac OS X Server
675   *-*-darwin* )
676     tcsh_config_file=bsd4.4
677   ;;
678
679   ## Silicon Graphics machines
680   *-sgi-iri* )
681     tcsh_config_file=irix
682     case "${host_os}" in
683       irix[34]*) # Irix-3.x - Irix 4.x
684         NON_GNU_DFLAGS='-D__STDC__'
685         LIBS='-lsun -lbsd -lc_s'
686       ;;
687       irix5* | irix6.[01]*) # Irix 5.x, Irix 6.0 - 6.1
688         LIBS='-lbsd'
689       ;;
690       irix6.[2-9]*) # Irix 6.2 and later
691         tcsh_config_file=irix62
692       ;;
693     esac
694   ;;
695
696   ## Suns
697   *-sun-sunos3* )
698     tcsh_config_file=sunos35
699   ;;
700   *-sun-sunos4.0* )
701     tcsh_config_file=sunos40
702   ;;
703   *-sun-sunos4.1.[12]* )
704     tcsh_config_file=sunos41
705   ;;
706   *-sun-sunos4.1.[3456]* )
707     tcsh_config_file=sunos413
708   ;;
709   *-*-solaris2.[01]* ) # Should handle sparc or x86
710     tcsh_config_file=sol2
711   ;;
712   *-sun-solaris2.2* ) # Sparc only release
713     tcsh_config_file=sol22
714   ;;
715   *-sun-solaris2.3* ) # Sparc only release
716     tcsh_config_file=sol23
717   ;;
718   *-*-solaris2.[45]* ) # Should handle sparc, x86 and powerpc
719     tcsh_config_file=sol24
720   ;;
721   *-*-solaris2.* ) # Should handle sparc, x86 and powerpc
722     tcsh_config_file=sol26
723   ;;
724
725   ## Dell SVR4
726   *-dell-sysv4* )
727     tcsh_config_file=sysv4
728     DFLAGS="$DFLAGS -DDELL"
729   ;;
730
731   ## SVR4 (Generic and otherwise)
732   *-*-sysv4* )
733     tcsh_config_file=sysv4
734   ;;
735
736   ## Tektronix systems
737   m68k-tektronix-bsd* )
738     tcsh_config_file=bsd
739     NON_GNU_DFLAGS='-DBSD -DUTek'
740   ;;
741   m88k-tektronix-sysv3* )
742     tcsh_config_file=tekXD88
743   ;;
744
745   ## SCO
746   *-sco3.2v5*) 
747     tcsh_config_file=sco32v5
748   ;;
749   *-sco3.2v4*)
750     tcsh_config_file=sco32v4
751   ;;
752   *-sco3.2v2*)
753     tcsh_config_file=sco32v2
754   ;;
755
756   ## Siemens BS2000 Mainframe
757   bs2000-siemens-posix)
758     tcsh_config_file=bs2000
759   ;;
760
761   ## Convex
762   *-convex*)
763     tcsh_config_file=convex
764   ;;
765
766   ## Cray
767   *-cray-unicos*)
768     tcsh_config_file=cray
769   ;;
770
771   ## Cygnus GNU Win32
772   *-cygwin)
773     tcsh_config_file=cygwin32
774   ;;
775
776   ## mips-compaq-nonstopux
777   *-*-nonstopux)
778     tcsh_config_file=sysv4
779   ;;
780
781   ## Apollo Domain/OS
782   *-apollo-*)
783     tcsh_config_file=apollo
784   ;;
785
786   * )
787     { echo "configure: error: Tcsh can't guess the configuration file name
788 for \`${host}' systems.
789 Check tcsh's \`Ported' file for manual configuration instructions." 1>&2; exit 1; }
790     ;;
791
792 esac
793
794 echo "Tcsh will use configuration file \`$tcsh_config_file'."
795
796
797 # Extract the first word of "gcc", so it can be a program name with args.
798 set dummy gcc; ac_word=$2
799 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
800 echo "configure:801: checking for $ac_word" >&5
801 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
802   echo $ac_n "(cached) $ac_c" 1>&6
803 else
804   if test -n "$CC"; then
805   ac_cv_prog_CC="$CC" # Let the user override the test.
806 else
807   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
808   ac_dummy="$PATH"
809   for ac_dir in $ac_dummy; do
810     test -z "$ac_dir" && ac_dir=.
811     if test -f $ac_dir/$ac_word; then
812       ac_cv_prog_CC="gcc"
813       break
814     fi
815   done
816   IFS="$ac_save_ifs"
817 fi
818 fi
819 CC="$ac_cv_prog_CC"
820 if test -n "$CC"; then
821   echo "$ac_t""$CC" 1>&6
822 else
823   echo "$ac_t""no" 1>&6
824 fi
825
826 if test -z "$CC"; then
827   # Extract the first word of "cc", so it can be a program name with args.
828 set dummy cc; ac_word=$2
829 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
830 echo "configure:831: checking for $ac_word" >&5
831 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
832   echo $ac_n "(cached) $ac_c" 1>&6
833 else
834   if test -n "$CC"; then
835   ac_cv_prog_CC="$CC" # Let the user override the test.
836 else
837   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
838   ac_prog_rejected=no
839   ac_dummy="$PATH"
840   for ac_dir in $ac_dummy; do
841     test -z "$ac_dir" && ac_dir=.
842     if test -f $ac_dir/$ac_word; then
843       if test "$ac_dir/$ac_word" = "/usr/ucb/cc"; then
844         ac_prog_rejected=yes
845         continue
846       fi
847       ac_cv_prog_CC="cc"
848       break
849     fi
850   done
851   IFS="$ac_save_ifs"
852 if test $ac_prog_rejected = yes; then
853   # We found a bogon in the path, so make sure we never use it.
854   set dummy $ac_cv_prog_CC
855   shift
856   if test $# -gt 0; then
857     # We chose a different compiler from the bogus one.
858     # However, it has the same basename, so the bogon will be chosen
859     # first if we set CC to just the basename; use the full file name.
860     shift
861     set dummy "$ac_dir/$ac_word" "$@"
862     shift
863     ac_cv_prog_CC="$@"
864   fi
865 fi
866 fi
867 fi
868 CC="$ac_cv_prog_CC"
869 if test -n "$CC"; then
870   echo "$ac_t""$CC" 1>&6
871 else
872   echo "$ac_t""no" 1>&6
873 fi
874
875   if test -z "$CC"; then
876     case "`uname -s`" in
877     *win32* | *WIN32*)
878       # Extract the first word of "cl", so it can be a program name with args.
879 set dummy cl; ac_word=$2
880 echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
881 echo "configure:882: checking for $ac_word" >&5
882 if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
883   echo $ac_n "(cached) $ac_c" 1>&6
884 else
885   if test -n "$CC"; then
886   ac_cv_prog_CC="$CC" # Let the user override the test.
887 else
888   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS=":"
889   ac_dummy="$PATH"
890   for ac_dir in $ac_dummy; do
891     test -z "$ac_dir" && ac_dir=.
892     if test -f $ac_dir/$ac_word; then
893       ac_cv_prog_CC="cl"
894       break
895     fi
896   done
897   IFS="$ac_save_ifs"
898 fi
899 fi
900 CC="$ac_cv_prog_CC"
901 if test -n "$CC"; then
902   echo "$ac_t""$CC" 1>&6
903 else
904   echo "$ac_t""no" 1>&6
905 fi
906  ;;
907     esac
908   fi
909   test -z "$CC" && { echo "configure: error: no acceptable cc found in \$PATH" 1>&2; exit 1; }
910 fi
911
912 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
913 echo "configure:914: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
914
915 ac_ext=c
916 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
917 ac_cpp='$CPP $CPPFLAGS'
918 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
919 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
920 cross_compiling=$ac_cv_prog_cc_cross
921
922 cat > conftest.$ac_ext << EOF
923
924 #line 925 "configure"
925 #include "confdefs.h"
926
927 main(){return(0);}
928 EOF
929 if { (eval echo configure:930: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
930   ac_cv_prog_cc_works=yes
931   # If we can't run a trivial program, we are probably using a cross compiler.
932   if (./conftest; exit) 2>/dev/null; then
933     ac_cv_prog_cc_cross=no
934   else
935     ac_cv_prog_cc_cross=yes
936   fi
937 else
938   echo "configure: failed program was:" >&5
939   cat conftest.$ac_ext >&5
940   ac_cv_prog_cc_works=no
941 fi
942 rm -fr conftest*
943 ac_ext=c
944 # CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
945 ac_cpp='$CPP $CPPFLAGS'
946 ac_compile='${CC-cc} -c $CFLAGS $CPPFLAGS conftest.$ac_ext 1>&5'
947 ac_link='${CC-cc} -o conftest${ac_exeext} $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS 1>&5'
948 cross_compiling=$ac_cv_prog_cc_cross
949
950 echo "$ac_t""$ac_cv_prog_cc_works" 1>&6
951 if test $ac_cv_prog_cc_works = no; then
952   { echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
953 fi
954 echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
955 echo "configure:956: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
956 echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
957 cross_compiling=$ac_cv_prog_cc_cross
958
959 echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
960 echo "configure:961: checking whether we are using GNU C" >&5
961 if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
962   echo $ac_n "(cached) $ac_c" 1>&6
963 else
964   cat > conftest.c <<EOF
965 #ifdef __GNUC__
966   yes;
967 #endif
968 EOF
969 if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:970: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
970   ac_cv_prog_gcc=yes
971 else
972   ac_cv_prog_gcc=no
973 fi
974 fi
975
976 echo "$ac_t""$ac_cv_prog_gcc" 1>&6
977
978 if test $ac_cv_prog_gcc = yes; then
979   GCC=yes
980 else
981   GCC=
982 fi
983
984 ac_test_CFLAGS="${CFLAGS+set}"
985 ac_save_CFLAGS="$CFLAGS"
986 CFLAGS=
987 echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
988 echo "configure:989: checking whether ${CC-cc} accepts -g" >&5
989 if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
990   echo $ac_n "(cached) $ac_c" 1>&6
991 else
992   echo 'void f(){}' > conftest.c
993 if test -z "`${CC-cc} -g -c conftest.c 2>&1`"; then
994   ac_cv_prog_cc_g=yes
995 else
996   ac_cv_prog_cc_g=no
997 fi
998 rm -f conftest*
999
1000 fi
1001
1002 echo "$ac_t""$ac_cv_prog_cc_g" 1>&6
1003 if test "$ac_test_CFLAGS" = set; then
1004   CFLAGS="$ac_save_CFLAGS"
1005 elif test $ac_cv_prog_cc_g = yes; then
1006   if test "$GCC" = yes; then
1007     CFLAGS="-g -O2"
1008   else
1009     CFLAGS="-g"
1010   fi
1011 else
1012   if test "$GCC" = yes; then
1013     CFLAGS="-O2"
1014   else
1015     CFLAGS=
1016   fi
1017 fi
1018
1019 echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
1020 echo "configure:1021: checking how to run the C preprocessor" >&5
1021 # On Suns, sometimes $CPP names a directory.
1022 if test -n "$CPP" && test -d "$CPP"; then
1023   CPP=
1024 fi
1025 if test -z "$CPP"; then
1026 if eval "test \"`echo '$''{'ac_cv_prog_CPP'+set}'`\" = set"; then
1027   echo $ac_n "(cached) $ac_c" 1>&6
1028 else
1029     # This must be in double quotes, not single quotes, because CPP may get
1030   # substituted into the Makefile and "${CC-cc}" will confuse make.
1031   CPP="${CC-cc} -E"
1032   # On the NeXT, cc -E runs the code through the compiler's parser,
1033   # not just through cpp.
1034   cat > conftest.$ac_ext <<EOF
1035 #line 1036 "configure"
1036 #include "confdefs.h"
1037 #include <assert.h>
1038 Syntax Error
1039 EOF
1040 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1041 { (eval echo configure:1042: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1042 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1043 if test -z "$ac_err"; then
1044   :
1045 else
1046   echo "$ac_err" >&5
1047   echo "configure: failed program was:" >&5
1048   cat conftest.$ac_ext >&5
1049   rm -rf conftest*
1050   CPP="${CC-cc} -E -traditional-cpp"
1051   cat > conftest.$ac_ext <<EOF
1052 #line 1053 "configure"
1053 #include "confdefs.h"
1054 #include <assert.h>
1055 Syntax Error
1056 EOF
1057 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1058 { (eval echo configure:1059: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1059 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1060 if test -z "$ac_err"; then
1061   :
1062 else
1063   echo "$ac_err" >&5
1064   echo "configure: failed program was:" >&5
1065   cat conftest.$ac_ext >&5
1066   rm -rf conftest*
1067   CPP="${CC-cc} -nologo -E"
1068   cat > conftest.$ac_ext <<EOF
1069 #line 1070 "configure"
1070 #include "confdefs.h"
1071 #include <assert.h>
1072 Syntax Error
1073 EOF
1074 ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
1075 { (eval echo configure:1076: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
1076 ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
1077 if test -z "$ac_err"; then
1078   :
1079 else
1080   echo "$ac_err" >&5
1081   echo "configure: failed program was:" >&5
1082   cat conftest.$ac_ext >&5
1083   rm -rf conftest*
1084   CPP=/lib/cpp
1085 fi
1086 rm -f conftest*
1087 fi
1088 rm -f conftest*
1089 fi
1090 rm -f conftest*
1091   ac_cv_prog_CPP="$CPP"
1092 fi
1093   CPP="$ac_cv_prog_CPP"
1094 else
1095   ac_cv_prog_CPP="$CPP"
1096 fi
1097 echo "$ac_t""$CPP" 1>&6
1098
1099 if test $ac_cv_prog_gcc = yes; then
1100     echo $ac_n "checking whether ${CC-cc} needs -traditional""... $ac_c" 1>&6
1101 echo "configure:1102: checking whether ${CC-cc} needs -traditional" >&5
1102 if eval "test \"`echo '$''{'ac_cv_prog_gcc_traditional'+set}'`\" = set"; then
1103   echo $ac_n "(cached) $ac_c" 1>&6
1104 else
1105     ac_pattern="Autoconf.*'x'"
1106   cat > conftest.$ac_ext <<EOF
1107 #line 1108 "configure"
1108 #include "confdefs.h"
1109 #include <sgtty.h>
1110 Autoconf TIOCGETP
1111 EOF
1112 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1113   egrep "$ac_pattern" >/dev/null 2>&1; then
1114   rm -rf conftest*
1115   ac_cv_prog_gcc_traditional=yes
1116 else
1117   rm -rf conftest*
1118   ac_cv_prog_gcc_traditional=no
1119 fi
1120 rm -f conftest*
1121
1122
1123   if test $ac_cv_prog_gcc_traditional = no; then
1124     cat > conftest.$ac_ext <<EOF
1125 #line 1126 "configure"
1126 #include "confdefs.h"
1127 #include <termio.h>
1128 Autoconf TCGETA
1129 EOF
1130 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
1131   egrep "$ac_pattern" >/dev/null 2>&1; then
1132   rm -rf conftest*
1133   ac_cv_prog_gcc_traditional=yes
1134 fi
1135 rm -f conftest*
1136
1137   fi
1138 fi
1139
1140 echo "$ac_t""$ac_cv_prog_gcc_traditional" 1>&6
1141   if test $ac_cv_prog_gcc_traditional = yes; then
1142     CC="$CC -traditional"
1143   fi
1144 fi
1145
1146
1147 if test $ac_cv_prog_gcc = no ; then
1148   DFLAGS="$DFLAGS $NON_GNU_DFLAGS"
1149   CFLAGS="$CFLAGS $NON_GNU_CFLAGS"
1150 fi
1151
1152 case "${host}" in
1153   ## Cygnus GNU Win32
1154   *-cygwin)
1155     CFLAGS="$CFLAGS -mno-win32"
1156   ;;
1157 esac
1158
1159
1160 echo $ac_n "checking for library containing crypt""... $ac_c" 1>&6
1161 echo "configure:1162: checking for library containing crypt" >&5
1162 if eval "test \"`echo '$''{'ac_cv_search_crypt'+set}'`\" = set"; then
1163   echo $ac_n "(cached) $ac_c" 1>&6
1164 else
1165   ac_func_search_save_LIBS="$LIBS"
1166 ac_cv_search_crypt="no"
1167 cat > conftest.$ac_ext <<EOF
1168 #line 1169 "configure"
1169 #include "confdefs.h"
1170 /* Override any gcc2 internal prototype to avoid an error.  */
1171 /* We use char because int might match the return type of a gcc2
1172     builtin and then its argument prototype would still apply.  */
1173 char crypt();
1174
1175 int main() {
1176 crypt()
1177 ; return 0; }
1178 EOF
1179 if { (eval echo configure:1180: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1180   rm -rf conftest*
1181   ac_cv_search_crypt="none required"
1182 else
1183   echo "configure: failed program was:" >&5
1184   cat conftest.$ac_ext >&5
1185 fi
1186 rm -f conftest*
1187 test "$ac_cv_search_crypt" = "no" && for i in crypt; do
1188 LIBS="-l$i  $ac_func_search_save_LIBS"
1189 cat > conftest.$ac_ext <<EOF
1190 #line 1191 "configure"
1191 #include "confdefs.h"
1192 /* Override any gcc2 internal prototype to avoid an error.  */
1193 /* We use char because int might match the return type of a gcc2
1194     builtin and then its argument prototype would still apply.  */
1195 char crypt();
1196
1197 int main() {
1198 crypt()
1199 ; return 0; }
1200 EOF
1201 if { (eval echo configure:1202: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1202   rm -rf conftest*
1203   ac_cv_search_crypt="-l$i"
1204 break
1205 else
1206   echo "configure: failed program was:" >&5
1207   cat conftest.$ac_ext >&5
1208 fi
1209 rm -f conftest*
1210 done
1211 LIBS="$ac_func_search_save_LIBS"
1212 fi
1213
1214 echo "$ac_t""$ac_cv_search_crypt" 1>&6
1215 if test "$ac_cv_search_crypt" != "no"; then
1216   test "$ac_cv_search_crypt" = "none required" || LIBS="$ac_cv_search_crypt $LIBS"
1217   
1218 else :
1219   
1220 fi
1221
1222 echo $ac_n "checking for library containing tgetent""... $ac_c" 1>&6
1223 echo "configure:1224: checking for library containing tgetent" >&5
1224 if eval "test \"`echo '$''{'ac_cv_search_tgetent'+set}'`\" = set"; then
1225   echo $ac_n "(cached) $ac_c" 1>&6
1226 else
1227   ac_func_search_save_LIBS="$LIBS"
1228 ac_cv_search_tgetent="no"
1229 cat > conftest.$ac_ext <<EOF
1230 #line 1231 "configure"
1231 #include "confdefs.h"
1232 /* Override any gcc2 internal prototype to avoid an error.  */
1233 /* We use char because int might match the return type of a gcc2
1234     builtin and then its argument prototype would still apply.  */
1235 char tgetent();
1236
1237 int main() {
1238 tgetent()
1239 ; return 0; }
1240 EOF
1241 if { (eval echo configure:1242: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1242   rm -rf conftest*
1243   ac_cv_search_tgetent="none required"
1244 else
1245   echo "configure: failed program was:" >&5
1246   cat conftest.$ac_ext >&5
1247 fi
1248 rm -f conftest*
1249 test "$ac_cv_search_tgetent" = "no" && for i in termlib curses termcap; do
1250 LIBS="-l$i  $ac_func_search_save_LIBS"
1251 cat > conftest.$ac_ext <<EOF
1252 #line 1253 "configure"
1253 #include "confdefs.h"
1254 /* Override any gcc2 internal prototype to avoid an error.  */
1255 /* We use char because int might match the return type of a gcc2
1256     builtin and then its argument prototype would still apply.  */
1257 char tgetent();
1258
1259 int main() {
1260 tgetent()
1261 ; return 0; }
1262 EOF
1263 if { (eval echo configure:1264: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1264   rm -rf conftest*
1265   ac_cv_search_tgetent="-l$i"
1266 break
1267 else
1268   echo "configure: failed program was:" >&5
1269   cat conftest.$ac_ext >&5
1270 fi
1271 rm -f conftest*
1272 done
1273 LIBS="$ac_func_search_save_LIBS"
1274 fi
1275
1276 echo "$ac_t""$ac_cv_search_tgetent" 1>&6
1277 if test "$ac_cv_search_tgetent" != "no"; then
1278   test "$ac_cv_search_tgetent" = "none required" || LIBS="$ac_cv_search_tgetent $LIBS"
1279   
1280 else :
1281   
1282 fi
1283
1284 echo $ac_n "checking for library containing gethostbyname""... $ac_c" 1>&6
1285 echo "configure:1286: checking for library containing gethostbyname" >&5
1286 if eval "test \"`echo '$''{'ac_cv_search_gethostbyname'+set}'`\" = set"; then
1287   echo $ac_n "(cached) $ac_c" 1>&6
1288 else
1289   ac_func_search_save_LIBS="$LIBS"
1290 ac_cv_search_gethostbyname="no"
1291 cat > conftest.$ac_ext <<EOF
1292 #line 1293 "configure"
1293 #include "confdefs.h"
1294 /* Override any gcc2 internal prototype to avoid an error.  */
1295 /* We use char because int might match the return type of a gcc2
1296     builtin and then its argument prototype would still apply.  */
1297 char gethostbyname();
1298
1299 int main() {
1300 gethostbyname()
1301 ; return 0; }
1302 EOF
1303 if { (eval echo configure:1304: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1304   rm -rf conftest*
1305   ac_cv_search_gethostbyname="none required"
1306 else
1307   echo "configure: failed program was:" >&5
1308   cat conftest.$ac_ext >&5
1309 fi
1310 rm -f conftest*
1311 test "$ac_cv_search_gethostbyname" = "no" && for i in nsl; do
1312 LIBS="-l$i  $ac_func_search_save_LIBS"
1313 cat > conftest.$ac_ext <<EOF
1314 #line 1315 "configure"
1315 #include "confdefs.h"
1316 /* Override any gcc2 internal prototype to avoid an error.  */
1317 /* We use char because int might match the return type of a gcc2
1318     builtin and then its argument prototype would still apply.  */
1319 char gethostbyname();
1320
1321 int main() {
1322 gethostbyname()
1323 ; return 0; }
1324 EOF
1325 if { (eval echo configure:1326: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1326   rm -rf conftest*
1327   ac_cv_search_gethostbyname="-l$i"
1328 break
1329 else
1330   echo "configure: failed program was:" >&5
1331   cat conftest.$ac_ext >&5
1332 fi
1333 rm -f conftest*
1334 done
1335 LIBS="$ac_func_search_save_LIBS"
1336 fi
1337
1338 echo "$ac_t""$ac_cv_search_gethostbyname" 1>&6
1339 if test "$ac_cv_search_gethostbyname" != "no"; then
1340   test "$ac_cv_search_gethostbyname" = "none required" || LIBS="$ac_cv_search_gethostbyname $LIBS"
1341   
1342 else :
1343   
1344 fi
1345
1346 echo $ac_n "checking for library containing connect""... $ac_c" 1>&6
1347 echo "configure:1348: checking for library containing connect" >&5
1348 if eval "test \"`echo '$''{'ac_cv_search_connect'+set}'`\" = set"; then
1349   echo $ac_n "(cached) $ac_c" 1>&6
1350 else
1351   ac_func_search_save_LIBS="$LIBS"
1352 ac_cv_search_connect="no"
1353 cat > conftest.$ac_ext <<EOF
1354 #line 1355 "configure"
1355 #include "confdefs.h"
1356 /* Override any gcc2 internal prototype to avoid an error.  */
1357 /* We use char because int might match the return type of a gcc2
1358     builtin and then its argument prototype would still apply.  */
1359 char connect();
1360
1361 int main() {
1362 connect()
1363 ; return 0; }
1364 EOF
1365 if { (eval echo configure:1366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1366   rm -rf conftest*
1367   ac_cv_search_connect="none required"
1368 else
1369   echo "configure: failed program was:" >&5
1370   cat conftest.$ac_ext >&5
1371 fi
1372 rm -f conftest*
1373 test "$ac_cv_search_connect" = "no" && for i in socket; do
1374 LIBS="-l$i  $ac_func_search_save_LIBS"
1375 cat > conftest.$ac_ext <<EOF
1376 #line 1377 "configure"
1377 #include "confdefs.h"
1378 /* Override any gcc2 internal prototype to avoid an error.  */
1379 /* We use char because int might match the return type of a gcc2
1380     builtin and then its argument prototype would still apply.  */
1381 char connect();
1382
1383 int main() {
1384 connect()
1385 ; return 0; }
1386 EOF
1387 if { (eval echo configure:1388: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1388   rm -rf conftest*
1389   ac_cv_search_connect="-l$i"
1390 break
1391 else
1392   echo "configure: failed program was:" >&5
1393   cat conftest.$ac_ext >&5
1394 fi
1395 rm -f conftest*
1396 done
1397 LIBS="$ac_func_search_save_LIBS"
1398 fi
1399
1400 echo "$ac_t""$ac_cv_search_connect" 1>&6
1401 if test "$ac_cv_search_connect" != "no"; then
1402   test "$ac_cv_search_connect" = "none required" || LIBS="$ac_cv_search_connect $LIBS"
1403   
1404 else :
1405   
1406 fi
1407
1408
1409 echo $ac_n "checking ss_family in sockaddr_storage""... $ac_c" 1>&6
1410 echo "configure:1411: checking ss_family in sockaddr_storage" >&5
1411 if eval "test \"`echo '$''{'ac_cv_ss_family'+set}'`\" = set"; then
1412   echo $ac_n "(cached) $ac_c" 1>&6
1413 else
1414   cat > conftest.$ac_ext <<EOF
1415 #line 1416 "configure"
1416 #include "confdefs.h"
1417 #include <sys/types.h>
1418 #include <sys/socket.h>
1419 int main() {
1420 struct sockaddr_storage ss; ss.ss_family;
1421 ; return 0; }
1422 EOF
1423 if { (eval echo configure:1424: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
1424   rm -rf conftest*
1425   ac_cv_ss_family=yes
1426 else
1427   echo "configure: failed program was:" >&5
1428   cat conftest.$ac_ext >&5
1429   rm -rf conftest*
1430   ac_cv_ss_family=no
1431 fi
1432 rm -f conftest*
1433 if test "$ac_cv_ss_family" = no; then
1434   DFLAGS="$DFLAGS -DNO_SS_FAMILY"
1435 fi
1436
1437 fi
1438
1439 echo "$ac_t""$ac_cv_ss_family" 1>&6
1440
1441
1442
1443 # Check whether --with-hesiod or --without-hesiod was given.
1444 if test "${with_hesiod+set}" = set; then
1445   withval="$with_hesiod"
1446   hesiod="$withval"
1447 else
1448   hesiod=no
1449 fi
1450
1451 if test "$hesiod" != no; then
1452   HESLIB="-lhesiod"
1453   echo $ac_n "checking for res_send""... $ac_c" 1>&6
1454 echo "configure:1455: checking for res_send" >&5
1455 if eval "test \"`echo '$''{'ac_cv_func_res_send'+set}'`\" = set"; then
1456   echo $ac_n "(cached) $ac_c" 1>&6
1457 else
1458   cat > conftest.$ac_ext <<EOF
1459 #line 1460 "configure"
1460 #include "confdefs.h"
1461 /* System header to define __stub macros and hopefully few prototypes,
1462     which can conflict with char res_send(); below.  */
1463 #include <assert.h>
1464 /* Override any gcc2 internal prototype to avoid an error.  */
1465 /* We use char because int might match the return type of a gcc2
1466     builtin and then its argument prototype would still apply.  */
1467 char res_send();
1468
1469 int main() {
1470
1471 /* The GNU C library defines this for functions which it implements
1472     to always fail with ENOSYS.  Some functions are actually named
1473     something starting with __ and the normal name is an alias.  */
1474 #if defined (__stub_res_send) || defined (__stub___res_send)
1475 choke me
1476 #else
1477 res_send();
1478 #endif
1479
1480 ; return 0; }
1481 EOF
1482 if { (eval echo configure:1483: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1483   rm -rf conftest*
1484   eval "ac_cv_func_res_send=yes"
1485 else
1486   echo "configure: failed program was:" >&5
1487   cat conftest.$ac_ext >&5
1488   rm -rf conftest*
1489   eval "ac_cv_func_res_send=no"
1490 fi
1491 rm -f conftest*
1492 fi
1493
1494 if eval "test \"`echo '$ac_cv_func_'res_send`\" = yes"; then
1495   echo "$ac_t""yes" 1>&6
1496   :
1497 else
1498   echo "$ac_t""no" 1>&6
1499 echo $ac_n "checking for res_send in -lresolv""... $ac_c" 1>&6
1500 echo "configure:1501: checking for res_send in -lresolv" >&5
1501 ac_lib_var=`echo resolv'_'res_send | sed 'y%./+-%__p_%'`
1502 if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
1503   echo $ac_n "(cached) $ac_c" 1>&6
1504 else
1505   ac_save_LIBS="$LIBS"
1506 LIBS="-lresolv  $LIBS"
1507 cat > conftest.$ac_ext <<EOF
1508 #line 1509 "configure"
1509 #include "confdefs.h"
1510 /* Override any gcc2 internal prototype to avoid an error.  */
1511 /* We use char because int might match the return type of a gcc2
1512     builtin and then its argument prototype would still apply.  */
1513 char res_send();
1514
1515 int main() {
1516 res_send()
1517 ; return 0; }
1518 EOF
1519 if { (eval echo configure:1520: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
1520   rm -rf conftest*
1521   eval "ac_cv_lib_$ac_lib_var=yes"
1522 else
1523   echo "configure: failed program was:" >&5
1524   cat conftest.$ac_ext >&5
1525   rm -rf conftest*
1526   eval "ac_cv_lib_$ac_lib_var=no"
1527 fi
1528 rm -f conftest*
1529 LIBS="$ac_save_LIBS"
1530
1531 fi
1532 if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then
1533   echo "$ac_t""yes" 1>&6
1534   HESLIB="$HESLIB -lresolv"
1535 else
1536   echo "$ac_t""no" 1>&6
1537 fi
1538
1539 fi
1540
1541   HESDEF=-DHESIOD
1542   if test "$hesiod" != yes; then
1543     HESDEF="$HESDEF -I$hesiod/include"
1544     HESLIB="-L$hesiod/lib $HESLIB"
1545   fi
1546 fi
1547
1548
1549
1550 trap '' 1 2 15
1551 cat > confcache <<\EOF
1552 # This file is a shell script that caches the results of configure
1553 # tests run on this system so they can be shared between configure
1554 # scripts and configure runs.  It is not useful on other systems.
1555 # If it contains results you don't want to keep, you may remove or edit it.
1556 #
1557 # By default, configure uses ./config.cache as the cache file,
1558 # creating it if it does not exist already.  You can give configure
1559 # the --cache-file=FILE option to use a different cache file; that is
1560 # what configure does when it calls configure scripts in
1561 # subdirectories, so they share the cache.
1562 # Giving --cache-file=/dev/null disables caching, for debugging configure.
1563 # config.status only pays attention to the cache file if you give it the
1564 # --recheck option to rerun configure.
1565 #
1566 EOF
1567 # The following way of writing the cache mishandles newlines in values,
1568 # but we know of no workaround that is simple, portable, and efficient.
1569 # So, don't put newlines in cache variables' values.
1570 # Ultrix sh set writes to stderr and can't be redirected directly,
1571 # and sets the high bit in the cache file unless we assign to the vars.
1572 (set) 2>&1 |
1573   case `(ac_space=' '; set | grep ac_space) 2>&1` in
1574   *ac_space=\ *)
1575     # `set' does not quote correctly, so add quotes (double-quote substitution
1576     # turns \\\\ into \\, and sed turns \\ into \).
1577     sed -n \
1578       -e "s/'/'\\\\''/g" \
1579       -e "s/^\\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\\)=\\(.*\\)/\\1=\${\\1='\\2'}/p"
1580     ;;
1581   *)
1582     # `set' quotes correctly as required by POSIX, so do not add quotes.
1583     sed -n -e 's/^\([a-zA-Z0-9_]*_cv_[a-zA-Z0-9_]*\)=\(.*\)/\1=${\1=\2}/p'
1584     ;;
1585   esac >> confcache
1586 if cmp -s $cache_file confcache; then
1587   :
1588 else
1589   if test -w $cache_file; then
1590     echo "updating cache $cache_file"
1591     cat confcache > $cache_file
1592   else
1593     echo "not updating unwritable cache $cache_file"
1594   fi
1595 fi
1596 rm -f confcache
1597
1598 trap 'rm -fr conftest* confdefs* core core.* *.core $ac_clean_files; exit 1' 1 2 15
1599
1600 test "x$prefix" = xNONE && prefix=$ac_default_prefix
1601 # Let make expand exec_prefix.
1602 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
1603
1604 # Any assignment to VPATH causes Sun make to only execute
1605 # the first set of double-colon rules, so remove it if not needed.
1606 # If there is a colon in the path, we need to keep it.
1607 if test "x$srcdir" = x.; then
1608   ac_vpsub='/^[         ]*VPATH[        ]*=[^:]*$/d'
1609 fi
1610
1611 trap 'rm -f $CONFIG_STATUS conftest*; exit 1' 1 2 15
1612
1613 DEFS=-DHAVE_CONFIG_H
1614
1615 # Without the "./", some shells look in PATH for config.status.
1616 : ${CONFIG_STATUS=./config.status}
1617
1618 echo creating $CONFIG_STATUS
1619 rm -f $CONFIG_STATUS
1620 cat > $CONFIG_STATUS <<EOF
1621 #! /bin/sh
1622 # Generated automatically by configure.
1623 # Run this file to recreate the current configuration.
1624 # This directory was configured as follows,
1625 # on host `(hostname || uname -n) 2>/dev/null | sed 1q`:
1626 #
1627 # $0 $ac_configure_args
1628 #
1629 # Compiler output produced by configure, useful for debugging
1630 # configure, is in ./config.log if it exists.
1631
1632 ac_cs_usage="Usage: $CONFIG_STATUS [--recheck] [--version] [--help]"
1633 for ac_option
1634 do
1635   case "\$ac_option" in
1636   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
1637     echo "running \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion"
1638     exec \${CONFIG_SHELL-/bin/sh} $0 $ac_configure_args --no-create --no-recursion ;;
1639   -version | --version | --versio | --versi | --vers | --ver | --ve | --v)
1640     echo "$CONFIG_STATUS generated by autoconf version 2.13"
1641     exit 0 ;;
1642   -help | --help | --hel | --he | --h)
1643     echo "\$ac_cs_usage"; exit 0 ;;
1644   *) echo "\$ac_cs_usage"; exit 1 ;;
1645   esac
1646 done
1647
1648 ac_given_srcdir=$srcdir
1649
1650 trap 'rm -fr `echo "Makefile config.h:config/${tcsh_config_file}:config.h.in" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15
1651 EOF
1652 cat >> $CONFIG_STATUS <<EOF
1653
1654 # Protect against being on the right side of a sed subst in config.status.
1655 sed 's/%@/@@/; s/@%/@@/; s/%g\$/@g/; /@g\$/s/[\\\\&%]/\\\\&/g;
1656  s/@@/%@/; s/@@/@%/; s/@g\$/%g/' > conftest.subs <<\\CEOF
1657 $ac_vpsub
1658 $extrasub
1659 s%@SHELL@%$SHELL%g
1660 s%@CFLAGS@%$CFLAGS%g
1661 s%@CPPFLAGS@%$CPPFLAGS%g
1662 s%@CXXFLAGS@%$CXXFLAGS%g
1663 s%@FFLAGS@%$FFLAGS%g
1664 s%@DEFS@%$DEFS%g
1665 s%@LDFLAGS@%$LDFLAGS%g
1666 s%@LIBS@%$LIBS%g
1667 s%@exec_prefix@%$exec_prefix%g
1668 s%@prefix@%$prefix%g
1669 s%@program_transform_name@%$program_transform_name%g
1670 s%@bindir@%$bindir%g
1671 s%@sbindir@%$sbindir%g
1672 s%@libexecdir@%$libexecdir%g
1673 s%@datadir@%$datadir%g
1674 s%@sysconfdir@%$sysconfdir%g
1675 s%@sharedstatedir@%$sharedstatedir%g
1676 s%@localstatedir@%$localstatedir%g
1677 s%@libdir@%$libdir%g
1678 s%@includedir@%$includedir%g
1679 s%@oldincludedir@%$oldincludedir%g
1680 s%@infodir@%$infodir%g
1681 s%@mandir@%$mandir%g
1682 s%@host@%$host%g
1683 s%@host_alias@%$host_alias%g
1684 s%@host_cpu@%$host_cpu%g
1685 s%@host_vendor@%$host_vendor%g
1686 s%@host_os@%$host_os%g
1687 s%@CC@%$CC%g
1688 s%@CPP@%$CPP%g
1689 s%@DFLAGS@%$DFLAGS%g
1690 s%@HESDEF@%$HESDEF%g
1691 s%@HESLIB@%$HESLIB%g
1692
1693 CEOF
1694 EOF
1695
1696 cat >> $CONFIG_STATUS <<\EOF
1697
1698 # Split the substitutions into bite-sized pieces for seds with
1699 # small command number limits, like on Digital OSF/1 and HP-UX.
1700 ac_max_sed_cmds=90 # Maximum number of lines to put in a sed script.
1701 ac_file=1 # Number of current file.
1702 ac_beg=1 # First line for current file.
1703 ac_end=$ac_max_sed_cmds # Line after last line for current file.
1704 ac_more_lines=:
1705 ac_sed_cmds=""
1706 while $ac_more_lines; do
1707   if test $ac_beg -gt 1; then
1708     sed "1,${ac_beg}d; ${ac_end}q" conftest.subs > conftest.s$ac_file
1709   else
1710     sed "${ac_end}q" conftest.subs > conftest.s$ac_file
1711   fi
1712   if test ! -s conftest.s$ac_file; then
1713     ac_more_lines=false
1714     rm -f conftest.s$ac_file
1715   else
1716     if test -z "$ac_sed_cmds"; then
1717       ac_sed_cmds="sed -f conftest.s$ac_file"
1718     else
1719       ac_sed_cmds="$ac_sed_cmds | sed -f conftest.s$ac_file"
1720     fi
1721     ac_file=`expr $ac_file + 1`
1722     ac_beg=$ac_end
1723     ac_end=`expr $ac_end + $ac_max_sed_cmds`
1724   fi
1725 done
1726 if test -z "$ac_sed_cmds"; then
1727   ac_sed_cmds=cat
1728 fi
1729 EOF
1730
1731 cat >> $CONFIG_STATUS <<EOF
1732
1733 CONFIG_FILES=\${CONFIG_FILES-"Makefile"}
1734 EOF
1735 cat >> $CONFIG_STATUS <<\EOF
1736 for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then
1737   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
1738   case "$ac_file" in
1739   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
1740        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1741   *) ac_file_in="${ac_file}.in" ;;
1742   esac
1743
1744   # Adjust a relative srcdir, top_srcdir, and INSTALL for subdirectories.
1745
1746   # Remove last slash and all that follows it.  Not all systems have dirname.
1747   ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
1748   if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
1749     # The file is in a subdirectory.
1750     test ! -d "$ac_dir" && mkdir "$ac_dir"
1751     ac_dir_suffix="/`echo $ac_dir|sed 's%^\./%%'`"
1752     # A "../" for each directory in $ac_dir_suffix.
1753     ac_dots=`echo $ac_dir_suffix|sed 's%/[^/]*%../%g'`
1754   else
1755     ac_dir_suffix= ac_dots=
1756   fi
1757
1758   case "$ac_given_srcdir" in
1759   .)  srcdir=.
1760       if test -z "$ac_dots"; then top_srcdir=.
1761       else top_srcdir=`echo $ac_dots|sed 's%/$%%'`; fi ;;
1762   /*) srcdir="$ac_given_srcdir$ac_dir_suffix"; top_srcdir="$ac_given_srcdir" ;;
1763   *) # Relative path.
1764     srcdir="$ac_dots$ac_given_srcdir$ac_dir_suffix"
1765     top_srcdir="$ac_dots$ac_given_srcdir" ;;
1766   esac
1767
1768
1769   echo creating "$ac_file"
1770   rm -f "$ac_file"
1771   configure_input="Generated automatically from `echo $ac_file_in|sed 's%.*/%%'` by configure."
1772   case "$ac_file" in
1773   *Makefile*) ac_comsub="1i\\
1774 # $configure_input" ;;
1775   *) ac_comsub= ;;
1776   esac
1777
1778   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
1779   sed -e "$ac_comsub
1780 s%@configure_input@%$configure_input%g
1781 s%@srcdir@%$srcdir%g
1782 s%@top_srcdir@%$top_srcdir%g
1783 " $ac_file_inputs | (eval "$ac_sed_cmds") > $ac_file
1784 fi; done
1785 rm -f conftest.s*
1786
1787 # These sed commands are passed to sed as "A NAME B NAME C VALUE D", where
1788 # NAME is the cpp macro being defined and VALUE is the value it is being given.
1789 #
1790 # ac_d sets the value in "#define NAME VALUE" lines.
1791 ac_dA='s%^\([   ]*\)#\([        ]*define[       ][      ]*\)'
1792 ac_dB='\([      ][      ]*\)[^  ]*%\1#\2'
1793 ac_dC='\3'
1794 ac_dD='%g'
1795 # ac_u turns "#undef NAME" with trailing blanks into "#define NAME VALUE".
1796 ac_uA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
1797 ac_uB='\([      ]\)%\1#\2define\3'
1798 ac_uC=' '
1799 ac_uD='\4%g'
1800 # ac_e turns "#undef NAME" without trailing blanks into "#define NAME VALUE".
1801 ac_eA='s%^\([   ]*\)#\([        ]*\)undef\([    ][      ]*\)'
1802 ac_eB='$%\1#\2define\3'
1803 ac_eC=' '
1804 ac_eD='%g'
1805
1806 if test "${CONFIG_HEADERS+set}" != set; then
1807 EOF
1808 cat >> $CONFIG_STATUS <<EOF
1809   CONFIG_HEADERS="config.h:config/${tcsh_config_file}:config.h.in"
1810 EOF
1811 cat >> $CONFIG_STATUS <<\EOF
1812 fi
1813 for ac_file in .. $CONFIG_HEADERS; do if test "x$ac_file" != x..; then
1814   # Support "outfile[:infile[:infile...]]", defaulting infile="outfile.in".
1815   case "$ac_file" in
1816   *:*) ac_file_in=`echo "$ac_file"|sed 's%[^:]*:%%'`
1817        ac_file=`echo "$ac_file"|sed 's%:.*%%'` ;;
1818   *) ac_file_in="${ac_file}.in" ;;
1819   esac
1820
1821   echo creating $ac_file
1822
1823   rm -f conftest.frag conftest.in conftest.out
1824   ac_file_inputs=`echo $ac_file_in|sed -e "s%^%$ac_given_srcdir/%" -e "s%:% $ac_given_srcdir/%g"`
1825   cat $ac_file_inputs > conftest.in
1826
1827 EOF
1828
1829 # Transform confdefs.h into a sed script conftest.vals that substitutes
1830 # the proper values into config.h.in to produce config.h.  And first:
1831 # Protect against being on the right side of a sed subst in config.status.
1832 # Protect against being in an unquoted here document in config.status.
1833 rm -f conftest.vals
1834 cat > conftest.hdr <<\EOF
1835 s/[\\&%]/\\&/g
1836 s%[\\$`]%\\&%g
1837 s%#define \([A-Za-z_][A-Za-z0-9_]*\) *\(.*\)%${ac_dA}\1${ac_dB}\1${ac_dC}\2${ac_dD}%gp
1838 s%ac_d%ac_u%gp
1839 s%ac_u%ac_e%gp
1840 EOF
1841 sed -n -f conftest.hdr confdefs.h > conftest.vals
1842 rm -f conftest.hdr
1843
1844 # This sed command replaces #undef with comments.  This is necessary, for
1845 # example, in the case of _POSIX_SOURCE, which is predefined and required
1846 # on some systems where configure will not decide to define it.
1847 cat >> conftest.vals <<\EOF
1848 s%^[    ]*#[    ]*undef[        ][      ]*[a-zA-Z_][a-zA-Z_0-9]*%/* & */%
1849 EOF
1850
1851 # Break up conftest.vals because some shells have a limit on
1852 # the size of here documents, and old seds have small limits too.
1853
1854 rm -f conftest.tail
1855 while :
1856 do
1857   ac_lines=`grep -c . conftest.vals`
1858   # grep -c gives empty output for an empty file on some AIX systems.
1859   if test -z "$ac_lines" || test "$ac_lines" -eq 0; then break; fi
1860   # Write a limited-size here document to conftest.frag.
1861   echo '  cat > conftest.frag <<CEOF' >> $CONFIG_STATUS
1862   sed ${ac_max_here_lines}q conftest.vals >> $CONFIG_STATUS
1863   echo 'CEOF
1864   sed -f conftest.frag conftest.in > conftest.out
1865   rm -f conftest.in
1866   mv conftest.out conftest.in
1867 ' >> $CONFIG_STATUS
1868   sed 1,${ac_max_here_lines}d conftest.vals > conftest.tail
1869   rm -f conftest.vals
1870   mv conftest.tail conftest.vals
1871 done
1872 rm -f conftest.vals
1873
1874 cat >> $CONFIG_STATUS <<\EOF
1875   rm -f conftest.frag conftest.h
1876   echo "/* $ac_file.  Generated automatically by configure.  */" > conftest.h
1877   cat conftest.in >> conftest.h
1878   rm -f conftest.in
1879   if cmp -s $ac_file conftest.h 2>/dev/null; then
1880     echo "$ac_file is unchanged"
1881     rm -f conftest.h
1882   else
1883     # Remove last slash and all that follows it.  Not all systems have dirname.
1884       ac_dir=`echo $ac_file|sed 's%/[^/][^/]*$%%'`
1885       if test "$ac_dir" != "$ac_file" && test "$ac_dir" != .; then
1886       # The file is in a subdirectory.
1887       test ! -d "$ac_dir" && mkdir "$ac_dir"
1888     fi
1889     rm -f $ac_file
1890     mv conftest.h $ac_file
1891   fi
1892 fi; done
1893
1894 EOF
1895 cat >> $CONFIG_STATUS <<EOF
1896
1897 EOF
1898 cat >> $CONFIG_STATUS <<\EOF
1899
1900 exit 0
1901 EOF
1902 chmod +x $CONFIG_STATUS
1903 rm -fr confdefs* $ac_clean_files
1904 test "$no_create" = yes || ${CONFIG_SHELL-/bin/sh} $CONFIG_STATUS || exit 1
1905