Apply patches
[openssh.git] / .pc / cross-pkg-config.patch / configure
1 #! /bin/sh
2 # From configure.ac Revision: 1.480 .
3 # Guess values for system-dependent variables and create Makefiles.
4 # Generated by GNU Autoconf 2.67 for OpenSSH Portable.
5 #
6 # Report bugs to <openssh-unix-dev@mindrot.org>.
7 #
8 #
9 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
10 # 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Free Software
11 # Foundation, Inc.
12 #
13 #
14 # This configure script is free software; the Free Software Foundation
15 # gives unlimited permission to copy, distribute and modify it.
16 ## -------------------- ##
17 ## M4sh Initialization. ##
18 ## -------------------- ##
19
20 # Be more Bourne compatible
21 DUALCASE=1; export DUALCASE # for MKS sh
22 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
23   emulate sh
24   NULLCMD=:
25   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
26   # is contrary to our usage.  Disable this feature.
27   alias -g '${1+"$@"}'='"$@"'
28   setopt NO_GLOB_SUBST
29 else
30   case `(set -o) 2>/dev/null` in #(
31   *posix*) :
32     set -o posix ;; #(
33   *) :
34      ;;
35 esac
36 fi
37
38
39 as_nl='
40 '
41 export as_nl
42 # Printing a long string crashes Solaris 7 /usr/bin/printf.
43 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
44 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
45 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
46 # Prefer a ksh shell builtin over an external printf program on Solaris,
47 # but without wasting forks for bash or zsh.
48 if test -z "$BASH_VERSION$ZSH_VERSION" \
49     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
50   as_echo='print -r --'
51   as_echo_n='print -rn --'
52 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
53   as_echo='printf %s\n'
54   as_echo_n='printf %s'
55 else
56   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
57     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
58     as_echo_n='/usr/ucb/echo -n'
59   else
60     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
61     as_echo_n_body='eval
62       arg=$1;
63       case $arg in #(
64       *"$as_nl"*)
65         expr "X$arg" : "X\\(.*\\)$as_nl";
66         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
67       esac;
68       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
69     '
70     export as_echo_n_body
71     as_echo_n='sh -c $as_echo_n_body as_echo'
72   fi
73   export as_echo_body
74   as_echo='sh -c $as_echo_body as_echo'
75 fi
76
77 # The user is always right.
78 if test "${PATH_SEPARATOR+set}" != set; then
79   PATH_SEPARATOR=:
80   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
81     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
82       PATH_SEPARATOR=';'
83   }
84 fi
85
86
87 # IFS
88 # We need space, tab and new line, in precisely that order.  Quoting is
89 # there to prevent editors from complaining about space-tab.
90 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
91 # splitting by setting IFS to empty value.)
92 IFS=" ""        $as_nl"
93
94 # Find who we are.  Look in the path if we contain no directory separator.
95 case $0 in #((
96   *[\\/]* ) as_myself=$0 ;;
97   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
98 for as_dir in $PATH
99 do
100   IFS=$as_save_IFS
101   test -z "$as_dir" && as_dir=.
102     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
103   done
104 IFS=$as_save_IFS
105
106      ;;
107 esac
108 # We did not find ourselves, most probably we were run as `sh COMMAND'
109 # in which case we are not to be found in the path.
110 if test "x$as_myself" = x; then
111   as_myself=$0
112 fi
113 if test ! -f "$as_myself"; then
114   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
115   exit 1
116 fi
117
118 # Unset variables that we do not need and which cause bugs (e.g. in
119 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
120 # suppresses any "Segmentation fault" message there.  '((' could
121 # trigger a bug in pdksh 5.2.14.
122 for as_var in BASH_ENV ENV MAIL MAILPATH
123 do eval test x\${$as_var+set} = xset \
124   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
125 done
126 PS1='$ '
127 PS2='> '
128 PS4='+ '
129
130 # NLS nuisances.
131 LC_ALL=C
132 export LC_ALL
133 LANGUAGE=C
134 export LANGUAGE
135
136 # CDPATH.
137 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
138
139 if test "x$CONFIG_SHELL" = x; then
140   as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then :
141   emulate sh
142   NULLCMD=:
143   # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which
144   # is contrary to our usage.  Disable this feature.
145   alias -g '\${1+\"\$@\"}'='\"\$@\"'
146   setopt NO_GLOB_SUBST
147 else
148   case \`(set -o) 2>/dev/null\` in #(
149   *posix*) :
150     set -o posix ;; #(
151   *) :
152      ;;
153 esac
154 fi
155 "
156   as_required="as_fn_return () { (exit \$1); }
157 as_fn_success () { as_fn_return 0; }
158 as_fn_failure () { as_fn_return 1; }
159 as_fn_ret_success () { return 0; }
160 as_fn_ret_failure () { return 1; }
161
162 exitcode=0
163 as_fn_success || { exitcode=1; echo as_fn_success failed.; }
164 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; }
165 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; }
166 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; }
167 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then :
168
169 else
170   exitcode=1; echo positional parameters were not saved.
171 fi
172 test x\$exitcode = x0 || exit 1"
173   as_suggested="  as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO
174   as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO
175   eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" &&
176   test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1
177 test \$(( 1 + 1 )) = 2 || exit 1"
178   if (eval "$as_required") 2>/dev/null; then :
179   as_have_required=yes
180 else
181   as_have_required=no
182 fi
183   if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then :
184
185 else
186   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
187 as_found=false
188 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
189 do
190   IFS=$as_save_IFS
191   test -z "$as_dir" && as_dir=.
192   as_found=:
193   case $as_dir in #(
194          /*)
195            for as_base in sh bash ksh sh5; do
196              # Try only shells that exist, to save several forks.
197              as_shell=$as_dir/$as_base
198              if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
199                     { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then :
200   CONFIG_SHELL=$as_shell as_have_required=yes
201                    if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then :
202   break 2
203 fi
204 fi
205            done;;
206        esac
207   as_found=false
208 done
209 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } &&
210               { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then :
211   CONFIG_SHELL=$SHELL as_have_required=yes
212 fi; }
213 IFS=$as_save_IFS
214
215
216       if test "x$CONFIG_SHELL" != x; then :
217   # We cannot yet assume a decent shell, so we have to provide a
218         # neutralization value for shells without unset; and this also
219         # works around shells that cannot unset nonexistent variables.
220         BASH_ENV=/dev/null
221         ENV=/dev/null
222         (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV
223         export CONFIG_SHELL
224         exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
225 fi
226
227     if test x$as_have_required = xno; then :
228   $as_echo "$0: This script requires a shell more modern than all"
229   $as_echo "$0: the shells that I found on your system."
230   if test x${ZSH_VERSION+set} = xset ; then
231     $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should"
232     $as_echo "$0: be upgraded to zsh 4.3.4 or later."
233   else
234     $as_echo "$0: Please tell bug-autoconf@gnu.org and
235 $0: openssh-unix-dev@mindrot.org about your system,
236 $0: including any error possibly output before this
237 $0: message. Then install a modern shell, or manually run
238 $0: the script under such a shell if you do have one."
239   fi
240   exit 1
241 fi
242 fi
243 fi
244 SHELL=${CONFIG_SHELL-/bin/sh}
245 export SHELL
246 # Unset more variables known to interfere with behavior of common tools.
247 CLICOLOR_FORCE= GREP_OPTIONS=
248 unset CLICOLOR_FORCE GREP_OPTIONS
249
250 ## --------------------- ##
251 ## M4sh Shell Functions. ##
252 ## --------------------- ##
253 # as_fn_unset VAR
254 # ---------------
255 # Portably unset VAR.
256 as_fn_unset ()
257 {
258   { eval $1=; unset $1;}
259 }
260 as_unset=as_fn_unset
261
262 # as_fn_set_status STATUS
263 # -----------------------
264 # Set $? to STATUS, without forking.
265 as_fn_set_status ()
266 {
267   return $1
268 } # as_fn_set_status
269
270 # as_fn_exit STATUS
271 # -----------------
272 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
273 as_fn_exit ()
274 {
275   set +e
276   as_fn_set_status $1
277   exit $1
278 } # as_fn_exit
279
280 # as_fn_mkdir_p
281 # -------------
282 # Create "$as_dir" as a directory, including parents if necessary.
283 as_fn_mkdir_p ()
284 {
285
286   case $as_dir in #(
287   -*) as_dir=./$as_dir;;
288   esac
289   test -d "$as_dir" || eval $as_mkdir_p || {
290     as_dirs=
291     while :; do
292       case $as_dir in #(
293       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
294       *) as_qdir=$as_dir;;
295       esac
296       as_dirs="'$as_qdir' $as_dirs"
297       as_dir=`$as_dirname -- "$as_dir" ||
298 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
299          X"$as_dir" : 'X\(//\)[^/]' \| \
300          X"$as_dir" : 'X\(//\)$' \| \
301          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
302 $as_echo X"$as_dir" |
303     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
304             s//\1/
305             q
306           }
307           /^X\(\/\/\)[^/].*/{
308             s//\1/
309             q
310           }
311           /^X\(\/\/\)$/{
312             s//\1/
313             q
314           }
315           /^X\(\/\).*/{
316             s//\1/
317             q
318           }
319           s/.*/./; q'`
320       test -d "$as_dir" && break
321     done
322     test -z "$as_dirs" || eval "mkdir $as_dirs"
323   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
324
325
326 } # as_fn_mkdir_p
327 # as_fn_append VAR VALUE
328 # ----------------------
329 # Append the text in VALUE to the end of the definition contained in VAR. Take
330 # advantage of any shell optimizations that allow amortized linear growth over
331 # repeated appends, instead of the typical quadratic growth present in naive
332 # implementations.
333 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
334   eval 'as_fn_append ()
335   {
336     eval $1+=\$2
337   }'
338 else
339   as_fn_append ()
340   {
341     eval $1=\$$1\$2
342   }
343 fi # as_fn_append
344
345 # as_fn_arith ARG...
346 # ------------------
347 # Perform arithmetic evaluation on the ARGs, and store the result in the
348 # global $as_val. Take advantage of shells that can avoid forks. The arguments
349 # must be portable across $(()) and expr.
350 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
351   eval 'as_fn_arith ()
352   {
353     as_val=$(( $* ))
354   }'
355 else
356   as_fn_arith ()
357   {
358     as_val=`expr "$@" || test $? -eq 1`
359   }
360 fi # as_fn_arith
361
362
363 # as_fn_error STATUS ERROR [LINENO LOG_FD]
364 # ----------------------------------------
365 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
366 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
367 # script with STATUS, using 1 if that was 0.
368 as_fn_error ()
369 {
370   as_status=$1; test $as_status -eq 0 && as_status=1
371   if test "$4"; then
372     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
373     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
374   fi
375   $as_echo "$as_me: error: $2" >&2
376   as_fn_exit $as_status
377 } # as_fn_error
378
379 if expr a : '\(a\)' >/dev/null 2>&1 &&
380    test "X`expr 00001 : '.*\(...\)'`" = X001; then
381   as_expr=expr
382 else
383   as_expr=false
384 fi
385
386 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
387   as_basename=basename
388 else
389   as_basename=false
390 fi
391
392 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
393   as_dirname=dirname
394 else
395   as_dirname=false
396 fi
397
398 as_me=`$as_basename -- "$0" ||
399 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
400          X"$0" : 'X\(//\)$' \| \
401          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
402 $as_echo X/"$0" |
403     sed '/^.*\/\([^/][^/]*\)\/*$/{
404             s//\1/
405             q
406           }
407           /^X\/\(\/\/\)$/{
408             s//\1/
409             q
410           }
411           /^X\/\(\/\).*/{
412             s//\1/
413             q
414           }
415           s/.*/./; q'`
416
417 # Avoid depending upon Character Ranges.
418 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
419 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
420 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
421 as_cr_digits='0123456789'
422 as_cr_alnum=$as_cr_Letters$as_cr_digits
423
424
425   as_lineno_1=$LINENO as_lineno_1a=$LINENO
426   as_lineno_2=$LINENO as_lineno_2a=$LINENO
427   eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" &&
428   test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || {
429   # Blame Lee E. McMahon (1931-1989) for sed's syntax.  :-)
430   sed -n '
431     p
432     /[$]LINENO/=
433   ' <$as_myself |
434     sed '
435       s/[$]LINENO.*/&-/
436       t lineno
437       b
438       :lineno
439       N
440       :loop
441       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
442       t loop
443       s/-\n.*//
444     ' >$as_me.lineno &&
445   chmod +x "$as_me.lineno" ||
446     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; }
447
448   # Don't try to exec as it changes $[0], causing all sort of problems
449   # (the dirname of $[0] is not the place where we might find the
450   # original and so on.  Autoconf is especially sensitive to this).
451   . "./$as_me.lineno"
452   # Exit status is that of the last command.
453   exit
454 }
455
456 ECHO_C= ECHO_N= ECHO_T=
457 case `echo -n x` in #(((((
458 -n*)
459   case `echo 'xy\c'` in
460   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
461   xy)  ECHO_C='\c';;
462   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
463        ECHO_T=' ';;
464   esac;;
465 *)
466   ECHO_N='-n';;
467 esac
468
469 rm -f conf$$ conf$$.exe conf$$.file
470 if test -d conf$$.dir; then
471   rm -f conf$$.dir/conf$$.file
472 else
473   rm -f conf$$.dir
474   mkdir conf$$.dir 2>/dev/null
475 fi
476 if (echo >conf$$.file) 2>/dev/null; then
477   if ln -s conf$$.file conf$$ 2>/dev/null; then
478     as_ln_s='ln -s'
479     # ... but there are two gotchas:
480     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
481     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
482     # In both cases, we have to default to `cp -p'.
483     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
484       as_ln_s='cp -p'
485   elif ln conf$$.file conf$$ 2>/dev/null; then
486     as_ln_s=ln
487   else
488     as_ln_s='cp -p'
489   fi
490 else
491   as_ln_s='cp -p'
492 fi
493 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
494 rmdir conf$$.dir 2>/dev/null
495
496 if mkdir -p . 2>/dev/null; then
497   as_mkdir_p='mkdir -p "$as_dir"'
498 else
499   test -d ./-p && rmdir ./-p
500   as_mkdir_p=false
501 fi
502
503 if test -x / >/dev/null 2>&1; then
504   as_test_x='test -x'
505 else
506   if ls -dL / >/dev/null 2>&1; then
507     as_ls_L_option=L
508   else
509     as_ls_L_option=
510   fi
511   as_test_x='
512     eval sh -c '\''
513       if test -d "$1"; then
514         test -d "$1/.";
515       else
516         case $1 in #(
517         -*)set "./$1";;
518         esac;
519         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
520         ???[sx]*):;;*)false;;esac;fi
521     '\'' sh
522   '
523 fi
524 as_executable_p=$as_test_x
525
526 # Sed expression to map a string onto a valid CPP name.
527 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
528
529 # Sed expression to map a string onto a valid variable name.
530 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
531
532
533 test -n "$DJDIR" || exec 7<&0 </dev/null
534 exec 6>&1
535
536 # Name of the host.
537 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status,
538 # so uname gets run too.
539 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
540
541 #
542 # Initializations.
543 #
544 ac_default_prefix=/usr/local
545 ac_clean_files=
546 ac_config_libobj_dir=.
547 LIBOBJS=
548 cross_compiling=no
549 subdirs=
550 MFLAGS=
551 MAKEFLAGS=
552
553 # Identity of this package.
554 PACKAGE_NAME='OpenSSH'
555 PACKAGE_TARNAME='openssh'
556 PACKAGE_VERSION='Portable'
557 PACKAGE_STRING='OpenSSH Portable'
558 PACKAGE_BUGREPORT='openssh-unix-dev@mindrot.org'
559 PACKAGE_URL=''
560
561 ac_unique_file="ssh.c"
562 # Factoring default headers for most tests.
563 ac_includes_default="\
564 #include <stdio.h>
565 #ifdef HAVE_SYS_TYPES_H
566 # include <sys/types.h>
567 #endif
568 #ifdef HAVE_SYS_STAT_H
569 # include <sys/stat.h>
570 #endif
571 #ifdef STDC_HEADERS
572 # include <stdlib.h>
573 # include <stddef.h>
574 #else
575 # ifdef HAVE_STDLIB_H
576 #  include <stdlib.h>
577 # endif
578 #endif
579 #ifdef HAVE_STRING_H
580 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
581 #  include <memory.h>
582 # endif
583 # include <string.h>
584 #endif
585 #ifdef HAVE_STRINGS_H
586 # include <strings.h>
587 #endif
588 #ifdef HAVE_INTTYPES_H
589 # include <inttypes.h>
590 #endif
591 #ifdef HAVE_STDINT_H
592 # include <stdint.h>
593 #endif
594 #ifdef HAVE_UNISTD_H
595 # include <unistd.h>
596 #endif"
597
598 ac_subst_vars='LTLIBOBJS
599 LIBOBJS
600 TEST_SSH_IPV6
601 piddir
602 user_path
603 mansubdir
604 MANTYPE
605 XAUTH_PATH
606 STRIP_OPT
607 xauth_path
608 PRIVSEP_PATH
609 KRB5CONF
610 SSHDLIBS
611 SSHLIBS
612 SSH_PRIVSEP_USER
613 COMMENT_OUT_ECC
614 TEST_SSH_ECC
615 TEST_SSH_SHA256
616 LIBEDIT
617 PKGCONFIG
618 LD
619 PATH_PASSWD_PROG
620 LOGIN_PROGRAM_FALLBACK
621 STARTUP_SCRIPT_SHELL
622 MAKE_PACKAGE_SUPPORTED
623 PATH_USERADD_PROG
624 PATH_GROUPADD_PROG
625 MANFMT
626 TEST_SHELL
627 MANDOC
628 NROFF
629 GROFF
630 SH
631 TEST_MINUS_S_SH
632 ENT
633 SED
634 PERL
635 KILL
636 CAT
637 AR
638 INSTALL_DATA
639 INSTALL_SCRIPT
640 INSTALL_PROGRAM
641 RANLIB
642 AWK
643 EGREP
644 GREP
645 CPP
646 host_os
647 host_vendor
648 host_cpu
649 host
650 build_os
651 build_vendor
652 build_cpu
653 build
654 OBJEXT
655 EXEEXT
656 ac_ct_CC
657 CPPFLAGS
658 LDFLAGS
659 CFLAGS
660 CC
661 target_alias
662 host_alias
663 build_alias
664 LIBS
665 ECHO_T
666 ECHO_N
667 ECHO_C
668 DEFS
669 mandir
670 localedir
671 libdir
672 psdir
673 pdfdir
674 dvidir
675 htmldir
676 infodir
677 docdir
678 oldincludedir
679 includedir
680 localstatedir
681 sharedstatedir
682 sysconfdir
683 datadir
684 datarootdir
685 libexecdir
686 sbindir
687 bindir
688 program_transform_name
689 prefix
690 exec_prefix
691 PACKAGE_URL
692 PACKAGE_BUGREPORT
693 PACKAGE_STRING
694 PACKAGE_VERSION
695 PACKAGE_TARNAME
696 PACKAGE_NAME
697 PATH_SEPARATOR
698 SHELL'
699 ac_subst_files=''
700 ac_user_opts='
701 enable_option_checking
702 enable_largefile
703 with_stackprotect
704 with_rpath
705 with_cflags
706 with_cppflags
707 with_ldflags
708 with_libs
709 with_Werror
710 with_solaris_contracts
711 with_solaris_projects
712 with_osfsia
713 with_zlib
714 with_zlib_version_check
715 with_skey
716 with_tcp_wrappers
717 with_libedit
718 with_audit
719 with_ssl_dir
720 with_openssl_header_check
721 with_ssl_engine
722 with_prngd_port
723 with_prngd_socket
724 with_pam
725 with_privsep_user
726 with_sandbox
727 with_selinux
728 with_kerberos5
729 with_privsep_path
730 with_xauth
731 enable_strip
732 with_maildir
733 with_mantype
734 with_md5_passwords
735 with_shadow
736 with_ipaddr_display
737 enable_etc_default_login
738 with_default_path
739 with_superuser_path
740 with_4in6
741 with_bsd_auth
742 with_pid_dir
743 enable_lastlog
744 enable_utmp
745 enable_utmpx
746 enable_wtmp
747 enable_wtmpx
748 enable_libutil
749 enable_pututline
750 enable_pututxline
751 with_lastlog
752 '
753       ac_precious_vars='build_alias
754 host_alias
755 target_alias
756 CC
757 CFLAGS
758 LDFLAGS
759 LIBS
760 CPPFLAGS
761 CPP'
762
763
764 # Initialize some variables set by options.
765 ac_init_help=
766 ac_init_version=false
767 ac_unrecognized_opts=
768 ac_unrecognized_sep=
769 # The variables have the same names as the options, with
770 # dashes changed to underlines.
771 cache_file=/dev/null
772 exec_prefix=NONE
773 no_create=
774 no_recursion=
775 prefix=NONE
776 program_prefix=NONE
777 program_suffix=NONE
778 program_transform_name=s,x,x,
779 silent=
780 site=
781 srcdir=
782 verbose=
783 x_includes=NONE
784 x_libraries=NONE
785
786 # Installation directory options.
787 # These are left unexpanded so users can "make install exec_prefix=/foo"
788 # and all the variables that are supposed to be based on exec_prefix
789 # by default will actually change.
790 # Use braces instead of parens because sh, perl, etc. also accept them.
791 # (The list follows the same order as the GNU Coding Standards.)
792 bindir='${exec_prefix}/bin'
793 sbindir='${exec_prefix}/sbin'
794 libexecdir='${exec_prefix}/libexec'
795 datarootdir='${prefix}/share'
796 datadir='${datarootdir}'
797 sysconfdir='${prefix}/etc'
798 sharedstatedir='${prefix}/com'
799 localstatedir='${prefix}/var'
800 includedir='${prefix}/include'
801 oldincludedir='/usr/include'
802 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
803 infodir='${datarootdir}/info'
804 htmldir='${docdir}'
805 dvidir='${docdir}'
806 pdfdir='${docdir}'
807 psdir='${docdir}'
808 libdir='${exec_prefix}/lib'
809 localedir='${datarootdir}/locale'
810 mandir='${datarootdir}/man'
811
812 ac_prev=
813 ac_dashdash=
814 for ac_option
815 do
816   # If the previous option needs an argument, assign it.
817   if test -n "$ac_prev"; then
818     eval $ac_prev=\$ac_option
819     ac_prev=
820     continue
821   fi
822
823   case $ac_option in
824   *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
825   *=)   ac_optarg= ;;
826   *)    ac_optarg=yes ;;
827   esac
828
829   # Accept the important Cygnus configure options, so we can diagnose typos.
830
831   case $ac_dashdash$ac_option in
832   --)
833     ac_dashdash=yes ;;
834
835   -bindir | --bindir | --bindi | --bind | --bin | --bi)
836     ac_prev=bindir ;;
837   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
838     bindir=$ac_optarg ;;
839
840   -build | --build | --buil | --bui | --bu)
841     ac_prev=build_alias ;;
842   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
843     build_alias=$ac_optarg ;;
844
845   -cache-file | --cache-file | --cache-fil | --cache-fi \
846   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
847     ac_prev=cache_file ;;
848   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
849   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
850     cache_file=$ac_optarg ;;
851
852   --config-cache | -C)
853     cache_file=config.cache ;;
854
855   -datadir | --datadir | --datadi | --datad)
856     ac_prev=datadir ;;
857   -datadir=* | --datadir=* | --datadi=* | --datad=*)
858     datadir=$ac_optarg ;;
859
860   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
861   | --dataroo | --dataro | --datar)
862     ac_prev=datarootdir ;;
863   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
864   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
865     datarootdir=$ac_optarg ;;
866
867   -disable-* | --disable-*)
868     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
869     # Reject names that are not valid shell variable names.
870     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
871       as_fn_error $? "invalid feature name: $ac_useropt"
872     ac_useropt_orig=$ac_useropt
873     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
874     case $ac_user_opts in
875       *"
876 "enable_$ac_useropt"
877 "*) ;;
878       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
879          ac_unrecognized_sep=', ';;
880     esac
881     eval enable_$ac_useropt=no ;;
882
883   -docdir | --docdir | --docdi | --doc | --do)
884     ac_prev=docdir ;;
885   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
886     docdir=$ac_optarg ;;
887
888   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
889     ac_prev=dvidir ;;
890   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
891     dvidir=$ac_optarg ;;
892
893   -enable-* | --enable-*)
894     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
895     # Reject names that are not valid shell variable names.
896     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
897       as_fn_error $? "invalid feature name: $ac_useropt"
898     ac_useropt_orig=$ac_useropt
899     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
900     case $ac_user_opts in
901       *"
902 "enable_$ac_useropt"
903 "*) ;;
904       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
905          ac_unrecognized_sep=', ';;
906     esac
907     eval enable_$ac_useropt=\$ac_optarg ;;
908
909   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
910   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
911   | --exec | --exe | --ex)
912     ac_prev=exec_prefix ;;
913   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
914   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
915   | --exec=* | --exe=* | --ex=*)
916     exec_prefix=$ac_optarg ;;
917
918   -gas | --gas | --ga | --g)
919     # Obsolete; use --with-gas.
920     with_gas=yes ;;
921
922   -help | --help | --hel | --he | -h)
923     ac_init_help=long ;;
924   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
925     ac_init_help=recursive ;;
926   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
927     ac_init_help=short ;;
928
929   -host | --host | --hos | --ho)
930     ac_prev=host_alias ;;
931   -host=* | --host=* | --hos=* | --ho=*)
932     host_alias=$ac_optarg ;;
933
934   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
935     ac_prev=htmldir ;;
936   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
937   | --ht=*)
938     htmldir=$ac_optarg ;;
939
940   -includedir | --includedir | --includedi | --included | --include \
941   | --includ | --inclu | --incl | --inc)
942     ac_prev=includedir ;;
943   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
944   | --includ=* | --inclu=* | --incl=* | --inc=*)
945     includedir=$ac_optarg ;;
946
947   -infodir | --infodir | --infodi | --infod | --info | --inf)
948     ac_prev=infodir ;;
949   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
950     infodir=$ac_optarg ;;
951
952   -libdir | --libdir | --libdi | --libd)
953     ac_prev=libdir ;;
954   -libdir=* | --libdir=* | --libdi=* | --libd=*)
955     libdir=$ac_optarg ;;
956
957   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
958   | --libexe | --libex | --libe)
959     ac_prev=libexecdir ;;
960   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
961   | --libexe=* | --libex=* | --libe=*)
962     libexecdir=$ac_optarg ;;
963
964   -localedir | --localedir | --localedi | --localed | --locale)
965     ac_prev=localedir ;;
966   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
967     localedir=$ac_optarg ;;
968
969   -localstatedir | --localstatedir | --localstatedi | --localstated \
970   | --localstate | --localstat | --localsta | --localst | --locals)
971     ac_prev=localstatedir ;;
972   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
973   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
974     localstatedir=$ac_optarg ;;
975
976   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
977     ac_prev=mandir ;;
978   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
979     mandir=$ac_optarg ;;
980
981   -nfp | --nfp | --nf)
982     # Obsolete; use --without-fp.
983     with_fp=no ;;
984
985   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
986   | --no-cr | --no-c | -n)
987     no_create=yes ;;
988
989   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
990   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
991     no_recursion=yes ;;
992
993   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
994   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
995   | --oldin | --oldi | --old | --ol | --o)
996     ac_prev=oldincludedir ;;
997   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
998   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
999   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1000     oldincludedir=$ac_optarg ;;
1001
1002   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1003     ac_prev=prefix ;;
1004   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1005     prefix=$ac_optarg ;;
1006
1007   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1008   | --program-pre | --program-pr | --program-p)
1009     ac_prev=program_prefix ;;
1010   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1011   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1012     program_prefix=$ac_optarg ;;
1013
1014   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1015   | --program-suf | --program-su | --program-s)
1016     ac_prev=program_suffix ;;
1017   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1018   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1019     program_suffix=$ac_optarg ;;
1020
1021   -program-transform-name | --program-transform-name \
1022   | --program-transform-nam | --program-transform-na \
1023   | --program-transform-n | --program-transform- \
1024   | --program-transform | --program-transfor \
1025   | --program-transfo | --program-transf \
1026   | --program-trans | --program-tran \
1027   | --progr-tra | --program-tr | --program-t)
1028     ac_prev=program_transform_name ;;
1029   -program-transform-name=* | --program-transform-name=* \
1030   | --program-transform-nam=* | --program-transform-na=* \
1031   | --program-transform-n=* | --program-transform-=* \
1032   | --program-transform=* | --program-transfor=* \
1033   | --program-transfo=* | --program-transf=* \
1034   | --program-trans=* | --program-tran=* \
1035   | --progr-tra=* | --program-tr=* | --program-t=*)
1036     program_transform_name=$ac_optarg ;;
1037
1038   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1039     ac_prev=pdfdir ;;
1040   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1041     pdfdir=$ac_optarg ;;
1042
1043   -psdir | --psdir | --psdi | --psd | --ps)
1044     ac_prev=psdir ;;
1045   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1046     psdir=$ac_optarg ;;
1047
1048   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1049   | -silent | --silent | --silen | --sile | --sil)
1050     silent=yes ;;
1051
1052   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1053     ac_prev=sbindir ;;
1054   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1055   | --sbi=* | --sb=*)
1056     sbindir=$ac_optarg ;;
1057
1058   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1059   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1060   | --sharedst | --shareds | --shared | --share | --shar \
1061   | --sha | --sh)
1062     ac_prev=sharedstatedir ;;
1063   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1064   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1065   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1066   | --sha=* | --sh=*)
1067     sharedstatedir=$ac_optarg ;;
1068
1069   -site | --site | --sit)
1070     ac_prev=site ;;
1071   -site=* | --site=* | --sit=*)
1072     site=$ac_optarg ;;
1073
1074   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1075     ac_prev=srcdir ;;
1076   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1077     srcdir=$ac_optarg ;;
1078
1079   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1080   | --syscon | --sysco | --sysc | --sys | --sy)
1081     ac_prev=sysconfdir ;;
1082   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1083   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1084     sysconfdir=$ac_optarg ;;
1085
1086   -target | --target | --targe | --targ | --tar | --ta | --t)
1087     ac_prev=target_alias ;;
1088   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1089     target_alias=$ac_optarg ;;
1090
1091   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1092     verbose=yes ;;
1093
1094   -version | --version | --versio | --versi | --vers | -V)
1095     ac_init_version=: ;;
1096
1097   -with-* | --with-*)
1098     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1099     # Reject names that are not valid shell variable names.
1100     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1101       as_fn_error $? "invalid package name: $ac_useropt"
1102     ac_useropt_orig=$ac_useropt
1103     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1104     case $ac_user_opts in
1105       *"
1106 "with_$ac_useropt"
1107 "*) ;;
1108       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1109          ac_unrecognized_sep=', ';;
1110     esac
1111     eval with_$ac_useropt=\$ac_optarg ;;
1112
1113   -without-* | --without-*)
1114     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1115     # Reject names that are not valid shell variable names.
1116     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1117       as_fn_error $? "invalid package name: $ac_useropt"
1118     ac_useropt_orig=$ac_useropt
1119     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1120     case $ac_user_opts in
1121       *"
1122 "with_$ac_useropt"
1123 "*) ;;
1124       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1125          ac_unrecognized_sep=', ';;
1126     esac
1127     eval with_$ac_useropt=no ;;
1128
1129   --x)
1130     # Obsolete; use --with-x.
1131     with_x=yes ;;
1132
1133   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1134   | --x-incl | --x-inc | --x-in | --x-i)
1135     ac_prev=x_includes ;;
1136   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1137   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1138     x_includes=$ac_optarg ;;
1139
1140   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1141   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1142     ac_prev=x_libraries ;;
1143   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1144   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1145     x_libraries=$ac_optarg ;;
1146
1147   -*) as_fn_error $? "unrecognized option: \`$ac_option'
1148 Try \`$0 --help' for more information"
1149     ;;
1150
1151   *=*)
1152     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1153     # Reject names that are not valid shell variable names.
1154     case $ac_envvar in #(
1155       '' | [0-9]* | *[!_$as_cr_alnum]* )
1156       as_fn_error $? "invalid variable name: \`$ac_envvar'" ;;
1157     esac
1158     eval $ac_envvar=\$ac_optarg
1159     export $ac_envvar ;;
1160
1161   *)
1162     # FIXME: should be removed in autoconf 3.0.
1163     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1164     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1165       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1166     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1167     ;;
1168
1169   esac
1170 done
1171
1172 if test -n "$ac_prev"; then
1173   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1174   as_fn_error $? "missing argument to $ac_option"
1175 fi
1176
1177 if test -n "$ac_unrecognized_opts"; then
1178   case $enable_option_checking in
1179     no) ;;
1180     fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;;
1181     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1182   esac
1183 fi
1184
1185 # Check all directory arguments for consistency.
1186 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1187                 datadir sysconfdir sharedstatedir localstatedir includedir \
1188                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1189                 libdir localedir mandir
1190 do
1191   eval ac_val=\$$ac_var
1192   # Remove trailing slashes.
1193   case $ac_val in
1194     */ )
1195       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1196       eval $ac_var=\$ac_val;;
1197   esac
1198   # Be sure to have absolute directory names.
1199   case $ac_val in
1200     [\\/$]* | ?:[\\/]* )  continue;;
1201     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1202   esac
1203   as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val"
1204 done
1205
1206 # There might be people who depend on the old broken behavior: `$host'
1207 # used to hold the argument of --host etc.
1208 # FIXME: To remove some day.
1209 build=$build_alias
1210 host=$host_alias
1211 target=$target_alias
1212
1213 # FIXME: To remove some day.
1214 if test "x$host_alias" != x; then
1215   if test "x$build_alias" = x; then
1216     cross_compiling=maybe
1217     $as_echo "$as_me: WARNING: if you wanted to set the --build type, don't use --host.
1218     If a cross compiler is detected then cross compile mode will be used" >&2
1219   elif test "x$build_alias" != "x$host_alias"; then
1220     cross_compiling=yes
1221   fi
1222 fi
1223
1224 ac_tool_prefix=
1225 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1226
1227 test "$silent" = yes && exec 6>/dev/null
1228
1229
1230 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1231 ac_ls_di=`ls -di .` &&
1232 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1233   as_fn_error $? "working directory cannot be determined"
1234 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1235   as_fn_error $? "pwd does not report name of working directory"
1236
1237
1238 # Find the source files, if location was not specified.
1239 if test -z "$srcdir"; then
1240   ac_srcdir_defaulted=yes
1241   # Try the directory containing this script, then the parent directory.
1242   ac_confdir=`$as_dirname -- "$as_myself" ||
1243 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1244          X"$as_myself" : 'X\(//\)[^/]' \| \
1245          X"$as_myself" : 'X\(//\)$' \| \
1246          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1247 $as_echo X"$as_myself" |
1248     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1249             s//\1/
1250             q
1251           }
1252           /^X\(\/\/\)[^/].*/{
1253             s//\1/
1254             q
1255           }
1256           /^X\(\/\/\)$/{
1257             s//\1/
1258             q
1259           }
1260           /^X\(\/\).*/{
1261             s//\1/
1262             q
1263           }
1264           s/.*/./; q'`
1265   srcdir=$ac_confdir
1266   if test ! -r "$srcdir/$ac_unique_file"; then
1267     srcdir=..
1268   fi
1269 else
1270   ac_srcdir_defaulted=no
1271 fi
1272 if test ! -r "$srcdir/$ac_unique_file"; then
1273   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1274   as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir"
1275 fi
1276 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1277 ac_abs_confdir=`(
1278         cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg"
1279         pwd)`
1280 # When building in place, set srcdir=.
1281 if test "$ac_abs_confdir" = "$ac_pwd"; then
1282   srcdir=.
1283 fi
1284 # Remove unnecessary trailing slashes from srcdir.
1285 # Double slashes in file names in object file debugging info
1286 # mess up M-x gdb in Emacs.
1287 case $srcdir in
1288 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1289 esac
1290 for ac_var in $ac_precious_vars; do
1291   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1292   eval ac_env_${ac_var}_value=\$${ac_var}
1293   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1294   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1295 done
1296
1297 #
1298 # Report the --help message.
1299 #
1300 if test "$ac_init_help" = "long"; then
1301   # Omit some internal or obsolete options to make the list less imposing.
1302   # This message is too long to be a string in the A/UX 3.1 sh.
1303   cat <<_ACEOF
1304 \`configure' configures OpenSSH Portable to adapt to many kinds of systems.
1305
1306 Usage: $0 [OPTION]... [VAR=VALUE]...
1307
1308 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1309 VAR=VALUE.  See below for descriptions of some of the useful variables.
1310
1311 Defaults for the options are specified in brackets.
1312
1313 Configuration:
1314   -h, --help              display this help and exit
1315       --help=short        display options specific to this package
1316       --help=recursive    display the short help of all the included packages
1317   -V, --version           display version information and exit
1318   -q, --quiet, --silent   do not print \`checking ...' messages
1319       --cache-file=FILE   cache test results in FILE [disabled]
1320   -C, --config-cache      alias for \`--cache-file=config.cache'
1321   -n, --no-create         do not create output files
1322       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1323
1324 Installation directories:
1325   --prefix=PREFIX         install architecture-independent files in PREFIX
1326                           [$ac_default_prefix]
1327   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1328                           [PREFIX]
1329
1330 By default, \`make install' will install all the files in
1331 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1332 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1333 for instance \`--prefix=\$HOME'.
1334
1335 For better control, use the options below.
1336
1337 Fine tuning of the installation directories:
1338   --bindir=DIR            user executables [EPREFIX/bin]
1339   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1340   --libexecdir=DIR        program executables [EPREFIX/libexec]
1341   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1342   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1343   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1344   --libdir=DIR            object code libraries [EPREFIX/lib]
1345   --includedir=DIR        C header files [PREFIX/include]
1346   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1347   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1348   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1349   --infodir=DIR           info documentation [DATAROOTDIR/info]
1350   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1351   --mandir=DIR            man documentation [DATAROOTDIR/man]
1352   --docdir=DIR            documentation root [DATAROOTDIR/doc/openssh]
1353   --htmldir=DIR           html documentation [DOCDIR]
1354   --dvidir=DIR            dvi documentation [DOCDIR]
1355   --pdfdir=DIR            pdf documentation [DOCDIR]
1356   --psdir=DIR             ps documentation [DOCDIR]
1357 _ACEOF
1358
1359   cat <<\_ACEOF
1360
1361 System types:
1362   --build=BUILD     configure for building on BUILD [guessed]
1363   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1364 _ACEOF
1365 fi
1366
1367 if test -n "$ac_init_help"; then
1368   case $ac_init_help in
1369      short | recursive ) echo "Configuration of OpenSSH Portable:";;
1370    esac
1371   cat <<\_ACEOF
1372
1373 Optional Features:
1374   --disable-option-checking  ignore unrecognized --enable/--with options
1375   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1376   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1377   --disable-largefile     omit support for large files
1378   --disable-strip         Disable calling strip(1) on install
1379   --disable-etc-default-login Disable using PATH from /etc/default/login no
1380   --disable-lastlog       disable use of lastlog even if detected no
1381   --disable-utmp          disable use of utmp even if detected no
1382   --disable-utmpx         disable use of utmpx even if detected no
1383   --disable-wtmp          disable use of wtmp even if detected no
1384   --disable-wtmpx         disable use of wtmpx even if detected no
1385   --disable-libutil       disable use of libutil (login() etc.) no
1386   --disable-pututline     disable use of pututline() etc. (uwtmp) no
1387   --disable-pututxline    disable use of pututxline() etc. (uwtmpx) no
1388
1389 Optional Packages:
1390   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1391   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1392   --without-stackprotect  Don't use compiler's stack protection
1393   --without-rpath         Disable auto-added -R linker paths
1394   --with-cflags           Specify additional flags to pass to compiler
1395   --with-cppflags         Specify additional flags to pass to preprocessor
1396   --with-ldflags          Specify additional flags to pass to linker
1397   --with-libs             Specify additional libraries to link with
1398   --with-Werror           Build main code with -Werror
1399   --with-solaris-contracts Enable Solaris process contracts (experimental)
1400   --with-solaris-projects Enable Solaris projects (experimental)
1401   --with-osfsia           Enable Digital Unix SIA
1402   --with-zlib=PATH        Use zlib in PATH
1403   --without-zlib-version-check Disable zlib version check
1404   --with-skey[=PATH]      Enable S/Key support (optionally in PATH)
1405   --with-tcp-wrappers[=PATH] Enable tcpwrappers support (optionally in PATH)
1406   --with-libedit[=PATH]   Enable libedit support for sftp
1407   --with-audit=module     Enable audit support (modules=debug,bsm,linux)
1408   --with-ssl-dir=PATH     Specify path to OpenSSL installation
1409   --without-openssl-header-check Disable OpenSSL version consistency check
1410   --with-ssl-engine       Enable OpenSSL (hardware) ENGINE support
1411   --with-prngd-port=PORT  read entropy from PRNGD/EGD TCP localhost:PORT
1412   --with-prngd-socket=FILE read entropy from PRNGD/EGD socket FILE (default=/var/run/egd-pool)
1413   --with-pam              Enable PAM support
1414   --with-privsep-user=user Specify non-privileged user for privilege separation
1415   --with-sandbox=style    Specify privilege separation sandbox (no, darwin, rlimit, systrace)
1416   --with-selinux          Enable SELinux support
1417   --with-kerberos5=PATH   Enable Kerberos 5 support
1418   --with-privsep-path=xxx Path for privilege separation chroot (default=/var/empty)
1419   --with-xauth=PATH       Specify path to xauth program
1420   --with-maildir=/path/to/mail    Specify your system mail directory
1421   --with-mantype=man|cat|doc  Set man page type
1422   --with-md5-passwords    Enable use of MD5 passwords
1423   --without-shadow        Disable shadow password support
1424   --with-ipaddr-display   Use ip address instead of hostname in \$DISPLAY
1425   --with-default-path=    Specify default \$PATH environment for server
1426   --with-superuser-path=  Specify different path for super-user
1427   --with-4in6             Check for and convert IPv4 in IPv6 mapped addresses
1428   --with-bsd-auth         Enable BSD auth support
1429   --with-pid-dir=PATH     Specify location of ssh.pid file
1430   --with-lastlog=FILE|DIR specify lastlog location common locations
1431
1432 Some influential environment variables:
1433   CC          C compiler command
1434   CFLAGS      C compiler flags
1435   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1436               nonstandard directory <lib dir>
1437   LIBS        libraries to pass to the linker, e.g. -l<library>
1438   CPPFLAGS    (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
1439               you have headers in a nonstandard directory <include dir>
1440   CPP         C preprocessor
1441
1442 Use these variables to override the choices made by `configure' or to help
1443 it to find libraries and programs with nonstandard names/locations.
1444
1445 Report bugs to <openssh-unix-dev@mindrot.org>.
1446 _ACEOF
1447 ac_status=$?
1448 fi
1449
1450 if test "$ac_init_help" = "recursive"; then
1451   # If there are subdirs, report their specific --help.
1452   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1453     test -d "$ac_dir" ||
1454       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1455       continue
1456     ac_builddir=.
1457
1458 case "$ac_dir" in
1459 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1460 *)
1461   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1462   # A ".." for each directory in $ac_dir_suffix.
1463   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1464   case $ac_top_builddir_sub in
1465   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1466   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1467   esac ;;
1468 esac
1469 ac_abs_top_builddir=$ac_pwd
1470 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1471 # for backward compatibility:
1472 ac_top_builddir=$ac_top_build_prefix
1473
1474 case $srcdir in
1475   .)  # We are building in place.
1476     ac_srcdir=.
1477     ac_top_srcdir=$ac_top_builddir_sub
1478     ac_abs_top_srcdir=$ac_pwd ;;
1479   [\\/]* | ?:[\\/]* )  # Absolute name.
1480     ac_srcdir=$srcdir$ac_dir_suffix;
1481     ac_top_srcdir=$srcdir
1482     ac_abs_top_srcdir=$srcdir ;;
1483   *) # Relative name.
1484     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1485     ac_top_srcdir=$ac_top_build_prefix$srcdir
1486     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1487 esac
1488 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1489
1490     cd "$ac_dir" || { ac_status=$?; continue; }
1491     # Check for guested configure.
1492     if test -f "$ac_srcdir/configure.gnu"; then
1493       echo &&
1494       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1495     elif test -f "$ac_srcdir/configure"; then
1496       echo &&
1497       $SHELL "$ac_srcdir/configure" --help=recursive
1498     else
1499       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1500     fi || ac_status=$?
1501     cd "$ac_pwd" || { ac_status=$?; break; }
1502   done
1503 fi
1504
1505 test -n "$ac_init_help" && exit $ac_status
1506 if $ac_init_version; then
1507   cat <<\_ACEOF
1508 OpenSSH configure Portable
1509 generated by GNU Autoconf 2.67
1510
1511 Copyright (C) 2010 Free Software Foundation, Inc.
1512 This configure script is free software; the Free Software Foundation
1513 gives unlimited permission to copy, distribute and modify it.
1514 _ACEOF
1515   exit
1516 fi
1517
1518 ## ------------------------ ##
1519 ## Autoconf initialization. ##
1520 ## ------------------------ ##
1521
1522 # ac_fn_c_try_compile LINENO
1523 # --------------------------
1524 # Try to compile conftest.$ac_ext, and return whether this succeeded.
1525 ac_fn_c_try_compile ()
1526 {
1527   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1528   rm -f conftest.$ac_objext
1529   if { { ac_try="$ac_compile"
1530 case "(($ac_try" in
1531   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1532   *) ac_try_echo=$ac_try;;
1533 esac
1534 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1535 $as_echo "$ac_try_echo"; } >&5
1536   (eval "$ac_compile") 2>conftest.err
1537   ac_status=$?
1538   if test -s conftest.err; then
1539     grep -v '^ *+' conftest.err >conftest.er1
1540     cat conftest.er1 >&5
1541     mv -f conftest.er1 conftest.err
1542   fi
1543   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1544   test $ac_status = 0; } && {
1545          test -z "$ac_c_werror_flag" ||
1546          test ! -s conftest.err
1547        } && test -s conftest.$ac_objext; then :
1548   ac_retval=0
1549 else
1550   $as_echo "$as_me: failed program was:" >&5
1551 sed 's/^/| /' conftest.$ac_ext >&5
1552
1553         ac_retval=1
1554 fi
1555   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1556   as_fn_set_status $ac_retval
1557
1558 } # ac_fn_c_try_compile
1559
1560 # ac_fn_c_try_run LINENO
1561 # ----------------------
1562 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes
1563 # that executables *can* be run.
1564 ac_fn_c_try_run ()
1565 {
1566   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1567   if { { ac_try="$ac_link"
1568 case "(($ac_try" in
1569   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1570   *) ac_try_echo=$ac_try;;
1571 esac
1572 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1573 $as_echo "$ac_try_echo"; } >&5
1574   (eval "$ac_link") 2>&5
1575   ac_status=$?
1576   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1577   test $ac_status = 0; } && { ac_try='./conftest$ac_exeext'
1578   { { case "(($ac_try" in
1579   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1580   *) ac_try_echo=$ac_try;;
1581 esac
1582 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1583 $as_echo "$ac_try_echo"; } >&5
1584   (eval "$ac_try") 2>&5
1585   ac_status=$?
1586   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1587   test $ac_status = 0; }; }; then :
1588   ac_retval=0
1589 else
1590   $as_echo "$as_me: program exited with status $ac_status" >&5
1591        $as_echo "$as_me: failed program was:" >&5
1592 sed 's/^/| /' conftest.$ac_ext >&5
1593
1594        ac_retval=$ac_status
1595 fi
1596   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1597   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1598   as_fn_set_status $ac_retval
1599
1600 } # ac_fn_c_try_run
1601
1602 # ac_fn_c_try_cpp LINENO
1603 # ----------------------
1604 # Try to preprocess conftest.$ac_ext, and return whether this succeeded.
1605 ac_fn_c_try_cpp ()
1606 {
1607   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1608   if { { ac_try="$ac_cpp conftest.$ac_ext"
1609 case "(($ac_try" in
1610   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1611   *) ac_try_echo=$ac_try;;
1612 esac
1613 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1614 $as_echo "$ac_try_echo"; } >&5
1615   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err
1616   ac_status=$?
1617   if test -s conftest.err; then
1618     grep -v '^ *+' conftest.err >conftest.er1
1619     cat conftest.er1 >&5
1620     mv -f conftest.er1 conftest.err
1621   fi
1622   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1623   test $ac_status = 0; } > conftest.i && {
1624          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
1625          test ! -s conftest.err
1626        }; then :
1627   ac_retval=0
1628 else
1629   $as_echo "$as_me: failed program was:" >&5
1630 sed 's/^/| /' conftest.$ac_ext >&5
1631
1632     ac_retval=1
1633 fi
1634   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1635   as_fn_set_status $ac_retval
1636
1637 } # ac_fn_c_try_cpp
1638
1639 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES
1640 # -------------------------------------------------------
1641 # Tests whether HEADER exists and can be compiled using the include files in
1642 # INCLUDES, setting the cache variable VAR accordingly.
1643 ac_fn_c_check_header_compile ()
1644 {
1645   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1646   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1647 $as_echo_n "checking for $2... " >&6; }
1648 if eval "test \"\${$3+set}\"" = set; then :
1649   $as_echo_n "(cached) " >&6
1650 else
1651   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1652 /* end confdefs.h.  */
1653 $4
1654 #include <$2>
1655 _ACEOF
1656 if ac_fn_c_try_compile "$LINENO"; then :
1657   eval "$3=yes"
1658 else
1659   eval "$3=no"
1660 fi
1661 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1662 fi
1663 eval ac_res=\$$3
1664                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1665 $as_echo "$ac_res" >&6; }
1666   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1667
1668 } # ac_fn_c_check_header_compile
1669
1670 # ac_fn_c_check_decl LINENO SYMBOL VAR INCLUDES
1671 # ---------------------------------------------
1672 # Tests whether SYMBOL is declared in INCLUDES, setting cache variable VAR
1673 # accordingly.
1674 ac_fn_c_check_decl ()
1675 {
1676   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1677   as_decl_name=`echo $2|sed 's/ *(.*//'`
1678   as_decl_use=`echo $2|sed -e 's/(/((/' -e 's/)/) 0&/' -e 's/,/) 0& (/g'`
1679   { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $as_decl_name is declared" >&5
1680 $as_echo_n "checking whether $as_decl_name is declared... " >&6; }
1681 if eval "test \"\${$3+set}\"" = set; then :
1682   $as_echo_n "(cached) " >&6
1683 else
1684   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1685 /* end confdefs.h.  */
1686 $4
1687 int
1688 main ()
1689 {
1690 #ifndef $as_decl_name
1691 #ifdef __cplusplus
1692   (void) $as_decl_use;
1693 #else
1694   (void) $as_decl_name;
1695 #endif
1696 #endif
1697
1698   ;
1699   return 0;
1700 }
1701 _ACEOF
1702 if ac_fn_c_try_compile "$LINENO"; then :
1703   eval "$3=yes"
1704 else
1705   eval "$3=no"
1706 fi
1707 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1708 fi
1709 eval ac_res=\$$3
1710                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1711 $as_echo "$ac_res" >&6; }
1712   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1713
1714 } # ac_fn_c_check_decl
1715
1716 # ac_fn_c_try_link LINENO
1717 # -----------------------
1718 # Try to link conftest.$ac_ext, and return whether this succeeded.
1719 ac_fn_c_try_link ()
1720 {
1721   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1722   rm -f conftest.$ac_objext conftest$ac_exeext
1723   if { { ac_try="$ac_link"
1724 case "(($ac_try" in
1725   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
1726   *) ac_try_echo=$ac_try;;
1727 esac
1728 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
1729 $as_echo "$ac_try_echo"; } >&5
1730   (eval "$ac_link") 2>conftest.err
1731   ac_status=$?
1732   if test -s conftest.err; then
1733     grep -v '^ *+' conftest.err >conftest.er1
1734     cat conftest.er1 >&5
1735     mv -f conftest.er1 conftest.err
1736   fi
1737   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
1738   test $ac_status = 0; } && {
1739          test -z "$ac_c_werror_flag" ||
1740          test ! -s conftest.err
1741        } && test -s conftest$ac_exeext && {
1742          test "$cross_compiling" = yes ||
1743          $as_test_x conftest$ac_exeext
1744        }; then :
1745   ac_retval=0
1746 else
1747   $as_echo "$as_me: failed program was:" >&5
1748 sed 's/^/| /' conftest.$ac_ext >&5
1749
1750         ac_retval=1
1751 fi
1752   # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information
1753   # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would
1754   # interfere with the next link command; also delete a directory that is
1755   # left behind by Apple's compiler.  We do this before executing the actions.
1756   rm -rf conftest.dSYM conftest_ipa8_conftest.oo
1757   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1758   as_fn_set_status $ac_retval
1759
1760 } # ac_fn_c_try_link
1761
1762 # ac_fn_c_check_header_mongrel LINENO HEADER VAR INCLUDES
1763 # -------------------------------------------------------
1764 # Tests whether HEADER exists, giving a warning if it cannot be compiled using
1765 # the include files in INCLUDES and setting the cache variable VAR
1766 # accordingly.
1767 ac_fn_c_check_header_mongrel ()
1768 {
1769   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1770   if eval "test \"\${$3+set}\"" = set; then :
1771   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1772 $as_echo_n "checking for $2... " >&6; }
1773 if eval "test \"\${$3+set}\"" = set; then :
1774   $as_echo_n "(cached) " >&6
1775 fi
1776 eval ac_res=\$$3
1777                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1778 $as_echo "$ac_res" >&6; }
1779 else
1780   # Is the header compilable?
1781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5
1782 $as_echo_n "checking $2 usability... " >&6; }
1783 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1784 /* end confdefs.h.  */
1785 $4
1786 #include <$2>
1787 _ACEOF
1788 if ac_fn_c_try_compile "$LINENO"; then :
1789   ac_header_compiler=yes
1790 else
1791   ac_header_compiler=no
1792 fi
1793 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5
1795 $as_echo "$ac_header_compiler" >&6; }
1796
1797 # Is the header present?
1798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5
1799 $as_echo_n "checking $2 presence... " >&6; }
1800 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1801 /* end confdefs.h.  */
1802 #include <$2>
1803 _ACEOF
1804 if ac_fn_c_try_cpp "$LINENO"; then :
1805   ac_header_preproc=yes
1806 else
1807   ac_header_preproc=no
1808 fi
1809 rm -f conftest.err conftest.i conftest.$ac_ext
1810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5
1811 $as_echo "$ac_header_preproc" >&6; }
1812
1813 # So?  What about this header?
1814 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in #((
1815   yes:no: )
1816     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5
1817 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;}
1818     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1819 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1820     ;;
1821   no:yes:* )
1822     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5
1823 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;}
1824     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     check for missing prerequisite headers?" >&5
1825 $as_echo "$as_me: WARNING: $2:     check for missing prerequisite headers?" >&2;}
1826     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5
1827 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;}
1828     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&5
1829 $as_echo "$as_me: WARNING: $2:     section \"Present But Cannot Be Compiled\"" >&2;}
1830     { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5
1831 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;}
1832 ( $as_echo "## ------------------------------------------- ##
1833 ## Report this to openssh-unix-dev@mindrot.org ##
1834 ## ------------------------------------------- ##"
1835      ) | sed "s/^/$as_me: WARNING:     /" >&2
1836     ;;
1837 esac
1838   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1839 $as_echo_n "checking for $2... " >&6; }
1840 if eval "test \"\${$3+set}\"" = set; then :
1841   $as_echo_n "(cached) " >&6
1842 else
1843   eval "$3=\$ac_header_compiler"
1844 fi
1845 eval ac_res=\$$3
1846                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1847 $as_echo "$ac_res" >&6; }
1848 fi
1849   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1850
1851 } # ac_fn_c_check_header_mongrel
1852
1853 # ac_fn_c_check_func LINENO FUNC VAR
1854 # ----------------------------------
1855 # Tests whether FUNC exists, setting the cache variable VAR accordingly
1856 ac_fn_c_check_func ()
1857 {
1858   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1859   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1860 $as_echo_n "checking for $2... " >&6; }
1861 if eval "test \"\${$3+set}\"" = set; then :
1862   $as_echo_n "(cached) " >&6
1863 else
1864   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1865 /* end confdefs.h.  */
1866 /* Define $2 to an innocuous variant, in case <limits.h> declares $2.
1867    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
1868 #define $2 innocuous_$2
1869
1870 /* System header to define __stub macros and hopefully few prototypes,
1871     which can conflict with char $2 (); below.
1872     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
1873     <limits.h> exists even on freestanding compilers.  */
1874
1875 #ifdef __STDC__
1876 # include <limits.h>
1877 #else
1878 # include <assert.h>
1879 #endif
1880
1881 #undef $2
1882
1883 /* Override any GCC internal prototype to avoid an error.
1884    Use char because int might match the return type of a GCC
1885    builtin and then its argument prototype would still apply.  */
1886 #ifdef __cplusplus
1887 extern "C"
1888 #endif
1889 char $2 ();
1890 /* The GNU C library defines this for functions which it implements
1891     to always fail with ENOSYS.  Some functions are actually named
1892     something starting with __ and the normal name is an alias.  */
1893 #if defined __stub_$2 || defined __stub___$2
1894 choke me
1895 #endif
1896
1897 int
1898 main ()
1899 {
1900 return $2 ();
1901   ;
1902   return 0;
1903 }
1904 _ACEOF
1905 if ac_fn_c_try_link "$LINENO"; then :
1906   eval "$3=yes"
1907 else
1908   eval "$3=no"
1909 fi
1910 rm -f core conftest.err conftest.$ac_objext \
1911     conftest$ac_exeext conftest.$ac_ext
1912 fi
1913 eval ac_res=\$$3
1914                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1915 $as_echo "$ac_res" >&6; }
1916   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1917
1918 } # ac_fn_c_check_func
1919
1920 # ac_fn_c_check_type LINENO TYPE VAR INCLUDES
1921 # -------------------------------------------
1922 # Tests whether TYPE exists after having included INCLUDES, setting cache
1923 # variable VAR accordingly.
1924 ac_fn_c_check_type ()
1925 {
1926   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1927   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5
1928 $as_echo_n "checking for $2... " >&6; }
1929 if eval "test \"\${$3+set}\"" = set; then :
1930   $as_echo_n "(cached) " >&6
1931 else
1932   eval "$3=no"
1933   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1934 /* end confdefs.h.  */
1935 $4
1936 int
1937 main ()
1938 {
1939 if (sizeof ($2))
1940          return 0;
1941   ;
1942   return 0;
1943 }
1944 _ACEOF
1945 if ac_fn_c_try_compile "$LINENO"; then :
1946   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1947 /* end confdefs.h.  */
1948 $4
1949 int
1950 main ()
1951 {
1952 if (sizeof (($2)))
1953             return 0;
1954   ;
1955   return 0;
1956 }
1957 _ACEOF
1958 if ac_fn_c_try_compile "$LINENO"; then :
1959
1960 else
1961   eval "$3=yes"
1962 fi
1963 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1964 fi
1965 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
1966 fi
1967 eval ac_res=\$$3
1968                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
1969 $as_echo "$ac_res" >&6; }
1970   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
1971
1972 } # ac_fn_c_check_type
1973
1974 # ac_fn_c_compute_int LINENO EXPR VAR INCLUDES
1975 # --------------------------------------------
1976 # Tries to find the compile-time value of EXPR in a program that includes
1977 # INCLUDES, setting VAR accordingly. Returns whether the value could be
1978 # computed
1979 ac_fn_c_compute_int ()
1980 {
1981   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
1982   if test "$cross_compiling" = yes; then
1983     # Depending upon the size, compute the lo and hi bounds.
1984 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
1985 /* end confdefs.h.  */
1986 $4
1987 int
1988 main ()
1989 {
1990 static int test_array [1 - 2 * !(($2) >= 0)];
1991 test_array [0] = 0
1992
1993   ;
1994   return 0;
1995 }
1996 _ACEOF
1997 if ac_fn_c_try_compile "$LINENO"; then :
1998   ac_lo=0 ac_mid=0
1999   while :; do
2000     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2001 /* end confdefs.h.  */
2002 $4
2003 int
2004 main ()
2005 {
2006 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2007 test_array [0] = 0
2008
2009   ;
2010   return 0;
2011 }
2012 _ACEOF
2013 if ac_fn_c_try_compile "$LINENO"; then :
2014   ac_hi=$ac_mid; break
2015 else
2016   as_fn_arith $ac_mid + 1 && ac_lo=$as_val
2017                         if test $ac_lo -le $ac_mid; then
2018                           ac_lo= ac_hi=
2019                           break
2020                         fi
2021                         as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val
2022 fi
2023 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2024   done
2025 else
2026   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2027 /* end confdefs.h.  */
2028 $4
2029 int
2030 main ()
2031 {
2032 static int test_array [1 - 2 * !(($2) < 0)];
2033 test_array [0] = 0
2034
2035   ;
2036   return 0;
2037 }
2038 _ACEOF
2039 if ac_fn_c_try_compile "$LINENO"; then :
2040   ac_hi=-1 ac_mid=-1
2041   while :; do
2042     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2043 /* end confdefs.h.  */
2044 $4
2045 int
2046 main ()
2047 {
2048 static int test_array [1 - 2 * !(($2) >= $ac_mid)];
2049 test_array [0] = 0
2050
2051   ;
2052   return 0;
2053 }
2054 _ACEOF
2055 if ac_fn_c_try_compile "$LINENO"; then :
2056   ac_lo=$ac_mid; break
2057 else
2058   as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val
2059                         if test $ac_mid -le $ac_hi; then
2060                           ac_lo= ac_hi=
2061                           break
2062                         fi
2063                         as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val
2064 fi
2065 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2066   done
2067 else
2068   ac_lo= ac_hi=
2069 fi
2070 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2071 fi
2072 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2073 # Binary search between lo and hi bounds.
2074 while test "x$ac_lo" != "x$ac_hi"; do
2075   as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val
2076   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2077 /* end confdefs.h.  */
2078 $4
2079 int
2080 main ()
2081 {
2082 static int test_array [1 - 2 * !(($2) <= $ac_mid)];
2083 test_array [0] = 0
2084
2085   ;
2086   return 0;
2087 }
2088 _ACEOF
2089 if ac_fn_c_try_compile "$LINENO"; then :
2090   ac_hi=$ac_mid
2091 else
2092   as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val
2093 fi
2094 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2095 done
2096 case $ac_lo in #((
2097 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;;
2098 '') ac_retval=1 ;;
2099 esac
2100   else
2101     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2102 /* end confdefs.h.  */
2103 $4
2104 static long int longval () { return $2; }
2105 static unsigned long int ulongval () { return $2; }
2106 #include <stdio.h>
2107 #include <stdlib.h>
2108 int
2109 main ()
2110 {
2111
2112   FILE *f = fopen ("conftest.val", "w");
2113   if (! f)
2114     return 1;
2115   if (($2) < 0)
2116     {
2117       long int i = longval ();
2118       if (i != ($2))
2119         return 1;
2120       fprintf (f, "%ld", i);
2121     }
2122   else
2123     {
2124       unsigned long int i = ulongval ();
2125       if (i != ($2))
2126         return 1;
2127       fprintf (f, "%lu", i);
2128     }
2129   /* Do not output a trailing newline, as this causes \r\n confusion
2130      on some platforms.  */
2131   return ferror (f) || fclose (f) != 0;
2132
2133   ;
2134   return 0;
2135 }
2136 _ACEOF
2137 if ac_fn_c_try_run "$LINENO"; then :
2138   echo >>conftest.val; read $3 <conftest.val; ac_retval=0
2139 else
2140   ac_retval=1
2141 fi
2142 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
2143   conftest.$ac_objext conftest.beam conftest.$ac_ext
2144 rm -f conftest.val
2145
2146   fi
2147   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2148   as_fn_set_status $ac_retval
2149
2150 } # ac_fn_c_compute_int
2151
2152 # ac_fn_c_check_member LINENO AGGR MEMBER VAR INCLUDES
2153 # ----------------------------------------------------
2154 # Tries to find if the field MEMBER exists in type AGGR, after including
2155 # INCLUDES, setting cache variable VAR accordingly.
2156 ac_fn_c_check_member ()
2157 {
2158   as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
2159   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2.$3" >&5
2160 $as_echo_n "checking for $2.$3... " >&6; }
2161 if eval "test \"\${$4+set}\"" = set; then :
2162   $as_echo_n "(cached) " >&6
2163 else
2164   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2165 /* end confdefs.h.  */
2166 $5
2167 int
2168 main ()
2169 {
2170 static $2 ac_aggr;
2171 if (ac_aggr.$3)
2172 return 0;
2173   ;
2174   return 0;
2175 }
2176 _ACEOF
2177 if ac_fn_c_try_compile "$LINENO"; then :
2178   eval "$4=yes"
2179 else
2180   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2181 /* end confdefs.h.  */
2182 $5
2183 int
2184 main ()
2185 {
2186 static $2 ac_aggr;
2187 if (sizeof ac_aggr.$3)
2188 return 0;
2189   ;
2190   return 0;
2191 }
2192 _ACEOF
2193 if ac_fn_c_try_compile "$LINENO"; then :
2194   eval "$4=yes"
2195 else
2196   eval "$4=no"
2197 fi
2198 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2199 fi
2200 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2201 fi
2202 eval ac_res=\$$4
2203                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
2204 $as_echo "$ac_res" >&6; }
2205   eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;}
2206
2207 } # ac_fn_c_check_member
2208 cat >config.log <<_ACEOF
2209 This file contains any messages produced by compilers while
2210 running configure, to aid debugging if configure makes a mistake.
2211
2212 It was created by OpenSSH $as_me Portable, which was
2213 generated by GNU Autoconf 2.67.  Invocation command line was
2214
2215   $ $0 $@
2216
2217 _ACEOF
2218 exec 5>>config.log
2219 {
2220 cat <<_ASUNAME
2221 ## --------- ##
2222 ## Platform. ##
2223 ## --------- ##
2224
2225 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
2226 uname -m = `(uname -m) 2>/dev/null || echo unknown`
2227 uname -r = `(uname -r) 2>/dev/null || echo unknown`
2228 uname -s = `(uname -s) 2>/dev/null || echo unknown`
2229 uname -v = `(uname -v) 2>/dev/null || echo unknown`
2230
2231 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
2232 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
2233
2234 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
2235 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
2236 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
2237 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
2238 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
2239 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
2240 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
2241
2242 _ASUNAME
2243
2244 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2245 for as_dir in $PATH
2246 do
2247   IFS=$as_save_IFS
2248   test -z "$as_dir" && as_dir=.
2249     $as_echo "PATH: $as_dir"
2250   done
2251 IFS=$as_save_IFS
2252
2253 } >&5
2254
2255 cat >&5 <<_ACEOF
2256
2257
2258 ## ----------- ##
2259 ## Core tests. ##
2260 ## ----------- ##
2261
2262 _ACEOF
2263
2264
2265 # Keep a trace of the command line.
2266 # Strip out --no-create and --no-recursion so they do not pile up.
2267 # Strip out --silent because we don't want to record it for future runs.
2268 # Also quote any args containing shell meta-characters.
2269 # Make two passes to allow for proper duplicate-argument suppression.
2270 ac_configure_args=
2271 ac_configure_args0=
2272 ac_configure_args1=
2273 ac_must_keep_next=false
2274 for ac_pass in 1 2
2275 do
2276   for ac_arg
2277   do
2278     case $ac_arg in
2279     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
2280     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
2281     | -silent | --silent | --silen | --sile | --sil)
2282       continue ;;
2283     *\'*)
2284       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
2285     esac
2286     case $ac_pass in
2287     1) as_fn_append ac_configure_args0 " '$ac_arg'" ;;
2288     2)
2289       as_fn_append ac_configure_args1 " '$ac_arg'"
2290       if test $ac_must_keep_next = true; then
2291         ac_must_keep_next=false # Got value, back to normal.
2292       else
2293         case $ac_arg in
2294           *=* | --config-cache | -C | -disable-* | --disable-* \
2295           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
2296           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
2297           | -with-* | --with-* | -without-* | --without-* | --x)
2298             case "$ac_configure_args0 " in
2299               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
2300             esac
2301             ;;
2302           -* ) ac_must_keep_next=true ;;
2303         esac
2304       fi
2305       as_fn_append ac_configure_args " '$ac_arg'"
2306       ;;
2307     esac
2308   done
2309 done
2310 { ac_configure_args0=; unset ac_configure_args0;}
2311 { ac_configure_args1=; unset ac_configure_args1;}
2312
2313 # When interrupted or exit'd, cleanup temporary files, and complete
2314 # config.log.  We remove comments because anyway the quotes in there
2315 # would cause problems or look ugly.
2316 # WARNING: Use '\'' to represent an apostrophe within the trap.
2317 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
2318 trap 'exit_status=$?
2319   # Save into config.log some information that might help in debugging.
2320   {
2321     echo
2322
2323     $as_echo "## ---------------- ##
2324 ## Cache variables. ##
2325 ## ---------------- ##"
2326     echo
2327     # The following way of writing the cache mishandles newlines in values,
2328 (
2329   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
2330     eval ac_val=\$$ac_var
2331     case $ac_val in #(
2332     *${as_nl}*)
2333       case $ac_var in #(
2334       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
2335 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
2336       esac
2337       case $ac_var in #(
2338       _ | IFS | as_nl) ;; #(
2339       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
2340       *) { eval $ac_var=; unset $ac_var;} ;;
2341       esac ;;
2342     esac
2343   done
2344   (set) 2>&1 |
2345     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
2346     *${as_nl}ac_space=\ *)
2347       sed -n \
2348         "s/'\''/'\''\\\\'\'''\''/g;
2349           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
2350       ;; #(
2351     *)
2352       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
2353       ;;
2354     esac |
2355     sort
2356 )
2357     echo
2358
2359     $as_echo "## ----------------- ##
2360 ## Output variables. ##
2361 ## ----------------- ##"
2362     echo
2363     for ac_var in $ac_subst_vars
2364     do
2365       eval ac_val=\$$ac_var
2366       case $ac_val in
2367       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2368       esac
2369       $as_echo "$ac_var='\''$ac_val'\''"
2370     done | sort
2371     echo
2372
2373     if test -n "$ac_subst_files"; then
2374       $as_echo "## ------------------- ##
2375 ## File substitutions. ##
2376 ## ------------------- ##"
2377       echo
2378       for ac_var in $ac_subst_files
2379       do
2380         eval ac_val=\$$ac_var
2381         case $ac_val in
2382         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
2383         esac
2384         $as_echo "$ac_var='\''$ac_val'\''"
2385       done | sort
2386       echo
2387     fi
2388
2389     if test -s confdefs.h; then
2390       $as_echo "## ----------- ##
2391 ## confdefs.h. ##
2392 ## ----------- ##"
2393       echo
2394       cat confdefs.h
2395       echo
2396     fi
2397     test "$ac_signal" != 0 &&
2398       $as_echo "$as_me: caught signal $ac_signal"
2399     $as_echo "$as_me: exit $exit_status"
2400   } >&5
2401   rm -f core *.core core.conftest.* &&
2402     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
2403     exit $exit_status
2404 ' 0
2405 for ac_signal in 1 2 13 15; do
2406   trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal
2407 done
2408 ac_signal=0
2409
2410 # confdefs.h avoids OS command line length limits that DEFS can exceed.
2411 rm -f -r conftest* confdefs.h
2412
2413 $as_echo "/* confdefs.h */" > confdefs.h
2414
2415 # Predefined preprocessor variables.
2416
2417 cat >>confdefs.h <<_ACEOF
2418 #define PACKAGE_NAME "$PACKAGE_NAME"
2419 _ACEOF
2420
2421 cat >>confdefs.h <<_ACEOF
2422 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
2423 _ACEOF
2424
2425 cat >>confdefs.h <<_ACEOF
2426 #define PACKAGE_VERSION "$PACKAGE_VERSION"
2427 _ACEOF
2428
2429 cat >>confdefs.h <<_ACEOF
2430 #define PACKAGE_STRING "$PACKAGE_STRING"
2431 _ACEOF
2432
2433 cat >>confdefs.h <<_ACEOF
2434 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
2435 _ACEOF
2436
2437 cat >>confdefs.h <<_ACEOF
2438 #define PACKAGE_URL "$PACKAGE_URL"
2439 _ACEOF
2440
2441
2442 # Let the site file select an alternate cache file if it wants to.
2443 # Prefer an explicitly selected file to automatically selected ones.
2444 ac_site_file1=NONE
2445 ac_site_file2=NONE
2446 if test -n "$CONFIG_SITE"; then
2447   # We do not want a PATH search for config.site.
2448   case $CONFIG_SITE in #((
2449     -*)  ac_site_file1=./$CONFIG_SITE;;
2450     */*) ac_site_file1=$CONFIG_SITE;;
2451     *)   ac_site_file1=./$CONFIG_SITE;;
2452   esac
2453 elif test "x$prefix" != xNONE; then
2454   ac_site_file1=$prefix/share/config.site
2455   ac_site_file2=$prefix/etc/config.site
2456 else
2457   ac_site_file1=$ac_default_prefix/share/config.site
2458   ac_site_file2=$ac_default_prefix/etc/config.site
2459 fi
2460 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
2461 do
2462   test "x$ac_site_file" = xNONE && continue
2463   if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then
2464     { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5
2465 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
2466     sed 's/^/| /' "$ac_site_file" >&5
2467     . "$ac_site_file" \
2468       || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2469 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2470 as_fn_error $? "failed to load site script $ac_site_file
2471 See \`config.log' for more details" "$LINENO" 5 ; }
2472   fi
2473 done
2474
2475 if test -r "$cache_file"; then
2476   # Some versions of bash will fail to source /dev/null (special files
2477   # actually), so we avoid doing that.  DJGPP emulates it as a regular file.
2478   if test /dev/null != "$cache_file" && test -f "$cache_file"; then
2479     { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5
2480 $as_echo "$as_me: loading cache $cache_file" >&6;}
2481     case $cache_file in
2482       [\\/]* | ?:[\\/]* ) . "$cache_file";;
2483       *)                      . "./$cache_file";;
2484     esac
2485   fi
2486 else
2487   { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5
2488 $as_echo "$as_me: creating cache $cache_file" >&6;}
2489   >$cache_file
2490 fi
2491
2492 # Check that the precious variables saved in the cache have kept the same
2493 # value.
2494 ac_cache_corrupted=false
2495 for ac_var in $ac_precious_vars; do
2496   eval ac_old_set=\$ac_cv_env_${ac_var}_set
2497   eval ac_new_set=\$ac_env_${ac_var}_set
2498   eval ac_old_val=\$ac_cv_env_${ac_var}_value
2499   eval ac_new_val=\$ac_env_${ac_var}_value
2500   case $ac_old_set,$ac_new_set in
2501     set,)
2502       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
2503 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
2504       ac_cache_corrupted=: ;;
2505     ,set)
2506       { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5
2507 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
2508       ac_cache_corrupted=: ;;
2509     ,);;
2510     *)
2511       if test "x$ac_old_val" != "x$ac_new_val"; then
2512         # differences in whitespace do not lead to failure.
2513         ac_old_val_w=`echo x $ac_old_val`
2514         ac_new_val_w=`echo x $ac_new_val`
2515         if test "$ac_old_val_w" != "$ac_new_val_w"; then
2516           { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5
2517 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
2518           ac_cache_corrupted=:
2519         else
2520           { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
2521 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
2522           eval $ac_var=\$ac_old_val
2523         fi
2524         { $as_echo "$as_me:${as_lineno-$LINENO}:   former value:  \`$ac_old_val'" >&5
2525 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
2526         { $as_echo "$as_me:${as_lineno-$LINENO}:   current value: \`$ac_new_val'" >&5
2527 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
2528       fi;;
2529   esac
2530   # Pass precious variables to config.status.
2531   if test "$ac_new_set" = set; then
2532     case $ac_new_val in
2533     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
2534     *) ac_arg=$ac_var=$ac_new_val ;;
2535     esac
2536     case " $ac_configure_args " in
2537       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
2538       *) as_fn_append ac_configure_args " '$ac_arg'" ;;
2539     esac
2540   fi
2541 done
2542 if $ac_cache_corrupted; then
2543   { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2544 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2545   { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5
2546 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
2547   as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5
2548 fi
2549 ## -------------------- ##
2550 ## Main body of script. ##
2551 ## -------------------- ##
2552
2553 ac_ext=c
2554 ac_cpp='$CPP $CPPFLAGS'
2555 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2556 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2557 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2558
2559
2560
2561
2562 ac_ext=c
2563 ac_cpp='$CPP $CPPFLAGS'
2564 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2565 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2566 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2567
2568
2569 ac_config_headers="$ac_config_headers config.h"
2570
2571 ac_ext=c
2572 ac_cpp='$CPP $CPPFLAGS'
2573 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2574 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2575 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2576 if test -n "$ac_tool_prefix"; then
2577   # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
2578 set dummy ${ac_tool_prefix}gcc; ac_word=$2
2579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2580 $as_echo_n "checking for $ac_word... " >&6; }
2581 if test "${ac_cv_prog_CC+set}" = set; then :
2582   $as_echo_n "(cached) " >&6
2583 else
2584   if test -n "$CC"; then
2585   ac_cv_prog_CC="$CC" # Let the user override the test.
2586 else
2587 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2588 for as_dir in $PATH
2589 do
2590   IFS=$as_save_IFS
2591   test -z "$as_dir" && as_dir=.
2592     for ac_exec_ext in '' $ac_executable_extensions; do
2593   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2594     ac_cv_prog_CC="${ac_tool_prefix}gcc"
2595     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2596     break 2
2597   fi
2598 done
2599   done
2600 IFS=$as_save_IFS
2601
2602 fi
2603 fi
2604 CC=$ac_cv_prog_CC
2605 if test -n "$CC"; then
2606   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2607 $as_echo "$CC" >&6; }
2608 else
2609   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2610 $as_echo "no" >&6; }
2611 fi
2612
2613
2614 fi
2615 if test -z "$ac_cv_prog_CC"; then
2616   ac_ct_CC=$CC
2617   # Extract the first word of "gcc", so it can be a program name with args.
2618 set dummy gcc; ac_word=$2
2619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2620 $as_echo_n "checking for $ac_word... " >&6; }
2621 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
2622   $as_echo_n "(cached) " >&6
2623 else
2624   if test -n "$ac_ct_CC"; then
2625   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2626 else
2627 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2628 for as_dir in $PATH
2629 do
2630   IFS=$as_save_IFS
2631   test -z "$as_dir" && as_dir=.
2632     for ac_exec_ext in '' $ac_executable_extensions; do
2633   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2634     ac_cv_prog_ac_ct_CC="gcc"
2635     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2636     break 2
2637   fi
2638 done
2639   done
2640 IFS=$as_save_IFS
2641
2642 fi
2643 fi
2644 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2645 if test -n "$ac_ct_CC"; then
2646   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2647 $as_echo "$ac_ct_CC" >&6; }
2648 else
2649   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2650 $as_echo "no" >&6; }
2651 fi
2652
2653   if test "x$ac_ct_CC" = x; then
2654     CC=""
2655   else
2656     case $cross_compiling:$ac_tool_warned in
2657 yes:)
2658 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2659 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2660 ac_tool_warned=yes ;;
2661 esac
2662     CC=$ac_ct_CC
2663   fi
2664 else
2665   CC="$ac_cv_prog_CC"
2666 fi
2667
2668 if test -z "$CC"; then
2669           if test -n "$ac_tool_prefix"; then
2670     # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
2671 set dummy ${ac_tool_prefix}cc; ac_word=$2
2672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2673 $as_echo_n "checking for $ac_word... " >&6; }
2674 if test "${ac_cv_prog_CC+set}" = set; then :
2675   $as_echo_n "(cached) " >&6
2676 else
2677   if test -n "$CC"; then
2678   ac_cv_prog_CC="$CC" # Let the user override the test.
2679 else
2680 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2681 for as_dir in $PATH
2682 do
2683   IFS=$as_save_IFS
2684   test -z "$as_dir" && as_dir=.
2685     for ac_exec_ext in '' $ac_executable_extensions; do
2686   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2687     ac_cv_prog_CC="${ac_tool_prefix}cc"
2688     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2689     break 2
2690   fi
2691 done
2692   done
2693 IFS=$as_save_IFS
2694
2695 fi
2696 fi
2697 CC=$ac_cv_prog_CC
2698 if test -n "$CC"; then
2699   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2700 $as_echo "$CC" >&6; }
2701 else
2702   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2703 $as_echo "no" >&6; }
2704 fi
2705
2706
2707   fi
2708 fi
2709 if test -z "$CC"; then
2710   # Extract the first word of "cc", so it can be a program name with args.
2711 set dummy cc; ac_word=$2
2712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2713 $as_echo_n "checking for $ac_word... " >&6; }
2714 if test "${ac_cv_prog_CC+set}" = set; then :
2715   $as_echo_n "(cached) " >&6
2716 else
2717   if test -n "$CC"; then
2718   ac_cv_prog_CC="$CC" # Let the user override the test.
2719 else
2720   ac_prog_rejected=no
2721 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2722 for as_dir in $PATH
2723 do
2724   IFS=$as_save_IFS
2725   test -z "$as_dir" && as_dir=.
2726     for ac_exec_ext in '' $ac_executable_extensions; do
2727   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2728     if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
2729        ac_prog_rejected=yes
2730        continue
2731      fi
2732     ac_cv_prog_CC="cc"
2733     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2734     break 2
2735   fi
2736 done
2737   done
2738 IFS=$as_save_IFS
2739
2740 if test $ac_prog_rejected = yes; then
2741   # We found a bogon in the path, so make sure we never use it.
2742   set dummy $ac_cv_prog_CC
2743   shift
2744   if test $# != 0; then
2745     # We chose a different compiler from the bogus one.
2746     # However, it has the same basename, so the bogon will be chosen
2747     # first if we set CC to just the basename; use the full file name.
2748     shift
2749     ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
2750   fi
2751 fi
2752 fi
2753 fi
2754 CC=$ac_cv_prog_CC
2755 if test -n "$CC"; then
2756   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2757 $as_echo "$CC" >&6; }
2758 else
2759   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2760 $as_echo "no" >&6; }
2761 fi
2762
2763
2764 fi
2765 if test -z "$CC"; then
2766   if test -n "$ac_tool_prefix"; then
2767   for ac_prog in cl.exe
2768   do
2769     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2770 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2772 $as_echo_n "checking for $ac_word... " >&6; }
2773 if test "${ac_cv_prog_CC+set}" = set; then :
2774   $as_echo_n "(cached) " >&6
2775 else
2776   if test -n "$CC"; then
2777   ac_cv_prog_CC="$CC" # Let the user override the test.
2778 else
2779 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2780 for as_dir in $PATH
2781 do
2782   IFS=$as_save_IFS
2783   test -z "$as_dir" && as_dir=.
2784     for ac_exec_ext in '' $ac_executable_extensions; do
2785   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2786     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2787     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2788     break 2
2789   fi
2790 done
2791   done
2792 IFS=$as_save_IFS
2793
2794 fi
2795 fi
2796 CC=$ac_cv_prog_CC
2797 if test -n "$CC"; then
2798   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5
2799 $as_echo "$CC" >&6; }
2800 else
2801   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2802 $as_echo "no" >&6; }
2803 fi
2804
2805
2806     test -n "$CC" && break
2807   done
2808 fi
2809 if test -z "$CC"; then
2810   ac_ct_CC=$CC
2811   for ac_prog in cl.exe
2812 do
2813   # Extract the first word of "$ac_prog", so it can be a program name with args.
2814 set dummy $ac_prog; ac_word=$2
2815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
2816 $as_echo_n "checking for $ac_word... " >&6; }
2817 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then :
2818   $as_echo_n "(cached) " >&6
2819 else
2820   if test -n "$ac_ct_CC"; then
2821   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2822 else
2823 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2824 for as_dir in $PATH
2825 do
2826   IFS=$as_save_IFS
2827   test -z "$as_dir" && as_dir=.
2828     for ac_exec_ext in '' $ac_executable_extensions; do
2829   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2830     ac_cv_prog_ac_ct_CC="$ac_prog"
2831     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
2832     break 2
2833   fi
2834 done
2835   done
2836 IFS=$as_save_IFS
2837
2838 fi
2839 fi
2840 ac_ct_CC=$ac_cv_prog_ac_ct_CC
2841 if test -n "$ac_ct_CC"; then
2842   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5
2843 $as_echo "$ac_ct_CC" >&6; }
2844 else
2845   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2846 $as_echo "no" >&6; }
2847 fi
2848
2849
2850   test -n "$ac_ct_CC" && break
2851 done
2852
2853   if test "x$ac_ct_CC" = x; then
2854     CC=""
2855   else
2856     case $cross_compiling:$ac_tool_warned in
2857 yes:)
2858 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
2859 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
2860 ac_tool_warned=yes ;;
2861 esac
2862     CC=$ac_ct_CC
2863   fi
2864 fi
2865
2866 fi
2867
2868
2869 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2870 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2871 as_fn_error $? "no acceptable C compiler found in \$PATH
2872 See \`config.log' for more details" "$LINENO" 5 ; }
2873
2874 # Provide some information about the compiler.
2875 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5
2876 set X $ac_compile
2877 ac_compiler=$2
2878 for ac_option in --version -v -V -qversion; do
2879   { { ac_try="$ac_compiler $ac_option >&5"
2880 case "(($ac_try" in
2881   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2882   *) ac_try_echo=$ac_try;;
2883 esac
2884 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2885 $as_echo "$ac_try_echo"; } >&5
2886   (eval "$ac_compiler $ac_option >&5") 2>conftest.err
2887   ac_status=$?
2888   if test -s conftest.err; then
2889     sed '10a\
2890 ... rest of stderr output deleted ...
2891          10q' conftest.err >conftest.er1
2892     cat conftest.er1 >&5
2893   fi
2894   rm -f conftest.er1 conftest.err
2895   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2896   test $ac_status = 0; }
2897 done
2898
2899 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
2900 /* end confdefs.h.  */
2901
2902 int
2903 main ()
2904 {
2905
2906   ;
2907   return 0;
2908 }
2909 _ACEOF
2910 ac_clean_files_save=$ac_clean_files
2911 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
2912 # Try to create an executable without -o first, disregard a.out.
2913 # It will help us diagnose broken compilers, and finding out an intuition
2914 # of exeext.
2915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5
2916 $as_echo_n "checking whether the C compiler works... " >&6; }
2917 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2918
2919 # The possible output files:
2920 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
2921
2922 ac_rmfiles=
2923 for ac_file in $ac_files
2924 do
2925   case $ac_file in
2926     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
2927     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
2928   esac
2929 done
2930 rm -f $ac_rmfiles
2931
2932 if { { ac_try="$ac_link_default"
2933 case "(($ac_try" in
2934   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2935   *) ac_try_echo=$ac_try;;
2936 esac
2937 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
2938 $as_echo "$ac_try_echo"; } >&5
2939   (eval "$ac_link_default") 2>&5
2940   ac_status=$?
2941   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
2942   test $ac_status = 0; }; then :
2943   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
2944 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
2945 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
2946 # so that the user can short-circuit this test for compilers unknown to
2947 # Autoconf.
2948 for ac_file in $ac_files ''
2949 do
2950   test -f "$ac_file" || continue
2951   case $ac_file in
2952     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
2953         ;;
2954     [ab].out )
2955         # We found the default executable, but exeext='' is most
2956         # certainly right.
2957         break;;
2958     *.* )
2959         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
2960         then :; else
2961            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2962         fi
2963         # We set ac_cv_exeext here because the later test for it is not
2964         # safe: cross compilers may not add the suffix if given an `-o'
2965         # argument, so we may need to know it at that point already.
2966         # Even if this section looks crufty: it has the advantage of
2967         # actually working.
2968         break;;
2969     * )
2970         break;;
2971   esac
2972 done
2973 test "$ac_cv_exeext" = no && ac_cv_exeext=
2974
2975 else
2976   ac_file=''
2977 fi
2978 if test -z "$ac_file"; then :
2979   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
2980 $as_echo "no" >&6; }
2981 $as_echo "$as_me: failed program was:" >&5
2982 sed 's/^/| /' conftest.$ac_ext >&5
2983
2984 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
2985 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
2986 as_fn_error 77 "C compiler cannot create executables
2987 See \`config.log' for more details" "$LINENO" 5 ; }
2988 else
2989   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
2990 $as_echo "yes" >&6; }
2991 fi
2992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5
2993 $as_echo_n "checking for C compiler default output file name... " >&6; }
2994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5
2995 $as_echo "$ac_file" >&6; }
2996 ac_exeext=$ac_cv_exeext
2997
2998 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
2999 ac_clean_files=$ac_clean_files_save
3000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5
3001 $as_echo_n "checking for suffix of executables... " >&6; }
3002 if { { ac_try="$ac_link"
3003 case "(($ac_try" in
3004   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3005   *) ac_try_echo=$ac_try;;
3006 esac
3007 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3008 $as_echo "$ac_try_echo"; } >&5
3009   (eval "$ac_link") 2>&5
3010   ac_status=$?
3011   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3012   test $ac_status = 0; }; then :
3013   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3014 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3015 # work properly (i.e., refer to `conftest.exe'), while it won't with
3016 # `rm'.
3017 for ac_file in conftest.exe conftest conftest.*; do
3018   test -f "$ac_file" || continue
3019   case $ac_file in
3020     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3021     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3022           break;;
3023     * ) break;;
3024   esac
3025 done
3026 else
3027   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3028 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3029 as_fn_error $? "cannot compute suffix of executables: cannot compile and link
3030 See \`config.log' for more details" "$LINENO" 5 ; }
3031 fi
3032 rm -f conftest conftest$ac_cv_exeext
3033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5
3034 $as_echo "$ac_cv_exeext" >&6; }
3035
3036 rm -f conftest.$ac_ext
3037 EXEEXT=$ac_cv_exeext
3038 ac_exeext=$EXEEXT
3039 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3040 /* end confdefs.h.  */
3041 #include <stdio.h>
3042 int
3043 main ()
3044 {
3045 FILE *f = fopen ("conftest.out", "w");
3046  return ferror (f) || fclose (f) != 0;
3047
3048   ;
3049   return 0;
3050 }
3051 _ACEOF
3052 ac_clean_files="$ac_clean_files conftest.out"
3053 # Check that the compiler produces executables we can run.  If not, either
3054 # the compiler is broken, or we cross compile.
3055 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5
3056 $as_echo_n "checking whether we are cross compiling... " >&6; }
3057 if test "$cross_compiling" != yes; then
3058   { { ac_try="$ac_link"
3059 case "(($ac_try" in
3060   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3061   *) ac_try_echo=$ac_try;;
3062 esac
3063 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3064 $as_echo "$ac_try_echo"; } >&5
3065   (eval "$ac_link") 2>&5
3066   ac_status=$?
3067   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3068   test $ac_status = 0; }
3069   if { ac_try='./conftest$ac_cv_exeext'
3070   { { case "(($ac_try" in
3071   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3072   *) ac_try_echo=$ac_try;;
3073 esac
3074 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3075 $as_echo "$ac_try_echo"; } >&5
3076   (eval "$ac_try") 2>&5
3077   ac_status=$?
3078   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3079   test $ac_status = 0; }; }; then
3080     cross_compiling=no
3081   else
3082     if test "$cross_compiling" = maybe; then
3083         cross_compiling=yes
3084     else
3085         { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3086 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3087 as_fn_error $? "cannot run C compiled programs.
3088 If you meant to cross compile, use \`--host'.
3089 See \`config.log' for more details" "$LINENO" 5 ; }
3090     fi
3091   fi
3092 fi
3093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5
3094 $as_echo "$cross_compiling" >&6; }
3095
3096 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out
3097 ac_clean_files=$ac_clean_files_save
3098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5
3099 $as_echo_n "checking for suffix of object files... " >&6; }
3100 if test "${ac_cv_objext+set}" = set; then :
3101   $as_echo_n "(cached) " >&6
3102 else
3103   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3104 /* end confdefs.h.  */
3105
3106 int
3107 main ()
3108 {
3109
3110   ;
3111   return 0;
3112 }
3113 _ACEOF
3114 rm -f conftest.o conftest.obj
3115 if { { ac_try="$ac_compile"
3116 case "(($ac_try" in
3117   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3118   *) ac_try_echo=$ac_try;;
3119 esac
3120 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\""
3121 $as_echo "$ac_try_echo"; } >&5
3122   (eval "$ac_compile") 2>&5
3123   ac_status=$?
3124   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
3125   test $ac_status = 0; }; then :
3126   for ac_file in conftest.o conftest.obj conftest.*; do
3127   test -f "$ac_file" || continue;
3128   case $ac_file in
3129     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3130     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3131        break;;
3132   esac
3133 done
3134 else
3135   $as_echo "$as_me: failed program was:" >&5
3136 sed 's/^/| /' conftest.$ac_ext >&5
3137
3138 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3139 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3140 as_fn_error $? "cannot compute suffix of object files: cannot compile
3141 See \`config.log' for more details" "$LINENO" 5 ; }
3142 fi
3143 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3144 fi
3145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5
3146 $as_echo "$ac_cv_objext" >&6; }
3147 OBJEXT=$ac_cv_objext
3148 ac_objext=$OBJEXT
3149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5
3150 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3151 if test "${ac_cv_c_compiler_gnu+set}" = set; then :
3152   $as_echo_n "(cached) " >&6
3153 else
3154   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3155 /* end confdefs.h.  */
3156
3157 int
3158 main ()
3159 {
3160 #ifndef __GNUC__
3161        choke me
3162 #endif
3163
3164   ;
3165   return 0;
3166 }
3167 _ACEOF
3168 if ac_fn_c_try_compile "$LINENO"; then :
3169   ac_compiler_gnu=yes
3170 else
3171   ac_compiler_gnu=no
3172 fi
3173 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3174 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3175
3176 fi
3177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5
3178 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3179 if test $ac_compiler_gnu = yes; then
3180   GCC=yes
3181 else
3182   GCC=
3183 fi
3184 ac_test_CFLAGS=${CFLAGS+set}
3185 ac_save_CFLAGS=$CFLAGS
3186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5
3187 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3188 if test "${ac_cv_prog_cc_g+set}" = set; then :
3189   $as_echo_n "(cached) " >&6
3190 else
3191   ac_save_c_werror_flag=$ac_c_werror_flag
3192    ac_c_werror_flag=yes
3193    ac_cv_prog_cc_g=no
3194    CFLAGS="-g"
3195    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3196 /* end confdefs.h.  */
3197
3198 int
3199 main ()
3200 {
3201
3202   ;
3203   return 0;
3204 }
3205 _ACEOF
3206 if ac_fn_c_try_compile "$LINENO"; then :
3207   ac_cv_prog_cc_g=yes
3208 else
3209   CFLAGS=""
3210       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3211 /* end confdefs.h.  */
3212
3213 int
3214 main ()
3215 {
3216
3217   ;
3218   return 0;
3219 }
3220 _ACEOF
3221 if ac_fn_c_try_compile "$LINENO"; then :
3222
3223 else
3224   ac_c_werror_flag=$ac_save_c_werror_flag
3225          CFLAGS="-g"
3226          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3227 /* end confdefs.h.  */
3228
3229 int
3230 main ()
3231 {
3232
3233   ;
3234   return 0;
3235 }
3236 _ACEOF
3237 if ac_fn_c_try_compile "$LINENO"; then :
3238   ac_cv_prog_cc_g=yes
3239 fi
3240 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3241 fi
3242 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3243 fi
3244 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3245    ac_c_werror_flag=$ac_save_c_werror_flag
3246 fi
3247 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5
3248 $as_echo "$ac_cv_prog_cc_g" >&6; }
3249 if test "$ac_test_CFLAGS" = set; then
3250   CFLAGS=$ac_save_CFLAGS
3251 elif test $ac_cv_prog_cc_g = yes; then
3252   if test "$GCC" = yes; then
3253     CFLAGS="-g -O2"
3254   else
3255     CFLAGS="-g"
3256   fi
3257 else
3258   if test "$GCC" = yes; then
3259     CFLAGS="-O2"
3260   else
3261     CFLAGS=
3262   fi
3263 fi
3264 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5
3265 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3266 if test "${ac_cv_prog_cc_c89+set}" = set; then :
3267   $as_echo_n "(cached) " >&6
3268 else
3269   ac_cv_prog_cc_c89=no
3270 ac_save_CC=$CC
3271 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3272 /* end confdefs.h.  */
3273 #include <stdarg.h>
3274 #include <stdio.h>
3275 #include <sys/types.h>
3276 #include <sys/stat.h>
3277 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3278 struct buf { int x; };
3279 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3280 static char *e (p, i)
3281      char **p;
3282      int i;
3283 {
3284   return p[i];
3285 }
3286 static char *f (char * (*g) (char **, int), char **p, ...)
3287 {
3288   char *s;
3289   va_list v;
3290   va_start (v,p);
3291   s = g (p, va_arg (v,int));
3292   va_end (v);
3293   return s;
3294 }
3295
3296 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3297    function prototypes and stuff, but not '\xHH' hex character constants.
3298    These don't provoke an error unfortunately, instead are silently treated
3299    as 'x'.  The following induces an error, until -std is added to get
3300    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3301    array size at least.  It's necessary to write '\x00'==0 to get something
3302    that's true only with -std.  */
3303 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3304
3305 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3306    inside strings and character constants.  */
3307 #define FOO(x) 'x'
3308 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3309
3310 int test (int i, double x);
3311 struct s1 {int (*f) (int a);};
3312 struct s2 {int (*f) (double a);};
3313 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3314 int argc;
3315 char **argv;
3316 int
3317 main ()
3318 {
3319 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3320   ;
3321   return 0;
3322 }
3323 _ACEOF
3324 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3325         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3326 do
3327   CC="$ac_save_CC $ac_arg"
3328   if ac_fn_c_try_compile "$LINENO"; then :
3329   ac_cv_prog_cc_c89=$ac_arg
3330 fi
3331 rm -f core conftest.err conftest.$ac_objext
3332   test "x$ac_cv_prog_cc_c89" != "xno" && break
3333 done
3334 rm -f conftest.$ac_ext
3335 CC=$ac_save_CC
3336
3337 fi
3338 # AC_CACHE_VAL
3339 case "x$ac_cv_prog_cc_c89" in
3340   x)
3341     { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5
3342 $as_echo "none needed" >&6; } ;;
3343   xno)
3344     { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5
3345 $as_echo "unsupported" >&6; } ;;
3346   *)
3347     CC="$CC $ac_cv_prog_cc_c89"
3348     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5
3349 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3350 esac
3351 if test "x$ac_cv_prog_cc_c89" != xno; then :
3352
3353 fi
3354
3355 ac_ext=c
3356 ac_cpp='$CPP $CPPFLAGS'
3357 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3358 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3359 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3360
3361 ac_aux_dir=
3362 for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
3363   if test -f "$ac_dir/install-sh"; then
3364     ac_aux_dir=$ac_dir
3365     ac_install_sh="$ac_aux_dir/install-sh -c"
3366     break
3367   elif test -f "$ac_dir/install.sh"; then
3368     ac_aux_dir=$ac_dir
3369     ac_install_sh="$ac_aux_dir/install.sh -c"
3370     break
3371   elif test -f "$ac_dir/shtool"; then
3372     ac_aux_dir=$ac_dir
3373     ac_install_sh="$ac_aux_dir/shtool install -c"
3374     break
3375   fi
3376 done
3377 if test -z "$ac_aux_dir"; then
3378   as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5
3379 fi
3380
3381 # These three variables are undocumented and unsupported,
3382 # and are intended to be withdrawn in a future Autoconf release.
3383 # They can cause serious problems if a builder's source tree is in a directory
3384 # whose full name contains unusual characters.
3385 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
3386 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
3387 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
3388
3389
3390 # Make sure we can run config.sub.
3391 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
3392   as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5
3393
3394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5
3395 $as_echo_n "checking build system type... " >&6; }
3396 if test "${ac_cv_build+set}" = set; then :
3397   $as_echo_n "(cached) " >&6
3398 else
3399   ac_build_alias=$build_alias
3400 test "x$ac_build_alias" = x &&
3401   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
3402 test "x$ac_build_alias" = x &&
3403   as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5
3404 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
3405   as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5
3406
3407 fi
3408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5
3409 $as_echo "$ac_cv_build" >&6; }
3410 case $ac_cv_build in
3411 *-*-*) ;;
3412 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5 ;;
3413 esac
3414 build=$ac_cv_build
3415 ac_save_IFS=$IFS; IFS='-'
3416 set x $ac_cv_build
3417 shift
3418 build_cpu=$1
3419 build_vendor=$2
3420 shift; shift
3421 # Remember, the first character of IFS is used to create $*,
3422 # except with old shells:
3423 build_os=$*
3424 IFS=$ac_save_IFS
3425 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
3426
3427
3428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5
3429 $as_echo_n "checking host system type... " >&6; }
3430 if test "${ac_cv_host+set}" = set; then :
3431   $as_echo_n "(cached) " >&6
3432 else
3433   if test "x$host_alias" = x; then
3434   ac_cv_host=$ac_cv_build
3435 else
3436   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
3437     as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5
3438 fi
3439
3440 fi
3441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5
3442 $as_echo "$ac_cv_host" >&6; }
3443 case $ac_cv_host in
3444 *-*-*) ;;
3445 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5 ;;
3446 esac
3447 host=$ac_cv_host
3448 ac_save_IFS=$IFS; IFS='-'
3449 set x $ac_cv_host
3450 shift
3451 host_cpu=$1
3452 host_vendor=$2
3453 shift; shift
3454 # Remember, the first character of IFS is used to create $*,
3455 # except with old shells:
3456 host_os=$*
3457 IFS=$ac_save_IFS
3458 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
3459
3460
3461
3462 ac_ext=c
3463 ac_cpp='$CPP $CPPFLAGS'
3464 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3465 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3466 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
3468 $as_echo_n "checking how to run the C preprocessor... " >&6; }
3469 # On Suns, sometimes $CPP names a directory.
3470 if test -n "$CPP" && test -d "$CPP"; then
3471   CPP=
3472 fi
3473 if test -z "$CPP"; then
3474   if test "${ac_cv_prog_CPP+set}" = set; then :
3475   $as_echo_n "(cached) " >&6
3476 else
3477       # Double quotes because CPP needs to be expanded
3478     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3479     do
3480       ac_preproc_ok=false
3481 for ac_c_preproc_warn_flag in '' yes
3482 do
3483   # Use a header file that comes with gcc, so configuring glibc
3484   # with a fresh cross-compiler works.
3485   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3486   # <limits.h> exists even on freestanding compilers.
3487   # On the NeXT, cc -E runs the code through the compiler's parser,
3488   # not just through cpp. "Syntax error" is here to catch this case.
3489   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3490 /* end confdefs.h.  */
3491 #ifdef __STDC__
3492 # include <limits.h>
3493 #else
3494 # include <assert.h>
3495 #endif
3496                      Syntax error
3497 _ACEOF
3498 if ac_fn_c_try_cpp "$LINENO"; then :
3499
3500 else
3501   # Broken: fails on valid input.
3502 continue
3503 fi
3504 rm -f conftest.err conftest.i conftest.$ac_ext
3505
3506   # OK, works on sane cases.  Now check whether nonexistent headers
3507   # can be detected and how.
3508   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3509 /* end confdefs.h.  */
3510 #include <ac_nonexistent.h>
3511 _ACEOF
3512 if ac_fn_c_try_cpp "$LINENO"; then :
3513   # Broken: success on invalid input.
3514 continue
3515 else
3516   # Passes both tests.
3517 ac_preproc_ok=:
3518 break
3519 fi
3520 rm -f conftest.err conftest.i conftest.$ac_ext
3521
3522 done
3523 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3524 rm -f conftest.i conftest.err conftest.$ac_ext
3525 if $ac_preproc_ok; then :
3526   break
3527 fi
3528
3529     done
3530     ac_cv_prog_CPP=$CPP
3531
3532 fi
3533   CPP=$ac_cv_prog_CPP
3534 else
3535   ac_cv_prog_CPP=$CPP
3536 fi
3537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
3538 $as_echo "$CPP" >&6; }
3539 ac_preproc_ok=false
3540 for ac_c_preproc_warn_flag in '' yes
3541 do
3542   # Use a header file that comes with gcc, so configuring glibc
3543   # with a fresh cross-compiler works.
3544   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3545   # <limits.h> exists even on freestanding compilers.
3546   # On the NeXT, cc -E runs the code through the compiler's parser,
3547   # not just through cpp. "Syntax error" is here to catch this case.
3548   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3549 /* end confdefs.h.  */
3550 #ifdef __STDC__
3551 # include <limits.h>
3552 #else
3553 # include <assert.h>
3554 #endif
3555                      Syntax error
3556 _ACEOF
3557 if ac_fn_c_try_cpp "$LINENO"; then :
3558
3559 else
3560   # Broken: fails on valid input.
3561 continue
3562 fi
3563 rm -f conftest.err conftest.i conftest.$ac_ext
3564
3565   # OK, works on sane cases.  Now check whether nonexistent headers
3566   # can be detected and how.
3567   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3568 /* end confdefs.h.  */
3569 #include <ac_nonexistent.h>
3570 _ACEOF
3571 if ac_fn_c_try_cpp "$LINENO"; then :
3572   # Broken: success on invalid input.
3573 continue
3574 else
3575   # Passes both tests.
3576 ac_preproc_ok=:
3577 break
3578 fi
3579 rm -f conftest.err conftest.i conftest.$ac_ext
3580
3581 done
3582 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3583 rm -f conftest.i conftest.err conftest.$ac_ext
3584 if $ac_preproc_ok; then :
3585
3586 else
3587   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
3588 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3589 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
3590 See \`config.log' for more details" "$LINENO" 5 ; }
3591 fi
3592
3593 ac_ext=c
3594 ac_cpp='$CPP $CPPFLAGS'
3595 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3596 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3597 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3598
3599
3600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5
3601 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
3602 if test "${ac_cv_path_GREP+set}" = set; then :
3603   $as_echo_n "(cached) " >&6
3604 else
3605   if test -z "$GREP"; then
3606   ac_path_GREP_found=false
3607   # Loop through the user's path and test for each of PROGNAME-LIST
3608   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3609 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3610 do
3611   IFS=$as_save_IFS
3612   test -z "$as_dir" && as_dir=.
3613     for ac_prog in grep ggrep; do
3614     for ac_exec_ext in '' $ac_executable_extensions; do
3615       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3616       { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
3617 # Check for GNU ac_path_GREP and select it if it is found.
3618   # Check for GNU $ac_path_GREP
3619 case `"$ac_path_GREP" --version 2>&1` in
3620 *GNU*)
3621   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3622 *)
3623   ac_count=0
3624   $as_echo_n 0123456789 >"conftest.in"
3625   while :
3626   do
3627     cat "conftest.in" "conftest.in" >"conftest.tmp"
3628     mv "conftest.tmp" "conftest.in"
3629     cp "conftest.in" "conftest.nl"
3630     $as_echo 'GREP' >> "conftest.nl"
3631     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3632     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3633     as_fn_arith $ac_count + 1 && ac_count=$as_val
3634     if test $ac_count -gt ${ac_path_GREP_max-0}; then
3635       # Best one so far, save it but keep looking for a better one
3636       ac_cv_path_GREP="$ac_path_GREP"
3637       ac_path_GREP_max=$ac_count
3638     fi
3639     # 10*(2^10) chars as input seems more than enough
3640     test $ac_count -gt 10 && break
3641   done
3642   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3643 esac
3644
3645       $ac_path_GREP_found && break 3
3646     done
3647   done
3648   done
3649 IFS=$as_save_IFS
3650   if test -z "$ac_cv_path_GREP"; then
3651     as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3652   fi
3653 else
3654   ac_cv_path_GREP=$GREP
3655 fi
3656
3657 fi
3658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5
3659 $as_echo "$ac_cv_path_GREP" >&6; }
3660  GREP="$ac_cv_path_GREP"
3661
3662
3663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
3664 $as_echo_n "checking for egrep... " >&6; }
3665 if test "${ac_cv_path_EGREP+set}" = set; then :
3666   $as_echo_n "(cached) " >&6
3667 else
3668   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3669    then ac_cv_path_EGREP="$GREP -E"
3670    else
3671      if test -z "$EGREP"; then
3672   ac_path_EGREP_found=false
3673   # Loop through the user's path and test for each of PROGNAME-LIST
3674   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3675 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3676 do
3677   IFS=$as_save_IFS
3678   test -z "$as_dir" && as_dir=.
3679     for ac_prog in egrep; do
3680     for ac_exec_ext in '' $ac_executable_extensions; do
3681       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
3682       { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
3683 # Check for GNU ac_path_EGREP and select it if it is found.
3684   # Check for GNU $ac_path_EGREP
3685 case `"$ac_path_EGREP" --version 2>&1` in
3686 *GNU*)
3687   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
3688 *)
3689   ac_count=0
3690   $as_echo_n 0123456789 >"conftest.in"
3691   while :
3692   do
3693     cat "conftest.in" "conftest.in" >"conftest.tmp"
3694     mv "conftest.tmp" "conftest.in"
3695     cp "conftest.in" "conftest.nl"
3696     $as_echo 'EGREP' >> "conftest.nl"
3697     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3698     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3699     as_fn_arith $ac_count + 1 && ac_count=$as_val
3700     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
3701       # Best one so far, save it but keep looking for a better one
3702       ac_cv_path_EGREP="$ac_path_EGREP"
3703       ac_path_EGREP_max=$ac_count
3704     fi
3705     # 10*(2^10) chars as input seems more than enough
3706     test $ac_count -gt 10 && break
3707   done
3708   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3709 esac
3710
3711       $ac_path_EGREP_found && break 3
3712     done
3713   done
3714   done
3715 IFS=$as_save_IFS
3716   if test -z "$ac_cv_path_EGREP"; then
3717     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
3718   fi
3719 else
3720   ac_cv_path_EGREP=$EGREP
3721 fi
3722
3723    fi
3724 fi
3725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
3726 $as_echo "$ac_cv_path_EGREP" >&6; }
3727  EGREP="$ac_cv_path_EGREP"
3728
3729
3730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
3731 $as_echo_n "checking for ANSI C header files... " >&6; }
3732 if test "${ac_cv_header_stdc+set}" = set; then :
3733   $as_echo_n "(cached) " >&6
3734 else
3735   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3736 /* end confdefs.h.  */
3737 #include <stdlib.h>
3738 #include <stdarg.h>
3739 #include <string.h>
3740 #include <float.h>
3741
3742 int
3743 main ()
3744 {
3745
3746   ;
3747   return 0;
3748 }
3749 _ACEOF
3750 if ac_fn_c_try_compile "$LINENO"; then :
3751   ac_cv_header_stdc=yes
3752 else
3753   ac_cv_header_stdc=no
3754 fi
3755 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3756
3757 if test $ac_cv_header_stdc = yes; then
3758   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3759   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3760 /* end confdefs.h.  */
3761 #include <string.h>
3762
3763 _ACEOF
3764 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3765   $EGREP "memchr" >/dev/null 2>&1; then :
3766
3767 else
3768   ac_cv_header_stdc=no
3769 fi
3770 rm -f conftest*
3771
3772 fi
3773
3774 if test $ac_cv_header_stdc = yes; then
3775   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3776   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3777 /* end confdefs.h.  */
3778 #include <stdlib.h>
3779
3780 _ACEOF
3781 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3782   $EGREP "free" >/dev/null 2>&1; then :
3783
3784 else
3785   ac_cv_header_stdc=no
3786 fi
3787 rm -f conftest*
3788
3789 fi
3790
3791 if test $ac_cv_header_stdc = yes; then
3792   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3793   if test "$cross_compiling" = yes; then :
3794   :
3795 else
3796   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3797 /* end confdefs.h.  */
3798 #include <ctype.h>
3799 #include <stdlib.h>
3800 #if ((' ' & 0x0FF) == 0x020)
3801 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3802 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3803 #else
3804 # define ISLOWER(c) \
3805                    (('a' <= (c) && (c) <= 'i') \
3806                      || ('j' <= (c) && (c) <= 'r') \
3807                      || ('s' <= (c) && (c) <= 'z'))
3808 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
3809 #endif
3810
3811 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3812 int
3813 main ()
3814 {
3815   int i;
3816   for (i = 0; i < 256; i++)
3817     if (XOR (islower (i), ISLOWER (i))
3818         || toupper (i) != TOUPPER (i))
3819       return 2;
3820   return 0;
3821 }
3822 _ACEOF
3823 if ac_fn_c_try_run "$LINENO"; then :
3824
3825 else
3826   ac_cv_header_stdc=no
3827 fi
3828 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
3829   conftest.$ac_objext conftest.beam conftest.$ac_ext
3830 fi
3831
3832 fi
3833 fi
3834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5
3835 $as_echo "$ac_cv_header_stdc" >&6; }
3836 if test $ac_cv_header_stdc = yes; then
3837
3838 $as_echo "#define STDC_HEADERS 1" >>confdefs.h
3839
3840 fi
3841
3842 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
3843 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
3844                   inttypes.h stdint.h unistd.h
3845 do :
3846   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
3847 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default
3848 "
3849 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
3850   cat >>confdefs.h <<_ACEOF
3851 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
3852 _ACEOF
3853
3854 fi
3855
3856 done
3857
3858
3859  { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5
3860 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
3861 if test "${ac_cv_c_bigendian+set}" = set; then :
3862   $as_echo_n "(cached) " >&6
3863 else
3864   ac_cv_c_bigendian=unknown
3865     # See if we're dealing with a universal compiler.
3866     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3867 /* end confdefs.h.  */
3868 #ifndef __APPLE_CC__
3869                not a universal capable compiler
3870              #endif
3871              typedef int dummy;
3872
3873 _ACEOF
3874 if ac_fn_c_try_compile "$LINENO"; then :
3875
3876         # Check for potential -arch flags.  It is not universal unless
3877         # there are at least two -arch flags with different values.
3878         ac_arch=
3879         ac_prev=
3880         for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do
3881          if test -n "$ac_prev"; then
3882            case $ac_word in
3883              i?86 | x86_64 | ppc | ppc64)
3884                if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then
3885                  ac_arch=$ac_word
3886                else
3887                  ac_cv_c_bigendian=universal
3888                  break
3889                fi
3890                ;;
3891            esac
3892            ac_prev=
3893          elif test "x$ac_word" = "x-arch"; then
3894            ac_prev=arch
3895          fi
3896        done
3897 fi
3898 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3899     if test $ac_cv_c_bigendian = unknown; then
3900       # See if sys/param.h defines the BYTE_ORDER macro.
3901       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3902 /* end confdefs.h.  */
3903 #include <sys/types.h>
3904              #include <sys/param.h>
3905
3906 int
3907 main ()
3908 {
3909 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
3910                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
3911                      && LITTLE_ENDIAN)
3912               bogus endian macros
3913              #endif
3914
3915   ;
3916   return 0;
3917 }
3918 _ACEOF
3919 if ac_fn_c_try_compile "$LINENO"; then :
3920   # It does; now see whether it defined to BIG_ENDIAN or not.
3921          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3922 /* end confdefs.h.  */
3923 #include <sys/types.h>
3924                 #include <sys/param.h>
3925
3926 int
3927 main ()
3928 {
3929 #if BYTE_ORDER != BIG_ENDIAN
3930                  not big endian
3931                 #endif
3932
3933   ;
3934   return 0;
3935 }
3936 _ACEOF
3937 if ac_fn_c_try_compile "$LINENO"; then :
3938   ac_cv_c_bigendian=yes
3939 else
3940   ac_cv_c_bigendian=no
3941 fi
3942 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3943 fi
3944 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3945     fi
3946     if test $ac_cv_c_bigendian = unknown; then
3947       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
3948       cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3949 /* end confdefs.h.  */
3950 #include <limits.h>
3951
3952 int
3953 main ()
3954 {
3955 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
3956               bogus endian macros
3957              #endif
3958
3959   ;
3960   return 0;
3961 }
3962 _ACEOF
3963 if ac_fn_c_try_compile "$LINENO"; then :
3964   # It does; now see whether it defined to _BIG_ENDIAN or not.
3965          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3966 /* end confdefs.h.  */
3967 #include <limits.h>
3968
3969 int
3970 main ()
3971 {
3972 #ifndef _BIG_ENDIAN
3973                  not big endian
3974                 #endif
3975
3976   ;
3977   return 0;
3978 }
3979 _ACEOF
3980 if ac_fn_c_try_compile "$LINENO"; then :
3981   ac_cv_c_bigendian=yes
3982 else
3983   ac_cv_c_bigendian=no
3984 fi
3985 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3986 fi
3987 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3988     fi
3989     if test $ac_cv_c_bigendian = unknown; then
3990       # Compile a test program.
3991       if test "$cross_compiling" = yes; then :
3992   # Try to guess by grepping values from an object file.
3993          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
3994 /* end confdefs.h.  */
3995 short int ascii_mm[] =
3996                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
3997                 short int ascii_ii[] =
3998                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
3999                 int use_ascii (int i) {
4000                   return ascii_mm[i] + ascii_ii[i];
4001                 }
4002                 short int ebcdic_ii[] =
4003                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
4004                 short int ebcdic_mm[] =
4005                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
4006                 int use_ebcdic (int i) {
4007                   return ebcdic_mm[i] + ebcdic_ii[i];
4008                 }
4009                 extern int foo;
4010
4011 int
4012 main ()
4013 {
4014 return use_ascii (foo) == use_ebcdic (foo);
4015   ;
4016   return 0;
4017 }
4018 _ACEOF
4019 if ac_fn_c_try_compile "$LINENO"; then :
4020   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
4021               ac_cv_c_bigendian=yes
4022             fi
4023             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
4024               if test "$ac_cv_c_bigendian" = unknown; then
4025                 ac_cv_c_bigendian=no
4026               else
4027                 # finding both strings is unlikely to happen, but who knows?
4028                 ac_cv_c_bigendian=unknown
4029               fi
4030             fi
4031 fi
4032 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4033 else
4034   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4035 /* end confdefs.h.  */
4036 $ac_includes_default
4037 int
4038 main ()
4039 {
4040
4041              /* Are we little or big endian?  From Harbison&Steele.  */
4042              union
4043              {
4044                long int l;
4045                char c[sizeof (long int)];
4046              } u;
4047              u.l = 1;
4048              return u.c[sizeof (long int) - 1] == 1;
4049
4050   ;
4051   return 0;
4052 }
4053 _ACEOF
4054 if ac_fn_c_try_run "$LINENO"; then :
4055   ac_cv_c_bigendian=no
4056 else
4057   ac_cv_c_bigendian=yes
4058 fi
4059 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
4060   conftest.$ac_objext conftest.beam conftest.$ac_ext
4061 fi
4062
4063     fi
4064 fi
4065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5
4066 $as_echo "$ac_cv_c_bigendian" >&6; }
4067  case $ac_cv_c_bigendian in #(
4068    yes)
4069      $as_echo "#define WORDS_BIGENDIAN 1" >>confdefs.h
4070 ;; #(
4071    no)
4072       ;; #(
4073    universal)
4074
4075 $as_echo "#define AC_APPLE_UNIVERSAL_BUILD 1" >>confdefs.h
4076
4077      ;; #(
4078    *)
4079      as_fn_error $? "unknown endianness
4080  presetting ac_cv_c_bigendian=no (or yes) will help" "$LINENO" 5  ;;
4081  esac
4082
4083
4084 # Checks for programs.
4085 for ac_prog in gawk mawk nawk awk
4086 do
4087   # Extract the first word of "$ac_prog", so it can be a program name with args.
4088 set dummy $ac_prog; ac_word=$2
4089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4090 $as_echo_n "checking for $ac_word... " >&6; }
4091 if test "${ac_cv_prog_AWK+set}" = set; then :
4092   $as_echo_n "(cached) " >&6
4093 else
4094   if test -n "$AWK"; then
4095   ac_cv_prog_AWK="$AWK" # Let the user override the test.
4096 else
4097 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4098 for as_dir in $PATH
4099 do
4100   IFS=$as_save_IFS
4101   test -z "$as_dir" && as_dir=.
4102     for ac_exec_ext in '' $ac_executable_extensions; do
4103   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4104     ac_cv_prog_AWK="$ac_prog"
4105     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4106     break 2
4107   fi
4108 done
4109   done
4110 IFS=$as_save_IFS
4111
4112 fi
4113 fi
4114 AWK=$ac_cv_prog_AWK
4115 if test -n "$AWK"; then
4116   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5
4117 $as_echo "$AWK" >&6; }
4118 else
4119   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4120 $as_echo "no" >&6; }
4121 fi
4122
4123
4124   test -n "$AWK" && break
4125 done
4126
4127 ac_ext=c
4128 ac_cpp='$CPP $CPPFLAGS'
4129 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4130 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4131 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5
4133 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4134 # On Suns, sometimes $CPP names a directory.
4135 if test -n "$CPP" && test -d "$CPP"; then
4136   CPP=
4137 fi
4138 if test -z "$CPP"; then
4139   if test "${ac_cv_prog_CPP+set}" = set; then :
4140   $as_echo_n "(cached) " >&6
4141 else
4142       # Double quotes because CPP needs to be expanded
4143     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4144     do
4145       ac_preproc_ok=false
4146 for ac_c_preproc_warn_flag in '' yes
4147 do
4148   # Use a header file that comes with gcc, so configuring glibc
4149   # with a fresh cross-compiler works.
4150   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4151   # <limits.h> exists even on freestanding compilers.
4152   # On the NeXT, cc -E runs the code through the compiler's parser,
4153   # not just through cpp. "Syntax error" is here to catch this case.
4154   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4155 /* end confdefs.h.  */
4156 #ifdef __STDC__
4157 # include <limits.h>
4158 #else
4159 # include <assert.h>
4160 #endif
4161                      Syntax error
4162 _ACEOF
4163 if ac_fn_c_try_cpp "$LINENO"; then :
4164
4165 else
4166   # Broken: fails on valid input.
4167 continue
4168 fi
4169 rm -f conftest.err conftest.i conftest.$ac_ext
4170
4171   # OK, works on sane cases.  Now check whether nonexistent headers
4172   # can be detected and how.
4173   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4174 /* end confdefs.h.  */
4175 #include <ac_nonexistent.h>
4176 _ACEOF
4177 if ac_fn_c_try_cpp "$LINENO"; then :
4178   # Broken: success on invalid input.
4179 continue
4180 else
4181   # Passes both tests.
4182 ac_preproc_ok=:
4183 break
4184 fi
4185 rm -f conftest.err conftest.i conftest.$ac_ext
4186
4187 done
4188 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4189 rm -f conftest.i conftest.err conftest.$ac_ext
4190 if $ac_preproc_ok; then :
4191   break
4192 fi
4193
4194     done
4195     ac_cv_prog_CPP=$CPP
4196
4197 fi
4198   CPP=$ac_cv_prog_CPP
4199 else
4200   ac_cv_prog_CPP=$CPP
4201 fi
4202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5
4203 $as_echo "$CPP" >&6; }
4204 ac_preproc_ok=false
4205 for ac_c_preproc_warn_flag in '' yes
4206 do
4207   # Use a header file that comes with gcc, so configuring glibc
4208   # with a fresh cross-compiler works.
4209   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4210   # <limits.h> exists even on freestanding compilers.
4211   # On the NeXT, cc -E runs the code through the compiler's parser,
4212   # not just through cpp. "Syntax error" is here to catch this case.
4213   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4214 /* end confdefs.h.  */
4215 #ifdef __STDC__
4216 # include <limits.h>
4217 #else
4218 # include <assert.h>
4219 #endif
4220                      Syntax error
4221 _ACEOF
4222 if ac_fn_c_try_cpp "$LINENO"; then :
4223
4224 else
4225   # Broken: fails on valid input.
4226 continue
4227 fi
4228 rm -f conftest.err conftest.i conftest.$ac_ext
4229
4230   # OK, works on sane cases.  Now check whether nonexistent headers
4231   # can be detected and how.
4232   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
4233 /* end confdefs.h.  */
4234 #include <ac_nonexistent.h>
4235 _ACEOF
4236 if ac_fn_c_try_cpp "$LINENO"; then :
4237   # Broken: success on invalid input.
4238 continue
4239 else
4240   # Passes both tests.
4241 ac_preproc_ok=:
4242 break
4243 fi
4244 rm -f conftest.err conftest.i conftest.$ac_ext
4245
4246 done
4247 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4248 rm -f conftest.i conftest.err conftest.$ac_ext
4249 if $ac_preproc_ok; then :
4250
4251 else
4252   { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
4253 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4254 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check
4255 See \`config.log' for more details" "$LINENO" 5 ; }
4256 fi
4257
4258 ac_ext=c
4259 ac_cpp='$CPP $CPPFLAGS'
4260 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4261 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4262 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4263
4264 if test -n "$ac_tool_prefix"; then
4265   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
4266 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4268 $as_echo_n "checking for $ac_word... " >&6; }
4269 if test "${ac_cv_prog_RANLIB+set}" = set; then :
4270   $as_echo_n "(cached) " >&6
4271 else
4272   if test -n "$RANLIB"; then
4273   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4274 else
4275 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4276 for as_dir in $PATH
4277 do
4278   IFS=$as_save_IFS
4279   test -z "$as_dir" && as_dir=.
4280     for ac_exec_ext in '' $ac_executable_extensions; do
4281   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4282     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4283     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4284     break 2
4285   fi
4286 done
4287   done
4288 IFS=$as_save_IFS
4289
4290 fi
4291 fi
4292 RANLIB=$ac_cv_prog_RANLIB
4293 if test -n "$RANLIB"; then
4294   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5
4295 $as_echo "$RANLIB" >&6; }
4296 else
4297   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4298 $as_echo "no" >&6; }
4299 fi
4300
4301
4302 fi
4303 if test -z "$ac_cv_prog_RANLIB"; then
4304   ac_ct_RANLIB=$RANLIB
4305   # Extract the first word of "ranlib", so it can be a program name with args.
4306 set dummy ranlib; ac_word=$2
4307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4308 $as_echo_n "checking for $ac_word... " >&6; }
4309 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then :
4310   $as_echo_n "(cached) " >&6
4311 else
4312   if test -n "$ac_ct_RANLIB"; then
4313   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4314 else
4315 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4316 for as_dir in $PATH
4317 do
4318   IFS=$as_save_IFS
4319   test -z "$as_dir" && as_dir=.
4320     for ac_exec_ext in '' $ac_executable_extensions; do
4321   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4322     ac_cv_prog_ac_ct_RANLIB="ranlib"
4323     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4324     break 2
4325   fi
4326 done
4327   done
4328 IFS=$as_save_IFS
4329
4330 fi
4331 fi
4332 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4333 if test -n "$ac_ct_RANLIB"; then
4334   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5
4335 $as_echo "$ac_ct_RANLIB" >&6; }
4336 else
4337   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4338 $as_echo "no" >&6; }
4339 fi
4340
4341   if test "x$ac_ct_RANLIB" = x; then
4342     RANLIB=":"
4343   else
4344     case $cross_compiling:$ac_tool_warned in
4345 yes:)
4346 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4347 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4348 ac_tool_warned=yes ;;
4349 esac
4350     RANLIB=$ac_ct_RANLIB
4351   fi
4352 else
4353   RANLIB="$ac_cv_prog_RANLIB"
4354 fi
4355
4356 # Find a good install program.  We prefer a C program (faster),
4357 # so one script is as good as another.  But avoid the broken or
4358 # incompatible versions:
4359 # SysV /etc/install, /usr/sbin/install
4360 # SunOS /usr/etc/install
4361 # IRIX /sbin/install
4362 # AIX /bin/install
4363 # AmigaOS /C/install, which installs bootblocks on floppy discs
4364 # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
4365 # AFS /usr/afsws/bin/install, which mishandles nonexistent args
4366 # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
4367 # OS/2's system install, which has a completely different semantic
4368 # ./install, which can be erroneously created by make from ./install.sh.
4369 # Reject install programs that cannot install multiple files.
4370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5
4371 $as_echo_n "checking for a BSD-compatible install... " >&6; }
4372 if test -z "$INSTALL"; then
4373 if test "${ac_cv_path_install+set}" = set; then :
4374   $as_echo_n "(cached) " >&6
4375 else
4376   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4377 for as_dir in $PATH
4378 do
4379   IFS=$as_save_IFS
4380   test -z "$as_dir" && as_dir=.
4381     # Account for people who put trailing slashes in PATH elements.
4382 case $as_dir/ in #((
4383   ./ | .// | /[cC]/* | \
4384   /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
4385   ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \
4386   /usr/ucb/* ) ;;
4387   *)
4388     # OSF1 and SCO ODT 3.0 have their own names for install.
4389     # Don't use installbsd from OSF since it installs stuff as root
4390     # by default.
4391     for ac_prog in ginstall scoinst install; do
4392       for ac_exec_ext in '' $ac_executable_extensions; do
4393         if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
4394           if test $ac_prog = install &&
4395             grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4396             # AIX install.  It has an incompatible calling convention.
4397             :
4398           elif test $ac_prog = install &&
4399             grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4400             # program-specific install script used by HP pwplus--don't use.
4401             :
4402           else
4403             rm -rf conftest.one conftest.two conftest.dir
4404             echo one > conftest.one
4405             echo two > conftest.two
4406             mkdir conftest.dir
4407             if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" &&
4408               test -s conftest.one && test -s conftest.two &&
4409               test -s conftest.dir/conftest.one &&
4410               test -s conftest.dir/conftest.two
4411             then
4412               ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
4413               break 3
4414             fi
4415           fi
4416         fi
4417       done
4418     done
4419     ;;
4420 esac
4421
4422   done
4423 IFS=$as_save_IFS
4424
4425 rm -rf conftest.one conftest.two conftest.dir
4426
4427 fi
4428   if test "${ac_cv_path_install+set}" = set; then
4429     INSTALL=$ac_cv_path_install
4430   else
4431     # As a last resort, use the slow shell script.  Don't cache a
4432     # value for INSTALL within a source directory, because that will
4433     # break other packages using the cache if that directory is
4434     # removed, or if the value is a relative name.
4435     INSTALL=$ac_install_sh
4436   fi
4437 fi
4438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5
4439 $as_echo "$INSTALL" >&6; }
4440
4441 # Use test -z because SunOS4 sh mishandles braces in ${var-val}.
4442 # It thinks the first close brace ends the variable substitution.
4443 test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
4444
4445 test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
4446
4447 test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
4448
4449 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5
4450 $as_echo_n "checking for egrep... " >&6; }
4451 if test "${ac_cv_path_EGREP+set}" = set; then :
4452   $as_echo_n "(cached) " >&6
4453 else
4454   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4455    then ac_cv_path_EGREP="$GREP -E"
4456    else
4457      if test -z "$EGREP"; then
4458   ac_path_EGREP_found=false
4459   # Loop through the user's path and test for each of PROGNAME-LIST
4460   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4461 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4462 do
4463   IFS=$as_save_IFS
4464   test -z "$as_dir" && as_dir=.
4465     for ac_prog in egrep; do
4466     for ac_exec_ext in '' $ac_executable_extensions; do
4467       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4468       { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
4469 # Check for GNU ac_path_EGREP and select it if it is found.
4470   # Check for GNU $ac_path_EGREP
4471 case `"$ac_path_EGREP" --version 2>&1` in
4472 *GNU*)
4473   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4474 *)
4475   ac_count=0
4476   $as_echo_n 0123456789 >"conftest.in"
4477   while :
4478   do
4479     cat "conftest.in" "conftest.in" >"conftest.tmp"
4480     mv "conftest.tmp" "conftest.in"
4481     cp "conftest.in" "conftest.nl"
4482     $as_echo 'EGREP' >> "conftest.nl"
4483     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4484     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4485     as_fn_arith $ac_count + 1 && ac_count=$as_val
4486     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4487       # Best one so far, save it but keep looking for a better one
4488       ac_cv_path_EGREP="$ac_path_EGREP"
4489       ac_path_EGREP_max=$ac_count
4490     fi
4491     # 10*(2^10) chars as input seems more than enough
4492     test $ac_count -gt 10 && break
4493   done
4494   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4495 esac
4496
4497       $ac_path_EGREP_found && break 3
4498     done
4499   done
4500   done
4501 IFS=$as_save_IFS
4502   if test -z "$ac_cv_path_EGREP"; then
4503     as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5
4504   fi
4505 else
4506   ac_cv_path_EGREP=$EGREP
4507 fi
4508
4509    fi
4510 fi
4511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5
4512 $as_echo "$ac_cv_path_EGREP" >&6; }
4513  EGREP="$ac_cv_path_EGREP"
4514
4515
4516 # Extract the first word of "ar", so it can be a program name with args.
4517 set dummy ar; ac_word=$2
4518 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4519 $as_echo_n "checking for $ac_word... " >&6; }
4520 if test "${ac_cv_path_AR+set}" = set; then :
4521   $as_echo_n "(cached) " >&6
4522 else
4523   case $AR in
4524   [\\/]* | ?:[\\/]*)
4525   ac_cv_path_AR="$AR" # Let the user override the test with a path.
4526   ;;
4527   *)
4528   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4529 for as_dir in $PATH
4530 do
4531   IFS=$as_save_IFS
4532   test -z "$as_dir" && as_dir=.
4533     for ac_exec_ext in '' $ac_executable_extensions; do
4534   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4535     ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext"
4536     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4537     break 2
4538   fi
4539 done
4540   done
4541 IFS=$as_save_IFS
4542
4543   ;;
4544 esac
4545 fi
4546 AR=$ac_cv_path_AR
4547 if test -n "$AR"; then
4548   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5
4549 $as_echo "$AR" >&6; }
4550 else
4551   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4552 $as_echo "no" >&6; }
4553 fi
4554
4555
4556 # Extract the first word of "cat", so it can be a program name with args.
4557 set dummy cat; ac_word=$2
4558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4559 $as_echo_n "checking for $ac_word... " >&6; }
4560 if test "${ac_cv_path_CAT+set}" = set; then :
4561   $as_echo_n "(cached) " >&6
4562 else
4563   case $CAT in
4564   [\\/]* | ?:[\\/]*)
4565   ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4566   ;;
4567   *)
4568   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4569 for as_dir in $PATH
4570 do
4571   IFS=$as_save_IFS
4572   test -z "$as_dir" && as_dir=.
4573     for ac_exec_ext in '' $ac_executable_extensions; do
4574   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4575     ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4576     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4577     break 2
4578   fi
4579 done
4580   done
4581 IFS=$as_save_IFS
4582
4583   ;;
4584 esac
4585 fi
4586 CAT=$ac_cv_path_CAT
4587 if test -n "$CAT"; then
4588   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5
4589 $as_echo "$CAT" >&6; }
4590 else
4591   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4592 $as_echo "no" >&6; }
4593 fi
4594
4595
4596 # Extract the first word of "kill", so it can be a program name with args.
4597 set dummy kill; ac_word=$2
4598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4599 $as_echo_n "checking for $ac_word... " >&6; }
4600 if test "${ac_cv_path_KILL+set}" = set; then :
4601   $as_echo_n "(cached) " >&6
4602 else
4603   case $KILL in
4604   [\\/]* | ?:[\\/]*)
4605   ac_cv_path_KILL="$KILL" # Let the user override the test with a path.
4606   ;;
4607   *)
4608   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4609 for as_dir in $PATH
4610 do
4611   IFS=$as_save_IFS
4612   test -z "$as_dir" && as_dir=.
4613     for ac_exec_ext in '' $ac_executable_extensions; do
4614   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4615     ac_cv_path_KILL="$as_dir/$ac_word$ac_exec_ext"
4616     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4617     break 2
4618   fi
4619 done
4620   done
4621 IFS=$as_save_IFS
4622
4623   ;;
4624 esac
4625 fi
4626 KILL=$ac_cv_path_KILL
4627 if test -n "$KILL"; then
4628   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $KILL" >&5
4629 $as_echo "$KILL" >&6; }
4630 else
4631   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4632 $as_echo "no" >&6; }
4633 fi
4634
4635
4636 for ac_prog in perl5 perl
4637 do
4638   # Extract the first word of "$ac_prog", so it can be a program name with args.
4639 set dummy $ac_prog; ac_word=$2
4640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4641 $as_echo_n "checking for $ac_word... " >&6; }
4642 if test "${ac_cv_path_PERL+set}" = set; then :
4643   $as_echo_n "(cached) " >&6
4644 else
4645   case $PERL in
4646   [\\/]* | ?:[\\/]*)
4647   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
4648   ;;
4649   *)
4650   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4651 for as_dir in $PATH
4652 do
4653   IFS=$as_save_IFS
4654   test -z "$as_dir" && as_dir=.
4655     for ac_exec_ext in '' $ac_executable_extensions; do
4656   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4657     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
4658     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4659     break 2
4660   fi
4661 done
4662   done
4663 IFS=$as_save_IFS
4664
4665   ;;
4666 esac
4667 fi
4668 PERL=$ac_cv_path_PERL
4669 if test -n "$PERL"; then
4670   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PERL" >&5
4671 $as_echo "$PERL" >&6; }
4672 else
4673   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4674 $as_echo "no" >&6; }
4675 fi
4676
4677
4678   test -n "$PERL" && break
4679 done
4680
4681 # Extract the first word of "sed", so it can be a program name with args.
4682 set dummy sed; ac_word=$2
4683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4684 $as_echo_n "checking for $ac_word... " >&6; }
4685 if test "${ac_cv_path_SED+set}" = set; then :
4686   $as_echo_n "(cached) " >&6
4687 else
4688   case $SED in
4689   [\\/]* | ?:[\\/]*)
4690   ac_cv_path_SED="$SED" # Let the user override the test with a path.
4691   ;;
4692   *)
4693   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4694 for as_dir in $PATH
4695 do
4696   IFS=$as_save_IFS
4697   test -z "$as_dir" && as_dir=.
4698     for ac_exec_ext in '' $ac_executable_extensions; do
4699   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4700     ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext"
4701     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4702     break 2
4703   fi
4704 done
4705   done
4706 IFS=$as_save_IFS
4707
4708   ;;
4709 esac
4710 fi
4711 SED=$ac_cv_path_SED
4712 if test -n "$SED"; then
4713   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5
4714 $as_echo "$SED" >&6; }
4715 else
4716   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4717 $as_echo "no" >&6; }
4718 fi
4719
4720
4721
4722 # Extract the first word of "ent", so it can be a program name with args.
4723 set dummy ent; ac_word=$2
4724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4725 $as_echo_n "checking for $ac_word... " >&6; }
4726 if test "${ac_cv_path_ENT+set}" = set; then :
4727   $as_echo_n "(cached) " >&6
4728 else
4729   case $ENT in
4730   [\\/]* | ?:[\\/]*)
4731   ac_cv_path_ENT="$ENT" # Let the user override the test with a path.
4732   ;;
4733   *)
4734   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4735 for as_dir in $PATH
4736 do
4737   IFS=$as_save_IFS
4738   test -z "$as_dir" && as_dir=.
4739     for ac_exec_ext in '' $ac_executable_extensions; do
4740   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4741     ac_cv_path_ENT="$as_dir/$ac_word$ac_exec_ext"
4742     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4743     break 2
4744   fi
4745 done
4746   done
4747 IFS=$as_save_IFS
4748
4749   ;;
4750 esac
4751 fi
4752 ENT=$ac_cv_path_ENT
4753 if test -n "$ENT"; then
4754   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENT" >&5
4755 $as_echo "$ENT" >&6; }
4756 else
4757   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4758 $as_echo "no" >&6; }
4759 fi
4760
4761
4762
4763 # Extract the first word of "bash", so it can be a program name with args.
4764 set dummy bash; ac_word=$2
4765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4766 $as_echo_n "checking for $ac_word... " >&6; }
4767 if test "${ac_cv_path_TEST_MINUS_S_SH+set}" = set; then :
4768   $as_echo_n "(cached) " >&6
4769 else
4770   case $TEST_MINUS_S_SH in
4771   [\\/]* | ?:[\\/]*)
4772   ac_cv_path_TEST_MINUS_S_SH="$TEST_MINUS_S_SH" # Let the user override the test with a path.
4773   ;;
4774   *)
4775   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4776 for as_dir in $PATH
4777 do
4778   IFS=$as_save_IFS
4779   test -z "$as_dir" && as_dir=.
4780     for ac_exec_ext in '' $ac_executable_extensions; do
4781   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4782     ac_cv_path_TEST_MINUS_S_SH="$as_dir/$ac_word$ac_exec_ext"
4783     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4784     break 2
4785   fi
4786 done
4787   done
4788 IFS=$as_save_IFS
4789
4790   ;;
4791 esac
4792 fi
4793 TEST_MINUS_S_SH=$ac_cv_path_TEST_MINUS_S_SH
4794 if test -n "$TEST_MINUS_S_SH"; then
4795   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_MINUS_S_SH" >&5
4796 $as_echo "$TEST_MINUS_S_SH" >&6; }
4797 else
4798   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4799 $as_echo "no" >&6; }
4800 fi
4801
4802
4803 # Extract the first word of "ksh", so it can be a program name with args.
4804 set dummy ksh; ac_word=$2
4805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4806 $as_echo_n "checking for $ac_word... " >&6; }
4807 if test "${ac_cv_path_TEST_MINUS_S_SH+set}" = set; then :
4808   $as_echo_n "(cached) " >&6
4809 else
4810   case $TEST_MINUS_S_SH in
4811   [\\/]* | ?:[\\/]*)
4812   ac_cv_path_TEST_MINUS_S_SH="$TEST_MINUS_S_SH" # Let the user override the test with a path.
4813   ;;
4814   *)
4815   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4816 for as_dir in $PATH
4817 do
4818   IFS=$as_save_IFS
4819   test -z "$as_dir" && as_dir=.
4820     for ac_exec_ext in '' $ac_executable_extensions; do
4821   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4822     ac_cv_path_TEST_MINUS_S_SH="$as_dir/$ac_word$ac_exec_ext"
4823     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4824     break 2
4825   fi
4826 done
4827   done
4828 IFS=$as_save_IFS
4829
4830   ;;
4831 esac
4832 fi
4833 TEST_MINUS_S_SH=$ac_cv_path_TEST_MINUS_S_SH
4834 if test -n "$TEST_MINUS_S_SH"; then
4835   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_MINUS_S_SH" >&5
4836 $as_echo "$TEST_MINUS_S_SH" >&6; }
4837 else
4838   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4839 $as_echo "no" >&6; }
4840 fi
4841
4842
4843 # Extract the first word of "sh", so it can be a program name with args.
4844 set dummy sh; ac_word=$2
4845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4846 $as_echo_n "checking for $ac_word... " >&6; }
4847 if test "${ac_cv_path_TEST_MINUS_S_SH+set}" = set; then :
4848   $as_echo_n "(cached) " >&6
4849 else
4850   case $TEST_MINUS_S_SH in
4851   [\\/]* | ?:[\\/]*)
4852   ac_cv_path_TEST_MINUS_S_SH="$TEST_MINUS_S_SH" # Let the user override the test with a path.
4853   ;;
4854   *)
4855   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4856 for as_dir in $PATH
4857 do
4858   IFS=$as_save_IFS
4859   test -z "$as_dir" && as_dir=.
4860     for ac_exec_ext in '' $ac_executable_extensions; do
4861   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4862     ac_cv_path_TEST_MINUS_S_SH="$as_dir/$ac_word$ac_exec_ext"
4863     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4864     break 2
4865   fi
4866 done
4867   done
4868 IFS=$as_save_IFS
4869
4870   ;;
4871 esac
4872 fi
4873 TEST_MINUS_S_SH=$ac_cv_path_TEST_MINUS_S_SH
4874 if test -n "$TEST_MINUS_S_SH"; then
4875   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_MINUS_S_SH" >&5
4876 $as_echo "$TEST_MINUS_S_SH" >&6; }
4877 else
4878   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4879 $as_echo "no" >&6; }
4880 fi
4881
4882
4883 # Extract the first word of "sh", so it can be a program name with args.
4884 set dummy sh; ac_word=$2
4885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4886 $as_echo_n "checking for $ac_word... " >&6; }
4887 if test "${ac_cv_path_SH+set}" = set; then :
4888   $as_echo_n "(cached) " >&6
4889 else
4890   case $SH in
4891   [\\/]* | ?:[\\/]*)
4892   ac_cv_path_SH="$SH" # Let the user override the test with a path.
4893   ;;
4894   *)
4895   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4896 for as_dir in $PATH
4897 do
4898   IFS=$as_save_IFS
4899   test -z "$as_dir" && as_dir=.
4900     for ac_exec_ext in '' $ac_executable_extensions; do
4901   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4902     ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
4903     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4904     break 2
4905   fi
4906 done
4907   done
4908 IFS=$as_save_IFS
4909
4910   ;;
4911 esac
4912 fi
4913 SH=$ac_cv_path_SH
4914 if test -n "$SH"; then
4915   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5
4916 $as_echo "$SH" >&6; }
4917 else
4918   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4919 $as_echo "no" >&6; }
4920 fi
4921
4922
4923 # Extract the first word of "groff", so it can be a program name with args.
4924 set dummy groff; ac_word=$2
4925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4926 $as_echo_n "checking for $ac_word... " >&6; }
4927 if test "${ac_cv_path_GROFF+set}" = set; then :
4928   $as_echo_n "(cached) " >&6
4929 else
4930   case $GROFF in
4931   [\\/]* | ?:[\\/]*)
4932   ac_cv_path_GROFF="$GROFF" # Let the user override the test with a path.
4933   ;;
4934   *)
4935   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4936 for as_dir in $PATH
4937 do
4938   IFS=$as_save_IFS
4939   test -z "$as_dir" && as_dir=.
4940     for ac_exec_ext in '' $ac_executable_extensions; do
4941   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4942     ac_cv_path_GROFF="$as_dir/$ac_word$ac_exec_ext"
4943     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4944     break 2
4945   fi
4946 done
4947   done
4948 IFS=$as_save_IFS
4949
4950   ;;
4951 esac
4952 fi
4953 GROFF=$ac_cv_path_GROFF
4954 if test -n "$GROFF"; then
4955   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GROFF" >&5
4956 $as_echo "$GROFF" >&6; }
4957 else
4958   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4959 $as_echo "no" >&6; }
4960 fi
4961
4962
4963 # Extract the first word of "nroff", so it can be a program name with args.
4964 set dummy nroff; ac_word=$2
4965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4966 $as_echo_n "checking for $ac_word... " >&6; }
4967 if test "${ac_cv_path_NROFF+set}" = set; then :
4968   $as_echo_n "(cached) " >&6
4969 else
4970   case $NROFF in
4971   [\\/]* | ?:[\\/]*)
4972   ac_cv_path_NROFF="$NROFF" # Let the user override the test with a path.
4973   ;;
4974   *)
4975   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4976 for as_dir in $PATH
4977 do
4978   IFS=$as_save_IFS
4979   test -z "$as_dir" && as_dir=.
4980     for ac_exec_ext in '' $ac_executable_extensions; do
4981   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4982     ac_cv_path_NROFF="$as_dir/$ac_word$ac_exec_ext"
4983     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
4984     break 2
4985   fi
4986 done
4987   done
4988 IFS=$as_save_IFS
4989
4990   ;;
4991 esac
4992 fi
4993 NROFF=$ac_cv_path_NROFF
4994 if test -n "$NROFF"; then
4995   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NROFF" >&5
4996 $as_echo "$NROFF" >&6; }
4997 else
4998   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
4999 $as_echo "no" >&6; }
5000 fi
5001
5002
5003 # Extract the first word of "mandoc", so it can be a program name with args.
5004 set dummy mandoc; ac_word=$2
5005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5006 $as_echo_n "checking for $ac_word... " >&6; }
5007 if test "${ac_cv_path_MANDOC+set}" = set; then :
5008   $as_echo_n "(cached) " >&6
5009 else
5010   case $MANDOC in
5011   [\\/]* | ?:[\\/]*)
5012   ac_cv_path_MANDOC="$MANDOC" # Let the user override the test with a path.
5013   ;;
5014   *)
5015   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5016 for as_dir in $PATH
5017 do
5018   IFS=$as_save_IFS
5019   test -z "$as_dir" && as_dir=.
5020     for ac_exec_ext in '' $ac_executable_extensions; do
5021   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5022     ac_cv_path_MANDOC="$as_dir/$ac_word$ac_exec_ext"
5023     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5024     break 2
5025   fi
5026 done
5027   done
5028 IFS=$as_save_IFS
5029
5030   ;;
5031 esac
5032 fi
5033 MANDOC=$ac_cv_path_MANDOC
5034 if test -n "$MANDOC"; then
5035   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MANDOC" >&5
5036 $as_echo "$MANDOC" >&6; }
5037 else
5038   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5039 $as_echo "no" >&6; }
5040 fi
5041
5042
5043 TEST_SHELL=sh
5044
5045
5046 if test "x$MANDOC" != "x" ; then
5047         MANFMT="$MANDOC"
5048 elif test "x$NROFF" != "x" ; then
5049         MANFMT="$NROFF -mandoc"
5050 elif test "x$GROFF" != "x" ; then
5051         MANFMT="$GROFF -mandoc -Tascii"
5052 else
5053         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: no manpage formatted found" >&5
5054 $as_echo "$as_me: WARNING: no manpage formatted found" >&2;}
5055         MANFMT="false"
5056 fi
5057
5058
5059 # Extract the first word of "groupadd", so it can be a program name with args.
5060 set dummy groupadd; ac_word=$2
5061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5062 $as_echo_n "checking for $ac_word... " >&6; }
5063 if test "${ac_cv_path_PATH_GROUPADD_PROG+set}" = set; then :
5064   $as_echo_n "(cached) " >&6
5065 else
5066   case $PATH_GROUPADD_PROG in
5067   [\\/]* | ?:[\\/]*)
5068   ac_cv_path_PATH_GROUPADD_PROG="$PATH_GROUPADD_PROG" # Let the user override the test with a path.
5069   ;;
5070   *)
5071   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5072 for as_dir in /usr/sbin${PATH_SEPARATOR}/etc
5073 do
5074   IFS=$as_save_IFS
5075   test -z "$as_dir" && as_dir=.
5076     for ac_exec_ext in '' $ac_executable_extensions; do
5077   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5078     ac_cv_path_PATH_GROUPADD_PROG="$as_dir/$ac_word$ac_exec_ext"
5079     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5080     break 2
5081   fi
5082 done
5083   done
5084 IFS=$as_save_IFS
5085
5086   test -z "$ac_cv_path_PATH_GROUPADD_PROG" && ac_cv_path_PATH_GROUPADD_PROG="groupadd"
5087   ;;
5088 esac
5089 fi
5090 PATH_GROUPADD_PROG=$ac_cv_path_PATH_GROUPADD_PROG
5091 if test -n "$PATH_GROUPADD_PROG"; then
5092   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_GROUPADD_PROG" >&5
5093 $as_echo "$PATH_GROUPADD_PROG" >&6; }
5094 else
5095   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5096 $as_echo "no" >&6; }
5097 fi
5098
5099
5100 # Extract the first word of "useradd", so it can be a program name with args.
5101 set dummy useradd; ac_word=$2
5102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5103 $as_echo_n "checking for $ac_word... " >&6; }
5104 if test "${ac_cv_path_PATH_USERADD_PROG+set}" = set; then :
5105   $as_echo_n "(cached) " >&6
5106 else
5107   case $PATH_USERADD_PROG in
5108   [\\/]* | ?:[\\/]*)
5109   ac_cv_path_PATH_USERADD_PROG="$PATH_USERADD_PROG" # Let the user override the test with a path.
5110   ;;
5111   *)
5112   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5113 for as_dir in /usr/sbin${PATH_SEPARATOR}/etc
5114 do
5115   IFS=$as_save_IFS
5116   test -z "$as_dir" && as_dir=.
5117     for ac_exec_ext in '' $ac_executable_extensions; do
5118   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5119     ac_cv_path_PATH_USERADD_PROG="$as_dir/$ac_word$ac_exec_ext"
5120     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5121     break 2
5122   fi
5123 done
5124   done
5125 IFS=$as_save_IFS
5126
5127   test -z "$ac_cv_path_PATH_USERADD_PROG" && ac_cv_path_PATH_USERADD_PROG="useradd"
5128   ;;
5129 esac
5130 fi
5131 PATH_USERADD_PROG=$ac_cv_path_PATH_USERADD_PROG
5132 if test -n "$PATH_USERADD_PROG"; then
5133   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_USERADD_PROG" >&5
5134 $as_echo "$PATH_USERADD_PROG" >&6; }
5135 else
5136   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5137 $as_echo "no" >&6; }
5138 fi
5139
5140
5141 # Extract the first word of "pkgmk", so it can be a program name with args.
5142 set dummy pkgmk; ac_word=$2
5143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5144 $as_echo_n "checking for $ac_word... " >&6; }
5145 if test "${ac_cv_prog_MAKE_PACKAGE_SUPPORTED+set}" = set; then :
5146   $as_echo_n "(cached) " >&6
5147 else
5148   if test -n "$MAKE_PACKAGE_SUPPORTED"; then
5149   ac_cv_prog_MAKE_PACKAGE_SUPPORTED="$MAKE_PACKAGE_SUPPORTED" # Let the user override the test.
5150 else
5151 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5152 for as_dir in $PATH
5153 do
5154   IFS=$as_save_IFS
5155   test -z "$as_dir" && as_dir=.
5156     for ac_exec_ext in '' $ac_executable_extensions; do
5157   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5158     ac_cv_prog_MAKE_PACKAGE_SUPPORTED="yes"
5159     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5160     break 2
5161   fi
5162 done
5163   done
5164 IFS=$as_save_IFS
5165
5166   test -z "$ac_cv_prog_MAKE_PACKAGE_SUPPORTED" && ac_cv_prog_MAKE_PACKAGE_SUPPORTED="no"
5167 fi
5168 fi
5169 MAKE_PACKAGE_SUPPORTED=$ac_cv_prog_MAKE_PACKAGE_SUPPORTED
5170 if test -n "$MAKE_PACKAGE_SUPPORTED"; then
5171   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE_PACKAGE_SUPPORTED" >&5
5172 $as_echo "$MAKE_PACKAGE_SUPPORTED" >&6; }
5173 else
5174   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5175 $as_echo "no" >&6; }
5176 fi
5177
5178
5179 if test -x /sbin/sh; then
5180         STARTUP_SCRIPT_SHELL=/sbin/sh
5181
5182 else
5183         STARTUP_SCRIPT_SHELL=/bin/sh
5184
5185 fi
5186
5187 # System features
5188 # Check whether --enable-largefile was given.
5189 if test "${enable_largefile+set}" = set; then :
5190   enableval=$enable_largefile;
5191 fi
5192
5193 if test "$enable_largefile" != no; then
5194
5195   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5
5196 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
5197 if test "${ac_cv_sys_largefile_CC+set}" = set; then :
5198   $as_echo_n "(cached) " >&6
5199 else
5200   ac_cv_sys_largefile_CC=no
5201      if test "$GCC" != yes; then
5202        ac_save_CC=$CC
5203        while :; do
5204          # IRIX 6.2 and later do not support large files by default,
5205          # so use the C compiler's -n32 option if that helps.
5206          cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5207 /* end confdefs.h.  */
5208 #include <sys/types.h>
5209  /* Check that off_t can represent 2**63 - 1 correctly.
5210     We can't simply define LARGE_OFF_T to be 9223372036854775807,
5211     since some C++ compilers masquerading as C compilers
5212     incorrectly reject 9223372036854775807.  */
5213 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5214   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5215                        && LARGE_OFF_T % 2147483647 == 1)
5216                       ? 1 : -1];
5217 int
5218 main ()
5219 {
5220
5221   ;
5222   return 0;
5223 }
5224 _ACEOF
5225          if ac_fn_c_try_compile "$LINENO"; then :
5226   break
5227 fi
5228 rm -f core conftest.err conftest.$ac_objext
5229          CC="$CC -n32"
5230          if ac_fn_c_try_compile "$LINENO"; then :
5231   ac_cv_sys_largefile_CC=' -n32'; break
5232 fi
5233 rm -f core conftest.err conftest.$ac_objext
5234          break
5235        done
5236        CC=$ac_save_CC
5237        rm -f conftest.$ac_ext
5238     fi
5239 fi
5240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_largefile_CC" >&5
5241 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
5242   if test "$ac_cv_sys_largefile_CC" != no; then
5243     CC=$CC$ac_cv_sys_largefile_CC
5244   fi
5245
5246   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5
5247 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
5248 if test "${ac_cv_sys_file_offset_bits+set}" = set; then :
5249   $as_echo_n "(cached) " >&6
5250 else
5251   while :; do
5252   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5253 /* end confdefs.h.  */
5254 #include <sys/types.h>
5255  /* Check that off_t can represent 2**63 - 1 correctly.
5256     We can't simply define LARGE_OFF_T to be 9223372036854775807,
5257     since some C++ compilers masquerading as C compilers
5258     incorrectly reject 9223372036854775807.  */
5259 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5260   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5261                        && LARGE_OFF_T % 2147483647 == 1)
5262                       ? 1 : -1];
5263 int
5264 main ()
5265 {
5266
5267   ;
5268   return 0;
5269 }
5270 _ACEOF
5271 if ac_fn_c_try_compile "$LINENO"; then :
5272   ac_cv_sys_file_offset_bits=no; break
5273 fi
5274 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5275   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5276 /* end confdefs.h.  */
5277 #define _FILE_OFFSET_BITS 64
5278 #include <sys/types.h>
5279  /* Check that off_t can represent 2**63 - 1 correctly.
5280     We can't simply define LARGE_OFF_T to be 9223372036854775807,
5281     since some C++ compilers masquerading as C compilers
5282     incorrectly reject 9223372036854775807.  */
5283 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5284   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5285                        && LARGE_OFF_T % 2147483647 == 1)
5286                       ? 1 : -1];
5287 int
5288 main ()
5289 {
5290
5291   ;
5292   return 0;
5293 }
5294 _ACEOF
5295 if ac_fn_c_try_compile "$LINENO"; then :
5296   ac_cv_sys_file_offset_bits=64; break
5297 fi
5298 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5299   ac_cv_sys_file_offset_bits=unknown
5300   break
5301 done
5302 fi
5303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_file_offset_bits" >&5
5304 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
5305 case $ac_cv_sys_file_offset_bits in #(
5306   no | unknown) ;;
5307   *)
5308 cat >>confdefs.h <<_ACEOF
5309 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
5310 _ACEOF
5311 ;;
5312 esac
5313 rm -rf conftest*
5314   if test $ac_cv_sys_file_offset_bits = unknown; then
5315     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5
5316 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
5317 if test "${ac_cv_sys_large_files+set}" = set; then :
5318   $as_echo_n "(cached) " >&6
5319 else
5320   while :; do
5321   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5322 /* end confdefs.h.  */
5323 #include <sys/types.h>
5324  /* Check that off_t can represent 2**63 - 1 correctly.
5325     We can't simply define LARGE_OFF_T to be 9223372036854775807,
5326     since some C++ compilers masquerading as C compilers
5327     incorrectly reject 9223372036854775807.  */
5328 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5329   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5330                        && LARGE_OFF_T % 2147483647 == 1)
5331                       ? 1 : -1];
5332 int
5333 main ()
5334 {
5335
5336   ;
5337   return 0;
5338 }
5339 _ACEOF
5340 if ac_fn_c_try_compile "$LINENO"; then :
5341   ac_cv_sys_large_files=no; break
5342 fi
5343 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5344   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5345 /* end confdefs.h.  */
5346 #define _LARGE_FILES 1
5347 #include <sys/types.h>
5348  /* Check that off_t can represent 2**63 - 1 correctly.
5349     We can't simply define LARGE_OFF_T to be 9223372036854775807,
5350     since some C++ compilers masquerading as C compilers
5351     incorrectly reject 9223372036854775807.  */
5352 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5353   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5354                        && LARGE_OFF_T % 2147483647 == 1)
5355                       ? 1 : -1];
5356 int
5357 main ()
5358 {
5359
5360   ;
5361   return 0;
5362 }
5363 _ACEOF
5364 if ac_fn_c_try_compile "$LINENO"; then :
5365   ac_cv_sys_large_files=1; break
5366 fi
5367 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5368   ac_cv_sys_large_files=unknown
5369   break
5370 done
5371 fi
5372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sys_large_files" >&5
5373 $as_echo "$ac_cv_sys_large_files" >&6; }
5374 case $ac_cv_sys_large_files in #(
5375   no | unknown) ;;
5376   *)
5377 cat >>confdefs.h <<_ACEOF
5378 #define _LARGE_FILES $ac_cv_sys_large_files
5379 _ACEOF
5380 ;;
5381 esac
5382 rm -rf conftest*
5383   fi
5384 fi
5385
5386
5387 if test -z "$AR" ; then
5388         as_fn_error $? "*** 'ar' missing, please install or fix your \$PATH ***" "$LINENO" 5
5389 fi
5390
5391 # Use LOGIN_PROGRAM from environment if possible
5392 if test ! -z "$LOGIN_PROGRAM" ; then
5393
5394 cat >>confdefs.h <<_ACEOF
5395 #define LOGIN_PROGRAM_FALLBACK "$LOGIN_PROGRAM"
5396 _ACEOF
5397
5398 else
5399         # Search for login
5400         # Extract the first word of "login", so it can be a program name with args.
5401 set dummy login; ac_word=$2
5402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5403 $as_echo_n "checking for $ac_word... " >&6; }
5404 if test "${ac_cv_path_LOGIN_PROGRAM_FALLBACK+set}" = set; then :
5405   $as_echo_n "(cached) " >&6
5406 else
5407   case $LOGIN_PROGRAM_FALLBACK in
5408   [\\/]* | ?:[\\/]*)
5409   ac_cv_path_LOGIN_PROGRAM_FALLBACK="$LOGIN_PROGRAM_FALLBACK" # Let the user override the test with a path.
5410   ;;
5411   *)
5412   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5413 for as_dir in $PATH
5414 do
5415   IFS=$as_save_IFS
5416   test -z "$as_dir" && as_dir=.
5417     for ac_exec_ext in '' $ac_executable_extensions; do
5418   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5419     ac_cv_path_LOGIN_PROGRAM_FALLBACK="$as_dir/$ac_word$ac_exec_ext"
5420     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5421     break 2
5422   fi
5423 done
5424   done
5425 IFS=$as_save_IFS
5426
5427   ;;
5428 esac
5429 fi
5430 LOGIN_PROGRAM_FALLBACK=$ac_cv_path_LOGIN_PROGRAM_FALLBACK
5431 if test -n "$LOGIN_PROGRAM_FALLBACK"; then
5432   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LOGIN_PROGRAM_FALLBACK" >&5
5433 $as_echo "$LOGIN_PROGRAM_FALLBACK" >&6; }
5434 else
5435   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5436 $as_echo "no" >&6; }
5437 fi
5438
5439
5440         if test ! -z "$LOGIN_PROGRAM_FALLBACK" ; then
5441                 cat >>confdefs.h <<_ACEOF
5442 #define LOGIN_PROGRAM_FALLBACK "$LOGIN_PROGRAM_FALLBACK"
5443 _ACEOF
5444
5445         fi
5446 fi
5447
5448 # Extract the first word of "passwd", so it can be a program name with args.
5449 set dummy passwd; ac_word=$2
5450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
5451 $as_echo_n "checking for $ac_word... " >&6; }
5452 if test "${ac_cv_path_PATH_PASSWD_PROG+set}" = set; then :
5453   $as_echo_n "(cached) " >&6
5454 else
5455   case $PATH_PASSWD_PROG in
5456   [\\/]* | ?:[\\/]*)
5457   ac_cv_path_PATH_PASSWD_PROG="$PATH_PASSWD_PROG" # Let the user override the test with a path.
5458   ;;
5459   *)
5460   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5461 for as_dir in $PATH
5462 do
5463   IFS=$as_save_IFS
5464   test -z "$as_dir" && as_dir=.
5465     for ac_exec_ext in '' $ac_executable_extensions; do
5466   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5467     ac_cv_path_PATH_PASSWD_PROG="$as_dir/$ac_word$ac_exec_ext"
5468     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
5469     break 2
5470   fi
5471 done
5472   done
5473 IFS=$as_save_IFS
5474
5475   ;;
5476 esac
5477 fi
5478 PATH_PASSWD_PROG=$ac_cv_path_PATH_PASSWD_PROG
5479 if test -n "$PATH_PASSWD_PROG"; then
5480   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATH_PASSWD_PROG" >&5
5481 $as_echo "$PATH_PASSWD_PROG" >&6; }
5482 else
5483   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5484 $as_echo "no" >&6; }
5485 fi
5486
5487
5488 if test ! -z "$PATH_PASSWD_PROG" ; then
5489
5490 cat >>confdefs.h <<_ACEOF
5491 #define _PATH_PASSWD_PROG "$PATH_PASSWD_PROG"
5492 _ACEOF
5493
5494 fi
5495
5496 if test -z "$LD" ; then
5497         LD=$CC
5498 fi
5499
5500
5501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for inline" >&5
5502 $as_echo_n "checking for inline... " >&6; }
5503 if test "${ac_cv_c_inline+set}" = set; then :
5504   $as_echo_n "(cached) " >&6
5505 else
5506   ac_cv_c_inline=no
5507 for ac_kw in inline __inline__ __inline; do
5508   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5509 /* end confdefs.h.  */
5510 #ifndef __cplusplus
5511 typedef int foo_t;
5512 static $ac_kw foo_t static_foo () {return 0; }
5513 $ac_kw foo_t foo () {return 0; }
5514 #endif
5515
5516 _ACEOF
5517 if ac_fn_c_try_compile "$LINENO"; then :
5518   ac_cv_c_inline=$ac_kw
5519 fi
5520 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5521   test "$ac_cv_c_inline" != no && break
5522 done
5523
5524 fi
5525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_inline" >&5
5526 $as_echo "$ac_cv_c_inline" >&6; }
5527
5528 case $ac_cv_c_inline in
5529   inline | yes) ;;
5530   *)
5531     case $ac_cv_c_inline in
5532       no) ac_val=;;
5533       *) ac_val=$ac_cv_c_inline;;
5534     esac
5535     cat >>confdefs.h <<_ACEOF
5536 #ifndef __cplusplus
5537 #define inline $ac_val
5538 #endif
5539 _ACEOF
5540     ;;
5541 esac
5542
5543
5544 ac_fn_c_check_decl "$LINENO" "LLONG_MAX" "ac_cv_have_decl_LLONG_MAX" "#include <limits.h>
5545 "
5546 if test "x$ac_cv_have_decl_LLONG_MAX" = x""yes; then :
5547   have_llong_max=1
5548 fi
5549
5550 ac_fn_c_check_decl "$LINENO" "SYSTR_POLICY_KILL" "ac_cv_have_decl_SYSTR_POLICY_KILL" "
5551         #include <sys/types.h>
5552         #include <sys/param.h>
5553         #include <dev/systrace.h>
5554
5555 "
5556 if test "x$ac_cv_have_decl_SYSTR_POLICY_KILL" = x""yes; then :
5557   have_systr_policy_kill=1
5558 fi
5559
5560 ac_fn_c_check_decl "$LINENO" "RLIMIT_NPROC" "ac_cv_have_decl_RLIMIT_NPROC" "
5561         #include <sys/types.h>
5562         #include <sys/resource.h>
5563
5564 "
5565 if test "x$ac_cv_have_decl_RLIMIT_NPROC" = x""yes; then :
5566
5567 $as_echo "#define HAVE_RLIMIT_NPROC /**/" >>confdefs.h
5568
5569 fi
5570
5571
5572 use_stack_protector=1
5573
5574 # Check whether --with-stackprotect was given.
5575 if test "${with_stackprotect+set}" = set; then :
5576   withval=$with_stackprotect;
5577     if test "x$withval" = "xno"; then
5578         use_stack_protector=0
5579     fi
5580 fi
5581
5582
5583
5584 if test "$GCC" = "yes" || test "$GCC" = "egcs"; then
5585         {
5586         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -Wall" >&5
5587 $as_echo_n "checking if $CC supports -Wall... " >&6; }
5588         saved_CFLAGS="$CFLAGS"
5589         CFLAGS="$CFLAGS -Wall"
5590         _define_flag=""
5591         test "x$_define_flag" = "x" && _define_flag="-Wall"
5592         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5593 /* end confdefs.h.  */
5594 int main(void) { return 0; }
5595 _ACEOF
5596 if ac_fn_c_try_compile "$LINENO"; then :
5597    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5598 $as_echo "yes" >&6; }
5599                   CFLAGS="$saved_CFLAGS $_define_flag"
5600 else
5601    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5602 $as_echo "no" >&6; }
5603                   CFLAGS="$saved_CFLAGS"
5604
5605 fi
5606 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5607 }
5608         {
5609         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -Wpointer-arith" >&5
5610 $as_echo_n "checking if $CC supports -Wpointer-arith... " >&6; }
5611         saved_CFLAGS="$CFLAGS"
5612         CFLAGS="$CFLAGS -Wpointer-arith"
5613         _define_flag=""
5614         test "x$_define_flag" = "x" && _define_flag="-Wpointer-arith"
5615         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5616 /* end confdefs.h.  */
5617 int main(void) { return 0; }
5618 _ACEOF
5619 if ac_fn_c_try_compile "$LINENO"; then :
5620    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5621 $as_echo "yes" >&6; }
5622                   CFLAGS="$saved_CFLAGS $_define_flag"
5623 else
5624    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5625 $as_echo "no" >&6; }
5626                   CFLAGS="$saved_CFLAGS"
5627
5628 fi
5629 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5630 }
5631         {
5632         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -Wuninitialized" >&5
5633 $as_echo_n "checking if $CC supports -Wuninitialized... " >&6; }
5634         saved_CFLAGS="$CFLAGS"
5635         CFLAGS="$CFLAGS -Wuninitialized"
5636         _define_flag=""
5637         test "x$_define_flag" = "x" && _define_flag="-Wuninitialized"
5638         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5639 /* end confdefs.h.  */
5640 int main(void) { return 0; }
5641 _ACEOF
5642 if ac_fn_c_try_compile "$LINENO"; then :
5643    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5644 $as_echo "yes" >&6; }
5645                   CFLAGS="$saved_CFLAGS $_define_flag"
5646 else
5647    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5648 $as_echo "no" >&6; }
5649                   CFLAGS="$saved_CFLAGS"
5650
5651 fi
5652 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5653 }
5654         {
5655         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -Wsign-compare" >&5
5656 $as_echo_n "checking if $CC supports -Wsign-compare... " >&6; }
5657         saved_CFLAGS="$CFLAGS"
5658         CFLAGS="$CFLAGS -Wsign-compare"
5659         _define_flag=""
5660         test "x$_define_flag" = "x" && _define_flag="-Wsign-compare"
5661         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5662 /* end confdefs.h.  */
5663 int main(void) { return 0; }
5664 _ACEOF
5665 if ac_fn_c_try_compile "$LINENO"; then :
5666    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5667 $as_echo "yes" >&6; }
5668                   CFLAGS="$saved_CFLAGS $_define_flag"
5669 else
5670    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5671 $as_echo "no" >&6; }
5672                   CFLAGS="$saved_CFLAGS"
5673
5674 fi
5675 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5676 }
5677         {
5678         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -Wformat-security" >&5
5679 $as_echo_n "checking if $CC supports -Wformat-security... " >&6; }
5680         saved_CFLAGS="$CFLAGS"
5681         CFLAGS="$CFLAGS -Wformat-security"
5682         _define_flag=""
5683         test "x$_define_flag" = "x" && _define_flag="-Wformat-security"
5684         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5685 /* end confdefs.h.  */
5686 int main(void) { return 0; }
5687 _ACEOF
5688 if ac_fn_c_try_compile "$LINENO"; then :
5689    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5690 $as_echo "yes" >&6; }
5691                   CFLAGS="$saved_CFLAGS $_define_flag"
5692 else
5693    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5694 $as_echo "no" >&6; }
5695                   CFLAGS="$saved_CFLAGS"
5696
5697 fi
5698 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5699 }
5700         {
5701         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -Wpointer-sign" >&5
5702 $as_echo_n "checking if $CC supports -Wpointer-sign... " >&6; }
5703         saved_CFLAGS="$CFLAGS"
5704         CFLAGS="$CFLAGS -Wpointer-sign"
5705         _define_flag="-Wno-pointer-sign"
5706         test "x$_define_flag" = "x" && _define_flag="-Wpointer-sign"
5707         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5708 /* end confdefs.h.  */
5709 int main(void) { return 0; }
5710 _ACEOF
5711 if ac_fn_c_try_compile "$LINENO"; then :
5712    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5713 $as_echo "yes" >&6; }
5714                   CFLAGS="$saved_CFLAGS $_define_flag"
5715 else
5716    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5717 $as_echo "no" >&6; }
5718                   CFLAGS="$saved_CFLAGS"
5719
5720 fi
5721 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5722 }
5723         {
5724         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -Wunused-result" >&5
5725 $as_echo_n "checking if $CC supports -Wunused-result... " >&6; }
5726         saved_CFLAGS="$CFLAGS"
5727         CFLAGS="$CFLAGS -Wunused-result"
5728         _define_flag="-Wno-unused-result"
5729         test "x$_define_flag" = "x" && _define_flag="-Wunused-result"
5730         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5731 /* end confdefs.h.  */
5732 int main(void) { return 0; }
5733 _ACEOF
5734 if ac_fn_c_try_compile "$LINENO"; then :
5735    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5736 $as_echo "yes" >&6; }
5737                   CFLAGS="$saved_CFLAGS $_define_flag"
5738 else
5739    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5740 $as_echo "no" >&6; }
5741                   CFLAGS="$saved_CFLAGS"
5742
5743 fi
5744 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5745 }
5746         {
5747         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports -fno-strict-aliasing" >&5
5748 $as_echo_n "checking if $CC supports -fno-strict-aliasing... " >&6; }
5749         saved_CFLAGS="$CFLAGS"
5750         CFLAGS="$CFLAGS -fno-strict-aliasing"
5751         _define_flag=""
5752         test "x$_define_flag" = "x" && _define_flag="-fno-strict-aliasing"
5753         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5754 /* end confdefs.h.  */
5755 int main(void) { return 0; }
5756 _ACEOF
5757 if ac_fn_c_try_compile "$LINENO"; then :
5758    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5759 $as_echo "yes" >&6; }
5760                   CFLAGS="$saved_CFLAGS $_define_flag"
5761 else
5762    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5763 $as_echo "no" >&6; }
5764                   CFLAGS="$saved_CFLAGS"
5765
5766 fi
5767 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5768 }
5769         { $as_echo "$as_me:${as_lineno-$LINENO}: checking gcc version" >&5
5770 $as_echo_n "checking gcc version... " >&6; }
5771         GCC_VER=`$CC -v 2>&1 | $AWK '/gcc version /{print $3}'`
5772         case $GCC_VER in
5773                 1.*) no_attrib_nonnull=1 ;;
5774                 2.8* | 2.9*)
5775                      no_attrib_nonnull=1
5776                      ;;
5777                 2.*) no_attrib_nonnull=1 ;;
5778                 *) ;;
5779         esac
5780         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GCC_VER" >&5
5781 $as_echo "$GCC_VER" >&6; }
5782
5783         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC accepts -fno-builtin-memset" >&5
5784 $as_echo_n "checking if $CC accepts -fno-builtin-memset... " >&6; }
5785         saved_CFLAGS="$CFLAGS"
5786         CFLAGS="$CFLAGS -fno-builtin-memset"
5787         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5788 /* end confdefs.h.  */
5789  #include <string.h>
5790 int
5791 main ()
5792 {
5793  char b[10]; memset(b, 0, sizeof(b));
5794   ;
5795   return 0;
5796 }
5797 _ACEOF
5798 if ac_fn_c_try_link "$LINENO"; then :
5799    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5800 $as_echo "yes" >&6; }
5801 else
5802    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5803 $as_echo "no" >&6; }
5804                   CFLAGS="$saved_CFLAGS"
5805
5806 fi
5807 rm -f core conftest.err conftest.$ac_objext \
5808     conftest$ac_exeext conftest.$ac_ext
5809
5810         # -fstack-protector-all doesn't always work for some GCC versions
5811         # and/or platforms, so we test if we can.  If it's not supported
5812         # on a given platform gcc will emit a warning so we use -Werror.
5813         if test "x$use_stack_protector" = "x1"; then
5814             for t in -fstack-protector-all -fstack-protector; do
5815                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $CC supports $t" >&5
5816 $as_echo_n "checking if $CC supports $t... " >&6; }
5817                 saved_CFLAGS="$CFLAGS"
5818                 saved_LDFLAGS="$LDFLAGS"
5819                 CFLAGS="$CFLAGS $t -Werror"
5820                 LDFLAGS="$LDFLAGS $t -Werror"
5821                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5822 /* end confdefs.h.  */
5823  #include <stdio.h>
5824 int
5825 main ()
5826 {
5827
5828         char x[256];
5829         snprintf(x, sizeof(x), "XXX");
5830
5831   ;
5832   return 0;
5833 }
5834 _ACEOF
5835 if ac_fn_c_try_link "$LINENO"; then :
5836    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5837 $as_echo "yes" >&6; }
5838                       CFLAGS="$saved_CFLAGS $t"
5839                       LDFLAGS="$saved_LDFLAGS $t"
5840                       { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $t works" >&5
5841 $as_echo_n "checking if $t works... " >&6; }
5842                       if test "$cross_compiling" = yes; then :
5843    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: cannot test" >&5
5844 $as_echo "$as_me: WARNING: cross compiling: cannot test" >&2;}
5845                           break
5846
5847 else
5848   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
5849 /* end confdefs.h.  */
5850  #include <stdio.h>
5851 int
5852 main ()
5853 {
5854
5855         char x[256];
5856         snprintf(x, sizeof(x), "XXX");
5857
5858   ;
5859   return 0;
5860 }
5861 _ACEOF
5862 if ac_fn_c_try_run "$LINENO"; then :
5863    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
5864 $as_echo "yes" >&6; }
5865                           break
5866 else
5867    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5868 $as_echo "no" >&6; }
5869 fi
5870 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
5871   conftest.$ac_objext conftest.beam conftest.$ac_ext
5872 fi
5873
5874
5875 else
5876    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
5877 $as_echo "no" >&6; }
5878
5879 fi
5880 rm -f core conftest.err conftest.$ac_objext \
5881     conftest$ac_exeext conftest.$ac_ext
5882                 CFLAGS="$saved_CFLAGS"
5883                 LDFLAGS="$saved_LDFLAGS"
5884             done
5885         fi
5886
5887         if test -z "$have_llong_max"; then
5888                 # retry LLONG_MAX with -std=gnu99, needed on some Linuxes
5889                 unset ac_cv_have_decl_LLONG_MAX
5890                 saved_CFLAGS="$CFLAGS"
5891                 CFLAGS="$CFLAGS -std=gnu99"
5892                 ac_fn_c_check_decl "$LINENO" "LLONG_MAX" "ac_cv_have_decl_LLONG_MAX" "#include <limits.h>
5893
5894 "
5895 if test "x$ac_cv_have_decl_LLONG_MAX" = x""yes; then :
5896   have_llong_max=1
5897 else
5898   CFLAGS="$saved_CFLAGS"
5899 fi
5900
5901         fi
5902 fi
5903
5904 if test "x$no_attrib_nonnull" != "x1" ; then
5905
5906 $as_echo "#define HAVE_ATTRIBUTE__NONNULL__ 1" >>confdefs.h
5907
5908 fi
5909
5910
5911 # Check whether --with-rpath was given.
5912 if test "${with_rpath+set}" = set; then :
5913   withval=$with_rpath;
5914                 if test "x$withval" = "xno" ; then
5915                         need_dash_r=""
5916                 fi
5917                 if test "x$withval" = "xyes" ; then
5918                         need_dash_r=1
5919                 fi
5920
5921
5922 fi
5923
5924
5925 # Allow user to specify flags
5926
5927 # Check whether --with-cflags was given.
5928 if test "${with_cflags+set}" = set; then :
5929   withval=$with_cflags;
5930                 if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
5931                     test "x${withval}" != "xyes"; then
5932                         CFLAGS="$CFLAGS $withval"
5933                 fi
5934
5935
5936 fi
5937
5938
5939 # Check whether --with-cppflags was given.
5940 if test "${with_cppflags+set}" = set; then :
5941   withval=$with_cppflags;
5942                 if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
5943                     test "x${withval}" != "xyes"; then
5944                         CPPFLAGS="$CPPFLAGS $withval"
5945                 fi
5946
5947
5948 fi
5949
5950
5951 # Check whether --with-ldflags was given.
5952 if test "${with_ldflags+set}" = set; then :
5953   withval=$with_ldflags;
5954                 if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
5955                     test "x${withval}" != "xyes"; then
5956                         LDFLAGS="$LDFLAGS $withval"
5957                 fi
5958
5959
5960 fi
5961
5962
5963 # Check whether --with-libs was given.
5964 if test "${with_libs+set}" = set; then :
5965   withval=$with_libs;
5966                 if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
5967                     test "x${withval}" != "xyes"; then
5968                         LIBS="$LIBS $withval"
5969                 fi
5970
5971
5972 fi
5973
5974
5975 # Check whether --with-Werror was given.
5976 if test "${with_Werror+set}" = set; then :
5977   withval=$with_Werror;
5978                 if test -n "$withval"  &&  test "x$withval" != "xno"; then
5979                         werror_flags="-Werror"
5980                         if test "x${withval}" != "xyes"; then
5981                                 werror_flags="$withval"
5982                         fi
5983                 fi
5984
5985
5986 fi
5987
5988
5989 for ac_header in  \
5990         bstring.h \
5991         crypt.h \
5992         crypto/sha2.h \
5993         dirent.h \
5994         endian.h \
5995         features.h \
5996         fcntl.h \
5997         floatingpoint.h \
5998         getopt.h \
5999         glob.h \
6000         ia.h \
6001         iaf.h \
6002         limits.h \
6003         login.h \
6004         maillock.h \
6005         ndir.h \
6006         net/if_tun.h \
6007         netdb.h \
6008         netgroup.h \
6009         pam/pam_appl.h \
6010         paths.h \
6011         poll.h \
6012         pty.h \
6013         readpassphrase.h \
6014         rpc/types.h \
6015         security/pam_appl.h \
6016         sha2.h \
6017         shadow.h \
6018         stddef.h \
6019         stdint.h \
6020         string.h \
6021         strings.h \
6022         sys/audit.h \
6023         sys/bitypes.h \
6024         sys/bsdtty.h \
6025         sys/cdefs.h \
6026         sys/dir.h \
6027         sys/mman.h \
6028         sys/ndir.h \
6029         sys/poll.h \
6030         sys/prctl.h \
6031         sys/pstat.h \
6032         sys/select.h \
6033         sys/stat.h \
6034         sys/stream.h \
6035         sys/stropts.h \
6036         sys/strtio.h \
6037         sys/statvfs.h \
6038         sys/sysmacros.h \
6039         sys/time.h \
6040         sys/timers.h \
6041         sys/un.h \
6042         time.h \
6043         tmpdir.h \
6044         ttyent.h \
6045         ucred.h \
6046         unistd.h \
6047         usersec.h \
6048         util.h \
6049         utime.h \
6050         utmp.h \
6051         utmpx.h \
6052         vis.h \
6053
6054 do :
6055   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
6056 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
6057 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
6058   cat >>confdefs.h <<_ACEOF
6059 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
6060 _ACEOF
6061
6062 fi
6063
6064 done
6065
6066
6067 # lastlog.h requires sys/time.h to be included first on Solaris
6068 for ac_header in lastlog.h
6069 do :
6070   ac_fn_c_check_header_compile "$LINENO" "lastlog.h" "ac_cv_header_lastlog_h" "
6071 #ifdef HAVE_SYS_TIME_H
6072 # include <sys/time.h>
6073 #endif
6074
6075 "
6076 if test "x$ac_cv_header_lastlog_h" = x""yes; then :
6077   cat >>confdefs.h <<_ACEOF
6078 #define HAVE_LASTLOG_H 1
6079 _ACEOF
6080
6081 fi
6082
6083 done
6084
6085
6086 # sys/ptms.h requires sys/stream.h to be included first on Solaris
6087 for ac_header in sys/ptms.h
6088 do :
6089   ac_fn_c_check_header_compile "$LINENO" "sys/ptms.h" "ac_cv_header_sys_ptms_h" "
6090 #ifdef HAVE_SYS_STREAM_H
6091 # include <sys/stream.h>
6092 #endif
6093
6094 "
6095 if test "x$ac_cv_header_sys_ptms_h" = x""yes; then :
6096   cat >>confdefs.h <<_ACEOF
6097 #define HAVE_SYS_PTMS_H 1
6098 _ACEOF
6099
6100 fi
6101
6102 done
6103
6104
6105 # login_cap.h requires sys/types.h on NetBSD
6106 for ac_header in login_cap.h
6107 do :
6108   ac_fn_c_check_header_compile "$LINENO" "login_cap.h" "ac_cv_header_login_cap_h" "
6109 #include <sys/types.h>
6110
6111 "
6112 if test "x$ac_cv_header_login_cap_h" = x""yes; then :
6113   cat >>confdefs.h <<_ACEOF
6114 #define HAVE_LOGIN_CAP_H 1
6115 _ACEOF
6116
6117 fi
6118
6119 done
6120
6121
6122 # older BSDs need sys/param.h before sys/mount.h
6123 for ac_header in sys/mount.h
6124 do :
6125   ac_fn_c_check_header_compile "$LINENO" "sys/mount.h" "ac_cv_header_sys_mount_h" "
6126 #include <sys/param.h>
6127
6128 "
6129 if test "x$ac_cv_header_sys_mount_h" = x""yes; then :
6130   cat >>confdefs.h <<_ACEOF
6131 #define HAVE_SYS_MOUNT_H 1
6132 _ACEOF
6133
6134 fi
6135
6136 done
6137
6138
6139 # Messages for features tested for in target-specific section
6140 SIA_MSG="no"
6141 SPC_MSG="no"
6142 SP_MSG="no"
6143
6144 # Check for some target-specific stuff
6145 case "$host" in
6146 *-*-aix*)
6147         # Some versions of VAC won't allow macro redefinitions at
6148         # -qlanglevel=ansi, and autoconf 2.60 sometimes insists on using that
6149         # particularly with older versions of vac or xlc.
6150         # It also throws errors about null macro argments, but these are
6151         # not fatal.
6152         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler allows macro redefinitions" >&5
6153 $as_echo_n "checking if compiler allows macro redefinitions... " >&6; }
6154         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6155 /* end confdefs.h.  */
6156
6157 #define testmacro foo
6158 #define testmacro bar
6159 int
6160 main ()
6161 {
6162  exit(0);
6163   ;
6164   return 0;
6165 }
6166 _ACEOF
6167 if ac_fn_c_try_compile "$LINENO"; then :
6168    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6169 $as_echo "yes" >&6; }
6170 else
6171    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6172 $as_echo "no" >&6; }
6173               CC="`echo $CC | sed 's/-qlanglvl\=ansi//g'`"
6174               LD="`echo $LD | sed 's/-qlanglvl\=ansi//g'`"
6175               CFLAGS="`echo $CFLAGS | sed 's/-qlanglvl\=ansi//g'`"
6176               CPPFLAGS="`echo $CPPFLAGS | sed 's/-qlanglvl\=ansi//g'`"
6177
6178
6179 fi
6180 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6181
6182         { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to specify blibpath for linker ($LD)" >&5
6183 $as_echo_n "checking how to specify blibpath for linker ($LD)... " >&6; }
6184         if (test -z "$blibpath"); then
6185                 blibpath="/usr/lib:/lib"
6186         fi
6187         saved_LDFLAGS="$LDFLAGS"
6188         if test "$GCC" = "yes"; then
6189                 flags="-Wl,-blibpath: -Wl,-rpath, -blibpath:"
6190         else
6191                 flags="-blibpath: -Wl,-blibpath: -Wl,-rpath,"
6192         fi
6193         for tryflags in $flags ;do
6194                 if (test -z "$blibflags"); then
6195                         LDFLAGS="$saved_LDFLAGS $tryflags$blibpath"
6196                         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6197 /* end confdefs.h.  */
6198
6199 int
6200 main ()
6201 {
6202
6203   ;
6204   return 0;
6205 }
6206 _ACEOF
6207 if ac_fn_c_try_link "$LINENO"; then :
6208   blibflags=$tryflags
6209 fi
6210 rm -f core conftest.err conftest.$ac_objext \
6211     conftest$ac_exeext conftest.$ac_ext
6212                 fi
6213         done
6214         if (test -z "$blibflags"); then
6215                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
6216 $as_echo "not found" >&6; }
6217                 as_fn_error $? "*** must be able to specify blibpath on AIX - check config.log" "$LINENO" 5
6218         else
6219                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $blibflags" >&5
6220 $as_echo "$blibflags" >&6; }
6221         fi
6222         LDFLAGS="$saved_LDFLAGS"
6223                 ac_fn_c_check_func "$LINENO" "authenticate" "ac_cv_func_authenticate"
6224 if test "x$ac_cv_func_authenticate" = x""yes; then :
6225
6226 $as_echo "#define WITH_AIXAUTHENTICATE 1" >>confdefs.h
6227
6228 else
6229   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for authenticate in -ls" >&5
6230 $as_echo_n "checking for authenticate in -ls... " >&6; }
6231 if test "${ac_cv_lib_s_authenticate+set}" = set; then :
6232   $as_echo_n "(cached) " >&6
6233 else
6234   ac_check_lib_save_LIBS=$LIBS
6235 LIBS="-ls  $LIBS"
6236 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6237 /* end confdefs.h.  */
6238
6239 /* Override any GCC internal prototype to avoid an error.
6240    Use char because int might match the return type of a GCC
6241    builtin and then its argument prototype would still apply.  */
6242 #ifdef __cplusplus
6243 extern "C"
6244 #endif
6245 char authenticate ();
6246 int
6247 main ()
6248 {
6249 return authenticate ();
6250   ;
6251   return 0;
6252 }
6253 _ACEOF
6254 if ac_fn_c_try_link "$LINENO"; then :
6255   ac_cv_lib_s_authenticate=yes
6256 else
6257   ac_cv_lib_s_authenticate=no
6258 fi
6259 rm -f core conftest.err conftest.$ac_objext \
6260     conftest$ac_exeext conftest.$ac_ext
6261 LIBS=$ac_check_lib_save_LIBS
6262 fi
6263 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_s_authenticate" >&5
6264 $as_echo "$ac_cv_lib_s_authenticate" >&6; }
6265 if test "x$ac_cv_lib_s_authenticate" = x""yes; then :
6266    $as_echo "#define WITH_AIXAUTHENTICATE 1" >>confdefs.h
6267
6268                                 LIBS="$LIBS -ls"
6269
6270 fi
6271
6272
6273 fi
6274
6275                 ac_fn_c_check_decl "$LINENO" "authenticate" "ac_cv_have_decl_authenticate" "#include <usersec.h>
6276 "
6277 if test "x$ac_cv_have_decl_authenticate" = x""yes; then :
6278   ac_have_decl=1
6279 else
6280   ac_have_decl=0
6281 fi
6282
6283 cat >>confdefs.h <<_ACEOF
6284 #define HAVE_DECL_AUTHENTICATE $ac_have_decl
6285 _ACEOF
6286 ac_fn_c_check_decl "$LINENO" "loginrestrictions" "ac_cv_have_decl_loginrestrictions" "#include <usersec.h>
6287 "
6288 if test "x$ac_cv_have_decl_loginrestrictions" = x""yes; then :
6289   ac_have_decl=1
6290 else
6291   ac_have_decl=0
6292 fi
6293
6294 cat >>confdefs.h <<_ACEOF
6295 #define HAVE_DECL_LOGINRESTRICTIONS $ac_have_decl
6296 _ACEOF
6297 ac_fn_c_check_decl "$LINENO" "loginsuccess" "ac_cv_have_decl_loginsuccess" "#include <usersec.h>
6298 "
6299 if test "x$ac_cv_have_decl_loginsuccess" = x""yes; then :
6300   ac_have_decl=1
6301 else
6302   ac_have_decl=0
6303 fi
6304
6305 cat >>confdefs.h <<_ACEOF
6306 #define HAVE_DECL_LOGINSUCCESS $ac_have_decl
6307 _ACEOF
6308 ac_fn_c_check_decl "$LINENO" "passwdexpired" "ac_cv_have_decl_passwdexpired" "#include <usersec.h>
6309 "
6310 if test "x$ac_cv_have_decl_passwdexpired" = x""yes; then :
6311   ac_have_decl=1
6312 else
6313   ac_have_decl=0
6314 fi
6315
6316 cat >>confdefs.h <<_ACEOF
6317 #define HAVE_DECL_PASSWDEXPIRED $ac_have_decl
6318 _ACEOF
6319 ac_fn_c_check_decl "$LINENO" "setauthdb" "ac_cv_have_decl_setauthdb" "#include <usersec.h>
6320 "
6321 if test "x$ac_cv_have_decl_setauthdb" = x""yes; then :
6322   ac_have_decl=1
6323 else
6324   ac_have_decl=0
6325 fi
6326
6327 cat >>confdefs.h <<_ACEOF
6328 #define HAVE_DECL_SETAUTHDB $ac_have_decl
6329 _ACEOF
6330
6331                 ac_fn_c_check_decl "$LINENO" "loginfailed" "ac_cv_have_decl_loginfailed" "#include <usersec.h>
6332
6333 "
6334 if test "x$ac_cv_have_decl_loginfailed" = x""yes; then :
6335   ac_have_decl=1
6336 else
6337   ac_have_decl=0
6338 fi
6339
6340 cat >>confdefs.h <<_ACEOF
6341 #define HAVE_DECL_LOGINFAILED $ac_have_decl
6342 _ACEOF
6343 if test $ac_have_decl = 1; then :
6344   { $as_echo "$as_me:${as_lineno-$LINENO}: checking if loginfailed takes 4 arguments" >&5
6345 $as_echo_n "checking if loginfailed takes 4 arguments... " >&6; }
6346             cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6347 /* end confdefs.h.  */
6348  #include <usersec.h>
6349 int
6350 main ()
6351 {
6352  (void)loginfailed("user","host","tty",0);
6353   ;
6354   return 0;
6355 }
6356 _ACEOF
6357 if ac_fn_c_try_compile "$LINENO"; then :
6358   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6359 $as_echo "yes" >&6; }
6360
6361 $as_echo "#define AIX_LOGINFAILED_4ARG 1" >>confdefs.h
6362
6363 else
6364   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6365 $as_echo "no" >&6; }
6366
6367 fi
6368 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6369 fi
6370
6371         for ac_func in getgrset setauthdb
6372 do :
6373   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
6374 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
6375 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
6376   cat >>confdefs.h <<_ACEOF
6377 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
6378 _ACEOF
6379
6380 fi
6381 done
6382
6383         ac_fn_c_check_decl "$LINENO" "F_CLOSEM" "ac_cv_have_decl_F_CLOSEM" " #include <limits.h>
6384               #include <fcntl.h>
6385
6386 "
6387 if test "x$ac_cv_have_decl_F_CLOSEM" = x""yes; then :
6388
6389 $as_echo "#define HAVE_FCNTL_CLOSEM 1" >>confdefs.h
6390
6391 fi
6392
6393         check_for_aix_broken_getaddrinfo=1
6394
6395 $as_echo "#define BROKEN_REALPATH 1" >>confdefs.h
6396
6397
6398 $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
6399
6400
6401 $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
6402
6403
6404 $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
6405
6406
6407 $as_echo "#define DISABLE_LASTLOG 1" >>confdefs.h
6408
6409
6410 $as_echo "#define LOGIN_NEEDS_UTMPX 1" >>confdefs.h
6411
6412
6413 $as_echo "#define SPT_TYPE SPT_REUSEARGV" >>confdefs.h
6414
6415
6416 $as_echo "#define SSHPAM_CHAUTHTOK_NEEDS_RUID 1" >>confdefs.h
6417
6418
6419 $as_echo "#define PTY_ZEROREAD 1" >>confdefs.h
6420
6421         ;;
6422 *-*-cygwin*)
6423         check_for_libcrypt_later=1
6424         LIBS="$LIBS /usr/lib/textreadmode.o"
6425
6426 $as_echo "#define HAVE_CYGWIN 1" >>confdefs.h
6427
6428
6429 $as_echo "#define USE_PIPES 1" >>confdefs.h
6430
6431
6432 $as_echo "#define DISABLE_SHADOW 1" >>confdefs.h
6433
6434
6435 $as_echo "#define NO_X11_UNIX_SOCKETS 1" >>confdefs.h
6436
6437
6438 $as_echo "#define NO_IPPORT_RESERVED_CONCEPT 1" >>confdefs.h
6439
6440
6441 $as_echo "#define DISABLE_FD_PASSING 1" >>confdefs.h
6442
6443
6444 $as_echo "#define SSH_IOBUFSZ 65535" >>confdefs.h
6445
6446
6447 $as_echo "#define FILESYSTEM_NO_BACKSLASH 1" >>confdefs.h
6448
6449         ;;
6450 *-*-dgux*)
6451
6452 $as_echo "#define IP_TOS_IS_BROKEN 1" >>confdefs.h
6453
6454         $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
6455
6456         $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
6457
6458         $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
6459
6460         ;;
6461 *-*-darwin*)
6462         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have working getaddrinfo" >&5
6463 $as_echo_n "checking if we have working getaddrinfo... " >&6; }
6464         if test "$cross_compiling" = yes; then :
6465   { $as_echo "$as_me:${as_lineno-$LINENO}: result: assume it is working" >&5
6466 $as_echo "assume it is working" >&6; }
6467 else
6468   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6469 /* end confdefs.h.  */
6470  #include <mach-o/dyld.h>
6471 main() { if (NSVersionOfRunTimeLibrary("System") >= (60 << 16))
6472                 exit(0);
6473         else
6474                 exit(1);
6475 }
6476
6477 _ACEOF
6478 if ac_fn_c_try_run "$LINENO"; then :
6479   { $as_echo "$as_me:${as_lineno-$LINENO}: result: working" >&5
6480 $as_echo "working" >&6; }
6481 else
6482   { $as_echo "$as_me:${as_lineno-$LINENO}: result: buggy" >&5
6483 $as_echo "buggy" >&6; }
6484
6485 $as_echo "#define BROKEN_GETADDRINFO 1" >>confdefs.h
6486
6487
6488 fi
6489 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
6490   conftest.$ac_objext conftest.beam conftest.$ac_ext
6491 fi
6492
6493         $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
6494
6495         $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
6496
6497         $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
6498
6499
6500 $as_echo "#define BROKEN_GLOB 1" >>confdefs.h
6501
6502
6503 cat >>confdefs.h <<_ACEOF
6504 #define BIND_8_COMPAT 1
6505 _ACEOF
6506
6507
6508 $as_echo "#define SSH_TUN_FREEBSD 1" >>confdefs.h
6509
6510
6511 $as_echo "#define SSH_TUN_COMPAT_AF 1" >>confdefs.h
6512
6513
6514 $as_echo "#define SSH_TUN_PREPEND_AF 1" >>confdefs.h
6515
6516         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have the Security Authorization Session API" >&5
6517 $as_echo_n "checking if we have the Security Authorization Session API... " >&6; }
6518         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6519 /* end confdefs.h.  */
6520 #include <Security/AuthSession.h>
6521 int
6522 main ()
6523 {
6524 SessionCreate(0, 0);
6525   ;
6526   return 0;
6527 }
6528 _ACEOF
6529 if ac_fn_c_try_compile "$LINENO"; then :
6530   ac_cv_use_security_session_api="yes"
6531
6532 $as_echo "#define USE_SECURITY_SESSION_API 1" >>confdefs.h
6533
6534                  LIBS="$LIBS -framework Security"
6535                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6536 $as_echo "yes" >&6; }
6537 else
6538   ac_cv_use_security_session_api="no"
6539                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6540 $as_echo "no" >&6; }
6541 fi
6542 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6543         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we have an in-memory credentials cache" >&5
6544 $as_echo_n "checking if we have an in-memory credentials cache... " >&6; }
6545         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6546 /* end confdefs.h.  */
6547 #include <Kerberos/Kerberos.h>
6548 int
6549 main ()
6550 {
6551 cc_context_t c;
6552                  (void) cc_initialize (&c, 0, NULL, NULL);
6553   ;
6554   return 0;
6555 }
6556 _ACEOF
6557 if ac_fn_c_try_compile "$LINENO"; then :
6558
6559 $as_echo "#define USE_CCAPI 1" >>confdefs.h
6560
6561                  LIBS="$LIBS -framework Security"
6562                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
6563 $as_echo "yes" >&6; }
6564                  if test "x$ac_cv_use_security_session_api" = "xno"; then
6565                         as_fn_error $? "*** Need a security framework to use the credentials cache API ***" "$LINENO" 5
6566                 fi
6567 else
6568   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
6569 $as_echo "no" >&6; }
6570
6571 fi
6572 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6573
6574         ac_fn_c_check_decl "$LINENO" "AU_IPv4" "ac_cv_have_decl_AU_IPv4" "$ac_includes_default"
6575 if test "x$ac_cv_have_decl_AU_IPv4" = x""yes; then :
6576
6577 else
6578
6579 $as_echo "#define AU_IPv4 0" >>confdefs.h
6580
6581             #include <bsm/audit.h>
6582
6583 $as_echo "#define LASTLOG_WRITE_PUTUTXLINE 1" >>confdefs.h
6584
6585
6586 fi
6587
6588
6589 $as_echo "#define SPT_TYPE SPT_REUSEARGV" >>confdefs.h
6590
6591         for ac_func in sandbox_init
6592 do :
6593   ac_fn_c_check_func "$LINENO" "sandbox_init" "ac_cv_func_sandbox_init"
6594 if test "x$ac_cv_func_sandbox_init" = x""yes; then :
6595   cat >>confdefs.h <<_ACEOF
6596 #define HAVE_SANDBOX_INIT 1
6597 _ACEOF
6598
6599 fi
6600 done
6601
6602         for ac_header in sandbox.h
6603 do :
6604   ac_fn_c_check_header_mongrel "$LINENO" "sandbox.h" "ac_cv_header_sandbox_h" "$ac_includes_default"
6605 if test "x$ac_cv_header_sandbox_h" = x""yes; then :
6606   cat >>confdefs.h <<_ACEOF
6607 #define HAVE_SANDBOX_H 1
6608 _ACEOF
6609
6610 fi
6611
6612 done
6613
6614         ;;
6615 *-*-dragonfly*)
6616         SSHDLIBS="$SSHDLIBS -lcrypt"
6617         ;;
6618 *-*-haiku*)
6619     LIBS="$LIBS -lbsd "
6620     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socket in -lnetwork" >&5
6621 $as_echo_n "checking for socket in -lnetwork... " >&6; }
6622 if test "${ac_cv_lib_network_socket+set}" = set; then :
6623   $as_echo_n "(cached) " >&6
6624 else
6625   ac_check_lib_save_LIBS=$LIBS
6626 LIBS="-lnetwork  $LIBS"
6627 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6628 /* end confdefs.h.  */
6629
6630 /* Override any GCC internal prototype to avoid an error.
6631    Use char because int might match the return type of a GCC
6632    builtin and then its argument prototype would still apply.  */
6633 #ifdef __cplusplus
6634 extern "C"
6635 #endif
6636 char socket ();
6637 int
6638 main ()
6639 {
6640 return socket ();
6641   ;
6642   return 0;
6643 }
6644 _ACEOF
6645 if ac_fn_c_try_link "$LINENO"; then :
6646   ac_cv_lib_network_socket=yes
6647 else
6648   ac_cv_lib_network_socket=no
6649 fi
6650 rm -f core conftest.err conftest.$ac_objext \
6651     conftest$ac_exeext conftest.$ac_ext
6652 LIBS=$ac_check_lib_save_LIBS
6653 fi
6654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_network_socket" >&5
6655 $as_echo "$ac_cv_lib_network_socket" >&6; }
6656 if test "x$ac_cv_lib_network_socket" = x""yes; then :
6657   cat >>confdefs.h <<_ACEOF
6658 #define HAVE_LIBNETWORK 1
6659 _ACEOF
6660
6661   LIBS="-lnetwork $LIBS"
6662
6663 fi
6664
6665     $as_echo "#define HAVE_U_INT64_T 1" >>confdefs.h
6666
6667     MANTYPE=man
6668     ;;
6669 *-*-hpux*)
6670         # first we define all of the options common to all HP-UX releases
6671         CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED=1"
6672         IPADDR_IN_DISPLAY=yes
6673         $as_echo "#define USE_PIPES 1" >>confdefs.h
6674
6675
6676 $as_echo "#define LOGIN_NO_ENDOPT 1" >>confdefs.h
6677
6678         $as_echo "#define LOGIN_NEEDS_UTMPX 1" >>confdefs.h
6679
6680
6681 $as_echo "#define LOCKED_PASSWD_STRING \"*\"" >>confdefs.h
6682
6683         $as_echo "#define SPT_TYPE SPT_PSTAT" >>confdefs.h
6684
6685         maildir="/var/mail"
6686         LIBS="$LIBS -lsec"
6687         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for t_error in -lxnet" >&5
6688 $as_echo_n "checking for t_error in -lxnet... " >&6; }
6689 if test "${ac_cv_lib_xnet_t_error+set}" = set; then :
6690   $as_echo_n "(cached) " >&6
6691 else
6692   ac_check_lib_save_LIBS=$LIBS
6693 LIBS="-lxnet  $LIBS"
6694 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
6695 /* end confdefs.h.  */
6696
6697 /* Override any GCC internal prototype to avoid an error.
6698    Use char because int might match the return type of a GCC
6699    builtin and then its argument prototype would still apply.  */
6700 #ifdef __cplusplus
6701 extern "C"
6702 #endif
6703 char t_error ();
6704 int
6705 main ()
6706 {
6707 return t_error ();
6708   ;
6709   return 0;
6710 }
6711 _ACEOF
6712 if ac_fn_c_try_link "$LINENO"; then :
6713   ac_cv_lib_xnet_t_error=yes
6714 else
6715   ac_cv_lib_xnet_t_error=no
6716 fi
6717 rm -f core conftest.err conftest.$ac_objext \
6718     conftest$ac_exeext conftest.$ac_ext
6719 LIBS=$ac_check_lib_save_LIBS
6720 fi
6721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xnet_t_error" >&5
6722 $as_echo "$ac_cv_lib_xnet_t_error" >&6; }
6723 if test "x$ac_cv_lib_xnet_t_error" = x""yes; then :
6724   cat >>confdefs.h <<_ACEOF
6725 #define HAVE_LIBXNET 1
6726 _ACEOF
6727
6728   LIBS="-lxnet $LIBS"
6729
6730 else
6731   as_fn_error $? "*** -lxnet needed on HP-UX - check config.log ***" "$LINENO" 5
6732 fi
6733
6734
6735         # next, we define all of the options specific to major releases
6736         case "$host" in
6737         *-*-hpux10*)
6738                 if test -z "$GCC"; then
6739                         CFLAGS="$CFLAGS -Ae"
6740                 fi
6741                 ;;
6742         *-*-hpux11*)
6743
6744 $as_echo "#define PAM_SUN_CODEBASE 1" >>confdefs.h
6745
6746
6747 $as_echo "#define DISABLE_UTMP 1" >>confdefs.h
6748
6749
6750 $as_echo "#define USE_BTMP 1" >>confdefs.h
6751
6752                 check_for_hpux_broken_getaddrinfo=1
6753                 check_for_conflicting_getspnam=1
6754                 ;;
6755         esac
6756
6757         # lastly, we define options specific to minor releases
6758         case "$host" in
6759         *-*-hpux10.26)
6760
6761 $as_echo "#define HAVE_SECUREWARE 1" >>confdefs.h
6762
6763                 disable_ptmx_check=yes
6764                 LIBS="$LIBS -lsecpw"
6765                 ;;
6766         esac
6767         ;;
6768 *-*-irix5*)
6769         PATH="$PATH:/usr/etc"
6770
6771 $as_echo "#define BROKEN_INET_NTOA 1" >>confdefs.h
6772
6773         $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
6774
6775         $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
6776
6777         $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
6778
6779
6780 $as_echo "#define WITH_ABBREV_NO_TTY 1" >>confdefs.h
6781
6782         $as_echo "#define LOCKED_PASSWD_STRING \"*LK*\"" >>confdefs.h
6783
6784         ;;
6785 *-*-irix6*)
6786         PATH="$PATH:/usr/etc"
6787
6788 $as_echo "#define WITH_IRIX_ARRAY 1" >>confdefs.h
6789
6790
6791 $as_echo "#define WITH_IRIX_PROJECT 1" >>confdefs.h
6792
6793
6794 $as_echo "#define WITH_IRIX_AUDIT 1" >>confdefs.h
6795
6796         ac_fn_c_check_func "$LINENO" "jlimit_startjob" "ac_cv_func_jlimit_startjob"
6797 if test "x$ac_cv_func_jlimit_startjob" = x""yes; then :
6798
6799 $as_echo "#define WITH_IRIX_JOBS 1" >>confdefs.h
6800
6801 fi
6802
6803         $as_echo "#define BROKEN_INET_NTOA 1" >>confdefs.h
6804
6805         $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
6806
6807         $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
6808
6809         $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
6810
6811
6812 $as_echo "#define BROKEN_UPDWTMPX 1" >>confdefs.h
6813
6814         $as_echo "#define WITH_ABBREV_NO_TTY 1" >>confdefs.h
6815
6816         $as_echo "#define LOCKED_PASSWD_STRING \"*LK*\"" >>confdefs.h
6817
6818         ;;
6819 *-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
6820         check_for_libcrypt_later=1
6821         $as_echo "#define PAM_TTY_KLUDGE 1" >>confdefs.h
6822
6823         $as_echo "#define LOCKED_PASSWD_PREFIX \"!\"" >>confdefs.h
6824
6825         $as_echo "#define SPT_TYPE SPT_REUSEARGV" >>confdefs.h
6826
6827
6828 $as_echo "#define _PATH_BTMP \"/var/log/btmp\"" >>confdefs.h
6829
6830
6831 $as_echo "#define USE_BTMP 1" >>confdefs.h
6832
6833         ;;
6834 *-*-linux*)
6835         no_dev_ptmx=1
6836         check_for_libcrypt_later=1
6837         check_for_openpty_ctty_bug=1
6838
6839 $as_echo "#define PAM_TTY_KLUDGE 1" >>confdefs.h
6840
6841
6842 $as_echo "#define LOCKED_PASSWD_PREFIX \"!\"" >>confdefs.h
6843
6844         $as_echo "#define SPT_TYPE SPT_REUSEARGV" >>confdefs.h
6845
6846
6847 $as_echo "#define LINK_OPNOTSUPP_ERRNO EPERM" >>confdefs.h
6848
6849
6850 $as_echo "#define _PATH_BTMP \"/var/log/btmp\"" >>confdefs.h
6851
6852         $as_echo "#define USE_BTMP 1" >>confdefs.h
6853
6854
6855 $as_echo "#define LINUX_OOM_ADJUST 1" >>confdefs.h
6856
6857         inet6_default_4in6=yes
6858         case `uname -r` in
6859         1.*|2.0.*)
6860
6861 $as_echo "#define BROKEN_CMSG_TYPE 1" >>confdefs.h
6862
6863                 ;;
6864         esac
6865         # tun(4) forwarding compat code
6866         for ac_header in linux/if_tun.h
6867 do :
6868   ac_fn_c_check_header_mongrel "$LINENO" "linux/if_tun.h" "ac_cv_header_linux_if_tun_h" "$ac_includes_default"
6869 if test "x$ac_cv_header_linux_if_tun_h" = x""yes; then :
6870   cat >>confdefs.h <<_ACEOF
6871 #define HAVE_LINUX_IF_TUN_H 1
6872 _ACEOF
6873
6874 fi
6875
6876 done
6877
6878         if test "x$ac_cv_header_linux_if_tun_h" = "xyes" ; then
6879
6880 $as_echo "#define SSH_TUN_LINUX 1" >>confdefs.h
6881
6882
6883 $as_echo "#define SSH_TUN_COMPAT_AF 1" >>confdefs.h
6884
6885
6886 $as_echo "#define SSH_TUN_PREPEND_AF 1" >>confdefs.h
6887
6888         fi
6889         ;;
6890 mips-sony-bsd|mips-sony-newsos4)
6891
6892 $as_echo "#define NEED_SETPGRP 1" >>confdefs.h
6893
6894         SONY=1
6895         ;;
6896 *-*-netbsd*)
6897         check_for_libcrypt_before=1
6898         if test "x$withval" != "xno" ; then
6899                 need_dash_r=1
6900         fi
6901
6902 $as_echo "#define SSH_TUN_FREEBSD 1" >>confdefs.h
6903
6904         ac_fn_c_check_header_mongrel "$LINENO" "net/if_tap.h" "ac_cv_header_net_if_tap_h" "$ac_includes_default"
6905 if test "x$ac_cv_header_net_if_tap_h" = x""yes; then :
6906
6907 else
6908
6909 $as_echo "#define SSH_TUN_NO_L2 1" >>confdefs.h
6910
6911 fi
6912
6913
6914
6915 $as_echo "#define SSH_TUN_PREPEND_AF 1" >>confdefs.h
6916
6917         ;;
6918 *-*-freebsd*)
6919         check_for_libcrypt_later=1
6920
6921 $as_echo "#define LOCKED_PASSWD_PREFIX \"*LOCKED*\"" >>confdefs.h
6922
6923
6924 $as_echo "#define SSH_TUN_FREEBSD 1" >>confdefs.h
6925
6926         ac_fn_c_check_header_mongrel "$LINENO" "net/if_tap.h" "ac_cv_header_net_if_tap_h" "$ac_includes_default"
6927 if test "x$ac_cv_header_net_if_tap_h" = x""yes; then :
6928
6929 else
6930
6931 $as_echo "#define SSH_TUN_NO_L2 1" >>confdefs.h
6932
6933 fi
6934
6935
6936
6937 $as_echo "#define BROKEN_GLOB 1" >>confdefs.h
6938
6939         ;;
6940 *-*-bsdi*)
6941         $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
6942
6943         $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
6944
6945         $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
6946
6947         ;;
6948 *-next-*)
6949         conf_lastlog_location="/usr/adm/lastlog"
6950         conf_utmp_location=/etc/utmp
6951         conf_wtmp_location=/usr/adm/wtmp
6952         maildir=/usr/spool/mail
6953
6954 $as_echo "#define HAVE_NEXT 1" >>confdefs.h
6955
6956         $as_echo "#define BROKEN_REALPATH 1" >>confdefs.h
6957
6958         $as_echo "#define USE_PIPES 1" >>confdefs.h
6959
6960
6961 $as_echo "#define BROKEN_SAVED_UIDS 1" >>confdefs.h
6962
6963         ;;
6964 *-*-openbsd*)
6965
6966 $as_echo "#define HAVE_ATTRIBUTE__SENTINEL__ 1" >>confdefs.h
6967
6968
6969 $as_echo "#define HAVE_ATTRIBUTE__BOUNDED__ 1" >>confdefs.h
6970
6971
6972 $as_echo "#define SSH_TUN_OPENBSD 1" >>confdefs.h
6973
6974
6975 $as_echo "#define SYSLOG_R_SAFE_IN_SIGHAND 1" >>confdefs.h
6976
6977         ;;
6978 *-*-solaris*)
6979         if test "x$withval" != "xno" ; then
6980                 need_dash_r=1
6981         fi
6982         $as_echo "#define PAM_SUN_CODEBASE 1" >>confdefs.h
6983
6984         $as_echo "#define LOGIN_NEEDS_UTMPX 1" >>confdefs.h
6985
6986
6987 $as_echo "#define LOGIN_NEEDS_TERM 1" >>confdefs.h
6988
6989         $as_echo "#define PAM_TTY_KLUDGE 1" >>confdefs.h
6990
6991
6992 $as_echo "#define SSHPAM_CHAUTHTOK_NEEDS_RUID 1" >>confdefs.h
6993
6994         $as_echo "#define LOCKED_PASSWD_STRING \"*LK*\"" >>confdefs.h
6995
6996         # Pushing STREAMS modules will cause sshd to acquire a controlling tty.
6997
6998 $as_echo "#define SSHD_ACQUIRES_CTTY 1" >>confdefs.h
6999
7000
7001 $as_echo "#define PASSWD_NEEDS_USERNAME 1" >>confdefs.h
7002
7003
7004 $as_echo "#define BROKEN_TCGETATTR_ICANON 1" >>confdefs.h
7005
7006         external_path_file=/etc/default/login
7007         # hardwire lastlog location (can't detect it on some versions)
7008         conf_lastlog_location="/var/adm/lastlog"
7009         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for obsolete utmp and wtmp in solaris2.x" >&5
7010 $as_echo_n "checking for obsolete utmp and wtmp in solaris2.x... " >&6; }
7011         sol2ver=`echo "$host"| sed -e 's/.*[0-9]\.//'`
7012         if test "$sol2ver" -ge 8; then
7013                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7014 $as_echo "yes" >&6; }
7015                 $as_echo "#define DISABLE_UTMP 1" >>confdefs.h
7016
7017
7018 $as_echo "#define DISABLE_WTMP 1" >>confdefs.h
7019
7020         else
7021                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7022 $as_echo "no" >&6; }
7023         fi
7024
7025 # Check whether --with-solaris-contracts was given.
7026 if test "${with_solaris_contracts+set}" = set; then :
7027   withval=$with_solaris_contracts;
7028                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ct_tmpl_activate in -lcontract" >&5
7029 $as_echo_n "checking for ct_tmpl_activate in -lcontract... " >&6; }
7030 if test "${ac_cv_lib_contract_ct_tmpl_activate+set}" = set; then :
7031   $as_echo_n "(cached) " >&6
7032 else
7033   ac_check_lib_save_LIBS=$LIBS
7034 LIBS="-lcontract  $LIBS"
7035 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7036 /* end confdefs.h.  */
7037
7038 /* Override any GCC internal prototype to avoid an error.
7039    Use char because int might match the return type of a GCC
7040    builtin and then its argument prototype would still apply.  */
7041 #ifdef __cplusplus
7042 extern "C"
7043 #endif
7044 char ct_tmpl_activate ();
7045 int
7046 main ()
7047 {
7048 return ct_tmpl_activate ();
7049   ;
7050   return 0;
7051 }
7052 _ACEOF
7053 if ac_fn_c_try_link "$LINENO"; then :
7054   ac_cv_lib_contract_ct_tmpl_activate=yes
7055 else
7056   ac_cv_lib_contract_ct_tmpl_activate=no
7057 fi
7058 rm -f core conftest.err conftest.$ac_objext \
7059     conftest$ac_exeext conftest.$ac_ext
7060 LIBS=$ac_check_lib_save_LIBS
7061 fi
7062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_contract_ct_tmpl_activate" >&5
7063 $as_echo "$ac_cv_lib_contract_ct_tmpl_activate" >&6; }
7064 if test "x$ac_cv_lib_contract_ct_tmpl_activate" = x""yes; then :
7065
7066 $as_echo "#define USE_SOLARIS_PROCESS_CONTRACTS 1" >>confdefs.h
7067
7068                           SSHDLIBS="$SSHDLIBS -lcontract"
7069                           SPC_MSG="yes"
7070 fi
7071
7072
7073 fi
7074
7075
7076 # Check whether --with-solaris-projects was given.
7077 if test "${with_solaris_projects+set}" = set; then :
7078   withval=$with_solaris_projects;
7079                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setproject in -lproject" >&5
7080 $as_echo_n "checking for setproject in -lproject... " >&6; }
7081 if test "${ac_cv_lib_project_setproject+set}" = set; then :
7082   $as_echo_n "(cached) " >&6
7083 else
7084   ac_check_lib_save_LIBS=$LIBS
7085 LIBS="-lproject  $LIBS"
7086 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7087 /* end confdefs.h.  */
7088
7089 /* Override any GCC internal prototype to avoid an error.
7090    Use char because int might match the return type of a GCC
7091    builtin and then its argument prototype would still apply.  */
7092 #ifdef __cplusplus
7093 extern "C"
7094 #endif
7095 char setproject ();
7096 int
7097 main ()
7098 {
7099 return setproject ();
7100   ;
7101   return 0;
7102 }
7103 _ACEOF
7104 if ac_fn_c_try_link "$LINENO"; then :
7105   ac_cv_lib_project_setproject=yes
7106 else
7107   ac_cv_lib_project_setproject=no
7108 fi
7109 rm -f core conftest.err conftest.$ac_objext \
7110     conftest$ac_exeext conftest.$ac_ext
7111 LIBS=$ac_check_lib_save_LIBS
7112 fi
7113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_project_setproject" >&5
7114 $as_echo "$ac_cv_lib_project_setproject" >&6; }
7115 if test "x$ac_cv_lib_project_setproject" = x""yes; then :
7116
7117 $as_echo "#define USE_SOLARIS_PROJECTS 1" >>confdefs.h
7118
7119                         SSHDLIBS="$SSHDLIBS -lproject"
7120                         SP_MSG="yes"
7121 fi
7122
7123
7124 fi
7125
7126         ;;
7127 *-*-sunos4*)
7128         CPPFLAGS="$CPPFLAGS -DSUNOS4"
7129         for ac_func in getpwanam
7130 do :
7131   ac_fn_c_check_func "$LINENO" "getpwanam" "ac_cv_func_getpwanam"
7132 if test "x$ac_cv_func_getpwanam" = x""yes; then :
7133   cat >>confdefs.h <<_ACEOF
7134 #define HAVE_GETPWANAM 1
7135 _ACEOF
7136
7137 fi
7138 done
7139
7140         $as_echo "#define PAM_SUN_CODEBASE 1" >>confdefs.h
7141
7142         conf_utmp_location=/etc/utmp
7143         conf_wtmp_location=/var/adm/wtmp
7144         conf_lastlog_location=/var/adm/lastlog
7145         $as_echo "#define USE_PIPES 1" >>confdefs.h
7146
7147         ;;
7148 *-ncr-sysv*)
7149         LIBS="$LIBS -lc89"
7150         $as_echo "#define USE_PIPES 1" >>confdefs.h
7151
7152         $as_echo "#define SSHD_ACQUIRES_CTTY 1" >>confdefs.h
7153
7154         $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
7155
7156         $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
7157
7158         $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
7159
7160         ;;
7161 *-sni-sysv*)
7162         # /usr/ucblib MUST NOT be searched on ReliantUNIX
7163         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlsym in -ldl" >&5
7164 $as_echo_n "checking for dlsym in -ldl... " >&6; }
7165 if test "${ac_cv_lib_dl_dlsym+set}" = set; then :
7166   $as_echo_n "(cached) " >&6
7167 else
7168   ac_check_lib_save_LIBS=$LIBS
7169 LIBS="-ldl  $LIBS"
7170 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7171 /* end confdefs.h.  */
7172
7173 /* Override any GCC internal prototype to avoid an error.
7174    Use char because int might match the return type of a GCC
7175    builtin and then its argument prototype would still apply.  */
7176 #ifdef __cplusplus
7177 extern "C"
7178 #endif
7179 char dlsym ();
7180 int
7181 main ()
7182 {
7183 return dlsym ();
7184   ;
7185   return 0;
7186 }
7187 _ACEOF
7188 if ac_fn_c_try_link "$LINENO"; then :
7189   ac_cv_lib_dl_dlsym=yes
7190 else
7191   ac_cv_lib_dl_dlsym=no
7192 fi
7193 rm -f core conftest.err conftest.$ac_objext \
7194     conftest$ac_exeext conftest.$ac_ext
7195 LIBS=$ac_check_lib_save_LIBS
7196 fi
7197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlsym" >&5
7198 $as_echo "$ac_cv_lib_dl_dlsym" >&6; }
7199 if test "x$ac_cv_lib_dl_dlsym" = x""yes; then :
7200   cat >>confdefs.h <<_ACEOF
7201 #define HAVE_LIBDL 1
7202 _ACEOF
7203
7204   LIBS="-ldl $LIBS"
7205
7206 fi
7207
7208         # -lresolv needs to be at the end of LIBS or DNS lookups break
7209         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_query in -lresolv" >&5
7210 $as_echo_n "checking for res_query in -lresolv... " >&6; }
7211 if test "${ac_cv_lib_resolv_res_query+set}" = set; then :
7212   $as_echo_n "(cached) " >&6
7213 else
7214   ac_check_lib_save_LIBS=$LIBS
7215 LIBS="-lresolv  $LIBS"
7216 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7217 /* end confdefs.h.  */
7218
7219 /* Override any GCC internal prototype to avoid an error.
7220    Use char because int might match the return type of a GCC
7221    builtin and then its argument prototype would still apply.  */
7222 #ifdef __cplusplus
7223 extern "C"
7224 #endif
7225 char res_query ();
7226 int
7227 main ()
7228 {
7229 return res_query ();
7230   ;
7231   return 0;
7232 }
7233 _ACEOF
7234 if ac_fn_c_try_link "$LINENO"; then :
7235   ac_cv_lib_resolv_res_query=yes
7236 else
7237   ac_cv_lib_resolv_res_query=no
7238 fi
7239 rm -f core conftest.err conftest.$ac_objext \
7240     conftest$ac_exeext conftest.$ac_ext
7241 LIBS=$ac_check_lib_save_LIBS
7242 fi
7243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_res_query" >&5
7244 $as_echo "$ac_cv_lib_resolv_res_query" >&6; }
7245 if test "x$ac_cv_lib_resolv_res_query" = x""yes; then :
7246    LIBS="$LIBS -lresolv"
7247 fi
7248
7249         IPADDR_IN_DISPLAY=yes
7250         $as_echo "#define USE_PIPES 1" >>confdefs.h
7251
7252         $as_echo "#define IP_TOS_IS_BROKEN 1" >>confdefs.h
7253
7254         $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
7255
7256         $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
7257
7258         $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
7259
7260         $as_echo "#define SSHD_ACQUIRES_CTTY 1" >>confdefs.h
7261
7262         external_path_file=/etc/default/login
7263         # /usr/ucblib/libucb.a no longer needed on ReliantUNIX
7264         # Attention: always take care to bind libsocket and libnsl before libc,
7265         # otherwise you will find lots of "SIOCGPGRP errno 22" on syslog
7266         ;;
7267 # UnixWare 1.x, UnixWare 2.x, and others based on code from Univel.
7268 *-*-sysv4.2*)
7269         $as_echo "#define USE_PIPES 1" >>confdefs.h
7270
7271         $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
7272
7273         $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
7274
7275         $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
7276
7277
7278 $as_echo "#define PASSWD_NEEDS_USERNAME 1" >>confdefs.h
7279
7280         $as_echo "#define LOCKED_PASSWD_STRING \"*LK*\"" >>confdefs.h
7281
7282         ;;
7283 # UnixWare 7.x, OpenUNIX 8
7284 *-*-sysv5*)
7285         CPPFLAGS="$CPPFLAGS -Dvsnprintf=_xvsnprintf -Dsnprintf=_xsnprintf"
7286
7287 $as_echo "#define UNIXWARE_LONG_PASSWORDS 1" >>confdefs.h
7288
7289         $as_echo "#define USE_PIPES 1" >>confdefs.h
7290
7291         $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
7292
7293         $as_echo "#define BROKEN_GETADDRINFO 1" >>confdefs.h
7294
7295         $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
7296
7297         $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
7298
7299         $as_echo "#define PASSWD_NEEDS_USERNAME 1" >>confdefs.h
7300
7301         case "$host" in
7302         *-*-sysv5SCO_SV*)       # SCO OpenServer 6.x
7303                 maildir=/var/spool/mail
7304                 TEST_SHELL=/u95/bin/sh
7305
7306 $as_echo "#define BROKEN_LIBIAF 1" >>confdefs.h
7307
7308                 $as_echo "#define BROKEN_UPDWTMPX 1" >>confdefs.h
7309
7310                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getluid in -lprot" >&5
7311 $as_echo_n "checking for getluid in -lprot... " >&6; }
7312 if test "${ac_cv_lib_prot_getluid+set}" = set; then :
7313   $as_echo_n "(cached) " >&6
7314 else
7315   ac_check_lib_save_LIBS=$LIBS
7316 LIBS="-lprot  $LIBS"
7317 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7318 /* end confdefs.h.  */
7319
7320 /* Override any GCC internal prototype to avoid an error.
7321    Use char because int might match the return type of a GCC
7322    builtin and then its argument prototype would still apply.  */
7323 #ifdef __cplusplus
7324 extern "C"
7325 #endif
7326 char getluid ();
7327 int
7328 main ()
7329 {
7330 return getluid ();
7331   ;
7332   return 0;
7333 }
7334 _ACEOF
7335 if ac_fn_c_try_link "$LINENO"; then :
7336   ac_cv_lib_prot_getluid=yes
7337 else
7338   ac_cv_lib_prot_getluid=no
7339 fi
7340 rm -f core conftest.err conftest.$ac_objext \
7341     conftest$ac_exeext conftest.$ac_ext
7342 LIBS=$ac_check_lib_save_LIBS
7343 fi
7344 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_prot_getluid" >&5
7345 $as_echo "$ac_cv_lib_prot_getluid" >&6; }
7346 if test "x$ac_cv_lib_prot_getluid" = x""yes; then :
7347    LIBS="$LIBS -lprot"
7348                         for ac_func in getluid setluid
7349 do :
7350   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
7351 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
7352 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
7353   cat >>confdefs.h <<_ACEOF
7354 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
7355 _ACEOF
7356
7357 fi
7358 done
7359
7360                         $as_echo "#define HAVE_SECUREWARE 1" >>confdefs.h
7361
7362                         $as_echo "#define DISABLE_SHADOW 1" >>confdefs.h
7363
7364
7365 fi
7366
7367                 ;;
7368         *)      $as_echo "#define LOCKED_PASSWD_STRING \"*LK*\"" >>confdefs.h
7369
7370                 check_for_libcrypt_later=1
7371                 ;;
7372         esac
7373         ;;
7374 *-*-sysv*)
7375         ;;
7376 # SCO UNIX and OEM versions of SCO UNIX
7377 *-*-sco3.2v4*)
7378         as_fn_error $? "\"This Platform is no longer supported.\"" "$LINENO" 5
7379         ;;
7380 # SCO OpenServer 5.x
7381 *-*-sco3.2v5*)
7382         if test -z "$GCC"; then
7383                 CFLAGS="$CFLAGS -belf"
7384         fi
7385         LIBS="$LIBS -lprot -lx -ltinfo -lm"
7386         no_dev_ptmx=1
7387         $as_echo "#define USE_PIPES 1" >>confdefs.h
7388
7389         $as_echo "#define HAVE_SECUREWARE 1" >>confdefs.h
7390
7391         $as_echo "#define DISABLE_SHADOW 1" >>confdefs.h
7392
7393         $as_echo "#define DISABLE_FD_PASSING 1" >>confdefs.h
7394
7395         $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
7396
7397         $as_echo "#define BROKEN_GETADDRINFO 1" >>confdefs.h
7398
7399         $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
7400
7401         $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
7402
7403         $as_echo "#define WITH_ABBREV_NO_TTY 1" >>confdefs.h
7404
7405         $as_echo "#define BROKEN_UPDWTMPX 1" >>confdefs.h
7406
7407         $as_echo "#define PASSWD_NEEDS_USERNAME 1" >>confdefs.h
7408
7409         for ac_func in getluid setluid
7410 do :
7411   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
7412 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
7413 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
7414   cat >>confdefs.h <<_ACEOF
7415 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
7416 _ACEOF
7417
7418 fi
7419 done
7420
7421         MANTYPE=man
7422         TEST_SHELL=ksh
7423         ;;
7424 *-*-unicosmk*)
7425
7426 $as_echo "#define NO_SSH_LASTLOG 1" >>confdefs.h
7427
7428         $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
7429
7430         $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
7431
7432         $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
7433
7434         $as_echo "#define USE_PIPES 1" >>confdefs.h
7435
7436         $as_echo "#define DISABLE_FD_PASSING 1" >>confdefs.h
7437
7438         LDFLAGS="$LDFLAGS"
7439         LIBS="$LIBS -lgen -lrsc -lshare -luex -lacm"
7440         MANTYPE=cat
7441         ;;
7442 *-*-unicosmp*)
7443         $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
7444
7445         $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
7446
7447         $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
7448
7449         $as_echo "#define WITH_ABBREV_NO_TTY 1" >>confdefs.h
7450
7451         $as_echo "#define USE_PIPES 1" >>confdefs.h
7452
7453         $as_echo "#define DISABLE_FD_PASSING 1" >>confdefs.h
7454
7455         LDFLAGS="$LDFLAGS"
7456         LIBS="$LIBS -lgen -lacid -ldb"
7457         MANTYPE=cat
7458         ;;
7459 *-*-unicos*)
7460         $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
7461
7462         $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
7463
7464         $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
7465
7466         $as_echo "#define USE_PIPES 1" >>confdefs.h
7467
7468         $as_echo "#define DISABLE_FD_PASSING 1" >>confdefs.h
7469
7470         $as_echo "#define NO_SSH_LASTLOG 1" >>confdefs.h
7471
7472         LDFLAGS="$LDFLAGS -Wl,-Dmsglevel=334:fatal"
7473         LIBS="$LIBS -lgen -lrsc -lshare -luex -lacm"
7474         MANTYPE=cat
7475         ;;
7476 *-dec-osf*)
7477         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Digital Unix SIA" >&5
7478 $as_echo_n "checking for Digital Unix SIA... " >&6; }
7479         no_osfsia=""
7480
7481 # Check whether --with-osfsia was given.
7482 if test "${with_osfsia+set}" = set; then :
7483   withval=$with_osfsia;
7484                         if test "x$withval" = "xno" ; then
7485                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5
7486 $as_echo "disabled" >&6; }
7487                                 no_osfsia=1
7488                         fi
7489
7490 fi
7491
7492         if test -z "$no_osfsia" ; then
7493                 if test -f /etc/sia/matrix.conf; then
7494                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7495 $as_echo "yes" >&6; }
7496
7497 $as_echo "#define HAVE_OSF_SIA 1" >>confdefs.h
7498
7499
7500 $as_echo "#define DISABLE_LOGIN 1" >>confdefs.h
7501
7502                         $as_echo "#define DISABLE_FD_PASSING 1" >>confdefs.h
7503
7504                         LIBS="$LIBS -lsecurity -ldb -lm -laud"
7505                         SIA_MSG="yes"
7506                 else
7507                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7508 $as_echo "no" >&6; }
7509
7510 $as_echo "#define LOCKED_PASSWD_SUBSTR \"Nologin\"" >>confdefs.h
7511
7512                 fi
7513         fi
7514         $as_echo "#define BROKEN_GETADDRINFO 1" >>confdefs.h
7515
7516         $as_echo "#define SETEUID_BREAKS_SETUID 1" >>confdefs.h
7517
7518         $as_echo "#define BROKEN_SETREUID 1" >>confdefs.h
7519
7520         $as_echo "#define BROKEN_SETREGID 1" >>confdefs.h
7521
7522
7523 $as_echo "#define BROKEN_READV_COMPARISON 1" >>confdefs.h
7524
7525         ;;
7526
7527 *-*-nto-qnx*)
7528         $as_echo "#define USE_PIPES 1" >>confdefs.h
7529
7530         $as_echo "#define NO_X11_UNIX_SOCKETS 1" >>confdefs.h
7531
7532
7533 $as_echo "#define MISSING_NFDBITS 1" >>confdefs.h
7534
7535
7536 $as_echo "#define MISSING_HOWMANY 1" >>confdefs.h
7537
7538
7539 $as_echo "#define MISSING_FD_MASK 1" >>confdefs.h
7540
7541         $as_echo "#define DISABLE_LASTLOG 1" >>confdefs.h
7542
7543         $as_echo "#define SSHD_ACQUIRES_CTTY 1" >>confdefs.h
7544
7545
7546 $as_echo "#define BROKEN_SHADOW_EXPIRE 1" >>confdefs.h
7547
7548         enable_etc_default_login=no     # has incompatible /etc/default/login
7549         case "$host" in
7550         *-*-nto-qnx6*)
7551                 $as_echo "#define DISABLE_FD_PASSING 1" >>confdefs.h
7552
7553                 ;;
7554         esac
7555         ;;
7556
7557 *-*-ultrix*)
7558
7559 $as_echo "#define BROKEN_GETGROUPS 1" >>confdefs.h
7560
7561
7562 $as_echo "#define BROKEN_MMAP 1" >>confdefs.h
7563
7564         $as_echo "#define NEED_SETPGRP 1" >>confdefs.h
7565
7566
7567 $as_echo "#define HAVE_SYS_SYSLOG_H 1" >>confdefs.h
7568
7569         ;;
7570
7571 *-*-lynxos)
7572         CFLAGS="$CFLAGS -D__NO_INCLUDE_WARN__"
7573         $as_echo "#define MISSING_HOWMANY 1" >>confdefs.h
7574
7575
7576 $as_echo "#define BROKEN_SETVBUF 1" >>confdefs.h
7577
7578         ;;
7579 esac
7580
7581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compiler and flags for sanity" >&5
7582 $as_echo_n "checking compiler and flags for sanity... " >&6; }
7583 if test "$cross_compiling" = yes; then :
7584         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking compiler sanity" >&5
7585 $as_echo "$as_me: WARNING: cross compiling: not checking compiler sanity" >&2;}
7586
7587 else
7588   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7589 /* end confdefs.h.  */
7590  #include <stdio.h>
7591 int
7592 main ()
7593 {
7594  exit(0);
7595   ;
7596   return 0;
7597 }
7598 _ACEOF
7599 if ac_fn_c_try_run "$LINENO"; then :
7600         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
7601 $as_echo "yes" >&6; }
7602 else
7603
7604                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
7605 $as_echo "no" >&6; }
7606                 as_fn_error $? "*** compiler cannot create working executables, check config.log ***" "$LINENO" 5
7607
7608 fi
7609 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7610   conftest.$ac_objext conftest.beam conftest.$ac_ext
7611 fi
7612
7613
7614 # Checks for libraries.
7615 ac_fn_c_check_func "$LINENO" "yp_match" "ac_cv_func_yp_match"
7616 if test "x$ac_cv_func_yp_match" = x""yes; then :
7617
7618 else
7619   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for yp_match in -lnsl" >&5
7620 $as_echo_n "checking for yp_match in -lnsl... " >&6; }
7621 if test "${ac_cv_lib_nsl_yp_match+set}" = set; then :
7622   $as_echo_n "(cached) " >&6
7623 else
7624   ac_check_lib_save_LIBS=$LIBS
7625 LIBS="-lnsl  $LIBS"
7626 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7627 /* end confdefs.h.  */
7628
7629 /* Override any GCC internal prototype to avoid an error.
7630    Use char because int might match the return type of a GCC
7631    builtin and then its argument prototype would still apply.  */
7632 #ifdef __cplusplus
7633 extern "C"
7634 #endif
7635 char yp_match ();
7636 int
7637 main ()
7638 {
7639 return yp_match ();
7640   ;
7641   return 0;
7642 }
7643 _ACEOF
7644 if ac_fn_c_try_link "$LINENO"; then :
7645   ac_cv_lib_nsl_yp_match=yes
7646 else
7647   ac_cv_lib_nsl_yp_match=no
7648 fi
7649 rm -f core conftest.err conftest.$ac_objext \
7650     conftest$ac_exeext conftest.$ac_ext
7651 LIBS=$ac_check_lib_save_LIBS
7652 fi
7653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_yp_match" >&5
7654 $as_echo "$ac_cv_lib_nsl_yp_match" >&6; }
7655 if test "x$ac_cv_lib_nsl_yp_match" = x""yes; then :
7656   cat >>confdefs.h <<_ACEOF
7657 #define HAVE_LIBNSL 1
7658 _ACEOF
7659
7660   LIBS="-lnsl $LIBS"
7661
7662 fi
7663
7664 fi
7665
7666 ac_fn_c_check_func "$LINENO" "setsockopt" "ac_cv_func_setsockopt"
7667 if test "x$ac_cv_func_setsockopt" = x""yes; then :
7668
7669 else
7670   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setsockopt in -lsocket" >&5
7671 $as_echo_n "checking for setsockopt in -lsocket... " >&6; }
7672 if test "${ac_cv_lib_socket_setsockopt+set}" = set; then :
7673   $as_echo_n "(cached) " >&6
7674 else
7675   ac_check_lib_save_LIBS=$LIBS
7676 LIBS="-lsocket  $LIBS"
7677 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7678 /* end confdefs.h.  */
7679
7680 /* Override any GCC internal prototype to avoid an error.
7681    Use char because int might match the return type of a GCC
7682    builtin and then its argument prototype would still apply.  */
7683 #ifdef __cplusplus
7684 extern "C"
7685 #endif
7686 char setsockopt ();
7687 int
7688 main ()
7689 {
7690 return setsockopt ();
7691   ;
7692   return 0;
7693 }
7694 _ACEOF
7695 if ac_fn_c_try_link "$LINENO"; then :
7696   ac_cv_lib_socket_setsockopt=yes
7697 else
7698   ac_cv_lib_socket_setsockopt=no
7699 fi
7700 rm -f core conftest.err conftest.$ac_objext \
7701     conftest$ac_exeext conftest.$ac_ext
7702 LIBS=$ac_check_lib_save_LIBS
7703 fi
7704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_setsockopt" >&5
7705 $as_echo "$ac_cv_lib_socket_setsockopt" >&6; }
7706 if test "x$ac_cv_lib_socket_setsockopt" = x""yes; then :
7707   cat >>confdefs.h <<_ACEOF
7708 #define HAVE_LIBSOCKET 1
7709 _ACEOF
7710
7711   LIBS="-lsocket $LIBS"
7712
7713 fi
7714
7715 fi
7716
7717
7718 for ac_func in dirname
7719 do :
7720   ac_fn_c_check_func "$LINENO" "dirname" "ac_cv_func_dirname"
7721 if test "x$ac_cv_func_dirname" = x""yes; then :
7722   cat >>confdefs.h <<_ACEOF
7723 #define HAVE_DIRNAME 1
7724 _ACEOF
7725  for ac_header in libgen.h
7726 do :
7727   ac_fn_c_check_header_mongrel "$LINENO" "libgen.h" "ac_cv_header_libgen_h" "$ac_includes_default"
7728 if test "x$ac_cv_header_libgen_h" = x""yes; then :
7729   cat >>confdefs.h <<_ACEOF
7730 #define HAVE_LIBGEN_H 1
7731 _ACEOF
7732
7733 fi
7734
7735 done
7736
7737 else
7738
7739         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dirname in -lgen" >&5
7740 $as_echo_n "checking for dirname in -lgen... " >&6; }
7741 if test "${ac_cv_lib_gen_dirname+set}" = set; then :
7742   $as_echo_n "(cached) " >&6
7743 else
7744   ac_check_lib_save_LIBS=$LIBS
7745 LIBS="-lgen  $LIBS"
7746 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7747 /* end confdefs.h.  */
7748
7749 /* Override any GCC internal prototype to avoid an error.
7750    Use char because int might match the return type of a GCC
7751    builtin and then its argument prototype would still apply.  */
7752 #ifdef __cplusplus
7753 extern "C"
7754 #endif
7755 char dirname ();
7756 int
7757 main ()
7758 {
7759 return dirname ();
7760   ;
7761   return 0;
7762 }
7763 _ACEOF
7764 if ac_fn_c_try_link "$LINENO"; then :
7765   ac_cv_lib_gen_dirname=yes
7766 else
7767   ac_cv_lib_gen_dirname=no
7768 fi
7769 rm -f core conftest.err conftest.$ac_objext \
7770     conftest$ac_exeext conftest.$ac_ext
7771 LIBS=$ac_check_lib_save_LIBS
7772 fi
7773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_dirname" >&5
7774 $as_echo "$ac_cv_lib_gen_dirname" >&6; }
7775 if test "x$ac_cv_lib_gen_dirname" = x""yes; then :
7776
7777                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken dirname" >&5
7778 $as_echo_n "checking for broken dirname... " >&6; }
7779 if test "${ac_cv_have_broken_dirname+set}" = set; then :
7780   $as_echo_n "(cached) " >&6
7781 else
7782
7783                         save_LIBS="$LIBS"
7784                         LIBS="$LIBS -lgen"
7785                         if test "$cross_compiling" = yes; then :
7786    ac_cv_have_broken_dirname="no"
7787 else
7788   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7789 /* end confdefs.h.  */
7790
7791 #include <libgen.h>
7792 #include <string.h>
7793
7794 int main(int argc, char **argv) {
7795     char *s, buf[32];
7796
7797     strncpy(buf,"/etc", 32);
7798     s = dirname(buf);
7799     if (!s || strncmp(s, "/", 32) != 0) {
7800         exit(1);
7801     } else {
7802         exit(0);
7803     }
7804 }
7805
7806 _ACEOF
7807 if ac_fn_c_try_run "$LINENO"; then :
7808    ac_cv_have_broken_dirname="no"
7809 else
7810    ac_cv_have_broken_dirname="yes"
7811 fi
7812 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
7813   conftest.$ac_objext conftest.beam conftest.$ac_ext
7814 fi
7815
7816                         LIBS="$save_LIBS"
7817
7818 fi
7819 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_broken_dirname" >&5
7820 $as_echo "$ac_cv_have_broken_dirname" >&6; }
7821                 if test "x$ac_cv_have_broken_dirname" = "xno" ; then
7822                         LIBS="$LIBS -lgen"
7823                         $as_echo "#define HAVE_DIRNAME 1" >>confdefs.h
7824
7825                         for ac_header in libgen.h
7826 do :
7827   ac_fn_c_check_header_mongrel "$LINENO" "libgen.h" "ac_cv_header_libgen_h" "$ac_includes_default"
7828 if test "x$ac_cv_header_libgen_h" = x""yes; then :
7829   cat >>confdefs.h <<_ACEOF
7830 #define HAVE_LIBGEN_H 1
7831 _ACEOF
7832
7833 fi
7834
7835 done
7836
7837                 fi
7838
7839 fi
7840
7841
7842 fi
7843 done
7844
7845
7846 ac_fn_c_check_func "$LINENO" "getspnam" "ac_cv_func_getspnam"
7847 if test "x$ac_cv_func_getspnam" = x""yes; then :
7848
7849 else
7850   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getspnam in -lgen" >&5
7851 $as_echo_n "checking for getspnam in -lgen... " >&6; }
7852 if test "${ac_cv_lib_gen_getspnam+set}" = set; then :
7853   $as_echo_n "(cached) " >&6
7854 else
7855   ac_check_lib_save_LIBS=$LIBS
7856 LIBS="-lgen  $LIBS"
7857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7858 /* end confdefs.h.  */
7859
7860 /* Override any GCC internal prototype to avoid an error.
7861    Use char because int might match the return type of a GCC
7862    builtin and then its argument prototype would still apply.  */
7863 #ifdef __cplusplus
7864 extern "C"
7865 #endif
7866 char getspnam ();
7867 int
7868 main ()
7869 {
7870 return getspnam ();
7871   ;
7872   return 0;
7873 }
7874 _ACEOF
7875 if ac_fn_c_try_link "$LINENO"; then :
7876   ac_cv_lib_gen_getspnam=yes
7877 else
7878   ac_cv_lib_gen_getspnam=no
7879 fi
7880 rm -f core conftest.err conftest.$ac_objext \
7881     conftest$ac_exeext conftest.$ac_ext
7882 LIBS=$ac_check_lib_save_LIBS
7883 fi
7884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gen_getspnam" >&5
7885 $as_echo "$ac_cv_lib_gen_getspnam" >&6; }
7886 if test "x$ac_cv_lib_gen_getspnam" = x""yes; then :
7887   LIBS="$LIBS -lgen"
7888 fi
7889
7890 fi
7891
7892 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing basename" >&5
7893 $as_echo_n "checking for library containing basename... " >&6; }
7894 if test "${ac_cv_search_basename+set}" = set; then :
7895   $as_echo_n "(cached) " >&6
7896 else
7897   ac_func_search_save_LIBS=$LIBS
7898 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7899 /* end confdefs.h.  */
7900
7901 /* Override any GCC internal prototype to avoid an error.
7902    Use char because int might match the return type of a GCC
7903    builtin and then its argument prototype would still apply.  */
7904 #ifdef __cplusplus
7905 extern "C"
7906 #endif
7907 char basename ();
7908 int
7909 main ()
7910 {
7911 return basename ();
7912   ;
7913   return 0;
7914 }
7915 _ACEOF
7916 for ac_lib in '' gen; do
7917   if test -z "$ac_lib"; then
7918     ac_res="none required"
7919   else
7920     ac_res=-l$ac_lib
7921     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7922   fi
7923   if ac_fn_c_try_link "$LINENO"; then :
7924   ac_cv_search_basename=$ac_res
7925 fi
7926 rm -f core conftest.err conftest.$ac_objext \
7927     conftest$ac_exeext
7928   if test "${ac_cv_search_basename+set}" = set; then :
7929   break
7930 fi
7931 done
7932 if test "${ac_cv_search_basename+set}" = set; then :
7933
7934 else
7935   ac_cv_search_basename=no
7936 fi
7937 rm conftest.$ac_ext
7938 LIBS=$ac_func_search_save_LIBS
7939 fi
7940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_basename" >&5
7941 $as_echo "$ac_cv_search_basename" >&6; }
7942 ac_res=$ac_cv_search_basename
7943 if test "$ac_res" != no; then :
7944   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7945
7946 $as_echo "#define HAVE_BASENAME 1" >>confdefs.h
7947
7948 fi
7949
7950
7951
7952 # Check whether --with-zlib was given.
7953 if test "${with_zlib+set}" = set; then :
7954   withval=$with_zlib;  if test "x$withval" = "xno" ; then
7955                 as_fn_error $? "*** zlib is required ***" "$LINENO" 5
7956           elif test "x$withval" != "xyes"; then
7957                 if test -d "$withval/lib"; then
7958                         if test -n "${need_dash_r}"; then
7959                                 LDFLAGS="-L${withval}/lib -R${withval}/lib ${LDFLAGS}"
7960                         else
7961                                 LDFLAGS="-L${withval}/lib ${LDFLAGS}"
7962                         fi
7963                 else
7964                         if test -n "${need_dash_r}"; then
7965                                 LDFLAGS="-L${withval} -R${withval} ${LDFLAGS}"
7966                         else
7967                                 LDFLAGS="-L${withval} ${LDFLAGS}"
7968                         fi
7969                 fi
7970                 if test -d "$withval/include"; then
7971                         CPPFLAGS="-I${withval}/include ${CPPFLAGS}"
7972                 else
7973                         CPPFLAGS="-I${withval} ${CPPFLAGS}"
7974                 fi
7975         fi
7976
7977 fi
7978
7979
7980 ac_fn_c_check_header_mongrel "$LINENO" "zlib.h" "ac_cv_header_zlib_h" "$ac_includes_default"
7981 if test "x$ac_cv_header_zlib_h" = x""yes; then :
7982
7983 else
7984   as_fn_error $? "*** zlib.h missing - please install first or check config.log ***" "$LINENO" 5
7985 fi
7986
7987
7988 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for deflate in -lz" >&5
7989 $as_echo_n "checking for deflate in -lz... " >&6; }
7990 if test "${ac_cv_lib_z_deflate+set}" = set; then :
7991   $as_echo_n "(cached) " >&6
7992 else
7993   ac_check_lib_save_LIBS=$LIBS
7994 LIBS="-lz  $LIBS"
7995 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
7996 /* end confdefs.h.  */
7997
7998 /* Override any GCC internal prototype to avoid an error.
7999    Use char because int might match the return type of a GCC
8000    builtin and then its argument prototype would still apply.  */
8001 #ifdef __cplusplus
8002 extern "C"
8003 #endif
8004 char deflate ();
8005 int
8006 main ()
8007 {
8008 return deflate ();
8009   ;
8010   return 0;
8011 }
8012 _ACEOF
8013 if ac_fn_c_try_link "$LINENO"; then :
8014   ac_cv_lib_z_deflate=yes
8015 else
8016   ac_cv_lib_z_deflate=no
8017 fi
8018 rm -f core conftest.err conftest.$ac_objext \
8019     conftest$ac_exeext conftest.$ac_ext
8020 LIBS=$ac_check_lib_save_LIBS
8021 fi
8022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_deflate" >&5
8023 $as_echo "$ac_cv_lib_z_deflate" >&6; }
8024 if test "x$ac_cv_lib_z_deflate" = x""yes; then :
8025   cat >>confdefs.h <<_ACEOF
8026 #define HAVE_LIBZ 1
8027 _ACEOF
8028
8029   LIBS="-lz $LIBS"
8030
8031 else
8032
8033                 saved_CPPFLAGS="$CPPFLAGS"
8034                 saved_LDFLAGS="$LDFLAGS"
8035                 save_LIBS="$LIBS"
8036                                 if test -n "${need_dash_r}"; then
8037                         LDFLAGS="-L/usr/local/lib -R/usr/local/lib ${saved_LDFLAGS}"
8038                 else
8039                         LDFLAGS="-L/usr/local/lib ${saved_LDFLAGS}"
8040                 fi
8041                 CPPFLAGS="-I/usr/local/include ${saved_CPPFLAGS}"
8042                 LIBS="$LIBS -lz"
8043                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8044 /* end confdefs.h.  */
8045
8046 /* Override any GCC internal prototype to avoid an error.
8047    Use char because int might match the return type of a GCC
8048    builtin and then its argument prototype would still apply.  */
8049 #ifdef __cplusplus
8050 extern "C"
8051 #endif
8052 char deflate ();
8053 int
8054 main ()
8055 {
8056 return deflate ();
8057   ;
8058   return 0;
8059 }
8060 _ACEOF
8061 if ac_fn_c_try_link "$LINENO"; then :
8062   $as_echo "#define HAVE_LIBZ 1" >>confdefs.h
8063
8064 else
8065
8066                                 as_fn_error $? "*** zlib missing - please install first or check config.log ***" "$LINENO" 5
8067
8068
8069 fi
8070 rm -f core conftest.err conftest.$ac_objext \
8071     conftest$ac_exeext conftest.$ac_ext
8072
8073
8074 fi
8075
8076
8077
8078 # Check whether --with-zlib-version-check was given.
8079 if test "${with_zlib_version_check+set}" = set; then :
8080   withval=$with_zlib_version_check;   if test "x$withval" = "xno" ; then
8081                 zlib_check_nonfatal=1
8082            fi
8083
8084
8085 fi
8086
8087
8088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for possibly buggy zlib" >&5
8089 $as_echo_n "checking for possibly buggy zlib... " >&6; }
8090 if test "$cross_compiling" = yes; then :
8091         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking zlib version" >&5
8092 $as_echo "$as_me: WARNING: cross compiling: not checking zlib version" >&2;}
8093
8094 else
8095   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8096 /* end confdefs.h.  */
8097
8098 #include <stdio.h>
8099 #include <zlib.h>
8100
8101 int
8102 main ()
8103 {
8104
8105         int a=0, b=0, c=0, d=0, n, v;
8106         n = sscanf(ZLIB_VERSION, "%d.%d.%d.%d", &a, &b, &c, &d);
8107         if (n != 3 && n != 4)
8108                 exit(1);
8109         v = a*1000000 + b*10000 + c*100 + d;
8110         fprintf(stderr, "found zlib version %s (%d)\n", ZLIB_VERSION, v);
8111
8112         /* 1.1.4 is OK */
8113         if (a == 1 && b == 1 && c >= 4)
8114                 exit(0);
8115
8116         /* 1.2.3 and up are OK */
8117         if (v >= 1020300)
8118                 exit(0);
8119
8120         exit(2);
8121
8122   ;
8123   return 0;
8124 }
8125 _ACEOF
8126 if ac_fn_c_try_run "$LINENO"; then :
8127   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8128 $as_echo "no" >&6; }
8129 else
8130    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8131 $as_echo "yes" >&6; }
8132           if test -z "$zlib_check_nonfatal" ; then
8133                 as_fn_error $? "*** zlib too old - check config.log ***
8134 Your reported zlib version has known security problems.  It's possible your
8135 vendor has fixed these problems without changing the version number.  If you
8136 are sure this is the case, you can disable the check by running
8137 \"./configure --without-zlib-version-check\".
8138 If you are in doubt, upgrade zlib to version 1.2.3 or greater.
8139 See http://www.gzip.org/zlib/ for details." "$LINENO" 5
8140           else
8141                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: zlib version may have security problems" >&5
8142 $as_echo "$as_me: WARNING: zlib version may have security problems" >&2;}
8143           fi
8144
8145 fi
8146 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8147   conftest.$ac_objext conftest.beam conftest.$ac_ext
8148 fi
8149
8150
8151 ac_fn_c_check_func "$LINENO" "strcasecmp" "ac_cv_func_strcasecmp"
8152 if test "x$ac_cv_func_strcasecmp" = x""yes; then :
8153
8154 else
8155    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strcasecmp in -lresolv" >&5
8156 $as_echo_n "checking for strcasecmp in -lresolv... " >&6; }
8157 if test "${ac_cv_lib_resolv_strcasecmp+set}" = set; then :
8158   $as_echo_n "(cached) " >&6
8159 else
8160   ac_check_lib_save_LIBS=$LIBS
8161 LIBS="-lresolv  $LIBS"
8162 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8163 /* end confdefs.h.  */
8164
8165 /* Override any GCC internal prototype to avoid an error.
8166    Use char because int might match the return type of a GCC
8167    builtin and then its argument prototype would still apply.  */
8168 #ifdef __cplusplus
8169 extern "C"
8170 #endif
8171 char strcasecmp ();
8172 int
8173 main ()
8174 {
8175 return strcasecmp ();
8176   ;
8177   return 0;
8178 }
8179 _ACEOF
8180 if ac_fn_c_try_link "$LINENO"; then :
8181   ac_cv_lib_resolv_strcasecmp=yes
8182 else
8183   ac_cv_lib_resolv_strcasecmp=no
8184 fi
8185 rm -f core conftest.err conftest.$ac_objext \
8186     conftest$ac_exeext conftest.$ac_ext
8187 LIBS=$ac_check_lib_save_LIBS
8188 fi
8189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_resolv_strcasecmp" >&5
8190 $as_echo "$ac_cv_lib_resolv_strcasecmp" >&6; }
8191 if test "x$ac_cv_lib_resolv_strcasecmp" = x""yes; then :
8192   LIBS="$LIBS -lresolv"
8193 fi
8194
8195
8196 fi
8197
8198 for ac_func in utimes
8199 do :
8200   ac_fn_c_check_func "$LINENO" "utimes" "ac_cv_func_utimes"
8201 if test "x$ac_cv_func_utimes" = x""yes; then :
8202   cat >>confdefs.h <<_ACEOF
8203 #define HAVE_UTIMES 1
8204 _ACEOF
8205
8206 else
8207    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for utimes in -lc89" >&5
8208 $as_echo_n "checking for utimes in -lc89... " >&6; }
8209 if test "${ac_cv_lib_c89_utimes+set}" = set; then :
8210   $as_echo_n "(cached) " >&6
8211 else
8212   ac_check_lib_save_LIBS=$LIBS
8213 LIBS="-lc89  $LIBS"
8214 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8215 /* end confdefs.h.  */
8216
8217 /* Override any GCC internal prototype to avoid an error.
8218    Use char because int might match the return type of a GCC
8219    builtin and then its argument prototype would still apply.  */
8220 #ifdef __cplusplus
8221 extern "C"
8222 #endif
8223 char utimes ();
8224 int
8225 main ()
8226 {
8227 return utimes ();
8228   ;
8229   return 0;
8230 }
8231 _ACEOF
8232 if ac_fn_c_try_link "$LINENO"; then :
8233   ac_cv_lib_c89_utimes=yes
8234 else
8235   ac_cv_lib_c89_utimes=no
8236 fi
8237 rm -f core conftest.err conftest.$ac_objext \
8238     conftest$ac_exeext conftest.$ac_ext
8239 LIBS=$ac_check_lib_save_LIBS
8240 fi
8241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_c89_utimes" >&5
8242 $as_echo "$ac_cv_lib_c89_utimes" >&6; }
8243 if test "x$ac_cv_lib_c89_utimes" = x""yes; then :
8244   $as_echo "#define HAVE_UTIMES 1" >>confdefs.h
8245
8246                                         LIBS="$LIBS -lc89"
8247 fi
8248
8249
8250 fi
8251 done
8252
8253
8254 for ac_header in libutil.h
8255 do :
8256   ac_fn_c_check_header_mongrel "$LINENO" "libutil.h" "ac_cv_header_libutil_h" "$ac_includes_default"
8257 if test "x$ac_cv_header_libutil_h" = x""yes; then :
8258   cat >>confdefs.h <<_ACEOF
8259 #define HAVE_LIBUTIL_H 1
8260 _ACEOF
8261
8262 fi
8263
8264 done
8265
8266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing login" >&5
8267 $as_echo_n "checking for library containing login... " >&6; }
8268 if test "${ac_cv_search_login+set}" = set; then :
8269   $as_echo_n "(cached) " >&6
8270 else
8271   ac_func_search_save_LIBS=$LIBS
8272 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8273 /* end confdefs.h.  */
8274
8275 /* Override any GCC internal prototype to avoid an error.
8276    Use char because int might match the return type of a GCC
8277    builtin and then its argument prototype would still apply.  */
8278 #ifdef __cplusplus
8279 extern "C"
8280 #endif
8281 char login ();
8282 int
8283 main ()
8284 {
8285 return login ();
8286   ;
8287   return 0;
8288 }
8289 _ACEOF
8290 for ac_lib in '' util bsd; do
8291   if test -z "$ac_lib"; then
8292     ac_res="none required"
8293   else
8294     ac_res=-l$ac_lib
8295     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8296   fi
8297   if ac_fn_c_try_link "$LINENO"; then :
8298   ac_cv_search_login=$ac_res
8299 fi
8300 rm -f core conftest.err conftest.$ac_objext \
8301     conftest$ac_exeext
8302   if test "${ac_cv_search_login+set}" = set; then :
8303   break
8304 fi
8305 done
8306 if test "${ac_cv_search_login+set}" = set; then :
8307
8308 else
8309   ac_cv_search_login=no
8310 fi
8311 rm conftest.$ac_ext
8312 LIBS=$ac_func_search_save_LIBS
8313 fi
8314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_login" >&5
8315 $as_echo "$ac_cv_search_login" >&6; }
8316 ac_res=$ac_cv_search_login
8317 if test "$ac_res" != no; then :
8318   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8319
8320 $as_echo "#define HAVE_LOGIN 1" >>confdefs.h
8321
8322 fi
8323
8324 for ac_func in fmt_scaled logout updwtmp logwtmp
8325 do :
8326   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8327 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8328 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8329   cat >>confdefs.h <<_ACEOF
8330 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8331 _ACEOF
8332
8333 fi
8334 done
8335
8336
8337 for ac_func in strftime
8338 do :
8339   ac_fn_c_check_func "$LINENO" "strftime" "ac_cv_func_strftime"
8340 if test "x$ac_cv_func_strftime" = x""yes; then :
8341   cat >>confdefs.h <<_ACEOF
8342 #define HAVE_STRFTIME 1
8343 _ACEOF
8344
8345 else
8346   # strftime is in -lintl on SCO UNIX.
8347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for strftime in -lintl" >&5
8348 $as_echo_n "checking for strftime in -lintl... " >&6; }
8349 if test "${ac_cv_lib_intl_strftime+set}" = set; then :
8350   $as_echo_n "(cached) " >&6
8351 else
8352   ac_check_lib_save_LIBS=$LIBS
8353 LIBS="-lintl  $LIBS"
8354 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8355 /* end confdefs.h.  */
8356
8357 /* Override any GCC internal prototype to avoid an error.
8358    Use char because int might match the return type of a GCC
8359    builtin and then its argument prototype would still apply.  */
8360 #ifdef __cplusplus
8361 extern "C"
8362 #endif
8363 char strftime ();
8364 int
8365 main ()
8366 {
8367 return strftime ();
8368   ;
8369   return 0;
8370 }
8371 _ACEOF
8372 if ac_fn_c_try_link "$LINENO"; then :
8373   ac_cv_lib_intl_strftime=yes
8374 else
8375   ac_cv_lib_intl_strftime=no
8376 fi
8377 rm -f core conftest.err conftest.$ac_objext \
8378     conftest$ac_exeext conftest.$ac_ext
8379 LIBS=$ac_check_lib_save_LIBS
8380 fi
8381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_intl_strftime" >&5
8382 $as_echo "$ac_cv_lib_intl_strftime" >&6; }
8383 if test "x$ac_cv_lib_intl_strftime" = x""yes; then :
8384   $as_echo "#define HAVE_STRFTIME 1" >>confdefs.h
8385
8386 LIBS="-lintl $LIBS"
8387 fi
8388
8389 fi
8390 done
8391
8392
8393 # Check for ALTDIRFUNC glob() extension
8394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GLOB_ALTDIRFUNC support" >&5
8395 $as_echo_n "checking for GLOB_ALTDIRFUNC support... " >&6; }
8396 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8397 /* end confdefs.h.  */
8398
8399                 #include <glob.h>
8400                 #ifdef GLOB_ALTDIRFUNC
8401                 FOUNDIT
8402                 #endif
8403
8404 _ACEOF
8405 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
8406   $EGREP "FOUNDIT" >/dev/null 2>&1; then :
8407
8408
8409 $as_echo "#define GLOB_HAS_ALTDIRFUNC 1" >>confdefs.h
8410
8411                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8412 $as_echo "yes" >&6; }
8413
8414 else
8415
8416                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8417 $as_echo "no" >&6; }
8418
8419
8420 fi
8421 rm -f conftest*
8422
8423
8424 # Check for g.gl_matchc glob() extension
8425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gl_matchc field in glob_t" >&5
8426 $as_echo_n "checking for gl_matchc field in glob_t... " >&6; }
8427 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8428 /* end confdefs.h.  */
8429  #include <glob.h>
8430 int
8431 main ()
8432 {
8433  glob_t g; g.gl_matchc = 1;
8434   ;
8435   return 0;
8436 }
8437 _ACEOF
8438 if ac_fn_c_try_compile "$LINENO"; then :
8439
8440
8441 $as_echo "#define GLOB_HAS_GL_MATCHC 1" >>confdefs.h
8442
8443                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8444 $as_echo "yes" >&6; }
8445
8446 else
8447
8448                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8449 $as_echo "no" >&6; }
8450
8451 fi
8452 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8453
8454 # Check for g.gl_statv glob() extension
8455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gl_statv and GLOB_KEEPSTAT extensions for glob" >&5
8456 $as_echo_n "checking for gl_statv and GLOB_KEEPSTAT extensions for glob... " >&6; }
8457 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8458 /* end confdefs.h.  */
8459  #include <glob.h>
8460 int
8461 main ()
8462 {
8463
8464 #ifndef GLOB_KEEPSTAT
8465 #error "glob does not support GLOB_KEEPSTAT extension"
8466 #endif
8467 glob_t g;
8468 g.gl_statv = NULL;
8469
8470   ;
8471   return 0;
8472 }
8473 _ACEOF
8474 if ac_fn_c_try_compile "$LINENO"; then :
8475
8476
8477 $as_echo "#define GLOB_HAS_GL_STATV 1" >>confdefs.h
8478
8479                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8480 $as_echo "yes" >&6; }
8481
8482 else
8483
8484                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8485 $as_echo "no" >&6; }
8486
8487
8488 fi
8489 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8490
8491 ac_fn_c_check_decl "$LINENO" "GLOB_NOMATCH" "ac_cv_have_decl_GLOB_NOMATCH" "#include <glob.h>
8492 "
8493 if test "x$ac_cv_have_decl_GLOB_NOMATCH" = x""yes; then :
8494   ac_have_decl=1
8495 else
8496   ac_have_decl=0
8497 fi
8498
8499 cat >>confdefs.h <<_ACEOF
8500 #define HAVE_DECL_GLOB_NOMATCH $ac_have_decl
8501 _ACEOF
8502
8503
8504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether struct dirent allocates space for d_name" >&5
8505 $as_echo_n "checking whether struct dirent allocates space for d_name... " >&6; }
8506 if test "$cross_compiling" = yes; then :
8507
8508                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: assuming BROKEN_ONE_BYTE_DIRENT_D_NAME" >&5
8509 $as_echo "$as_me: WARNING: cross compiling: assuming BROKEN_ONE_BYTE_DIRENT_D_NAME" >&2;}
8510                 $as_echo "#define BROKEN_ONE_BYTE_DIRENT_D_NAME 1" >>confdefs.h
8511
8512
8513
8514 else
8515   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8516 /* end confdefs.h.  */
8517
8518 #include <sys/types.h>
8519 #include <dirent.h>
8520 int
8521 main ()
8522 {
8523
8524         struct dirent d;
8525         exit(sizeof(d.d_name)<=sizeof(char));
8526
8527   ;
8528   return 0;
8529 }
8530 _ACEOF
8531 if ac_fn_c_try_run "$LINENO"; then :
8532   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8533 $as_echo "yes" >&6; }
8534 else
8535
8536                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8537 $as_echo "no" >&6; }
8538
8539 $as_echo "#define BROKEN_ONE_BYTE_DIRENT_D_NAME 1" >>confdefs.h
8540
8541
8542 fi
8543 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
8544   conftest.$ac_objext conftest.beam conftest.$ac_ext
8545 fi
8546
8547
8548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for /proc/pid/fd directory" >&5
8549 $as_echo_n "checking for /proc/pid/fd directory... " >&6; }
8550 if test -d "/proc/$$/fd" ; then
8551
8552 $as_echo "#define HAVE_PROC_PID 1" >>confdefs.h
8553
8554         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8555 $as_echo "yes" >&6; }
8556 else
8557         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8558 $as_echo "no" >&6; }
8559 fi
8560
8561 # Check whether user wants S/Key support
8562 SKEY_MSG="no"
8563
8564 # Check whether --with-skey was given.
8565 if test "${with_skey+set}" = set; then :
8566   withval=$with_skey;
8567                 if test "x$withval" != "xno" ; then
8568
8569                         if test "x$withval" != "xyes" ; then
8570                                 CPPFLAGS="$CPPFLAGS -I${withval}/include"
8571                                 LDFLAGS="$LDFLAGS -L${withval}/lib"
8572                         fi
8573
8574
8575 $as_echo "#define SKEY 1" >>confdefs.h
8576
8577                         LIBS="-lskey $LIBS"
8578                         SKEY_MSG="yes"
8579
8580                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for s/key support" >&5
8581 $as_echo_n "checking for s/key support... " >&6; }
8582                         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8583 /* end confdefs.h.  */
8584
8585 #include <stdio.h>
8586 #include <skey.h>
8587
8588 int
8589 main ()
8590 {
8591
8592         char *ff = skey_keyinfo(""); ff="";
8593         exit(0);
8594
8595   ;
8596   return 0;
8597 }
8598 _ACEOF
8599 if ac_fn_c_try_link "$LINENO"; then :
8600   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8601 $as_echo "yes" >&6; }
8602 else
8603
8604                                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8605 $as_echo "no" >&6; }
8606                                         as_fn_error $? "** Incomplete or missing s/key libraries." "$LINENO" 5
8607
8608 fi
8609 rm -f core conftest.err conftest.$ac_objext \
8610     conftest$ac_exeext conftest.$ac_ext
8611                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if skeychallenge takes 4 arguments" >&5
8612 $as_echo_n "checking if skeychallenge takes 4 arguments... " >&6; }
8613                         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8614 /* end confdefs.h.  */
8615
8616 #include <stdio.h>
8617 #include <skey.h>
8618
8619 int
8620 main ()
8621 {
8622
8623         (void)skeychallenge(NULL,"name","",0);
8624
8625   ;
8626   return 0;
8627 }
8628 _ACEOF
8629 if ac_fn_c_try_compile "$LINENO"; then :
8630
8631                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8632 $as_echo "yes" >&6; }
8633
8634 $as_echo "#define SKEYCHALLENGE_4ARG 1" >>confdefs.h
8635
8636 else
8637
8638                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8639 $as_echo "no" >&6; }
8640
8641 fi
8642 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8643                 fi
8644
8645
8646 fi
8647
8648
8649 # Check whether user wants TCP wrappers support
8650 TCPW_MSG="no"
8651
8652 # Check whether --with-tcp-wrappers was given.
8653 if test "${with_tcp_wrappers+set}" = set; then :
8654   withval=$with_tcp_wrappers;
8655                 if test "x$withval" != "xno" ; then
8656                         saved_LIBS="$LIBS"
8657                         saved_LDFLAGS="$LDFLAGS"
8658                         saved_CPPFLAGS="$CPPFLAGS"
8659                         if test -n "${withval}" && \
8660                             test "x${withval}" != "xyes"; then
8661                                 if test -d "${withval}/lib"; then
8662                                         if test -n "${need_dash_r}"; then
8663                                                 LDFLAGS="-L${withval}/lib -R${withval}/lib ${LDFLAGS}"
8664                                         else
8665                                                 LDFLAGS="-L${withval}/lib ${LDFLAGS}"
8666                                         fi
8667                                 else
8668                                         if test -n "${need_dash_r}"; then
8669                                                 LDFLAGS="-L${withval} -R${withval} ${LDFLAGS}"
8670                                         else
8671                                                 LDFLAGS="-L${withval} ${LDFLAGS}"
8672                                         fi
8673                                 fi
8674                                 if test -d "${withval}/include"; then
8675                                         CPPFLAGS="-I${withval}/include ${CPPFLAGS}"
8676                                 else
8677                                         CPPFLAGS="-I${withval} ${CPPFLAGS}"
8678                                 fi
8679                         fi
8680                         LIBS="-lwrap $LIBS"
8681                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libwrap" >&5
8682 $as_echo_n "checking for libwrap... " >&6; }
8683                         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8684 /* end confdefs.h.  */
8685
8686 #include <sys/types.h>
8687 #include <sys/socket.h>
8688 #include <netinet/in.h>
8689 #include <tcpd.h>
8690 int deny_severity = 0, allow_severity = 0;
8691
8692 int
8693 main ()
8694 {
8695
8696         hosts_access(0);
8697
8698   ;
8699   return 0;
8700 }
8701 _ACEOF
8702 if ac_fn_c_try_link "$LINENO"; then :
8703
8704                                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8705 $as_echo "yes" >&6; }
8706
8707 $as_echo "#define LIBWRAP 1" >>confdefs.h
8708
8709                                         SSHDLIBS="$SSHDLIBS -lwrap"
8710                                         TCPW_MSG="yes"
8711
8712 else
8713
8714                                         as_fn_error $? "*** libwrap missing" "$LINENO" 5
8715
8716
8717 fi
8718 rm -f core conftest.err conftest.$ac_objext \
8719     conftest$ac_exeext conftest.$ac_ext
8720                         LIBS="$saved_LIBS"
8721                 fi
8722
8723
8724 fi
8725
8726
8727 # Check whether user wants libedit support
8728 LIBEDIT_MSG="no"
8729
8730 # Check whether --with-libedit was given.
8731 if test "${with_libedit+set}" = set; then :
8732   withval=$with_libedit;  if test "x$withval" != "xno" ; then
8733                 if test "x$withval" = "xyes" ; then
8734                         # Extract the first word of "pkg-config", so it can be a program name with args.
8735 set dummy pkg-config; ac_word=$2
8736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
8737 $as_echo_n "checking for $ac_word... " >&6; }
8738 if test "${ac_cv_path_PKGCONFIG+set}" = set; then :
8739   $as_echo_n "(cached) " >&6
8740 else
8741   case $PKGCONFIG in
8742   [\\/]* | ?:[\\/]*)
8743   ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
8744   ;;
8745   *)
8746   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
8747 for as_dir in $PATH
8748 do
8749   IFS=$as_save_IFS
8750   test -z "$as_dir" && as_dir=.
8751     for ac_exec_ext in '' $ac_executable_extensions; do
8752   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
8753     ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
8754     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
8755     break 2
8756   fi
8757 done
8758   done
8759 IFS=$as_save_IFS
8760
8761   test -z "$ac_cv_path_PKGCONFIG" && ac_cv_path_PKGCONFIG="no"
8762   ;;
8763 esac
8764 fi
8765 PKGCONFIG=$ac_cv_path_PKGCONFIG
8766 if test -n "$PKGCONFIG"; then
8767   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGCONFIG" >&5
8768 $as_echo "$PKGCONFIG" >&6; }
8769 else
8770   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8771 $as_echo "no" >&6; }
8772 fi
8773
8774
8775                         if test "x$PKGCONFIG" != "xno"; then
8776                                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if $PKGCONFIG knows about libedit" >&5
8777 $as_echo_n "checking if $PKGCONFIG knows about libedit... " >&6; }
8778                                 if "$PKGCONFIG" libedit; then
8779                                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8780 $as_echo "yes" >&6; }
8781                                         use_pkgconfig_for_libedit=yes
8782                                 else
8783                                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8784 $as_echo "no" >&6; }
8785                                 fi
8786                         fi
8787                 else
8788                         CPPFLAGS="$CPPFLAGS -I${withval}/include"
8789                         if test -n "${need_dash_r}"; then
8790                                 LDFLAGS="-L${withval}/lib -R${withval}/lib ${LDFLAGS}"
8791                         else
8792                                 LDFLAGS="-L${withval}/lib ${LDFLAGS}"
8793                         fi
8794                 fi
8795                 if test "x$use_pkgconfig_for_libedit" = "xyes"; then
8796                         LIBEDIT=`$PKGCONFIG --libs-only-l libedit`
8797                         CPPFLAGS="$CPPFLAGS `$PKGCONFIG --cflags libedit`"
8798                 else
8799                         LIBEDIT="-ledit -lcurses"
8800                 fi
8801                 OTHERLIBS=`echo $LIBEDIT | sed 's/-ledit//'`
8802                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for el_init in -ledit" >&5
8803 $as_echo_n "checking for el_init in -ledit... " >&6; }
8804 if test "${ac_cv_lib_edit_el_init+set}" = set; then :
8805   $as_echo_n "(cached) " >&6
8806 else
8807   ac_check_lib_save_LIBS=$LIBS
8808 LIBS="-ledit  $OTHERLIBS
8809                  $LIBS"
8810 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8811 /* end confdefs.h.  */
8812
8813 /* Override any GCC internal prototype to avoid an error.
8814    Use char because int might match the return type of a GCC
8815    builtin and then its argument prototype would still apply.  */
8816 #ifdef __cplusplus
8817 extern "C"
8818 #endif
8819 char el_init ();
8820 int
8821 main ()
8822 {
8823 return el_init ();
8824   ;
8825   return 0;
8826 }
8827 _ACEOF
8828 if ac_fn_c_try_link "$LINENO"; then :
8829   ac_cv_lib_edit_el_init=yes
8830 else
8831   ac_cv_lib_edit_el_init=no
8832 fi
8833 rm -f core conftest.err conftest.$ac_objext \
8834     conftest$ac_exeext conftest.$ac_ext
8835 LIBS=$ac_check_lib_save_LIBS
8836 fi
8837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_edit_el_init" >&5
8838 $as_echo "$ac_cv_lib_edit_el_init" >&6; }
8839 if test "x$ac_cv_lib_edit_el_init" = x""yes; then :
8840
8841 $as_echo "#define USE_LIBEDIT 1" >>confdefs.h
8842
8843                           LIBEDIT_MSG="yes"
8844
8845
8846 else
8847    as_fn_error $? "libedit not found" "$LINENO" 5
8848 fi
8849
8850                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libedit version is compatible" >&5
8851 $as_echo_n "checking if libedit version is compatible... " >&6; }
8852                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8853 /* end confdefs.h.  */
8854  #include <histedit.h>
8855 int
8856 main ()
8857 {
8858
8859         int i = H_SETSIZE;
8860         el_init("", NULL, NULL, NULL);
8861         exit(0);
8862
8863   ;
8864   return 0;
8865 }
8866 _ACEOF
8867 if ac_fn_c_try_compile "$LINENO"; then :
8868    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
8869 $as_echo "yes" >&6; }
8870 else
8871    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
8872 $as_echo "no" >&6; }
8873                       as_fn_error $? "libedit version is not compatible" "$LINENO" 5
8874
8875 fi
8876 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8877         fi
8878
8879 fi
8880
8881
8882 AUDIT_MODULE=none
8883
8884 # Check whether --with-audit was given.
8885 if test "${with_audit+set}" = set; then :
8886   withval=$with_audit;
8887           { $as_echo "$as_me:${as_lineno-$LINENO}: checking for supported audit module" >&5
8888 $as_echo_n "checking for supported audit module... " >&6; }
8889           case "$withval" in
8890           bsm)
8891                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bsm" >&5
8892 $as_echo "bsm" >&6; }
8893                 AUDIT_MODULE=bsm
8894                                 for ac_header in bsm/audit.h
8895 do :
8896   ac_fn_c_check_header_compile "$LINENO" "bsm/audit.h" "ac_cv_header_bsm_audit_h" "
8897 #ifdef HAVE_TIME_H
8898 # include <time.h>
8899 #endif
8900
8901
8902 "
8903 if test "x$ac_cv_header_bsm_audit_h" = x""yes; then :
8904   cat >>confdefs.h <<_ACEOF
8905 #define HAVE_BSM_AUDIT_H 1
8906 _ACEOF
8907
8908 else
8909   as_fn_error $? "BSM enabled and bsm/audit.h not found" "$LINENO" 5
8910 fi
8911
8912 done
8913
8914                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getaudit in -lbsm" >&5
8915 $as_echo_n "checking for getaudit in -lbsm... " >&6; }
8916 if test "${ac_cv_lib_bsm_getaudit+set}" = set; then :
8917   $as_echo_n "(cached) " >&6
8918 else
8919   ac_check_lib_save_LIBS=$LIBS
8920 LIBS="-lbsm  $LIBS"
8921 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
8922 /* end confdefs.h.  */
8923
8924 /* Override any GCC internal prototype to avoid an error.
8925    Use char because int might match the return type of a GCC
8926    builtin and then its argument prototype would still apply.  */
8927 #ifdef __cplusplus
8928 extern "C"
8929 #endif
8930 char getaudit ();
8931 int
8932 main ()
8933 {
8934 return getaudit ();
8935   ;
8936   return 0;
8937 }
8938 _ACEOF
8939 if ac_fn_c_try_link "$LINENO"; then :
8940   ac_cv_lib_bsm_getaudit=yes
8941 else
8942   ac_cv_lib_bsm_getaudit=no
8943 fi
8944 rm -f core conftest.err conftest.$ac_objext \
8945     conftest$ac_exeext conftest.$ac_ext
8946 LIBS=$ac_check_lib_save_LIBS
8947 fi
8948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsm_getaudit" >&5
8949 $as_echo "$ac_cv_lib_bsm_getaudit" >&6; }
8950 if test "x$ac_cv_lib_bsm_getaudit" = x""yes; then :
8951   cat >>confdefs.h <<_ACEOF
8952 #define HAVE_LIBBSM 1
8953 _ACEOF
8954
8955   LIBS="-lbsm $LIBS"
8956
8957 else
8958   as_fn_error $? "BSM enabled and required library not found" "$LINENO" 5
8959 fi
8960
8961                 for ac_func in getaudit
8962 do :
8963   ac_fn_c_check_func "$LINENO" "getaudit" "ac_cv_func_getaudit"
8964 if test "x$ac_cv_func_getaudit" = x""yes; then :
8965   cat >>confdefs.h <<_ACEOF
8966 #define HAVE_GETAUDIT 1
8967 _ACEOF
8968
8969 else
8970   as_fn_error $? "BSM enabled and required function not found" "$LINENO" 5
8971 fi
8972 done
8973
8974                 # These are optional
8975                 for ac_func in getaudit_addr aug_get_machine
8976 do :
8977   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
8978 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
8979 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
8980   cat >>confdefs.h <<_ACEOF
8981 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
8982 _ACEOF
8983
8984 fi
8985 done
8986
8987
8988 $as_echo "#define USE_BSM_AUDIT 1" >>confdefs.h
8989
8990                 ;;
8991           linux)
8992                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: linux" >&5
8993 $as_echo "linux" >&6; }
8994                 AUDIT_MODULE=linux
8995                                 for ac_header in libaudit.h
8996 do :
8997   ac_fn_c_check_header_mongrel "$LINENO" "libaudit.h" "ac_cv_header_libaudit_h" "$ac_includes_default"
8998 if test "x$ac_cv_header_libaudit_h" = x""yes; then :
8999   cat >>confdefs.h <<_ACEOF
9000 #define HAVE_LIBAUDIT_H 1
9001 _ACEOF
9002
9003 fi
9004
9005 done
9006
9007                 SSHDLIBS="$SSHDLIBS -laudit"
9008
9009 $as_echo "#define USE_LINUX_AUDIT 1" >>confdefs.h
9010
9011                 ;;
9012           debug)
9013                 AUDIT_MODULE=debug
9014                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: debug" >&5
9015 $as_echo "debug" >&6; }
9016
9017 $as_echo "#define SSH_AUDIT_EVENTS 1" >>confdefs.h
9018
9019                 ;;
9020           no)
9021                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9022 $as_echo "no" >&6; }
9023                 ;;
9024           *)
9025                 as_fn_error $? "Unknown audit module $withval" "$LINENO" 5
9026                 ;;
9027         esac
9028
9029 fi
9030
9031
9032 for ac_func in  \
9033         arc4random \
9034         arc4random_buf \
9035         arc4random_uniform \
9036         asprintf \
9037         b64_ntop \
9038         __b64_ntop \
9039         b64_pton \
9040         __b64_pton \
9041         bcopy \
9042         bindresvport_sa \
9043         clock \
9044         closefrom \
9045         dirfd \
9046         fchmod \
9047         fchown \
9048         freeaddrinfo \
9049         fstatvfs \
9050         futimes \
9051         getaddrinfo \
9052         getcwd \
9053         getgrouplist \
9054         getnameinfo \
9055         getopt \
9056         getpeereid \
9057         getpeerucred \
9058         _getpty \
9059         getrlimit \
9060         getttyent \
9061         glob \
9062         group_from_gid \
9063         inet_aton \
9064         inet_ntoa \
9065         inet_ntop \
9066         innetgr \
9067         login_getcapbool \
9068         md5_crypt \
9069         memmove \
9070         mkdtemp \
9071         mmap \
9072         ngetaddrinfo \
9073         nsleep \
9074         ogetaddrinfo \
9075         openlog_r \
9076         openpty \
9077         poll \
9078         prctl \
9079         pstat \
9080         readpassphrase \
9081         realpath \
9082         recvmsg \
9083         rresvport_af \
9084         sendmsg \
9085         setdtablesize \
9086         setegid \
9087         setenv \
9088         seteuid \
9089         setgroupent \
9090         setgroups \
9091         setlogin \
9092         setpassent\
9093         setpcred \
9094         setproctitle \
9095         setregid \
9096         setreuid \
9097         setrlimit \
9098         setsid \
9099         setvbuf \
9100         sigaction \
9101         sigvec \
9102         snprintf \
9103         socketpair \
9104         statfs \
9105         statvfs \
9106         strdup \
9107         strerror \
9108         strlcat \
9109         strlcpy \
9110         strmode \
9111         strnvis \
9112         strptime \
9113         strtonum \
9114         strtoll \
9115         strtoul \
9116         swap32 \
9117         sysconf \
9118         tcgetpgrp \
9119         timingsafe_bcmp \
9120         truncate \
9121         unsetenv \
9122         updwtmpx \
9123         user_from_uid \
9124         vasprintf \
9125         vhangup \
9126         vsnprintf \
9127         waitpid \
9128
9129 do :
9130   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9131 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9132 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
9133   cat >>confdefs.h <<_ACEOF
9134 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9135 _ACEOF
9136
9137 fi
9138 done
9139
9140
9141 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9142 /* end confdefs.h.  */
9143  #include <ctype.h>
9144 int
9145 main ()
9146 {
9147  return (isblank('a'));
9148   ;
9149   return 0;
9150 }
9151 _ACEOF
9152 if ac_fn_c_try_link "$LINENO"; then :
9153
9154 $as_echo "#define HAVE_ISBLANK 1" >>confdefs.h
9155
9156
9157 fi
9158 rm -f core conftest.err conftest.$ac_objext \
9159     conftest$ac_exeext conftest.$ac_ext
9160
9161 # PKCS#11 support requires dlopen() and co
9162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dlopen" >&5
9163 $as_echo_n "checking for library containing dlopen... " >&6; }
9164 if test "${ac_cv_search_dlopen+set}" = set; then :
9165   $as_echo_n "(cached) " >&6
9166 else
9167   ac_func_search_save_LIBS=$LIBS
9168 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9169 /* end confdefs.h.  */
9170
9171 /* Override any GCC internal prototype to avoid an error.
9172    Use char because int might match the return type of a GCC
9173    builtin and then its argument prototype would still apply.  */
9174 #ifdef __cplusplus
9175 extern "C"
9176 #endif
9177 char dlopen ();
9178 int
9179 main ()
9180 {
9181 return dlopen ();
9182   ;
9183   return 0;
9184 }
9185 _ACEOF
9186 for ac_lib in '' dl; do
9187   if test -z "$ac_lib"; then
9188     ac_res="none required"
9189   else
9190     ac_res=-l$ac_lib
9191     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9192   fi
9193   if ac_fn_c_try_link "$LINENO"; then :
9194   ac_cv_search_dlopen=$ac_res
9195 fi
9196 rm -f core conftest.err conftest.$ac_objext \
9197     conftest$ac_exeext
9198   if test "${ac_cv_search_dlopen+set}" = set; then :
9199   break
9200 fi
9201 done
9202 if test "${ac_cv_search_dlopen+set}" = set; then :
9203
9204 else
9205   ac_cv_search_dlopen=no
9206 fi
9207 rm conftest.$ac_ext
9208 LIBS=$ac_func_search_save_LIBS
9209 fi
9210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dlopen" >&5
9211 $as_echo "$ac_cv_search_dlopen" >&6; }
9212 ac_res=$ac_cv_search_dlopen
9213 if test "$ac_res" != no; then :
9214   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9215
9216 $as_echo "#define ENABLE_PKCS11 /**/" >>confdefs.h
9217
9218
9219 fi
9220
9221
9222 # IRIX has a const char return value for gai_strerror()
9223 for ac_func in gai_strerror
9224 do :
9225   ac_fn_c_check_func "$LINENO" "gai_strerror" "ac_cv_func_gai_strerror"
9226 if test "x$ac_cv_func_gai_strerror" = x""yes; then :
9227   cat >>confdefs.h <<_ACEOF
9228 #define HAVE_GAI_STRERROR 1
9229 _ACEOF
9230
9231         $as_echo "#define HAVE_GAI_STRERROR 1" >>confdefs.h
9232
9233         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9234 /* end confdefs.h.  */
9235
9236 #include <sys/types.h>
9237 #include <sys/socket.h>
9238 #include <netdb.h>
9239
9240 const char *gai_strerror(int);
9241
9242 int
9243 main ()
9244 {
9245
9246         char *str;
9247         str = gai_strerror(0);
9248
9249   ;
9250   return 0;
9251 }
9252 _ACEOF
9253 if ac_fn_c_try_compile "$LINENO"; then :
9254
9255
9256 $as_echo "#define HAVE_CONST_GAI_STRERROR_PROTO 1" >>confdefs.h
9257
9258 fi
9259 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9260 fi
9261 done
9262
9263
9264 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing nanosleep" >&5
9265 $as_echo_n "checking for library containing nanosleep... " >&6; }
9266 if test "${ac_cv_search_nanosleep+set}" = set; then :
9267   $as_echo_n "(cached) " >&6
9268 else
9269   ac_func_search_save_LIBS=$LIBS
9270 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9271 /* end confdefs.h.  */
9272
9273 /* Override any GCC internal prototype to avoid an error.
9274    Use char because int might match the return type of a GCC
9275    builtin and then its argument prototype would still apply.  */
9276 #ifdef __cplusplus
9277 extern "C"
9278 #endif
9279 char nanosleep ();
9280 int
9281 main ()
9282 {
9283 return nanosleep ();
9284   ;
9285   return 0;
9286 }
9287 _ACEOF
9288 for ac_lib in '' rt posix4; do
9289   if test -z "$ac_lib"; then
9290     ac_res="none required"
9291   else
9292     ac_res=-l$ac_lib
9293     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
9294   fi
9295   if ac_fn_c_try_link "$LINENO"; then :
9296   ac_cv_search_nanosleep=$ac_res
9297 fi
9298 rm -f core conftest.err conftest.$ac_objext \
9299     conftest$ac_exeext
9300   if test "${ac_cv_search_nanosleep+set}" = set; then :
9301   break
9302 fi
9303 done
9304 if test "${ac_cv_search_nanosleep+set}" = set; then :
9305
9306 else
9307   ac_cv_search_nanosleep=no
9308 fi
9309 rm conftest.$ac_ext
9310 LIBS=$ac_func_search_save_LIBS
9311 fi
9312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_nanosleep" >&5
9313 $as_echo "$ac_cv_search_nanosleep" >&6; }
9314 ac_res=$ac_cv_search_nanosleep
9315 if test "$ac_res" != no; then :
9316   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
9317
9318 $as_echo "#define HAVE_NANOSLEEP 1" >>confdefs.h
9319
9320 fi
9321
9322
9323 ac_fn_c_check_decl "$LINENO" "getrusage" "ac_cv_have_decl_getrusage" "$ac_includes_default"
9324 if test "x$ac_cv_have_decl_getrusage" = x""yes; then :
9325   for ac_func in getrusage
9326 do :
9327   ac_fn_c_check_func "$LINENO" "getrusage" "ac_cv_func_getrusage"
9328 if test "x$ac_cv_func_getrusage" = x""yes; then :
9329   cat >>confdefs.h <<_ACEOF
9330 #define HAVE_GETRUSAGE 1
9331 _ACEOF
9332
9333 fi
9334 done
9335
9336 fi
9337
9338 ac_fn_c_check_decl "$LINENO" "strsep" "ac_cv_have_decl_strsep" "
9339 #ifdef HAVE_STRING_H
9340 # include <string.h>
9341 #endif
9342
9343 "
9344 if test "x$ac_cv_have_decl_strsep" = x""yes; then :
9345   for ac_func in strsep
9346 do :
9347   ac_fn_c_check_func "$LINENO" "strsep" "ac_cv_func_strsep"
9348 if test "x$ac_cv_func_strsep" = x""yes; then :
9349   cat >>confdefs.h <<_ACEOF
9350 #define HAVE_STRSEP 1
9351 _ACEOF
9352
9353 fi
9354 done
9355
9356 fi
9357
9358
9359 ac_fn_c_check_decl "$LINENO" "tcsendbreak" "ac_cv_have_decl_tcsendbreak" "#include <termios.h>
9360
9361 "
9362 if test "x$ac_cv_have_decl_tcsendbreak" = x""yes; then :
9363   $as_echo "#define HAVE_TCSENDBREAK 1" >>confdefs.h
9364
9365 else
9366   for ac_func in tcsendbreak
9367 do :
9368   ac_fn_c_check_func "$LINENO" "tcsendbreak" "ac_cv_func_tcsendbreak"
9369 if test "x$ac_cv_func_tcsendbreak" = x""yes; then :
9370   cat >>confdefs.h <<_ACEOF
9371 #define HAVE_TCSENDBREAK 1
9372 _ACEOF
9373
9374 fi
9375 done
9376
9377 fi
9378
9379
9380 ac_fn_c_check_decl "$LINENO" "h_errno" "ac_cv_have_decl_h_errno" "#include <netdb.h>
9381 "
9382 if test "x$ac_cv_have_decl_h_errno" = x""yes; then :
9383   ac_have_decl=1
9384 else
9385   ac_have_decl=0
9386 fi
9387
9388 cat >>confdefs.h <<_ACEOF
9389 #define HAVE_DECL_H_ERRNO $ac_have_decl
9390 _ACEOF
9391
9392
9393 ac_fn_c_check_decl "$LINENO" "SHUT_RD" "ac_cv_have_decl_SHUT_RD" "
9394 #include <sys/types.h>
9395 #include <sys/socket.h>
9396
9397 "
9398 if test "x$ac_cv_have_decl_SHUT_RD" = x""yes; then :
9399   ac_have_decl=1
9400 else
9401   ac_have_decl=0
9402 fi
9403
9404 cat >>confdefs.h <<_ACEOF
9405 #define HAVE_DECL_SHUT_RD $ac_have_decl
9406 _ACEOF
9407
9408
9409 ac_fn_c_check_decl "$LINENO" "O_NONBLOCK" "ac_cv_have_decl_O_NONBLOCK" "
9410 #include <sys/types.h>
9411 #ifdef HAVE_SYS_STAT_H
9412 # include <sys/stat.h>
9413 #endif
9414 #ifdef HAVE_FCNTL_H
9415 # include <fcntl.h>
9416 #endif
9417
9418 "
9419 if test "x$ac_cv_have_decl_O_NONBLOCK" = x""yes; then :
9420   ac_have_decl=1
9421 else
9422   ac_have_decl=0
9423 fi
9424
9425 cat >>confdefs.h <<_ACEOF
9426 #define HAVE_DECL_O_NONBLOCK $ac_have_decl
9427 _ACEOF
9428
9429
9430 ac_fn_c_check_decl "$LINENO" "writev" "ac_cv_have_decl_writev" "
9431 #include <sys/types.h>
9432 #include <sys/uio.h>
9433 #include <unistd.h>
9434
9435 "
9436 if test "x$ac_cv_have_decl_writev" = x""yes; then :
9437   ac_have_decl=1
9438 else
9439   ac_have_decl=0
9440 fi
9441
9442 cat >>confdefs.h <<_ACEOF
9443 #define HAVE_DECL_WRITEV $ac_have_decl
9444 _ACEOF
9445
9446
9447 ac_fn_c_check_decl "$LINENO" "MAXSYMLINKS" "ac_cv_have_decl_MAXSYMLINKS" "
9448 #include <sys/param.h>
9449
9450 "
9451 if test "x$ac_cv_have_decl_MAXSYMLINKS" = x""yes; then :
9452   ac_have_decl=1
9453 else
9454   ac_have_decl=0
9455 fi
9456
9457 cat >>confdefs.h <<_ACEOF
9458 #define HAVE_DECL_MAXSYMLINKS $ac_have_decl
9459 _ACEOF
9460
9461
9462 ac_fn_c_check_decl "$LINENO" "offsetof" "ac_cv_have_decl_offsetof" "
9463 #include <stddef.h>
9464
9465 "
9466 if test "x$ac_cv_have_decl_offsetof" = x""yes; then :
9467   ac_have_decl=1
9468 else
9469   ac_have_decl=0
9470 fi
9471
9472 cat >>confdefs.h <<_ACEOF
9473 #define HAVE_DECL_OFFSETOF $ac_have_decl
9474 _ACEOF
9475
9476
9477 for ac_func in setresuid
9478 do :
9479   ac_fn_c_check_func "$LINENO" "setresuid" "ac_cv_func_setresuid"
9480 if test "x$ac_cv_func_setresuid" = x""yes; then :
9481   cat >>confdefs.h <<_ACEOF
9482 #define HAVE_SETRESUID 1
9483 _ACEOF
9484
9485                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setresuid seems to work" >&5
9486 $as_echo_n "checking if setresuid seems to work... " >&6; }
9487         if test "$cross_compiling" = yes; then :
9488   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking setresuid" >&5
9489 $as_echo "$as_me: WARNING: cross compiling: not checking setresuid" >&2;}
9490
9491 else
9492   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9493 /* end confdefs.h.  */
9494
9495 #include <stdlib.h>
9496 #include <errno.h>
9497
9498 int
9499 main ()
9500 {
9501
9502         errno=0;
9503         setresuid(0,0,0);
9504         if (errno==ENOSYS)
9505                 exit(1);
9506         else
9507                 exit(0);
9508
9509   ;
9510   return 0;
9511 }
9512 _ACEOF
9513 if ac_fn_c_try_run "$LINENO"; then :
9514   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9515 $as_echo "yes" >&6; }
9516 else
9517
9518 $as_echo "#define BROKEN_SETRESUID 1" >>confdefs.h
9519
9520                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: not implemented" >&5
9521 $as_echo "not implemented" >&6; }
9522 fi
9523 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9524   conftest.$ac_objext conftest.beam conftest.$ac_ext
9525 fi
9526
9527
9528 fi
9529 done
9530
9531
9532 for ac_func in setresgid
9533 do :
9534   ac_fn_c_check_func "$LINENO" "setresgid" "ac_cv_func_setresgid"
9535 if test "x$ac_cv_func_setresgid" = x""yes; then :
9536   cat >>confdefs.h <<_ACEOF
9537 #define HAVE_SETRESGID 1
9538 _ACEOF
9539
9540                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if setresgid seems to work" >&5
9541 $as_echo_n "checking if setresgid seems to work... " >&6; }
9542         if test "$cross_compiling" = yes; then :
9543   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking setresuid" >&5
9544 $as_echo "$as_me: WARNING: cross compiling: not checking setresuid" >&2;}
9545
9546 else
9547   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9548 /* end confdefs.h.  */
9549
9550 #include <stdlib.h>
9551 #include <errno.h>
9552
9553 int
9554 main ()
9555 {
9556
9557         errno=0;
9558         setresgid(0,0,0);
9559         if (errno==ENOSYS)
9560                 exit(1);
9561         else
9562                 exit(0);
9563
9564   ;
9565   return 0;
9566 }
9567 _ACEOF
9568 if ac_fn_c_try_run "$LINENO"; then :
9569   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9570 $as_echo "yes" >&6; }
9571 else
9572
9573 $as_echo "#define BROKEN_SETRESGID 1" >>confdefs.h
9574
9575                  { $as_echo "$as_me:${as_lineno-$LINENO}: result: not implemented" >&5
9576 $as_echo "not implemented" >&6; }
9577 fi
9578 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9579   conftest.$ac_objext conftest.beam conftest.$ac_ext
9580 fi
9581
9582
9583 fi
9584 done
9585
9586
9587 for ac_func in gettimeofday time
9588 do :
9589   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9590 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9591 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
9592   cat >>confdefs.h <<_ACEOF
9593 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9594 _ACEOF
9595
9596 fi
9597 done
9598
9599 for ac_func in endutent getutent getutid getutline pututline setutent
9600 do :
9601   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9602 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9603 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
9604   cat >>confdefs.h <<_ACEOF
9605 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9606 _ACEOF
9607
9608 fi
9609 done
9610
9611 for ac_func in utmpname
9612 do :
9613   ac_fn_c_check_func "$LINENO" "utmpname" "ac_cv_func_utmpname"
9614 if test "x$ac_cv_func_utmpname" = x""yes; then :
9615   cat >>confdefs.h <<_ACEOF
9616 #define HAVE_UTMPNAME 1
9617 _ACEOF
9618
9619 fi
9620 done
9621
9622 for ac_func in endutxent getutxent getutxid getutxline getutxuser pututxline
9623 do :
9624   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9625 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9626 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
9627   cat >>confdefs.h <<_ACEOF
9628 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9629 _ACEOF
9630
9631 fi
9632 done
9633
9634 for ac_func in setutxdb setutxent utmpxname
9635 do :
9636   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
9637 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
9638 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
9639   cat >>confdefs.h <<_ACEOF
9640 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
9641 _ACEOF
9642
9643 fi
9644 done
9645
9646 for ac_func in getlastlogxbyname
9647 do :
9648   ac_fn_c_check_func "$LINENO" "getlastlogxbyname" "ac_cv_func_getlastlogxbyname"
9649 if test "x$ac_cv_func_getlastlogxbyname" = x""yes; then :
9650   cat >>confdefs.h <<_ACEOF
9651 #define HAVE_GETLASTLOGXBYNAME 1
9652 _ACEOF
9653
9654 fi
9655 done
9656
9657
9658 ac_fn_c_check_func "$LINENO" "daemon" "ac_cv_func_daemon"
9659 if test "x$ac_cv_func_daemon" = x""yes; then :
9660
9661 $as_echo "#define HAVE_DAEMON 1" >>confdefs.h
9662
9663 else
9664   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for daemon in -lbsd" >&5
9665 $as_echo_n "checking for daemon in -lbsd... " >&6; }
9666 if test "${ac_cv_lib_bsd_daemon+set}" = set; then :
9667   $as_echo_n "(cached) " >&6
9668 else
9669   ac_check_lib_save_LIBS=$LIBS
9670 LIBS="-lbsd  $LIBS"
9671 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9672 /* end confdefs.h.  */
9673
9674 /* Override any GCC internal prototype to avoid an error.
9675    Use char because int might match the return type of a GCC
9676    builtin and then its argument prototype would still apply.  */
9677 #ifdef __cplusplus
9678 extern "C"
9679 #endif
9680 char daemon ();
9681 int
9682 main ()
9683 {
9684 return daemon ();
9685   ;
9686   return 0;
9687 }
9688 _ACEOF
9689 if ac_fn_c_try_link "$LINENO"; then :
9690   ac_cv_lib_bsd_daemon=yes
9691 else
9692   ac_cv_lib_bsd_daemon=no
9693 fi
9694 rm -f core conftest.err conftest.$ac_objext \
9695     conftest$ac_exeext conftest.$ac_ext
9696 LIBS=$ac_check_lib_save_LIBS
9697 fi
9698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_daemon" >&5
9699 $as_echo "$ac_cv_lib_bsd_daemon" >&6; }
9700 if test "x$ac_cv_lib_bsd_daemon" = x""yes; then :
9701   LIBS="$LIBS -lbsd"; $as_echo "#define HAVE_DAEMON 1" >>confdefs.h
9702
9703 fi
9704
9705
9706 fi
9707
9708
9709 ac_fn_c_check_func "$LINENO" "getpagesize" "ac_cv_func_getpagesize"
9710 if test "x$ac_cv_func_getpagesize" = x""yes; then :
9711
9712 $as_echo "#define HAVE_GETPAGESIZE 1" >>confdefs.h
9713
9714 else
9715   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for getpagesize in -lucb" >&5
9716 $as_echo_n "checking for getpagesize in -lucb... " >&6; }
9717 if test "${ac_cv_lib_ucb_getpagesize+set}" = set; then :
9718   $as_echo_n "(cached) " >&6
9719 else
9720   ac_check_lib_save_LIBS=$LIBS
9721 LIBS="-lucb  $LIBS"
9722 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9723 /* end confdefs.h.  */
9724
9725 /* Override any GCC internal prototype to avoid an error.
9726    Use char because int might match the return type of a GCC
9727    builtin and then its argument prototype would still apply.  */
9728 #ifdef __cplusplus
9729 extern "C"
9730 #endif
9731 char getpagesize ();
9732 int
9733 main ()
9734 {
9735 return getpagesize ();
9736   ;
9737   return 0;
9738 }
9739 _ACEOF
9740 if ac_fn_c_try_link "$LINENO"; then :
9741   ac_cv_lib_ucb_getpagesize=yes
9742 else
9743   ac_cv_lib_ucb_getpagesize=no
9744 fi
9745 rm -f core conftest.err conftest.$ac_objext \
9746     conftest$ac_exeext conftest.$ac_ext
9747 LIBS=$ac_check_lib_save_LIBS
9748 fi
9749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ucb_getpagesize" >&5
9750 $as_echo "$ac_cv_lib_ucb_getpagesize" >&6; }
9751 if test "x$ac_cv_lib_ucb_getpagesize" = x""yes; then :
9752   LIBS="$LIBS -lucb"; $as_echo "#define HAVE_GETPAGESIZE 1" >>confdefs.h
9753
9754 fi
9755
9756
9757 fi
9758
9759
9760 # Check for broken snprintf
9761 if test "x$ac_cv_func_snprintf" = "xyes" ; then
9762         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf correctly terminates long strings" >&5
9763 $as_echo_n "checking whether snprintf correctly terminates long strings... " >&6; }
9764         if test "$cross_compiling" = yes; then :
9765    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: Assuming working snprintf()" >&5
9766 $as_echo "$as_me: WARNING: cross compiling: Assuming working snprintf()" >&2;}
9767
9768 else
9769   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9770 /* end confdefs.h.  */
9771  #include <stdio.h>
9772 int
9773 main ()
9774 {
9775
9776         char b[5];
9777         snprintf(b,5,"123456789");
9778         exit(b[4]!='\0');
9779
9780   ;
9781   return 0;
9782 }
9783 _ACEOF
9784 if ac_fn_c_try_run "$LINENO"; then :
9785   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9786 $as_echo "yes" >&6; }
9787 else
9788
9789                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9790 $as_echo "no" >&6; }
9791
9792 $as_echo "#define BROKEN_SNPRINTF 1" >>confdefs.h
9793
9794                         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ****** Your snprintf() function is broken, complain to your vendor" >&5
9795 $as_echo "$as_me: WARNING: ****** Your snprintf() function is broken, complain to your vendor" >&2;}
9796
9797 fi
9798 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9799   conftest.$ac_objext conftest.beam conftest.$ac_ext
9800 fi
9801
9802 fi
9803
9804 # If we don't have a working asprintf, then we strongly depend on vsnprintf
9805 # returning the right thing on overflow: the number of characters it tried to
9806 # create (as per SUSv3)
9807 if test "x$ac_cv_func_asprintf" != "xyes" && \
9808    test "x$ac_cv_func_vsnprintf" = "xyes" ; then
9809         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether vsnprintf returns correct values on overflow" >&5
9810 $as_echo_n "checking whether vsnprintf returns correct values on overflow... " >&6; }
9811         if test "$cross_compiling" = yes; then :
9812    { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: Assuming working vsnprintf()" >&5
9813 $as_echo "$as_me: WARNING: cross compiling: Assuming working vsnprintf()" >&2;}
9814
9815 else
9816   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9817 /* end confdefs.h.  */
9818
9819 #include <sys/types.h>
9820 #include <stdio.h>
9821 #include <stdarg.h>
9822
9823 int x_snprintf(char *str,size_t count,const char *fmt,...)
9824 {
9825         size_t ret; va_list ap;
9826         va_start(ap, fmt); ret = vsnprintf(str, count, fmt, ap); va_end(ap);
9827         return ret;
9828 }
9829
9830 int
9831 main ()
9832 {
9833
9834         char x[1];
9835         exit(x_snprintf(x, 1, "%s %d", "hello", 12345) == 11 ? 0 : 1);
9836
9837   ;
9838   return 0;
9839 }
9840 _ACEOF
9841 if ac_fn_c_try_run "$LINENO"; then :
9842   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9843 $as_echo "yes" >&6; }
9844 else
9845
9846                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9847 $as_echo "no" >&6; }
9848
9849 $as_echo "#define BROKEN_SNPRINTF 1" >>confdefs.h
9850
9851                         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ****** Your vsnprintf() function is broken, complain to your vendor" >&5
9852 $as_echo "$as_me: WARNING: ****** Your vsnprintf() function is broken, complain to your vendor" >&2;}
9853
9854 fi
9855 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9856   conftest.$ac_objext conftest.beam conftest.$ac_ext
9857 fi
9858
9859 fi
9860
9861 # On systems where [v]snprintf is broken, but is declared in stdio,
9862 # check that the fmt argument is const char * or just char *.
9863 # This is only useful for when BROKEN_SNPRINTF
9864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether snprintf can declare const char *fmt" >&5
9865 $as_echo_n "checking whether snprintf can declare const char *fmt... " >&6; }
9866 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9867 /* end confdefs.h.  */
9868
9869 #include <stdio.h>
9870 int snprintf(char *a, size_t b, const char *c, ...) { return 0; }
9871
9872 int
9873 main ()
9874 {
9875
9876         snprintf(0, 0, 0);
9877
9878   ;
9879   return 0;
9880 }
9881 _ACEOF
9882 if ac_fn_c_try_compile "$LINENO"; then :
9883   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9884 $as_echo "yes" >&6; }
9885
9886 $as_echo "#define SNPRINTF_CONST const" >>confdefs.h
9887
9888 else
9889   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9890 $as_echo "no" >&6; }
9891     $as_echo "#define SNPRINTF_CONST /* not const */" >>confdefs.h
9892
9893 fi
9894 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9895
9896 # Check for missing getpeereid (or equiv) support
9897 NO_PEERCHECK=""
9898 if test "x$ac_cv_func_getpeereid" != "xyes" -a "x$ac_cv_func_getpeerucred" != "xyes"; then
9899         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether system supports SO_PEERCRED getsockopt" >&5
9900 $as_echo_n "checking whether system supports SO_PEERCRED getsockopt... " >&6; }
9901         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9902 /* end confdefs.h.  */
9903
9904 #include <sys/types.h>
9905 #include <sys/socket.h>
9906 int
9907 main ()
9908 {
9909 int i = SO_PEERCRED;
9910   ;
9911   return 0;
9912 }
9913 _ACEOF
9914 if ac_fn_c_try_compile "$LINENO"; then :
9915    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9916 $as_echo "yes" >&6; }
9917
9918 $as_echo "#define HAVE_SO_PEERCRED 1" >>confdefs.h
9919
9920
9921 else
9922   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9923 $as_echo "no" >&6; }
9924                 NO_PEERCHECK=1
9925
9926 fi
9927 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9928 fi
9929
9930 if test "x$ac_cv_func_mkdtemp" = "xyes" ; then
9931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for (overly) strict mkstemp" >&5
9932 $as_echo_n "checking for (overly) strict mkstemp... " >&6; }
9933 if test "$cross_compiling" = yes; then :
9934
9935                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9936 $as_echo "yes" >&6; }
9937                 $as_echo "#define HAVE_STRICT_MKSTEMP 1" >>confdefs.h
9938
9939
9940
9941 else
9942   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9943 /* end confdefs.h.  */
9944
9945 #include <stdlib.h>
9946
9947 int
9948 main ()
9949 {
9950
9951         char template[]="conftest.mkstemp-test";
9952         if (mkstemp(template) == -1)
9953                 exit(1);
9954         unlink(template);
9955         exit(0);
9956
9957   ;
9958   return 0;
9959 }
9960 _ACEOF
9961 if ac_fn_c_try_run "$LINENO"; then :
9962
9963                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
9964 $as_echo "no" >&6; }
9965
9966 else
9967
9968                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
9969 $as_echo "yes" >&6; }
9970
9971 $as_echo "#define HAVE_STRICT_MKSTEMP 1" >>confdefs.h
9972
9973
9974 fi
9975 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
9976   conftest.$ac_objext conftest.beam conftest.$ac_ext
9977 fi
9978
9979 fi
9980
9981 if test ! -z "$check_for_openpty_ctty_bug"; then
9982         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openpty correctly handles controlling tty" >&5
9983 $as_echo_n "checking if openpty correctly handles controlling tty... " >&6; }
9984         if test "$cross_compiling" = yes; then :
9985
9986                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: cross-compiling, assuming yes" >&5
9987 $as_echo "cross-compiling, assuming yes" >&6; }
9988
9989
9990 else
9991   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
9992 /* end confdefs.h.  */
9993
9994 #include <stdio.h>
9995 #include <sys/fcntl.h>
9996 #include <sys/types.h>
9997 #include <sys/wait.h>
9998
9999 int
10000 main ()
10001 {
10002
10003         pid_t pid;
10004         int fd, ptyfd, ttyfd, status;
10005
10006         pid = fork();
10007         if (pid < 0) {          /* failed */
10008                 exit(1);
10009         } else if (pid > 0) {   /* parent */
10010                 waitpid(pid, &status, 0);
10011                 if (WIFEXITED(status))
10012                         exit(WEXITSTATUS(status));
10013                 else
10014                         exit(2);
10015         } else {                /* child */
10016                 close(0); close(1); close(2);
10017                 setsid();
10018                 openpty(&ptyfd, &ttyfd, NULL, NULL, NULL);
10019                 fd = open("/dev/tty", O_RDWR | O_NOCTTY);
10020                 if (fd >= 0)
10021                         exit(3);        /* Acquired ctty: broken */
10022                 else
10023                         exit(0);        /* Did not acquire ctty: OK */
10024         }
10025
10026   ;
10027   return 0;
10028 }
10029 _ACEOF
10030 if ac_fn_c_try_run "$LINENO"; then :
10031
10032                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10033 $as_echo "yes" >&6; }
10034
10035 else
10036
10037                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10038 $as_echo "no" >&6; }
10039                         $as_echo "#define SSHD_ACQUIRES_CTTY 1" >>confdefs.h
10040
10041
10042 fi
10043 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10044   conftest.$ac_objext conftest.beam conftest.$ac_ext
10045 fi
10046
10047 fi
10048
10049 if test "x$ac_cv_func_getaddrinfo" = "xyes" && \
10050     test "x$check_for_hpux_broken_getaddrinfo" = "x1"; then
10051         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo seems to work" >&5
10052 $as_echo_n "checking if getaddrinfo seems to work... " >&6; }
10053         if test "$cross_compiling" = yes; then :
10054
10055                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: cross-compiling, assuming yes" >&5
10056 $as_echo "cross-compiling, assuming yes" >&6; }
10057
10058
10059 else
10060   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10061 /* end confdefs.h.  */
10062
10063 #include <stdio.h>
10064 #include <sys/socket.h>
10065 #include <netdb.h>
10066 #include <errno.h>
10067 #include <netinet/in.h>
10068
10069 #define TEST_PORT "2222"
10070
10071 int
10072 main ()
10073 {
10074
10075         int err, sock;
10076         struct addrinfo *gai_ai, *ai, hints;
10077         char ntop[NI_MAXHOST], strport[NI_MAXSERV], *name = NULL;
10078
10079         memset(&hints, 0, sizeof(hints));
10080         hints.ai_family = PF_UNSPEC;
10081         hints.ai_socktype = SOCK_STREAM;
10082         hints.ai_flags = AI_PASSIVE;
10083
10084         err = getaddrinfo(name, TEST_PORT, &hints, &gai_ai);
10085         if (err != 0) {
10086                 fprintf(stderr, "getaddrinfo failed (%s)", gai_strerror(err));
10087                 exit(1);
10088         }
10089
10090         for (ai = gai_ai; ai != NULL; ai = ai->ai_next) {
10091                 if (ai->ai_family != AF_INET6)
10092                         continue;
10093
10094                 err = getnameinfo(ai->ai_addr, ai->ai_addrlen, ntop,
10095                     sizeof(ntop), strport, sizeof(strport),
10096                     NI_NUMERICHOST|NI_NUMERICSERV);
10097
10098                 if (err != 0) {
10099                         if (err == EAI_SYSTEM)
10100                                 perror("getnameinfo EAI_SYSTEM");
10101                         else
10102                                 fprintf(stderr, "getnameinfo failed: %s\n",
10103                                     gai_strerror(err));
10104                         exit(2);
10105                 }
10106
10107                 sock = socket(ai->ai_family, ai->ai_socktype, ai->ai_protocol);
10108                 if (sock < 0)
10109                         perror("socket");
10110                 if (bind(sock, ai->ai_addr, ai->ai_addrlen) < 0) {
10111                         if (errno == EBADF)
10112                                 exit(3);
10113                 }
10114         }
10115         exit(0);
10116
10117   ;
10118   return 0;
10119 }
10120 _ACEOF
10121 if ac_fn_c_try_run "$LINENO"; then :
10122
10123                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10124 $as_echo "yes" >&6; }
10125
10126 else
10127
10128                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10129 $as_echo "no" >&6; }
10130                         $as_echo "#define BROKEN_GETADDRINFO 1" >>confdefs.h
10131
10132
10133 fi
10134 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10135   conftest.$ac_objext conftest.beam conftest.$ac_ext
10136 fi
10137
10138 fi
10139
10140 if test "x$ac_cv_func_getaddrinfo" = "xyes" && \
10141     test "x$check_for_aix_broken_getaddrinfo" = "x1"; then
10142         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if getaddrinfo seems to work" >&5
10143 $as_echo_n "checking if getaddrinfo seems to work... " >&6; }
10144         if test "$cross_compiling" = yes; then :
10145
10146                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: cross-compiling, assuming no" >&5
10147 $as_echo "cross-compiling, assuming no" >&6; }
10148
10149
10150 else
10151   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10152 /* end confdefs.h.  */
10153
10154 #include <stdio.h>
10155 #include <sys/socket.h>
10156 #include <netdb.h>
10157 #include <errno.h>
10158 #include <netinet/in.h>
10159
10160 #define TEST_PORT "2222"
10161
10162 int
10163 main ()
10164 {
10165
10166         int err, sock;
10167         struct addrinfo *gai_ai, *ai, hints;
10168         char ntop[NI_MAXHOST], strport[NI_MAXSERV], *name = NULL;
10169
10170         memset(&hints, 0, sizeof(hints));
10171         hints.ai_family = PF_UNSPEC;
10172         hints.ai_socktype = SOCK_STREAM;
10173         hints.ai_flags = AI_PASSIVE;
10174
10175         err = getaddrinfo(name, TEST_PORT, &hints, &gai_ai);
10176         if (err != 0) {
10177                 fprintf(stderr, "getaddrinfo failed (%s)", gai_strerror(err));
10178                 exit(1);
10179         }
10180
10181         for (ai = gai_ai; ai != NULL; ai = ai->ai_next) {
10182                 if (ai->ai_family != AF_INET && ai->ai_family != AF_INET6)
10183                         continue;
10184
10185                 err = getnameinfo(ai->ai_addr, ai->ai_addrlen, ntop,
10186                     sizeof(ntop), strport, sizeof(strport),
10187                     NI_NUMERICHOST|NI_NUMERICSERV);
10188
10189                 if (ai->ai_family == AF_INET && err != 0) {
10190                         perror("getnameinfo");
10191                         exit(2);
10192                 }
10193         }
10194         exit(0);
10195
10196   ;
10197   return 0;
10198 }
10199 _ACEOF
10200 if ac_fn_c_try_run "$LINENO"; then :
10201
10202                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10203 $as_echo "yes" >&6; }
10204
10205 $as_echo "#define AIX_GETNAMEINFO_HACK 1" >>confdefs.h
10206
10207
10208 else
10209
10210                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10211 $as_echo "no" >&6; }
10212                         $as_echo "#define BROKEN_GETADDRINFO 1" >>confdefs.h
10213
10214
10215 fi
10216 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10217   conftest.$ac_objext conftest.beam conftest.$ac_ext
10218 fi
10219
10220 fi
10221
10222 if test "x$check_for_conflicting_getspnam" = "x1"; then
10223         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for conflicting getspnam in shadow.h" >&5
10224 $as_echo_n "checking for conflicting getspnam in shadow.h... " >&6; }
10225         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10226 /* end confdefs.h.  */
10227  #include <shadow.h>
10228 int
10229 main ()
10230 {
10231  exit(0);
10232   ;
10233   return 0;
10234 }
10235 _ACEOF
10236 if ac_fn_c_try_compile "$LINENO"; then :
10237
10238                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10239 $as_echo "no" >&6; }
10240
10241 else
10242
10243                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10244 $as_echo "yes" >&6; }
10245
10246 $as_echo "#define GETSPNAM_CONFLICTING_DEFS 1" >>confdefs.h
10247
10248
10249
10250 fi
10251 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10252 fi
10253
10254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getpgrp requires zero arguments" >&5
10255 $as_echo_n "checking whether getpgrp requires zero arguments... " >&6; }
10256 if test "${ac_cv_func_getpgrp_void+set}" = set; then :
10257   $as_echo_n "(cached) " >&6
10258 else
10259   # Use it with a single arg.
10260 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10261 /* end confdefs.h.  */
10262 $ac_includes_default
10263 int
10264 main ()
10265 {
10266 getpgrp (0);
10267   ;
10268   return 0;
10269 }
10270 _ACEOF
10271 if ac_fn_c_try_compile "$LINENO"; then :
10272   ac_cv_func_getpgrp_void=no
10273 else
10274   ac_cv_func_getpgrp_void=yes
10275 fi
10276 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10277
10278 fi
10279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_func_getpgrp_void" >&5
10280 $as_echo "$ac_cv_func_getpgrp_void" >&6; }
10281 if test $ac_cv_func_getpgrp_void = yes; then
10282
10283 $as_echo "#define GETPGRP_VOID 1" >>confdefs.h
10284
10285 fi
10286
10287
10288 # Search for OpenSSL
10289 saved_CPPFLAGS="$CPPFLAGS"
10290 saved_LDFLAGS="$LDFLAGS"
10291
10292 # Check whether --with-ssl-dir was given.
10293 if test "${with_ssl_dir+set}" = set; then :
10294   withval=$with_ssl_dir;
10295                 if test "x$withval" != "xno" ; then
10296                         case "$withval" in
10297                                 # Relative paths
10298                                 ./*|../*)       withval="`pwd`/$withval"
10299                         esac
10300                         if test -d "$withval/lib"; then
10301                                 if test -n "${need_dash_r}"; then
10302                                         LDFLAGS="-L${withval}/lib -R${withval}/lib ${LDFLAGS}"
10303                                 else
10304                                         LDFLAGS="-L${withval}/lib ${LDFLAGS}"
10305                                 fi
10306                         elif test -d "$withval/lib64"; then
10307                                 if test -n "${need_dash_r}"; then
10308                                         LDFLAGS="-L${withval}/lib64 -R${withval}/lib64 ${LDFLAGS}"
10309                                 else
10310                                         LDFLAGS="-L${withval}/lib64 ${LDFLAGS}"
10311                                 fi
10312                         else
10313                                 if test -n "${need_dash_r}"; then
10314                                         LDFLAGS="-L${withval} -R${withval} ${LDFLAGS}"
10315                                 else
10316                                         LDFLAGS="-L${withval} ${LDFLAGS}"
10317                                 fi
10318                         fi
10319                         if test -d "$withval/include"; then
10320                                 CPPFLAGS="-I${withval}/include ${CPPFLAGS}"
10321                         else
10322                                 CPPFLAGS="-I${withval} ${CPPFLAGS}"
10323                         fi
10324                 fi
10325
10326
10327 fi
10328
10329 LIBS="-lcrypto $LIBS"
10330 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10331 /* end confdefs.h.  */
10332
10333 /* Override any GCC internal prototype to avoid an error.
10334    Use char because int might match the return type of a GCC
10335    builtin and then its argument prototype would still apply.  */
10336 #ifdef __cplusplus
10337 extern "C"
10338 #endif
10339 char RAND_add ();
10340 int
10341 main ()
10342 {
10343 return RAND_add ();
10344   ;
10345   return 0;
10346 }
10347 _ACEOF
10348 if ac_fn_c_try_link "$LINENO"; then :
10349
10350 $as_echo "#define HAVE_OPENSSL 1" >>confdefs.h
10351
10352 else
10353
10354                                 if test -n "${need_dash_r}"; then
10355                         LDFLAGS="-L/usr/local/ssl/lib -R/usr/local/ssl/lib ${saved_LDFLAGS}"
10356                 else
10357                         LDFLAGS="-L/usr/local/ssl/lib ${saved_LDFLAGS}"
10358                 fi
10359                 CPPFLAGS="-I/usr/local/ssl/include ${saved_CPPFLAGS}"
10360                 ac_fn_c_check_header_mongrel "$LINENO" "openssl/opensslv.h" "ac_cv_header_openssl_opensslv_h" "$ac_includes_default"
10361 if test "x$ac_cv_header_openssl_opensslv_h" = x""yes; then :
10362
10363 else
10364   as_fn_error $? "*** OpenSSL headers missing - please install first or check config.log ***" "$LINENO" 5
10365 fi
10366
10367
10368                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10369 /* end confdefs.h.  */
10370
10371 /* Override any GCC internal prototype to avoid an error.
10372    Use char because int might match the return type of a GCC
10373    builtin and then its argument prototype would still apply.  */
10374 #ifdef __cplusplus
10375 extern "C"
10376 #endif
10377 char RAND_add ();
10378 int
10379 main ()
10380 {
10381 return RAND_add ();
10382   ;
10383   return 0;
10384 }
10385 _ACEOF
10386 if ac_fn_c_try_link "$LINENO"; then :
10387   $as_echo "#define HAVE_OPENSSL 1" >>confdefs.h
10388
10389 else
10390
10391                                 as_fn_error $? "*** Can't find recent OpenSSL libcrypto (see config.log for details) ***" "$LINENO" 5
10392
10393
10394 fi
10395 rm -f core conftest.err conftest.$ac_objext \
10396     conftest$ac_exeext conftest.$ac_ext
10397
10398
10399 fi
10400 rm -f core conftest.err conftest.$ac_objext \
10401     conftest$ac_exeext conftest.$ac_ext
10402
10403 # Determine OpenSSL header version
10404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking OpenSSL header version" >&5
10405 $as_echo_n "checking OpenSSL header version... " >&6; }
10406 if test "$cross_compiling" = yes; then :
10407
10408                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking" >&5
10409 $as_echo "$as_me: WARNING: cross compiling: not checking" >&2;}
10410
10411
10412 else
10413   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10414 /* end confdefs.h.  */
10415
10416 #include <stdio.h>
10417 #include <string.h>
10418 #include <openssl/opensslv.h>
10419 #define DATA "conftest.sslincver"
10420
10421 int
10422 main ()
10423 {
10424
10425         FILE *fd;
10426         int rc;
10427
10428         fd = fopen(DATA,"w");
10429         if(fd == NULL)
10430                 exit(1);
10431
10432         if ((rc = fprintf(fd ,"%x (%s)\n", OPENSSL_VERSION_NUMBER, OPENSSL_VERSION_TEXT)) <0)
10433                 exit(1);
10434
10435         exit(0);
10436
10437   ;
10438   return 0;
10439 }
10440 _ACEOF
10441 if ac_fn_c_try_run "$LINENO"; then :
10442
10443                 ssl_header_ver=`cat conftest.sslincver`
10444                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ssl_header_ver" >&5
10445 $as_echo "$ssl_header_ver" >&6; }
10446
10447 else
10448
10449                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10450 $as_echo "not found" >&6; }
10451                 as_fn_error $? "OpenSSL version header not found." "$LINENO" 5
10452
10453 fi
10454 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10455   conftest.$ac_objext conftest.beam conftest.$ac_ext
10456 fi
10457
10458
10459 # Determine OpenSSL library version
10460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking OpenSSL library version" >&5
10461 $as_echo_n "checking OpenSSL library version... " >&6; }
10462 if test "$cross_compiling" = yes; then :
10463
10464                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking" >&5
10465 $as_echo "$as_me: WARNING: cross compiling: not checking" >&2;}
10466
10467
10468 else
10469   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10470 /* end confdefs.h.  */
10471
10472 #include <stdio.h>
10473 #include <string.h>
10474 #include <openssl/opensslv.h>
10475 #include <openssl/crypto.h>
10476 #define DATA "conftest.ssllibver"
10477
10478 int
10479 main ()
10480 {
10481
10482         FILE *fd;
10483         int rc;
10484
10485         fd = fopen(DATA,"w");
10486         if(fd == NULL)
10487                 exit(1);
10488
10489         if ((rc = fprintf(fd ,"%x (%s)\n", SSLeay(), SSLeay_version(SSLEAY_VERSION))) <0)
10490                 exit(1);
10491
10492         exit(0);
10493
10494   ;
10495   return 0;
10496 }
10497 _ACEOF
10498 if ac_fn_c_try_run "$LINENO"; then :
10499
10500                 ssl_library_ver=`cat conftest.ssllibver`
10501                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ssl_library_ver" >&5
10502 $as_echo "$ssl_library_ver" >&6; }
10503
10504 else
10505
10506                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
10507 $as_echo "not found" >&6; }
10508                 as_fn_error $? "OpenSSL library not found." "$LINENO" 5
10509
10510 fi
10511 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10512   conftest.$ac_objext conftest.beam conftest.$ac_ext
10513 fi
10514
10515
10516
10517 # Check whether --with-openssl-header-check was given.
10518 if test "${with_openssl_header_check+set}" = set; then :
10519   withval=$with_openssl_header_check;   if test "x$withval" = "xno" ; then
10520                 openssl_check_nonfatal=1
10521            fi
10522
10523
10524 fi
10525
10526
10527 # Sanity check OpenSSL headers
10528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether OpenSSL's headers match the library" >&5
10529 $as_echo_n "checking whether OpenSSL's headers match the library... " >&6; }
10530 if test "$cross_compiling" = yes; then :
10531
10532                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking" >&5
10533 $as_echo "$as_me: WARNING: cross compiling: not checking" >&2;}
10534
10535
10536 else
10537   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10538 /* end confdefs.h.  */
10539
10540 #include <string.h>
10541 #include <openssl/opensslv.h>
10542
10543 int
10544 main ()
10545 {
10546
10547         exit(SSLeay() == OPENSSL_VERSION_NUMBER ? 0 : 1);
10548
10549   ;
10550   return 0;
10551 }
10552 _ACEOF
10553 if ac_fn_c_try_run "$LINENO"; then :
10554
10555                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10556 $as_echo "yes" >&6; }
10557
10558 else
10559
10560                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10561 $as_echo "no" >&6; }
10562                 if test "x$openssl_check_nonfatal" = "x"; then
10563                         as_fn_error $? "Your OpenSSL headers do not match your
10564 library. Check config.log for details.
10565 If you are sure your installation is consistent, you can disable the check
10566 by running \"./configure --without-openssl-header-check\".
10567 Also see contrib/findssl.sh for help identifying header/library mismatches.
10568 " "$LINENO" 5
10569                 else
10570                         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Your OpenSSL headers do not match your
10571 library. Check config.log for details.
10572 Also see contrib/findssl.sh for help identifying header/library mismatches." >&5
10573 $as_echo "$as_me: WARNING: Your OpenSSL headers do not match your
10574 library. Check config.log for details.
10575 Also see contrib/findssl.sh for help identifying header/library mismatches." >&2;}
10576                 fi
10577
10578 fi
10579 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
10580   conftest.$ac_objext conftest.beam conftest.$ac_ext
10581 fi
10582
10583
10584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if programs using OpenSSL functions will link" >&5
10585 $as_echo_n "checking if programs using OpenSSL functions will link... " >&6; }
10586 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10587 /* end confdefs.h.  */
10588  #include <openssl/evp.h>
10589 int
10590 main ()
10591 {
10592  SSLeay_add_all_algorithms();
10593   ;
10594   return 0;
10595 }
10596 _ACEOF
10597 if ac_fn_c_try_link "$LINENO"; then :
10598
10599                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10600 $as_echo "yes" >&6; }
10601
10602 else
10603
10604                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10605 $as_echo "no" >&6; }
10606                 saved_LIBS="$LIBS"
10607                 LIBS="$LIBS -ldl"
10608                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if programs using OpenSSL need -ldl" >&5
10609 $as_echo_n "checking if programs using OpenSSL need -ldl... " >&6; }
10610                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10611 /* end confdefs.h.  */
10612  #include <openssl/evp.h>
10613 int
10614 main ()
10615 {
10616  SSLeay_add_all_algorithms();
10617   ;
10618   return 0;
10619 }
10620 _ACEOF
10621 if ac_fn_c_try_link "$LINENO"; then :
10622
10623                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10624 $as_echo "yes" >&6; }
10625
10626 else
10627
10628                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10629 $as_echo "no" >&6; }
10630                                 LIBS="$saved_LIBS"
10631
10632
10633 fi
10634 rm -f core conftest.err conftest.$ac_objext \
10635     conftest$ac_exeext conftest.$ac_ext
10636
10637
10638 fi
10639 rm -f core conftest.err conftest.$ac_objext \
10640     conftest$ac_exeext conftest.$ac_ext
10641
10642 for ac_func in RSA_generate_key_ex DSA_generate_parameters_ex BN_is_prime_ex RSA_get_default_method
10643 do :
10644   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10645 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10646 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
10647   cat >>confdefs.h <<_ACEOF
10648 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10649 _ACEOF
10650
10651 fi
10652 done
10653
10654
10655
10656 # Check whether --with-ssl-engine was given.
10657 if test "${with_ssl_engine+set}" = set; then :
10658   withval=$with_ssl_engine;  if test "x$withval" != "xno" ; then
10659                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OpenSSL ENGINE support" >&5
10660 $as_echo_n "checking for OpenSSL ENGINE support... " >&6; }
10661                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10662 /* end confdefs.h.  */
10663
10664 #include <openssl/engine.h>
10665
10666 int
10667 main ()
10668 {
10669
10670         ENGINE_load_builtin_engines();
10671         ENGINE_register_all_complete();
10672
10673   ;
10674   return 0;
10675 }
10676 _ACEOF
10677 if ac_fn_c_try_compile "$LINENO"; then :
10678    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10679 $as_echo "yes" >&6; }
10680
10681 $as_echo "#define USE_OPENSSL_ENGINE 1" >>confdefs.h
10682
10683
10684 else
10685    as_fn_error $? "OpenSSL ENGINE support not found" "$LINENO" 5
10686
10687 fi
10688 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10689           fi
10690
10691 fi
10692
10693
10694 # Check for OpenSSL without EVP_aes_{192,256}_cbc
10695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether OpenSSL has crippled AES support" >&5
10696 $as_echo_n "checking whether OpenSSL has crippled AES support... " >&6; }
10697 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10698 /* end confdefs.h.  */
10699
10700 #include <string.h>
10701 #include <openssl/evp.h>
10702
10703 int
10704 main ()
10705 {
10706
10707         exit(EVP_aes_192_cbc() == NULL || EVP_aes_256_cbc() == NULL);
10708
10709   ;
10710   return 0;
10711 }
10712 _ACEOF
10713 if ac_fn_c_try_link "$LINENO"; then :
10714
10715                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10716 $as_echo "no" >&6; }
10717
10718 else
10719
10720                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10721 $as_echo "yes" >&6; }
10722
10723 $as_echo "#define OPENSSL_LOBOTOMISED_AES 1" >>confdefs.h
10724
10725
10726
10727 fi
10728 rm -f core conftest.err conftest.$ac_objext \
10729     conftest$ac_exeext conftest.$ac_ext
10730
10731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if EVP_DigestUpdate returns an int" >&5
10732 $as_echo_n "checking if EVP_DigestUpdate returns an int... " >&6; }
10733 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10734 /* end confdefs.h.  */
10735
10736 #include <string.h>
10737 #include <openssl/evp.h>
10738
10739 int
10740 main ()
10741 {
10742
10743         if(EVP_DigestUpdate(NULL, NULL,0))
10744                 exit(0);
10745
10746   ;
10747   return 0;
10748 }
10749 _ACEOF
10750 if ac_fn_c_try_link "$LINENO"; then :
10751
10752                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10753 $as_echo "yes" >&6; }
10754
10755 else
10756
10757                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10758 $as_echo "no" >&6; }
10759
10760 $as_echo "#define OPENSSL_EVP_DIGESTUPDATE_VOID 1" >>confdefs.h
10761
10762
10763
10764 fi
10765 rm -f core conftest.err conftest.$ac_objext \
10766     conftest$ac_exeext conftest.$ac_ext
10767
10768 # Some systems want crypt() from libcrypt, *not* the version in OpenSSL,
10769 # because the system crypt() is more featureful.
10770 if test "x$check_for_libcrypt_before" = "x1"; then
10771         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for crypt in -lcrypt" >&5
10772 $as_echo_n "checking for crypt in -lcrypt... " >&6; }
10773 if test "${ac_cv_lib_crypt_crypt+set}" = set; then :
10774   $as_echo_n "(cached) " >&6
10775 else
10776   ac_check_lib_save_LIBS=$LIBS
10777 LIBS="-lcrypt  $LIBS"
10778 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10779 /* end confdefs.h.  */
10780
10781 /* Override any GCC internal prototype to avoid an error.
10782    Use char because int might match the return type of a GCC
10783    builtin and then its argument prototype would still apply.  */
10784 #ifdef __cplusplus
10785 extern "C"
10786 #endif
10787 char crypt ();
10788 int
10789 main ()
10790 {
10791 return crypt ();
10792   ;
10793   return 0;
10794 }
10795 _ACEOF
10796 if ac_fn_c_try_link "$LINENO"; then :
10797   ac_cv_lib_crypt_crypt=yes
10798 else
10799   ac_cv_lib_crypt_crypt=no
10800 fi
10801 rm -f core conftest.err conftest.$ac_objext \
10802     conftest$ac_exeext conftest.$ac_ext
10803 LIBS=$ac_check_lib_save_LIBS
10804 fi
10805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypt_crypt" >&5
10806 $as_echo "$ac_cv_lib_crypt_crypt" >&6; }
10807 if test "x$ac_cv_lib_crypt_crypt" = x""yes; then :
10808   cat >>confdefs.h <<_ACEOF
10809 #define HAVE_LIBCRYPT 1
10810 _ACEOF
10811
10812   LIBS="-lcrypt $LIBS"
10813
10814 fi
10815
10816 fi
10817
10818 # Some Linux systems (Slackware) need crypt() from libcrypt, *not* the
10819 # version in OpenSSL.
10820 if test "x$check_for_libcrypt_later" = "x1"; then
10821         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for crypt in -lcrypt" >&5
10822 $as_echo_n "checking for crypt in -lcrypt... " >&6; }
10823 if test "${ac_cv_lib_crypt_crypt+set}" = set; then :
10824   $as_echo_n "(cached) " >&6
10825 else
10826   ac_check_lib_save_LIBS=$LIBS
10827 LIBS="-lcrypt  $LIBS"
10828 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10829 /* end confdefs.h.  */
10830
10831 /* Override any GCC internal prototype to avoid an error.
10832    Use char because int might match the return type of a GCC
10833    builtin and then its argument prototype would still apply.  */
10834 #ifdef __cplusplus
10835 extern "C"
10836 #endif
10837 char crypt ();
10838 int
10839 main ()
10840 {
10841 return crypt ();
10842   ;
10843   return 0;
10844 }
10845 _ACEOF
10846 if ac_fn_c_try_link "$LINENO"; then :
10847   ac_cv_lib_crypt_crypt=yes
10848 else
10849   ac_cv_lib_crypt_crypt=no
10850 fi
10851 rm -f core conftest.err conftest.$ac_objext \
10852     conftest$ac_exeext conftest.$ac_ext
10853 LIBS=$ac_check_lib_save_LIBS
10854 fi
10855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_crypt_crypt" >&5
10856 $as_echo "$ac_cv_lib_crypt_crypt" >&6; }
10857 if test "x$ac_cv_lib_crypt_crypt" = x""yes; then :
10858   LIBS="$LIBS -lcrypt"
10859 fi
10860
10861 fi
10862
10863 # Search for SHA256 support in libc and/or OpenSSL
10864 for ac_func in SHA256_Update EVP_sha256
10865 do :
10866   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
10867 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
10868 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
10869   cat >>confdefs.h <<_ACEOF
10870 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
10871 _ACEOF
10872  TEST_SSH_SHA256=yes
10873 else
10874   TEST_SSH_SHA256=no
10875 fi
10876 done
10877
10878
10879
10880 # Check complete ECC support in OpenSSL
10881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether OpenSSL has complete ECC support" >&5
10882 $as_echo_n "checking whether OpenSSL has complete ECC support... " >&6; }
10883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10884 /* end confdefs.h.  */
10885
10886 #include <openssl/ec.h>
10887 #include <openssl/ecdh.h>
10888 #include <openssl/ecdsa.h>
10889 #include <openssl/evp.h>
10890 #include <openssl/objects.h>
10891 #include <openssl/opensslv.h>
10892 #if OPENSSL_VERSION_NUMBER < 0x0090807f /* 0.9.8g */
10893 # error "OpenSSL < 0.9.8g has unreliable ECC code"
10894 #endif
10895
10896 int
10897 main ()
10898 {
10899
10900         EC_KEY *e = EC_KEY_new_by_curve_name(NID_secp521r1);
10901         const EVP_MD *m = EVP_sha512(); /* We need this too */
10902
10903   ;
10904   return 0;
10905 }
10906 _ACEOF
10907 if ac_fn_c_try_link "$LINENO"; then :
10908
10909                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
10910 $as_echo "yes" >&6; }
10911
10912 $as_echo "#define OPENSSL_HAS_ECC 1" >>confdefs.h
10913
10914                 TEST_SSH_ECC=yes
10915                 COMMENT_OUT_ECC=""
10916
10917 else
10918
10919                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
10920 $as_echo "no" >&6; }
10921                 TEST_SSH_ECC=no
10922                 COMMENT_OUT_ECC="#no ecc#"
10923
10924
10925 fi
10926 rm -f core conftest.err conftest.$ac_objext \
10927     conftest$ac_exeext conftest.$ac_ext
10928
10929
10930
10931 saved_LIBS="$LIBS"
10932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ia_openinfo in -liaf" >&5
10933 $as_echo_n "checking for ia_openinfo in -liaf... " >&6; }
10934 if test "${ac_cv_lib_iaf_ia_openinfo+set}" = set; then :
10935   $as_echo_n "(cached) " >&6
10936 else
10937   ac_check_lib_save_LIBS=$LIBS
10938 LIBS="-liaf  $LIBS"
10939 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
10940 /* end confdefs.h.  */
10941
10942 /* Override any GCC internal prototype to avoid an error.
10943    Use char because int might match the return type of a GCC
10944    builtin and then its argument prototype would still apply.  */
10945 #ifdef __cplusplus
10946 extern "C"
10947 #endif
10948 char ia_openinfo ();
10949 int
10950 main ()
10951 {
10952 return ia_openinfo ();
10953   ;
10954   return 0;
10955 }
10956 _ACEOF
10957 if ac_fn_c_try_link "$LINENO"; then :
10958   ac_cv_lib_iaf_ia_openinfo=yes
10959 else
10960   ac_cv_lib_iaf_ia_openinfo=no
10961 fi
10962 rm -f core conftest.err conftest.$ac_objext \
10963     conftest$ac_exeext conftest.$ac_ext
10964 LIBS=$ac_check_lib_save_LIBS
10965 fi
10966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_iaf_ia_openinfo" >&5
10967 $as_echo "$ac_cv_lib_iaf_ia_openinfo" >&6; }
10968 if test "x$ac_cv_lib_iaf_ia_openinfo" = x""yes; then :
10969
10970         LIBS="$LIBS -liaf"
10971         for ac_func in set_id
10972 do :
10973   ac_fn_c_check_func "$LINENO" "set_id" "ac_cv_func_set_id"
10974 if test "x$ac_cv_func_set_id" = x""yes; then :
10975   cat >>confdefs.h <<_ACEOF
10976 #define HAVE_SET_ID 1
10977 _ACEOF
10978  SSHDLIBS="$SSHDLIBS -liaf"
10979
10980 $as_echo "#define HAVE_LIBIAF 1" >>confdefs.h
10981
10982
10983 fi
10984 done
10985
10986
10987 fi
10988
10989 LIBS="$saved_LIBS"
10990
10991 ### Configure cryptographic random number support
10992
10993 # Check wheter OpenSSL seeds itself
10994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether OpenSSL's PRNG is internally seeded" >&5
10995 $as_echo_n "checking whether OpenSSL's PRNG is internally seeded... " >&6; }
10996 if test "$cross_compiling" = yes; then :
10997
10998                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: assuming yes" >&5
10999 $as_echo "$as_me: WARNING: cross compiling: assuming yes" >&2;}
11000                 # This is safe, since we will fatal() at runtime if
11001                 # OpenSSL is not seeded correctly.
11002                 OPENSSL_SEEDS_ITSELF=yes
11003
11004
11005 else
11006   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11007 /* end confdefs.h.  */
11008
11009 #include <string.h>
11010 #include <openssl/rand.h>
11011
11012 int
11013 main ()
11014 {
11015
11016         exit(RAND_status() == 1 ? 0 : 1);
11017
11018   ;
11019   return 0;
11020 }
11021 _ACEOF
11022 if ac_fn_c_try_run "$LINENO"; then :
11023
11024                 OPENSSL_SEEDS_ITSELF=yes
11025                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11026 $as_echo "yes" >&6; }
11027
11028 else
11029
11030                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11031 $as_echo "no" >&6; }
11032
11033 fi
11034 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11035   conftest.$ac_objext conftest.beam conftest.$ac_ext
11036 fi
11037
11038
11039 # PRNGD TCP socket
11040
11041 # Check whether --with-prngd-port was given.
11042 if test "${with_prngd_port+set}" = set; then :
11043   withval=$with_prngd_port;
11044                 case "$withval" in
11045                 no)
11046                         withval=""
11047                         ;;
11048                 [0-9]*)
11049                         ;;
11050                 *)
11051                         as_fn_error $? "You must specify a numeric port number for --with-prngd-port" "$LINENO" 5
11052                         ;;
11053                 esac
11054                 if test ! -z "$withval" ; then
11055                         PRNGD_PORT="$withval"
11056
11057 cat >>confdefs.h <<_ACEOF
11058 #define PRNGD_PORT $PRNGD_PORT
11059 _ACEOF
11060
11061                 fi
11062
11063
11064 fi
11065
11066
11067 # PRNGD Unix domain socket
11068
11069 # Check whether --with-prngd-socket was given.
11070 if test "${with_prngd_socket+set}" = set; then :
11071   withval=$with_prngd_socket;
11072                 case "$withval" in
11073                 yes)
11074                         withval="/var/run/egd-pool"
11075                         ;;
11076                 no)
11077                         withval=""
11078                         ;;
11079                 /*)
11080                         ;;
11081                 *)
11082                         as_fn_error $? "You must specify an absolute path to the entropy socket" "$LINENO" 5
11083                         ;;
11084                 esac
11085
11086                 if test ! -z "$withval" ; then
11087                         if test ! -z "$PRNGD_PORT" ; then
11088                                 as_fn_error $? "You may not specify both a PRNGD/EGD port and socket" "$LINENO" 5
11089                         fi
11090                         if test ! -r "$withval" ; then
11091                                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Entropy socket is not readable" >&5
11092 $as_echo "$as_me: WARNING: Entropy socket is not readable" >&2;}
11093                         fi
11094                         PRNGD_SOCKET="$withval"
11095
11096 cat >>confdefs.h <<_ACEOF
11097 #define PRNGD_SOCKET "$PRNGD_SOCKET"
11098 _ACEOF
11099
11100                 fi
11101
11102 else
11103
11104                 # Check for existing socket only if we don't have a random device already
11105                 if test "x$OPENSSL_SEEDS_ITSELF" != "xyes" ; then
11106                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRNGD/EGD socket" >&5
11107 $as_echo_n "checking for PRNGD/EGD socket... " >&6; }
11108                         # Insert other locations here
11109                         for sock in /var/run/egd-pool /dev/egd-pool /etc/entropy; do
11110                                 if test -r $sock && $TEST_MINUS_S_SH -c "test -S $sock -o -p $sock" ; then
11111                                         PRNGD_SOCKET="$sock"
11112                                         cat >>confdefs.h <<_ACEOF
11113 #define PRNGD_SOCKET "$PRNGD_SOCKET"
11114 _ACEOF
11115
11116                                         break;
11117                                 fi
11118                         done
11119                         if test ! -z "$PRNGD_SOCKET" ; then
11120                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRNGD_SOCKET" >&5
11121 $as_echo "$PRNGD_SOCKET" >&6; }
11122                         else
11123                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11124 $as_echo "not found" >&6; }
11125                         fi
11126                 fi
11127
11128
11129 fi
11130
11131
11132 # Which randomness source do we use?
11133 if test ! -z "$PRNGD_PORT" ; then
11134         RAND_MSG="PRNGd port $PRNGD_PORT"
11135 elif test ! -z "$PRNGD_SOCKET" ; then
11136         RAND_MSG="PRNGd socket $PRNGD_SOCKET"
11137 elif test ! -z "$OPENSSL_SEEDS_ITSELF" ; then
11138
11139 $as_echo "#define OPENSSL_PRNG_ONLY 1" >>confdefs.h
11140
11141         RAND_MSG="OpenSSL internal ONLY"
11142 else
11143         as_fn_error $? "OpenSSH has no source of random numbers. Please configure OpenSSL with an entropy source or re-run configure using one of the --with-prngd-port or --with-prngd-socket options" "$LINENO" 5
11144 fi
11145
11146 # Check for PAM libs
11147 PAM_MSG="no"
11148
11149 # Check whether --with-pam was given.
11150 if test "${with_pam+set}" = set; then :
11151   withval=$with_pam;
11152                 if test "x$withval" != "xno" ; then
11153                         if test "x$ac_cv_header_security_pam_appl_h" != "xyes" && \
11154                            test "x$ac_cv_header_pam_pam_appl_h" != "xyes" ; then
11155                                 as_fn_error $? "PAM headers not found" "$LINENO" 5
11156                         fi
11157
11158                         saved_LIBS="$LIBS"
11159                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5
11160 $as_echo_n "checking for dlopen in -ldl... " >&6; }
11161 if test "${ac_cv_lib_dl_dlopen+set}" = set; then :
11162   $as_echo_n "(cached) " >&6
11163 else
11164   ac_check_lib_save_LIBS=$LIBS
11165 LIBS="-ldl  $LIBS"
11166 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11167 /* end confdefs.h.  */
11168
11169 /* Override any GCC internal prototype to avoid an error.
11170    Use char because int might match the return type of a GCC
11171    builtin and then its argument prototype would still apply.  */
11172 #ifdef __cplusplus
11173 extern "C"
11174 #endif
11175 char dlopen ();
11176 int
11177 main ()
11178 {
11179 return dlopen ();
11180   ;
11181   return 0;
11182 }
11183 _ACEOF
11184 if ac_fn_c_try_link "$LINENO"; then :
11185   ac_cv_lib_dl_dlopen=yes
11186 else
11187   ac_cv_lib_dl_dlopen=no
11188 fi
11189 rm -f core conftest.err conftest.$ac_objext \
11190     conftest$ac_exeext conftest.$ac_ext
11191 LIBS=$ac_check_lib_save_LIBS
11192 fi
11193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5
11194 $as_echo "$ac_cv_lib_dl_dlopen" >&6; }
11195 if test "x$ac_cv_lib_dl_dlopen" = x""yes; then :
11196   cat >>confdefs.h <<_ACEOF
11197 #define HAVE_LIBDL 1
11198 _ACEOF
11199
11200   LIBS="-ldl $LIBS"
11201
11202 fi
11203
11204                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pam_set_item in -lpam" >&5
11205 $as_echo_n "checking for pam_set_item in -lpam... " >&6; }
11206 if test "${ac_cv_lib_pam_pam_set_item+set}" = set; then :
11207   $as_echo_n "(cached) " >&6
11208 else
11209   ac_check_lib_save_LIBS=$LIBS
11210 LIBS="-lpam  $LIBS"
11211 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11212 /* end confdefs.h.  */
11213
11214 /* Override any GCC internal prototype to avoid an error.
11215    Use char because int might match the return type of a GCC
11216    builtin and then its argument prototype would still apply.  */
11217 #ifdef __cplusplus
11218 extern "C"
11219 #endif
11220 char pam_set_item ();
11221 int
11222 main ()
11223 {
11224 return pam_set_item ();
11225   ;
11226   return 0;
11227 }
11228 _ACEOF
11229 if ac_fn_c_try_link "$LINENO"; then :
11230   ac_cv_lib_pam_pam_set_item=yes
11231 else
11232   ac_cv_lib_pam_pam_set_item=no
11233 fi
11234 rm -f core conftest.err conftest.$ac_objext \
11235     conftest$ac_exeext conftest.$ac_ext
11236 LIBS=$ac_check_lib_save_LIBS
11237 fi
11238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_pam_pam_set_item" >&5
11239 $as_echo "$ac_cv_lib_pam_pam_set_item" >&6; }
11240 if test "x$ac_cv_lib_pam_pam_set_item" = x""yes; then :
11241   cat >>confdefs.h <<_ACEOF
11242 #define HAVE_LIBPAM 1
11243 _ACEOF
11244
11245   LIBS="-lpam $LIBS"
11246
11247 else
11248   as_fn_error $? "*** libpam missing" "$LINENO" 5
11249 fi
11250
11251                         for ac_func in pam_getenvlist
11252 do :
11253   ac_fn_c_check_func "$LINENO" "pam_getenvlist" "ac_cv_func_pam_getenvlist"
11254 if test "x$ac_cv_func_pam_getenvlist" = x""yes; then :
11255   cat >>confdefs.h <<_ACEOF
11256 #define HAVE_PAM_GETENVLIST 1
11257 _ACEOF
11258
11259 fi
11260 done
11261
11262                         for ac_func in pam_putenv
11263 do :
11264   ac_fn_c_check_func "$LINENO" "pam_putenv" "ac_cv_func_pam_putenv"
11265 if test "x$ac_cv_func_pam_putenv" = x""yes; then :
11266   cat >>confdefs.h <<_ACEOF
11267 #define HAVE_PAM_PUTENV 1
11268 _ACEOF
11269
11270 fi
11271 done
11272
11273                         LIBS="$saved_LIBS"
11274
11275                         PAM_MSG="yes"
11276
11277                         SSHDLIBS="$SSHDLIBS -lpam"
11278
11279 $as_echo "#define USE_PAM 1" >>confdefs.h
11280
11281
11282                         if test $ac_cv_lib_dl_dlopen = yes; then
11283                                 case "$LIBS" in
11284                                 *-ldl*)
11285                                         # libdl already in LIBS
11286                                         ;;
11287                                 *)
11288                                         SSHDLIBS="$SSHDLIBS -ldl"
11289                                         ;;
11290                                 esac
11291                         fi
11292                 fi
11293
11294
11295 fi
11296
11297
11298 # Check for older PAM
11299 if test "x$PAM_MSG" = "xyes" ; then
11300         # Check PAM strerror arguments (old PAM)
11301         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether pam_strerror takes only one argument" >&5
11302 $as_echo_n "checking whether pam_strerror takes only one argument... " >&6; }
11303         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11304 /* end confdefs.h.  */
11305
11306 #include <stdlib.h>
11307 #if defined(HAVE_SECURITY_PAM_APPL_H)
11308 #include <security/pam_appl.h>
11309 #elif defined (HAVE_PAM_PAM_APPL_H)
11310 #include <pam/pam_appl.h>
11311 #endif
11312
11313 int
11314 main ()
11315 {
11316
11317 (void)pam_strerror((pam_handle_t *)NULL, -1);
11318
11319   ;
11320   return 0;
11321 }
11322 _ACEOF
11323 if ac_fn_c_try_compile "$LINENO"; then :
11324   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11325 $as_echo "no" >&6; }
11326 else
11327
11328
11329 $as_echo "#define HAVE_OLD_PAM 1" >>confdefs.h
11330
11331                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11332 $as_echo "yes" >&6; }
11333                         PAM_MSG="yes (old library)"
11334
11335
11336 fi
11337 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11338 fi
11339
11340 SSH_PRIVSEP_USER=sshd
11341
11342 # Check whether --with-privsep-user was given.
11343 if test "${with_privsep_user+set}" = set; then :
11344   withval=$with_privsep_user;
11345                 if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
11346                     test "x${withval}" != "xyes"; then
11347                         SSH_PRIVSEP_USER=$withval
11348                 fi
11349
11350
11351 fi
11352
11353
11354 cat >>confdefs.h <<_ACEOF
11355 #define SSH_PRIVSEP_USER "$SSH_PRIVSEP_USER"
11356 _ACEOF
11357
11358
11359
11360 # Decide which sandbox style to use
11361 sandbox_arg=""
11362
11363 # Check whether --with-sandbox was given.
11364 if test "${with_sandbox+set}" = set; then :
11365   withval=$with_sandbox;
11366                 if test "x$withval" = "xyes" ; then
11367                         sandbox_arg=""
11368                 else
11369                         sandbox_arg="$withval"
11370                 fi
11371
11372
11373 fi
11374
11375 if test "x$sandbox_arg" = "xsystrace" || \
11376    ( test -z "$sandbox_arg" && test "x$have_systr_policy_kill" = "x1" ) ; then
11377         test "x$have_systr_policy_kill" != "x1" && \
11378                 as_fn_error $? "systrace sandbox requires systrace headers and SYSTR_POLICY_KILL support" "$LINENO" 5
11379         SANDBOX_STYLE="systrace"
11380
11381 $as_echo "#define SANDBOX_SYSTRACE 1" >>confdefs.h
11382
11383 elif test "x$sandbox_arg" = "xdarwin" || \
11384      ( test -z "$sandbox_arg" && test "x$ac_cv_func_sandbox_init" = "xyes" && \
11385        test "x$ac_cv_header_sandbox_h" = "xyes") ; then
11386         test "x$ac_cv_func_sandbox_init" != "xyes" -o \
11387              "x$ac_cv_header_sandbox_h" != "xyes" && \
11388                 as_fn_error $? "Darwin seatbelt sandbox requires sandbox.h and sandbox_init function" "$LINENO" 5
11389         SANDBOX_STYLE="darwin"
11390
11391 $as_echo "#define SANDBOX_DARWIN 1" >>confdefs.h
11392
11393 elif test "x$sandbox_arg" = "xrlimit" || \
11394      ( test -z "$sandbox_arg" && test "x$ac_cv_func_setrlimit" = "xyes" ) ; then
11395         test "x$ac_cv_func_setrlimit" != "xyes" && \
11396                 as_fn_error $? "rlimit sandbox requires setrlimit function" "$LINENO" 5
11397         SANDBOX_STYLE="rlimit"
11398
11399 $as_echo "#define SANDBOX_RLIMIT 1" >>confdefs.h
11400
11401 elif test -z "$sandbox_arg" || test "x$sandbox_arg" = "xno" || \
11402      test "x$sandbox_arg" = "xnone" || test "x$sandbox_arg" = "xnull" ; then
11403         SANDBOX_STYLE="none"
11404
11405 $as_echo "#define SANDBOX_NULL 1" >>confdefs.h
11406
11407 else
11408         as_fn_error $? "unsupported --with-sandbox" "$LINENO" 5
11409 fi
11410
11411 # Cheap hack to ensure NEWS-OS libraries are arranged right.
11412 if test ! -z "$SONY" ; then
11413   LIBS="$LIBS -liberty";
11414 fi
11415
11416 # Check for  long long datatypes
11417 ac_fn_c_check_type "$LINENO" "long long" "ac_cv_type_long_long" "$ac_includes_default"
11418 if test "x$ac_cv_type_long_long" = x""yes; then :
11419
11420 cat >>confdefs.h <<_ACEOF
11421 #define HAVE_LONG_LONG 1
11422 _ACEOF
11423
11424
11425 fi
11426 ac_fn_c_check_type "$LINENO" "unsigned long long" "ac_cv_type_unsigned_long_long" "$ac_includes_default"
11427 if test "x$ac_cv_type_unsigned_long_long" = x""yes; then :
11428
11429 cat >>confdefs.h <<_ACEOF
11430 #define HAVE_UNSIGNED_LONG_LONG 1
11431 _ACEOF
11432
11433
11434 fi
11435 ac_fn_c_check_type "$LINENO" "long double" "ac_cv_type_long_double" "$ac_includes_default"
11436 if test "x$ac_cv_type_long_double" = x""yes; then :
11437
11438 cat >>confdefs.h <<_ACEOF
11439 #define HAVE_LONG_DOUBLE 1
11440 _ACEOF
11441
11442
11443 fi
11444
11445
11446 # Check datatype sizes
11447 # The cast to long int works around a bug in the HP C Compiler
11448 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
11449 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
11450 # This bug is HP SR number 8606223364.
11451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of char" >&5
11452 $as_echo_n "checking size of char... " >&6; }
11453 if test "${ac_cv_sizeof_char+set}" = set; then :
11454   $as_echo_n "(cached) " >&6
11455 else
11456   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (char))" "ac_cv_sizeof_char"        "$ac_includes_default"; then :
11457
11458 else
11459   if test "$ac_cv_type_char" = yes; then
11460      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11461 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11462 as_fn_error 77 "cannot compute sizeof (char)
11463 See \`config.log' for more details" "$LINENO" 5 ; }
11464    else
11465      ac_cv_sizeof_char=0
11466    fi
11467 fi
11468
11469 fi
11470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_char" >&5
11471 $as_echo "$ac_cv_sizeof_char" >&6; }
11472
11473
11474
11475 cat >>confdefs.h <<_ACEOF
11476 #define SIZEOF_CHAR $ac_cv_sizeof_char
11477 _ACEOF
11478
11479
11480 # The cast to long int works around a bug in the HP C Compiler
11481 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
11482 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
11483 # This bug is HP SR number 8606223364.
11484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of short int" >&5
11485 $as_echo_n "checking size of short int... " >&6; }
11486 if test "${ac_cv_sizeof_short_int+set}" = set; then :
11487   $as_echo_n "(cached) " >&6
11488 else
11489   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (short int))" "ac_cv_sizeof_short_int"        "$ac_includes_default"; then :
11490
11491 else
11492   if test "$ac_cv_type_short_int" = yes; then
11493      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11494 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11495 as_fn_error 77 "cannot compute sizeof (short int)
11496 See \`config.log' for more details" "$LINENO" 5 ; }
11497    else
11498      ac_cv_sizeof_short_int=0
11499    fi
11500 fi
11501
11502 fi
11503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_short_int" >&5
11504 $as_echo "$ac_cv_sizeof_short_int" >&6; }
11505
11506
11507
11508 cat >>confdefs.h <<_ACEOF
11509 #define SIZEOF_SHORT_INT $ac_cv_sizeof_short_int
11510 _ACEOF
11511
11512
11513 # The cast to long int works around a bug in the HP C Compiler
11514 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
11515 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
11516 # This bug is HP SR number 8606223364.
11517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int" >&5
11518 $as_echo_n "checking size of int... " >&6; }
11519 if test "${ac_cv_sizeof_int+set}" = set; then :
11520   $as_echo_n "(cached) " >&6
11521 else
11522   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (int))" "ac_cv_sizeof_int"        "$ac_includes_default"; then :
11523
11524 else
11525   if test "$ac_cv_type_int" = yes; then
11526      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11527 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11528 as_fn_error 77 "cannot compute sizeof (int)
11529 See \`config.log' for more details" "$LINENO" 5 ; }
11530    else
11531      ac_cv_sizeof_int=0
11532    fi
11533 fi
11534
11535 fi
11536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int" >&5
11537 $as_echo "$ac_cv_sizeof_int" >&6; }
11538
11539
11540
11541 cat >>confdefs.h <<_ACEOF
11542 #define SIZEOF_INT $ac_cv_sizeof_int
11543 _ACEOF
11544
11545
11546 # The cast to long int works around a bug in the HP C Compiler
11547 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
11548 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
11549 # This bug is HP SR number 8606223364.
11550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long int" >&5
11551 $as_echo_n "checking size of long int... " >&6; }
11552 if test "${ac_cv_sizeof_long_int+set}" = set; then :
11553   $as_echo_n "(cached) " >&6
11554 else
11555   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long int))" "ac_cv_sizeof_long_int"        "$ac_includes_default"; then :
11556
11557 else
11558   if test "$ac_cv_type_long_int" = yes; then
11559      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11560 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11561 as_fn_error 77 "cannot compute sizeof (long int)
11562 See \`config.log' for more details" "$LINENO" 5 ; }
11563    else
11564      ac_cv_sizeof_long_int=0
11565    fi
11566 fi
11567
11568 fi
11569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_int" >&5
11570 $as_echo "$ac_cv_sizeof_long_int" >&6; }
11571
11572
11573
11574 cat >>confdefs.h <<_ACEOF
11575 #define SIZEOF_LONG_INT $ac_cv_sizeof_long_int
11576 _ACEOF
11577
11578
11579 # The cast to long int works around a bug in the HP C Compiler
11580 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
11581 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
11582 # This bug is HP SR number 8606223364.
11583 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of long long int" >&5
11584 $as_echo_n "checking size of long long int... " >&6; }
11585 if test "${ac_cv_sizeof_long_long_int+set}" = set; then :
11586   $as_echo_n "(cached) " >&6
11587 else
11588   if ac_fn_c_compute_int "$LINENO" "(long int) (sizeof (long long int))" "ac_cv_sizeof_long_long_int"        "$ac_includes_default"; then :
11589
11590 else
11591   if test "$ac_cv_type_long_long_int" = yes; then
11592      { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
11593 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
11594 as_fn_error 77 "cannot compute sizeof (long long int)
11595 See \`config.log' for more details" "$LINENO" 5 ; }
11596    else
11597      ac_cv_sizeof_long_long_int=0
11598    fi
11599 fi
11600
11601 fi
11602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_long_long_int" >&5
11603 $as_echo "$ac_cv_sizeof_long_long_int" >&6; }
11604
11605
11606
11607 cat >>confdefs.h <<_ACEOF
11608 #define SIZEOF_LONG_LONG_INT $ac_cv_sizeof_long_long_int
11609 _ACEOF
11610
11611
11612
11613 # Sanity check long long for some platforms (AIX)
11614 if test "x$ac_cv_sizeof_long_long_int" = "x4" ; then
11615         ac_cv_sizeof_long_long_int=0
11616 fi
11617
11618 # compute LLONG_MIN and LLONG_MAX if we don't know them.
11619 if test -z "$have_llong_max"; then
11620         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for max value of long long" >&5
11621 $as_echo_n "checking for max value of long long... " >&6; }
11622         if test "$cross_compiling" = yes; then :
11623
11624                         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking" >&5
11625 $as_echo "$as_me: WARNING: cross compiling: not checking" >&2;}
11626
11627
11628 else
11629   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11630 /* end confdefs.h.  */
11631
11632 #include <stdio.h>
11633 /* Why is this so damn hard? */
11634 #ifdef __GNUC__
11635 # undef __GNUC__
11636 #endif
11637 #define __USE_ISOC99
11638 #include <limits.h>
11639 #define DATA "conftest.llminmax"
11640 #define my_abs(a) ((a) < 0 ? ((a) * -1) : (a))
11641
11642 /*
11643  * printf in libc on some platforms (eg old Tru64) does not understand %lld so
11644  * we do this the hard way.
11645  */
11646 static int
11647 fprint_ll(FILE *f, long long n)
11648 {
11649         unsigned int i;
11650         int l[sizeof(long long) * 8];
11651
11652         if (n < 0)
11653                 if (fprintf(f, "-") < 0)
11654                         return -1;
11655         for (i = 0; n != 0; i++) {
11656                 l[i] = my_abs(n % 10);
11657                 n /= 10;
11658         }
11659         do {
11660                 if (fprintf(f, "%d", l[--i]) < 0)
11661                         return -1;
11662         } while (i != 0);
11663         if (fprintf(f, " ") < 0)
11664                 return -1;
11665         return 0;
11666 }
11667
11668 int
11669 main ()
11670 {
11671
11672         FILE *f;
11673         long long i, llmin, llmax = 0;
11674
11675         if((f = fopen(DATA,"w")) == NULL)
11676                 exit(1);
11677
11678 #if defined(LLONG_MIN) && defined(LLONG_MAX)
11679         fprintf(stderr, "Using system header for LLONG_MIN and LLONG_MAX\n");
11680         llmin = LLONG_MIN;
11681         llmax = LLONG_MAX;
11682 #else
11683         fprintf(stderr, "Calculating  LLONG_MIN and LLONG_MAX\n");
11684         /* This will work on one's complement and two's complement */
11685         for (i = 1; i > llmax; i <<= 1, i++)
11686                 llmax = i;
11687         llmin = llmax + 1LL;    /* wrap */
11688 #endif
11689
11690         /* Sanity check */
11691         if (llmin + 1 < llmin || llmin - 1 < llmin || llmax + 1 > llmax
11692             || llmax - 1 > llmax || llmin == llmax || llmin == 0
11693             || llmax == 0 || llmax < LONG_MAX || llmin > LONG_MIN) {
11694                 fprintf(f, "unknown unknown\n");
11695                 exit(2);
11696         }
11697
11698         if (fprint_ll(f, llmin) < 0)
11699                 exit(3);
11700         if (fprint_ll(f, llmax) < 0)
11701                 exit(4);
11702         if (fclose(f) < 0)
11703                 exit(5);
11704         exit(0);
11705
11706   ;
11707   return 0;
11708 }
11709 _ACEOF
11710 if ac_fn_c_try_run "$LINENO"; then :
11711
11712                         llong_min=`$AWK '{print $1}' conftest.llminmax`
11713                         llong_max=`$AWK '{print $2}' conftest.llminmax`
11714
11715                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $llong_max" >&5
11716 $as_echo "$llong_max" >&6; }
11717
11718 cat >>confdefs.h <<_ACEOF
11719 #define LLONG_MAX ${llong_max}LL
11720 _ACEOF
11721
11722                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for min value of long long" >&5
11723 $as_echo_n "checking for min value of long long... " >&6; }
11724                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: $llong_min" >&5
11725 $as_echo "$llong_min" >&6; }
11726
11727 cat >>confdefs.h <<_ACEOF
11728 #define LLONG_MIN ${llong_min}LL
11729 _ACEOF
11730
11731
11732 else
11733
11734                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5
11735 $as_echo "not found" >&6; }
11736
11737 fi
11738 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
11739   conftest.$ac_objext conftest.beam conftest.$ac_ext
11740 fi
11741
11742 fi
11743
11744
11745 # More checks for data types
11746 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for u_int type" >&5
11747 $as_echo_n "checking for u_int type... " >&6; }
11748 if test "${ac_cv_have_u_int+set}" = set; then :
11749   $as_echo_n "(cached) " >&6
11750 else
11751
11752         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11753 /* end confdefs.h.  */
11754  #include <sys/types.h>
11755 int
11756 main ()
11757 {
11758  u_int a; a = 1;
11759   ;
11760   return 0;
11761 }
11762 _ACEOF
11763 if ac_fn_c_try_compile "$LINENO"; then :
11764    ac_cv_have_u_int="yes"
11765 else
11766    ac_cv_have_u_int="no"
11767
11768 fi
11769 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11770
11771 fi
11772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_u_int" >&5
11773 $as_echo "$ac_cv_have_u_int" >&6; }
11774 if test "x$ac_cv_have_u_int" = "xyes" ; then
11775
11776 $as_echo "#define HAVE_U_INT 1" >>confdefs.h
11777
11778         have_u_int=1
11779 fi
11780
11781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for intXX_t types" >&5
11782 $as_echo_n "checking for intXX_t types... " >&6; }
11783 if test "${ac_cv_have_intxx_t+set}" = set; then :
11784   $as_echo_n "(cached) " >&6
11785 else
11786
11787         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11788 /* end confdefs.h.  */
11789  #include <sys/types.h>
11790 int
11791 main ()
11792 {
11793  int8_t a; int16_t b; int32_t c; a = b = c = 1;
11794   ;
11795   return 0;
11796 }
11797 _ACEOF
11798 if ac_fn_c_try_compile "$LINENO"; then :
11799    ac_cv_have_intxx_t="yes"
11800 else
11801    ac_cv_have_intxx_t="no"
11802
11803 fi
11804 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11805
11806 fi
11807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_intxx_t" >&5
11808 $as_echo "$ac_cv_have_intxx_t" >&6; }
11809 if test "x$ac_cv_have_intxx_t" = "xyes" ; then
11810
11811 $as_echo "#define HAVE_INTXX_T 1" >>confdefs.h
11812
11813         have_intxx_t=1
11814 fi
11815
11816 if (test -z "$have_intxx_t" && \
11817            test "x$ac_cv_header_stdint_h" = "xyes")
11818 then
11819     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for intXX_t types in stdint.h" >&5
11820 $as_echo_n "checking for intXX_t types in stdint.h... " >&6; }
11821         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11822 /* end confdefs.h.  */
11823  #include <stdint.h>
11824 int
11825 main ()
11826 {
11827  int8_t a; int16_t b; int32_t c; a = b = c = 1;
11828   ;
11829   return 0;
11830 }
11831 _ACEOF
11832 if ac_fn_c_try_compile "$LINENO"; then :
11833
11834                         $as_echo "#define HAVE_INTXX_T 1" >>confdefs.h
11835
11836                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11837 $as_echo "yes" >&6; }
11838
11839 else
11840    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11841 $as_echo "no" >&6; }
11842
11843 fi
11844 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11845 fi
11846
11847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for int64_t type" >&5
11848 $as_echo_n "checking for int64_t type... " >&6; }
11849 if test "${ac_cv_have_int64_t+set}" = set; then :
11850   $as_echo_n "(cached) " >&6
11851 else
11852
11853         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11854 /* end confdefs.h.  */
11855
11856 #include <sys/types.h>
11857 #ifdef HAVE_STDINT_H
11858 # include <stdint.h>
11859 #endif
11860 #include <sys/socket.h>
11861 #ifdef HAVE_SYS_BITYPES_H
11862 # include <sys/bitypes.h>
11863 #endif
11864
11865 int
11866 main ()
11867 {
11868
11869 int64_t a; a = 1;
11870
11871   ;
11872   return 0;
11873 }
11874 _ACEOF
11875 if ac_fn_c_try_compile "$LINENO"; then :
11876    ac_cv_have_int64_t="yes"
11877 else
11878    ac_cv_have_int64_t="no"
11879
11880 fi
11881 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11882
11883 fi
11884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_int64_t" >&5
11885 $as_echo "$ac_cv_have_int64_t" >&6; }
11886 if test "x$ac_cv_have_int64_t" = "xyes" ; then
11887
11888 $as_echo "#define HAVE_INT64_T 1" >>confdefs.h
11889
11890 fi
11891
11892 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for u_intXX_t types" >&5
11893 $as_echo_n "checking for u_intXX_t types... " >&6; }
11894 if test "${ac_cv_have_u_intxx_t+set}" = set; then :
11895   $as_echo_n "(cached) " >&6
11896 else
11897
11898         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11899 /* end confdefs.h.  */
11900  #include <sys/types.h>
11901 int
11902 main ()
11903 {
11904  u_int8_t a; u_int16_t b; u_int32_t c; a = b = c = 1;
11905   ;
11906   return 0;
11907 }
11908 _ACEOF
11909 if ac_fn_c_try_compile "$LINENO"; then :
11910    ac_cv_have_u_intxx_t="yes"
11911 else
11912    ac_cv_have_u_intxx_t="no"
11913
11914 fi
11915 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11916
11917 fi
11918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_u_intxx_t" >&5
11919 $as_echo "$ac_cv_have_u_intxx_t" >&6; }
11920 if test "x$ac_cv_have_u_intxx_t" = "xyes" ; then
11921
11922 $as_echo "#define HAVE_U_INTXX_T 1" >>confdefs.h
11923
11924         have_u_intxx_t=1
11925 fi
11926
11927 if test -z "$have_u_intxx_t" ; then
11928     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for u_intXX_t types in sys/socket.h" >&5
11929 $as_echo_n "checking for u_intXX_t types in sys/socket.h... " >&6; }
11930         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11931 /* end confdefs.h.  */
11932  #include <sys/socket.h>
11933 int
11934 main ()
11935 {
11936  u_int8_t a; u_int16_t b; u_int32_t c; a = b = c = 1;
11937   ;
11938   return 0;
11939 }
11940 _ACEOF
11941 if ac_fn_c_try_compile "$LINENO"; then :
11942
11943                         $as_echo "#define HAVE_U_INTXX_T 1" >>confdefs.h
11944
11945                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
11946 $as_echo "yes" >&6; }
11947
11948 else
11949    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
11950 $as_echo "no" >&6; }
11951
11952 fi
11953 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11954 fi
11955
11956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for u_int64_t types" >&5
11957 $as_echo_n "checking for u_int64_t types... " >&6; }
11958 if test "${ac_cv_have_u_int64_t+set}" = set; then :
11959   $as_echo_n "(cached) " >&6
11960 else
11961
11962         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11963 /* end confdefs.h.  */
11964  #include <sys/types.h>
11965 int
11966 main ()
11967 {
11968  u_int64_t a; a = 1;
11969   ;
11970   return 0;
11971 }
11972 _ACEOF
11973 if ac_fn_c_try_compile "$LINENO"; then :
11974    ac_cv_have_u_int64_t="yes"
11975 else
11976    ac_cv_have_u_int64_t="no"
11977
11978 fi
11979 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11980
11981 fi
11982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_u_int64_t" >&5
11983 $as_echo "$ac_cv_have_u_int64_t" >&6; }
11984 if test "x$ac_cv_have_u_int64_t" = "xyes" ; then
11985
11986 $as_echo "#define HAVE_U_INT64_T 1" >>confdefs.h
11987
11988         have_u_int64_t=1
11989 fi
11990
11991 if test -z "$have_u_int64_t" ; then
11992     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for u_int64_t type in sys/bitypes.h" >&5
11993 $as_echo_n "checking for u_int64_t type in sys/bitypes.h... " >&6; }
11994         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
11995 /* end confdefs.h.  */
11996  #include <sys/bitypes.h>
11997 int
11998 main ()
11999 {
12000  u_int64_t a; a = 1
12001   ;
12002   return 0;
12003 }
12004 _ACEOF
12005 if ac_fn_c_try_compile "$LINENO"; then :
12006
12007                         $as_echo "#define HAVE_U_INT64_T 1" >>confdefs.h
12008
12009                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12010 $as_echo "yes" >&6; }
12011
12012 else
12013    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12014 $as_echo "no" >&6; }
12015
12016 fi
12017 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12018 fi
12019
12020 if test -z "$have_u_intxx_t" ; then
12021         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uintXX_t types" >&5
12022 $as_echo_n "checking for uintXX_t types... " >&6; }
12023 if test "${ac_cv_have_uintxx_t+set}" = set; then :
12024   $as_echo_n "(cached) " >&6
12025 else
12026
12027                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12028 /* end confdefs.h.  */
12029
12030 #include <sys/types.h>
12031
12032 int
12033 main ()
12034 {
12035
12036         uint8_t a;
12037         uint16_t b;
12038         uint32_t c;
12039         a = b = c = 1;
12040
12041   ;
12042   return 0;
12043 }
12044 _ACEOF
12045 if ac_fn_c_try_compile "$LINENO"; then :
12046    ac_cv_have_uintxx_t="yes"
12047 else
12048    ac_cv_have_uintxx_t="no"
12049
12050 fi
12051 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12052
12053 fi
12054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_uintxx_t" >&5
12055 $as_echo "$ac_cv_have_uintxx_t" >&6; }
12056         if test "x$ac_cv_have_uintxx_t" = "xyes" ; then
12057
12058 $as_echo "#define HAVE_UINTXX_T 1" >>confdefs.h
12059
12060         fi
12061 fi
12062
12063 if test -z "$have_uintxx_t" ; then
12064     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for uintXX_t types in stdint.h" >&5
12065 $as_echo_n "checking for uintXX_t types in stdint.h... " >&6; }
12066         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12067 /* end confdefs.h.  */
12068  #include <stdint.h>
12069 int
12070 main ()
12071 {
12072  uint8_t a; uint16_t b; uint32_t c; a = b = c = 1;
12073   ;
12074   return 0;
12075 }
12076 _ACEOF
12077 if ac_fn_c_try_compile "$LINENO"; then :
12078
12079                         $as_echo "#define HAVE_UINTXX_T 1" >>confdefs.h
12080
12081                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12082 $as_echo "yes" >&6; }
12083
12084 else
12085    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12086 $as_echo "no" >&6; }
12087
12088 fi
12089 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12090 fi
12091
12092 if (test -z "$have_u_intxx_t" || test -z "$have_intxx_t" && \
12093            test "x$ac_cv_header_sys_bitypes_h" = "xyes")
12094 then
12095         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for intXX_t and u_intXX_t types in sys/bitypes.h" >&5
12096 $as_echo_n "checking for intXX_t and u_intXX_t types in sys/bitypes.h... " >&6; }
12097         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12098 /* end confdefs.h.  */
12099
12100 #include <sys/bitypes.h>
12101
12102 int
12103 main ()
12104 {
12105
12106                         int8_t a; int16_t b; int32_t c;
12107                         u_int8_t e; u_int16_t f; u_int32_t g;
12108                         a = b = c = e = f = g = 1;
12109
12110   ;
12111   return 0;
12112 }
12113 _ACEOF
12114 if ac_fn_c_try_compile "$LINENO"; then :
12115
12116                         $as_echo "#define HAVE_U_INTXX_T 1" >>confdefs.h
12117
12118                         $as_echo "#define HAVE_INTXX_T 1" >>confdefs.h
12119
12120                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
12121 $as_echo "yes" >&6; }
12122
12123 else
12124   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12125 $as_echo "no" >&6; }
12126
12127 fi
12128 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12129 fi
12130
12131
12132 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for u_char" >&5
12133 $as_echo_n "checking for u_char... " >&6; }
12134 if test "${ac_cv_have_u_char+set}" = set; then :
12135   $as_echo_n "(cached) " >&6
12136 else
12137
12138         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12139 /* end confdefs.h.  */
12140  #include <sys/types.h>
12141 int
12142 main ()
12143 {
12144  u_char foo; foo = 125;
12145   ;
12146   return 0;
12147 }
12148 _ACEOF
12149 if ac_fn_c_try_compile "$LINENO"; then :
12150    ac_cv_have_u_char="yes"
12151 else
12152    ac_cv_have_u_char="no"
12153
12154 fi
12155 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12156
12157 fi
12158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_u_char" >&5
12159 $as_echo "$ac_cv_have_u_char" >&6; }
12160 if test "x$ac_cv_have_u_char" = "xyes" ; then
12161
12162 $as_echo "#define HAVE_U_CHAR 1" >>confdefs.h
12163
12164 fi
12165
12166
12167    ac_fn_c_check_type "$LINENO" "socklen_t" "ac_cv_type_socklen_t" "#include <sys/types.h>
12168 #include <sys/socket.h>
12169 "
12170 if test "x$ac_cv_type_socklen_t" = x""yes; then :
12171
12172 else
12173
12174       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for socklen_t equivalent" >&5
12175 $as_echo_n "checking for socklen_t equivalent... " >&6; }
12176       if test "${curl_cv_socklen_t_equiv+set}" = set; then :
12177   $as_echo_n "(cached) " >&6
12178 else
12179
12180          # Systems have either "struct sockaddr *" or
12181          # "void *" as the second argument to getpeername
12182          curl_cv_socklen_t_equiv=
12183          for arg2 in "struct sockaddr" void; do
12184             for t in int size_t unsigned long "unsigned long"; do
12185                cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12186 /* end confdefs.h.  */
12187
12188                   #include <sys/types.h>
12189                   #include <sys/socket.h>
12190
12191                   int getpeername (int, $arg2 *, $t *);
12192
12193 int
12194 main ()
12195 {
12196
12197                   $t len;
12198                   getpeername(0,0,&len);
12199
12200   ;
12201   return 0;
12202 }
12203 _ACEOF
12204 if ac_fn_c_try_compile "$LINENO"; then :
12205
12206                   curl_cv_socklen_t_equiv="$t"
12207                   break
12208
12209 fi
12210 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12211             done
12212          done
12213
12214          if test "x$curl_cv_socklen_t_equiv" = x; then
12215             as_fn_error $? "Cannot find a type to use in place of socklen_t" "$LINENO" 5
12216          fi
12217
12218 fi
12219
12220       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $curl_cv_socklen_t_equiv" >&5
12221 $as_echo "$curl_cv_socklen_t_equiv" >&6; }
12222
12223 cat >>confdefs.h <<_ACEOF
12224 #define socklen_t $curl_cv_socklen_t_equiv
12225 _ACEOF
12226
12227 fi
12228
12229
12230
12231 ac_fn_c_check_type "$LINENO" "sig_atomic_t" "ac_cv_type_sig_atomic_t" "#include <signal.h>
12232 "
12233 if test "x$ac_cv_type_sig_atomic_t" = x""yes; then :
12234
12235 cat >>confdefs.h <<_ACEOF
12236 #define HAVE_SIG_ATOMIC_T 1
12237 _ACEOF
12238
12239
12240 fi
12241
12242 ac_fn_c_check_type "$LINENO" "fsblkcnt_t" "ac_cv_type_fsblkcnt_t" "
12243 #include <sys/types.h>
12244 #ifdef HAVE_SYS_BITYPES_H
12245 #include <sys/bitypes.h>
12246 #endif
12247 #ifdef HAVE_SYS_STATFS_H
12248 #include <sys/statfs.h>
12249 #endif
12250 #ifdef HAVE_SYS_STATVFS_H
12251 #include <sys/statvfs.h>
12252 #endif
12253
12254 "
12255 if test "x$ac_cv_type_fsblkcnt_t" = x""yes; then :
12256
12257 cat >>confdefs.h <<_ACEOF
12258 #define HAVE_FSBLKCNT_T 1
12259 _ACEOF
12260
12261
12262 fi
12263 ac_fn_c_check_type "$LINENO" "fsfilcnt_t" "ac_cv_type_fsfilcnt_t" "
12264 #include <sys/types.h>
12265 #ifdef HAVE_SYS_BITYPES_H
12266 #include <sys/bitypes.h>
12267 #endif
12268 #ifdef HAVE_SYS_STATFS_H
12269 #include <sys/statfs.h>
12270 #endif
12271 #ifdef HAVE_SYS_STATVFS_H
12272 #include <sys/statvfs.h>
12273 #endif
12274
12275 "
12276 if test "x$ac_cv_type_fsfilcnt_t" = x""yes; then :
12277
12278 cat >>confdefs.h <<_ACEOF
12279 #define HAVE_FSFILCNT_T 1
12280 _ACEOF
12281
12282
12283 fi
12284
12285
12286 ac_fn_c_check_type "$LINENO" "in_addr_t" "ac_cv_type_in_addr_t" "#include <sys/types.h>
12287 #include <netinet/in.h>
12288 "
12289 if test "x$ac_cv_type_in_addr_t" = x""yes; then :
12290
12291 cat >>confdefs.h <<_ACEOF
12292 #define HAVE_IN_ADDR_T 1
12293 _ACEOF
12294
12295
12296 fi
12297 ac_fn_c_check_type "$LINENO" "in_port_t" "ac_cv_type_in_port_t" "#include <sys/types.h>
12298 #include <netinet/in.h>
12299 "
12300 if test "x$ac_cv_type_in_port_t" = x""yes; then :
12301
12302 cat >>confdefs.h <<_ACEOF
12303 #define HAVE_IN_PORT_T 1
12304 _ACEOF
12305
12306
12307 fi
12308
12309
12310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for size_t" >&5
12311 $as_echo_n "checking for size_t... " >&6; }
12312 if test "${ac_cv_have_size_t+set}" = set; then :
12313   $as_echo_n "(cached) " >&6
12314 else
12315
12316         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12317 /* end confdefs.h.  */
12318  #include <sys/types.h>
12319 int
12320 main ()
12321 {
12322  size_t foo; foo = 1235;
12323   ;
12324   return 0;
12325 }
12326 _ACEOF
12327 if ac_fn_c_try_compile "$LINENO"; then :
12328    ac_cv_have_size_t="yes"
12329 else
12330    ac_cv_have_size_t="no"
12331
12332 fi
12333 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12334
12335 fi
12336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_size_t" >&5
12337 $as_echo "$ac_cv_have_size_t" >&6; }
12338 if test "x$ac_cv_have_size_t" = "xyes" ; then
12339
12340 $as_echo "#define HAVE_SIZE_T 1" >>confdefs.h
12341
12342 fi
12343
12344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ssize_t" >&5
12345 $as_echo_n "checking for ssize_t... " >&6; }
12346 if test "${ac_cv_have_ssize_t+set}" = set; then :
12347   $as_echo_n "(cached) " >&6
12348 else
12349
12350         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12351 /* end confdefs.h.  */
12352  #include <sys/types.h>
12353 int
12354 main ()
12355 {
12356  ssize_t foo; foo = 1235;
12357   ;
12358   return 0;
12359 }
12360 _ACEOF
12361 if ac_fn_c_try_compile "$LINENO"; then :
12362    ac_cv_have_ssize_t="yes"
12363 else
12364    ac_cv_have_ssize_t="no"
12365
12366 fi
12367 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12368
12369 fi
12370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_ssize_t" >&5
12371 $as_echo "$ac_cv_have_ssize_t" >&6; }
12372 if test "x$ac_cv_have_ssize_t" = "xyes" ; then
12373
12374 $as_echo "#define HAVE_SSIZE_T 1" >>confdefs.h
12375
12376 fi
12377
12378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for clock_t" >&5
12379 $as_echo_n "checking for clock_t... " >&6; }
12380 if test "${ac_cv_have_clock_t+set}" = set; then :
12381   $as_echo_n "(cached) " >&6
12382 else
12383
12384         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12385 /* end confdefs.h.  */
12386  #include <time.h>
12387 int
12388 main ()
12389 {
12390  clock_t foo; foo = 1235;
12391   ;
12392   return 0;
12393 }
12394 _ACEOF
12395 if ac_fn_c_try_compile "$LINENO"; then :
12396    ac_cv_have_clock_t="yes"
12397 else
12398    ac_cv_have_clock_t="no"
12399
12400 fi
12401 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12402
12403 fi
12404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_clock_t" >&5
12405 $as_echo "$ac_cv_have_clock_t" >&6; }
12406 if test "x$ac_cv_have_clock_t" = "xyes" ; then
12407
12408 $as_echo "#define HAVE_CLOCK_T 1" >>confdefs.h
12409
12410 fi
12411
12412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sa_family_t" >&5
12413 $as_echo_n "checking for sa_family_t... " >&6; }
12414 if test "${ac_cv_have_sa_family_t+set}" = set; then :
12415   $as_echo_n "(cached) " >&6
12416 else
12417
12418         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12419 /* end confdefs.h.  */
12420
12421 #include <sys/types.h>
12422 #include <sys/socket.h>
12423
12424 int
12425 main ()
12426 {
12427  sa_family_t foo; foo = 1235;
12428   ;
12429   return 0;
12430 }
12431 _ACEOF
12432 if ac_fn_c_try_compile "$LINENO"; then :
12433    ac_cv_have_sa_family_t="yes"
12434 else
12435    cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12436 /* end confdefs.h.  */
12437
12438 #include <sys/types.h>
12439 #include <sys/socket.h>
12440 #include <netinet/in.h>
12441
12442 int
12443 main ()
12444 {
12445  sa_family_t foo; foo = 1235;
12446   ;
12447   return 0;
12448 }
12449 _ACEOF
12450 if ac_fn_c_try_compile "$LINENO"; then :
12451    ac_cv_have_sa_family_t="yes"
12452 else
12453    ac_cv_have_sa_family_t="no"
12454
12455 fi
12456 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12457
12458 fi
12459 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12460
12461 fi
12462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_sa_family_t" >&5
12463 $as_echo "$ac_cv_have_sa_family_t" >&6; }
12464 if test "x$ac_cv_have_sa_family_t" = "xyes" ; then
12465
12466 $as_echo "#define HAVE_SA_FAMILY_T 1" >>confdefs.h
12467
12468 fi
12469
12470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pid_t" >&5
12471 $as_echo_n "checking for pid_t... " >&6; }
12472 if test "${ac_cv_have_pid_t+set}" = set; then :
12473   $as_echo_n "(cached) " >&6
12474 else
12475
12476         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12477 /* end confdefs.h.  */
12478  #include <sys/types.h>
12479 int
12480 main ()
12481 {
12482  pid_t foo; foo = 1235;
12483   ;
12484   return 0;
12485 }
12486 _ACEOF
12487 if ac_fn_c_try_compile "$LINENO"; then :
12488    ac_cv_have_pid_t="yes"
12489 else
12490    ac_cv_have_pid_t="no"
12491
12492 fi
12493 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12494
12495 fi
12496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_pid_t" >&5
12497 $as_echo "$ac_cv_have_pid_t" >&6; }
12498 if test "x$ac_cv_have_pid_t" = "xyes" ; then
12499
12500 $as_echo "#define HAVE_PID_T 1" >>confdefs.h
12501
12502 fi
12503
12504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for mode_t" >&5
12505 $as_echo_n "checking for mode_t... " >&6; }
12506 if test "${ac_cv_have_mode_t+set}" = set; then :
12507   $as_echo_n "(cached) " >&6
12508 else
12509
12510         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12511 /* end confdefs.h.  */
12512  #include <sys/types.h>
12513 int
12514 main ()
12515 {
12516  mode_t foo; foo = 1235;
12517   ;
12518   return 0;
12519 }
12520 _ACEOF
12521 if ac_fn_c_try_compile "$LINENO"; then :
12522    ac_cv_have_mode_t="yes"
12523 else
12524    ac_cv_have_mode_t="no"
12525
12526 fi
12527 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12528
12529 fi
12530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_mode_t" >&5
12531 $as_echo "$ac_cv_have_mode_t" >&6; }
12532 if test "x$ac_cv_have_mode_t" = "xyes" ; then
12533
12534 $as_echo "#define HAVE_MODE_T 1" >>confdefs.h
12535
12536 fi
12537
12538
12539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct sockaddr_storage" >&5
12540 $as_echo_n "checking for struct sockaddr_storage... " >&6; }
12541 if test "${ac_cv_have_struct_sockaddr_storage+set}" = set; then :
12542   $as_echo_n "(cached) " >&6
12543 else
12544
12545         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12546 /* end confdefs.h.  */
12547
12548 #include <sys/types.h>
12549 #include <sys/socket.h>
12550
12551 int
12552 main ()
12553 {
12554  struct sockaddr_storage s;
12555   ;
12556   return 0;
12557 }
12558 _ACEOF
12559 if ac_fn_c_try_compile "$LINENO"; then :
12560    ac_cv_have_struct_sockaddr_storage="yes"
12561 else
12562    ac_cv_have_struct_sockaddr_storage="no"
12563
12564 fi
12565 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12566
12567 fi
12568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_struct_sockaddr_storage" >&5
12569 $as_echo "$ac_cv_have_struct_sockaddr_storage" >&6; }
12570 if test "x$ac_cv_have_struct_sockaddr_storage" = "xyes" ; then
12571
12572 $as_echo "#define HAVE_STRUCT_SOCKADDR_STORAGE 1" >>confdefs.h
12573
12574 fi
12575
12576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct sockaddr_in6" >&5
12577 $as_echo_n "checking for struct sockaddr_in6... " >&6; }
12578 if test "${ac_cv_have_struct_sockaddr_in6+set}" = set; then :
12579   $as_echo_n "(cached) " >&6
12580 else
12581
12582         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12583 /* end confdefs.h.  */
12584
12585 #include <sys/types.h>
12586 #include <netinet/in.h>
12587
12588 int
12589 main ()
12590 {
12591  struct sockaddr_in6 s; s.sin6_family = 0;
12592   ;
12593   return 0;
12594 }
12595 _ACEOF
12596 if ac_fn_c_try_compile "$LINENO"; then :
12597    ac_cv_have_struct_sockaddr_in6="yes"
12598 else
12599    ac_cv_have_struct_sockaddr_in6="no"
12600
12601 fi
12602 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12603
12604 fi
12605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_struct_sockaddr_in6" >&5
12606 $as_echo "$ac_cv_have_struct_sockaddr_in6" >&6; }
12607 if test "x$ac_cv_have_struct_sockaddr_in6" = "xyes" ; then
12608
12609 $as_echo "#define HAVE_STRUCT_SOCKADDR_IN6 1" >>confdefs.h
12610
12611 fi
12612
12613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct in6_addr" >&5
12614 $as_echo_n "checking for struct in6_addr... " >&6; }
12615 if test "${ac_cv_have_struct_in6_addr+set}" = set; then :
12616   $as_echo_n "(cached) " >&6
12617 else
12618
12619         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12620 /* end confdefs.h.  */
12621
12622 #include <sys/types.h>
12623 #include <netinet/in.h>
12624
12625 int
12626 main ()
12627 {
12628  struct in6_addr s; s.s6_addr[0] = 0;
12629   ;
12630   return 0;
12631 }
12632 _ACEOF
12633 if ac_fn_c_try_compile "$LINENO"; then :
12634    ac_cv_have_struct_in6_addr="yes"
12635 else
12636    ac_cv_have_struct_in6_addr="no"
12637
12638 fi
12639 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12640
12641 fi
12642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_struct_in6_addr" >&5
12643 $as_echo "$ac_cv_have_struct_in6_addr" >&6; }
12644 if test "x$ac_cv_have_struct_in6_addr" = "xyes" ; then
12645
12646 $as_echo "#define HAVE_STRUCT_IN6_ADDR 1" >>confdefs.h
12647
12648
12649         ac_fn_c_check_member "$LINENO" "struct sockaddr_in6" "sin6_scope_id" "ac_cv_member_struct_sockaddr_in6_sin6_scope_id" "
12650 #ifdef HAVE_SYS_TYPES_H
12651 #include <sys/types.h>
12652 #endif
12653 #include <netinet/in.h>
12654
12655 "
12656 if test "x$ac_cv_member_struct_sockaddr_in6_sin6_scope_id" = x""yes; then :
12657
12658 cat >>confdefs.h <<_ACEOF
12659 #define HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID 1
12660 _ACEOF
12661
12662
12663 fi
12664
12665 fi
12666
12667 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct addrinfo" >&5
12668 $as_echo_n "checking for struct addrinfo... " >&6; }
12669 if test "${ac_cv_have_struct_addrinfo+set}" = set; then :
12670   $as_echo_n "(cached) " >&6
12671 else
12672
12673         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12674 /* end confdefs.h.  */
12675
12676 #include <sys/types.h>
12677 #include <sys/socket.h>
12678 #include <netdb.h>
12679
12680 int
12681 main ()
12682 {
12683  struct addrinfo s; s.ai_flags = AI_PASSIVE;
12684   ;
12685   return 0;
12686 }
12687 _ACEOF
12688 if ac_fn_c_try_compile "$LINENO"; then :
12689    ac_cv_have_struct_addrinfo="yes"
12690 else
12691    ac_cv_have_struct_addrinfo="no"
12692
12693 fi
12694 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12695
12696 fi
12697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_struct_addrinfo" >&5
12698 $as_echo "$ac_cv_have_struct_addrinfo" >&6; }
12699 if test "x$ac_cv_have_struct_addrinfo" = "xyes" ; then
12700
12701 $as_echo "#define HAVE_STRUCT_ADDRINFO 1" >>confdefs.h
12702
12703 fi
12704
12705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for struct timeval" >&5
12706 $as_echo_n "checking for struct timeval... " >&6; }
12707 if test "${ac_cv_have_struct_timeval+set}" = set; then :
12708   $as_echo_n "(cached) " >&6
12709 else
12710
12711         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12712 /* end confdefs.h.  */
12713  #include <sys/time.h>
12714 int
12715 main ()
12716 {
12717  struct timeval tv; tv.tv_sec = 1;
12718   ;
12719   return 0;
12720 }
12721 _ACEOF
12722 if ac_fn_c_try_compile "$LINENO"; then :
12723    ac_cv_have_struct_timeval="yes"
12724 else
12725    ac_cv_have_struct_timeval="no"
12726
12727 fi
12728 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12729
12730 fi
12731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_struct_timeval" >&5
12732 $as_echo "$ac_cv_have_struct_timeval" >&6; }
12733 if test "x$ac_cv_have_struct_timeval" = "xyes" ; then
12734
12735 $as_echo "#define HAVE_STRUCT_TIMEVAL 1" >>confdefs.h
12736
12737         have_struct_timeval=1
12738 fi
12739
12740 ac_fn_c_check_type "$LINENO" "struct timespec" "ac_cv_type_struct_timespec" "$ac_includes_default"
12741 if test "x$ac_cv_type_struct_timespec" = x""yes; then :
12742
12743 cat >>confdefs.h <<_ACEOF
12744 #define HAVE_STRUCT_TIMESPEC 1
12745 _ACEOF
12746
12747
12748 fi
12749
12750
12751 # We need int64_t or else certian parts of the compile will fail.
12752 if test "x$ac_cv_have_int64_t" = "xno" && \
12753         test "x$ac_cv_sizeof_long_int" != "x8" && \
12754         test "x$ac_cv_sizeof_long_long_int" = "x0" ; then
12755         echo "OpenSSH requires int64_t support.  Contact your vendor or install"
12756         echo "an alternative compiler (I.E., GCC) before continuing."
12757         echo ""
12758         exit 1;
12759 else
12760         if test "$cross_compiling" = yes; then :
12761   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: Assuming working snprintf()" >&5
12762 $as_echo "$as_me: WARNING: cross compiling: Assuming working snprintf()" >&2;}
12763
12764 else
12765   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12766 /* end confdefs.h.  */
12767
12768 #include <stdio.h>
12769 #include <string.h>
12770 #ifdef HAVE_SNPRINTF
12771 main()
12772 {
12773         char buf[50];
12774         char expected_out[50];
12775         int mazsize = 50 ;
12776 #if (SIZEOF_LONG_INT == 8)
12777         long int num = 0x7fffffffffffffff;
12778 #else
12779         long long num = 0x7fffffffffffffffll;
12780 #endif
12781         strcpy(expected_out, "9223372036854775807");
12782         snprintf(buf, mazsize, "%lld", num);
12783         if(strcmp(buf, expected_out) != 0)
12784                 exit(1);
12785         exit(0);
12786 }
12787 #else
12788 main() { exit(0); }
12789 #endif
12790
12791 _ACEOF
12792 if ac_fn_c_try_run "$LINENO"; then :
12793    true
12794 else
12795    $as_echo "#define BROKEN_SNPRINTF 1" >>confdefs.h
12796
12797 fi
12798 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
12799   conftest.$ac_objext conftest.beam conftest.$ac_ext
12800 fi
12801
12802 fi
12803
12804
12805 # look for field 'ut_host' in header 'utmp.h'
12806                 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
12807                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_host
12808         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_host field in utmp.h" >&5
12809 $as_echo_n "checking for ut_host field in utmp.h... " >&6; }
12810         if eval "test \"\${$ossh_varname+set}\"" = set; then :
12811   $as_echo_n "(cached) " >&6
12812 else
12813
12814                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12815 /* end confdefs.h.  */
12816 #include <utmp.h>
12817
12818 _ACEOF
12819 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12820   $EGREP "ut_host" >/dev/null 2>&1; then :
12821                         eval "$ossh_varname=yes"
12822 else
12823                         eval "$ossh_varname=no"
12824 fi
12825 rm -f conftest*
12826
12827 fi
12828
12829         ossh_result=`eval 'echo $'"$ossh_varname"`
12830         if test -n "`echo $ossh_varname`"; then
12831                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
12832 $as_echo "$ossh_result" >&6; }
12833                 if test "x$ossh_result" = "xyes"; then
12834
12835 $as_echo "#define HAVE_HOST_IN_UTMP 1" >>confdefs.h
12836
12837                 fi
12838         else
12839                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12840 $as_echo "no" >&6; }
12841         fi
12842
12843
12844 # look for field 'ut_host' in header 'utmpx.h'
12845                 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
12846                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_host
12847         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_host field in utmpx.h" >&5
12848 $as_echo_n "checking for ut_host field in utmpx.h... " >&6; }
12849         if eval "test \"\${$ossh_varname+set}\"" = set; then :
12850   $as_echo_n "(cached) " >&6
12851 else
12852
12853                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12854 /* end confdefs.h.  */
12855 #include <utmpx.h>
12856
12857 _ACEOF
12858 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12859   $EGREP "ut_host" >/dev/null 2>&1; then :
12860                         eval "$ossh_varname=yes"
12861 else
12862                         eval "$ossh_varname=no"
12863 fi
12864 rm -f conftest*
12865
12866 fi
12867
12868         ossh_result=`eval 'echo $'"$ossh_varname"`
12869         if test -n "`echo $ossh_varname`"; then
12870                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
12871 $as_echo "$ossh_result" >&6; }
12872                 if test "x$ossh_result" = "xyes"; then
12873
12874 $as_echo "#define HAVE_HOST_IN_UTMPX 1" >>confdefs.h
12875
12876                 fi
12877         else
12878                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12879 $as_echo "no" >&6; }
12880         fi
12881
12882
12883 # look for field 'syslen' in header 'utmpx.h'
12884                 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
12885                 ossh_varname="ossh_cv_$ossh_safe""_has_"syslen
12886         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for syslen field in utmpx.h" >&5
12887 $as_echo_n "checking for syslen field in utmpx.h... " >&6; }
12888         if eval "test \"\${$ossh_varname+set}\"" = set; then :
12889   $as_echo_n "(cached) " >&6
12890 else
12891
12892                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12893 /* end confdefs.h.  */
12894 #include <utmpx.h>
12895
12896 _ACEOF
12897 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12898   $EGREP "syslen" >/dev/null 2>&1; then :
12899                         eval "$ossh_varname=yes"
12900 else
12901                         eval "$ossh_varname=no"
12902 fi
12903 rm -f conftest*
12904
12905 fi
12906
12907         ossh_result=`eval 'echo $'"$ossh_varname"`
12908         if test -n "`echo $ossh_varname`"; then
12909                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
12910 $as_echo "$ossh_result" >&6; }
12911                 if test "x$ossh_result" = "xyes"; then
12912
12913 $as_echo "#define HAVE_SYSLEN_IN_UTMPX 1" >>confdefs.h
12914
12915                 fi
12916         else
12917                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12918 $as_echo "no" >&6; }
12919         fi
12920
12921
12922 # look for field 'ut_pid' in header 'utmp.h'
12923                 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
12924                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_pid
12925         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_pid field in utmp.h" >&5
12926 $as_echo_n "checking for ut_pid field in utmp.h... " >&6; }
12927         if eval "test \"\${$ossh_varname+set}\"" = set; then :
12928   $as_echo_n "(cached) " >&6
12929 else
12930
12931                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12932 /* end confdefs.h.  */
12933 #include <utmp.h>
12934
12935 _ACEOF
12936 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12937   $EGREP "ut_pid" >/dev/null 2>&1; then :
12938                         eval "$ossh_varname=yes"
12939 else
12940                         eval "$ossh_varname=no"
12941 fi
12942 rm -f conftest*
12943
12944 fi
12945
12946         ossh_result=`eval 'echo $'"$ossh_varname"`
12947         if test -n "`echo $ossh_varname`"; then
12948                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
12949 $as_echo "$ossh_result" >&6; }
12950                 if test "x$ossh_result" = "xyes"; then
12951
12952 $as_echo "#define HAVE_PID_IN_UTMP 1" >>confdefs.h
12953
12954                 fi
12955         else
12956                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12957 $as_echo "no" >&6; }
12958         fi
12959
12960
12961 # look for field 'ut_type' in header 'utmp.h'
12962                 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
12963                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_type
12964         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_type field in utmp.h" >&5
12965 $as_echo_n "checking for ut_type field in utmp.h... " >&6; }
12966         if eval "test \"\${$ossh_varname+set}\"" = set; then :
12967   $as_echo_n "(cached) " >&6
12968 else
12969
12970                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
12971 /* end confdefs.h.  */
12972 #include <utmp.h>
12973
12974 _ACEOF
12975 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
12976   $EGREP "ut_type" >/dev/null 2>&1; then :
12977                         eval "$ossh_varname=yes"
12978 else
12979                         eval "$ossh_varname=no"
12980 fi
12981 rm -f conftest*
12982
12983 fi
12984
12985         ossh_result=`eval 'echo $'"$ossh_varname"`
12986         if test -n "`echo $ossh_varname`"; then
12987                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
12988 $as_echo "$ossh_result" >&6; }
12989                 if test "x$ossh_result" = "xyes"; then
12990
12991 $as_echo "#define HAVE_TYPE_IN_UTMP 1" >>confdefs.h
12992
12993                 fi
12994         else
12995                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
12996 $as_echo "no" >&6; }
12997         fi
12998
12999
13000 # look for field 'ut_type' in header 'utmpx.h'
13001                 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
13002                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_type
13003         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_type field in utmpx.h" >&5
13004 $as_echo_n "checking for ut_type field in utmpx.h... " >&6; }
13005         if eval "test \"\${$ossh_varname+set}\"" = set; then :
13006   $as_echo_n "(cached) " >&6
13007 else
13008
13009                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13010 /* end confdefs.h.  */
13011 #include <utmpx.h>
13012
13013 _ACEOF
13014 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13015   $EGREP "ut_type" >/dev/null 2>&1; then :
13016                         eval "$ossh_varname=yes"
13017 else
13018                         eval "$ossh_varname=no"
13019 fi
13020 rm -f conftest*
13021
13022 fi
13023
13024         ossh_result=`eval 'echo $'"$ossh_varname"`
13025         if test -n "`echo $ossh_varname`"; then
13026                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
13027 $as_echo "$ossh_result" >&6; }
13028                 if test "x$ossh_result" = "xyes"; then
13029
13030 $as_echo "#define HAVE_TYPE_IN_UTMPX 1" >>confdefs.h
13031
13032                 fi
13033         else
13034                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13035 $as_echo "no" >&6; }
13036         fi
13037
13038
13039 # look for field 'ut_tv' in header 'utmp.h'
13040                 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
13041                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_tv
13042         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_tv field in utmp.h" >&5
13043 $as_echo_n "checking for ut_tv field in utmp.h... " >&6; }
13044         if eval "test \"\${$ossh_varname+set}\"" = set; then :
13045   $as_echo_n "(cached) " >&6
13046 else
13047
13048                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13049 /* end confdefs.h.  */
13050 #include <utmp.h>
13051
13052 _ACEOF
13053 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13054   $EGREP "ut_tv" >/dev/null 2>&1; then :
13055                         eval "$ossh_varname=yes"
13056 else
13057                         eval "$ossh_varname=no"
13058 fi
13059 rm -f conftest*
13060
13061 fi
13062
13063         ossh_result=`eval 'echo $'"$ossh_varname"`
13064         if test -n "`echo $ossh_varname`"; then
13065                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
13066 $as_echo "$ossh_result" >&6; }
13067                 if test "x$ossh_result" = "xyes"; then
13068
13069 $as_echo "#define HAVE_TV_IN_UTMP 1" >>confdefs.h
13070
13071                 fi
13072         else
13073                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13074 $as_echo "no" >&6; }
13075         fi
13076
13077
13078 # look for field 'ut_id' in header 'utmp.h'
13079                 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
13080                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_id
13081         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_id field in utmp.h" >&5
13082 $as_echo_n "checking for ut_id field in utmp.h... " >&6; }
13083         if eval "test \"\${$ossh_varname+set}\"" = set; then :
13084   $as_echo_n "(cached) " >&6
13085 else
13086
13087                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13088 /* end confdefs.h.  */
13089 #include <utmp.h>
13090
13091 _ACEOF
13092 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13093   $EGREP "ut_id" >/dev/null 2>&1; then :
13094                         eval "$ossh_varname=yes"
13095 else
13096                         eval "$ossh_varname=no"
13097 fi
13098 rm -f conftest*
13099
13100 fi
13101
13102         ossh_result=`eval 'echo $'"$ossh_varname"`
13103         if test -n "`echo $ossh_varname`"; then
13104                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
13105 $as_echo "$ossh_result" >&6; }
13106                 if test "x$ossh_result" = "xyes"; then
13107
13108 $as_echo "#define HAVE_ID_IN_UTMP 1" >>confdefs.h
13109
13110                 fi
13111         else
13112                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13113 $as_echo "no" >&6; }
13114         fi
13115
13116
13117 # look for field 'ut_id' in header 'utmpx.h'
13118                 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
13119                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_id
13120         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_id field in utmpx.h" >&5
13121 $as_echo_n "checking for ut_id field in utmpx.h... " >&6; }
13122         if eval "test \"\${$ossh_varname+set}\"" = set; then :
13123   $as_echo_n "(cached) " >&6
13124 else
13125
13126                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13127 /* end confdefs.h.  */
13128 #include <utmpx.h>
13129
13130 _ACEOF
13131 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13132   $EGREP "ut_id" >/dev/null 2>&1; then :
13133                         eval "$ossh_varname=yes"
13134 else
13135                         eval "$ossh_varname=no"
13136 fi
13137 rm -f conftest*
13138
13139 fi
13140
13141         ossh_result=`eval 'echo $'"$ossh_varname"`
13142         if test -n "`echo $ossh_varname`"; then
13143                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
13144 $as_echo "$ossh_result" >&6; }
13145                 if test "x$ossh_result" = "xyes"; then
13146
13147 $as_echo "#define HAVE_ID_IN_UTMPX 1" >>confdefs.h
13148
13149                 fi
13150         else
13151                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13152 $as_echo "no" >&6; }
13153         fi
13154
13155
13156 # look for field 'ut_addr' in header 'utmp.h'
13157                 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
13158                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_addr
13159         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_addr field in utmp.h" >&5
13160 $as_echo_n "checking for ut_addr field in utmp.h... " >&6; }
13161         if eval "test \"\${$ossh_varname+set}\"" = set; then :
13162   $as_echo_n "(cached) " >&6
13163 else
13164
13165                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13166 /* end confdefs.h.  */
13167 #include <utmp.h>
13168
13169 _ACEOF
13170 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13171   $EGREP "ut_addr" >/dev/null 2>&1; then :
13172                         eval "$ossh_varname=yes"
13173 else
13174                         eval "$ossh_varname=no"
13175 fi
13176 rm -f conftest*
13177
13178 fi
13179
13180         ossh_result=`eval 'echo $'"$ossh_varname"`
13181         if test -n "`echo $ossh_varname`"; then
13182                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
13183 $as_echo "$ossh_result" >&6; }
13184                 if test "x$ossh_result" = "xyes"; then
13185
13186 $as_echo "#define HAVE_ADDR_IN_UTMP 1" >>confdefs.h
13187
13188                 fi
13189         else
13190                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13191 $as_echo "no" >&6; }
13192         fi
13193
13194
13195 # look for field 'ut_addr' in header 'utmpx.h'
13196                 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
13197                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_addr
13198         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_addr field in utmpx.h" >&5
13199 $as_echo_n "checking for ut_addr field in utmpx.h... " >&6; }
13200         if eval "test \"\${$ossh_varname+set}\"" = set; then :
13201   $as_echo_n "(cached) " >&6
13202 else
13203
13204                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13205 /* end confdefs.h.  */
13206 #include <utmpx.h>
13207
13208 _ACEOF
13209 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13210   $EGREP "ut_addr" >/dev/null 2>&1; then :
13211                         eval "$ossh_varname=yes"
13212 else
13213                         eval "$ossh_varname=no"
13214 fi
13215 rm -f conftest*
13216
13217 fi
13218
13219         ossh_result=`eval 'echo $'"$ossh_varname"`
13220         if test -n "`echo $ossh_varname`"; then
13221                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
13222 $as_echo "$ossh_result" >&6; }
13223                 if test "x$ossh_result" = "xyes"; then
13224
13225 $as_echo "#define HAVE_ADDR_IN_UTMPX 1" >>confdefs.h
13226
13227                 fi
13228         else
13229                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13230 $as_echo "no" >&6; }
13231         fi
13232
13233
13234 # look for field 'ut_addr_v6' in header 'utmp.h'
13235                 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
13236                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_addr_v6
13237         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_addr_v6 field in utmp.h" >&5
13238 $as_echo_n "checking for ut_addr_v6 field in utmp.h... " >&6; }
13239         if eval "test \"\${$ossh_varname+set}\"" = set; then :
13240   $as_echo_n "(cached) " >&6
13241 else
13242
13243                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13244 /* end confdefs.h.  */
13245 #include <utmp.h>
13246
13247 _ACEOF
13248 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13249   $EGREP "ut_addr_v6" >/dev/null 2>&1; then :
13250                         eval "$ossh_varname=yes"
13251 else
13252                         eval "$ossh_varname=no"
13253 fi
13254 rm -f conftest*
13255
13256 fi
13257
13258         ossh_result=`eval 'echo $'"$ossh_varname"`
13259         if test -n "`echo $ossh_varname`"; then
13260                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
13261 $as_echo "$ossh_result" >&6; }
13262                 if test "x$ossh_result" = "xyes"; then
13263
13264 $as_echo "#define HAVE_ADDR_V6_IN_UTMP 1" >>confdefs.h
13265
13266                 fi
13267         else
13268                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13269 $as_echo "no" >&6; }
13270         fi
13271
13272
13273 # look for field 'ut_addr_v6' in header 'utmpx.h'
13274                 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
13275                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_addr_v6
13276         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_addr_v6 field in utmpx.h" >&5
13277 $as_echo_n "checking for ut_addr_v6 field in utmpx.h... " >&6; }
13278         if eval "test \"\${$ossh_varname+set}\"" = set; then :
13279   $as_echo_n "(cached) " >&6
13280 else
13281
13282                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13283 /* end confdefs.h.  */
13284 #include <utmpx.h>
13285
13286 _ACEOF
13287 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13288   $EGREP "ut_addr_v6" >/dev/null 2>&1; then :
13289                         eval "$ossh_varname=yes"
13290 else
13291                         eval "$ossh_varname=no"
13292 fi
13293 rm -f conftest*
13294
13295 fi
13296
13297         ossh_result=`eval 'echo $'"$ossh_varname"`
13298         if test -n "`echo $ossh_varname`"; then
13299                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
13300 $as_echo "$ossh_result" >&6; }
13301                 if test "x$ossh_result" = "xyes"; then
13302
13303 $as_echo "#define HAVE_ADDR_V6_IN_UTMPX 1" >>confdefs.h
13304
13305                 fi
13306         else
13307                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13308 $as_echo "no" >&6; }
13309         fi
13310
13311
13312 # look for field 'ut_exit' in header 'utmp.h'
13313                 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
13314                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_exit
13315         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_exit field in utmp.h" >&5
13316 $as_echo_n "checking for ut_exit field in utmp.h... " >&6; }
13317         if eval "test \"\${$ossh_varname+set}\"" = set; then :
13318   $as_echo_n "(cached) " >&6
13319 else
13320
13321                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13322 /* end confdefs.h.  */
13323 #include <utmp.h>
13324
13325 _ACEOF
13326 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13327   $EGREP "ut_exit" >/dev/null 2>&1; then :
13328                         eval "$ossh_varname=yes"
13329 else
13330                         eval "$ossh_varname=no"
13331 fi
13332 rm -f conftest*
13333
13334 fi
13335
13336         ossh_result=`eval 'echo $'"$ossh_varname"`
13337         if test -n "`echo $ossh_varname`"; then
13338                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
13339 $as_echo "$ossh_result" >&6; }
13340                 if test "x$ossh_result" = "xyes"; then
13341
13342 $as_echo "#define HAVE_EXIT_IN_UTMP 1" >>confdefs.h
13343
13344                 fi
13345         else
13346                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13347 $as_echo "no" >&6; }
13348         fi
13349
13350
13351 # look for field 'ut_time' in header 'utmp.h'
13352                 ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
13353                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_time
13354         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_time field in utmp.h" >&5
13355 $as_echo_n "checking for ut_time field in utmp.h... " >&6; }
13356         if eval "test \"\${$ossh_varname+set}\"" = set; then :
13357   $as_echo_n "(cached) " >&6
13358 else
13359
13360                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13361 /* end confdefs.h.  */
13362 #include <utmp.h>
13363
13364 _ACEOF
13365 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13366   $EGREP "ut_time" >/dev/null 2>&1; then :
13367                         eval "$ossh_varname=yes"
13368 else
13369                         eval "$ossh_varname=no"
13370 fi
13371 rm -f conftest*
13372
13373 fi
13374
13375         ossh_result=`eval 'echo $'"$ossh_varname"`
13376         if test -n "`echo $ossh_varname`"; then
13377                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
13378 $as_echo "$ossh_result" >&6; }
13379                 if test "x$ossh_result" = "xyes"; then
13380
13381 $as_echo "#define HAVE_TIME_IN_UTMP 1" >>confdefs.h
13382
13383                 fi
13384         else
13385                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13386 $as_echo "no" >&6; }
13387         fi
13388
13389
13390 # look for field 'ut_time' in header 'utmpx.h'
13391                 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
13392                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_time
13393         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_time field in utmpx.h" >&5
13394 $as_echo_n "checking for ut_time field in utmpx.h... " >&6; }
13395         if eval "test \"\${$ossh_varname+set}\"" = set; then :
13396   $as_echo_n "(cached) " >&6
13397 else
13398
13399                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13400 /* end confdefs.h.  */
13401 #include <utmpx.h>
13402
13403 _ACEOF
13404 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13405   $EGREP "ut_time" >/dev/null 2>&1; then :
13406                         eval "$ossh_varname=yes"
13407 else
13408                         eval "$ossh_varname=no"
13409 fi
13410 rm -f conftest*
13411
13412 fi
13413
13414         ossh_result=`eval 'echo $'"$ossh_varname"`
13415         if test -n "`echo $ossh_varname`"; then
13416                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
13417 $as_echo "$ossh_result" >&6; }
13418                 if test "x$ossh_result" = "xyes"; then
13419
13420 $as_echo "#define HAVE_TIME_IN_UTMPX 1" >>confdefs.h
13421
13422                 fi
13423         else
13424                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13425 $as_echo "no" >&6; }
13426         fi
13427
13428
13429 # look for field 'ut_tv' in header 'utmpx.h'
13430                 ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
13431                 ossh_varname="ossh_cv_$ossh_safe""_has_"ut_tv
13432         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ut_tv field in utmpx.h" >&5
13433 $as_echo_n "checking for ut_tv field in utmpx.h... " >&6; }
13434         if eval "test \"\${$ossh_varname+set}\"" = set; then :
13435   $as_echo_n "(cached) " >&6
13436 else
13437
13438                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13439 /* end confdefs.h.  */
13440 #include <utmpx.h>
13441
13442 _ACEOF
13443 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
13444   $EGREP "ut_tv" >/dev/null 2>&1; then :
13445                         eval "$ossh_varname=yes"
13446 else
13447                         eval "$ossh_varname=no"
13448 fi
13449 rm -f conftest*
13450
13451 fi
13452
13453         ossh_result=`eval 'echo $'"$ossh_varname"`
13454         if test -n "`echo $ossh_varname`"; then
13455                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ossh_result" >&5
13456 $as_echo "$ossh_result" >&6; }
13457                 if test "x$ossh_result" = "xyes"; then
13458
13459 $as_echo "#define HAVE_TV_IN_UTMPX 1" >>confdefs.h
13460
13461                 fi
13462         else
13463                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13464 $as_echo "no" >&6; }
13465         fi
13466
13467
13468 ac_fn_c_check_member "$LINENO" "struct stat" "st_blksize" "ac_cv_member_struct_stat_st_blksize" "$ac_includes_default"
13469 if test "x$ac_cv_member_struct_stat_st_blksize" = x""yes; then :
13470
13471 cat >>confdefs.h <<_ACEOF
13472 #define HAVE_STRUCT_STAT_ST_BLKSIZE 1
13473 _ACEOF
13474
13475
13476 fi
13477
13478 ac_fn_c_check_member "$LINENO" "struct __res_state" "retrans" "ac_cv_member_struct___res_state_retrans" "
13479 #include <stdio.h>
13480 #if HAVE_SYS_TYPES_H
13481 # include <sys/types.h>
13482 #endif
13483 #include <netinet/in.h>
13484 #include <arpa/nameser.h>
13485 #include <resolv.h>
13486
13487 "
13488 if test "x$ac_cv_member_struct___res_state_retrans" = x""yes; then :
13489
13490 else
13491
13492 $as_echo "#define __res_state state" >>confdefs.h
13493
13494 fi
13495
13496
13497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ss_family field in struct sockaddr_storage" >&5
13498 $as_echo_n "checking for ss_family field in struct sockaddr_storage... " >&6; }
13499 if test "${ac_cv_have_ss_family_in_struct_ss+set}" = set; then :
13500   $as_echo_n "(cached) " >&6
13501 else
13502
13503         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13504 /* end confdefs.h.  */
13505
13506 #include <sys/types.h>
13507 #include <sys/socket.h>
13508
13509 int
13510 main ()
13511 {
13512  struct sockaddr_storage s; s.ss_family = 1;
13513   ;
13514   return 0;
13515 }
13516 _ACEOF
13517 if ac_fn_c_try_compile "$LINENO"; then :
13518    ac_cv_have_ss_family_in_struct_ss="yes"
13519 else
13520    ac_cv_have_ss_family_in_struct_ss="no"
13521 fi
13522 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13523
13524 fi
13525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_ss_family_in_struct_ss" >&5
13526 $as_echo "$ac_cv_have_ss_family_in_struct_ss" >&6; }
13527 if test "x$ac_cv_have_ss_family_in_struct_ss" = "xyes" ; then
13528
13529 $as_echo "#define HAVE_SS_FAMILY_IN_SS 1" >>confdefs.h
13530
13531 fi
13532
13533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for __ss_family field in struct sockaddr_storage" >&5
13534 $as_echo_n "checking for __ss_family field in struct sockaddr_storage... " >&6; }
13535 if test "${ac_cv_have___ss_family_in_struct_ss+set}" = set; then :
13536   $as_echo_n "(cached) " >&6
13537 else
13538
13539         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13540 /* end confdefs.h.  */
13541
13542 #include <sys/types.h>
13543 #include <sys/socket.h>
13544
13545 int
13546 main ()
13547 {
13548  struct sockaddr_storage s; s.__ss_family = 1;
13549   ;
13550   return 0;
13551 }
13552 _ACEOF
13553 if ac_fn_c_try_compile "$LINENO"; then :
13554    ac_cv_have___ss_family_in_struct_ss="yes"
13555 else
13556    ac_cv_have___ss_family_in_struct_ss="no"
13557
13558 fi
13559 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13560
13561 fi
13562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have___ss_family_in_struct_ss" >&5
13563 $as_echo "$ac_cv_have___ss_family_in_struct_ss" >&6; }
13564 if test "x$ac_cv_have___ss_family_in_struct_ss" = "xyes" ; then
13565
13566 $as_echo "#define HAVE___SS_FAMILY_IN_SS 1" >>confdefs.h
13567
13568 fi
13569
13570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pw_class field in struct passwd" >&5
13571 $as_echo_n "checking for pw_class field in struct passwd... " >&6; }
13572 if test "${ac_cv_have_pw_class_in_struct_passwd+set}" = set; then :
13573   $as_echo_n "(cached) " >&6
13574 else
13575
13576         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13577 /* end confdefs.h.  */
13578  #include <pwd.h>
13579 int
13580 main ()
13581 {
13582  struct passwd p; p.pw_class = 0;
13583   ;
13584   return 0;
13585 }
13586 _ACEOF
13587 if ac_fn_c_try_compile "$LINENO"; then :
13588    ac_cv_have_pw_class_in_struct_passwd="yes"
13589 else
13590    ac_cv_have_pw_class_in_struct_passwd="no"
13591
13592 fi
13593 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13594
13595 fi
13596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_pw_class_in_struct_passwd" >&5
13597 $as_echo "$ac_cv_have_pw_class_in_struct_passwd" >&6; }
13598 if test "x$ac_cv_have_pw_class_in_struct_passwd" = "xyes" ; then
13599
13600 $as_echo "#define HAVE_PW_CLASS_IN_PASSWD 1" >>confdefs.h
13601
13602 fi
13603
13604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pw_expire field in struct passwd" >&5
13605 $as_echo_n "checking for pw_expire field in struct passwd... " >&6; }
13606 if test "${ac_cv_have_pw_expire_in_struct_passwd+set}" = set; then :
13607   $as_echo_n "(cached) " >&6
13608 else
13609
13610         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13611 /* end confdefs.h.  */
13612  #include <pwd.h>
13613 int
13614 main ()
13615 {
13616  struct passwd p; p.pw_expire = 0;
13617   ;
13618   return 0;
13619 }
13620 _ACEOF
13621 if ac_fn_c_try_compile "$LINENO"; then :
13622    ac_cv_have_pw_expire_in_struct_passwd="yes"
13623 else
13624    ac_cv_have_pw_expire_in_struct_passwd="no"
13625
13626 fi
13627 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13628
13629 fi
13630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_pw_expire_in_struct_passwd" >&5
13631 $as_echo "$ac_cv_have_pw_expire_in_struct_passwd" >&6; }
13632 if test "x$ac_cv_have_pw_expire_in_struct_passwd" = "xyes" ; then
13633
13634 $as_echo "#define HAVE_PW_EXPIRE_IN_PASSWD 1" >>confdefs.h
13635
13636 fi
13637
13638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for pw_change field in struct passwd" >&5
13639 $as_echo_n "checking for pw_change field in struct passwd... " >&6; }
13640 if test "${ac_cv_have_pw_change_in_struct_passwd+set}" = set; then :
13641   $as_echo_n "(cached) " >&6
13642 else
13643
13644         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13645 /* end confdefs.h.  */
13646  #include <pwd.h>
13647 int
13648 main ()
13649 {
13650  struct passwd p; p.pw_change = 0;
13651   ;
13652   return 0;
13653 }
13654 _ACEOF
13655 if ac_fn_c_try_compile "$LINENO"; then :
13656    ac_cv_have_pw_change_in_struct_passwd="yes"
13657 else
13658    ac_cv_have_pw_change_in_struct_passwd="no"
13659
13660 fi
13661 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13662
13663 fi
13664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_pw_change_in_struct_passwd" >&5
13665 $as_echo "$ac_cv_have_pw_change_in_struct_passwd" >&6; }
13666 if test "x$ac_cv_have_pw_change_in_struct_passwd" = "xyes" ; then
13667
13668 $as_echo "#define HAVE_PW_CHANGE_IN_PASSWD 1" >>confdefs.h
13669
13670 fi
13671
13672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msg_accrights field in struct msghdr" >&5
13673 $as_echo_n "checking for msg_accrights field in struct msghdr... " >&6; }
13674 if test "${ac_cv_have_accrights_in_msghdr+set}" = set; then :
13675   $as_echo_n "(cached) " >&6
13676 else
13677
13678         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13679 /* end confdefs.h.  */
13680
13681 #include <sys/types.h>
13682 #include <sys/socket.h>
13683 #include <sys/uio.h>
13684
13685 int
13686 main ()
13687 {
13688
13689 #ifdef msg_accrights
13690 #error "msg_accrights is a macro"
13691 exit(1);
13692 #endif
13693 struct msghdr m;
13694 m.msg_accrights = 0;
13695 exit(0);
13696
13697   ;
13698   return 0;
13699 }
13700 _ACEOF
13701 if ac_fn_c_try_compile "$LINENO"; then :
13702    ac_cv_have_accrights_in_msghdr="yes"
13703 else
13704    ac_cv_have_accrights_in_msghdr="no"
13705
13706 fi
13707 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13708
13709 fi
13710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_accrights_in_msghdr" >&5
13711 $as_echo "$ac_cv_have_accrights_in_msghdr" >&6; }
13712 if test "x$ac_cv_have_accrights_in_msghdr" = "xyes" ; then
13713
13714 $as_echo "#define HAVE_ACCRIGHTS_IN_MSGHDR 1" >>confdefs.h
13715
13716 fi
13717
13718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if struct statvfs.f_fsid is integral type" >&5
13719 $as_echo_n "checking if struct statvfs.f_fsid is integral type... " >&6; }
13720 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13721 /* end confdefs.h.  */
13722
13723 #include <sys/types.h>
13724 #include <sys/stat.h>
13725 #ifdef HAVE_SYS_TIME_H
13726 # include <sys/time.h>
13727 #endif
13728 #ifdef HAVE_SYS_MOUNT_H
13729 #include <sys/mount.h>
13730 #endif
13731 #ifdef HAVE_SYS_STATVFS_H
13732 #include <sys/statvfs.h>
13733 #endif
13734
13735 int
13736 main ()
13737 {
13738  struct statvfs s; s.f_fsid = 0;
13739   ;
13740   return 0;
13741 }
13742 _ACEOF
13743 if ac_fn_c_try_compile "$LINENO"; then :
13744    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13745 $as_echo "yes" >&6; }
13746 else
13747    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13748 $as_echo "no" >&6; }
13749
13750         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fsid_t has member val" >&5
13751 $as_echo_n "checking if fsid_t has member val... " >&6; }
13752         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13753 /* end confdefs.h.  */
13754
13755 #include <sys/types.h>
13756 #include <sys/statvfs.h>
13757
13758 int
13759 main ()
13760 {
13761  fsid_t t; t.val[0] = 0;
13762   ;
13763   return 0;
13764 }
13765 _ACEOF
13766 if ac_fn_c_try_compile "$LINENO"; then :
13767    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13768 $as_echo "yes" >&6; }
13769
13770 $as_echo "#define FSID_HAS_VAL 1" >>confdefs.h
13771
13772 else
13773    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13774 $as_echo "no" >&6; }
13775 fi
13776 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13777
13778         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if f_fsid has member __val" >&5
13779 $as_echo_n "checking if f_fsid has member __val... " >&6; }
13780         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13781 /* end confdefs.h.  */
13782
13783 #include <sys/types.h>
13784 #include <sys/statvfs.h>
13785
13786 int
13787 main ()
13788 {
13789  fsid_t t; t.__val[0] = 0;
13790   ;
13791   return 0;
13792 }
13793 _ACEOF
13794 if ac_fn_c_try_compile "$LINENO"; then :
13795    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
13796 $as_echo "yes" >&6; }
13797
13798 $as_echo "#define FSID_HAS___VAL 1" >>confdefs.h
13799
13800 else
13801    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
13802 $as_echo "no" >&6; }
13803 fi
13804 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13805
13806 fi
13807 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13808
13809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for msg_control field in struct msghdr" >&5
13810 $as_echo_n "checking for msg_control field in struct msghdr... " >&6; }
13811 if test "${ac_cv_have_control_in_msghdr+set}" = set; then :
13812   $as_echo_n "(cached) " >&6
13813 else
13814
13815         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13816 /* end confdefs.h.  */
13817
13818 #include <sys/types.h>
13819 #include <sys/socket.h>
13820 #include <sys/uio.h>
13821
13822 int
13823 main ()
13824 {
13825
13826 #ifdef msg_control
13827 #error "msg_control is a macro"
13828 exit(1);
13829 #endif
13830 struct msghdr m;
13831 m.msg_control = 0;
13832 exit(0);
13833
13834   ;
13835   return 0;
13836 }
13837 _ACEOF
13838 if ac_fn_c_try_compile "$LINENO"; then :
13839    ac_cv_have_control_in_msghdr="yes"
13840 else
13841    ac_cv_have_control_in_msghdr="no"
13842
13843 fi
13844 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13845
13846 fi
13847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_control_in_msghdr" >&5
13848 $as_echo "$ac_cv_have_control_in_msghdr" >&6; }
13849 if test "x$ac_cv_have_control_in_msghdr" = "xyes" ; then
13850
13851 $as_echo "#define HAVE_CONTROL_IN_MSGHDR 1" >>confdefs.h
13852
13853 fi
13854
13855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libc defines __progname" >&5
13856 $as_echo_n "checking if libc defines __progname... " >&6; }
13857 if test "${ac_cv_libc_defines___progname+set}" = set; then :
13858   $as_echo_n "(cached) " >&6
13859 else
13860
13861         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13862 /* end confdefs.h.  */
13863
13864 int
13865 main ()
13866 {
13867  extern char *__progname; printf("%s", __progname);
13868   ;
13869   return 0;
13870 }
13871 _ACEOF
13872 if ac_fn_c_try_link "$LINENO"; then :
13873    ac_cv_libc_defines___progname="yes"
13874 else
13875    ac_cv_libc_defines___progname="no"
13876
13877 fi
13878 rm -f core conftest.err conftest.$ac_objext \
13879     conftest$ac_exeext conftest.$ac_ext
13880
13881 fi
13882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libc_defines___progname" >&5
13883 $as_echo "$ac_cv_libc_defines___progname" >&6; }
13884 if test "x$ac_cv_libc_defines___progname" = "xyes" ; then
13885
13886 $as_echo "#define HAVE___PROGNAME 1" >>confdefs.h
13887
13888 fi
13889
13890 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC implements __FUNCTION__" >&5
13891 $as_echo_n "checking whether $CC implements __FUNCTION__... " >&6; }
13892 if test "${ac_cv_cc_implements___FUNCTION__+set}" = set; then :
13893   $as_echo_n "(cached) " >&6
13894 else
13895
13896         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13897 /* end confdefs.h.  */
13898  #include <stdio.h>
13899 int
13900 main ()
13901 {
13902  printf("%s", __FUNCTION__);
13903   ;
13904   return 0;
13905 }
13906 _ACEOF
13907 if ac_fn_c_try_link "$LINENO"; then :
13908    ac_cv_cc_implements___FUNCTION__="yes"
13909 else
13910    ac_cv_cc_implements___FUNCTION__="no"
13911
13912 fi
13913 rm -f core conftest.err conftest.$ac_objext \
13914     conftest$ac_exeext conftest.$ac_ext
13915
13916 fi
13917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_implements___FUNCTION__" >&5
13918 $as_echo "$ac_cv_cc_implements___FUNCTION__" >&6; }
13919 if test "x$ac_cv_cc_implements___FUNCTION__" = "xyes" ; then
13920
13921 $as_echo "#define HAVE___FUNCTION__ 1" >>confdefs.h
13922
13923 fi
13924
13925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC implements __func__" >&5
13926 $as_echo_n "checking whether $CC implements __func__... " >&6; }
13927 if test "${ac_cv_cc_implements___func__+set}" = set; then :
13928   $as_echo_n "(cached) " >&6
13929 else
13930
13931         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13932 /* end confdefs.h.  */
13933  #include <stdio.h>
13934 int
13935 main ()
13936 {
13937  printf("%s", __func__);
13938   ;
13939   return 0;
13940 }
13941 _ACEOF
13942 if ac_fn_c_try_link "$LINENO"; then :
13943    ac_cv_cc_implements___func__="yes"
13944 else
13945    ac_cv_cc_implements___func__="no"
13946
13947 fi
13948 rm -f core conftest.err conftest.$ac_objext \
13949     conftest$ac_exeext conftest.$ac_ext
13950
13951 fi
13952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cc_implements___func__" >&5
13953 $as_echo "$ac_cv_cc_implements___func__" >&6; }
13954 if test "x$ac_cv_cc_implements___func__" = "xyes" ; then
13955
13956 $as_echo "#define HAVE___func__ 1" >>confdefs.h
13957
13958 fi
13959
13960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether va_copy exists" >&5
13961 $as_echo_n "checking whether va_copy exists... " >&6; }
13962 if test "${ac_cv_have_va_copy+set}" = set; then :
13963   $as_echo_n "(cached) " >&6
13964 else
13965
13966         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
13967 /* end confdefs.h.  */
13968
13969 #include <stdarg.h>
13970 va_list x,y;
13971
13972 int
13973 main ()
13974 {
13975  va_copy(x,y);
13976   ;
13977   return 0;
13978 }
13979 _ACEOF
13980 if ac_fn_c_try_link "$LINENO"; then :
13981    ac_cv_have_va_copy="yes"
13982 else
13983    ac_cv_have_va_copy="no"
13984
13985 fi
13986 rm -f core conftest.err conftest.$ac_objext \
13987     conftest$ac_exeext conftest.$ac_ext
13988
13989 fi
13990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_va_copy" >&5
13991 $as_echo "$ac_cv_have_va_copy" >&6; }
13992 if test "x$ac_cv_have_va_copy" = "xyes" ; then
13993
13994 $as_echo "#define HAVE_VA_COPY 1" >>confdefs.h
13995
13996 fi
13997
13998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether __va_copy exists" >&5
13999 $as_echo_n "checking whether __va_copy exists... " >&6; }
14000 if test "${ac_cv_have___va_copy+set}" = set; then :
14001   $as_echo_n "(cached) " >&6
14002 else
14003
14004         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14005 /* end confdefs.h.  */
14006
14007 #include <stdarg.h>
14008 va_list x,y;
14009
14010 int
14011 main ()
14012 {
14013  __va_copy(x,y);
14014   ;
14015   return 0;
14016 }
14017 _ACEOF
14018 if ac_fn_c_try_link "$LINENO"; then :
14019    ac_cv_have___va_copy="yes"
14020 else
14021    ac_cv_have___va_copy="no"
14022
14023 fi
14024 rm -f core conftest.err conftest.$ac_objext \
14025     conftest$ac_exeext conftest.$ac_ext
14026
14027 fi
14028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have___va_copy" >&5
14029 $as_echo "$ac_cv_have___va_copy" >&6; }
14030 if test "x$ac_cv_have___va_copy" = "xyes" ; then
14031
14032 $as_echo "#define HAVE___VA_COPY 1" >>confdefs.h
14033
14034 fi
14035
14036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether getopt has optreset support" >&5
14037 $as_echo_n "checking whether getopt has optreset support... " >&6; }
14038 if test "${ac_cv_have_getopt_optreset+set}" = set; then :
14039   $as_echo_n "(cached) " >&6
14040 else
14041
14042         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14043 /* end confdefs.h.  */
14044  #include <getopt.h>
14045 int
14046 main ()
14047 {
14048  extern int optreset; optreset = 0;
14049   ;
14050   return 0;
14051 }
14052 _ACEOF
14053 if ac_fn_c_try_link "$LINENO"; then :
14054    ac_cv_have_getopt_optreset="yes"
14055 else
14056    ac_cv_have_getopt_optreset="no"
14057
14058 fi
14059 rm -f core conftest.err conftest.$ac_objext \
14060     conftest$ac_exeext conftest.$ac_ext
14061
14062 fi
14063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_have_getopt_optreset" >&5
14064 $as_echo "$ac_cv_have_getopt_optreset" >&6; }
14065 if test "x$ac_cv_have_getopt_optreset" = "xyes" ; then
14066
14067 $as_echo "#define HAVE_GETOPT_OPTRESET 1" >>confdefs.h
14068
14069 fi
14070
14071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libc defines sys_errlist" >&5
14072 $as_echo_n "checking if libc defines sys_errlist... " >&6; }
14073 if test "${ac_cv_libc_defines_sys_errlist+set}" = set; then :
14074   $as_echo_n "(cached) " >&6
14075 else
14076
14077         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14078 /* end confdefs.h.  */
14079
14080 int
14081 main ()
14082 {
14083  extern const char *const sys_errlist[]; printf("%s", sys_errlist[0]);
14084   ;
14085   return 0;
14086 }
14087 _ACEOF
14088 if ac_fn_c_try_link "$LINENO"; then :
14089    ac_cv_libc_defines_sys_errlist="yes"
14090 else
14091    ac_cv_libc_defines_sys_errlist="no"
14092
14093 fi
14094 rm -f core conftest.err conftest.$ac_objext \
14095     conftest$ac_exeext conftest.$ac_ext
14096
14097 fi
14098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libc_defines_sys_errlist" >&5
14099 $as_echo "$ac_cv_libc_defines_sys_errlist" >&6; }
14100 if test "x$ac_cv_libc_defines_sys_errlist" = "xyes" ; then
14101
14102 $as_echo "#define HAVE_SYS_ERRLIST 1" >>confdefs.h
14103
14104 fi
14105
14106
14107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libc defines sys_nerr" >&5
14108 $as_echo_n "checking if libc defines sys_nerr... " >&6; }
14109 if test "${ac_cv_libc_defines_sys_nerr+set}" = set; then :
14110   $as_echo_n "(cached) " >&6
14111 else
14112
14113         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14114 /* end confdefs.h.  */
14115
14116 int
14117 main ()
14118 {
14119  extern int sys_nerr; printf("%i", sys_nerr);
14120   ;
14121   return 0;
14122 }
14123 _ACEOF
14124 if ac_fn_c_try_link "$LINENO"; then :
14125    ac_cv_libc_defines_sys_nerr="yes"
14126 else
14127    ac_cv_libc_defines_sys_nerr="no"
14128
14129 fi
14130 rm -f core conftest.err conftest.$ac_objext \
14131     conftest$ac_exeext conftest.$ac_ext
14132
14133 fi
14134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_libc_defines_sys_nerr" >&5
14135 $as_echo "$ac_cv_libc_defines_sys_nerr" >&6; }
14136 if test "x$ac_cv_libc_defines_sys_nerr" = "xyes" ; then
14137
14138 $as_echo "#define HAVE_SYS_NERR 1" >>confdefs.h
14139
14140 fi
14141
14142 # Check libraries needed by DNS fingerprint support
14143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing getrrsetbyname" >&5
14144 $as_echo_n "checking for library containing getrrsetbyname... " >&6; }
14145 if test "${ac_cv_search_getrrsetbyname+set}" = set; then :
14146   $as_echo_n "(cached) " >&6
14147 else
14148   ac_func_search_save_LIBS=$LIBS
14149 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14150 /* end confdefs.h.  */
14151
14152 /* Override any GCC internal prototype to avoid an error.
14153    Use char because int might match the return type of a GCC
14154    builtin and then its argument prototype would still apply.  */
14155 #ifdef __cplusplus
14156 extern "C"
14157 #endif
14158 char getrrsetbyname ();
14159 int
14160 main ()
14161 {
14162 return getrrsetbyname ();
14163   ;
14164   return 0;
14165 }
14166 _ACEOF
14167 for ac_lib in '' resolv; do
14168   if test -z "$ac_lib"; then
14169     ac_res="none required"
14170   else
14171     ac_res=-l$ac_lib
14172     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14173   fi
14174   if ac_fn_c_try_link "$LINENO"; then :
14175   ac_cv_search_getrrsetbyname=$ac_res
14176 fi
14177 rm -f core conftest.err conftest.$ac_objext \
14178     conftest$ac_exeext
14179   if test "${ac_cv_search_getrrsetbyname+set}" = set; then :
14180   break
14181 fi
14182 done
14183 if test "${ac_cv_search_getrrsetbyname+set}" = set; then :
14184
14185 else
14186   ac_cv_search_getrrsetbyname=no
14187 fi
14188 rm conftest.$ac_ext
14189 LIBS=$ac_func_search_save_LIBS
14190 fi
14191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_getrrsetbyname" >&5
14192 $as_echo "$ac_cv_search_getrrsetbyname" >&6; }
14193 ac_res=$ac_cv_search_getrrsetbyname
14194 if test "$ac_res" != no; then :
14195   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14196
14197 $as_echo "#define HAVE_GETRRSETBYNAME 1" >>confdefs.h
14198
14199 else
14200
14201                 # Needed by our getrrsetbyname()
14202                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing res_query" >&5
14203 $as_echo_n "checking for library containing res_query... " >&6; }
14204 if test "${ac_cv_search_res_query+set}" = set; then :
14205   $as_echo_n "(cached) " >&6
14206 else
14207   ac_func_search_save_LIBS=$LIBS
14208 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14209 /* end confdefs.h.  */
14210
14211 /* Override any GCC internal prototype to avoid an error.
14212    Use char because int might match the return type of a GCC
14213    builtin and then its argument prototype would still apply.  */
14214 #ifdef __cplusplus
14215 extern "C"
14216 #endif
14217 char res_query ();
14218 int
14219 main ()
14220 {
14221 return res_query ();
14222   ;
14223   return 0;
14224 }
14225 _ACEOF
14226 for ac_lib in '' resolv; do
14227   if test -z "$ac_lib"; then
14228     ac_res="none required"
14229   else
14230     ac_res=-l$ac_lib
14231     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14232   fi
14233   if ac_fn_c_try_link "$LINENO"; then :
14234   ac_cv_search_res_query=$ac_res
14235 fi
14236 rm -f core conftest.err conftest.$ac_objext \
14237     conftest$ac_exeext
14238   if test "${ac_cv_search_res_query+set}" = set; then :
14239   break
14240 fi
14241 done
14242 if test "${ac_cv_search_res_query+set}" = set; then :
14243
14244 else
14245   ac_cv_search_res_query=no
14246 fi
14247 rm conftest.$ac_ext
14248 LIBS=$ac_func_search_save_LIBS
14249 fi
14250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_res_query" >&5
14251 $as_echo "$ac_cv_search_res_query" >&6; }
14252 ac_res=$ac_cv_search_res_query
14253 if test "$ac_res" != no; then :
14254   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14255
14256 fi
14257
14258                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dn_expand" >&5
14259 $as_echo_n "checking for library containing dn_expand... " >&6; }
14260 if test "${ac_cv_search_dn_expand+set}" = set; then :
14261   $as_echo_n "(cached) " >&6
14262 else
14263   ac_func_search_save_LIBS=$LIBS
14264 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14265 /* end confdefs.h.  */
14266
14267 /* Override any GCC internal prototype to avoid an error.
14268    Use char because int might match the return type of a GCC
14269    builtin and then its argument prototype would still apply.  */
14270 #ifdef __cplusplus
14271 extern "C"
14272 #endif
14273 char dn_expand ();
14274 int
14275 main ()
14276 {
14277 return dn_expand ();
14278   ;
14279   return 0;
14280 }
14281 _ACEOF
14282 for ac_lib in '' resolv; do
14283   if test -z "$ac_lib"; then
14284     ac_res="none required"
14285   else
14286     ac_res=-l$ac_lib
14287     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14288   fi
14289   if ac_fn_c_try_link "$LINENO"; then :
14290   ac_cv_search_dn_expand=$ac_res
14291 fi
14292 rm -f core conftest.err conftest.$ac_objext \
14293     conftest$ac_exeext
14294   if test "${ac_cv_search_dn_expand+set}" = set; then :
14295   break
14296 fi
14297 done
14298 if test "${ac_cv_search_dn_expand+set}" = set; then :
14299
14300 else
14301   ac_cv_search_dn_expand=no
14302 fi
14303 rm conftest.$ac_ext
14304 LIBS=$ac_func_search_save_LIBS
14305 fi
14306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dn_expand" >&5
14307 $as_echo "$ac_cv_search_dn_expand" >&6; }
14308 ac_res=$ac_cv_search_dn_expand
14309 if test "$ac_res" != no; then :
14310   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14311
14312 fi
14313
14314                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if res_query will link" >&5
14315 $as_echo_n "checking if res_query will link... " >&6; }
14316                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14317 /* end confdefs.h.  */
14318
14319 #include <sys/types.h>
14320 #include <netinet/in.h>
14321 #include <arpa/nameser.h>
14322 #include <netdb.h>
14323 #include <resolv.h>
14324
14325 int
14326 main ()
14327 {
14328
14329         res_query (0, 0, 0, 0, 0);
14330
14331   ;
14332   return 0;
14333 }
14334 _ACEOF
14335 if ac_fn_c_try_link "$LINENO"; then :
14336   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14337 $as_echo "yes" >&6; }
14338 else
14339   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14340 $as_echo "no" >&6; }
14341                     saved_LIBS="$LIBS"
14342                     LIBS="$LIBS -lresolv"
14343                     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for res_query in -lresolv" >&5
14344 $as_echo_n "checking for res_query in -lresolv... " >&6; }
14345                     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14346 /* end confdefs.h.  */
14347
14348 #include <sys/types.h>
14349 #include <netinet/in.h>
14350 #include <arpa/nameser.h>
14351 #include <netdb.h>
14352 #include <resolv.h>
14353
14354 int
14355 main ()
14356 {
14357
14358         res_query (0, 0, 0, 0, 0);
14359
14360   ;
14361   return 0;
14362 }
14363 _ACEOF
14364 if ac_fn_c_try_link "$LINENO"; then :
14365   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14366 $as_echo "yes" >&6; }
14367 else
14368   LIBS="$saved_LIBS"
14369                          { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14370 $as_echo "no" >&6; }
14371 fi
14372 rm -f core conftest.err conftest.$ac_objext \
14373     conftest$ac_exeext conftest.$ac_ext
14374
14375 fi
14376 rm -f core conftest.err conftest.$ac_objext \
14377     conftest$ac_exeext conftest.$ac_ext
14378                 for ac_func in _getshort _getlong
14379 do :
14380   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14381 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14382 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
14383   cat >>confdefs.h <<_ACEOF
14384 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14385 _ACEOF
14386
14387 fi
14388 done
14389
14390                 ac_fn_c_check_decl "$LINENO" "_getshort" "ac_cv_have_decl__getshort" "#include <sys/types.h>
14391                     #include <arpa/nameser.h>
14392 "
14393 if test "x$ac_cv_have_decl__getshort" = x""yes; then :
14394   ac_have_decl=1
14395 else
14396   ac_have_decl=0
14397 fi
14398
14399 cat >>confdefs.h <<_ACEOF
14400 #define HAVE_DECL__GETSHORT $ac_have_decl
14401 _ACEOF
14402 ac_fn_c_check_decl "$LINENO" "_getlong" "ac_cv_have_decl__getlong" "#include <sys/types.h>
14403                     #include <arpa/nameser.h>
14404 "
14405 if test "x$ac_cv_have_decl__getlong" = x""yes; then :
14406   ac_have_decl=1
14407 else
14408   ac_have_decl=0
14409 fi
14410
14411 cat >>confdefs.h <<_ACEOF
14412 #define HAVE_DECL__GETLONG $ac_have_decl
14413 _ACEOF
14414
14415                 ac_fn_c_check_member "$LINENO" "HEADER" "ad" "ac_cv_member_HEADER_ad" "#include <arpa/nameser.h>
14416 "
14417 if test "x$ac_cv_member_HEADER_ad" = x""yes; then :
14418
14419 $as_echo "#define HAVE_HEADER_AD 1" >>confdefs.h
14420
14421 fi
14422
14423
14424 fi
14425
14426
14427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if struct __res_state _res is an extern" >&5
14428 $as_echo_n "checking if struct __res_state _res is an extern... " >&6; }
14429 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14430 /* end confdefs.h.  */
14431
14432 #include <stdio.h>
14433 #if HAVE_SYS_TYPES_H
14434 # include <sys/types.h>
14435 #endif
14436 #include <netinet/in.h>
14437 #include <arpa/nameser.h>
14438 #include <resolv.h>
14439 extern struct __res_state _res;
14440
14441 int
14442 main ()
14443 {
14444
14445   ;
14446   return 0;
14447 }
14448 _ACEOF
14449 if ac_fn_c_try_link "$LINENO"; then :
14450   { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14451 $as_echo "yes" >&6; }
14452
14453 $as_echo "#define HAVE__RES_EXTERN 1" >>confdefs.h
14454
14455
14456 else
14457    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14458 $as_echo "no" >&6; }
14459
14460 fi
14461 rm -f core conftest.err conftest.$ac_objext \
14462     conftest$ac_exeext conftest.$ac_ext
14463
14464 # Check whether user wants SELinux support
14465 SELINUX_MSG="no"
14466 LIBSELINUX=""
14467
14468 # Check whether --with-selinux was given.
14469 if test "${with_selinux+set}" = set; then :
14470   withval=$with_selinux;  if test "x$withval" != "xno" ; then
14471                 save_LIBS="$LIBS"
14472
14473 $as_echo "#define WITH_SELINUX 1" >>confdefs.h
14474
14475                 SELINUX_MSG="yes"
14476                 ac_fn_c_check_header_mongrel "$LINENO" "selinux/selinux.h" "ac_cv_header_selinux_selinux_h" "$ac_includes_default"
14477 if test "x$ac_cv_header_selinux_selinux_h" = x""yes; then :
14478
14479 else
14480   as_fn_error $? "SELinux support requires selinux.h header" "$LINENO" 5
14481 fi
14482
14483
14484                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for setexeccon in -lselinux" >&5
14485 $as_echo_n "checking for setexeccon in -lselinux... " >&6; }
14486 if test "${ac_cv_lib_selinux_setexeccon+set}" = set; then :
14487   $as_echo_n "(cached) " >&6
14488 else
14489   ac_check_lib_save_LIBS=$LIBS
14490 LIBS="-lselinux  $LIBS"
14491 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14492 /* end confdefs.h.  */
14493
14494 /* Override any GCC internal prototype to avoid an error.
14495    Use char because int might match the return type of a GCC
14496    builtin and then its argument prototype would still apply.  */
14497 #ifdef __cplusplus
14498 extern "C"
14499 #endif
14500 char setexeccon ();
14501 int
14502 main ()
14503 {
14504 return setexeccon ();
14505   ;
14506   return 0;
14507 }
14508 _ACEOF
14509 if ac_fn_c_try_link "$LINENO"; then :
14510   ac_cv_lib_selinux_setexeccon=yes
14511 else
14512   ac_cv_lib_selinux_setexeccon=no
14513 fi
14514 rm -f core conftest.err conftest.$ac_objext \
14515     conftest$ac_exeext conftest.$ac_ext
14516 LIBS=$ac_check_lib_save_LIBS
14517 fi
14518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_selinux_setexeccon" >&5
14519 $as_echo "$ac_cv_lib_selinux_setexeccon" >&6; }
14520 if test "x$ac_cv_lib_selinux_setexeccon" = x""yes; then :
14521    LIBSELINUX="-lselinux"
14522                           LIBS="$LIBS -lselinux"
14523
14524 else
14525   as_fn_error $? "SELinux support requires libselinux library" "$LINENO" 5
14526 fi
14527
14528                 SSHLIBS="$SSHLIBS $LIBSELINUX"
14529                 SSHDLIBS="$SSHDLIBS $LIBSELINUX"
14530                 for ac_func in getseuserbyname get_default_context_with_level
14531 do :
14532   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14533 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14534 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
14535   cat >>confdefs.h <<_ACEOF
14536 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14537 _ACEOF
14538
14539 fi
14540 done
14541
14542                 LIBS="$save_LIBS"
14543         fi
14544
14545 fi
14546
14547
14548
14549
14550 # Check whether user wants Kerberos 5 support
14551 KRB5_MSG="no"
14552
14553 # Check whether --with-kerberos5 was given.
14554 if test "${with_kerberos5+set}" = set; then :
14555   withval=$with_kerberos5;  if test "x$withval" != "xno" ; then
14556                 if test "x$withval" = "xyes" ; then
14557                         KRB5ROOT="/usr/local"
14558                 else
14559                         KRB5ROOT=${withval}
14560                 fi
14561
14562
14563 $as_echo "#define KRB5 1" >>confdefs.h
14564
14565                 KRB5_MSG="yes"
14566
14567                 # Extract the first word of "krb5-config", so it can be a program name with args.
14568 set dummy krb5-config; ac_word=$2
14569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
14570 $as_echo_n "checking for $ac_word... " >&6; }
14571 if test "${ac_cv_path_KRB5CONF+set}" = set; then :
14572   $as_echo_n "(cached) " >&6
14573 else
14574   case $KRB5CONF in
14575   [\\/]* | ?:[\\/]*)
14576   ac_cv_path_KRB5CONF="$KRB5CONF" # Let the user override the test with a path.
14577   ;;
14578   *)
14579   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
14580 as_dummy="$KRB5ROOT/bin:$PATH"
14581 for as_dir in $as_dummy
14582 do
14583   IFS=$as_save_IFS
14584   test -z "$as_dir" && as_dir=.
14585     for ac_exec_ext in '' $ac_executable_extensions; do
14586   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
14587     ac_cv_path_KRB5CONF="$as_dir/$ac_word$ac_exec_ext"
14588     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
14589     break 2
14590   fi
14591 done
14592   done
14593 IFS=$as_save_IFS
14594
14595   test -z "$ac_cv_path_KRB5CONF" && ac_cv_path_KRB5CONF="$KRB5ROOT/bin/krb5-config"
14596   ;;
14597 esac
14598 fi
14599 KRB5CONF=$ac_cv_path_KRB5CONF
14600 if test -n "$KRB5CONF"; then
14601   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $KRB5CONF" >&5
14602 $as_echo "$KRB5CONF" >&6; }
14603 else
14604   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14605 $as_echo "no" >&6; }
14606 fi
14607
14608
14609                 if test -x $KRB5CONF ; then
14610
14611                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gssapi support" >&5
14612 $as_echo_n "checking for gssapi support... " >&6; }
14613                         if $KRB5CONF | grep gssapi >/dev/null ; then
14614                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14615 $as_echo "yes" >&6; }
14616
14617 $as_echo "#define GSSAPI 1" >>confdefs.h
14618
14619                                 k5confopts=gssapi
14620                         else
14621                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14622 $as_echo "no" >&6; }
14623                                 k5confopts=""
14624                         fi
14625                         K5CFLAGS="`$KRB5CONF --cflags $k5confopts`"
14626                         K5LIBS="`$KRB5CONF --libs $k5confopts`"
14627                         CPPFLAGS="$CPPFLAGS $K5CFLAGS"
14628                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using Heimdal" >&5
14629 $as_echo_n "checking whether we are using Heimdal... " >&6; }
14630                         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14631 /* end confdefs.h.  */
14632  #include <krb5.h>
14633
14634 int
14635 main ()
14636 {
14637  char *tmp = heimdal_version;
14638   ;
14639   return 0;
14640 }
14641 _ACEOF
14642 if ac_fn_c_try_compile "$LINENO"; then :
14643    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14644 $as_echo "yes" >&6; }
14645
14646 $as_echo "#define HEIMDAL 1" >>confdefs.h
14647
14648 else
14649   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14650 $as_echo "no" >&6; }
14651
14652 fi
14653 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14654                 else
14655                         CPPFLAGS="$CPPFLAGS -I${KRB5ROOT}/include"
14656                         LDFLAGS="$LDFLAGS -L${KRB5ROOT}/lib"
14657                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using Heimdal" >&5
14658 $as_echo_n "checking whether we are using Heimdal... " >&6; }
14659                         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14660 /* end confdefs.h.  */
14661  #include <krb5.h>
14662
14663 int
14664 main ()
14665 {
14666  char *tmp = heimdal_version;
14667   ;
14668   return 0;
14669 }
14670 _ACEOF
14671 if ac_fn_c_try_compile "$LINENO"; then :
14672    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
14673 $as_echo "yes" >&6; }
14674                                          $as_echo "#define HEIMDAL 1" >>confdefs.h
14675
14676                                          K5LIBS="-lkrb5"
14677                                          K5LIBS="$K5LIBS -lcom_err -lasn1"
14678                                          { $as_echo "$as_me:${as_lineno-$LINENO}: checking for net_write in -lroken" >&5
14679 $as_echo_n "checking for net_write in -lroken... " >&6; }
14680 if test "${ac_cv_lib_roken_net_write+set}" = set; then :
14681   $as_echo_n "(cached) " >&6
14682 else
14683   ac_check_lib_save_LIBS=$LIBS
14684 LIBS="-lroken  $LIBS"
14685 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14686 /* end confdefs.h.  */
14687
14688 /* Override any GCC internal prototype to avoid an error.
14689    Use char because int might match the return type of a GCC
14690    builtin and then its argument prototype would still apply.  */
14691 #ifdef __cplusplus
14692 extern "C"
14693 #endif
14694 char net_write ();
14695 int
14696 main ()
14697 {
14698 return net_write ();
14699   ;
14700   return 0;
14701 }
14702 _ACEOF
14703 if ac_fn_c_try_link "$LINENO"; then :
14704   ac_cv_lib_roken_net_write=yes
14705 else
14706   ac_cv_lib_roken_net_write=no
14707 fi
14708 rm -f core conftest.err conftest.$ac_objext \
14709     conftest$ac_exeext conftest.$ac_ext
14710 LIBS=$ac_check_lib_save_LIBS
14711 fi
14712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_roken_net_write" >&5
14713 $as_echo "$ac_cv_lib_roken_net_write" >&6; }
14714 if test "x$ac_cv_lib_roken_net_write" = x""yes; then :
14715   K5LIBS="$K5LIBS -lroken"
14716 fi
14717
14718                                          { $as_echo "$as_me:${as_lineno-$LINENO}: checking for des_cbc_encrypt in -ldes" >&5
14719 $as_echo_n "checking for des_cbc_encrypt in -ldes... " >&6; }
14720 if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then :
14721   $as_echo_n "(cached) " >&6
14722 else
14723   ac_check_lib_save_LIBS=$LIBS
14724 LIBS="-ldes  $LIBS"
14725 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14726 /* end confdefs.h.  */
14727
14728 /* Override any GCC internal prototype to avoid an error.
14729    Use char because int might match the return type of a GCC
14730    builtin and then its argument prototype would still apply.  */
14731 #ifdef __cplusplus
14732 extern "C"
14733 #endif
14734 char des_cbc_encrypt ();
14735 int
14736 main ()
14737 {
14738 return des_cbc_encrypt ();
14739   ;
14740   return 0;
14741 }
14742 _ACEOF
14743 if ac_fn_c_try_link "$LINENO"; then :
14744   ac_cv_lib_des_des_cbc_encrypt=yes
14745 else
14746   ac_cv_lib_des_des_cbc_encrypt=no
14747 fi
14748 rm -f core conftest.err conftest.$ac_objext \
14749     conftest$ac_exeext conftest.$ac_ext
14750 LIBS=$ac_check_lib_save_LIBS
14751 fi
14752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
14753 $as_echo "$ac_cv_lib_des_des_cbc_encrypt" >&6; }
14754 if test "x$ac_cv_lib_des_des_cbc_encrypt" = x""yes; then :
14755   K5LIBS="$K5LIBS -ldes"
14756 fi
14757
14758
14759 else
14760    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
14761 $as_echo "no" >&6; }
14762                                          K5LIBS="-lkrb5 -lk5crypto -lcom_err"
14763
14764
14765 fi
14766 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14767                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing dn_expand" >&5
14768 $as_echo_n "checking for library containing dn_expand... " >&6; }
14769 if test "${ac_cv_search_dn_expand+set}" = set; then :
14770   $as_echo_n "(cached) " >&6
14771 else
14772   ac_func_search_save_LIBS=$LIBS
14773 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14774 /* end confdefs.h.  */
14775
14776 /* Override any GCC internal prototype to avoid an error.
14777    Use char because int might match the return type of a GCC
14778    builtin and then its argument prototype would still apply.  */
14779 #ifdef __cplusplus
14780 extern "C"
14781 #endif
14782 char dn_expand ();
14783 int
14784 main ()
14785 {
14786 return dn_expand ();
14787   ;
14788   return 0;
14789 }
14790 _ACEOF
14791 for ac_lib in '' resolv; do
14792   if test -z "$ac_lib"; then
14793     ac_res="none required"
14794   else
14795     ac_res=-l$ac_lib
14796     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14797   fi
14798   if ac_fn_c_try_link "$LINENO"; then :
14799   ac_cv_search_dn_expand=$ac_res
14800 fi
14801 rm -f core conftest.err conftest.$ac_objext \
14802     conftest$ac_exeext
14803   if test "${ac_cv_search_dn_expand+set}" = set; then :
14804   break
14805 fi
14806 done
14807 if test "${ac_cv_search_dn_expand+set}" = set; then :
14808
14809 else
14810   ac_cv_search_dn_expand=no
14811 fi
14812 rm conftest.$ac_ext
14813 LIBS=$ac_func_search_save_LIBS
14814 fi
14815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_dn_expand" >&5
14816 $as_echo "$ac_cv_search_dn_expand" >&6; }
14817 ac_res=$ac_cv_search_dn_expand
14818 if test "$ac_res" != no; then :
14819   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14820
14821 fi
14822
14823
14824                         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gss_init_sec_context in -lgssapi_krb5" >&5
14825 $as_echo_n "checking for gss_init_sec_context in -lgssapi_krb5... " >&6; }
14826 if test "${ac_cv_lib_gssapi_krb5_gss_init_sec_context+set}" = set; then :
14827   $as_echo_n "(cached) " >&6
14828 else
14829   ac_check_lib_save_LIBS=$LIBS
14830 LIBS="-lgssapi_krb5 $K5LIBS $LIBS"
14831 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14832 /* end confdefs.h.  */
14833
14834 /* Override any GCC internal prototype to avoid an error.
14835    Use char because int might match the return type of a GCC
14836    builtin and then its argument prototype would still apply.  */
14837 #ifdef __cplusplus
14838 extern "C"
14839 #endif
14840 char gss_init_sec_context ();
14841 int
14842 main ()
14843 {
14844 return gss_init_sec_context ();
14845   ;
14846   return 0;
14847 }
14848 _ACEOF
14849 if ac_fn_c_try_link "$LINENO"; then :
14850   ac_cv_lib_gssapi_krb5_gss_init_sec_context=yes
14851 else
14852   ac_cv_lib_gssapi_krb5_gss_init_sec_context=no
14853 fi
14854 rm -f core conftest.err conftest.$ac_objext \
14855     conftest$ac_exeext conftest.$ac_ext
14856 LIBS=$ac_check_lib_save_LIBS
14857 fi
14858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gssapi_krb5_gss_init_sec_context" >&5
14859 $as_echo "$ac_cv_lib_gssapi_krb5_gss_init_sec_context" >&6; }
14860 if test "x$ac_cv_lib_gssapi_krb5_gss_init_sec_context" = x""yes; then :
14861    $as_echo "#define GSSAPI 1" >>confdefs.h
14862
14863                                   K5LIBS="-lgssapi_krb5 $K5LIBS"
14864 else
14865    { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gss_init_sec_context in -lgssapi" >&5
14866 $as_echo_n "checking for gss_init_sec_context in -lgssapi... " >&6; }
14867 if test "${ac_cv_lib_gssapi_gss_init_sec_context+set}" = set; then :
14868   $as_echo_n "(cached) " >&6
14869 else
14870   ac_check_lib_save_LIBS=$LIBS
14871 LIBS="-lgssapi $K5LIBS $LIBS"
14872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
14873 /* end confdefs.h.  */
14874
14875 /* Override any GCC internal prototype to avoid an error.
14876    Use char because int might match the return type of a GCC
14877    builtin and then its argument prototype would still apply.  */
14878 #ifdef __cplusplus
14879 extern "C"
14880 #endif
14881 char gss_init_sec_context ();
14882 int
14883 main ()
14884 {
14885 return gss_init_sec_context ();
14886   ;
14887   return 0;
14888 }
14889 _ACEOF
14890 if ac_fn_c_try_link "$LINENO"; then :
14891   ac_cv_lib_gssapi_gss_init_sec_context=yes
14892 else
14893   ac_cv_lib_gssapi_gss_init_sec_context=no
14894 fi
14895 rm -f core conftest.err conftest.$ac_objext \
14896     conftest$ac_exeext conftest.$ac_ext
14897 LIBS=$ac_check_lib_save_LIBS
14898 fi
14899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gssapi_gss_init_sec_context" >&5
14900 $as_echo "$ac_cv_lib_gssapi_gss_init_sec_context" >&6; }
14901 if test "x$ac_cv_lib_gssapi_gss_init_sec_context" = x""yes; then :
14902    $as_echo "#define GSSAPI 1" >>confdefs.h
14903
14904                                           K5LIBS="-lgssapi $K5LIBS"
14905 else
14906   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot find any suitable gss-api library - build may fail" >&5
14907 $as_echo "$as_me: WARNING: Cannot find any suitable gss-api library - build may fail" >&2;}
14908 fi
14909
14910
14911 fi
14912
14913
14914                         ac_fn_c_check_header_mongrel "$LINENO" "gssapi.h" "ac_cv_header_gssapi_h" "$ac_includes_default"
14915 if test "x$ac_cv_header_gssapi_h" = x""yes; then :
14916
14917 else
14918    unset ac_cv_header_gssapi_h
14919                                   CPPFLAGS="$CPPFLAGS -I${KRB5ROOT}/include/gssapi"
14920                                   for ac_header in gssapi.h
14921 do :
14922   ac_fn_c_check_header_mongrel "$LINENO" "gssapi.h" "ac_cv_header_gssapi_h" "$ac_includes_default"
14923 if test "x$ac_cv_header_gssapi_h" = x""yes; then :
14924   cat >>confdefs.h <<_ACEOF
14925 #define HAVE_GSSAPI_H 1
14926 _ACEOF
14927
14928 else
14929   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Cannot find any suitable gss-api header - build may fail" >&5
14930 $as_echo "$as_me: WARNING: Cannot find any suitable gss-api header - build may fail" >&2;}
14931
14932 fi
14933
14934 done
14935
14936
14937
14938 fi
14939
14940
14941
14942                         oldCPP="$CPPFLAGS"
14943                         CPPFLAGS="$CPPFLAGS -I${KRB5ROOT}/include/gssapi"
14944                         ac_fn_c_check_header_mongrel "$LINENO" "gssapi_krb5.h" "ac_cv_header_gssapi_krb5_h" "$ac_includes_default"
14945 if test "x$ac_cv_header_gssapi_krb5_h" = x""yes; then :
14946
14947 else
14948    CPPFLAGS="$oldCPP"
14949 fi
14950
14951
14952
14953                 fi
14954                 if test ! -z "$need_dash_r" ; then
14955                         LDFLAGS="$LDFLAGS -R${KRB5ROOT}/lib"
14956                 fi
14957                 if test ! -z "$blibpath" ; then
14958                         blibpath="$blibpath:${KRB5ROOT}/lib"
14959                 fi
14960
14961                 SAVELIBS=$LIBS
14962                 LIBS="$LIBS $K5LIBS"
14963                 for ac_func in gss_localname gss_userok
14964 do :
14965   as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
14966 ac_fn_c_check_func "$LINENO" "$ac_func" "$as_ac_var"
14967 if eval test \"x\$"$as_ac_var"\" = x"yes"; then :
14968   cat >>confdefs.h <<_ACEOF
14969 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
14970 _ACEOF
14971
14972 fi
14973 done
14974
14975                 LIBS=$SAVELIBS
14976
14977                 for ac_header in gssapi.h gssapi/gssapi.h gssapi/gssapi_ext.h
14978 do :
14979   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14980 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
14981 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14982   cat >>confdefs.h <<_ACEOF
14983 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14984 _ACEOF
14985
14986 fi
14987
14988 done
14989
14990                 for ac_header in gssapi_krb5.h gssapi/gssapi_krb5.h
14991 do :
14992   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
14993 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
14994 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
14995   cat >>confdefs.h <<_ACEOF
14996 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14997 _ACEOF
14998
14999 fi
15000
15001 done
15002
15003                 for ac_header in gssapi_generic.h gssapi/gssapi_generic.h
15004 do :
15005   as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
15006 ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
15007 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
15008   cat >>confdefs.h <<_ACEOF
15009 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
15010 _ACEOF
15011
15012 fi
15013
15014 done
15015
15016
15017                 LIBS="$LIBS $K5LIBS"
15018                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing k_hasafs" >&5
15019 $as_echo_n "checking for library containing k_hasafs... " >&6; }
15020 if test "${ac_cv_search_k_hasafs+set}" = set; then :
15021   $as_echo_n "(cached) " >&6
15022 else
15023   ac_func_search_save_LIBS=$LIBS
15024 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15025 /* end confdefs.h.  */
15026
15027 /* Override any GCC internal prototype to avoid an error.
15028    Use char because int might match the return type of a GCC
15029    builtin and then its argument prototype would still apply.  */
15030 #ifdef __cplusplus
15031 extern "C"
15032 #endif
15033 char k_hasafs ();
15034 int
15035 main ()
15036 {
15037 return k_hasafs ();
15038   ;
15039   return 0;
15040 }
15041 _ACEOF
15042 for ac_lib in '' kafs; do
15043   if test -z "$ac_lib"; then
15044     ac_res="none required"
15045   else
15046     ac_res=-l$ac_lib
15047     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
15048   fi
15049   if ac_fn_c_try_link "$LINENO"; then :
15050   ac_cv_search_k_hasafs=$ac_res
15051 fi
15052 rm -f core conftest.err conftest.$ac_objext \
15053     conftest$ac_exeext
15054   if test "${ac_cv_search_k_hasafs+set}" = set; then :
15055   break
15056 fi
15057 done
15058 if test "${ac_cv_search_k_hasafs+set}" = set; then :
15059
15060 else
15061   ac_cv_search_k_hasafs=no
15062 fi
15063 rm conftest.$ac_ext
15064 LIBS=$ac_func_search_save_LIBS
15065 fi
15066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_search_k_hasafs" >&5
15067 $as_echo "$ac_cv_search_k_hasafs" >&6; }
15068 ac_res=$ac_cv_search_k_hasafs
15069 if test "$ac_res" != no; then :
15070   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
15071
15072 $as_echo "#define USE_AFS 1" >>confdefs.h
15073
15074 fi
15075
15076         fi
15077
15078
15079 fi
15080
15081
15082 # Looking for programs, paths and files
15083
15084 PRIVSEP_PATH=/var/empty
15085
15086 # Check whether --with-privsep-path was given.
15087 if test "${with_privsep_path+set}" = set; then :
15088   withval=$with_privsep_path;
15089                 if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
15090                     test "x${withval}" != "xyes"; then
15091                         PRIVSEP_PATH=$withval
15092                 fi
15093
15094
15095 fi
15096
15097
15098
15099
15100 # Check whether --with-xauth was given.
15101 if test "${with_xauth+set}" = set; then :
15102   withval=$with_xauth;
15103                 if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
15104                     test "x${withval}" != "xyes"; then
15105                         xauth_path=$withval
15106                 fi
15107
15108 else
15109
15110                 TestPath="$PATH"
15111                 TestPath="${TestPath}${PATH_SEPARATOR}/usr/X/bin"
15112                 TestPath="${TestPath}${PATH_SEPARATOR}/usr/bin/X11"
15113                 TestPath="${TestPath}${PATH_SEPARATOR}/usr/X11R6/bin"
15114                 TestPath="${TestPath}${PATH_SEPARATOR}/usr/openwin/bin"
15115                 # Extract the first word of "xauth", so it can be a program name with args.
15116 set dummy xauth; ac_word=$2
15117 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15118 $as_echo_n "checking for $ac_word... " >&6; }
15119 if test "${ac_cv_path_xauth_path+set}" = set; then :
15120   $as_echo_n "(cached) " >&6
15121 else
15122   case $xauth_path in
15123   [\\/]* | ?:[\\/]*)
15124   ac_cv_path_xauth_path="$xauth_path" # Let the user override the test with a path.
15125   ;;
15126   *)
15127   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15128 for as_dir in $TestPath
15129 do
15130   IFS=$as_save_IFS
15131   test -z "$as_dir" && as_dir=.
15132     for ac_exec_ext in '' $ac_executable_extensions; do
15133   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
15134     ac_cv_path_xauth_path="$as_dir/$ac_word$ac_exec_ext"
15135     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15136     break 2
15137   fi
15138 done
15139   done
15140 IFS=$as_save_IFS
15141
15142   ;;
15143 esac
15144 fi
15145 xauth_path=$ac_cv_path_xauth_path
15146 if test -n "$xauth_path"; then
15147   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $xauth_path" >&5
15148 $as_echo "$xauth_path" >&6; }
15149 else
15150   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15151 $as_echo "no" >&6; }
15152 fi
15153
15154
15155                 if (test ! -z "$xauth_path" && test -x "/usr/openwin/bin/xauth") ; then
15156                         xauth_path="/usr/openwin/bin/xauth"
15157                 fi
15158
15159
15160 fi
15161
15162
15163 STRIP_OPT=-s
15164 # Check whether --enable-strip was given.
15165 if test "${enable_strip+set}" = set; then :
15166   enableval=$enable_strip;
15167                 if test "x$enableval" = "xno" ; then
15168                         STRIP_OPT=
15169                 fi
15170
15171
15172 fi
15173
15174
15175
15176 if test -z "$xauth_path" ; then
15177         XAUTH_PATH="undefined"
15178
15179 else
15180
15181 cat >>confdefs.h <<_ACEOF
15182 #define XAUTH_PATH "$xauth_path"
15183 _ACEOF
15184
15185         XAUTH_PATH=$xauth_path
15186
15187 fi
15188
15189 # Check for mail directory
15190
15191 # Check whether --with-maildir was given.
15192 if test "${with_maildir+set}" = set; then :
15193   withval=$with_maildir;
15194         if test "X$withval" != X  &&  test "x$withval" != xno  &&  \
15195             test "x${withval}" != xyes; then
15196
15197 cat >>confdefs.h <<_ACEOF
15198 #define MAIL_DIRECTORY "$withval"
15199 _ACEOF
15200
15201             fi
15202
15203 else
15204
15205         if test "X$maildir" != "X"; then
15206             cat >>confdefs.h <<_ACEOF
15207 #define MAIL_DIRECTORY "$maildir"
15208 _ACEOF
15209
15210         else
15211             { $as_echo "$as_me:${as_lineno-$LINENO}: checking Discovering system mail directory" >&5
15212 $as_echo_n "checking Discovering system mail directory... " >&6; }
15213             if test "$cross_compiling" = yes; then :
15214
15215                         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: use --with-maildir=/path/to/mail" >&5
15216 $as_echo "$as_me: WARNING: cross compiling: use --with-maildir=/path/to/mail" >&2;}
15217
15218
15219 else
15220   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15221 /* end confdefs.h.  */
15222
15223 #include <stdio.h>
15224 #include <string.h>
15225 #ifdef HAVE_PATHS_H
15226 #include <paths.h>
15227 #endif
15228 #ifdef HAVE_MAILLOCK_H
15229 #include <maillock.h>
15230 #endif
15231 #define DATA "conftest.maildir"
15232
15233 int
15234 main ()
15235 {
15236
15237         FILE *fd;
15238         int rc;
15239
15240         fd = fopen(DATA,"w");
15241         if(fd == NULL)
15242                 exit(1);
15243
15244 #if defined (_PATH_MAILDIR)
15245         if ((rc = fprintf(fd ,"_PATH_MAILDIR:%s\n", _PATH_MAILDIR)) <0)
15246                 exit(1);
15247 #elif defined (MAILDIR)
15248         if ((rc = fprintf(fd ,"MAILDIR:%s\n", MAILDIR)) <0)
15249                 exit(1);
15250 #elif defined (_PATH_MAIL)
15251         if ((rc = fprintf(fd ,"_PATH_MAIL:%s\n", _PATH_MAIL)) <0)
15252                 exit(1);
15253 #else
15254         exit (2);
15255 #endif
15256
15257         exit(0);
15258
15259   ;
15260   return 0;
15261 }
15262 _ACEOF
15263 if ac_fn_c_try_run "$LINENO"; then :
15264
15265                     maildir_what=`awk -F: '{print $1}' conftest.maildir`
15266                     maildir=`awk -F: '{print $2}' conftest.maildir \
15267                         | sed 's|/$||'`
15268                     { $as_echo "$as_me:${as_lineno-$LINENO}: result: Using: $maildir from $maildir_what" >&5
15269 $as_echo "Using: $maildir from $maildir_what" >&6; }
15270                     if test "x$maildir_what" != "x_PATH_MAILDIR"; then
15271                         cat >>confdefs.h <<_ACEOF
15272 #define MAIL_DIRECTORY "$maildir"
15273 _ACEOF
15274
15275                     fi
15276
15277 else
15278
15279                     if test "X$ac_status" = "X2";then
15280 # our test program didn't find it. Default to /var/spool/mail
15281                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: Using: default value of /var/spool/mail" >&5
15282 $as_echo "Using: default value of /var/spool/mail" >&6; }
15283                         cat >>confdefs.h <<_ACEOF
15284 #define MAIL_DIRECTORY "/var/spool/mail"
15285 _ACEOF
15286
15287                      else
15288                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: *** not found ***" >&5
15289 $as_echo "*** not found ***" >&6; }
15290                      fi
15291
15292 fi
15293 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15294   conftest.$ac_objext conftest.beam conftest.$ac_ext
15295 fi
15296
15297         fi
15298
15299
15300 fi
15301  # maildir
15302
15303 if test ! -z "$cross_compiling" && test "x$cross_compiling" = "xyes"; then
15304         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: Disabling /dev/ptmx test" >&5
15305 $as_echo "$as_me: WARNING: cross compiling: Disabling /dev/ptmx test" >&2;}
15306         disable_ptmx_check=yes
15307 fi
15308 if test -z "$no_dev_ptmx" ; then
15309         if test "x$disable_ptmx_check" != "xyes" ; then
15310                 as_ac_File=`$as_echo "ac_cv_file_"/dev/ptmx"" | $as_tr_sh`
15311 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for \"/dev/ptmx\"" >&5
15312 $as_echo_n "checking for \"/dev/ptmx\"... " >&6; }
15313 if eval "test \"\${$as_ac_File+set}\"" = set; then :
15314   $as_echo_n "(cached) " >&6
15315 else
15316   test "$cross_compiling" = yes &&
15317   as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15318 if test -r ""/dev/ptmx""; then
15319   eval "$as_ac_File=yes"
15320 else
15321   eval "$as_ac_File=no"
15322 fi
15323 fi
15324 eval ac_res=\$$as_ac_File
15325                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15326 $as_echo "$ac_res" >&6; }
15327 if eval test \"x\$"$as_ac_File"\" = x"yes"; then :
15328
15329
15330 cat >>confdefs.h <<_ACEOF
15331 #define HAVE_DEV_PTMX 1
15332 _ACEOF
15333
15334                                 have_dev_ptmx=1
15335
15336
15337 fi
15338
15339         fi
15340 fi
15341
15342 if test ! -z "$cross_compiling" && test "x$cross_compiling" != "xyes"; then
15343         as_ac_File=`$as_echo "ac_cv_file_"/dev/ptc"" | $as_tr_sh`
15344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for \"/dev/ptc\"" >&5
15345 $as_echo_n "checking for \"/dev/ptc\"... " >&6; }
15346 if eval "test \"\${$as_ac_File+set}\"" = set; then :
15347   $as_echo_n "(cached) " >&6
15348 else
15349   test "$cross_compiling" = yes &&
15350   as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15351 if test -r ""/dev/ptc""; then
15352   eval "$as_ac_File=yes"
15353 else
15354   eval "$as_ac_File=no"
15355 fi
15356 fi
15357 eval ac_res=\$$as_ac_File
15358                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15359 $as_echo "$ac_res" >&6; }
15360 if eval test \"x\$"$as_ac_File"\" = x"yes"; then :
15361
15362
15363 cat >>confdefs.h <<_ACEOF
15364 #define HAVE_DEV_PTS_AND_PTC 1
15365 _ACEOF
15366
15367                         have_dev_ptc=1
15368
15369
15370 fi
15371
15372 else
15373         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: Disabling /dev/ptc test" >&5
15374 $as_echo "$as_me: WARNING: cross compiling: Disabling /dev/ptc test" >&2;}
15375 fi
15376
15377 # Options from here on. Some of these are preset by platform above
15378
15379 # Check whether --with-mantype was given.
15380 if test "${with_mantype+set}" = set; then :
15381   withval=$with_mantype;
15382                 case "$withval" in
15383                 man|cat|doc)
15384                         MANTYPE=$withval
15385                         ;;
15386                 *)
15387                         as_fn_error $? "invalid man type: $withval" "$LINENO" 5
15388                         ;;
15389                 esac
15390
15391
15392 fi
15393
15394 if test -z "$MANTYPE"; then
15395         TestPath="/usr/bin${PATH_SEPARATOR}/usr/ucb"
15396         for ac_prog in nroff awf
15397 do
15398   # Extract the first word of "$ac_prog", so it can be a program name with args.
15399 set dummy $ac_prog; ac_word=$2
15400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
15401 $as_echo_n "checking for $ac_word... " >&6; }
15402 if test "${ac_cv_path_NROFF+set}" = set; then :
15403   $as_echo_n "(cached) " >&6
15404 else
15405   case $NROFF in
15406   [\\/]* | ?:[\\/]*)
15407   ac_cv_path_NROFF="$NROFF" # Let the user override the test with a path.
15408   ;;
15409   *)
15410   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15411 for as_dir in $TestPath
15412 do
15413   IFS=$as_save_IFS
15414   test -z "$as_dir" && as_dir=.
15415     for ac_exec_ext in '' $ac_executable_extensions; do
15416   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
15417     ac_cv_path_NROFF="$as_dir/$ac_word$ac_exec_ext"
15418     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
15419     break 2
15420   fi
15421 done
15422   done
15423 IFS=$as_save_IFS
15424
15425   ;;
15426 esac
15427 fi
15428 NROFF=$ac_cv_path_NROFF
15429 if test -n "$NROFF"; then
15430   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NROFF" >&5
15431 $as_echo "$NROFF" >&6; }
15432 else
15433   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15434 $as_echo "no" >&6; }
15435 fi
15436
15437
15438   test -n "$NROFF" && break
15439 done
15440 test -n "$NROFF" || NROFF="/bin/false"
15441
15442         if ${NROFF} -mdoc ${srcdir}/ssh.1 >/dev/null 2>&1; then
15443                 MANTYPE=doc
15444         elif ${NROFF} -man ${srcdir}/ssh.1 >/dev/null 2>&1; then
15445                 MANTYPE=man
15446         else
15447                 MANTYPE=cat
15448         fi
15449 fi
15450
15451 if test "$MANTYPE" = "doc"; then
15452         mansubdir=man;
15453 else
15454         mansubdir=$MANTYPE;
15455 fi
15456
15457
15458 # Check whether to enable MD5 passwords
15459 MD5_MSG="no"
15460
15461 # Check whether --with-md5-passwords was given.
15462 if test "${with_md5_passwords+set}" = set; then :
15463   withval=$with_md5_passwords;
15464                 if test "x$withval" != "xno" ; then
15465
15466 $as_echo "#define HAVE_MD5_PASSWORDS 1" >>confdefs.h
15467
15468                         MD5_MSG="yes"
15469                 fi
15470
15471
15472 fi
15473
15474
15475 # Whether to disable shadow password support
15476
15477 # Check whether --with-shadow was given.
15478 if test "${with_shadow+set}" = set; then :
15479   withval=$with_shadow;
15480                 if test "x$withval" = "xno" ; then
15481                         $as_echo "#define DISABLE_SHADOW 1" >>confdefs.h
15482
15483                         disable_shadow=yes
15484                 fi
15485
15486
15487 fi
15488
15489
15490 if test -z "$disable_shadow" ; then
15491         { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the systems has expire shadow information" >&5
15492 $as_echo_n "checking if the systems has expire shadow information... " >&6; }
15493         cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15494 /* end confdefs.h.  */
15495
15496 #include <sys/types.h>
15497 #include <shadow.h>
15498 struct spwd sp;
15499
15500 int
15501 main ()
15502 {
15503  sp.sp_expire = sp.sp_lstchg = sp.sp_inact = 0;
15504   ;
15505   return 0;
15506 }
15507 _ACEOF
15508 if ac_fn_c_try_compile "$LINENO"; then :
15509    sp_expire_available=yes
15510 fi
15511 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15512
15513         if test "x$sp_expire_available" = "xyes" ; then
15514                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15515 $as_echo "yes" >&6; }
15516
15517 $as_echo "#define HAS_SHADOW_EXPIRE 1" >>confdefs.h
15518
15519         else
15520                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15521 $as_echo "no" >&6; }
15522         fi
15523 fi
15524
15525 # Use ip address instead of hostname in $DISPLAY
15526 if test ! -z "$IPADDR_IN_DISPLAY" ; then
15527         DISPLAY_HACK_MSG="yes"
15528
15529 $as_echo "#define IPADDR_IN_DISPLAY 1" >>confdefs.h
15530
15531 else
15532         DISPLAY_HACK_MSG="no"
15533
15534 # Check whether --with-ipaddr-display was given.
15535 if test "${with_ipaddr_display+set}" = set; then :
15536   withval=$with_ipaddr_display;
15537                         if test "x$withval" != "xno" ; then
15538                                 $as_echo "#define IPADDR_IN_DISPLAY 1" >>confdefs.h
15539
15540                                 DISPLAY_HACK_MSG="yes"
15541                         fi
15542
15543
15544 fi
15545
15546 fi
15547
15548 # check for /etc/default/login and use it if present.
15549 # Check whether --enable-etc-default-login was given.
15550 if test "${enable_etc_default_login+set}" = set; then :
15551   enableval=$enable_etc_default_login;  if test "x$enableval" = "xno"; then
15552                 { $as_echo "$as_me:${as_lineno-$LINENO}: /etc/default/login handling disabled" >&5
15553 $as_echo "$as_me: /etc/default/login handling disabled" >&6;}
15554                 etc_default_login=no
15555           else
15556                 etc_default_login=yes
15557           fi
15558 else
15559    if test ! -z "$cross_compiling" && test "x$cross_compiling" = "xyes";
15560           then
15561                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cross compiling: not checking /etc/default/login" >&5
15562 $as_echo "$as_me: WARNING: cross compiling: not checking /etc/default/login" >&2;}
15563                 etc_default_login=no
15564           else
15565                 etc_default_login=yes
15566           fi
15567
15568 fi
15569
15570
15571 if test "x$etc_default_login" != "xno"; then
15572         as_ac_File=`$as_echo "ac_cv_file_"/etc/default/login"" | $as_tr_sh`
15573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for \"/etc/default/login\"" >&5
15574 $as_echo_n "checking for \"/etc/default/login\"... " >&6; }
15575 if eval "test \"\${$as_ac_File+set}\"" = set; then :
15576   $as_echo_n "(cached) " >&6
15577 else
15578   test "$cross_compiling" = yes &&
15579   as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
15580 if test -r ""/etc/default/login""; then
15581   eval "$as_ac_File=yes"
15582 else
15583   eval "$as_ac_File=no"
15584 fi
15585 fi
15586 eval ac_res=\$$as_ac_File
15587                { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5
15588 $as_echo "$ac_res" >&6; }
15589 if eval test \"x\$"$as_ac_File"\" = x"yes"; then :
15590    external_path_file=/etc/default/login
15591 fi
15592
15593         if test "x$external_path_file" = "x/etc/default/login"; then
15594
15595 $as_echo "#define HAVE_ETC_DEFAULT_LOGIN 1" >>confdefs.h
15596
15597         fi
15598 fi
15599
15600 if test $ac_cv_func_login_getcapbool = "yes" && \
15601         test $ac_cv_header_login_cap_h = "yes" ; then
15602         external_path_file=/etc/login.conf
15603 fi
15604
15605 # Whether to mess with the default path
15606 SERVER_PATH_MSG="(default)"
15607
15608 # Check whether --with-default-path was given.
15609 if test "${with_default_path+set}" = set; then :
15610   withval=$with_default_path;
15611                 if test "x$external_path_file" = "x/etc/login.conf" ; then
15612                         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
15613 --with-default-path=PATH has no effect on this system.
15614 Edit /etc/login.conf instead." >&5
15615 $as_echo "$as_me: WARNING:
15616 --with-default-path=PATH has no effect on this system.
15617 Edit /etc/login.conf instead." >&2;}
15618                 elif test "x$withval" != "xno" ; then
15619                         if test ! -z "$external_path_file" ; then
15620                                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
15621 --with-default-path=PATH will only be used if PATH is not defined in
15622 $external_path_file ." >&5
15623 $as_echo "$as_me: WARNING:
15624 --with-default-path=PATH will only be used if PATH is not defined in
15625 $external_path_file ." >&2;}
15626                         fi
15627                         user_path="$withval"
15628                         SERVER_PATH_MSG="$withval"
15629                 fi
15630
15631 else
15632    if test "x$external_path_file" = "x/etc/login.conf" ; then
15633                 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Make sure the path to scp is in /etc/login.conf" >&5
15634 $as_echo "$as_me: WARNING: Make sure the path to scp is in /etc/login.conf" >&2;}
15635         else
15636                 if test ! -z "$external_path_file" ; then
15637                         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING:
15638 If PATH is defined in $external_path_file, ensure the path to scp is included,
15639 otherwise scp will not work." >&5
15640 $as_echo "$as_me: WARNING:
15641 If PATH is defined in $external_path_file, ensure the path to scp is included,
15642 otherwise scp will not work." >&2;}
15643                 fi
15644                 if test "$cross_compiling" = yes; then :
15645    user_path="/usr/bin:/bin:/usr/sbin:/sbin"
15646
15647 else
15648   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15649 /* end confdefs.h.  */
15650
15651 /* find out what STDPATH is */
15652 #include <stdio.h>
15653 #ifdef HAVE_PATHS_H
15654 # include <paths.h>
15655 #endif
15656 #ifndef _PATH_STDPATH
15657 # ifdef _PATH_USERPATH  /* Irix */
15658 #  define _PATH_STDPATH _PATH_USERPATH
15659 # else
15660 #  define _PATH_STDPATH "/usr/bin:/bin:/usr/sbin:/sbin"
15661 # endif
15662 #endif
15663 #include <sys/types.h>
15664 #include <sys/stat.h>
15665 #include <fcntl.h>
15666 #define DATA "conftest.stdpath"
15667
15668 int
15669 main ()
15670 {
15671
15672         FILE *fd;
15673         int rc;
15674
15675         fd = fopen(DATA,"w");
15676         if(fd == NULL)
15677                 exit(1);
15678
15679         if ((rc = fprintf(fd,"%s", _PATH_STDPATH)) < 0)
15680                 exit(1);
15681
15682         exit(0);
15683
15684   ;
15685   return 0;
15686 }
15687 _ACEOF
15688 if ac_fn_c_try_run "$LINENO"; then :
15689    user_path=`cat conftest.stdpath`
15690 else
15691    user_path="/usr/bin:/bin:/usr/sbin:/sbin"
15692 fi
15693 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \
15694   conftest.$ac_objext conftest.beam conftest.$ac_ext
15695 fi
15696
15697 # make sure $bindir is in USER_PATH so scp will work
15698                 t_bindir=`eval echo ${bindir}`
15699                 case $t_bindir in
15700                         NONE/*) t_bindir=`echo $t_bindir | sed "s~NONE~$prefix~"` ;;
15701                 esac
15702                 case $t_bindir in
15703                         NONE/*) t_bindir=`echo $t_bindir | sed "s~NONE~$ac_default_prefix~"` ;;
15704                 esac
15705                 echo $user_path | grep ":$t_bindir"  > /dev/null 2>&1
15706                 if test $? -ne 0  ; then
15707                         echo $user_path | grep "^$t_bindir"  > /dev/null 2>&1
15708                         if test $? -ne 0  ; then
15709                                 user_path=$user_path:$t_bindir
15710                                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Adding $t_bindir to USER_PATH so scp will work" >&5
15711 $as_echo "Adding $t_bindir to USER_PATH so scp will work" >&6; }
15712                         fi
15713                 fi
15714         fi
15715
15716 fi
15717
15718 if test "x$external_path_file" != "x/etc/login.conf" ; then
15719
15720 cat >>confdefs.h <<_ACEOF
15721 #define USER_PATH "$user_path"
15722 _ACEOF
15723
15724
15725 fi
15726
15727 # Set superuser path separately to user path
15728
15729 # Check whether --with-superuser-path was given.
15730 if test "${with_superuser_path+set}" = set; then :
15731   withval=$with_superuser_path;
15732                 if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
15733                     test "x${withval}" != "xyes"; then
15734
15735 cat >>confdefs.h <<_ACEOF
15736 #define SUPERUSER_PATH "$withval"
15737 _ACEOF
15738
15739                         superuser_path=$withval
15740                 fi
15741
15742
15743 fi
15744
15745
15746
15747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we need to convert IPv4 in IPv6-mapped addresses" >&5
15748 $as_echo_n "checking if we need to convert IPv4 in IPv6-mapped addresses... " >&6; }
15749 IPV4_IN6_HACK_MSG="no"
15750
15751 # Check whether --with-4in6 was given.
15752 if test "${with_4in6+set}" = set; then :
15753   withval=$with_4in6;
15754                 if test "x$withval" != "xno" ; then
15755                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15756 $as_echo "yes" >&6; }
15757
15758 $as_echo "#define IPV4_IN_IPV6 1" >>confdefs.h
15759
15760                         IPV4_IN6_HACK_MSG="yes"
15761                 else
15762                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15763 $as_echo "no" >&6; }
15764                 fi
15765
15766 else
15767
15768                 if test "x$inet6_default_4in6" = "xyes"; then
15769                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5
15770 $as_echo "yes (default)" >&6; }
15771                         $as_echo "#define IPV4_IN_IPV6 1" >>confdefs.h
15772
15773                         IPV4_IN6_HACK_MSG="yes"
15774                 else
15775                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no (default)" >&5
15776 $as_echo "no (default)" >&6; }
15777                 fi
15778
15779
15780 fi
15781
15782
15783 # Whether to enable BSD auth support
15784 BSD_AUTH_MSG=no
15785
15786 # Check whether --with-bsd-auth was given.
15787 if test "${with_bsd_auth+set}" = set; then :
15788   withval=$with_bsd_auth;
15789                 if test "x$withval" != "xno" ; then
15790
15791 $as_echo "#define BSD_AUTH 1" >>confdefs.h
15792
15793                         BSD_AUTH_MSG=yes
15794                 fi
15795
15796
15797 fi
15798
15799
15800 # Where to place sshd.pid
15801 piddir=/var/run
15802 # make sure the directory exists
15803 if test ! -d $piddir ; then
15804         piddir=`eval echo ${sysconfdir}`
15805         case $piddir in
15806                 NONE/*) piddir=`echo $piddir | sed "s~NONE~$ac_default_prefix~"` ;;
15807         esac
15808 fi
15809
15810
15811 # Check whether --with-pid-dir was given.
15812 if test "${with_pid_dir+set}" = set; then :
15813   withval=$with_pid_dir;
15814                 if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
15815                     test "x${withval}" != "xyes"; then
15816                         piddir=$withval
15817                         if test ! -d $piddir ; then
15818                         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ** no $piddir directory on this system **" >&5
15819 $as_echo "$as_me: WARNING: ** no $piddir directory on this system **" >&2;}
15820                         fi
15821                 fi
15822
15823
15824 fi
15825
15826
15827
15828 cat >>confdefs.h <<_ACEOF
15829 #define _PATH_SSH_PIDDIR "$piddir"
15830 _ACEOF
15831
15832
15833
15834 # Check whether --enable-lastlog was given.
15835 if test "${enable_lastlog+set}" = set; then :
15836   enableval=$enable_lastlog;
15837                 if test "x$enableval" = "xno" ; then
15838                         $as_echo "#define DISABLE_LASTLOG 1" >>confdefs.h
15839
15840                 fi
15841
15842
15843 fi
15844
15845 # Check whether --enable-utmp was given.
15846 if test "${enable_utmp+set}" = set; then :
15847   enableval=$enable_utmp;
15848                 if test "x$enableval" = "xno" ; then
15849                         $as_echo "#define DISABLE_UTMP 1" >>confdefs.h
15850
15851                 fi
15852
15853
15854 fi
15855
15856 # Check whether --enable-utmpx was given.
15857 if test "${enable_utmpx+set}" = set; then :
15858   enableval=$enable_utmpx;
15859                 if test "x$enableval" = "xno" ; then
15860
15861 $as_echo "#define DISABLE_UTMPX 1" >>confdefs.h
15862
15863                 fi
15864
15865
15866 fi
15867
15868 # Check whether --enable-wtmp was given.
15869 if test "${enable_wtmp+set}" = set; then :
15870   enableval=$enable_wtmp;
15871                 if test "x$enableval" = "xno" ; then
15872                         $as_echo "#define DISABLE_WTMP 1" >>confdefs.h
15873
15874                 fi
15875
15876
15877 fi
15878
15879 # Check whether --enable-wtmpx was given.
15880 if test "${enable_wtmpx+set}" = set; then :
15881   enableval=$enable_wtmpx;
15882                 if test "x$enableval" = "xno" ; then
15883
15884 $as_echo "#define DISABLE_WTMPX 1" >>confdefs.h
15885
15886                 fi
15887
15888
15889 fi
15890
15891 # Check whether --enable-libutil was given.
15892 if test "${enable_libutil+set}" = set; then :
15893   enableval=$enable_libutil;
15894                 if test "x$enableval" = "xno" ; then
15895                         $as_echo "#define DISABLE_LOGIN 1" >>confdefs.h
15896
15897                 fi
15898
15899
15900 fi
15901
15902 # Check whether --enable-pututline was given.
15903 if test "${enable_pututline+set}" = set; then :
15904   enableval=$enable_pututline;
15905                 if test "x$enableval" = "xno" ; then
15906
15907 $as_echo "#define DISABLE_PUTUTLINE 1" >>confdefs.h
15908
15909                 fi
15910
15911
15912 fi
15913
15914 # Check whether --enable-pututxline was given.
15915 if test "${enable_pututxline+set}" = set; then :
15916   enableval=$enable_pututxline;
15917                 if test "x$enableval" = "xno" ; then
15918
15919 $as_echo "#define DISABLE_PUTUTXLINE 1" >>confdefs.h
15920
15921                 fi
15922
15923
15924 fi
15925
15926
15927 # Check whether --with-lastlog was given.
15928 if test "${with_lastlog+set}" = set; then :
15929   withval=$with_lastlog;
15930                 if test "x$withval" = "xno" ; then
15931                         $as_echo "#define DISABLE_LASTLOG 1" >>confdefs.h
15932
15933                 elif test -n "$withval"  &&  test "x${withval}" != "xyes"; then
15934                         conf_lastlog_location=$withval
15935                 fi
15936
15937
15938 fi
15939
15940
15941
15942 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if your system defines LASTLOG_FILE" >&5
15943 $as_echo_n "checking if your system defines LASTLOG_FILE... " >&6; }
15944 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15945 /* end confdefs.h.  */
15946
15947 #include <sys/types.h>
15948 #include <utmp.h>
15949 #ifdef HAVE_LASTLOG_H
15950 #  include <lastlog.h>
15951 #endif
15952 #ifdef HAVE_PATHS_H
15953 #  include <paths.h>
15954 #endif
15955 #ifdef HAVE_LOGIN_H
15956 # include <login.h>
15957 #endif
15958
15959 int
15960 main ()
15961 {
15962  char *lastlog = LASTLOG_FILE;
15963   ;
15964   return 0;
15965 }
15966 _ACEOF
15967 if ac_fn_c_try_compile "$LINENO"; then :
15968    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15969 $as_echo "yes" >&6; }
15970 else
15971
15972                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
15973 $as_echo "no" >&6; }
15974                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if your system defines _PATH_LASTLOG" >&5
15975 $as_echo_n "checking if your system defines _PATH_LASTLOG... " >&6; }
15976                 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
15977 /* end confdefs.h.  */
15978
15979 #include <sys/types.h>
15980 #include <utmp.h>
15981 #ifdef HAVE_LASTLOG_H
15982 #  include <lastlog.h>
15983 #endif
15984 #ifdef HAVE_PATHS_H
15985 #  include <paths.h>
15986 #endif
15987
15988 int
15989 main ()
15990 {
15991  char *lastlog = _PATH_LASTLOG;
15992   ;
15993   return 0;
15994 }
15995 _ACEOF
15996 if ac_fn_c_try_compile "$LINENO"; then :
15997    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
15998 $as_echo "yes" >&6; }
15999 else
16000
16001                         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16002 $as_echo "no" >&6; }
16003                         system_lastlog_path=no
16004
16005 fi
16006 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16007
16008 fi
16009 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16010
16011 if test -z "$conf_lastlog_location"; then
16012         if test x"$system_lastlog_path" = x"no" ; then
16013                 for f in /var/log/lastlog /usr/adm/lastlog /var/adm/lastlog /etc/security/lastlog ; do
16014                                 if (test -d "$f" || test -f "$f") ; then
16015                                         conf_lastlog_location=$f
16016                                 fi
16017                 done
16018                 if test -z "$conf_lastlog_location"; then
16019                         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ** Cannot find lastlog **" >&5
16020 $as_echo "$as_me: WARNING: ** Cannot find lastlog **" >&2;}
16021                                         fi
16022         fi
16023 fi
16024
16025 if test -n "$conf_lastlog_location"; then
16026
16027 cat >>confdefs.h <<_ACEOF
16028 #define CONF_LASTLOG_FILE "$conf_lastlog_location"
16029 _ACEOF
16030
16031 fi
16032
16033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if your system defines UTMP_FILE" >&5
16034 $as_echo_n "checking if your system defines UTMP_FILE... " >&6; }
16035 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16036 /* end confdefs.h.  */
16037
16038 #include <sys/types.h>
16039 #include <utmp.h>
16040 #ifdef HAVE_PATHS_H
16041 #  include <paths.h>
16042 #endif
16043
16044 int
16045 main ()
16046 {
16047  char *utmp = UTMP_FILE;
16048   ;
16049   return 0;
16050 }
16051 _ACEOF
16052 if ac_fn_c_try_compile "$LINENO"; then :
16053    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16054 $as_echo "yes" >&6; }
16055 else
16056    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16057 $as_echo "no" >&6; }
16058           system_utmp_path=no
16059
16060 fi
16061 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16062 if test -z "$conf_utmp_location"; then
16063         if test x"$system_utmp_path" = x"no" ; then
16064                 for f in /etc/utmp /usr/adm/utmp /var/run/utmp; do
16065                         if test -f $f ; then
16066                                 conf_utmp_location=$f
16067                         fi
16068                 done
16069                 if test -z "$conf_utmp_location"; then
16070                         $as_echo "#define DISABLE_UTMP 1" >>confdefs.h
16071
16072                 fi
16073         fi
16074 fi
16075 if test -n "$conf_utmp_location"; then
16076
16077 cat >>confdefs.h <<_ACEOF
16078 #define CONF_UTMP_FILE "$conf_utmp_location"
16079 _ACEOF
16080
16081 fi
16082
16083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if your system defines WTMP_FILE" >&5
16084 $as_echo_n "checking if your system defines WTMP_FILE... " >&6; }
16085 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16086 /* end confdefs.h.  */
16087
16088 #include <sys/types.h>
16089 #include <utmp.h>
16090 #ifdef HAVE_PATHS_H
16091 #  include <paths.h>
16092 #endif
16093
16094 int
16095 main ()
16096 {
16097  char *wtmp = WTMP_FILE;
16098   ;
16099   return 0;
16100 }
16101 _ACEOF
16102 if ac_fn_c_try_compile "$LINENO"; then :
16103    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16104 $as_echo "yes" >&6; }
16105 else
16106    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16107 $as_echo "no" >&6; }
16108           system_wtmp_path=no
16109
16110 fi
16111 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16112 if test -z "$conf_wtmp_location"; then
16113         if test x"$system_wtmp_path" = x"no" ; then
16114                 for f in /usr/adm/wtmp /var/log/wtmp; do
16115                         if test -f $f ; then
16116                                 conf_wtmp_location=$f
16117                         fi
16118                 done
16119                 if test -z "$conf_wtmp_location"; then
16120                         $as_echo "#define DISABLE_WTMP 1" >>confdefs.h
16121
16122                 fi
16123         fi
16124 fi
16125 if test -n "$conf_wtmp_location"; then
16126
16127 cat >>confdefs.h <<_ACEOF
16128 #define CONF_WTMP_FILE "$conf_wtmp_location"
16129 _ACEOF
16130
16131 fi
16132
16133
16134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if your system defines WTMPX_FILE" >&5
16135 $as_echo_n "checking if your system defines WTMPX_FILE... " >&6; }
16136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext
16137 /* end confdefs.h.  */
16138
16139 #include <sys/types.h>
16140 #include <utmp.h>
16141 #ifdef HAVE_UTMPX_H
16142 #include <utmpx.h>
16143 #endif
16144 #ifdef HAVE_PATHS_H
16145 #  include <paths.h>
16146 #endif
16147
16148 int
16149 main ()
16150 {
16151  char *wtmpx = WTMPX_FILE;
16152   ;
16153   return 0;
16154 }
16155 _ACEOF
16156 if ac_fn_c_try_compile "$LINENO"; then :
16157    { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
16158 $as_echo "yes" >&6; }
16159 else
16160    { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
16161 $as_echo "no" >&6; }
16162           system_wtmpx_path=no
16163
16164 fi
16165 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16166 if test -z "$conf_wtmpx_location"; then
16167         if test x"$system_wtmpx_path" = x"no" ; then
16168                 $as_echo "#define DISABLE_WTMPX 1" >>confdefs.h
16169
16170         fi
16171 else
16172
16173 cat >>confdefs.h <<_ACEOF
16174 #define CONF_WTMPX_FILE "$conf_wtmpx_location"
16175 _ACEOF
16176
16177 fi
16178
16179
16180 if test ! -z "$blibpath" ; then
16181         LDFLAGS="$LDFLAGS $blibflags$blibpath"
16182         { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please check and edit blibpath in LDFLAGS in Makefile" >&5
16183 $as_echo "$as_me: WARNING: Please check and edit blibpath in LDFLAGS in Makefile" >&2;}
16184 fi
16185
16186 CFLAGS="$CFLAGS $werror_flags"
16187
16188 if test "x$ac_cv_func_getaddrinfo" != "xyes" ; then
16189         TEST_SSH_IPV6=no
16190 else
16191         TEST_SSH_IPV6=yes
16192 fi
16193 ac_fn_c_check_decl "$LINENO" "BROKEN_GETADDRINFO" "ac_cv_have_decl_BROKEN_GETADDRINFO" "$ac_includes_default"
16194 if test "x$ac_cv_have_decl_BROKEN_GETADDRINFO" = x""yes; then :
16195   TEST_SSH_IPV6=no
16196 fi
16197
16198 TEST_SSH_IPV6=$TEST_SSH_IPV6
16199
16200
16201
16202 ac_config_files="$ac_config_files Makefile buildpkg.sh opensshd.init openssh.xml openbsd-compat/Makefile openbsd-compat/regress/Makefile survey.sh"
16203
16204 cat >confcache <<\_ACEOF
16205 # This file is a shell script that caches the results of configure
16206 # tests run on this system so they can be shared between configure
16207 # scripts and configure runs, see configure's option --config-cache.
16208 # It is not useful on other systems.  If it contains results you don't
16209 # want to keep, you may remove or edit it.
16210 #
16211 # config.status only pays attention to the cache file if you give it
16212 # the --recheck option to rerun configure.
16213 #
16214 # `ac_cv_env_foo' variables (set or unset) will be overridden when
16215 # loading this file, other *unset* `ac_cv_foo' will be assigned the
16216 # following values.
16217
16218 _ACEOF
16219
16220 # The following way of writing the cache mishandles newlines in values,
16221 # but we know of no workaround that is simple, portable, and efficient.
16222 # So, we kill variables containing newlines.
16223 # Ultrix sh set writes to stderr and can't be redirected directly,
16224 # and sets the high bit in the cache file unless we assign to the vars.
16225 (
16226   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
16227     eval ac_val=\$$ac_var
16228     case $ac_val in #(
16229     *${as_nl}*)
16230       case $ac_var in #(
16231       *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5
16232 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
16233       esac
16234       case $ac_var in #(
16235       _ | IFS | as_nl) ;; #(
16236       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
16237       *) { eval $ac_var=; unset $ac_var;} ;;
16238       esac ;;
16239     esac
16240   done
16241
16242   (set) 2>&1 |
16243     case $as_nl`(ac_space=' '; set) 2>&1` in #(
16244     *${as_nl}ac_space=\ *)
16245       # `set' does not quote correctly, so add quotes: double-quote
16246       # substitution turns \\\\ into \\, and sed turns \\ into \.
16247       sed -n \
16248         "s/'/'\\\\''/g;
16249           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
16250       ;; #(
16251     *)
16252       # `set' quotes correctly as required by POSIX, so do not add quotes.
16253       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
16254       ;;
16255     esac |
16256     sort
16257 ) |
16258   sed '
16259      /^ac_cv_env_/b end
16260      t clear
16261      :clear
16262      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
16263      t end
16264      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
16265      :end' >>confcache
16266 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
16267   if test -w "$cache_file"; then
16268     test "x$cache_file" != "x/dev/null" &&
16269       { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5
16270 $as_echo "$as_me: updating cache $cache_file" >&6;}
16271     cat confcache >$cache_file
16272   else
16273     { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5
16274 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
16275   fi
16276 fi
16277 rm -f confcache
16278
16279 test "x$prefix" = xNONE && prefix=$ac_default_prefix
16280 # Let make expand exec_prefix.
16281 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
16282
16283 DEFS=-DHAVE_CONFIG_H
16284
16285 ac_libobjs=
16286 ac_ltlibobjs=
16287 U=
16288 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
16289   # 1. Remove the extension, and $U if already installed.
16290   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
16291   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
16292   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
16293   #    will be set to the directory where LIBOBJS objects are built.
16294   as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext"
16295   as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo'
16296 done
16297 LIBOBJS=$ac_libobjs
16298
16299 LTLIBOBJS=$ac_ltlibobjs
16300
16301
16302
16303
16304 : ${CONFIG_STATUS=./config.status}
16305 ac_write_fail=0
16306 ac_clean_files_save=$ac_clean_files
16307 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
16308 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5
16309 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
16310 as_write_fail=0
16311 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1
16312 #! $SHELL
16313 # Generated by $as_me.
16314 # Run this file to recreate the current configuration.
16315 # Compiler output produced by configure, useful for debugging
16316 # configure, is in config.log if it exists.
16317
16318 debug=false
16319 ac_cs_recheck=false
16320 ac_cs_silent=false
16321
16322 SHELL=\${CONFIG_SHELL-$SHELL}
16323 export SHELL
16324 _ASEOF
16325 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1
16326 ## -------------------- ##
16327 ## M4sh Initialization. ##
16328 ## -------------------- ##
16329
16330 # Be more Bourne compatible
16331 DUALCASE=1; export DUALCASE # for MKS sh
16332 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then :
16333   emulate sh
16334   NULLCMD=:
16335   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
16336   # is contrary to our usage.  Disable this feature.
16337   alias -g '${1+"$@"}'='"$@"'
16338   setopt NO_GLOB_SUBST
16339 else
16340   case `(set -o) 2>/dev/null` in #(
16341   *posix*) :
16342     set -o posix ;; #(
16343   *) :
16344      ;;
16345 esac
16346 fi
16347
16348
16349 as_nl='
16350 '
16351 export as_nl
16352 # Printing a long string crashes Solaris 7 /usr/bin/printf.
16353 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
16354 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
16355 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
16356 # Prefer a ksh shell builtin over an external printf program on Solaris,
16357 # but without wasting forks for bash or zsh.
16358 if test -z "$BASH_VERSION$ZSH_VERSION" \
16359     && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then
16360   as_echo='print -r --'
16361   as_echo_n='print -rn --'
16362 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
16363   as_echo='printf %s\n'
16364   as_echo_n='printf %s'
16365 else
16366   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
16367     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
16368     as_echo_n='/usr/ucb/echo -n'
16369   else
16370     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
16371     as_echo_n_body='eval
16372       arg=$1;
16373       case $arg in #(
16374       *"$as_nl"*)
16375         expr "X$arg" : "X\\(.*\\)$as_nl";
16376         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
16377       esac;
16378       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
16379     '
16380     export as_echo_n_body
16381     as_echo_n='sh -c $as_echo_n_body as_echo'
16382   fi
16383   export as_echo_body
16384   as_echo='sh -c $as_echo_body as_echo'
16385 fi
16386
16387 # The user is always right.
16388 if test "${PATH_SEPARATOR+set}" != set; then
16389   PATH_SEPARATOR=:
16390   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
16391     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
16392       PATH_SEPARATOR=';'
16393   }
16394 fi
16395
16396
16397 # IFS
16398 # We need space, tab and new line, in precisely that order.  Quoting is
16399 # there to prevent editors from complaining about space-tab.
16400 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
16401 # splitting by setting IFS to empty value.)
16402 IFS=" ""        $as_nl"
16403
16404 # Find who we are.  Look in the path if we contain no directory separator.
16405 case $0 in #((
16406   *[\\/]* ) as_myself=$0 ;;
16407   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16408 for as_dir in $PATH
16409 do
16410   IFS=$as_save_IFS
16411   test -z "$as_dir" && as_dir=.
16412     test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
16413   done
16414 IFS=$as_save_IFS
16415
16416      ;;
16417 esac
16418 # We did not find ourselves, most probably we were run as `sh COMMAND'
16419 # in which case we are not to be found in the path.
16420 if test "x$as_myself" = x; then
16421   as_myself=$0
16422 fi
16423 if test ! -f "$as_myself"; then
16424   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
16425   exit 1
16426 fi
16427
16428 # Unset variables that we do not need and which cause bugs (e.g. in
16429 # pre-3.0 UWIN ksh).  But do not cause bugs in bash 2.01; the "|| exit 1"
16430 # suppresses any "Segmentation fault" message there.  '((' could
16431 # trigger a bug in pdksh 5.2.14.
16432 for as_var in BASH_ENV ENV MAIL MAILPATH
16433 do eval test x\${$as_var+set} = xset \
16434   && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || :
16435 done
16436 PS1='$ '
16437 PS2='> '
16438 PS4='+ '
16439
16440 # NLS nuisances.
16441 LC_ALL=C
16442 export LC_ALL
16443 LANGUAGE=C
16444 export LANGUAGE
16445
16446 # CDPATH.
16447 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH
16448
16449
16450 # as_fn_error STATUS ERROR [LINENO LOG_FD]
16451 # ----------------------------------------
16452 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are
16453 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the
16454 # script with STATUS, using 1 if that was 0.
16455 as_fn_error ()
16456 {
16457   as_status=$1; test $as_status -eq 0 && as_status=1
16458   if test "$4"; then
16459     as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack
16460     $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4
16461   fi
16462   $as_echo "$as_me: error: $2" >&2
16463   as_fn_exit $as_status
16464 } # as_fn_error
16465
16466
16467 # as_fn_set_status STATUS
16468 # -----------------------
16469 # Set $? to STATUS, without forking.
16470 as_fn_set_status ()
16471 {
16472   return $1
16473 } # as_fn_set_status
16474
16475 # as_fn_exit STATUS
16476 # -----------------
16477 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context.
16478 as_fn_exit ()
16479 {
16480   set +e
16481   as_fn_set_status $1
16482   exit $1
16483 } # as_fn_exit
16484
16485 # as_fn_unset VAR
16486 # ---------------
16487 # Portably unset VAR.
16488 as_fn_unset ()
16489 {
16490   { eval $1=; unset $1;}
16491 }
16492 as_unset=as_fn_unset
16493 # as_fn_append VAR VALUE
16494 # ----------------------
16495 # Append the text in VALUE to the end of the definition contained in VAR. Take
16496 # advantage of any shell optimizations that allow amortized linear growth over
16497 # repeated appends, instead of the typical quadratic growth present in naive
16498 # implementations.
16499 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then :
16500   eval 'as_fn_append ()
16501   {
16502     eval $1+=\$2
16503   }'
16504 else
16505   as_fn_append ()
16506   {
16507     eval $1=\$$1\$2
16508   }
16509 fi # as_fn_append
16510
16511 # as_fn_arith ARG...
16512 # ------------------
16513 # Perform arithmetic evaluation on the ARGs, and store the result in the
16514 # global $as_val. Take advantage of shells that can avoid forks. The arguments
16515 # must be portable across $(()) and expr.
16516 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then :
16517   eval 'as_fn_arith ()
16518   {
16519     as_val=$(( $* ))
16520   }'
16521 else
16522   as_fn_arith ()
16523   {
16524     as_val=`expr "$@" || test $? -eq 1`
16525   }
16526 fi # as_fn_arith
16527
16528
16529 if expr a : '\(a\)' >/dev/null 2>&1 &&
16530    test "X`expr 00001 : '.*\(...\)'`" = X001; then
16531   as_expr=expr
16532 else
16533   as_expr=false
16534 fi
16535
16536 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
16537   as_basename=basename
16538 else
16539   as_basename=false
16540 fi
16541
16542 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
16543   as_dirname=dirname
16544 else
16545   as_dirname=false
16546 fi
16547
16548 as_me=`$as_basename -- "$0" ||
16549 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
16550          X"$0" : 'X\(//\)$' \| \
16551          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
16552 $as_echo X/"$0" |
16553     sed '/^.*\/\([^/][^/]*\)\/*$/{
16554             s//\1/
16555             q
16556           }
16557           /^X\/\(\/\/\)$/{
16558             s//\1/
16559             q
16560           }
16561           /^X\/\(\/\).*/{
16562             s//\1/
16563             q
16564           }
16565           s/.*/./; q'`
16566
16567 # Avoid depending upon Character Ranges.
16568 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
16569 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
16570 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
16571 as_cr_digits='0123456789'
16572 as_cr_alnum=$as_cr_Letters$as_cr_digits
16573
16574 ECHO_C= ECHO_N= ECHO_T=
16575 case `echo -n x` in #(((((
16576 -n*)
16577   case `echo 'xy\c'` in
16578   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
16579   xy)  ECHO_C='\c';;
16580   *)   echo `echo ksh88 bug on AIX 6.1` > /dev/null
16581        ECHO_T=' ';;
16582   esac;;
16583 *)
16584   ECHO_N='-n';;
16585 esac
16586
16587 rm -f conf$$ conf$$.exe conf$$.file
16588 if test -d conf$$.dir; then
16589   rm -f conf$$.dir/conf$$.file
16590 else
16591   rm -f conf$$.dir
16592   mkdir conf$$.dir 2>/dev/null
16593 fi
16594 if (echo >conf$$.file) 2>/dev/null; then
16595   if ln -s conf$$.file conf$$ 2>/dev/null; then
16596     as_ln_s='ln -s'
16597     # ... but there are two gotchas:
16598     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
16599     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
16600     # In both cases, we have to default to `cp -p'.
16601     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
16602       as_ln_s='cp -p'
16603   elif ln conf$$.file conf$$ 2>/dev/null; then
16604     as_ln_s=ln
16605   else
16606     as_ln_s='cp -p'
16607   fi
16608 else
16609   as_ln_s='cp -p'
16610 fi
16611 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
16612 rmdir conf$$.dir 2>/dev/null
16613
16614
16615 # as_fn_mkdir_p
16616 # -------------
16617 # Create "$as_dir" as a directory, including parents if necessary.
16618 as_fn_mkdir_p ()
16619 {
16620
16621   case $as_dir in #(
16622   -*) as_dir=./$as_dir;;
16623   esac
16624   test -d "$as_dir" || eval $as_mkdir_p || {
16625     as_dirs=
16626     while :; do
16627       case $as_dir in #(
16628       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
16629       *) as_qdir=$as_dir;;
16630       esac
16631       as_dirs="'$as_qdir' $as_dirs"
16632       as_dir=`$as_dirname -- "$as_dir" ||
16633 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
16634          X"$as_dir" : 'X\(//\)[^/]' \| \
16635          X"$as_dir" : 'X\(//\)$' \| \
16636          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
16637 $as_echo X"$as_dir" |
16638     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
16639             s//\1/
16640             q
16641           }
16642           /^X\(\/\/\)[^/].*/{
16643             s//\1/
16644             q
16645           }
16646           /^X\(\/\/\)$/{
16647             s//\1/
16648             q
16649           }
16650           /^X\(\/\).*/{
16651             s//\1/
16652             q
16653           }
16654           s/.*/./; q'`
16655       test -d "$as_dir" && break
16656     done
16657     test -z "$as_dirs" || eval "mkdir $as_dirs"
16658   } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir"
16659
16660
16661 } # as_fn_mkdir_p
16662 if mkdir -p . 2>/dev/null; then
16663   as_mkdir_p='mkdir -p "$as_dir"'
16664 else
16665   test -d ./-p && rmdir ./-p
16666   as_mkdir_p=false
16667 fi
16668
16669 if test -x / >/dev/null 2>&1; then
16670   as_test_x='test -x'
16671 else
16672   if ls -dL / >/dev/null 2>&1; then
16673     as_ls_L_option=L
16674   else
16675     as_ls_L_option=
16676   fi
16677   as_test_x='
16678     eval sh -c '\''
16679       if test -d "$1"; then
16680         test -d "$1/.";
16681       else
16682         case $1 in #(
16683         -*)set "./$1";;
16684         esac;
16685         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in #((
16686         ???[sx]*):;;*)false;;esac;fi
16687     '\'' sh
16688   '
16689 fi
16690 as_executable_p=$as_test_x
16691
16692 # Sed expression to map a string onto a valid CPP name.
16693 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
16694
16695 # Sed expression to map a string onto a valid variable name.
16696 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
16697
16698
16699 exec 6>&1
16700 ## ----------------------------------- ##
16701 ## Main body of $CONFIG_STATUS script. ##
16702 ## ----------------------------------- ##
16703 _ASEOF
16704 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1
16705
16706 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16707 # Save the log message, to keep $0 and so on meaningful, and to
16708 # report actual input values of CONFIG_FILES etc. instead of their
16709 # values after options handling.
16710 ac_log="
16711 This file was extended by OpenSSH $as_me Portable, which was
16712 generated by GNU Autoconf 2.67.  Invocation command line was
16713
16714   CONFIG_FILES    = $CONFIG_FILES
16715   CONFIG_HEADERS  = $CONFIG_HEADERS
16716   CONFIG_LINKS    = $CONFIG_LINKS
16717   CONFIG_COMMANDS = $CONFIG_COMMANDS
16718   $ $0 $@
16719
16720 on `(hostname || uname -n) 2>/dev/null | sed 1q`
16721 "
16722
16723 _ACEOF
16724
16725 case $ac_config_files in *"
16726 "*) set x $ac_config_files; shift; ac_config_files=$*;;
16727 esac
16728
16729 case $ac_config_headers in *"
16730 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
16731 esac
16732
16733
16734 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16735 # Files that config.status was made for.
16736 config_files="$ac_config_files"
16737 config_headers="$ac_config_headers"
16738
16739 _ACEOF
16740
16741 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16742 ac_cs_usage="\
16743 \`$as_me' instantiates files and other configuration actions
16744 from templates according to the current configuration.  Unless the files
16745 and actions are specified as TAGs, all are instantiated by default.
16746
16747 Usage: $0 [OPTION]... [TAG]...
16748
16749   -h, --help       print this help, then exit
16750   -V, --version    print version number and configuration settings, then exit
16751       --config     print configuration, then exit
16752   -q, --quiet, --silent
16753                    do not print progress messages
16754   -d, --debug      don't remove temporary files
16755       --recheck    update $as_me by reconfiguring in the same conditions
16756       --file=FILE[:TEMPLATE]
16757                    instantiate the configuration file FILE
16758       --header=FILE[:TEMPLATE]
16759                    instantiate the configuration header FILE
16760
16761 Configuration files:
16762 $config_files
16763
16764 Configuration headers:
16765 $config_headers
16766
16767 Report bugs to <openssh-unix-dev@mindrot.org>."
16768
16769 _ACEOF
16770 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16771 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
16772 ac_cs_version="\\
16773 OpenSSH config.status Portable
16774 configured by $0, generated by GNU Autoconf 2.67,
16775   with options \\"\$ac_cs_config\\"
16776
16777 Copyright (C) 2010 Free Software Foundation, Inc.
16778 This config.status script is free software; the Free Software Foundation
16779 gives unlimited permission to copy, distribute and modify it."
16780
16781 ac_pwd='$ac_pwd'
16782 srcdir='$srcdir'
16783 INSTALL='$INSTALL'
16784 AWK='$AWK'
16785 test -n "\$AWK" || AWK=awk
16786 _ACEOF
16787
16788 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16789 # The default lists apply if the user does not specify any file.
16790 ac_need_defaults=:
16791 while test $# != 0
16792 do
16793   case $1 in
16794   --*=?*)
16795     ac_option=`expr "X$1" : 'X\([^=]*\)='`
16796     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
16797     ac_shift=:
16798     ;;
16799   --*=)
16800     ac_option=`expr "X$1" : 'X\([^=]*\)='`
16801     ac_optarg=
16802     ac_shift=:
16803     ;;
16804   *)
16805     ac_option=$1
16806     ac_optarg=$2
16807     ac_shift=shift
16808     ;;
16809   esac
16810
16811   case $ac_option in
16812   # Handling of the options.
16813   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
16814     ac_cs_recheck=: ;;
16815   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
16816     $as_echo "$ac_cs_version"; exit ;;
16817   --config | --confi | --conf | --con | --co | --c )
16818     $as_echo "$ac_cs_config"; exit ;;
16819   --debug | --debu | --deb | --de | --d | -d )
16820     debug=: ;;
16821   --file | --fil | --fi | --f )
16822     $ac_shift
16823     case $ac_optarg in
16824     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
16825     '') as_fn_error $? "missing file argument" ;;
16826     esac
16827     as_fn_append CONFIG_FILES " '$ac_optarg'"
16828     ac_need_defaults=false;;
16829   --header | --heade | --head | --hea )
16830     $ac_shift
16831     case $ac_optarg in
16832     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
16833     esac
16834     as_fn_append CONFIG_HEADERS " '$ac_optarg'"
16835     ac_need_defaults=false;;
16836   --he | --h)
16837     # Conflict between --help and --header
16838     as_fn_error $? "ambiguous option: \`$1'
16839 Try \`$0 --help' for more information.";;
16840   --help | --hel | -h )
16841     $as_echo "$ac_cs_usage"; exit ;;
16842   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
16843   | -silent | --silent | --silen | --sile | --sil | --si | --s)
16844     ac_cs_silent=: ;;
16845
16846   # This is an error.
16847   -*) as_fn_error $? "unrecognized option: \`$1'
16848 Try \`$0 --help' for more information." ;;
16849
16850   *) as_fn_append ac_config_targets " $1"
16851      ac_need_defaults=false ;;
16852
16853   esac
16854   shift
16855 done
16856
16857 ac_configure_extra_args=
16858
16859 if $ac_cs_silent; then
16860   exec 6>/dev/null
16861   ac_configure_extra_args="$ac_configure_extra_args --silent"
16862 fi
16863
16864 _ACEOF
16865 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16866 if \$ac_cs_recheck; then
16867   set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
16868   shift
16869   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
16870   CONFIG_SHELL='$SHELL'
16871   export CONFIG_SHELL
16872   exec "\$@"
16873 fi
16874
16875 _ACEOF
16876 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16877 exec 5>>config.log
16878 {
16879   echo
16880   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
16881 ## Running $as_me. ##
16882 _ASBOX
16883   $as_echo "$ac_log"
16884 } >&5
16885
16886 _ACEOF
16887 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16888 _ACEOF
16889
16890 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
16891
16892 # Handling of arguments.
16893 for ac_config_target in $ac_config_targets
16894 do
16895   case $ac_config_target in
16896     "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
16897     "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
16898     "buildpkg.sh") CONFIG_FILES="$CONFIG_FILES buildpkg.sh" ;;
16899     "opensshd.init") CONFIG_FILES="$CONFIG_FILES opensshd.init" ;;
16900     "openssh.xml") CONFIG_FILES="$CONFIG_FILES openssh.xml" ;;
16901     "openbsd-compat/Makefile") CONFIG_FILES="$CONFIG_FILES openbsd-compat/Makefile" ;;
16902     "openbsd-compat/regress/Makefile") CONFIG_FILES="$CONFIG_FILES openbsd-compat/regress/Makefile" ;;
16903     "survey.sh") CONFIG_FILES="$CONFIG_FILES survey.sh" ;;
16904
16905   *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5 ;;
16906   esac
16907 done
16908
16909
16910 # If the user did not use the arguments to specify the items to instantiate,
16911 # then the envvar interface is used.  Set only those that are not.
16912 # We use the long form for the default assignment because of an extremely
16913 # bizarre bug on SunOS 4.1.3.
16914 if $ac_need_defaults; then
16915   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
16916   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
16917 fi
16918
16919 # Have a temporary directory for convenience.  Make it in the build tree
16920 # simply because there is no reason against having it here, and in addition,
16921 # creating and moving files from /tmp can sometimes cause problems.
16922 # Hook for its removal unless debugging.
16923 # Note that there is a small window in which the directory will not be cleaned:
16924 # after its creation but before its name has been assigned to `$tmp'.
16925 $debug ||
16926 {
16927   tmp=
16928   trap 'exit_status=$?
16929   { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
16930 ' 0
16931   trap 'as_fn_exit 1' 1 2 13 15
16932 }
16933 # Create a (secure) tmp directory for tmp files.
16934
16935 {
16936   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
16937   test -n "$tmp" && test -d "$tmp"
16938 }  ||
16939 {
16940   tmp=./conf$$-$RANDOM
16941   (umask 077 && mkdir "$tmp")
16942 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5
16943
16944 # Set up the scripts for CONFIG_FILES section.
16945 # No need to generate them if there are no CONFIG_FILES.
16946 # This happens for instance with `./config.status config.h'.
16947 if test -n "$CONFIG_FILES"; then
16948
16949
16950 ac_cr=`echo X | tr X '\015'`
16951 # On cygwin, bash can eat \r inside `` if the user requested igncr.
16952 # But we know of no other shell where ac_cr would be empty at this
16953 # point, so we can use a bashism as a fallback.
16954 if test "x$ac_cr" = x; then
16955   eval ac_cr=\$\'\\r\'
16956 fi
16957 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
16958 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
16959   ac_cs_awk_cr='\\r'
16960 else
16961   ac_cs_awk_cr=$ac_cr
16962 fi
16963
16964 echo 'BEGIN {' >"$tmp/subs1.awk" &&
16965 _ACEOF
16966
16967
16968 {
16969   echo "cat >conf$$subs.awk <<_ACEOF" &&
16970   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
16971   echo "_ACEOF"
16972 } >conf$$subs.sh ||
16973   as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
16974 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'`
16975 ac_delim='%!_!# '
16976 for ac_last_try in false false false false false :; do
16977   . ./conf$$subs.sh ||
16978     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
16979
16980   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
16981   if test $ac_delim_n = $ac_delim_num; then
16982     break
16983   elif $ac_last_try; then
16984     as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5
16985   else
16986     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
16987   fi
16988 done
16989 rm -f conf$$subs.sh
16990
16991 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
16992 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
16993 _ACEOF
16994 sed -n '
16995 h
16996 s/^/S["/; s/!.*/"]=/
16997 p
16998 g
16999 s/^[^!]*!//
17000 :repl
17001 t repl
17002 s/'"$ac_delim"'$//
17003 t delim
17004 :nl
17005 h
17006 s/\(.\{148\}\)..*/\1/
17007 t more1
17008 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
17009 p
17010 n
17011 b repl
17012 :more1
17013 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
17014 p
17015 g
17016 s/.\{148\}//
17017 t nl
17018 :delim
17019 h
17020 s/\(.\{148\}\)..*/\1/
17021 t more2
17022 s/["\\]/\\&/g; s/^/"/; s/$/"/
17023 p
17024 b
17025 :more2
17026 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
17027 p
17028 g
17029 s/.\{148\}//
17030 t delim
17031 ' <conf$$subs.awk | sed '
17032 /^[^""]/{
17033   N
17034   s/\n//
17035 }
17036 ' >>$CONFIG_STATUS || ac_write_fail=1
17037 rm -f conf$$subs.awk
17038 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
17039 _ACAWK
17040 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
17041   for (key in S) S_is_set[key] = 1
17042   FS = "\a"
17043
17044 }
17045 {
17046   line = $ 0
17047   nfields = split(line, field, "@")
17048   substed = 0
17049   len = length(field[1])
17050   for (i = 2; i < nfields; i++) {
17051     key = field[i]
17052     keylen = length(key)
17053     if (S_is_set[key]) {
17054       value = S[key]
17055       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
17056       len += length(value) + length(field[++i])
17057       substed = 1
17058     } else
17059       len += 1 + keylen
17060   }
17061
17062   print line
17063 }
17064
17065 _ACAWK
17066 _ACEOF
17067 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
17068 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
17069   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
17070 else
17071   cat
17072 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
17073   || as_fn_error $? "could not setup config files machinery" "$LINENO" 5
17074 _ACEOF
17075
17076 # VPATH may cause trouble with some makes, so we remove sole $(srcdir),
17077 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and
17078 # trailing colons and then remove the whole line if VPATH becomes empty
17079 # (actually we leave an empty line to preserve line numbers).
17080 if test "x$srcdir" = x.; then
17081   ac_vpsub='/^[  ]*VPATH[        ]*=[    ]*/{
17082 h
17083 s///
17084 s/^/:/
17085 s/[      ]*$/:/
17086 s/:\$(srcdir):/:/g
17087 s/:\${srcdir}:/:/g
17088 s/:@srcdir@:/:/g
17089 s/^:*//
17090 s/:*$//
17091 x
17092 s/\(=[   ]*\).*/\1/
17093 G
17094 s/\n//
17095 s/^[^=]*=[       ]*$//
17096 }'
17097 fi
17098
17099 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
17100 fi # test -n "$CONFIG_FILES"
17101
17102 # Set up the scripts for CONFIG_HEADERS section.
17103 # No need to generate them if there are no CONFIG_HEADERS.
17104 # This happens for instance with `./config.status Makefile'.
17105 if test -n "$CONFIG_HEADERS"; then
17106 cat >"$tmp/defines.awk" <<\_ACAWK ||
17107 BEGIN {
17108 _ACEOF
17109
17110 # Transform confdefs.h into an awk script `defines.awk', embedded as
17111 # here-document in config.status, that substitutes the proper values into
17112 # config.h.in to produce config.h.
17113
17114 # Create a delimiter string that does not exist in confdefs.h, to ease
17115 # handling of long lines.
17116 ac_delim='%!_!# '
17117 for ac_last_try in false false :; do
17118   ac_t=`sed -n "/$ac_delim/p" confdefs.h`
17119   if test -z "$ac_t"; then
17120     break
17121   elif $ac_last_try; then
17122     as_fn_error $? "could not make $CONFIG_HEADERS" "$LINENO" 5
17123   else
17124     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
17125   fi
17126 done
17127
17128 # For the awk script, D is an array of macro values keyed by name,
17129 # likewise P contains macro parameters if any.  Preserve backslash
17130 # newline sequences.
17131
17132 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
17133 sed -n '
17134 s/.\{148\}/&'"$ac_delim"'/g
17135 t rset
17136 :rset
17137 s/^[     ]*#[    ]*define[       ][      ]*/ /
17138 t def
17139 d
17140 :def
17141 s/\\$//
17142 t bsnl
17143 s/["\\]/\\&/g
17144 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
17145 D["\1"]=" \3"/p
17146 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
17147 d
17148 :bsnl
17149 s/["\\]/\\&/g
17150 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
17151 D["\1"]=" \3\\\\\\n"\\/p
17152 t cont
17153 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
17154 t cont
17155 d
17156 :cont
17157 n
17158 s/.\{148\}/&'"$ac_delim"'/g
17159 t clear
17160 :clear
17161 s/\\$//
17162 t bsnlc
17163 s/["\\]/\\&/g; s/^/"/; s/$/"/p
17164 d
17165 :bsnlc
17166 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
17167 b cont
17168 ' <confdefs.h | sed '
17169 s/'"$ac_delim"'/"\\\
17170 "/g' >>$CONFIG_STATUS || ac_write_fail=1
17171
17172 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
17173   for (key in D) D_is_set[key] = 1
17174   FS = "\a"
17175 }
17176 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
17177   line = \$ 0
17178   split(line, arg, " ")
17179   if (arg[1] == "#") {
17180     defundef = arg[2]
17181     mac1 = arg[3]
17182   } else {
17183     defundef = substr(arg[1], 2)
17184     mac1 = arg[2]
17185   }
17186   split(mac1, mac2, "(") #)
17187   macro = mac2[1]
17188   prefix = substr(line, 1, index(line, defundef) - 1)
17189   if (D_is_set[macro]) {
17190     # Preserve the white space surrounding the "#".
17191     print prefix "define", macro P[macro] D[macro]
17192     next
17193   } else {
17194     # Replace #undef with comments.  This is necessary, for example,
17195     # in the case of _POSIX_SOURCE, which is predefined and required
17196     # on some systems where configure will not decide to define it.
17197     if (defundef == "undef") {
17198       print "/*", prefix defundef, macro, "*/"
17199       next
17200     }
17201   }
17202 }
17203 { print }
17204 _ACAWK
17205 _ACEOF
17206 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
17207   as_fn_error $? "could not setup config headers machinery" "$LINENO" 5
17208 fi # test -n "$CONFIG_HEADERS"
17209
17210
17211 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS    "
17212 shift
17213 for ac_tag
17214 do
17215   case $ac_tag in
17216   :[FHLC]) ac_mode=$ac_tag; continue;;
17217   esac
17218   case $ac_mode$ac_tag in
17219   :[FHL]*:*);;
17220   :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5 ;;
17221   :[FH]-) ac_tag=-:-;;
17222   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
17223   esac
17224   ac_save_IFS=$IFS
17225   IFS=:
17226   set x $ac_tag
17227   IFS=$ac_save_IFS
17228   shift
17229   ac_file=$1
17230   shift
17231
17232   case $ac_mode in
17233   :L) ac_source=$1;;
17234   :[FH])
17235     ac_file_inputs=
17236     for ac_f
17237     do
17238       case $ac_f in
17239       -) ac_f="$tmp/stdin";;
17240       *) # Look for the file first in the build tree, then in the source tree
17241          # (if the path is not absolute).  The absolute path cannot be DOS-style,
17242          # because $ac_f cannot contain `:'.
17243          test -f "$ac_f" ||
17244            case $ac_f in
17245            [\\/$]*) false;;
17246            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
17247            esac ||
17248            as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5 ;;
17249       esac
17250       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
17251       as_fn_append ac_file_inputs " '$ac_f'"
17252     done
17253
17254     # Let's still pretend it is `configure' which instantiates (i.e., don't
17255     # use $as_me), people would be surprised to read:
17256     #    /* config.h.  Generated by config.status.  */
17257     configure_input='Generated from '`
17258           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
17259         `' by configure.'
17260     if test x"$ac_file" != x-; then
17261       configure_input="$ac_file.  $configure_input"
17262       { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5
17263 $as_echo "$as_me: creating $ac_file" >&6;}
17264     fi
17265     # Neutralize special characters interpreted by sed in replacement strings.
17266     case $configure_input in #(
17267     *\&* | *\|* | *\\* )
17268        ac_sed_conf_input=`$as_echo "$configure_input" |
17269        sed 's/[\\\\&|]/\\\\&/g'`;; #(
17270     *) ac_sed_conf_input=$configure_input;;
17271     esac
17272
17273     case $ac_tag in
17274     *:-:* | *:-) cat >"$tmp/stdin" \
17275       || as_fn_error $? "could not create $ac_file" "$LINENO" 5  ;;
17276     esac
17277     ;;
17278   esac
17279
17280   ac_dir=`$as_dirname -- "$ac_file" ||
17281 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
17282          X"$ac_file" : 'X\(//\)[^/]' \| \
17283          X"$ac_file" : 'X\(//\)$' \| \
17284          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
17285 $as_echo X"$ac_file" |
17286     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
17287             s//\1/
17288             q
17289           }
17290           /^X\(\/\/\)[^/].*/{
17291             s//\1/
17292             q
17293           }
17294           /^X\(\/\/\)$/{
17295             s//\1/
17296             q
17297           }
17298           /^X\(\/\).*/{
17299             s//\1/
17300             q
17301           }
17302           s/.*/./; q'`
17303   as_dir="$ac_dir"; as_fn_mkdir_p
17304   ac_builddir=.
17305
17306 case "$ac_dir" in
17307 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
17308 *)
17309   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
17310   # A ".." for each directory in $ac_dir_suffix.
17311   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
17312   case $ac_top_builddir_sub in
17313   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
17314   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
17315   esac ;;
17316 esac
17317 ac_abs_top_builddir=$ac_pwd
17318 ac_abs_builddir=$ac_pwd$ac_dir_suffix
17319 # for backward compatibility:
17320 ac_top_builddir=$ac_top_build_prefix
17321
17322 case $srcdir in
17323   .)  # We are building in place.
17324     ac_srcdir=.
17325     ac_top_srcdir=$ac_top_builddir_sub
17326     ac_abs_top_srcdir=$ac_pwd ;;
17327   [\\/]* | ?:[\\/]* )  # Absolute name.
17328     ac_srcdir=$srcdir$ac_dir_suffix;
17329     ac_top_srcdir=$srcdir
17330     ac_abs_top_srcdir=$srcdir ;;
17331   *) # Relative name.
17332     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
17333     ac_top_srcdir=$ac_top_build_prefix$srcdir
17334     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
17335 esac
17336 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
17337
17338
17339   case $ac_mode in
17340   :F)
17341   #
17342   # CONFIG_FILE
17343   #
17344
17345   case $INSTALL in
17346   [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
17347   *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
17348   esac
17349 _ACEOF
17350
17351 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
17352 # If the template does not know about datarootdir, expand it.
17353 # FIXME: This hack should be removed a few years after 2.60.
17354 ac_datarootdir_hack=; ac_datarootdir_seen=
17355 ac_sed_dataroot='
17356 /datarootdir/ {
17357   p
17358   q
17359 }
17360 /@datadir@/p
17361 /@docdir@/p
17362 /@infodir@/p
17363 /@localedir@/p
17364 /@mandir@/p'
17365 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
17366 *datarootdir*) ac_datarootdir_seen=yes;;
17367 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
17368   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
17369 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
17370 _ACEOF
17371 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
17372   ac_datarootdir_hack='
17373   s&@datadir@&$datadir&g
17374   s&@docdir@&$docdir&g
17375   s&@infodir@&$infodir&g
17376   s&@localedir@&$localedir&g
17377   s&@mandir@&$mandir&g
17378   s&\\\${datarootdir}&$datarootdir&g' ;;
17379 esac
17380 _ACEOF
17381
17382 # Neutralize VPATH when `$srcdir' = `.'.
17383 # Shell code in configure.ac might set extrasub.
17384 # FIXME: do we really want to maintain this feature?
17385 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
17386 ac_sed_extra="$ac_vpsub
17387 $extrasub
17388 _ACEOF
17389 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
17390 :t
17391 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
17392 s|@configure_input@|$ac_sed_conf_input|;t t
17393 s&@top_builddir@&$ac_top_builddir_sub&;t t
17394 s&@top_build_prefix@&$ac_top_build_prefix&;t t
17395 s&@srcdir@&$ac_srcdir&;t t
17396 s&@abs_srcdir@&$ac_abs_srcdir&;t t
17397 s&@top_srcdir@&$ac_top_srcdir&;t t
17398 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
17399 s&@builddir@&$ac_builddir&;t t
17400 s&@abs_builddir@&$ac_abs_builddir&;t t
17401 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
17402 s&@INSTALL@&$ac_INSTALL&;t t
17403 $ac_datarootdir_hack
17404 "
17405 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
17406   || as_fn_error $? "could not create $ac_file" "$LINENO" 5
17407
17408 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
17409   { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
17410   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
17411   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir'
17412 which seems to be undefined.  Please make sure it is defined" >&5
17413 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
17414 which seems to be undefined.  Please make sure it is defined" >&2;}
17415
17416   rm -f "$tmp/stdin"
17417   case $ac_file in
17418   -) cat "$tmp/out" && rm -f "$tmp/out";;
17419   *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
17420   esac \
17421   || as_fn_error $? "could not create $ac_file" "$LINENO" 5
17422  ;;
17423   :H)
17424   #
17425   # CONFIG_HEADER
17426   #
17427   if test x"$ac_file" != x-; then
17428     {
17429       $as_echo "/* $configure_input  */" \
17430       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
17431     } >"$tmp/config.h" \
17432       || as_fn_error $? "could not create $ac_file" "$LINENO" 5
17433     if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
17434       { $as_echo "$as_me:${as_lineno-$LINENO}: $ac_file is unchanged" >&5
17435 $as_echo "$as_me: $ac_file is unchanged" >&6;}
17436     else
17437       rm -f "$ac_file"
17438       mv "$tmp/config.h" "$ac_file" \
17439         || as_fn_error $? "could not create $ac_file" "$LINENO" 5
17440     fi
17441   else
17442     $as_echo "/* $configure_input  */" \
17443       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
17444       || as_fn_error $? "could not create -" "$LINENO" 5
17445   fi
17446  ;;
17447
17448
17449   esac
17450
17451 done # for ac_tag
17452
17453
17454 as_fn_exit 0
17455 _ACEOF
17456 ac_clean_files=$ac_clean_files_save
17457
17458 test $ac_write_fail = 0 ||
17459   as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5
17460
17461
17462 # configure is writing to config.log, and then calls config.status.
17463 # config.status does its own redirection, appending to config.log.
17464 # Unfortunately, on DOS this fails, as config.log is still kept open
17465 # by configure, so config.status won't be able to write to it; its
17466 # output is simply discarded.  So we exec the FD to /dev/null,
17467 # effectively closing config.log, so it can be properly (re)opened and
17468 # appended to by config.status.  When coming back to configure, we
17469 # need to make the FD available again.
17470 if test "$no_create" != yes; then
17471   ac_cs_success=:
17472   ac_config_status_args=
17473   test "$silent" = yes &&
17474     ac_config_status_args="$ac_config_status_args --quiet"
17475   exec 5>/dev/null
17476   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
17477   exec 5>>config.log
17478   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
17479   # would make configure fail if this is the last instruction.
17480   $ac_cs_success || as_fn_exit 1
17481 fi
17482 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
17483   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
17484 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
17485 fi
17486
17487
17488 # Print summary of options
17489
17490 # Someone please show me a better way :)
17491 A=`eval echo ${prefix}` ; A=`eval echo ${A}`
17492 B=`eval echo ${bindir}` ; B=`eval echo ${B}`
17493 C=`eval echo ${sbindir}` ; C=`eval echo ${C}`
17494 D=`eval echo ${sysconfdir}` ; D=`eval echo ${D}`
17495 E=`eval echo ${libexecdir}/ssh-askpass` ; E=`eval echo ${E}`
17496 F=`eval echo ${mandir}/${mansubdir}X` ; F=`eval echo ${F}`
17497 G=`eval echo ${piddir}` ; G=`eval echo ${G}`
17498 H=`eval echo ${PRIVSEP_PATH}` ; H=`eval echo ${H}`
17499 I=`eval echo ${user_path}` ; I=`eval echo ${I}`
17500 J=`eval echo ${superuser_path}` ; J=`eval echo ${J}`
17501
17502 echo ""
17503 echo "OpenSSH has been configured with the following options:"
17504 echo "                     User binaries: $B"
17505 echo "                   System binaries: $C"
17506 echo "               Configuration files: $D"
17507 echo "                   Askpass program: $E"
17508 echo "                      Manual pages: $F"
17509 echo "                          PID file: $G"
17510 echo "  Privilege separation chroot path: $H"
17511 if test "x$external_path_file" = "x/etc/login.conf" ; then
17512 echo "   At runtime, sshd will use the path defined in $external_path_file"
17513 echo "   Make sure the path to scp is present, otherwise scp will not work"
17514 else
17515 echo "            sshd default user PATH: $I"
17516         if test ! -z "$external_path_file"; then
17517 echo "   (If PATH is set in $external_path_file it will be used instead. If"
17518 echo "   used, ensure the path to scp is present, otherwise scp will not work.)"
17519         fi
17520 fi
17521 if test ! -z "$superuser_path" ; then
17522 echo "          sshd superuser user PATH: $J"
17523 fi
17524 echo "                    Manpage format: $MANTYPE"
17525 echo "                       PAM support: $PAM_MSG"
17526 echo "                   OSF SIA support: $SIA_MSG"
17527 echo "                 KerberosV support: $KRB5_MSG"
17528 echo "                   SELinux support: $SELINUX_MSG"
17529 echo "                 Smartcard support: $SCARD_MSG"
17530 echo "                     S/KEY support: $SKEY_MSG"
17531 echo "              TCP Wrappers support: $TCPW_MSG"
17532 echo "              MD5 password support: $MD5_MSG"
17533 echo "                   libedit support: $LIBEDIT_MSG"
17534 echo "  Solaris process contract support: $SPC_MSG"
17535 echo "           Solaris project support: $SP_MSG"
17536 echo "       IP address in \$DISPLAY hack: $DISPLAY_HACK_MSG"
17537 echo "           Translate v4 in v6 hack: $IPV4_IN6_HACK_MSG"
17538 echo "                  BSD Auth support: $BSD_AUTH_MSG"
17539 echo "              Random number source: $RAND_MSG"
17540 echo "             Privsep sandbox style: $SANDBOX_STYLE"
17541
17542 echo ""
17543
17544 echo "              Host: ${host}"
17545 echo "          Compiler: ${CC}"
17546 echo "    Compiler flags: ${CFLAGS}"
17547 echo "Preprocessor flags: ${CPPFLAGS}"
17548 echo "      Linker flags: ${LDFLAGS}"
17549 echo "         Libraries: ${LIBS}"
17550 if test ! -z "${SSHDLIBS}"; then
17551 echo "         +for sshd: ${SSHDLIBS}"
17552 fi
17553 if test ! -z "${SSHLIBS}"; then
17554 echo "          +for ssh: ${SSHLIBS}"
17555 fi
17556
17557 echo ""
17558
17559 if test "x$MAKE_PACKAGE_SUPPORTED" = "xyes" ; then
17560         echo "SVR4 style packages are supported with \"make package\""
17561         echo ""
17562 fi
17563
17564 if test "x$PAM_MSG" = "xyes" ; then
17565         echo "PAM is enabled. You may need to install a PAM control file "
17566         echo "for sshd, otherwise password authentication may fail. "
17567         echo "Example PAM control files can be found in the contrib/ "
17568         echo "subdirectory"
17569         echo ""
17570 fi
17571
17572 if test ! -z "$NO_PEERCHECK" ; then
17573         echo "WARNING: the operating system that you are using does not"
17574         echo "appear to support getpeereid(), getpeerucred() or the"
17575         echo "SO_PEERCRED getsockopt() option. These facilities are used to"
17576         echo "enforce security checks to prevent unauthorised connections to"
17577         echo "ssh-agent. Their absence increases the risk that a malicious"
17578         echo "user can connect to your agent."
17579         echo ""
17580 fi
17581
17582 if test "$AUDIT_MODULE" = "bsm" ; then
17583         echo "WARNING: BSM audit support is currently considered EXPERIMENTAL."
17584         echo "See the Solaris section in README.platform for details."
17585 fi