1#! /bin/sh
2# From configure.ac Revision: 1.583 .
3# Guess values for system-dependent variables and create Makefiles.
4# Generated by GNU Autoconf 2.61 for OpenSSH Portable.
5#
6# Report bugs to <openssh-unix-dev@mindrot.org>.
7#
8# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
9# 2002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
10# This configure script is free software; the Free Software Foundation
11# gives unlimited permission to copy, distribute and modify it.
12## --------------------- ##
13## M4sh Initialization.  ##
14## --------------------- ##
15
16# Be more Bourne compatible
17DUALCASE=1; export DUALCASE # for MKS sh
18if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
19  emulate sh
20  NULLCMD=:
21  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
22  # is contrary to our usage.  Disable this feature.
23  alias -g '${1+"$@"}'='"$@"'
24  setopt NO_GLOB_SUBST
25else
26  case `(set -o) 2>/dev/null` in
27  *posix*) set -o posix ;;
28esac
29
30fi
31
32
33
34
35# PATH needs CR
36# Avoid depending upon Character Ranges.
37as_cr_letters='abcdefghijklmnopqrstuvwxyz'
38as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
39as_cr_Letters=$as_cr_letters$as_cr_LETTERS
40as_cr_digits='0123456789'
41as_cr_alnum=$as_cr_Letters$as_cr_digits
42
43# The user is always right.
44if test "${PATH_SEPARATOR+set}" != set; then
45  echo "#! /bin/sh" >conf$$.sh
46  echo  "exit 0"   >>conf$$.sh
47  chmod +x conf$$.sh
48  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
49    PATH_SEPARATOR=';'
50  else
51    PATH_SEPARATOR=:
52  fi
53  rm -f conf$$.sh
54fi
55
56# Support unset when possible.
57if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
58  as_unset=unset
59else
60  as_unset=false
61fi
62
63
64# IFS
65# We need space, tab and new line, in precisely that order.  Quoting is
66# there to prevent editors from complaining about space-tab.
67# (If _AS_PATH_WALK were called with IFS unset, it would disable word
68# splitting by setting IFS to empty value.)
69as_nl='
70'
71IFS=" ""	$as_nl"
72
73# Find who we are.  Look in the path if we contain no directory separator.
74case $0 in
75  *[\\/]* ) as_myself=$0 ;;
76  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
77for as_dir in $PATH
78do
79  IFS=$as_save_IFS
80  test -z "$as_dir" && as_dir=.
81  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
82done
83IFS=$as_save_IFS
84
85     ;;
86esac
87# We did not find ourselves, most probably we were run as `sh COMMAND'
88# in which case we are not to be found in the path.
89if test "x$as_myself" = x; then
90  as_myself=$0
91fi
92if test ! -f "$as_myself"; then
93  echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
94  { (exit 1); exit 1; }
95fi
96
97# Work around bugs in pre-3.0 UWIN ksh.
98for as_var in ENV MAIL MAILPATH
99do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
100done
101PS1='$ '
102PS2='> '
103PS4='+ '
104
105# NLS nuisances.
106for as_var in \
107  LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
108  LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
109  LC_TELEPHONE LC_TIME
110do
111  if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
112    eval $as_var=C; export $as_var
113  else
114    ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
115  fi
116done
117
118# Required to use basename.
119if expr a : '\(a\)' >/dev/null 2>&1 &&
120   test "X`expr 00001 : '.*\(...\)'`" = X001; then
121  as_expr=expr
122else
123  as_expr=false
124fi
125
126if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
127  as_basename=basename
128else
129  as_basename=false
130fi
131
132
133# Name of the executable.
134as_me=`$as_basename -- "$0" ||
135$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
136	 X"$0" : 'X\(//\)$' \| \
137	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
138echo X/"$0" |
139    sed '/^.*\/\([^/][^/]*\)\/*$/{
140	    s//\1/
141	    q
142	  }
143	  /^X\/\(\/\/\)$/{
144	    s//\1/
145	    q
146	  }
147	  /^X\/\(\/\).*/{
148	    s//\1/
149	    q
150	  }
151	  s/.*/./; q'`
152
153# CDPATH.
154$as_unset CDPATH
155
156
157if test "x$CONFIG_SHELL" = x; then
158  if (eval ":") 2>/dev/null; then
159  as_have_required=yes
160else
161  as_have_required=no
162fi
163
164  if test $as_have_required = yes && 	 (eval ":
165(as_func_return () {
166  (exit \$1)
167}
168as_func_success () {
169  as_func_return 0
170}
171as_func_failure () {
172  as_func_return 1
173}
174as_func_ret_success () {
175  return 0
176}
177as_func_ret_failure () {
178  return 1
179}
180
181exitcode=0
182if as_func_success; then
183  :
184else
185  exitcode=1
186  echo as_func_success failed.
187fi
188
189if as_func_failure; then
190  exitcode=1
191  echo as_func_failure succeeded.
192fi
193
194if as_func_ret_success; then
195  :
196else
197  exitcode=1
198  echo as_func_ret_success failed.
199fi
200
201if as_func_ret_failure; then
202  exitcode=1
203  echo as_func_ret_failure succeeded.
204fi
205
206if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
207  :
208else
209  exitcode=1
210  echo positional parameters were not saved.
211fi
212
213test \$exitcode = 0) || { (exit 1); exit 1; }
214
215(
216  as_lineno_1=\$LINENO
217  as_lineno_2=\$LINENO
218  test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
219  test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
220") 2> /dev/null; then
221  :
222else
223  as_candidate_shells=
224    as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
225for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
226do
227  IFS=$as_save_IFS
228  test -z "$as_dir" && as_dir=.
229  case $as_dir in
230	 /*)
231	   for as_base in sh bash ksh sh5; do
232	     as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
233	   done;;
234       esac
235done
236IFS=$as_save_IFS
237
238
239      for as_shell in $as_candidate_shells $SHELL; do
240	 # Try only shells that exist, to save several forks.
241	 if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
242		{ ("$as_shell") 2> /dev/null <<\_ASEOF
243if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
244  emulate sh
245  NULLCMD=:
246  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
247  # is contrary to our usage.  Disable this feature.
248  alias -g '${1+"$@"}'='"$@"'
249  setopt NO_GLOB_SUBST
250else
251  case `(set -o) 2>/dev/null` in
252  *posix*) set -o posix ;;
253esac
254
255fi
256
257
258:
259_ASEOF
260}; then
261  CONFIG_SHELL=$as_shell
262	       as_have_required=yes
263	       if { "$as_shell" 2> /dev/null <<\_ASEOF
264if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
265  emulate sh
266  NULLCMD=:
267  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
268  # is contrary to our usage.  Disable this feature.
269  alias -g '${1+"$@"}'='"$@"'
270  setopt NO_GLOB_SUBST
271else
272  case `(set -o) 2>/dev/null` in
273  *posix*) set -o posix ;;
274esac
275
276fi
277
278
279:
280(as_func_return () {
281  (exit $1)
282}
283as_func_success () {
284  as_func_return 0
285}
286as_func_failure () {
287  as_func_return 1
288}
289as_func_ret_success () {
290  return 0
291}
292as_func_ret_failure () {
293  return 1
294}
295
296exitcode=0
297if as_func_success; then
298  :
299else
300  exitcode=1
301  echo as_func_success failed.
302fi
303
304if as_func_failure; then
305  exitcode=1
306  echo as_func_failure succeeded.
307fi
308
309if as_func_ret_success; then
310  :
311else
312  exitcode=1
313  echo as_func_ret_success failed.
314fi
315
316if as_func_ret_failure; then
317  exitcode=1
318  echo as_func_ret_failure succeeded.
319fi
320
321if ( set x; as_func_ret_success y && test x = "$1" ); then
322  :
323else
324  exitcode=1
325  echo positional parameters were not saved.
326fi
327
328test $exitcode = 0) || { (exit 1); exit 1; }
329
330(
331  as_lineno_1=$LINENO
332  as_lineno_2=$LINENO
333  test "x$as_lineno_1" != "x$as_lineno_2" &&
334  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }
335
336_ASEOF
337}; then
338  break
339fi
340
341fi
342
343      done
344
345      if test "x$CONFIG_SHELL" != x; then
346  for as_var in BASH_ENV ENV
347        do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
348        done
349        export CONFIG_SHELL
350        exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
351fi
352
353
354    if test $as_have_required = no; then
355  echo This script requires a shell more modern than all the
356      echo shells that I found on your system.  Please install a
357      echo modern shell, or manually run the script under such a
358      echo shell if you do have one.
359      { (exit 1); exit 1; }
360fi
361
362
363fi
364
365fi
366
367
368
369(eval "as_func_return () {
370  (exit \$1)
371}
372as_func_success () {
373  as_func_return 0
374}
375as_func_failure () {
376  as_func_return 1
377}
378as_func_ret_success () {
379  return 0
380}
381as_func_ret_failure () {
382  return 1
383}
384
385exitcode=0
386if as_func_success; then
387  :
388else
389  exitcode=1
390  echo as_func_success failed.
391fi
392
393if as_func_failure; then
394  exitcode=1
395  echo as_func_failure succeeded.
396fi
397
398if as_func_ret_success; then
399  :
400else
401  exitcode=1
402  echo as_func_ret_success failed.
403fi
404
405if as_func_ret_failure; then
406  exitcode=1
407  echo as_func_ret_failure succeeded.
408fi
409
410if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
411  :
412else
413  exitcode=1
414  echo positional parameters were not saved.
415fi
416
417test \$exitcode = 0") || {
418  echo No shell found that supports shell functions.
419  echo Please tell autoconf@gnu.org about your system,
420  echo including any error possibly output before this
421  echo message
422}
423
424
425
426  as_lineno_1=$LINENO
427  as_lineno_2=$LINENO
428  test "x$as_lineno_1" != "x$as_lineno_2" &&
429  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
430
431  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
432  # uniformly replaced by the line number.  The first 'sed' inserts a
433  # line-number line after each line using $LINENO; the second 'sed'
434  # does the real work.  The second script uses 'N' to pair each
435  # line-number line with the line containing $LINENO, and appends
436  # trailing '-' during substitution so that $LINENO is not a special
437  # case at line end.
438  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
439  # scripts with optimization help from Paolo Bonzini.  Blame Lee
440  # E. McMahon (1931-1989) for sed's syntax.  :-)
441  sed -n '
442    p
443    /[$]LINENO/=
444  ' <$as_myself |
445    sed '
446      s/[$]LINENO.*/&-/
447      t lineno
448      b
449      :lineno
450      N
451      :loop
452      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
453      t loop
454      s/-\n.*//
455    ' >$as_me.lineno &&
456  chmod +x "$as_me.lineno" ||
457    { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
458   { (exit 1); exit 1; }; }
459
460  # Don't try to exec as it changes $[0], causing all sort of problems
461  # (the dirname of $[0] is not the place where we might find the
462  # original and so on.  Autoconf is especially sensitive to this).
463  . "./$as_me.lineno"
464  # Exit status is that of the last command.
465  exit
466}
467
468
469if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
470  as_dirname=dirname
471else
472  as_dirname=false
473fi
474
475ECHO_C= ECHO_N= ECHO_T=
476case `echo -n x` in
477-n*)
478  case `echo 'x\c'` in
479  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
480  *)   ECHO_C='\c';;
481  esac;;
482*)
483  ECHO_N='-n';;
484esac
485
486if expr a : '\(a\)' >/dev/null 2>&1 &&
487   test "X`expr 00001 : '.*\(...\)'`" = X001; then
488  as_expr=expr
489else
490  as_expr=false
491fi
492
493rm -f conf$$ conf$$.exe conf$$.file
494if test -d conf$$.dir; then
495  rm -f conf$$.dir/conf$$.file
496else
497  rm -f conf$$.dir
498  mkdir conf$$.dir
499fi
500echo >conf$$.file
501if ln -s conf$$.file conf$$ 2>/dev/null; then
502  as_ln_s='ln -s'
503  # ... but there are two gotchas:
504  # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
505  # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
506  # In both cases, we have to default to `cp -p'.
507  ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
508    as_ln_s='cp -p'
509elif ln conf$$.file conf$$ 2>/dev/null; then
510  as_ln_s=ln
511else
512  as_ln_s='cp -p'
513fi
514rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
515rmdir conf$$.dir 2>/dev/null
516
517if mkdir -p . 2>/dev/null; then
518  as_mkdir_p=:
519else
520  test -d ./-p && rmdir ./-p
521  as_mkdir_p=false
522fi
523
524if test -x / >/dev/null 2>&1; then
525  as_test_x='test -x'
526else
527  if ls -dL / >/dev/null 2>&1; then
528    as_ls_L_option=L
529  else
530    as_ls_L_option=
531  fi
532  as_test_x='
533    eval sh -c '\''
534      if test -d "$1"; then
535        test -d "$1/.";
536      else
537	case $1 in
538        -*)set "./$1";;
539	esac;
540	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
541	???[sx]*):;;*)false;;esac;fi
542    '\'' sh
543  '
544fi
545as_executable_p=$as_test_x
546
547# Sed expression to map a string onto a valid CPP name.
548as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
549
550# Sed expression to map a string onto a valid variable name.
551as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
552
553
554
555exec 7<&0 </dev/null 6>&1
556
557# Name of the host.
558# hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
559# so uname gets run too.
560ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
561
562#
563# Initializations.
564#
565ac_default_prefix=/usr/local
566ac_clean_files=
567ac_config_libobj_dir=.
568LIBOBJS=
569cross_compiling=no
570subdirs=
571MFLAGS=
572MAKEFLAGS=
573SHELL=${CONFIG_SHELL-/bin/sh}
574
575# Identity of this package.
576PACKAGE_NAME='OpenSSH'
577PACKAGE_TARNAME='openssh'
578PACKAGE_VERSION='Portable'
579PACKAGE_STRING='OpenSSH Portable'
580PACKAGE_BUGREPORT='openssh-unix-dev@mindrot.org'
581
582ac_unique_file="ssh.c"
583# Factoring default headers for most tests.
584ac_includes_default="\
585#include <stdio.h>
586#ifdef HAVE_SYS_TYPES_H
587# include <sys/types.h>
588#endif
589#ifdef HAVE_SYS_STAT_H
590# include <sys/stat.h>
591#endif
592#ifdef STDC_HEADERS
593# include <stdlib.h>
594# include <stddef.h>
595#else
596# ifdef HAVE_STDLIB_H
597#  include <stdlib.h>
598# endif
599#endif
600#ifdef HAVE_STRING_H
601# if !defined STDC_HEADERS && defined HAVE_MEMORY_H
602#  include <memory.h>
603# endif
604# include <string.h>
605#endif
606#ifdef HAVE_STRINGS_H
607# include <strings.h>
608#endif
609#ifdef HAVE_INTTYPES_H
610# include <inttypes.h>
611#endif
612#ifdef HAVE_STDINT_H
613# include <stdint.h>
614#endif
615#ifdef HAVE_UNISTD_H
616# include <unistd.h>
617#endif"
618
619ac_subst_vars='SHELL
620PATH_SEPARATOR
621PACKAGE_NAME
622PACKAGE_TARNAME
623PACKAGE_VERSION
624PACKAGE_STRING
625PACKAGE_BUGREPORT
626exec_prefix
627prefix
628program_transform_name
629bindir
630sbindir
631libexecdir
632datarootdir
633datadir
634sysconfdir
635sharedstatedir
636localstatedir
637includedir
638oldincludedir
639docdir
640infodir
641htmldir
642dvidir
643pdfdir
644psdir
645libdir
646localedir
647mandir
648DEFS
649ECHO_C
650ECHO_N
651ECHO_T
652LIBS
653build_alias
654host_alias
655target_alias
656CC
657CFLAGS
658LDFLAGS
659CPPFLAGS
660ac_ct_CC
661EXEEXT
662OBJEXT
663build
664build_cpu
665build_vendor
666build_os
667host
668host_cpu
669host_vendor
670host_os
671CPP
672GREP
673EGREP
674AWK
675RANLIB
676INSTALL_PROGRAM
677INSTALL_SCRIPT
678INSTALL_DATA
679AR
680CAT
681KILL
682PERL
683SED
684ENT
685TEST_MINUS_S_SH
686SH
687GROFF
688NROFF
689MANDOC
690TEST_SHELL
691MANFMT
692PATH_GROUPADD_PROG
693PATH_USERADD_PROG
694MAKE_PACKAGE_SUPPORTED
695STARTUP_SCRIPT_SHELL
696LOGIN_PROGRAM_FALLBACK
697PATH_PASSWD_PROG
698LD
699PKGCONFIG
700LIBEDIT
701TEST_SSH_ECC
702COMMENT_OUT_ECC
703SSH_PRIVSEP_USER
704SSHLIBS
705SSHDLIBS
706KRB5CONF
707GSSLIBS
708K5LIBS
709PRIVSEP_PATH
710xauth_path
711STRIP_OPT
712XAUTH_PATH
713MANTYPE
714mansubdir
715user_path
716piddir
717TEST_SSH_IPV6
718TEST_MALLOC_OPTIONS
719UNSUPPORTED_ALGORITHMS
720LIBOBJS
721LTLIBOBJS'
722ac_subst_files=''
723      ac_precious_vars='build_alias
724host_alias
725target_alias
726CC
727CFLAGS
728LDFLAGS
729LIBS
730CPPFLAGS
731CPP'
732
733
734# Initialize some variables set by options.
735ac_init_help=
736ac_init_version=false
737# The variables have the same names as the options, with
738# dashes changed to underlines.
739cache_file=/dev/null
740exec_prefix=NONE
741no_create=
742no_recursion=
743prefix=NONE
744program_prefix=NONE
745program_suffix=NONE
746program_transform_name=s,x,x,
747silent=
748site=
749srcdir=
750verbose=
751x_includes=NONE
752x_libraries=NONE
753
754# Installation directory options.
755# These are left unexpanded so users can "make install exec_prefix=/foo"
756# and all the variables that are supposed to be based on exec_prefix
757# by default will actually change.
758# Use braces instead of parens because sh, perl, etc. also accept them.
759# (The list follows the same order as the GNU Coding Standards.)
760bindir='${exec_prefix}/bin'
761sbindir='${exec_prefix}/sbin'
762libexecdir='${exec_prefix}/libexec'
763datarootdir='${prefix}/share'
764datadir='${datarootdir}'
765sysconfdir='${prefix}/etc'
766sharedstatedir='${prefix}/com'
767localstatedir='${prefix}/var'
768includedir='${prefix}/include'
769oldincludedir='/usr/include'
770docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
771infodir='${datarootdir}/info'
772htmldir='${docdir}'
773dvidir='${docdir}'
774pdfdir='${docdir}'
775psdir='${docdir}'
776libdir='${exec_prefix}/lib'
777localedir='${datarootdir}/locale'
778mandir='${datarootdir}/man'
779
780ac_prev=
781ac_dashdash=
782for ac_option
783do
784  # If the previous option needs an argument, assign it.
785  if test -n "$ac_prev"; then
786    eval $ac_prev=\$ac_option
787    ac_prev=
788    continue
789  fi
790
791  case $ac_option in
792  *=*)	ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
793  *)	ac_optarg=yes ;;
794  esac
795
796  # Accept the important Cygnus configure options, so we can diagnose typos.
797
798  case $ac_dashdash$ac_option in
799  --)
800    ac_dashdash=yes ;;
801
802  -bindir | --bindir | --bindi | --bind | --bin | --bi)
803    ac_prev=bindir ;;
804  -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
805    bindir=$ac_optarg ;;
806
807  -build | --build | --buil | --bui | --bu)
808    ac_prev=build_alias ;;
809  -build=* | --build=* | --buil=* | --bui=* | --bu=*)
810    build_alias=$ac_optarg ;;
811
812  -cache-file | --cache-file | --cache-fil | --cache-fi \
813  | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
814    ac_prev=cache_file ;;
815  -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
816  | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
817    cache_file=$ac_optarg ;;
818
819  --config-cache | -C)
820    cache_file=config.cache ;;
821
822  -datadir | --datadir | --datadi | --datad)
823    ac_prev=datadir ;;
824  -datadir=* | --datadir=* | --datadi=* | --datad=*)
825    datadir=$ac_optarg ;;
826
827  -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
828  | --dataroo | --dataro | --datar)
829    ac_prev=datarootdir ;;
830  -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
831  | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
832    datarootdir=$ac_optarg ;;
833
834  -disable-* | --disable-*)
835    ac_feature=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
836    # Reject names that are not valid shell variable names.
837    expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
838      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
839   { (exit 1); exit 1; }; }
840    ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
841    eval enable_$ac_feature=no ;;
842
843  -docdir | --docdir | --docdi | --doc | --do)
844    ac_prev=docdir ;;
845  -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
846    docdir=$ac_optarg ;;
847
848  -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
849    ac_prev=dvidir ;;
850  -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
851    dvidir=$ac_optarg ;;
852
853  -enable-* | --enable-*)
854    ac_feature=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
855    # Reject names that are not valid shell variable names.
856    expr "x$ac_feature" : ".*[^-._$as_cr_alnum]" >/dev/null &&
857      { echo "$as_me: error: invalid feature name: $ac_feature" >&2
858   { (exit 1); exit 1; }; }
859    ac_feature=`echo $ac_feature | sed 's/[-.]/_/g'`
860    eval enable_$ac_feature=\$ac_optarg ;;
861
862  -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
863  | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
864  | --exec | --exe | --ex)
865    ac_prev=exec_prefix ;;
866  -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
867  | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
868  | --exec=* | --exe=* | --ex=*)
869    exec_prefix=$ac_optarg ;;
870
871  -gas | --gas | --ga | --g)
872    # Obsolete; use --with-gas.
873    with_gas=yes ;;
874
875  -help | --help | --hel | --he | -h)
876    ac_init_help=long ;;
877  -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
878    ac_init_help=recursive ;;
879  -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
880    ac_init_help=short ;;
881
882  -host | --host | --hos | --ho)
883    ac_prev=host_alias ;;
884  -host=* | --host=* | --hos=* | --ho=*)
885    host_alias=$ac_optarg ;;
886
887  -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
888    ac_prev=htmldir ;;
889  -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
890  | --ht=*)
891    htmldir=$ac_optarg ;;
892
893  -includedir | --includedir | --includedi | --included | --include \
894  | --includ | --inclu | --incl | --inc)
895    ac_prev=includedir ;;
896  -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
897  | --includ=* | --inclu=* | --incl=* | --inc=*)
898    includedir=$ac_optarg ;;
899
900  -infodir | --infodir | --infodi | --infod | --info | --inf)
901    ac_prev=infodir ;;
902  -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
903    infodir=$ac_optarg ;;
904
905  -libdir | --libdir | --libdi | --libd)
906    ac_prev=libdir ;;
907  -libdir=* | --libdir=* | --libdi=* | --libd=*)
908    libdir=$ac_optarg ;;
909
910  -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
911  | --libexe | --libex | --libe)
912    ac_prev=libexecdir ;;
913  -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
914  | --libexe=* | --libex=* | --libe=*)
915    libexecdir=$ac_optarg ;;
916
917  -localedir | --localedir | --localedi | --localed | --locale)
918    ac_prev=localedir ;;
919  -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
920    localedir=$ac_optarg ;;
921
922  -localstatedir | --localstatedir | --localstatedi | --localstated \
923  | --localstate | --localstat | --localsta | --localst | --locals)
924    ac_prev=localstatedir ;;
925  -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
926  | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
927    localstatedir=$ac_optarg ;;
928
929  -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
930    ac_prev=mandir ;;
931  -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
932    mandir=$ac_optarg ;;
933
934  -nfp | --nfp | --nf)
935    # Obsolete; use --without-fp.
936    with_fp=no ;;
937
938  -no-create | --no-create | --no-creat | --no-crea | --no-cre \
939  | --no-cr | --no-c | -n)
940    no_create=yes ;;
941
942  -no-recursion | --no-recursion | --no-recursio | --no-recursi \
943  | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
944    no_recursion=yes ;;
945
946  -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
947  | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
948  | --oldin | --oldi | --old | --ol | --o)
949    ac_prev=oldincludedir ;;
950  -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
951  | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
952  | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
953    oldincludedir=$ac_optarg ;;
954
955  -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
956    ac_prev=prefix ;;
957  -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
958    prefix=$ac_optarg ;;
959
960  -program-prefix | --program-prefix | --program-prefi | --program-pref \
961  | --program-pre | --program-pr | --program-p)
962    ac_prev=program_prefix ;;
963  -program-prefix=* | --program-prefix=* | --program-prefi=* \
964  | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
965    program_prefix=$ac_optarg ;;
966
967  -program-suffix | --program-suffix | --program-suffi | --program-suff \
968  | --program-suf | --program-su | --program-s)
969    ac_prev=program_suffix ;;
970  -program-suffix=* | --program-suffix=* | --program-suffi=* \
971  | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
972    program_suffix=$ac_optarg ;;
973
974  -program-transform-name | --program-transform-name \
975  | --program-transform-nam | --program-transform-na \
976  | --program-transform-n | --program-transform- \
977  | --program-transform | --program-transfor \
978  | --program-transfo | --program-transf \
979  | --program-trans | --program-tran \
980  | --progr-tra | --program-tr | --program-t)
981    ac_prev=program_transform_name ;;
982  -program-transform-name=* | --program-transform-name=* \
983  | --program-transform-nam=* | --program-transform-na=* \
984  | --program-transform-n=* | --program-transform-=* \
985  | --program-transform=* | --program-transfor=* \
986  | --program-transfo=* | --program-transf=* \
987  | --program-trans=* | --program-tran=* \
988  | --progr-tra=* | --program-tr=* | --program-t=*)
989    program_transform_name=$ac_optarg ;;
990
991  -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
992    ac_prev=pdfdir ;;
993  -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
994    pdfdir=$ac_optarg ;;
995
996  -psdir | --psdir | --psdi | --psd | --ps)
997    ac_prev=psdir ;;
998  -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
999    psdir=$ac_optarg ;;
1000
1001  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1002  | -silent | --silent | --silen | --sile | --sil)
1003    silent=yes ;;
1004
1005  -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1006    ac_prev=sbindir ;;
1007  -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1008  | --sbi=* | --sb=*)
1009    sbindir=$ac_optarg ;;
1010
1011  -sharedstatedir | --sharedstatedir | --sharedstatedi \
1012  | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1013  | --sharedst | --shareds | --shared | --share | --shar \
1014  | --sha | --sh)
1015    ac_prev=sharedstatedir ;;
1016  -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1017  | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1018  | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1019  | --sha=* | --sh=*)
1020    sharedstatedir=$ac_optarg ;;
1021
1022  -site | --site | --sit)
1023    ac_prev=site ;;
1024  -site=* | --site=* | --sit=*)
1025    site=$ac_optarg ;;
1026
1027  -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1028    ac_prev=srcdir ;;
1029  -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1030    srcdir=$ac_optarg ;;
1031
1032  -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1033  | --syscon | --sysco | --sysc | --sys | --sy)
1034    ac_prev=sysconfdir ;;
1035  -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1036  | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1037    sysconfdir=$ac_optarg ;;
1038
1039  -target | --target | --targe | --targ | --tar | --ta | --t)
1040    ac_prev=target_alias ;;
1041  -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1042    target_alias=$ac_optarg ;;
1043
1044  -v | -verbose | --verbose | --verbos | --verbo | --verb)
1045    verbose=yes ;;
1046
1047  -version | --version | --versio | --versi | --vers | -V)
1048    ac_init_version=: ;;
1049
1050  -with-* | --with-*)
1051    ac_package=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1052    # Reject names that are not valid shell variable names.
1053    expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1054      { echo "$as_me: error: invalid package name: $ac_package" >&2
1055   { (exit 1); exit 1; }; }
1056    ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
1057    eval with_$ac_package=\$ac_optarg ;;
1058
1059  -without-* | --without-*)
1060    ac_package=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1061    # Reject names that are not valid shell variable names.
1062    expr "x$ac_package" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1063      { echo "$as_me: error: invalid package name: $ac_package" >&2
1064   { (exit 1); exit 1; }; }
1065    ac_package=`echo $ac_package | sed 's/[-.]/_/g'`
1066    eval with_$ac_package=no ;;
1067
1068  --x)
1069    # Obsolete; use --with-x.
1070    with_x=yes ;;
1071
1072  -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1073  | --x-incl | --x-inc | --x-in | --x-i)
1074    ac_prev=x_includes ;;
1075  -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1076  | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1077    x_includes=$ac_optarg ;;
1078
1079  -x-libraries | --x-libraries | --x-librarie | --x-librari \
1080  | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1081    ac_prev=x_libraries ;;
1082  -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1083  | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1084    x_libraries=$ac_optarg ;;
1085
1086  -*) { echo "$as_me: error: unrecognized option: $ac_option
1087Try \`$0 --help' for more information." >&2
1088   { (exit 1); exit 1; }; }
1089    ;;
1090
1091  *=*)
1092    ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1093    # Reject names that are not valid shell variable names.
1094    expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
1095      { echo "$as_me: error: invalid variable name: $ac_envvar" >&2
1096   { (exit 1); exit 1; }; }
1097    eval $ac_envvar=\$ac_optarg
1098    export $ac_envvar ;;
1099
1100  *)
1101    # FIXME: should be removed in autoconf 3.0.
1102    echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1103    expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1104      echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1105    : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1106    ;;
1107
1108  esac
1109done
1110
1111if test -n "$ac_prev"; then
1112  ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1113  { echo "$as_me: error: missing argument to $ac_option" >&2
1114   { (exit 1); exit 1; }; }
1115fi
1116
1117# Be sure to have absolute directory names.
1118for ac_var in	exec_prefix prefix bindir sbindir libexecdir datarootdir \
1119		datadir sysconfdir sharedstatedir localstatedir includedir \
1120		oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1121		libdir localedir mandir
1122do
1123  eval ac_val=\$$ac_var
1124  case $ac_val in
1125    [\\/$]* | ?:[\\/]* )  continue;;
1126    NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1127  esac
1128  { echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
1129   { (exit 1); exit 1; }; }
1130done
1131
1132# There might be people who depend on the old broken behavior: `$host'
1133# used to hold the argument of --host etc.
1134# FIXME: To remove some day.
1135build=$build_alias
1136host=$host_alias
1137target=$target_alias
1138
1139# FIXME: To remove some day.
1140if test "x$host_alias" != x; then
1141  if test "x$build_alias" = x; then
1142    cross_compiling=maybe
1143    echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1144    If a cross compiler is detected then cross compile mode will be used." >&2
1145  elif test "x$build_alias" != "x$host_alias"; then
1146    cross_compiling=yes
1147  fi
1148fi
1149
1150ac_tool_prefix=
1151test -n "$host_alias" && ac_tool_prefix=$host_alias-
1152
1153test "$silent" = yes && exec 6>/dev/null
1154
1155
1156ac_pwd=`pwd` && test -n "$ac_pwd" &&
1157ac_ls_di=`ls -di .` &&
1158ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1159  { echo "$as_me: error: Working directory cannot be determined" >&2
1160   { (exit 1); exit 1; }; }
1161test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1162  { echo "$as_me: error: pwd does not report name of working directory" >&2
1163   { (exit 1); exit 1; }; }
1164
1165
1166# Find the source files, if location was not specified.
1167if test -z "$srcdir"; then
1168  ac_srcdir_defaulted=yes
1169  # Try the directory containing this script, then the parent directory.
1170  ac_confdir=`$as_dirname -- "$0" ||
1171$as_expr X"$0" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1172	 X"$0" : 'X\(//\)[^/]' \| \
1173	 X"$0" : 'X\(//\)$' \| \
1174	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
1175echo X"$0" |
1176    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1177	    s//\1/
1178	    q
1179	  }
1180	  /^X\(\/\/\)[^/].*/{
1181	    s//\1/
1182	    q
1183	  }
1184	  /^X\(\/\/\)$/{
1185	    s//\1/
1186	    q
1187	  }
1188	  /^X\(\/\).*/{
1189	    s//\1/
1190	    q
1191	  }
1192	  s/.*/./; q'`
1193  srcdir=$ac_confdir
1194  if test ! -r "$srcdir/$ac_unique_file"; then
1195    srcdir=..
1196  fi
1197else
1198  ac_srcdir_defaulted=no
1199fi
1200if test ! -r "$srcdir/$ac_unique_file"; then
1201  test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1202  { echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
1203   { (exit 1); exit 1; }; }
1204fi
1205ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1206ac_abs_confdir=`(
1207	cd "$srcdir" && test -r "./$ac_unique_file" || { echo "$as_me: error: $ac_msg" >&2
1208   { (exit 1); exit 1; }; }
1209	pwd)`
1210# When building in place, set srcdir=.
1211if test "$ac_abs_confdir" = "$ac_pwd"; then
1212  srcdir=.
1213fi
1214# Remove unnecessary trailing slashes from srcdir.
1215# Double slashes in file names in object file debugging info
1216# mess up M-x gdb in Emacs.
1217case $srcdir in
1218*/) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1219esac
1220for ac_var in $ac_precious_vars; do
1221  eval ac_env_${ac_var}_set=\${${ac_var}+set}
1222  eval ac_env_${ac_var}_value=\$${ac_var}
1223  eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1224  eval ac_cv_env_${ac_var}_value=\$${ac_var}
1225done
1226
1227#
1228# Report the --help message.
1229#
1230if test "$ac_init_help" = "long"; then
1231  # Omit some internal or obsolete options to make the list less imposing.
1232  # This message is too long to be a string in the A/UX 3.1 sh.
1233  cat <<_ACEOF
1234\`configure' configures OpenSSH Portable to adapt to many kinds of systems.
1235
1236Usage: $0 [OPTION]... [VAR=VALUE]...
1237
1238To assign environment variables (e.g., CC, CFLAGS...), specify them as
1239VAR=VALUE.  See below for descriptions of some of the useful variables.
1240
1241Defaults for the options are specified in brackets.
1242
1243Configuration:
1244  -h, --help              display this help and exit
1245      --help=short        display options specific to this package
1246      --help=recursive    display the short help of all the included packages
1247  -V, --version           display version information and exit
1248  -q, --quiet, --silent   do not print \`checking...' messages
1249      --cache-file=FILE   cache test results in FILE [disabled]
1250  -C, --config-cache      alias for \`--cache-file=config.cache'
1251  -n, --no-create         do not create output files
1252      --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1253
1254Installation directories:
1255  --prefix=PREFIX         install architecture-independent files in PREFIX
1256			  [$ac_default_prefix]
1257  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1258			  [PREFIX]
1259
1260By default, \`make install' will install all the files in
1261\`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1262an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1263for instance \`--prefix=\$HOME'.
1264
1265For better control, use the options below.
1266
1267Fine tuning of the installation directories:
1268  --bindir=DIR           user executables [EPREFIX/bin]
1269  --sbindir=DIR          system admin executables [EPREFIX/sbin]
1270  --libexecdir=DIR       program executables [EPREFIX/libexec]
1271  --sysconfdir=DIR       read-only single-machine data [PREFIX/etc]
1272  --sharedstatedir=DIR   modifiable architecture-independent data [PREFIX/com]
1273  --localstatedir=DIR    modifiable single-machine data [PREFIX/var]
1274  --libdir=DIR           object code libraries [EPREFIX/lib]
1275  --includedir=DIR       C header files [PREFIX/include]
1276  --oldincludedir=DIR    C header files for non-gcc [/usr/include]
1277  --datarootdir=DIR      read-only arch.-independent data root [PREFIX/share]
1278  --datadir=DIR          read-only architecture-independent data [DATAROOTDIR]
1279  --infodir=DIR          info documentation [DATAROOTDIR/info]
1280  --localedir=DIR        locale-dependent data [DATAROOTDIR/locale]
1281  --mandir=DIR           man documentation [DATAROOTDIR/man]
1282  --docdir=DIR           documentation root [DATAROOTDIR/doc/openssh]
1283  --htmldir=DIR          html documentation [DOCDIR]
1284  --dvidir=DIR           dvi documentation [DOCDIR]
1285  --pdfdir=DIR           pdf documentation [DOCDIR]
1286  --psdir=DIR            ps documentation [DOCDIR]
1287_ACEOF
1288
1289  cat <<\_ACEOF
1290
1291System types:
1292  --build=BUILD     configure for building on BUILD [guessed]
1293  --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1294_ACEOF
1295fi
1296
1297if test -n "$ac_init_help"; then
1298  case $ac_init_help in
1299     short | recursive ) echo "Configuration of OpenSSH Portable:";;
1300   esac
1301  cat <<\_ACEOF
1302
1303Optional Features:
1304  --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1305  --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1306  --disable-largefile     omit support for large files
1307  --disable-strip         Disable calling strip(1) on install
1308  --disable-etc-default-login Disable using PATH from /etc/default/login no
1309  --disable-lastlog       disable use of lastlog even if detected no
1310  --disable-utmp          disable use of utmp even if detected no
1311  --disable-utmpx         disable use of utmpx even if detected no
1312  --disable-wtmp          disable use of wtmp even if detected no
1313  --disable-wtmpx         disable use of wtmpx even if detected no
1314  --disable-libutil       disable use of libutil (login() etc.) no
1315  --disable-pututline     disable use of pututline() etc. (uwtmp) no
1316  --disable-pututxline    disable use of pututxline() etc. (uwtmpx) no
1317
1318Optional Packages:
1319  --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1320  --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1321  --without-openssl       Disable use of OpenSSL; use only limited internal crypto **EXPERIMENTAL**
1322  --without-ssh1          Disable support for SSH protocol 1
1323  --without-stackprotect  Don't use compiler's stack protection
1324  --without-hardening     Don't use toolchain hardening flags
1325  --without-rpath         Disable auto-added -R linker paths
1326  --with-cflags           Specify additional flags to pass to compiler
1327  --with-cppflags         Specify additional flags to pass to preprocessor
1328  --with-ldflags          Specify additional flags to pass to linker
1329  --with-libs             Specify additional libraries to link with
1330  --with-Werror           Build main code with -Werror
1331  --with-solaris-contracts Enable Solaris process contracts (experimental)
1332  --with-solaris-projects Enable Solaris projects (experimental)
1333  --with-osfsia           Enable Digital Unix SIA
1334  --with-zlib=PATH        Use zlib in PATH
1335  --without-zlib-version-check Disable zlib version check
1336  --with-skey[=PATH]      Enable S/Key support (optionally in PATH)
1337  --with-ldns[=PATH]      Use ldns for DNSSEC support (optionally in PATH)
1338  --with-libedit[=PATH]   Enable libedit support for sftp
1339  --with-audit=module     Enable audit support (modules=debug,bsm,linux)
1340  --with-pie              Build Position Independent Executables if possible
1341  --with-ssl-dir=PATH     Specify path to OpenSSL installation
1342  --without-openssl-header-check Disable OpenSSL version consistency check
1343  --with-ssl-engine       Enable OpenSSL (hardware) ENGINE support
1344  --with-prngd-port=PORT  read entropy from PRNGD/EGD TCP localhost:PORT
1345  --with-prngd-socket=FILE read entropy from PRNGD/EGD socket FILE (default=/var/run/egd-pool)
1346  --with-pam              Enable PAM support
1347  --with-privsep-user=user Specify non-privileged user for privilege separation
1348  --with-sandbox=style    Specify privilege separation sandbox (no, darwin, rlimit, systrace, seccomp_filter, capsicum)
1349  --with-selinux          Enable SELinux support
1350  --with-kerberos5=PATH   Enable Kerberos 5 support
1351  --with-privsep-path=xxx Path for privilege separation chroot (default=/var/empty)
1352  --with-xauth=PATH       Specify path to xauth program
1353  --with-maildir=/path/to/mail    Specify your system mail directory
1354  --with-mantype=man|cat|doc  Set man page type
1355  --with-md5-passwords    Enable use of MD5 passwords
1356  --without-shadow        Disable shadow password support
1357  --with-ipaddr-display   Use ip address instead of hostname in \$DISPLAY
1358  --with-default-path=    Specify default \$PATH environment for server
1359  --with-superuser-path=  Specify different path for super-user
1360  --with-4in6             Check for and convert IPv4 in IPv6 mapped addresses
1361  --with-bsd-auth         Enable BSD auth support
1362  --with-pid-dir=PATH     Specify location of ssh.pid file
1363  --with-lastlog=FILE|DIR specify lastlog location common locations
1364
1365Some influential environment variables:
1366  CC          C compiler command
1367  CFLAGS      C compiler flags
1368  LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1369              nonstandard directory <lib dir>
1370  LIBS        libraries to pass to the linker, e.g. -l<library>
1371  CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1372              you have headers in a nonstandard directory <include dir>
1373  CPP         C preprocessor
1374
1375Use these variables to override the choices made by `configure' or to help
1376it to find libraries and programs with nonstandard names/locations.
1377
1378Report bugs to <openssh-unix-dev@mindrot.org>.
1379_ACEOF
1380ac_status=$?
1381fi
1382
1383if test "$ac_init_help" = "recursive"; then
1384  # If there are subdirs, report their specific --help.
1385  for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1386    test -d "$ac_dir" || continue
1387    ac_builddir=.
1388
1389case "$ac_dir" in
1390.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1391*)
1392  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
1393  # A ".." for each directory in $ac_dir_suffix.
1394  ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
1395  case $ac_top_builddir_sub in
1396  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1397  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1398  esac ;;
1399esac
1400ac_abs_top_builddir=$ac_pwd
1401ac_abs_builddir=$ac_pwd$ac_dir_suffix
1402# for backward compatibility:
1403ac_top_builddir=$ac_top_build_prefix
1404
1405case $srcdir in
1406  .)  # We are building in place.
1407    ac_srcdir=.
1408    ac_top_srcdir=$ac_top_builddir_sub
1409    ac_abs_top_srcdir=$ac_pwd ;;
1410  [\\/]* | ?:[\\/]* )  # Absolute name.
1411    ac_srcdir=$srcdir$ac_dir_suffix;
1412    ac_top_srcdir=$srcdir
1413    ac_abs_top_srcdir=$srcdir ;;
1414  *) # Relative name.
1415    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1416    ac_top_srcdir=$ac_top_build_prefix$srcdir
1417    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1418esac
1419ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1420
1421    cd "$ac_dir" || { ac_status=$?; continue; }
1422    # Check for guested configure.
1423    if test -f "$ac_srcdir/configure.gnu"; then
1424      echo &&
1425      $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1426    elif test -f "$ac_srcdir/configure"; then
1427      echo &&
1428      $SHELL "$ac_srcdir/configure" --help=recursive
1429    else
1430      echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1431    fi || ac_status=$?
1432    cd "$ac_pwd" || { ac_status=$?; break; }
1433  done
1434fi
1435
1436test -n "$ac_init_help" && exit $ac_status
1437if $ac_init_version; then
1438  cat <<\_ACEOF
1439OpenSSH configure Portable
1440generated by GNU Autoconf 2.61
1441
1442Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
14432002, 2003, 2004, 2005, 2006 Free Software Foundation, Inc.
1444This configure script is free software; the Free Software Foundation
1445gives unlimited permission to copy, distribute and modify it.
1446_ACEOF
1447  exit
1448fi
1449cat >config.log <<_ACEOF
1450This file contains any messages produced by compilers while
1451running configure, to aid debugging if configure makes a mistake.
1452
1453It was created by OpenSSH $as_me Portable, which was
1454generated by GNU Autoconf 2.61.  Invocation command line was
1455
1456  $ $0 $@
1457
1458_ACEOF
1459exec 5>>config.log
1460{
1461cat <<_ASUNAME
1462## --------- ##
1463## Platform. ##
1464## --------- ##
1465
1466hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1467uname -m = `(uname -m) 2>/dev/null || echo unknown`
1468uname -r = `(uname -r) 2>/dev/null || echo unknown`
1469uname -s = `(uname -s) 2>/dev/null || echo unknown`
1470uname -v = `(uname -v) 2>/dev/null || echo unknown`
1471
1472/usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1473/bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1474
1475/bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1476/usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1477/usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1478/usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1479/bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1480/usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1481/bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1482
1483_ASUNAME
1484
1485as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1486for as_dir in $PATH
1487do
1488  IFS=$as_save_IFS
1489  test -z "$as_dir" && as_dir=.
1490  echo "PATH: $as_dir"
1491done
1492IFS=$as_save_IFS
1493
1494} >&5
1495
1496cat >&5 <<_ACEOF
1497
1498
1499## ----------- ##
1500## Core tests. ##
1501## ----------- ##
1502
1503_ACEOF
1504
1505
1506# Keep a trace of the command line.
1507# Strip out --no-create and --no-recursion so they do not pile up.
1508# Strip out --silent because we don't want to record it for future runs.
1509# Also quote any args containing shell meta-characters.
1510# Make two passes to allow for proper duplicate-argument suppression.
1511ac_configure_args=
1512ac_configure_args0=
1513ac_configure_args1=
1514ac_must_keep_next=false
1515for ac_pass in 1 2
1516do
1517  for ac_arg
1518  do
1519    case $ac_arg in
1520    -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1521    -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1522    | -silent | --silent | --silen | --sile | --sil)
1523      continue ;;
1524    *\'*)
1525      ac_arg=`echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1526    esac
1527    case $ac_pass in
1528    1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1529    2)
1530      ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1531      if test $ac_must_keep_next = true; then
1532	ac_must_keep_next=false # Got value, back to normal.
1533      else
1534	case $ac_arg in
1535	  *=* | --config-cache | -C | -disable-* | --disable-* \
1536	  | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1537	  | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1538	  | -with-* | --with-* | -without-* | --without-* | --x)
1539	    case "$ac_configure_args0 " in
1540	      "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1541	    esac
1542	    ;;
1543	  -* ) ac_must_keep_next=true ;;
1544	esac
1545      fi
1546      ac_configure_args="$ac_configure_args '$ac_arg'"
1547      ;;
1548    esac
1549  done
1550done
1551$as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1552$as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1553
1554# When interrupted or exit'd, cleanup temporary files, and complete
1555# config.log.  We remove comments because anyway the quotes in there
1556# would cause problems or look ugly.
1557# WARNING: Use '\'' to represent an apostrophe within the trap.
1558# WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1559trap 'exit_status=$?
1560  # Save into config.log some information that might help in debugging.
1561  {
1562    echo
1563
1564    cat <<\_ASBOX
1565## ---------------- ##
1566## Cache variables. ##
1567## ---------------- ##
1568_ASBOX
1569    echo
1570    # The following way of writing the cache mishandles newlines in values,
1571(
1572  for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1573    eval ac_val=\$$ac_var
1574    case $ac_val in #(
1575    *${as_nl}*)
1576      case $ac_var in #(
1577      *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
1578echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
1579      esac
1580      case $ac_var in #(
1581      _ | IFS | as_nl) ;; #(
1582      *) $as_unset $ac_var ;;
1583      esac ;;
1584    esac
1585  done
1586  (set) 2>&1 |
1587    case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1588    *${as_nl}ac_space=\ *)
1589      sed -n \
1590	"s/'\''/'\''\\\\'\'''\''/g;
1591	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1592      ;; #(
1593    *)
1594      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1595      ;;
1596    esac |
1597    sort
1598)
1599    echo
1600
1601    cat <<\_ASBOX
1602## ----------------- ##
1603## Output variables. ##
1604## ----------------- ##
1605_ASBOX
1606    echo
1607    for ac_var in $ac_subst_vars
1608    do
1609      eval ac_val=\$$ac_var
1610      case $ac_val in
1611      *\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1612      esac
1613      echo "$ac_var='\''$ac_val'\''"
1614    done | sort
1615    echo
1616
1617    if test -n "$ac_subst_files"; then
1618      cat <<\_ASBOX
1619## ------------------- ##
1620## File substitutions. ##
1621## ------------------- ##
1622_ASBOX
1623      echo
1624      for ac_var in $ac_subst_files
1625      do
1626	eval ac_val=\$$ac_var
1627	case $ac_val in
1628	*\'\''*) ac_val=`echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1629	esac
1630	echo "$ac_var='\''$ac_val'\''"
1631      done | sort
1632      echo
1633    fi
1634
1635    if test -s confdefs.h; then
1636      cat <<\_ASBOX
1637## ----------- ##
1638## confdefs.h. ##
1639## ----------- ##
1640_ASBOX
1641      echo
1642      cat confdefs.h
1643      echo
1644    fi
1645    test "$ac_signal" != 0 &&
1646      echo "$as_me: caught signal $ac_signal"
1647    echo "$as_me: exit $exit_status"
1648  } >&5
1649  rm -f core *.core core.conftest.* &&
1650    rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1651    exit $exit_status
1652' 0
1653for ac_signal in 1 2 13 15; do
1654  trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1655done
1656ac_signal=0
1657
1658# confdefs.h avoids OS command line length limits that DEFS can exceed.
1659rm -f -r conftest* confdefs.h
1660
1661# Predefined preprocessor variables.
1662
1663cat >>confdefs.h <<_ACEOF
1664#define PACKAGE_NAME "$PACKAGE_NAME"
1665_ACEOF
1666
1667
1668cat >>confdefs.h <<_ACEOF
1669#define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1670_ACEOF
1671
1672
1673cat >>confdefs.h <<_ACEOF
1674#define PACKAGE_VERSION "$PACKAGE_VERSION"
1675_ACEOF
1676
1677
1678cat >>confdefs.h <<_ACEOF
1679#define PACKAGE_STRING "$PACKAGE_STRING"
1680_ACEOF
1681
1682
1683cat >>confdefs.h <<_ACEOF
1684#define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1685_ACEOF
1686
1687
1688# Let the site file select an alternate cache file if it wants to.
1689# Prefer explicitly selected file to automatically selected ones.
1690if test -n "$CONFIG_SITE"; then
1691  set x "$CONFIG_SITE"
1692elif test "x$prefix" != xNONE; then
1693  set x "$prefix/share/config.site" "$prefix/etc/config.site"
1694else
1695  set x "$ac_default_prefix/share/config.site" \
1696	"$ac_default_prefix/etc/config.site"
1697fi
1698shift
1699for ac_site_file
1700do
1701  if test -r "$ac_site_file"; then
1702    { echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1703echo "$as_me: loading site script $ac_site_file" >&6;}
1704    sed 's/^/| /' "$ac_site_file" >&5
1705    . "$ac_site_file"
1706  fi
1707done
1708
1709if test -r "$cache_file"; then
1710  # Some versions of bash will fail to source /dev/null (special
1711  # files actually), so we avoid doing that.
1712  if test -f "$cache_file"; then
1713    { echo "$as_me:$LINENO: loading cache $cache_file" >&5
1714echo "$as_me: loading cache $cache_file" >&6;}
1715    case $cache_file in
1716      [\\/]* | ?:[\\/]* ) . "$cache_file";;
1717      *)                      . "./$cache_file";;
1718    esac
1719  fi
1720else
1721  { echo "$as_me:$LINENO: creating cache $cache_file" >&5
1722echo "$as_me: creating cache $cache_file" >&6;}
1723  >$cache_file
1724fi
1725
1726# Check that the precious variables saved in the cache have kept the same
1727# value.
1728ac_cache_corrupted=false
1729for ac_var in $ac_precious_vars; do
1730  eval ac_old_set=\$ac_cv_env_${ac_var}_set
1731  eval ac_new_set=\$ac_env_${ac_var}_set
1732  eval ac_old_val=\$ac_cv_env_${ac_var}_value
1733  eval ac_new_val=\$ac_env_${ac_var}_value
1734  case $ac_old_set,$ac_new_set in
1735    set,)
1736      { echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1737echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1738      ac_cache_corrupted=: ;;
1739    ,set)
1740      { echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1741echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1742      ac_cache_corrupted=: ;;
1743    ,);;
1744    *)
1745      if test "x$ac_old_val" != "x$ac_new_val"; then
1746	{ echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1747echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1748	{ echo "$as_me:$LINENO:   former value:  $ac_old_val" >&5
1749echo "$as_me:   former value:  $ac_old_val" >&2;}
1750	{ echo "$as_me:$LINENO:   current value: $ac_new_val" >&5
1751echo "$as_me:   current value: $ac_new_val" >&2;}
1752	ac_cache_corrupted=:
1753      fi;;
1754  esac
1755  # Pass precious variables to config.status.
1756  if test "$ac_new_set" = set; then
1757    case $ac_new_val in
1758    *\'*) ac_arg=$ac_var=`echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1759    *) ac_arg=$ac_var=$ac_new_val ;;
1760    esac
1761    case " $ac_configure_args " in
1762      *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1763      *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1764    esac
1765  fi
1766done
1767if $ac_cache_corrupted; then
1768  { echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1769echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1770  { { echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1771echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1772   { (exit 1); exit 1; }; }
1773fi
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799ac_ext=c
1800ac_cpp='$CPP $CPPFLAGS'
1801ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1802ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1803ac_compiler_gnu=$ac_cv_c_compiler_gnu
1804
1805
1806
1807
1808ac_ext=c
1809ac_cpp='$CPP $CPPFLAGS'
1810ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1811ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1812ac_compiler_gnu=$ac_cv_c_compiler_gnu
1813
1814
1815ac_config_headers="$ac_config_headers config.h"
1816
1817ac_ext=c
1818ac_cpp='$CPP $CPPFLAGS'
1819ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
1820ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
1821ac_compiler_gnu=$ac_cv_c_compiler_gnu
1822if test -n "$ac_tool_prefix"; then
1823  # Extract the first word of "${ac_tool_prefix}gcc", so it can be a program name with args.
1824set dummy ${ac_tool_prefix}gcc; ac_word=$2
1825{ echo "$as_me:$LINENO: checking for $ac_word" >&5
1826echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
1827if test "${ac_cv_prog_CC+set}" = set; then
1828  echo $ECHO_N "(cached) $ECHO_C" >&6
1829else
1830  if test -n "$CC"; then
1831  ac_cv_prog_CC="$CC" # Let the user override the test.
1832else
1833as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1834for as_dir in $PATH
1835do
1836  IFS=$as_save_IFS
1837  test -z "$as_dir" && as_dir=.
1838  for ac_exec_ext in '' $ac_executable_extensions; do
1839  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
1840    ac_cv_prog_CC="${ac_tool_prefix}gcc"
1841    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1842    break 2
1843  fi
1844done
1845done
1846IFS=$as_save_IFS
1847
1848fi
1849fi
1850CC=$ac_cv_prog_CC
1851if test -n "$CC"; then
1852  { echo "$as_me:$LINENO: result: $CC" >&5
1853echo "${ECHO_T}$CC" >&6; }
1854else
1855  { echo "$as_me:$LINENO: result: no" >&5
1856echo "${ECHO_T}no" >&6; }
1857fi
1858
1859
1860fi
1861if test -z "$ac_cv_prog_CC"; then
1862  ac_ct_CC=$CC
1863  # Extract the first word of "gcc", so it can be a program name with args.
1864set dummy gcc; ac_word=$2
1865{ echo "$as_me:$LINENO: checking for $ac_word" >&5
1866echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
1867if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
1868  echo $ECHO_N "(cached) $ECHO_C" >&6
1869else
1870  if test -n "$ac_ct_CC"; then
1871  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
1872else
1873as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1874for as_dir in $PATH
1875do
1876  IFS=$as_save_IFS
1877  test -z "$as_dir" && as_dir=.
1878  for ac_exec_ext in '' $ac_executable_extensions; do
1879  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
1880    ac_cv_prog_ac_ct_CC="gcc"
1881    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1882    break 2
1883  fi
1884done
1885done
1886IFS=$as_save_IFS
1887
1888fi
1889fi
1890ac_ct_CC=$ac_cv_prog_ac_ct_CC
1891if test -n "$ac_ct_CC"; then
1892  { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
1893echo "${ECHO_T}$ac_ct_CC" >&6; }
1894else
1895  { echo "$as_me:$LINENO: result: no" >&5
1896echo "${ECHO_T}no" >&6; }
1897fi
1898
1899  if test "x$ac_ct_CC" = x; then
1900    CC=""
1901  else
1902    case $cross_compiling:$ac_tool_warned in
1903yes:)
1904{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
1905whose name does not start with the host triplet.  If you think this
1906configuration is useful to you, please write to autoconf@gnu.org." >&5
1907echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
1908whose name does not start with the host triplet.  If you think this
1909configuration is useful to you, please write to autoconf@gnu.org." >&2;}
1910ac_tool_warned=yes ;;
1911esac
1912    CC=$ac_ct_CC
1913  fi
1914else
1915  CC="$ac_cv_prog_CC"
1916fi
1917
1918if test -z "$CC"; then
1919          if test -n "$ac_tool_prefix"; then
1920    # Extract the first word of "${ac_tool_prefix}cc", so it can be a program name with args.
1921set dummy ${ac_tool_prefix}cc; ac_word=$2
1922{ echo "$as_me:$LINENO: checking for $ac_word" >&5
1923echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
1924if test "${ac_cv_prog_CC+set}" = set; then
1925  echo $ECHO_N "(cached) $ECHO_C" >&6
1926else
1927  if test -n "$CC"; then
1928  ac_cv_prog_CC="$CC" # Let the user override the test.
1929else
1930as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1931for as_dir in $PATH
1932do
1933  IFS=$as_save_IFS
1934  test -z "$as_dir" && as_dir=.
1935  for ac_exec_ext in '' $ac_executable_extensions; do
1936  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
1937    ac_cv_prog_CC="${ac_tool_prefix}cc"
1938    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1939    break 2
1940  fi
1941done
1942done
1943IFS=$as_save_IFS
1944
1945fi
1946fi
1947CC=$ac_cv_prog_CC
1948if test -n "$CC"; then
1949  { echo "$as_me:$LINENO: result: $CC" >&5
1950echo "${ECHO_T}$CC" >&6; }
1951else
1952  { echo "$as_me:$LINENO: result: no" >&5
1953echo "${ECHO_T}no" >&6; }
1954fi
1955
1956
1957  fi
1958fi
1959if test -z "$CC"; then
1960  # Extract the first word of "cc", so it can be a program name with args.
1961set dummy cc; ac_word=$2
1962{ echo "$as_me:$LINENO: checking for $ac_word" >&5
1963echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
1964if test "${ac_cv_prog_CC+set}" = set; then
1965  echo $ECHO_N "(cached) $ECHO_C" >&6
1966else
1967  if test -n "$CC"; then
1968  ac_cv_prog_CC="$CC" # Let the user override the test.
1969else
1970  ac_prog_rejected=no
1971as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1972for as_dir in $PATH
1973do
1974  IFS=$as_save_IFS
1975  test -z "$as_dir" && as_dir=.
1976  for ac_exec_ext in '' $ac_executable_extensions; do
1977  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
1978    if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/ucb/cc"; then
1979       ac_prog_rejected=yes
1980       continue
1981     fi
1982    ac_cv_prog_CC="cc"
1983    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
1984    break 2
1985  fi
1986done
1987done
1988IFS=$as_save_IFS
1989
1990if test $ac_prog_rejected = yes; then
1991  # We found a bogon in the path, so make sure we never use it.
1992  set dummy $ac_cv_prog_CC
1993  shift
1994  if test $# != 0; then
1995    # We chose a different compiler from the bogus one.
1996    # However, it has the same basename, so the bogon will be chosen
1997    # first if we set CC to just the basename; use the full file name.
1998    shift
1999    ac_cv_prog_CC="$as_dir/$ac_word${1+' '}$@"
2000  fi
2001fi
2002fi
2003fi
2004CC=$ac_cv_prog_CC
2005if test -n "$CC"; then
2006  { echo "$as_me:$LINENO: result: $CC" >&5
2007echo "${ECHO_T}$CC" >&6; }
2008else
2009  { echo "$as_me:$LINENO: result: no" >&5
2010echo "${ECHO_T}no" >&6; }
2011fi
2012
2013
2014fi
2015if test -z "$CC"; then
2016  if test -n "$ac_tool_prefix"; then
2017  for ac_prog in cl.exe
2018  do
2019    # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
2020set dummy $ac_tool_prefix$ac_prog; ac_word=$2
2021{ echo "$as_me:$LINENO: checking for $ac_word" >&5
2022echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
2023if test "${ac_cv_prog_CC+set}" = set; then
2024  echo $ECHO_N "(cached) $ECHO_C" >&6
2025else
2026  if test -n "$CC"; then
2027  ac_cv_prog_CC="$CC" # Let the user override the test.
2028else
2029as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2030for as_dir in $PATH
2031do
2032  IFS=$as_save_IFS
2033  test -z "$as_dir" && as_dir=.
2034  for ac_exec_ext in '' $ac_executable_extensions; do
2035  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2036    ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
2037    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2038    break 2
2039  fi
2040done
2041done
2042IFS=$as_save_IFS
2043
2044fi
2045fi
2046CC=$ac_cv_prog_CC
2047if test -n "$CC"; then
2048  { echo "$as_me:$LINENO: result: $CC" >&5
2049echo "${ECHO_T}$CC" >&6; }
2050else
2051  { echo "$as_me:$LINENO: result: no" >&5
2052echo "${ECHO_T}no" >&6; }
2053fi
2054
2055
2056    test -n "$CC" && break
2057  done
2058fi
2059if test -z "$CC"; then
2060  ac_ct_CC=$CC
2061  for ac_prog in cl.exe
2062do
2063  # Extract the first word of "$ac_prog", so it can be a program name with args.
2064set dummy $ac_prog; ac_word=$2
2065{ echo "$as_me:$LINENO: checking for $ac_word" >&5
2066echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
2067if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
2068  echo $ECHO_N "(cached) $ECHO_C" >&6
2069else
2070  if test -n "$ac_ct_CC"; then
2071  ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
2072else
2073as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2074for as_dir in $PATH
2075do
2076  IFS=$as_save_IFS
2077  test -z "$as_dir" && as_dir=.
2078  for ac_exec_ext in '' $ac_executable_extensions; do
2079  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2080    ac_cv_prog_ac_ct_CC="$ac_prog"
2081    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2082    break 2
2083  fi
2084done
2085done
2086IFS=$as_save_IFS
2087
2088fi
2089fi
2090ac_ct_CC=$ac_cv_prog_ac_ct_CC
2091if test -n "$ac_ct_CC"; then
2092  { echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
2093echo "${ECHO_T}$ac_ct_CC" >&6; }
2094else
2095  { echo "$as_me:$LINENO: result: no" >&5
2096echo "${ECHO_T}no" >&6; }
2097fi
2098
2099
2100  test -n "$ac_ct_CC" && break
2101done
2102
2103  if test "x$ac_ct_CC" = x; then
2104    CC=""
2105  else
2106    case $cross_compiling:$ac_tool_warned in
2107yes:)
2108{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
2109whose name does not start with the host triplet.  If you think this
2110configuration is useful to you, please write to autoconf@gnu.org." >&5
2111echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
2112whose name does not start with the host triplet.  If you think this
2113configuration is useful to you, please write to autoconf@gnu.org." >&2;}
2114ac_tool_warned=yes ;;
2115esac
2116    CC=$ac_ct_CC
2117  fi
2118fi
2119
2120fi
2121
2122
2123test -z "$CC" && { { echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
2124See \`config.log' for more details." >&5
2125echo "$as_me: error: no acceptable C compiler found in \$PATH
2126See \`config.log' for more details." >&2;}
2127   { (exit 1); exit 1; }; }
2128
2129# Provide some information about the compiler.
2130echo "$as_me:$LINENO: checking for C compiler version" >&5
2131ac_compiler=`set X $ac_compile; echo $2`
2132{ (ac_try="$ac_compiler --version >&5"
2133case "(($ac_try" in
2134  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2135  *) ac_try_echo=$ac_try;;
2136esac
2137eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2138  (eval "$ac_compiler --version >&5") 2>&5
2139  ac_status=$?
2140  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2141  (exit $ac_status); }
2142{ (ac_try="$ac_compiler -v >&5"
2143case "(($ac_try" in
2144  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2145  *) ac_try_echo=$ac_try;;
2146esac
2147eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2148  (eval "$ac_compiler -v >&5") 2>&5
2149  ac_status=$?
2150  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2151  (exit $ac_status); }
2152{ (ac_try="$ac_compiler -V >&5"
2153case "(($ac_try" in
2154  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2155  *) ac_try_echo=$ac_try;;
2156esac
2157eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2158  (eval "$ac_compiler -V >&5") 2>&5
2159  ac_status=$?
2160  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2161  (exit $ac_status); }
2162
2163cat >conftest.$ac_ext <<_ACEOF
2164/* confdefs.h.  */
2165_ACEOF
2166cat confdefs.h >>conftest.$ac_ext
2167cat >>conftest.$ac_ext <<_ACEOF
2168/* end confdefs.h.  */
2169
2170int
2171main ()
2172{
2173
2174  ;
2175  return 0;
2176}
2177_ACEOF
2178ac_clean_files_save=$ac_clean_files
2179ac_clean_files="$ac_clean_files a.out a.exe b.out"
2180# Try to create an executable without -o first, disregard a.out.
2181# It will help us diagnose broken compilers, and finding out an intuition
2182# of exeext.
2183{ echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
2184echo $ECHO_N "checking for C compiler default output file name... $ECHO_C" >&6; }
2185ac_link_default=`echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
2186#
2187# List of possible output files, starting from the most likely.
2188# The algorithm is not robust to junk in `.', hence go to wildcards (a.*)
2189# only as a last resort.  b.out is created by i960 compilers.
2190ac_files='a_out.exe a.exe conftest.exe a.out conftest a.* conftest.* b.out'
2191#
2192# The IRIX 6 linker writes into existing files which may not be
2193# executable, retaining their permissions.  Remove them first so a
2194# subsequent execution test works.
2195ac_rmfiles=
2196for ac_file in $ac_files
2197do
2198  case $ac_file in
2199    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
2200    * ) ac_rmfiles="$ac_rmfiles $ac_file";;
2201  esac
2202done
2203rm -f $ac_rmfiles
2204
2205if { (ac_try="$ac_link_default"
2206case "(($ac_try" in
2207  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2208  *) ac_try_echo=$ac_try;;
2209esac
2210eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2211  (eval "$ac_link_default") 2>&5
2212  ac_status=$?
2213  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2214  (exit $ac_status); }; then
2215  # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
2216# So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
2217# in a Makefile.  We should not override ac_cv_exeext if it was cached,
2218# so that the user can short-circuit this test for compilers unknown to
2219# Autoconf.
2220for ac_file in $ac_files ''
2221do
2222  test -f "$ac_file" || continue
2223  case $ac_file in
2224    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj )
2225	;;
2226    [ab].out )
2227	# We found the default executable, but exeext='' is most
2228	# certainly right.
2229	break;;
2230    *.* )
2231        if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
2232	then :; else
2233	   ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2234	fi
2235	# We set ac_cv_exeext here because the later test for it is not
2236	# safe: cross compilers may not add the suffix if given an `-o'
2237	# argument, so we may need to know it at that point already.
2238	# Even if this section looks crufty: it has the advantage of
2239	# actually working.
2240	break;;
2241    * )
2242	break;;
2243  esac
2244done
2245test "$ac_cv_exeext" = no && ac_cv_exeext=
2246
2247else
2248  ac_file=''
2249fi
2250
2251{ echo "$as_me:$LINENO: result: $ac_file" >&5
2252echo "${ECHO_T}$ac_file" >&6; }
2253if test -z "$ac_file"; then
2254  echo "$as_me: failed program was:" >&5
2255sed 's/^/| /' conftest.$ac_ext >&5
2256
2257{ { echo "$as_me:$LINENO: error: C compiler cannot create executables
2258See \`config.log' for more details." >&5
2259echo "$as_me: error: C compiler cannot create executables
2260See \`config.log' for more details." >&2;}
2261   { (exit 77); exit 77; }; }
2262fi
2263
2264ac_exeext=$ac_cv_exeext
2265
2266# Check that the compiler produces executables we can run.  If not, either
2267# the compiler is broken, or we cross compile.
2268{ echo "$as_me:$LINENO: checking whether the C compiler works" >&5
2269echo $ECHO_N "checking whether the C compiler works... $ECHO_C" >&6; }
2270# FIXME: These cross compiler hacks should be removed for Autoconf 3.0
2271# If not cross compiling, check that we can run a simple program.
2272if test "$cross_compiling" != yes; then
2273  if { ac_try='./$ac_file'
2274  { (case "(($ac_try" in
2275  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2276  *) ac_try_echo=$ac_try;;
2277esac
2278eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2279  (eval "$ac_try") 2>&5
2280  ac_status=$?
2281  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2282  (exit $ac_status); }; }; then
2283    cross_compiling=no
2284  else
2285    if test "$cross_compiling" = maybe; then
2286	cross_compiling=yes
2287    else
2288	{ { echo "$as_me:$LINENO: error: cannot run C compiled programs.
2289If you meant to cross compile, use \`--host'.
2290See \`config.log' for more details." >&5
2291echo "$as_me: error: cannot run C compiled programs.
2292If you meant to cross compile, use \`--host'.
2293See \`config.log' for more details." >&2;}
2294   { (exit 1); exit 1; }; }
2295    fi
2296  fi
2297fi
2298{ echo "$as_me:$LINENO: result: yes" >&5
2299echo "${ECHO_T}yes" >&6; }
2300
2301rm -f a.out a.exe conftest$ac_cv_exeext b.out
2302ac_clean_files=$ac_clean_files_save
2303# Check that the compiler produces executables we can run.  If not, either
2304# the compiler is broken, or we cross compile.
2305{ echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
2306echo $ECHO_N "checking whether we are cross compiling... $ECHO_C" >&6; }
2307{ echo "$as_me:$LINENO: result: $cross_compiling" >&5
2308echo "${ECHO_T}$cross_compiling" >&6; }
2309
2310{ echo "$as_me:$LINENO: checking for suffix of executables" >&5
2311echo $ECHO_N "checking for suffix of executables... $ECHO_C" >&6; }
2312if { (ac_try="$ac_link"
2313case "(($ac_try" in
2314  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2315  *) ac_try_echo=$ac_try;;
2316esac
2317eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2318  (eval "$ac_link") 2>&5
2319  ac_status=$?
2320  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2321  (exit $ac_status); }; then
2322  # If both `conftest.exe' and `conftest' are `present' (well, observable)
2323# catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
2324# work properly (i.e., refer to `conftest.exe'), while it won't with
2325# `rm'.
2326for ac_file in conftest.exe conftest conftest.*; do
2327  test -f "$ac_file" || continue
2328  case $ac_file in
2329    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.o | *.obj ) ;;
2330    *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
2331	  break;;
2332    * ) break;;
2333  esac
2334done
2335else
2336  { { echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
2337See \`config.log' for more details." >&5
2338echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
2339See \`config.log' for more details." >&2;}
2340   { (exit 1); exit 1; }; }
2341fi
2342
2343rm -f conftest$ac_cv_exeext
2344{ echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
2345echo "${ECHO_T}$ac_cv_exeext" >&6; }
2346
2347rm -f conftest.$ac_ext
2348EXEEXT=$ac_cv_exeext
2349ac_exeext=$EXEEXT
2350{ echo "$as_me:$LINENO: checking for suffix of object files" >&5
2351echo $ECHO_N "checking for suffix of object files... $ECHO_C" >&6; }
2352if test "${ac_cv_objext+set}" = set; then
2353  echo $ECHO_N "(cached) $ECHO_C" >&6
2354else
2355  cat >conftest.$ac_ext <<_ACEOF
2356/* confdefs.h.  */
2357_ACEOF
2358cat confdefs.h >>conftest.$ac_ext
2359cat >>conftest.$ac_ext <<_ACEOF
2360/* end confdefs.h.  */
2361
2362int
2363main ()
2364{
2365
2366  ;
2367  return 0;
2368}
2369_ACEOF
2370rm -f conftest.o conftest.obj
2371if { (ac_try="$ac_compile"
2372case "(($ac_try" in
2373  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2374  *) ac_try_echo=$ac_try;;
2375esac
2376eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2377  (eval "$ac_compile") 2>&5
2378  ac_status=$?
2379  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2380  (exit $ac_status); }; then
2381  for ac_file in conftest.o conftest.obj conftest.*; do
2382  test -f "$ac_file" || continue;
2383  case $ac_file in
2384    *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf ) ;;
2385    *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
2386       break;;
2387  esac
2388done
2389else
2390  echo "$as_me: failed program was:" >&5
2391sed 's/^/| /' conftest.$ac_ext >&5
2392
2393{ { echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
2394See \`config.log' for more details." >&5
2395echo "$as_me: error: cannot compute suffix of object files: cannot compile
2396See \`config.log' for more details." >&2;}
2397   { (exit 1); exit 1; }; }
2398fi
2399
2400rm -f conftest.$ac_cv_objext conftest.$ac_ext
2401fi
2402{ echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
2403echo "${ECHO_T}$ac_cv_objext" >&6; }
2404OBJEXT=$ac_cv_objext
2405ac_objext=$OBJEXT
2406{ echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
2407echo $ECHO_N "checking whether we are using the GNU C compiler... $ECHO_C" >&6; }
2408if test "${ac_cv_c_compiler_gnu+set}" = set; then
2409  echo $ECHO_N "(cached) $ECHO_C" >&6
2410else
2411  cat >conftest.$ac_ext <<_ACEOF
2412/* confdefs.h.  */
2413_ACEOF
2414cat confdefs.h >>conftest.$ac_ext
2415cat >>conftest.$ac_ext <<_ACEOF
2416/* end confdefs.h.  */
2417
2418int
2419main ()
2420{
2421#ifndef __GNUC__
2422       choke me
2423#endif
2424
2425  ;
2426  return 0;
2427}
2428_ACEOF
2429rm -f conftest.$ac_objext
2430if { (ac_try="$ac_compile"
2431case "(($ac_try" in
2432  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2433  *) ac_try_echo=$ac_try;;
2434esac
2435eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2436  (eval "$ac_compile") 2>conftest.er1
2437  ac_status=$?
2438  grep -v '^ *+' conftest.er1 >conftest.err
2439  rm -f conftest.er1
2440  cat conftest.err >&5
2441  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2442  (exit $ac_status); } && {
2443	 test -z "$ac_c_werror_flag" ||
2444	 test ! -s conftest.err
2445       } && test -s conftest.$ac_objext; then
2446  ac_compiler_gnu=yes
2447else
2448  echo "$as_me: failed program was:" >&5
2449sed 's/^/| /' conftest.$ac_ext >&5
2450
2451	ac_compiler_gnu=no
2452fi
2453
2454rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2455ac_cv_c_compiler_gnu=$ac_compiler_gnu
2456
2457fi
2458{ echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
2459echo "${ECHO_T}$ac_cv_c_compiler_gnu" >&6; }
2460GCC=`test $ac_compiler_gnu = yes && echo yes`
2461ac_test_CFLAGS=${CFLAGS+set}
2462ac_save_CFLAGS=$CFLAGS
2463{ echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
2464echo $ECHO_N "checking whether $CC accepts -g... $ECHO_C" >&6; }
2465if test "${ac_cv_prog_cc_g+set}" = set; then
2466  echo $ECHO_N "(cached) $ECHO_C" >&6
2467else
2468  ac_save_c_werror_flag=$ac_c_werror_flag
2469   ac_c_werror_flag=yes
2470   ac_cv_prog_cc_g=no
2471   CFLAGS="-g"
2472   cat >conftest.$ac_ext <<_ACEOF
2473/* confdefs.h.  */
2474_ACEOF
2475cat confdefs.h >>conftest.$ac_ext
2476cat >>conftest.$ac_ext <<_ACEOF
2477/* end confdefs.h.  */
2478
2479int
2480main ()
2481{
2482
2483  ;
2484  return 0;
2485}
2486_ACEOF
2487rm -f conftest.$ac_objext
2488if { (ac_try="$ac_compile"
2489case "(($ac_try" in
2490  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2491  *) ac_try_echo=$ac_try;;
2492esac
2493eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2494  (eval "$ac_compile") 2>conftest.er1
2495  ac_status=$?
2496  grep -v '^ *+' conftest.er1 >conftest.err
2497  rm -f conftest.er1
2498  cat conftest.err >&5
2499  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2500  (exit $ac_status); } && {
2501	 test -z "$ac_c_werror_flag" ||
2502	 test ! -s conftest.err
2503       } && test -s conftest.$ac_objext; then
2504  ac_cv_prog_cc_g=yes
2505else
2506  echo "$as_me: failed program was:" >&5
2507sed 's/^/| /' conftest.$ac_ext >&5
2508
2509	CFLAGS=""
2510      cat >conftest.$ac_ext <<_ACEOF
2511/* confdefs.h.  */
2512_ACEOF
2513cat confdefs.h >>conftest.$ac_ext
2514cat >>conftest.$ac_ext <<_ACEOF
2515/* end confdefs.h.  */
2516
2517int
2518main ()
2519{
2520
2521  ;
2522  return 0;
2523}
2524_ACEOF
2525rm -f conftest.$ac_objext
2526if { (ac_try="$ac_compile"
2527case "(($ac_try" in
2528  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2529  *) ac_try_echo=$ac_try;;
2530esac
2531eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2532  (eval "$ac_compile") 2>conftest.er1
2533  ac_status=$?
2534  grep -v '^ *+' conftest.er1 >conftest.err
2535  rm -f conftest.er1
2536  cat conftest.err >&5
2537  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2538  (exit $ac_status); } && {
2539	 test -z "$ac_c_werror_flag" ||
2540	 test ! -s conftest.err
2541       } && test -s conftest.$ac_objext; then
2542  :
2543else
2544  echo "$as_me: failed program was:" >&5
2545sed 's/^/| /' conftest.$ac_ext >&5
2546
2547	ac_c_werror_flag=$ac_save_c_werror_flag
2548	 CFLAGS="-g"
2549	 cat >conftest.$ac_ext <<_ACEOF
2550/* confdefs.h.  */
2551_ACEOF
2552cat confdefs.h >>conftest.$ac_ext
2553cat >>conftest.$ac_ext <<_ACEOF
2554/* end confdefs.h.  */
2555
2556int
2557main ()
2558{
2559
2560  ;
2561  return 0;
2562}
2563_ACEOF
2564rm -f conftest.$ac_objext
2565if { (ac_try="$ac_compile"
2566case "(($ac_try" in
2567  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2568  *) ac_try_echo=$ac_try;;
2569esac
2570eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2571  (eval "$ac_compile") 2>conftest.er1
2572  ac_status=$?
2573  grep -v '^ *+' conftest.er1 >conftest.err
2574  rm -f conftest.er1
2575  cat conftest.err >&5
2576  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2577  (exit $ac_status); } && {
2578	 test -z "$ac_c_werror_flag" ||
2579	 test ! -s conftest.err
2580       } && test -s conftest.$ac_objext; then
2581  ac_cv_prog_cc_g=yes
2582else
2583  echo "$as_me: failed program was:" >&5
2584sed 's/^/| /' conftest.$ac_ext >&5
2585
2586
2587fi
2588
2589rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2590fi
2591
2592rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2593fi
2594
2595rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
2596   ac_c_werror_flag=$ac_save_c_werror_flag
2597fi
2598{ echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
2599echo "${ECHO_T}$ac_cv_prog_cc_g" >&6; }
2600if test "$ac_test_CFLAGS" = set; then
2601  CFLAGS=$ac_save_CFLAGS
2602elif test $ac_cv_prog_cc_g = yes; then
2603  if test "$GCC" = yes; then
2604    CFLAGS="-g -O2"
2605  else
2606    CFLAGS="-g"
2607  fi
2608else
2609  if test "$GCC" = yes; then
2610    CFLAGS="-O2"
2611  else
2612    CFLAGS=
2613  fi
2614fi
2615{ echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
2616echo $ECHO_N "checking for $CC option to accept ISO C89... $ECHO_C" >&6; }
2617if test "${ac_cv_prog_cc_c89+set}" = set; then
2618  echo $ECHO_N "(cached) $ECHO_C" >&6
2619else
2620  ac_cv_prog_cc_c89=no
2621ac_save_CC=$CC
2622cat >conftest.$ac_ext <<_ACEOF
2623/* confdefs.h.  */
2624_ACEOF
2625cat confdefs.h >>conftest.$ac_ext
2626cat >>conftest.$ac_ext <<_ACEOF
2627/* end confdefs.h.  */
2628#include <stdarg.h>
2629#include <stdio.h>
2630#include <sys/types.h>
2631#include <sys/stat.h>
2632/* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
2633struct buf { int x; };
2634FILE * (*rcsopen) (struct buf *, struct stat *, int);
2635static char *e (p, i)
2636     char **p;
2637     int i;
2638{
2639  return p[i];
2640}
2641static char *f (char * (*g) (char **, int), char **p, ...)
2642{
2643  char *s;
2644  va_list v;
2645  va_start (v,p);
2646  s = g (p, va_arg (v,int));
2647  va_end (v);
2648  return s;
2649}
2650
2651/* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
2652   function prototypes and stuff, but not '\xHH' hex character constants.
2653   These don't provoke an error unfortunately, instead are silently treated
2654   as 'x'.  The following induces an error, until -std is added to get
2655   proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
2656   array size at least.  It's necessary to write '\x00'==0 to get something
2657   that's true only with -std.  */
2658int osf4_cc_array ['\x00' == 0 ? 1 : -1];
2659
2660/* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
2661   inside strings and character constants.  */
2662#define FOO(x) 'x'
2663int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
2664
2665int test (int i, double x);
2666struct s1 {int (*f) (int a);};
2667struct s2 {int (*f) (double a);};
2668int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
2669int argc;
2670char **argv;
2671int
2672main ()
2673{
2674return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
2675  ;
2676  return 0;
2677}
2678_ACEOF
2679for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
2680	-Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
2681do
2682  CC="$ac_save_CC $ac_arg"
2683  rm -f conftest.$ac_objext
2684if { (ac_try="$ac_compile"
2685case "(($ac_try" in
2686  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2687  *) ac_try_echo=$ac_try;;
2688esac
2689eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2690  (eval "$ac_compile") 2>conftest.er1
2691  ac_status=$?
2692  grep -v '^ *+' conftest.er1 >conftest.err
2693  rm -f conftest.er1
2694  cat conftest.err >&5
2695  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2696  (exit $ac_status); } && {
2697	 test -z "$ac_c_werror_flag" ||
2698	 test ! -s conftest.err
2699       } && test -s conftest.$ac_objext; then
2700  ac_cv_prog_cc_c89=$ac_arg
2701else
2702  echo "$as_me: failed program was:" >&5
2703sed 's/^/| /' conftest.$ac_ext >&5
2704
2705
2706fi
2707
2708rm -f core conftest.err conftest.$ac_objext
2709  test "x$ac_cv_prog_cc_c89" != "xno" && break
2710done
2711rm -f conftest.$ac_ext
2712CC=$ac_save_CC
2713
2714fi
2715# AC_CACHE_VAL
2716case "x$ac_cv_prog_cc_c89" in
2717  x)
2718    { echo "$as_me:$LINENO: result: none needed" >&5
2719echo "${ECHO_T}none needed" >&6; } ;;
2720  xno)
2721    { echo "$as_me:$LINENO: result: unsupported" >&5
2722echo "${ECHO_T}unsupported" >&6; } ;;
2723  *)
2724    CC="$CC $ac_cv_prog_cc_c89"
2725    { echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
2726echo "${ECHO_T}$ac_cv_prog_cc_c89" >&6; } ;;
2727esac
2728
2729
2730ac_ext=c
2731ac_cpp='$CPP $CPPFLAGS'
2732ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2733ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2734ac_compiler_gnu=$ac_cv_c_compiler_gnu
2735
2736ac_aux_dir=
2737for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
2738  if test -f "$ac_dir/install-sh"; then
2739    ac_aux_dir=$ac_dir
2740    ac_install_sh="$ac_aux_dir/install-sh -c"
2741    break
2742  elif test -f "$ac_dir/install.sh"; then
2743    ac_aux_dir=$ac_dir
2744    ac_install_sh="$ac_aux_dir/install.sh -c"
2745    break
2746  elif test -f "$ac_dir/shtool"; then
2747    ac_aux_dir=$ac_dir
2748    ac_install_sh="$ac_aux_dir/shtool install -c"
2749    break
2750  fi
2751done
2752if test -z "$ac_aux_dir"; then
2753  { { echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&5
2754echo "$as_me: error: cannot find install-sh or install.sh in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" >&2;}
2755   { (exit 1); exit 1; }; }
2756fi
2757
2758# These three variables are undocumented and unsupported,
2759# and are intended to be withdrawn in a future Autoconf release.
2760# They can cause serious problems if a builder's source tree is in a directory
2761# whose full name contains unusual characters.
2762ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2763ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2764ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2765
2766
2767# Make sure we can run config.sub.
2768$SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2769  { { echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
2770echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
2771   { (exit 1); exit 1; }; }
2772
2773{ echo "$as_me:$LINENO: checking build system type" >&5
2774echo $ECHO_N "checking build system type... $ECHO_C" >&6; }
2775if test "${ac_cv_build+set}" = set; then
2776  echo $ECHO_N "(cached) $ECHO_C" >&6
2777else
2778  ac_build_alias=$build_alias
2779test "x$ac_build_alias" = x &&
2780  ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2781test "x$ac_build_alias" = x &&
2782  { { echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
2783echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
2784   { (exit 1); exit 1; }; }
2785ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2786  { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
2787echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
2788   { (exit 1); exit 1; }; }
2789
2790fi
2791{ echo "$as_me:$LINENO: result: $ac_cv_build" >&5
2792echo "${ECHO_T}$ac_cv_build" >&6; }
2793case $ac_cv_build in
2794*-*-*) ;;
2795*) { { echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
2796echo "$as_me: error: invalid value of canonical build" >&2;}
2797   { (exit 1); exit 1; }; };;
2798esac
2799build=$ac_cv_build
2800ac_save_IFS=$IFS; IFS='-'
2801set x $ac_cv_build
2802shift
2803build_cpu=$1
2804build_vendor=$2
2805shift; shift
2806# Remember, the first character of IFS is used to create $*,
2807# except with old shells:
2808build_os=$*
2809IFS=$ac_save_IFS
2810case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2811
2812
2813{ echo "$as_me:$LINENO: checking host system type" >&5
2814echo $ECHO_N "checking host system type... $ECHO_C" >&6; }
2815if test "${ac_cv_host+set}" = set; then
2816  echo $ECHO_N "(cached) $ECHO_C" >&6
2817else
2818  if test "x$host_alias" = x; then
2819  ac_cv_host=$ac_cv_build
2820else
2821  ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2822    { { echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
2823echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
2824   { (exit 1); exit 1; }; }
2825fi
2826
2827fi
2828{ echo "$as_me:$LINENO: result: $ac_cv_host" >&5
2829echo "${ECHO_T}$ac_cv_host" >&6; }
2830case $ac_cv_host in
2831*-*-*) ;;
2832*) { { echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
2833echo "$as_me: error: invalid value of canonical host" >&2;}
2834   { (exit 1); exit 1; }; };;
2835esac
2836host=$ac_cv_host
2837ac_save_IFS=$IFS; IFS='-'
2838set x $ac_cv_host
2839shift
2840host_cpu=$1
2841host_vendor=$2
2842shift; shift
2843# Remember, the first character of IFS is used to create $*,
2844# except with old shells:
2845host_os=$*
2846IFS=$ac_save_IFS
2847case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2848
2849
2850
2851ac_ext=c
2852ac_cpp='$CPP $CPPFLAGS'
2853ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2854ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2855ac_compiler_gnu=$ac_cv_c_compiler_gnu
2856{ echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
2857echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; }
2858# On Suns, sometimes $CPP names a directory.
2859if test -n "$CPP" && test -d "$CPP"; then
2860  CPP=
2861fi
2862if test -z "$CPP"; then
2863  if test "${ac_cv_prog_CPP+set}" = set; then
2864  echo $ECHO_N "(cached) $ECHO_C" >&6
2865else
2866      # Double quotes because CPP needs to be expanded
2867    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
2868    do
2869      ac_preproc_ok=false
2870for ac_c_preproc_warn_flag in '' yes
2871do
2872  # Use a header file that comes with gcc, so configuring glibc
2873  # with a fresh cross-compiler works.
2874  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2875  # <limits.h> exists even on freestanding compilers.
2876  # On the NeXT, cc -E runs the code through the compiler's parser,
2877  # not just through cpp. "Syntax error" is here to catch this case.
2878  cat >conftest.$ac_ext <<_ACEOF
2879/* confdefs.h.  */
2880_ACEOF
2881cat confdefs.h >>conftest.$ac_ext
2882cat >>conftest.$ac_ext <<_ACEOF
2883/* end confdefs.h.  */
2884#ifdef __STDC__
2885# include <limits.h>
2886#else
2887# include <assert.h>
2888#endif
2889		     Syntax error
2890_ACEOF
2891if { (ac_try="$ac_cpp conftest.$ac_ext"
2892case "(($ac_try" in
2893  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2894  *) ac_try_echo=$ac_try;;
2895esac
2896eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2897  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
2898  ac_status=$?
2899  grep -v '^ *+' conftest.er1 >conftest.err
2900  rm -f conftest.er1
2901  cat conftest.err >&5
2902  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2903  (exit $ac_status); } >/dev/null && {
2904	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2905	 test ! -s conftest.err
2906       }; then
2907  :
2908else
2909  echo "$as_me: failed program was:" >&5
2910sed 's/^/| /' conftest.$ac_ext >&5
2911
2912  # Broken: fails on valid input.
2913continue
2914fi
2915
2916rm -f conftest.err conftest.$ac_ext
2917
2918  # OK, works on sane cases.  Now check whether nonexistent headers
2919  # can be detected and how.
2920  cat >conftest.$ac_ext <<_ACEOF
2921/* confdefs.h.  */
2922_ACEOF
2923cat confdefs.h >>conftest.$ac_ext
2924cat >>conftest.$ac_ext <<_ACEOF
2925/* end confdefs.h.  */
2926#include <ac_nonexistent.h>
2927_ACEOF
2928if { (ac_try="$ac_cpp conftest.$ac_ext"
2929case "(($ac_try" in
2930  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2931  *) ac_try_echo=$ac_try;;
2932esac
2933eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
2934  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
2935  ac_status=$?
2936  grep -v '^ *+' conftest.er1 >conftest.err
2937  rm -f conftest.er1
2938  cat conftest.err >&5
2939  echo "$as_me:$LINENO: \$? = $ac_status" >&5
2940  (exit $ac_status); } >/dev/null && {
2941	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
2942	 test ! -s conftest.err
2943       }; then
2944  # Broken: success on invalid input.
2945continue
2946else
2947  echo "$as_me: failed program was:" >&5
2948sed 's/^/| /' conftest.$ac_ext >&5
2949
2950  # Passes both tests.
2951ac_preproc_ok=:
2952break
2953fi
2954
2955rm -f conftest.err conftest.$ac_ext
2956
2957done
2958# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
2959rm -f conftest.err conftest.$ac_ext
2960if $ac_preproc_ok; then
2961  break
2962fi
2963
2964    done
2965    ac_cv_prog_CPP=$CPP
2966
2967fi
2968  CPP=$ac_cv_prog_CPP
2969else
2970  ac_cv_prog_CPP=$CPP
2971fi
2972{ echo "$as_me:$LINENO: result: $CPP" >&5
2973echo "${ECHO_T}$CPP" >&6; }
2974ac_preproc_ok=false
2975for ac_c_preproc_warn_flag in '' yes
2976do
2977  # Use a header file that comes with gcc, so configuring glibc
2978  # with a fresh cross-compiler works.
2979  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
2980  # <limits.h> exists even on freestanding compilers.
2981  # On the NeXT, cc -E runs the code through the compiler's parser,
2982  # not just through cpp. "Syntax error" is here to catch this case.
2983  cat >conftest.$ac_ext <<_ACEOF
2984/* confdefs.h.  */
2985_ACEOF
2986cat confdefs.h >>conftest.$ac_ext
2987cat >>conftest.$ac_ext <<_ACEOF
2988/* end confdefs.h.  */
2989#ifdef __STDC__
2990# include <limits.h>
2991#else
2992# include <assert.h>
2993#endif
2994		     Syntax error
2995_ACEOF
2996if { (ac_try="$ac_cpp conftest.$ac_ext"
2997case "(($ac_try" in
2998  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
2999  *) ac_try_echo=$ac_try;;
3000esac
3001eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3002  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
3003  ac_status=$?
3004  grep -v '^ *+' conftest.er1 >conftest.err
3005  rm -f conftest.er1
3006  cat conftest.err >&5
3007  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3008  (exit $ac_status); } >/dev/null && {
3009	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3010	 test ! -s conftest.err
3011       }; then
3012  :
3013else
3014  echo "$as_me: failed program was:" >&5
3015sed 's/^/| /' conftest.$ac_ext >&5
3016
3017  # Broken: fails on valid input.
3018continue
3019fi
3020
3021rm -f conftest.err conftest.$ac_ext
3022
3023  # OK, works on sane cases.  Now check whether nonexistent headers
3024  # can be detected and how.
3025  cat >conftest.$ac_ext <<_ACEOF
3026/* confdefs.h.  */
3027_ACEOF
3028cat confdefs.h >>conftest.$ac_ext
3029cat >>conftest.$ac_ext <<_ACEOF
3030/* end confdefs.h.  */
3031#include <ac_nonexistent.h>
3032_ACEOF
3033if { (ac_try="$ac_cpp conftest.$ac_ext"
3034case "(($ac_try" in
3035  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3036  *) ac_try_echo=$ac_try;;
3037esac
3038eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3039  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
3040  ac_status=$?
3041  grep -v '^ *+' conftest.er1 >conftest.err
3042  rm -f conftest.er1
3043  cat conftest.err >&5
3044  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3045  (exit $ac_status); } >/dev/null && {
3046	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3047	 test ! -s conftest.err
3048       }; then
3049  # Broken: success on invalid input.
3050continue
3051else
3052  echo "$as_me: failed program was:" >&5
3053sed 's/^/| /' conftest.$ac_ext >&5
3054
3055  # Passes both tests.
3056ac_preproc_ok=:
3057break
3058fi
3059
3060rm -f conftest.err conftest.$ac_ext
3061
3062done
3063# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3064rm -f conftest.err conftest.$ac_ext
3065if $ac_preproc_ok; then
3066  :
3067else
3068  { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
3069See \`config.log' for more details." >&5
3070echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3071See \`config.log' for more details." >&2;}
3072   { (exit 1); exit 1; }; }
3073fi
3074
3075ac_ext=c
3076ac_cpp='$CPP $CPPFLAGS'
3077ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3078ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3079ac_compiler_gnu=$ac_cv_c_compiler_gnu
3080
3081
3082{ echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
3083echo $ECHO_N "checking for grep that handles long lines and -e... $ECHO_C" >&6; }
3084if test "${ac_cv_path_GREP+set}" = set; then
3085  echo $ECHO_N "(cached) $ECHO_C" >&6
3086else
3087  # Extract the first word of "grep ggrep" to use in msg output
3088if test -z "$GREP"; then
3089set dummy grep ggrep; ac_prog_name=$2
3090if test "${ac_cv_path_GREP+set}" = set; then
3091  echo $ECHO_N "(cached) $ECHO_C" >&6
3092else
3093  ac_path_GREP_found=false
3094# Loop through the user's path and test for each of PROGNAME-LIST
3095as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3096for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3097do
3098  IFS=$as_save_IFS
3099  test -z "$as_dir" && as_dir=.
3100  for ac_prog in grep ggrep; do
3101  for ac_exec_ext in '' $ac_executable_extensions; do
3102    ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
3103    { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
3104    # Check for GNU ac_path_GREP and select it if it is found.
3105  # Check for GNU $ac_path_GREP
3106case `"$ac_path_GREP" --version 2>&1` in
3107*GNU*)
3108  ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
3109*)
3110  ac_count=0
3111  echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
3112  while :
3113  do
3114    cat "conftest.in" "conftest.in" >"conftest.tmp"
3115    mv "conftest.tmp" "conftest.in"
3116    cp "conftest.in" "conftest.nl"
3117    echo 'GREP' >> "conftest.nl"
3118    "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3119    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3120    ac_count=`expr $ac_count + 1`
3121    if test $ac_count -gt ${ac_path_GREP_max-0}; then
3122      # Best one so far, save it but keep looking for a better one
3123      ac_cv_path_GREP="$ac_path_GREP"
3124      ac_path_GREP_max=$ac_count
3125    fi
3126    # 10*(2^10) chars as input seems more than enough
3127    test $ac_count -gt 10 && break
3128  done
3129  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3130esac
3131
3132
3133    $ac_path_GREP_found && break 3
3134  done
3135done
3136
3137done
3138IFS=$as_save_IFS
3139
3140
3141fi
3142
3143GREP="$ac_cv_path_GREP"
3144if test -z "$GREP"; then
3145  { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
3146echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
3147   { (exit 1); exit 1; }; }
3148fi
3149
3150else
3151  ac_cv_path_GREP=$GREP
3152fi
3153
3154
3155fi
3156{ echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
3157echo "${ECHO_T}$ac_cv_path_GREP" >&6; }
3158 GREP="$ac_cv_path_GREP"
3159
3160
3161{ echo "$as_me:$LINENO: checking for egrep" >&5
3162echo $ECHO_N "checking for egrep... $ECHO_C" >&6; }
3163if test "${ac_cv_path_EGREP+set}" = set; then
3164  echo $ECHO_N "(cached) $ECHO_C" >&6
3165else
3166  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
3167   then ac_cv_path_EGREP="$GREP -E"
3168   else
3169     # Extract the first word of "egrep" to use in msg output
3170if test -z "$EGREP"; then
3171set dummy egrep; ac_prog_name=$2
3172if test "${ac_cv_path_EGREP+set}" = set; then
3173  echo $ECHO_N "(cached) $ECHO_C" >&6
3174else
3175  ac_path_EGREP_found=false
3176# Loop through the user's path and test for each of PROGNAME-LIST
3177as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3178for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
3179do
3180  IFS=$as_save_IFS
3181  test -z "$as_dir" && as_dir=.
3182  for ac_prog in egrep; do
3183  for ac_exec_ext in '' $ac_executable_extensions; do
3184    ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
3185    { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
3186    # Check for GNU ac_path_EGREP and select it if it is found.
3187  # Check for GNU $ac_path_EGREP
3188case `"$ac_path_EGREP" --version 2>&1` in
3189*GNU*)
3190  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
3191*)
3192  ac_count=0
3193  echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
3194  while :
3195  do
3196    cat "conftest.in" "conftest.in" >"conftest.tmp"
3197    mv "conftest.tmp" "conftest.in"
3198    cp "conftest.in" "conftest.nl"
3199    echo 'EGREP' >> "conftest.nl"
3200    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
3201    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
3202    ac_count=`expr $ac_count + 1`
3203    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
3204      # Best one so far, save it but keep looking for a better one
3205      ac_cv_path_EGREP="$ac_path_EGREP"
3206      ac_path_EGREP_max=$ac_count
3207    fi
3208    # 10*(2^10) chars as input seems more than enough
3209    test $ac_count -gt 10 && break
3210  done
3211  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
3212esac
3213
3214
3215    $ac_path_EGREP_found && break 3
3216  done
3217done
3218
3219done
3220IFS=$as_save_IFS
3221
3222
3223fi
3224
3225EGREP="$ac_cv_path_EGREP"
3226if test -z "$EGREP"; then
3227  { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
3228echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
3229   { (exit 1); exit 1; }; }
3230fi
3231
3232else
3233  ac_cv_path_EGREP=$EGREP
3234fi
3235
3236
3237   fi
3238fi
3239{ echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
3240echo "${ECHO_T}$ac_cv_path_EGREP" >&6; }
3241 EGREP="$ac_cv_path_EGREP"
3242
3243
3244{ echo "$as_me:$LINENO: checking for ANSI C header files" >&5
3245echo $ECHO_N "checking for ANSI C header files... $ECHO_C" >&6; }
3246if test "${ac_cv_header_stdc+set}" = set; then
3247  echo $ECHO_N "(cached) $ECHO_C" >&6
3248else
3249  cat >conftest.$ac_ext <<_ACEOF
3250/* confdefs.h.  */
3251_ACEOF
3252cat confdefs.h >>conftest.$ac_ext
3253cat >>conftest.$ac_ext <<_ACEOF
3254/* end confdefs.h.  */
3255#include <stdlib.h>
3256#include <stdarg.h>
3257#include <string.h>
3258#include <float.h>
3259
3260int
3261main ()
3262{
3263
3264  ;
3265  return 0;
3266}
3267_ACEOF
3268rm -f conftest.$ac_objext
3269if { (ac_try="$ac_compile"
3270case "(($ac_try" in
3271  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3272  *) ac_try_echo=$ac_try;;
3273esac
3274eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3275  (eval "$ac_compile") 2>conftest.er1
3276  ac_status=$?
3277  grep -v '^ *+' conftest.er1 >conftest.err
3278  rm -f conftest.er1
3279  cat conftest.err >&5
3280  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3281  (exit $ac_status); } && {
3282	 test -z "$ac_c_werror_flag" ||
3283	 test ! -s conftest.err
3284       } && test -s conftest.$ac_objext; then
3285  ac_cv_header_stdc=yes
3286else
3287  echo "$as_me: failed program was:" >&5
3288sed 's/^/| /' conftest.$ac_ext >&5
3289
3290	ac_cv_header_stdc=no
3291fi
3292
3293rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3294
3295if test $ac_cv_header_stdc = yes; then
3296  # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
3297  cat >conftest.$ac_ext <<_ACEOF
3298/* confdefs.h.  */
3299_ACEOF
3300cat confdefs.h >>conftest.$ac_ext
3301cat >>conftest.$ac_ext <<_ACEOF
3302/* end confdefs.h.  */
3303#include <string.h>
3304
3305_ACEOF
3306if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3307  $EGREP "memchr" >/dev/null 2>&1; then
3308  :
3309else
3310  ac_cv_header_stdc=no
3311fi
3312rm -f conftest*
3313
3314fi
3315
3316if test $ac_cv_header_stdc = yes; then
3317  # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
3318  cat >conftest.$ac_ext <<_ACEOF
3319/* confdefs.h.  */
3320_ACEOF
3321cat confdefs.h >>conftest.$ac_ext
3322cat >>conftest.$ac_ext <<_ACEOF
3323/* end confdefs.h.  */
3324#include <stdlib.h>
3325
3326_ACEOF
3327if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
3328  $EGREP "free" >/dev/null 2>&1; then
3329  :
3330else
3331  ac_cv_header_stdc=no
3332fi
3333rm -f conftest*
3334
3335fi
3336
3337if test $ac_cv_header_stdc = yes; then
3338  # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
3339  if test "$cross_compiling" = yes; then
3340  :
3341else
3342  cat >conftest.$ac_ext <<_ACEOF
3343/* confdefs.h.  */
3344_ACEOF
3345cat confdefs.h >>conftest.$ac_ext
3346cat >>conftest.$ac_ext <<_ACEOF
3347/* end confdefs.h.  */
3348#include <ctype.h>
3349#include <stdlib.h>
3350#if ((' ' & 0x0FF) == 0x020)
3351# define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
3352# define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
3353#else
3354# define ISLOWER(c) \
3355		   (('a' <= (c) && (c) <= 'i') \
3356		     || ('j' <= (c) && (c) <= 'r') \
3357		     || ('s' <= (c) && (c) <= 'z'))
3358# define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
3359#endif
3360
3361#define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
3362int
3363main ()
3364{
3365  int i;
3366  for (i = 0; i < 256; i++)
3367    if (XOR (islower (i), ISLOWER (i))
3368	|| toupper (i) != TOUPPER (i))
3369      return 2;
3370  return 0;
3371}
3372_ACEOF
3373rm -f conftest$ac_exeext
3374if { (ac_try="$ac_link"
3375case "(($ac_try" in
3376  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3377  *) ac_try_echo=$ac_try;;
3378esac
3379eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3380  (eval "$ac_link") 2>&5
3381  ac_status=$?
3382  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3383  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3384  { (case "(($ac_try" in
3385  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3386  *) ac_try_echo=$ac_try;;
3387esac
3388eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3389  (eval "$ac_try") 2>&5
3390  ac_status=$?
3391  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3392  (exit $ac_status); }; }; then
3393  :
3394else
3395  echo "$as_me: program exited with status $ac_status" >&5
3396echo "$as_me: failed program was:" >&5
3397sed 's/^/| /' conftest.$ac_ext >&5
3398
3399( exit $ac_status )
3400ac_cv_header_stdc=no
3401fi
3402rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
3403fi
3404
3405
3406fi
3407fi
3408{ echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
3409echo "${ECHO_T}$ac_cv_header_stdc" >&6; }
3410if test $ac_cv_header_stdc = yes; then
3411
3412cat >>confdefs.h <<\_ACEOF
3413#define STDC_HEADERS 1
3414_ACEOF
3415
3416fi
3417
3418# On IRIX 5.3, sys/types and inttypes.h are conflicting.
3419
3420
3421
3422
3423
3424
3425
3426
3427
3428for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
3429		  inttypes.h stdint.h unistd.h
3430do
3431as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
3432{ echo "$as_me:$LINENO: checking for $ac_header" >&5
3433echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
3434if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
3435  echo $ECHO_N "(cached) $ECHO_C" >&6
3436else
3437  cat >conftest.$ac_ext <<_ACEOF
3438/* confdefs.h.  */
3439_ACEOF
3440cat confdefs.h >>conftest.$ac_ext
3441cat >>conftest.$ac_ext <<_ACEOF
3442/* end confdefs.h.  */
3443$ac_includes_default
3444
3445#include <$ac_header>
3446_ACEOF
3447rm -f conftest.$ac_objext
3448if { (ac_try="$ac_compile"
3449case "(($ac_try" in
3450  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3451  *) ac_try_echo=$ac_try;;
3452esac
3453eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3454  (eval "$ac_compile") 2>conftest.er1
3455  ac_status=$?
3456  grep -v '^ *+' conftest.er1 >conftest.err
3457  rm -f conftest.er1
3458  cat conftest.err >&5
3459  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3460  (exit $ac_status); } && {
3461	 test -z "$ac_c_werror_flag" ||
3462	 test ! -s conftest.err
3463       } && test -s conftest.$ac_objext; then
3464  eval "$as_ac_Header=yes"
3465else
3466  echo "$as_me: failed program was:" >&5
3467sed 's/^/| /' conftest.$ac_ext >&5
3468
3469	eval "$as_ac_Header=no"
3470fi
3471
3472rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3473fi
3474ac_res=`eval echo '${'$as_ac_Header'}'`
3475	       { echo "$as_me:$LINENO: result: $ac_res" >&5
3476echo "${ECHO_T}$ac_res" >&6; }
3477if test `eval echo '${'$as_ac_Header'}'` = yes; then
3478  cat >>confdefs.h <<_ACEOF
3479#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
3480_ACEOF
3481
3482fi
3483
3484done
3485
3486
3487{ echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
3488echo $ECHO_N "checking whether byte ordering is bigendian... $ECHO_C" >&6; }
3489if test "${ac_cv_c_bigendian+set}" = set; then
3490  echo $ECHO_N "(cached) $ECHO_C" >&6
3491else
3492  # See if sys/param.h defines the BYTE_ORDER macro.
3493cat >conftest.$ac_ext <<_ACEOF
3494/* confdefs.h.  */
3495_ACEOF
3496cat confdefs.h >>conftest.$ac_ext
3497cat >>conftest.$ac_ext <<_ACEOF
3498/* end confdefs.h.  */
3499#include <sys/types.h>
3500#include <sys/param.h>
3501
3502int
3503main ()
3504{
3505#if  ! (defined BYTE_ORDER && defined BIG_ENDIAN && defined LITTLE_ENDIAN \
3506	&& BYTE_ORDER && BIG_ENDIAN && LITTLE_ENDIAN)
3507 bogus endian macros
3508#endif
3509
3510  ;
3511  return 0;
3512}
3513_ACEOF
3514rm -f conftest.$ac_objext
3515if { (ac_try="$ac_compile"
3516case "(($ac_try" in
3517  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3518  *) ac_try_echo=$ac_try;;
3519esac
3520eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3521  (eval "$ac_compile") 2>conftest.er1
3522  ac_status=$?
3523  grep -v '^ *+' conftest.er1 >conftest.err
3524  rm -f conftest.er1
3525  cat conftest.err >&5
3526  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3527  (exit $ac_status); } && {
3528	 test -z "$ac_c_werror_flag" ||
3529	 test ! -s conftest.err
3530       } && test -s conftest.$ac_objext; then
3531  # It does; now see whether it defined to BIG_ENDIAN or not.
3532cat >conftest.$ac_ext <<_ACEOF
3533/* confdefs.h.  */
3534_ACEOF
3535cat confdefs.h >>conftest.$ac_ext
3536cat >>conftest.$ac_ext <<_ACEOF
3537/* end confdefs.h.  */
3538#include <sys/types.h>
3539#include <sys/param.h>
3540
3541int
3542main ()
3543{
3544#if BYTE_ORDER != BIG_ENDIAN
3545 not big endian
3546#endif
3547
3548  ;
3549  return 0;
3550}
3551_ACEOF
3552rm -f conftest.$ac_objext
3553if { (ac_try="$ac_compile"
3554case "(($ac_try" in
3555  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3556  *) ac_try_echo=$ac_try;;
3557esac
3558eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3559  (eval "$ac_compile") 2>conftest.er1
3560  ac_status=$?
3561  grep -v '^ *+' conftest.er1 >conftest.err
3562  rm -f conftest.er1
3563  cat conftest.err >&5
3564  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3565  (exit $ac_status); } && {
3566	 test -z "$ac_c_werror_flag" ||
3567	 test ! -s conftest.err
3568       } && test -s conftest.$ac_objext; then
3569  ac_cv_c_bigendian=yes
3570else
3571  echo "$as_me: failed program was:" >&5
3572sed 's/^/| /' conftest.$ac_ext >&5
3573
3574	ac_cv_c_bigendian=no
3575fi
3576
3577rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3578else
3579  echo "$as_me: failed program was:" >&5
3580sed 's/^/| /' conftest.$ac_ext >&5
3581
3582	# It does not; compile a test program.
3583if test "$cross_compiling" = yes; then
3584  # try to guess the endianness by grepping values into an object file
3585  ac_cv_c_bigendian=unknown
3586  cat >conftest.$ac_ext <<_ACEOF
3587/* confdefs.h.  */
3588_ACEOF
3589cat confdefs.h >>conftest.$ac_ext
3590cat >>conftest.$ac_ext <<_ACEOF
3591/* end confdefs.h.  */
3592short int ascii_mm[] = { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
3593short int ascii_ii[] = { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
3594void _ascii () { char *s = (char *) ascii_mm; s = (char *) ascii_ii; }
3595short int ebcdic_ii[] = { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
3596short int ebcdic_mm[] = { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
3597void _ebcdic () { char *s = (char *) ebcdic_mm; s = (char *) ebcdic_ii; }
3598int
3599main ()
3600{
3601 _ascii (); _ebcdic ();
3602  ;
3603  return 0;
3604}
3605_ACEOF
3606rm -f conftest.$ac_objext
3607if { (ac_try="$ac_compile"
3608case "(($ac_try" in
3609  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3610  *) ac_try_echo=$ac_try;;
3611esac
3612eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3613  (eval "$ac_compile") 2>conftest.er1
3614  ac_status=$?
3615  grep -v '^ *+' conftest.er1 >conftest.err
3616  rm -f conftest.er1
3617  cat conftest.err >&5
3618  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3619  (exit $ac_status); } && {
3620	 test -z "$ac_c_werror_flag" ||
3621	 test ! -s conftest.err
3622       } && test -s conftest.$ac_objext; then
3623  if grep BIGenDianSyS conftest.$ac_objext >/dev/null ; then
3624  ac_cv_c_bigendian=yes
3625fi
3626if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
3627  if test "$ac_cv_c_bigendian" = unknown; then
3628    ac_cv_c_bigendian=no
3629  else
3630    # finding both strings is unlikely to happen, but who knows?
3631    ac_cv_c_bigendian=unknown
3632  fi
3633fi
3634else
3635  echo "$as_me: failed program was:" >&5
3636sed 's/^/| /' conftest.$ac_ext >&5
3637
3638
3639fi
3640
3641rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3642else
3643  cat >conftest.$ac_ext <<_ACEOF
3644/* confdefs.h.  */
3645_ACEOF
3646cat confdefs.h >>conftest.$ac_ext
3647cat >>conftest.$ac_ext <<_ACEOF
3648/* end confdefs.h.  */
3649$ac_includes_default
3650int
3651main ()
3652{
3653
3654  /* Are we little or big endian?  From Harbison&Steele.  */
3655  union
3656  {
3657    long int l;
3658    char c[sizeof (long int)];
3659  } u;
3660  u.l = 1;
3661  return u.c[sizeof (long int) - 1] == 1;
3662
3663  ;
3664  return 0;
3665}
3666_ACEOF
3667rm -f conftest$ac_exeext
3668if { (ac_try="$ac_link"
3669case "(($ac_try" in
3670  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3671  *) ac_try_echo=$ac_try;;
3672esac
3673eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3674  (eval "$ac_link") 2>&5
3675  ac_status=$?
3676  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3677  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
3678  { (case "(($ac_try" in
3679  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3680  *) ac_try_echo=$ac_try;;
3681esac
3682eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3683  (eval "$ac_try") 2>&5
3684  ac_status=$?
3685  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3686  (exit $ac_status); }; }; then
3687  ac_cv_c_bigendian=no
3688else
3689  echo "$as_me: program exited with status $ac_status" >&5
3690echo "$as_me: failed program was:" >&5
3691sed 's/^/| /' conftest.$ac_ext >&5
3692
3693( exit $ac_status )
3694ac_cv_c_bigendian=yes
3695fi
3696rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
3697fi
3698
3699
3700fi
3701
3702rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3703fi
3704{ echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
3705echo "${ECHO_T}$ac_cv_c_bigendian" >&6; }
3706case $ac_cv_c_bigendian in
3707  yes)
3708
3709cat >>confdefs.h <<\_ACEOF
3710#define WORDS_BIGENDIAN 1
3711_ACEOF
3712 ;;
3713  no)
3714     ;;
3715  *)
3716    { { echo "$as_me:$LINENO: error: unknown endianness
3717presetting ac_cv_c_bigendian=no (or yes) will help" >&5
3718echo "$as_me: error: unknown endianness
3719presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
3720   { (exit 1); exit 1; }; } ;;
3721esac
3722
3723
3724# Checks for programs.
3725for ac_prog in gawk mawk nawk awk
3726do
3727  # Extract the first word of "$ac_prog", so it can be a program name with args.
3728set dummy $ac_prog; ac_word=$2
3729{ echo "$as_me:$LINENO: checking for $ac_word" >&5
3730echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
3731if test "${ac_cv_prog_AWK+set}" = set; then
3732  echo $ECHO_N "(cached) $ECHO_C" >&6
3733else
3734  if test -n "$AWK"; then
3735  ac_cv_prog_AWK="$AWK" # Let the user override the test.
3736else
3737as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3738for as_dir in $PATH
3739do
3740  IFS=$as_save_IFS
3741  test -z "$as_dir" && as_dir=.
3742  for ac_exec_ext in '' $ac_executable_extensions; do
3743  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3744    ac_cv_prog_AWK="$ac_prog"
3745    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3746    break 2
3747  fi
3748done
3749done
3750IFS=$as_save_IFS
3751
3752fi
3753fi
3754AWK=$ac_cv_prog_AWK
3755if test -n "$AWK"; then
3756  { echo "$as_me:$LINENO: result: $AWK" >&5
3757echo "${ECHO_T}$AWK" >&6; }
3758else
3759  { echo "$as_me:$LINENO: result: no" >&5
3760echo "${ECHO_T}no" >&6; }
3761fi
3762
3763
3764  test -n "$AWK" && break
3765done
3766
3767ac_ext=c
3768ac_cpp='$CPP $CPPFLAGS'
3769ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3770ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3771ac_compiler_gnu=$ac_cv_c_compiler_gnu
3772{ echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
3773echo $ECHO_N "checking how to run the C preprocessor... $ECHO_C" >&6; }
3774# On Suns, sometimes $CPP names a directory.
3775if test -n "$CPP" && test -d "$CPP"; then
3776  CPP=
3777fi
3778if test -z "$CPP"; then
3779  if test "${ac_cv_prog_CPP+set}" = set; then
3780  echo $ECHO_N "(cached) $ECHO_C" >&6
3781else
3782      # Double quotes because CPP needs to be expanded
3783    for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
3784    do
3785      ac_preproc_ok=false
3786for ac_c_preproc_warn_flag in '' yes
3787do
3788  # Use a header file that comes with gcc, so configuring glibc
3789  # with a fresh cross-compiler works.
3790  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3791  # <limits.h> exists even on freestanding compilers.
3792  # On the NeXT, cc -E runs the code through the compiler's parser,
3793  # not just through cpp. "Syntax error" is here to catch this case.
3794  cat >conftest.$ac_ext <<_ACEOF
3795/* confdefs.h.  */
3796_ACEOF
3797cat confdefs.h >>conftest.$ac_ext
3798cat >>conftest.$ac_ext <<_ACEOF
3799/* end confdefs.h.  */
3800#ifdef __STDC__
3801# include <limits.h>
3802#else
3803# include <assert.h>
3804#endif
3805		     Syntax error
3806_ACEOF
3807if { (ac_try="$ac_cpp conftest.$ac_ext"
3808case "(($ac_try" in
3809  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3810  *) ac_try_echo=$ac_try;;
3811esac
3812eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3813  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
3814  ac_status=$?
3815  grep -v '^ *+' conftest.er1 >conftest.err
3816  rm -f conftest.er1
3817  cat conftest.err >&5
3818  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3819  (exit $ac_status); } >/dev/null && {
3820	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3821	 test ! -s conftest.err
3822       }; then
3823  :
3824else
3825  echo "$as_me: failed program was:" >&5
3826sed 's/^/| /' conftest.$ac_ext >&5
3827
3828  # Broken: fails on valid input.
3829continue
3830fi
3831
3832rm -f conftest.err conftest.$ac_ext
3833
3834  # OK, works on sane cases.  Now check whether nonexistent headers
3835  # can be detected and how.
3836  cat >conftest.$ac_ext <<_ACEOF
3837/* confdefs.h.  */
3838_ACEOF
3839cat confdefs.h >>conftest.$ac_ext
3840cat >>conftest.$ac_ext <<_ACEOF
3841/* end confdefs.h.  */
3842#include <ac_nonexistent.h>
3843_ACEOF
3844if { (ac_try="$ac_cpp conftest.$ac_ext"
3845case "(($ac_try" in
3846  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3847  *) ac_try_echo=$ac_try;;
3848esac
3849eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3850  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
3851  ac_status=$?
3852  grep -v '^ *+' conftest.er1 >conftest.err
3853  rm -f conftest.er1
3854  cat conftest.err >&5
3855  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3856  (exit $ac_status); } >/dev/null && {
3857	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3858	 test ! -s conftest.err
3859       }; then
3860  # Broken: success on invalid input.
3861continue
3862else
3863  echo "$as_me: failed program was:" >&5
3864sed 's/^/| /' conftest.$ac_ext >&5
3865
3866  # Passes both tests.
3867ac_preproc_ok=:
3868break
3869fi
3870
3871rm -f conftest.err conftest.$ac_ext
3872
3873done
3874# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3875rm -f conftest.err conftest.$ac_ext
3876if $ac_preproc_ok; then
3877  break
3878fi
3879
3880    done
3881    ac_cv_prog_CPP=$CPP
3882
3883fi
3884  CPP=$ac_cv_prog_CPP
3885else
3886  ac_cv_prog_CPP=$CPP
3887fi
3888{ echo "$as_me:$LINENO: result: $CPP" >&5
3889echo "${ECHO_T}$CPP" >&6; }
3890ac_preproc_ok=false
3891for ac_c_preproc_warn_flag in '' yes
3892do
3893  # Use a header file that comes with gcc, so configuring glibc
3894  # with a fresh cross-compiler works.
3895  # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
3896  # <limits.h> exists even on freestanding compilers.
3897  # On the NeXT, cc -E runs the code through the compiler's parser,
3898  # not just through cpp. "Syntax error" is here to catch this case.
3899  cat >conftest.$ac_ext <<_ACEOF
3900/* confdefs.h.  */
3901_ACEOF
3902cat confdefs.h >>conftest.$ac_ext
3903cat >>conftest.$ac_ext <<_ACEOF
3904/* end confdefs.h.  */
3905#ifdef __STDC__
3906# include <limits.h>
3907#else
3908# include <assert.h>
3909#endif
3910		     Syntax error
3911_ACEOF
3912if { (ac_try="$ac_cpp conftest.$ac_ext"
3913case "(($ac_try" in
3914  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3915  *) ac_try_echo=$ac_try;;
3916esac
3917eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3918  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
3919  ac_status=$?
3920  grep -v '^ *+' conftest.er1 >conftest.err
3921  rm -f conftest.er1
3922  cat conftest.err >&5
3923  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3924  (exit $ac_status); } >/dev/null && {
3925	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3926	 test ! -s conftest.err
3927       }; then
3928  :
3929else
3930  echo "$as_me: failed program was:" >&5
3931sed 's/^/| /' conftest.$ac_ext >&5
3932
3933  # Broken: fails on valid input.
3934continue
3935fi
3936
3937rm -f conftest.err conftest.$ac_ext
3938
3939  # OK, works on sane cases.  Now check whether nonexistent headers
3940  # can be detected and how.
3941  cat >conftest.$ac_ext <<_ACEOF
3942/* confdefs.h.  */
3943_ACEOF
3944cat confdefs.h >>conftest.$ac_ext
3945cat >>conftest.$ac_ext <<_ACEOF
3946/* end confdefs.h.  */
3947#include <ac_nonexistent.h>
3948_ACEOF
3949if { (ac_try="$ac_cpp conftest.$ac_ext"
3950case "(($ac_try" in
3951  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3952  *) ac_try_echo=$ac_try;;
3953esac
3954eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
3955  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
3956  ac_status=$?
3957  grep -v '^ *+' conftest.er1 >conftest.err
3958  rm -f conftest.er1
3959  cat conftest.err >&5
3960  echo "$as_me:$LINENO: \$? = $ac_status" >&5
3961  (exit $ac_status); } >/dev/null && {
3962	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
3963	 test ! -s conftest.err
3964       }; then
3965  # Broken: success on invalid input.
3966continue
3967else
3968  echo "$as_me: failed program was:" >&5
3969sed 's/^/| /' conftest.$ac_ext >&5
3970
3971  # Passes both tests.
3972ac_preproc_ok=:
3973break
3974fi
3975
3976rm -f conftest.err conftest.$ac_ext
3977
3978done
3979# Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
3980rm -f conftest.err conftest.$ac_ext
3981if $ac_preproc_ok; then
3982  :
3983else
3984  { { echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
3985See \`config.log' for more details." >&5
3986echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
3987See \`config.log' for more details." >&2;}
3988   { (exit 1); exit 1; }; }
3989fi
3990
3991ac_ext=c
3992ac_cpp='$CPP $CPPFLAGS'
3993ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3994ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3995ac_compiler_gnu=$ac_cv_c_compiler_gnu
3996
3997if test -n "$ac_tool_prefix"; then
3998  # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
3999set dummy ${ac_tool_prefix}ranlib; ac_word=$2
4000{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4001echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4002if test "${ac_cv_prog_RANLIB+set}" = set; then
4003  echo $ECHO_N "(cached) $ECHO_C" >&6
4004else
4005  if test -n "$RANLIB"; then
4006  ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
4007else
4008as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4009for as_dir in $PATH
4010do
4011  IFS=$as_save_IFS
4012  test -z "$as_dir" && as_dir=.
4013  for ac_exec_ext in '' $ac_executable_extensions; do
4014  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4015    ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
4016    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4017    break 2
4018  fi
4019done
4020done
4021IFS=$as_save_IFS
4022
4023fi
4024fi
4025RANLIB=$ac_cv_prog_RANLIB
4026if test -n "$RANLIB"; then
4027  { echo "$as_me:$LINENO: result: $RANLIB" >&5
4028echo "${ECHO_T}$RANLIB" >&6; }
4029else
4030  { echo "$as_me:$LINENO: result: no" >&5
4031echo "${ECHO_T}no" >&6; }
4032fi
4033
4034
4035fi
4036if test -z "$ac_cv_prog_RANLIB"; then
4037  ac_ct_RANLIB=$RANLIB
4038  # Extract the first word of "ranlib", so it can be a program name with args.
4039set dummy ranlib; ac_word=$2
4040{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4041echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4042if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
4043  echo $ECHO_N "(cached) $ECHO_C" >&6
4044else
4045  if test -n "$ac_ct_RANLIB"; then
4046  ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
4047else
4048as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4049for as_dir in $PATH
4050do
4051  IFS=$as_save_IFS
4052  test -z "$as_dir" && as_dir=.
4053  for ac_exec_ext in '' $ac_executable_extensions; do
4054  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4055    ac_cv_prog_ac_ct_RANLIB="ranlib"
4056    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4057    break 2
4058  fi
4059done
4060done
4061IFS=$as_save_IFS
4062
4063fi
4064fi
4065ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
4066if test -n "$ac_ct_RANLIB"; then
4067  { echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
4068echo "${ECHO_T}$ac_ct_RANLIB" >&6; }
4069else
4070  { echo "$as_me:$LINENO: result: no" >&5
4071echo "${ECHO_T}no" >&6; }
4072fi
4073
4074  if test "x$ac_ct_RANLIB" = x; then
4075    RANLIB=":"
4076  else
4077    case $cross_compiling:$ac_tool_warned in
4078yes:)
4079{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
4080whose name does not start with the host triplet.  If you think this
4081configuration is useful to you, please write to autoconf@gnu.org." >&5
4082echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
4083whose name does not start with the host triplet.  If you think this
4084configuration is useful to you, please write to autoconf@gnu.org." >&2;}
4085ac_tool_warned=yes ;;
4086esac
4087    RANLIB=$ac_ct_RANLIB
4088  fi
4089else
4090  RANLIB="$ac_cv_prog_RANLIB"
4091fi
4092
4093# Find a good install program.  We prefer a C program (faster),
4094# so one script is as good as another.  But avoid the broken or
4095# incompatible versions:
4096# SysV /etc/install, /usr/sbin/install
4097# SunOS /usr/etc/install
4098# IRIX /sbin/install
4099# AIX /bin/install
4100# AmigaOS /C/install, which installs bootblocks on floppy discs
4101# AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag
4102# AFS /usr/afsws/bin/install, which mishandles nonexistent args
4103# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
4104# OS/2's system install, which has a completely different semantic
4105# ./install, which can be erroneously created by make from ./install.sh.
4106{ echo "$as_me:$LINENO: checking for a BSD-compatible install" >&5
4107echo $ECHO_N "checking for a BSD-compatible install... $ECHO_C" >&6; }
4108if test -z "$INSTALL"; then
4109if test "${ac_cv_path_install+set}" = set; then
4110  echo $ECHO_N "(cached) $ECHO_C" >&6
4111else
4112  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4113for as_dir in $PATH
4114do
4115  IFS=$as_save_IFS
4116  test -z "$as_dir" && as_dir=.
4117  # Account for people who put trailing slashes in PATH elements.
4118case $as_dir/ in
4119  ./ | .// | /cC/* | \
4120  /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \
4121  ?:\\/os2\\/install\\/* | ?:\\/OS2\\/INSTALL\\/* | \
4122  /usr/ucb/* ) ;;
4123  *)
4124    # OSF1 and SCO ODT 3.0 have their own names for install.
4125    # Don't use installbsd from OSF since it installs stuff as root
4126    # by default.
4127    for ac_prog in ginstall scoinst install; do
4128      for ac_exec_ext in '' $ac_executable_extensions; do
4129	if { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; }; then
4130	  if test $ac_prog = install &&
4131	    grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4132	    # AIX install.  It has an incompatible calling convention.
4133	    :
4134	  elif test $ac_prog = install &&
4135	    grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then
4136	    # program-specific install script used by HP pwplus--don't use.
4137	    :
4138	  else
4139	    ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c"
4140	    break 3
4141	  fi
4142	fi
4143      done
4144    done
4145    ;;
4146esac
4147done
4148IFS=$as_save_IFS
4149
4150
4151fi
4152  if test "${ac_cv_path_install+set}" = set; then
4153    INSTALL=$ac_cv_path_install
4154  else
4155    # As a last resort, use the slow shell script.  Don't cache a
4156    # value for INSTALL within a source directory, because that will
4157    # break other packages using the cache if that directory is
4158    # removed, or if the value is a relative name.
4159    INSTALL=$ac_install_sh
4160  fi
4161fi
4162{ echo "$as_me:$LINENO: result: $INSTALL" >&5
4163echo "${ECHO_T}$INSTALL" >&6; }
4164
4165# Use test -z because SunOS4 sh mishandles braces in ${var-val}.
4166# It thinks the first close brace ends the variable substitution.
4167test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}'
4168
4169test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}'
4170
4171test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
4172
4173{ echo "$as_me:$LINENO: checking for egrep" >&5
4174echo $ECHO_N "checking for egrep... $ECHO_C" >&6; }
4175if test "${ac_cv_path_EGREP+set}" = set; then
4176  echo $ECHO_N "(cached) $ECHO_C" >&6
4177else
4178  if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
4179   then ac_cv_path_EGREP="$GREP -E"
4180   else
4181     # Extract the first word of "egrep" to use in msg output
4182if test -z "$EGREP"; then
4183set dummy egrep; ac_prog_name=$2
4184if test "${ac_cv_path_EGREP+set}" = set; then
4185  echo $ECHO_N "(cached) $ECHO_C" >&6
4186else
4187  ac_path_EGREP_found=false
4188# Loop through the user's path and test for each of PROGNAME-LIST
4189as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4190for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
4191do
4192  IFS=$as_save_IFS
4193  test -z "$as_dir" && as_dir=.
4194  for ac_prog in egrep; do
4195  for ac_exec_ext in '' $ac_executable_extensions; do
4196    ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
4197    { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
4198    # Check for GNU ac_path_EGREP and select it if it is found.
4199  # Check for GNU $ac_path_EGREP
4200case `"$ac_path_EGREP" --version 2>&1` in
4201*GNU*)
4202  ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
4203*)
4204  ac_count=0
4205  echo $ECHO_N "0123456789$ECHO_C" >"conftest.in"
4206  while :
4207  do
4208    cat "conftest.in" "conftest.in" >"conftest.tmp"
4209    mv "conftest.tmp" "conftest.in"
4210    cp "conftest.in" "conftest.nl"
4211    echo 'EGREP' >> "conftest.nl"
4212    "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
4213    diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
4214    ac_count=`expr $ac_count + 1`
4215    if test $ac_count -gt ${ac_path_EGREP_max-0}; then
4216      # Best one so far, save it but keep looking for a better one
4217      ac_cv_path_EGREP="$ac_path_EGREP"
4218      ac_path_EGREP_max=$ac_count
4219    fi
4220    # 10*(2^10) chars as input seems more than enough
4221    test $ac_count -gt 10 && break
4222  done
4223  rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
4224esac
4225
4226
4227    $ac_path_EGREP_found && break 3
4228  done
4229done
4230
4231done
4232IFS=$as_save_IFS
4233
4234
4235fi
4236
4237EGREP="$ac_cv_path_EGREP"
4238if test -z "$EGREP"; then
4239  { { echo "$as_me:$LINENO: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
4240echo "$as_me: error: no acceptable $ac_prog_name could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
4241   { (exit 1); exit 1; }; }
4242fi
4243
4244else
4245  ac_cv_path_EGREP=$EGREP
4246fi
4247
4248
4249   fi
4250fi
4251{ echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
4252echo "${ECHO_T}$ac_cv_path_EGREP" >&6; }
4253 EGREP="$ac_cv_path_EGREP"
4254
4255
4256# Extract the first word of "ar", so it can be a program name with args.
4257set dummy ar; ac_word=$2
4258{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4259echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4260if test "${ac_cv_path_AR+set}" = set; then
4261  echo $ECHO_N "(cached) $ECHO_C" >&6
4262else
4263  case $AR in
4264  [\\/]* | ?:[\\/]*)
4265  ac_cv_path_AR="$AR" # Let the user override the test with a path.
4266  ;;
4267  *)
4268  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4269for as_dir in $PATH
4270do
4271  IFS=$as_save_IFS
4272  test -z "$as_dir" && as_dir=.
4273  for ac_exec_ext in '' $ac_executable_extensions; do
4274  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4275    ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext"
4276    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4277    break 2
4278  fi
4279done
4280done
4281IFS=$as_save_IFS
4282
4283  ;;
4284esac
4285fi
4286AR=$ac_cv_path_AR
4287if test -n "$AR"; then
4288  { echo "$as_me:$LINENO: result: $AR" >&5
4289echo "${ECHO_T}$AR" >&6; }
4290else
4291  { echo "$as_me:$LINENO: result: no" >&5
4292echo "${ECHO_T}no" >&6; }
4293fi
4294
4295
4296# Extract the first word of "cat", so it can be a program name with args.
4297set dummy cat; ac_word=$2
4298{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4299echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4300if test "${ac_cv_path_CAT+set}" = set; then
4301  echo $ECHO_N "(cached) $ECHO_C" >&6
4302else
4303  case $CAT in
4304  [\\/]* | ?:[\\/]*)
4305  ac_cv_path_CAT="$CAT" # Let the user override the test with a path.
4306  ;;
4307  *)
4308  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4309for as_dir in $PATH
4310do
4311  IFS=$as_save_IFS
4312  test -z "$as_dir" && as_dir=.
4313  for ac_exec_ext in '' $ac_executable_extensions; do
4314  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4315    ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext"
4316    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4317    break 2
4318  fi
4319done
4320done
4321IFS=$as_save_IFS
4322
4323  ;;
4324esac
4325fi
4326CAT=$ac_cv_path_CAT
4327if test -n "$CAT"; then
4328  { echo "$as_me:$LINENO: result: $CAT" >&5
4329echo "${ECHO_T}$CAT" >&6; }
4330else
4331  { echo "$as_me:$LINENO: result: no" >&5
4332echo "${ECHO_T}no" >&6; }
4333fi
4334
4335
4336# Extract the first word of "kill", so it can be a program name with args.
4337set dummy kill; ac_word=$2
4338{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4339echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4340if test "${ac_cv_path_KILL+set}" = set; then
4341  echo $ECHO_N "(cached) $ECHO_C" >&6
4342else
4343  case $KILL in
4344  [\\/]* | ?:[\\/]*)
4345  ac_cv_path_KILL="$KILL" # Let the user override the test with a path.
4346  ;;
4347  *)
4348  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4349for as_dir in $PATH
4350do
4351  IFS=$as_save_IFS
4352  test -z "$as_dir" && as_dir=.
4353  for ac_exec_ext in '' $ac_executable_extensions; do
4354  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4355    ac_cv_path_KILL="$as_dir/$ac_word$ac_exec_ext"
4356    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4357    break 2
4358  fi
4359done
4360done
4361IFS=$as_save_IFS
4362
4363  ;;
4364esac
4365fi
4366KILL=$ac_cv_path_KILL
4367if test -n "$KILL"; then
4368  { echo "$as_me:$LINENO: result: $KILL" >&5
4369echo "${ECHO_T}$KILL" >&6; }
4370else
4371  { echo "$as_me:$LINENO: result: no" >&5
4372echo "${ECHO_T}no" >&6; }
4373fi
4374
4375
4376for ac_prog in perl5 perl
4377do
4378  # Extract the first word of "$ac_prog", so it can be a program name with args.
4379set dummy $ac_prog; ac_word=$2
4380{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4381echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4382if test "${ac_cv_path_PERL+set}" = set; then
4383  echo $ECHO_N "(cached) $ECHO_C" >&6
4384else
4385  case $PERL in
4386  [\\/]* | ?:[\\/]*)
4387  ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
4388  ;;
4389  *)
4390  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4391for as_dir in $PATH
4392do
4393  IFS=$as_save_IFS
4394  test -z "$as_dir" && as_dir=.
4395  for ac_exec_ext in '' $ac_executable_extensions; do
4396  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4397    ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
4398    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4399    break 2
4400  fi
4401done
4402done
4403IFS=$as_save_IFS
4404
4405  ;;
4406esac
4407fi
4408PERL=$ac_cv_path_PERL
4409if test -n "$PERL"; then
4410  { echo "$as_me:$LINENO: result: $PERL" >&5
4411echo "${ECHO_T}$PERL" >&6; }
4412else
4413  { echo "$as_me:$LINENO: result: no" >&5
4414echo "${ECHO_T}no" >&6; }
4415fi
4416
4417
4418  test -n "$PERL" && break
4419done
4420
4421# Extract the first word of "sed", so it can be a program name with args.
4422set dummy sed; ac_word=$2
4423{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4424echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4425if test "${ac_cv_path_SED+set}" = set; then
4426  echo $ECHO_N "(cached) $ECHO_C" >&6
4427else
4428  case $SED in
4429  [\\/]* | ?:[\\/]*)
4430  ac_cv_path_SED="$SED" # Let the user override the test with a path.
4431  ;;
4432  *)
4433  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4434for as_dir in $PATH
4435do
4436  IFS=$as_save_IFS
4437  test -z "$as_dir" && as_dir=.
4438  for ac_exec_ext in '' $ac_executable_extensions; do
4439  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4440    ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext"
4441    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4442    break 2
4443  fi
4444done
4445done
4446IFS=$as_save_IFS
4447
4448  ;;
4449esac
4450fi
4451SED=$ac_cv_path_SED
4452if test -n "$SED"; then
4453  { echo "$as_me:$LINENO: result: $SED" >&5
4454echo "${ECHO_T}$SED" >&6; }
4455else
4456  { echo "$as_me:$LINENO: result: no" >&5
4457echo "${ECHO_T}no" >&6; }
4458fi
4459
4460
4461
4462# Extract the first word of "ent", so it can be a program name with args.
4463set dummy ent; ac_word=$2
4464{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4465echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4466if test "${ac_cv_path_ENT+set}" = set; then
4467  echo $ECHO_N "(cached) $ECHO_C" >&6
4468else
4469  case $ENT in
4470  [\\/]* | ?:[\\/]*)
4471  ac_cv_path_ENT="$ENT" # Let the user override the test with a path.
4472  ;;
4473  *)
4474  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4475for as_dir in $PATH
4476do
4477  IFS=$as_save_IFS
4478  test -z "$as_dir" && as_dir=.
4479  for ac_exec_ext in '' $ac_executable_extensions; do
4480  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4481    ac_cv_path_ENT="$as_dir/$ac_word$ac_exec_ext"
4482    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4483    break 2
4484  fi
4485done
4486done
4487IFS=$as_save_IFS
4488
4489  ;;
4490esac
4491fi
4492ENT=$ac_cv_path_ENT
4493if test -n "$ENT"; then
4494  { echo "$as_me:$LINENO: result: $ENT" >&5
4495echo "${ECHO_T}$ENT" >&6; }
4496else
4497  { echo "$as_me:$LINENO: result: no" >&5
4498echo "${ECHO_T}no" >&6; }
4499fi
4500
4501
4502
4503# Extract the first word of "bash", so it can be a program name with args.
4504set dummy bash; ac_word=$2
4505{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4506echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4507if test "${ac_cv_path_TEST_MINUS_S_SH+set}" = set; then
4508  echo $ECHO_N "(cached) $ECHO_C" >&6
4509else
4510  case $TEST_MINUS_S_SH in
4511  [\\/]* | ?:[\\/]*)
4512  ac_cv_path_TEST_MINUS_S_SH="$TEST_MINUS_S_SH" # Let the user override the test with a path.
4513  ;;
4514  *)
4515  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4516for as_dir in $PATH
4517do
4518  IFS=$as_save_IFS
4519  test -z "$as_dir" && as_dir=.
4520  for ac_exec_ext in '' $ac_executable_extensions; do
4521  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4522    ac_cv_path_TEST_MINUS_S_SH="$as_dir/$ac_word$ac_exec_ext"
4523    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4524    break 2
4525  fi
4526done
4527done
4528IFS=$as_save_IFS
4529
4530  ;;
4531esac
4532fi
4533TEST_MINUS_S_SH=$ac_cv_path_TEST_MINUS_S_SH
4534if test -n "$TEST_MINUS_S_SH"; then
4535  { echo "$as_me:$LINENO: result: $TEST_MINUS_S_SH" >&5
4536echo "${ECHO_T}$TEST_MINUS_S_SH" >&6; }
4537else
4538  { echo "$as_me:$LINENO: result: no" >&5
4539echo "${ECHO_T}no" >&6; }
4540fi
4541
4542
4543# Extract the first word of "ksh", so it can be a program name with args.
4544set dummy ksh; ac_word=$2
4545{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4546echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4547if test "${ac_cv_path_TEST_MINUS_S_SH+set}" = set; then
4548  echo $ECHO_N "(cached) $ECHO_C" >&6
4549else
4550  case $TEST_MINUS_S_SH in
4551  [\\/]* | ?:[\\/]*)
4552  ac_cv_path_TEST_MINUS_S_SH="$TEST_MINUS_S_SH" # Let the user override the test with a path.
4553  ;;
4554  *)
4555  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4556for as_dir in $PATH
4557do
4558  IFS=$as_save_IFS
4559  test -z "$as_dir" && as_dir=.
4560  for ac_exec_ext in '' $ac_executable_extensions; do
4561  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4562    ac_cv_path_TEST_MINUS_S_SH="$as_dir/$ac_word$ac_exec_ext"
4563    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4564    break 2
4565  fi
4566done
4567done
4568IFS=$as_save_IFS
4569
4570  ;;
4571esac
4572fi
4573TEST_MINUS_S_SH=$ac_cv_path_TEST_MINUS_S_SH
4574if test -n "$TEST_MINUS_S_SH"; then
4575  { echo "$as_me:$LINENO: result: $TEST_MINUS_S_SH" >&5
4576echo "${ECHO_T}$TEST_MINUS_S_SH" >&6; }
4577else
4578  { echo "$as_me:$LINENO: result: no" >&5
4579echo "${ECHO_T}no" >&6; }
4580fi
4581
4582
4583# Extract the first word of "sh", so it can be a program name with args.
4584set dummy sh; ac_word=$2
4585{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4586echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4587if test "${ac_cv_path_TEST_MINUS_S_SH+set}" = set; then
4588  echo $ECHO_N "(cached) $ECHO_C" >&6
4589else
4590  case $TEST_MINUS_S_SH in
4591  [\\/]* | ?:[\\/]*)
4592  ac_cv_path_TEST_MINUS_S_SH="$TEST_MINUS_S_SH" # Let the user override the test with a path.
4593  ;;
4594  *)
4595  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4596for as_dir in $PATH
4597do
4598  IFS=$as_save_IFS
4599  test -z "$as_dir" && as_dir=.
4600  for ac_exec_ext in '' $ac_executable_extensions; do
4601  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4602    ac_cv_path_TEST_MINUS_S_SH="$as_dir/$ac_word$ac_exec_ext"
4603    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4604    break 2
4605  fi
4606done
4607done
4608IFS=$as_save_IFS
4609
4610  ;;
4611esac
4612fi
4613TEST_MINUS_S_SH=$ac_cv_path_TEST_MINUS_S_SH
4614if test -n "$TEST_MINUS_S_SH"; then
4615  { echo "$as_me:$LINENO: result: $TEST_MINUS_S_SH" >&5
4616echo "${ECHO_T}$TEST_MINUS_S_SH" >&6; }
4617else
4618  { echo "$as_me:$LINENO: result: no" >&5
4619echo "${ECHO_T}no" >&6; }
4620fi
4621
4622
4623# Extract the first word of "sh", so it can be a program name with args.
4624set dummy sh; ac_word=$2
4625{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4626echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4627if test "${ac_cv_path_SH+set}" = set; then
4628  echo $ECHO_N "(cached) $ECHO_C" >&6
4629else
4630  case $SH in
4631  [\\/]* | ?:[\\/]*)
4632  ac_cv_path_SH="$SH" # Let the user override the test with a path.
4633  ;;
4634  *)
4635  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4636for as_dir in $PATH
4637do
4638  IFS=$as_save_IFS
4639  test -z "$as_dir" && as_dir=.
4640  for ac_exec_ext in '' $ac_executable_extensions; do
4641  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4642    ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext"
4643    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4644    break 2
4645  fi
4646done
4647done
4648IFS=$as_save_IFS
4649
4650  ;;
4651esac
4652fi
4653SH=$ac_cv_path_SH
4654if test -n "$SH"; then
4655  { echo "$as_me:$LINENO: result: $SH" >&5
4656echo "${ECHO_T}$SH" >&6; }
4657else
4658  { echo "$as_me:$LINENO: result: no" >&5
4659echo "${ECHO_T}no" >&6; }
4660fi
4661
4662
4663# Extract the first word of "groff", so it can be a program name with args.
4664set dummy groff; ac_word=$2
4665{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4666echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4667if test "${ac_cv_path_GROFF+set}" = set; then
4668  echo $ECHO_N "(cached) $ECHO_C" >&6
4669else
4670  case $GROFF in
4671  [\\/]* | ?:[\\/]*)
4672  ac_cv_path_GROFF="$GROFF" # Let the user override the test with a path.
4673  ;;
4674  *)
4675  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4676for as_dir in $PATH
4677do
4678  IFS=$as_save_IFS
4679  test -z "$as_dir" && as_dir=.
4680  for ac_exec_ext in '' $ac_executable_extensions; do
4681  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4682    ac_cv_path_GROFF="$as_dir/$ac_word$ac_exec_ext"
4683    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4684    break 2
4685  fi
4686done
4687done
4688IFS=$as_save_IFS
4689
4690  ;;
4691esac
4692fi
4693GROFF=$ac_cv_path_GROFF
4694if test -n "$GROFF"; then
4695  { echo "$as_me:$LINENO: result: $GROFF" >&5
4696echo "${ECHO_T}$GROFF" >&6; }
4697else
4698  { echo "$as_me:$LINENO: result: no" >&5
4699echo "${ECHO_T}no" >&6; }
4700fi
4701
4702
4703# Extract the first word of "nroff", so it can be a program name with args.
4704set dummy nroff; ac_word=$2
4705{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4706echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4707if test "${ac_cv_path_NROFF+set}" = set; then
4708  echo $ECHO_N "(cached) $ECHO_C" >&6
4709else
4710  case $NROFF in
4711  [\\/]* | ?:[\\/]*)
4712  ac_cv_path_NROFF="$NROFF" # Let the user override the test with a path.
4713  ;;
4714  *)
4715  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4716for as_dir in $PATH
4717do
4718  IFS=$as_save_IFS
4719  test -z "$as_dir" && as_dir=.
4720  for ac_exec_ext in '' $ac_executable_extensions; do
4721  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4722    ac_cv_path_NROFF="$as_dir/$ac_word$ac_exec_ext"
4723    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4724    break 2
4725  fi
4726done
4727done
4728IFS=$as_save_IFS
4729
4730  ;;
4731esac
4732fi
4733NROFF=$ac_cv_path_NROFF
4734if test -n "$NROFF"; then
4735  { echo "$as_me:$LINENO: result: $NROFF" >&5
4736echo "${ECHO_T}$NROFF" >&6; }
4737else
4738  { echo "$as_me:$LINENO: result: no" >&5
4739echo "${ECHO_T}no" >&6; }
4740fi
4741
4742
4743# Extract the first word of "mandoc", so it can be a program name with args.
4744set dummy mandoc; ac_word=$2
4745{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4746echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4747if test "${ac_cv_path_MANDOC+set}" = set; then
4748  echo $ECHO_N "(cached) $ECHO_C" >&6
4749else
4750  case $MANDOC in
4751  [\\/]* | ?:[\\/]*)
4752  ac_cv_path_MANDOC="$MANDOC" # Let the user override the test with a path.
4753  ;;
4754  *)
4755  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4756for as_dir in $PATH
4757do
4758  IFS=$as_save_IFS
4759  test -z "$as_dir" && as_dir=.
4760  for ac_exec_ext in '' $ac_executable_extensions; do
4761  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4762    ac_cv_path_MANDOC="$as_dir/$ac_word$ac_exec_ext"
4763    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4764    break 2
4765  fi
4766done
4767done
4768IFS=$as_save_IFS
4769
4770  ;;
4771esac
4772fi
4773MANDOC=$ac_cv_path_MANDOC
4774if test -n "$MANDOC"; then
4775  { echo "$as_me:$LINENO: result: $MANDOC" >&5
4776echo "${ECHO_T}$MANDOC" >&6; }
4777else
4778  { echo "$as_me:$LINENO: result: no" >&5
4779echo "${ECHO_T}no" >&6; }
4780fi
4781
4782
4783TEST_SHELL=sh
4784
4785
4786if test "x$MANDOC" != "x" ; then
4787	MANFMT="$MANDOC"
4788elif test "x$NROFF" != "x" ; then
4789	MANFMT="$NROFF -mandoc"
4790elif test "x$GROFF" != "x" ; then
4791	MANFMT="$GROFF -mandoc -Tascii"
4792else
4793	{ echo "$as_me:$LINENO: WARNING: no manpage formatted found" >&5
4794echo "$as_me: WARNING: no manpage formatted found" >&2;}
4795	MANFMT="false"
4796fi
4797
4798
4799# Extract the first word of "groupadd", so it can be a program name with args.
4800set dummy groupadd; ac_word=$2
4801{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4802echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4803if test "${ac_cv_path_PATH_GROUPADD_PROG+set}" = set; then
4804  echo $ECHO_N "(cached) $ECHO_C" >&6
4805else
4806  case $PATH_GROUPADD_PROG in
4807  [\\/]* | ?:[\\/]*)
4808  ac_cv_path_PATH_GROUPADD_PROG="$PATH_GROUPADD_PROG" # Let the user override the test with a path.
4809  ;;
4810  *)
4811  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4812for as_dir in /usr/sbin${PATH_SEPARATOR}/etc
4813do
4814  IFS=$as_save_IFS
4815  test -z "$as_dir" && as_dir=.
4816  for ac_exec_ext in '' $ac_executable_extensions; do
4817  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4818    ac_cv_path_PATH_GROUPADD_PROG="$as_dir/$ac_word$ac_exec_ext"
4819    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4820    break 2
4821  fi
4822done
4823done
4824IFS=$as_save_IFS
4825
4826  test -z "$ac_cv_path_PATH_GROUPADD_PROG" && ac_cv_path_PATH_GROUPADD_PROG="groupadd"
4827  ;;
4828esac
4829fi
4830PATH_GROUPADD_PROG=$ac_cv_path_PATH_GROUPADD_PROG
4831if test -n "$PATH_GROUPADD_PROG"; then
4832  { echo "$as_me:$LINENO: result: $PATH_GROUPADD_PROG" >&5
4833echo "${ECHO_T}$PATH_GROUPADD_PROG" >&6; }
4834else
4835  { echo "$as_me:$LINENO: result: no" >&5
4836echo "${ECHO_T}no" >&6; }
4837fi
4838
4839
4840# Extract the first word of "useradd", so it can be a program name with args.
4841set dummy useradd; ac_word=$2
4842{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4843echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4844if test "${ac_cv_path_PATH_USERADD_PROG+set}" = set; then
4845  echo $ECHO_N "(cached) $ECHO_C" >&6
4846else
4847  case $PATH_USERADD_PROG in
4848  [\\/]* | ?:[\\/]*)
4849  ac_cv_path_PATH_USERADD_PROG="$PATH_USERADD_PROG" # Let the user override the test with a path.
4850  ;;
4851  *)
4852  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4853for as_dir in /usr/sbin${PATH_SEPARATOR}/etc
4854do
4855  IFS=$as_save_IFS
4856  test -z "$as_dir" && as_dir=.
4857  for ac_exec_ext in '' $ac_executable_extensions; do
4858  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4859    ac_cv_path_PATH_USERADD_PROG="$as_dir/$ac_word$ac_exec_ext"
4860    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4861    break 2
4862  fi
4863done
4864done
4865IFS=$as_save_IFS
4866
4867  test -z "$ac_cv_path_PATH_USERADD_PROG" && ac_cv_path_PATH_USERADD_PROG="useradd"
4868  ;;
4869esac
4870fi
4871PATH_USERADD_PROG=$ac_cv_path_PATH_USERADD_PROG
4872if test -n "$PATH_USERADD_PROG"; then
4873  { echo "$as_me:$LINENO: result: $PATH_USERADD_PROG" >&5
4874echo "${ECHO_T}$PATH_USERADD_PROG" >&6; }
4875else
4876  { echo "$as_me:$LINENO: result: no" >&5
4877echo "${ECHO_T}no" >&6; }
4878fi
4879
4880
4881# Extract the first word of "pkgmk", so it can be a program name with args.
4882set dummy pkgmk; ac_word=$2
4883{ echo "$as_me:$LINENO: checking for $ac_word" >&5
4884echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
4885if test "${ac_cv_prog_MAKE_PACKAGE_SUPPORTED+set}" = set; then
4886  echo $ECHO_N "(cached) $ECHO_C" >&6
4887else
4888  if test -n "$MAKE_PACKAGE_SUPPORTED"; then
4889  ac_cv_prog_MAKE_PACKAGE_SUPPORTED="$MAKE_PACKAGE_SUPPORTED" # Let the user override the test.
4890else
4891as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4892for as_dir in $PATH
4893do
4894  IFS=$as_save_IFS
4895  test -z "$as_dir" && as_dir=.
4896  for ac_exec_ext in '' $ac_executable_extensions; do
4897  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
4898    ac_cv_prog_MAKE_PACKAGE_SUPPORTED="yes"
4899    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
4900    break 2
4901  fi
4902done
4903done
4904IFS=$as_save_IFS
4905
4906  test -z "$ac_cv_prog_MAKE_PACKAGE_SUPPORTED" && ac_cv_prog_MAKE_PACKAGE_SUPPORTED="no"
4907fi
4908fi
4909MAKE_PACKAGE_SUPPORTED=$ac_cv_prog_MAKE_PACKAGE_SUPPORTED
4910if test -n "$MAKE_PACKAGE_SUPPORTED"; then
4911  { echo "$as_me:$LINENO: result: $MAKE_PACKAGE_SUPPORTED" >&5
4912echo "${ECHO_T}$MAKE_PACKAGE_SUPPORTED" >&6; }
4913else
4914  { echo "$as_me:$LINENO: result: no" >&5
4915echo "${ECHO_T}no" >&6; }
4916fi
4917
4918
4919if test -x /sbin/sh; then
4920	STARTUP_SCRIPT_SHELL=/sbin/sh
4921
4922else
4923	STARTUP_SCRIPT_SHELL=/bin/sh
4924
4925fi
4926
4927# System features
4928# Check whether --enable-largefile was given.
4929if test "${enable_largefile+set}" = set; then
4930  enableval=$enable_largefile;
4931fi
4932
4933if test "$enable_largefile" != no; then
4934
4935  { echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
4936echo $ECHO_N "checking for special C compiler options needed for large files... $ECHO_C" >&6; }
4937if test "${ac_cv_sys_largefile_CC+set}" = set; then
4938  echo $ECHO_N "(cached) $ECHO_C" >&6
4939else
4940  ac_cv_sys_largefile_CC=no
4941     if test "$GCC" != yes; then
4942       ac_save_CC=$CC
4943       while :; do
4944	 # IRIX 6.2 and later do not support large files by default,
4945	 # so use the C compiler's -n32 option if that helps.
4946	 cat >conftest.$ac_ext <<_ACEOF
4947/* confdefs.h.  */
4948_ACEOF
4949cat confdefs.h >>conftest.$ac_ext
4950cat >>conftest.$ac_ext <<_ACEOF
4951/* end confdefs.h.  */
4952#include <sys/types.h>
4953 /* Check that off_t can represent 2**63 - 1 correctly.
4954    We can't simply define LARGE_OFF_T to be 9223372036854775807,
4955    since some C++ compilers masquerading as C compilers
4956    incorrectly reject 9223372036854775807.  */
4957#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
4958  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
4959		       && LARGE_OFF_T % 2147483647 == 1)
4960		      ? 1 : -1];
4961int
4962main ()
4963{
4964
4965  ;
4966  return 0;
4967}
4968_ACEOF
4969	 rm -f conftest.$ac_objext
4970if { (ac_try="$ac_compile"
4971case "(($ac_try" in
4972  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4973  *) ac_try_echo=$ac_try;;
4974esac
4975eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
4976  (eval "$ac_compile") 2>conftest.er1
4977  ac_status=$?
4978  grep -v '^ *+' conftest.er1 >conftest.err
4979  rm -f conftest.er1
4980  cat conftest.err >&5
4981  echo "$as_me:$LINENO: \$? = $ac_status" >&5
4982  (exit $ac_status); } && {
4983	 test -z "$ac_c_werror_flag" ||
4984	 test ! -s conftest.err
4985       } && test -s conftest.$ac_objext; then
4986  break
4987else
4988  echo "$as_me: failed program was:" >&5
4989sed 's/^/| /' conftest.$ac_ext >&5
4990
4991
4992fi
4993
4994rm -f core conftest.err conftest.$ac_objext
4995	 CC="$CC -n32"
4996	 rm -f conftest.$ac_objext
4997if { (ac_try="$ac_compile"
4998case "(($ac_try" in
4999  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5000  *) ac_try_echo=$ac_try;;
5001esac
5002eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5003  (eval "$ac_compile") 2>conftest.er1
5004  ac_status=$?
5005  grep -v '^ *+' conftest.er1 >conftest.err
5006  rm -f conftest.er1
5007  cat conftest.err >&5
5008  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5009  (exit $ac_status); } && {
5010	 test -z "$ac_c_werror_flag" ||
5011	 test ! -s conftest.err
5012       } && test -s conftest.$ac_objext; then
5013  ac_cv_sys_largefile_CC=' -n32'; break
5014else
5015  echo "$as_me: failed program was:" >&5
5016sed 's/^/| /' conftest.$ac_ext >&5
5017
5018
5019fi
5020
5021rm -f core conftest.err conftest.$ac_objext
5022	 break
5023       done
5024       CC=$ac_save_CC
5025       rm -f conftest.$ac_ext
5026    fi
5027fi
5028{ echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
5029echo "${ECHO_T}$ac_cv_sys_largefile_CC" >&6; }
5030  if test "$ac_cv_sys_largefile_CC" != no; then
5031    CC=$CC$ac_cv_sys_largefile_CC
5032  fi
5033
5034  { echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
5035echo $ECHO_N "checking for _FILE_OFFSET_BITS value needed for large files... $ECHO_C" >&6; }
5036if test "${ac_cv_sys_file_offset_bits+set}" = set; then
5037  echo $ECHO_N "(cached) $ECHO_C" >&6
5038else
5039  while :; do
5040  cat >conftest.$ac_ext <<_ACEOF
5041/* confdefs.h.  */
5042_ACEOF
5043cat confdefs.h >>conftest.$ac_ext
5044cat >>conftest.$ac_ext <<_ACEOF
5045/* end confdefs.h.  */
5046#include <sys/types.h>
5047 /* Check that off_t can represent 2**63 - 1 correctly.
5048    We can't simply define LARGE_OFF_T to be 9223372036854775807,
5049    since some C++ compilers masquerading as C compilers
5050    incorrectly reject 9223372036854775807.  */
5051#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5052  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5053		       && LARGE_OFF_T % 2147483647 == 1)
5054		      ? 1 : -1];
5055int
5056main ()
5057{
5058
5059  ;
5060  return 0;
5061}
5062_ACEOF
5063rm -f conftest.$ac_objext
5064if { (ac_try="$ac_compile"
5065case "(($ac_try" in
5066  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5067  *) ac_try_echo=$ac_try;;
5068esac
5069eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5070  (eval "$ac_compile") 2>conftest.er1
5071  ac_status=$?
5072  grep -v '^ *+' conftest.er1 >conftest.err
5073  rm -f conftest.er1
5074  cat conftest.err >&5
5075  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5076  (exit $ac_status); } && {
5077	 test -z "$ac_c_werror_flag" ||
5078	 test ! -s conftest.err
5079       } && test -s conftest.$ac_objext; then
5080  ac_cv_sys_file_offset_bits=no; break
5081else
5082  echo "$as_me: failed program was:" >&5
5083sed 's/^/| /' conftest.$ac_ext >&5
5084
5085
5086fi
5087
5088rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5089  cat >conftest.$ac_ext <<_ACEOF
5090/* confdefs.h.  */
5091_ACEOF
5092cat confdefs.h >>conftest.$ac_ext
5093cat >>conftest.$ac_ext <<_ACEOF
5094/* end confdefs.h.  */
5095#define _FILE_OFFSET_BITS 64
5096#include <sys/types.h>
5097 /* Check that off_t can represent 2**63 - 1 correctly.
5098    We can't simply define LARGE_OFF_T to be 9223372036854775807,
5099    since some C++ compilers masquerading as C compilers
5100    incorrectly reject 9223372036854775807.  */
5101#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5102  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5103		       && LARGE_OFF_T % 2147483647 == 1)
5104		      ? 1 : -1];
5105int
5106main ()
5107{
5108
5109  ;
5110  return 0;
5111}
5112_ACEOF
5113rm -f conftest.$ac_objext
5114if { (ac_try="$ac_compile"
5115case "(($ac_try" in
5116  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5117  *) ac_try_echo=$ac_try;;
5118esac
5119eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5120  (eval "$ac_compile") 2>conftest.er1
5121  ac_status=$?
5122  grep -v '^ *+' conftest.er1 >conftest.err
5123  rm -f conftest.er1
5124  cat conftest.err >&5
5125  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5126  (exit $ac_status); } && {
5127	 test -z "$ac_c_werror_flag" ||
5128	 test ! -s conftest.err
5129       } && test -s conftest.$ac_objext; then
5130  ac_cv_sys_file_offset_bits=64; break
5131else
5132  echo "$as_me: failed program was:" >&5
5133sed 's/^/| /' conftest.$ac_ext >&5
5134
5135
5136fi
5137
5138rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5139  ac_cv_sys_file_offset_bits=unknown
5140  break
5141done
5142fi
5143{ echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
5144echo "${ECHO_T}$ac_cv_sys_file_offset_bits" >&6; }
5145case $ac_cv_sys_file_offset_bits in #(
5146  no | unknown) ;;
5147  *)
5148cat >>confdefs.h <<_ACEOF
5149#define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
5150_ACEOF
5151;;
5152esac
5153rm -f conftest*
5154  if test $ac_cv_sys_file_offset_bits = unknown; then
5155    { echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
5156echo $ECHO_N "checking for _LARGE_FILES value needed for large files... $ECHO_C" >&6; }
5157if test "${ac_cv_sys_large_files+set}" = set; then
5158  echo $ECHO_N "(cached) $ECHO_C" >&6
5159else
5160  while :; do
5161  cat >conftest.$ac_ext <<_ACEOF
5162/* confdefs.h.  */
5163_ACEOF
5164cat confdefs.h >>conftest.$ac_ext
5165cat >>conftest.$ac_ext <<_ACEOF
5166/* end confdefs.h.  */
5167#include <sys/types.h>
5168 /* Check that off_t can represent 2**63 - 1 correctly.
5169    We can't simply define LARGE_OFF_T to be 9223372036854775807,
5170    since some C++ compilers masquerading as C compilers
5171    incorrectly reject 9223372036854775807.  */
5172#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5173  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5174		       && LARGE_OFF_T % 2147483647 == 1)
5175		      ? 1 : -1];
5176int
5177main ()
5178{
5179
5180  ;
5181  return 0;
5182}
5183_ACEOF
5184rm -f conftest.$ac_objext
5185if { (ac_try="$ac_compile"
5186case "(($ac_try" in
5187  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5188  *) ac_try_echo=$ac_try;;
5189esac
5190eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5191  (eval "$ac_compile") 2>conftest.er1
5192  ac_status=$?
5193  grep -v '^ *+' conftest.er1 >conftest.err
5194  rm -f conftest.er1
5195  cat conftest.err >&5
5196  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5197  (exit $ac_status); } && {
5198	 test -z "$ac_c_werror_flag" ||
5199	 test ! -s conftest.err
5200       } && test -s conftest.$ac_objext; then
5201  ac_cv_sys_large_files=no; break
5202else
5203  echo "$as_me: failed program was:" >&5
5204sed 's/^/| /' conftest.$ac_ext >&5
5205
5206
5207fi
5208
5209rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5210  cat >conftest.$ac_ext <<_ACEOF
5211/* confdefs.h.  */
5212_ACEOF
5213cat confdefs.h >>conftest.$ac_ext
5214cat >>conftest.$ac_ext <<_ACEOF
5215/* end confdefs.h.  */
5216#define _LARGE_FILES 1
5217#include <sys/types.h>
5218 /* Check that off_t can represent 2**63 - 1 correctly.
5219    We can't simply define LARGE_OFF_T to be 9223372036854775807,
5220    since some C++ compilers masquerading as C compilers
5221    incorrectly reject 9223372036854775807.  */
5222#define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
5223  int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
5224		       && LARGE_OFF_T % 2147483647 == 1)
5225		      ? 1 : -1];
5226int
5227main ()
5228{
5229
5230  ;
5231  return 0;
5232}
5233_ACEOF
5234rm -f conftest.$ac_objext
5235if { (ac_try="$ac_compile"
5236case "(($ac_try" in
5237  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5238  *) ac_try_echo=$ac_try;;
5239esac
5240eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5241  (eval "$ac_compile") 2>conftest.er1
5242  ac_status=$?
5243  grep -v '^ *+' conftest.er1 >conftest.err
5244  rm -f conftest.er1
5245  cat conftest.err >&5
5246  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5247  (exit $ac_status); } && {
5248	 test -z "$ac_c_werror_flag" ||
5249	 test ! -s conftest.err
5250       } && test -s conftest.$ac_objext; then
5251  ac_cv_sys_large_files=1; break
5252else
5253  echo "$as_me: failed program was:" >&5
5254sed 's/^/| /' conftest.$ac_ext >&5
5255
5256
5257fi
5258
5259rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5260  ac_cv_sys_large_files=unknown
5261  break
5262done
5263fi
5264{ echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
5265echo "${ECHO_T}$ac_cv_sys_large_files" >&6; }
5266case $ac_cv_sys_large_files in #(
5267  no | unknown) ;;
5268  *)
5269cat >>confdefs.h <<_ACEOF
5270#define _LARGE_FILES $ac_cv_sys_large_files
5271_ACEOF
5272;;
5273esac
5274rm -f conftest*
5275  fi
5276fi
5277
5278
5279if test -z "$AR" ; then
5280	{ { echo "$as_me:$LINENO: error: *** 'ar' missing, please install or fix your \$PATH ***" >&5
5281echo "$as_me: error: *** 'ar' missing, please install or fix your \$PATH ***" >&2;}
5282   { (exit 1); exit 1; }; }
5283fi
5284
5285# Use LOGIN_PROGRAM from environment if possible
5286if test ! -z "$LOGIN_PROGRAM" ; then
5287
5288cat >>confdefs.h <<_ACEOF
5289#define LOGIN_PROGRAM_FALLBACK "$LOGIN_PROGRAM"
5290_ACEOF
5291
5292else
5293	# Search for login
5294	# Extract the first word of "login", so it can be a program name with args.
5295set dummy login; ac_word=$2
5296{ echo "$as_me:$LINENO: checking for $ac_word" >&5
5297echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5298if test "${ac_cv_path_LOGIN_PROGRAM_FALLBACK+set}" = set; then
5299  echo $ECHO_N "(cached) $ECHO_C" >&6
5300else
5301  case $LOGIN_PROGRAM_FALLBACK in
5302  [\\/]* | ?:[\\/]*)
5303  ac_cv_path_LOGIN_PROGRAM_FALLBACK="$LOGIN_PROGRAM_FALLBACK" # Let the user override the test with a path.
5304  ;;
5305  *)
5306  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5307for as_dir in $PATH
5308do
5309  IFS=$as_save_IFS
5310  test -z "$as_dir" && as_dir=.
5311  for ac_exec_ext in '' $ac_executable_extensions; do
5312  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5313    ac_cv_path_LOGIN_PROGRAM_FALLBACK="$as_dir/$ac_word$ac_exec_ext"
5314    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5315    break 2
5316  fi
5317done
5318done
5319IFS=$as_save_IFS
5320
5321  ;;
5322esac
5323fi
5324LOGIN_PROGRAM_FALLBACK=$ac_cv_path_LOGIN_PROGRAM_FALLBACK
5325if test -n "$LOGIN_PROGRAM_FALLBACK"; then
5326  { echo "$as_me:$LINENO: result: $LOGIN_PROGRAM_FALLBACK" >&5
5327echo "${ECHO_T}$LOGIN_PROGRAM_FALLBACK" >&6; }
5328else
5329  { echo "$as_me:$LINENO: result: no" >&5
5330echo "${ECHO_T}no" >&6; }
5331fi
5332
5333
5334	if test ! -z "$LOGIN_PROGRAM_FALLBACK" ; then
5335		cat >>confdefs.h <<_ACEOF
5336#define LOGIN_PROGRAM_FALLBACK "$LOGIN_PROGRAM_FALLBACK"
5337_ACEOF
5338
5339	fi
5340fi
5341
5342# Extract the first word of "passwd", so it can be a program name with args.
5343set dummy passwd; ac_word=$2
5344{ echo "$as_me:$LINENO: checking for $ac_word" >&5
5345echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
5346if test "${ac_cv_path_PATH_PASSWD_PROG+set}" = set; then
5347  echo $ECHO_N "(cached) $ECHO_C" >&6
5348else
5349  case $PATH_PASSWD_PROG in
5350  [\\/]* | ?:[\\/]*)
5351  ac_cv_path_PATH_PASSWD_PROG="$PATH_PASSWD_PROG" # Let the user override the test with a path.
5352  ;;
5353  *)
5354  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5355for as_dir in $PATH
5356do
5357  IFS=$as_save_IFS
5358  test -z "$as_dir" && as_dir=.
5359  for ac_exec_ext in '' $ac_executable_extensions; do
5360  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5361    ac_cv_path_PATH_PASSWD_PROG="$as_dir/$ac_word$ac_exec_ext"
5362    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5363    break 2
5364  fi
5365done
5366done
5367IFS=$as_save_IFS
5368
5369  ;;
5370esac
5371fi
5372PATH_PASSWD_PROG=$ac_cv_path_PATH_PASSWD_PROG
5373if test -n "$PATH_PASSWD_PROG"; then
5374  { echo "$as_me:$LINENO: result: $PATH_PASSWD_PROG" >&5
5375echo "${ECHO_T}$PATH_PASSWD_PROG" >&6; }
5376else
5377  { echo "$as_me:$LINENO: result: no" >&5
5378echo "${ECHO_T}no" >&6; }
5379fi
5380
5381
5382if test ! -z "$PATH_PASSWD_PROG" ; then
5383
5384cat >>confdefs.h <<_ACEOF
5385#define _PATH_PASSWD_PROG "$PATH_PASSWD_PROG"
5386_ACEOF
5387
5388fi
5389
5390if test -z "$LD" ; then
5391	LD=$CC
5392fi
5393
5394
5395{ echo "$as_me:$LINENO: checking for inline" >&5
5396echo $ECHO_N "checking for inline... $ECHO_C" >&6; }
5397if test "${ac_cv_c_inline+set}" = set; then
5398  echo $ECHO_N "(cached) $ECHO_C" >&6
5399else
5400  ac_cv_c_inline=no
5401for ac_kw in inline __inline__ __inline; do
5402  cat >conftest.$ac_ext <<_ACEOF
5403/* confdefs.h.  */
5404_ACEOF
5405cat confdefs.h >>conftest.$ac_ext
5406cat >>conftest.$ac_ext <<_ACEOF
5407/* end confdefs.h.  */
5408#ifndef __cplusplus
5409typedef int foo_t;
5410static $ac_kw foo_t static_foo () {return 0; }
5411$ac_kw foo_t foo () {return 0; }
5412#endif
5413
5414_ACEOF
5415rm -f conftest.$ac_objext
5416if { (ac_try="$ac_compile"
5417case "(($ac_try" in
5418  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5419  *) ac_try_echo=$ac_try;;
5420esac
5421eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5422  (eval "$ac_compile") 2>conftest.er1
5423  ac_status=$?
5424  grep -v '^ *+' conftest.er1 >conftest.err
5425  rm -f conftest.er1
5426  cat conftest.err >&5
5427  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5428  (exit $ac_status); } && {
5429	 test -z "$ac_c_werror_flag" ||
5430	 test ! -s conftest.err
5431       } && test -s conftest.$ac_objext; then
5432  ac_cv_c_inline=$ac_kw
5433else
5434  echo "$as_me: failed program was:" >&5
5435sed 's/^/| /' conftest.$ac_ext >&5
5436
5437
5438fi
5439
5440rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5441  test "$ac_cv_c_inline" != no && break
5442done
5443
5444fi
5445{ echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
5446echo "${ECHO_T}$ac_cv_c_inline" >&6; }
5447
5448
5449case $ac_cv_c_inline in
5450  inline | yes) ;;
5451  *)
5452    case $ac_cv_c_inline in
5453      no) ac_val=;;
5454      *) ac_val=$ac_cv_c_inline;;
5455    esac
5456    cat >>confdefs.h <<_ACEOF
5457#ifndef __cplusplus
5458#define inline $ac_val
5459#endif
5460_ACEOF
5461    ;;
5462esac
5463
5464
5465{ echo "$as_me:$LINENO: checking whether LLONG_MAX is declared" >&5
5466echo $ECHO_N "checking whether LLONG_MAX is declared... $ECHO_C" >&6; }
5467if test "${ac_cv_have_decl_LLONG_MAX+set}" = set; then
5468  echo $ECHO_N "(cached) $ECHO_C" >&6
5469else
5470  cat >conftest.$ac_ext <<_ACEOF
5471/* confdefs.h.  */
5472_ACEOF
5473cat confdefs.h >>conftest.$ac_ext
5474cat >>conftest.$ac_ext <<_ACEOF
5475/* end confdefs.h.  */
5476#include <limits.h>
5477
5478int
5479main ()
5480{
5481#ifndef LLONG_MAX
5482  (void) LLONG_MAX;
5483#endif
5484
5485  ;
5486  return 0;
5487}
5488_ACEOF
5489rm -f conftest.$ac_objext
5490if { (ac_try="$ac_compile"
5491case "(($ac_try" in
5492  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5493  *) ac_try_echo=$ac_try;;
5494esac
5495eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5496  (eval "$ac_compile") 2>conftest.er1
5497  ac_status=$?
5498  grep -v '^ *+' conftest.er1 >conftest.err
5499  rm -f conftest.er1
5500  cat conftest.err >&5
5501  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5502  (exit $ac_status); } && {
5503	 test -z "$ac_c_werror_flag" ||
5504	 test ! -s conftest.err
5505       } && test -s conftest.$ac_objext; then
5506  ac_cv_have_decl_LLONG_MAX=yes
5507else
5508  echo "$as_me: failed program was:" >&5
5509sed 's/^/| /' conftest.$ac_ext >&5
5510
5511	ac_cv_have_decl_LLONG_MAX=no
5512fi
5513
5514rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5515fi
5516{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_LLONG_MAX" >&5
5517echo "${ECHO_T}$ac_cv_have_decl_LLONG_MAX" >&6; }
5518if test $ac_cv_have_decl_LLONG_MAX = yes; then
5519  have_llong_max=1
5520fi
5521
5522{ echo "$as_me:$LINENO: checking whether SYSTR_POLICY_KILL is declared" >&5
5523echo $ECHO_N "checking whether SYSTR_POLICY_KILL is declared... $ECHO_C" >&6; }
5524if test "${ac_cv_have_decl_SYSTR_POLICY_KILL+set}" = set; then
5525  echo $ECHO_N "(cached) $ECHO_C" >&6
5526else
5527  cat >conftest.$ac_ext <<_ACEOF
5528/* confdefs.h.  */
5529_ACEOF
5530cat confdefs.h >>conftest.$ac_ext
5531cat >>conftest.$ac_ext <<_ACEOF
5532/* end confdefs.h.  */
5533
5534	#include <sys/types.h>
5535	#include <sys/param.h>
5536	#include <dev/systrace.h>
5537
5538
5539int
5540main ()
5541{
5542#ifndef SYSTR_POLICY_KILL
5543  (void) SYSTR_POLICY_KILL;
5544#endif
5545
5546  ;
5547  return 0;
5548}
5549_ACEOF
5550rm -f conftest.$ac_objext
5551if { (ac_try="$ac_compile"
5552case "(($ac_try" in
5553  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5554  *) ac_try_echo=$ac_try;;
5555esac
5556eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5557  (eval "$ac_compile") 2>conftest.er1
5558  ac_status=$?
5559  grep -v '^ *+' conftest.er1 >conftest.err
5560  rm -f conftest.er1
5561  cat conftest.err >&5
5562  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5563  (exit $ac_status); } && {
5564	 test -z "$ac_c_werror_flag" ||
5565	 test ! -s conftest.err
5566       } && test -s conftest.$ac_objext; then
5567  ac_cv_have_decl_SYSTR_POLICY_KILL=yes
5568else
5569  echo "$as_me: failed program was:" >&5
5570sed 's/^/| /' conftest.$ac_ext >&5
5571
5572	ac_cv_have_decl_SYSTR_POLICY_KILL=no
5573fi
5574
5575rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5576fi
5577{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_SYSTR_POLICY_KILL" >&5
5578echo "${ECHO_T}$ac_cv_have_decl_SYSTR_POLICY_KILL" >&6; }
5579if test $ac_cv_have_decl_SYSTR_POLICY_KILL = yes; then
5580  have_systr_policy_kill=1
5581fi
5582
5583{ echo "$as_me:$LINENO: checking whether RLIMIT_NPROC is declared" >&5
5584echo $ECHO_N "checking whether RLIMIT_NPROC is declared... $ECHO_C" >&6; }
5585if test "${ac_cv_have_decl_RLIMIT_NPROC+set}" = set; then
5586  echo $ECHO_N "(cached) $ECHO_C" >&6
5587else
5588  cat >conftest.$ac_ext <<_ACEOF
5589/* confdefs.h.  */
5590_ACEOF
5591cat confdefs.h >>conftest.$ac_ext
5592cat >>conftest.$ac_ext <<_ACEOF
5593/* end confdefs.h.  */
5594
5595	#include <sys/types.h>
5596	#include <sys/resource.h>
5597
5598
5599int
5600main ()
5601{
5602#ifndef RLIMIT_NPROC
5603  (void) RLIMIT_NPROC;
5604#endif
5605
5606  ;
5607  return 0;
5608}
5609_ACEOF
5610rm -f conftest.$ac_objext
5611if { (ac_try="$ac_compile"
5612case "(($ac_try" in
5613  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5614  *) ac_try_echo=$ac_try;;
5615esac
5616eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5617  (eval "$ac_compile") 2>conftest.er1
5618  ac_status=$?
5619  grep -v '^ *+' conftest.er1 >conftest.err
5620  rm -f conftest.er1
5621  cat conftest.err >&5
5622  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5623  (exit $ac_status); } && {
5624	 test -z "$ac_c_werror_flag" ||
5625	 test ! -s conftest.err
5626       } && test -s conftest.$ac_objext; then
5627  ac_cv_have_decl_RLIMIT_NPROC=yes
5628else
5629  echo "$as_me: failed program was:" >&5
5630sed 's/^/| /' conftest.$ac_ext >&5
5631
5632	ac_cv_have_decl_RLIMIT_NPROC=no
5633fi
5634
5635rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5636fi
5637{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_RLIMIT_NPROC" >&5
5638echo "${ECHO_T}$ac_cv_have_decl_RLIMIT_NPROC" >&6; }
5639if test $ac_cv_have_decl_RLIMIT_NPROC = yes; then
5640
5641cat >>confdefs.h <<\_ACEOF
5642#define HAVE_RLIMIT_NPROC
5643_ACEOF
5644
5645fi
5646
5647{ echo "$as_me:$LINENO: checking whether PR_SET_NO_NEW_PRIVS is declared" >&5
5648echo $ECHO_N "checking whether PR_SET_NO_NEW_PRIVS is declared... $ECHO_C" >&6; }
5649if test "${ac_cv_have_decl_PR_SET_NO_NEW_PRIVS+set}" = set; then
5650  echo $ECHO_N "(cached) $ECHO_C" >&6
5651else
5652  cat >conftest.$ac_ext <<_ACEOF
5653/* confdefs.h.  */
5654_ACEOF
5655cat confdefs.h >>conftest.$ac_ext
5656cat >>conftest.$ac_ext <<_ACEOF
5657/* end confdefs.h.  */
5658
5659	#include <sys/types.h>
5660	#include <linux/prctl.h>
5661
5662
5663int
5664main ()
5665{
5666#ifndef PR_SET_NO_NEW_PRIVS
5667  (void) PR_SET_NO_NEW_PRIVS;
5668#endif
5669
5670  ;
5671  return 0;
5672}
5673_ACEOF
5674rm -f conftest.$ac_objext
5675if { (ac_try="$ac_compile"
5676case "(($ac_try" in
5677  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5678  *) ac_try_echo=$ac_try;;
5679esac
5680eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5681  (eval "$ac_compile") 2>conftest.er1
5682  ac_status=$?
5683  grep -v '^ *+' conftest.er1 >conftest.err
5684  rm -f conftest.er1
5685  cat conftest.err >&5
5686  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5687  (exit $ac_status); } && {
5688	 test -z "$ac_c_werror_flag" ||
5689	 test ! -s conftest.err
5690       } && test -s conftest.$ac_objext; then
5691  ac_cv_have_decl_PR_SET_NO_NEW_PRIVS=yes
5692else
5693  echo "$as_me: failed program was:" >&5
5694sed 's/^/| /' conftest.$ac_ext >&5
5695
5696	ac_cv_have_decl_PR_SET_NO_NEW_PRIVS=no
5697fi
5698
5699rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5700fi
5701{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_PR_SET_NO_NEW_PRIVS" >&5
5702echo "${ECHO_T}$ac_cv_have_decl_PR_SET_NO_NEW_PRIVS" >&6; }
5703if test $ac_cv_have_decl_PR_SET_NO_NEW_PRIVS = yes; then
5704  have_linux_no_new_privs=1
5705fi
5706
5707
5708openssl=yes
5709ssh1=yes
5710
5711# Check whether --with-openssl was given.
5712if test "${with_openssl+set}" = set; then
5713  withval=$with_openssl;   if test "x$withval" = "xno" ; then
5714		openssl=no
5715		ssh1=no
5716	   fi
5717
5718
5719fi
5720
5721{ echo "$as_me:$LINENO: checking whether OpenSSL will be used for cryptography" >&5
5722echo $ECHO_N "checking whether OpenSSL will be used for cryptography... $ECHO_C" >&6; }
5723if test "x$openssl" = "xyes" ; then
5724	{ echo "$as_me:$LINENO: result: yes" >&5
5725echo "${ECHO_T}yes" >&6; }
5726
5727cat >>confdefs.h <<_ACEOF
5728#define WITH_OPENSSL 1
5729_ACEOF
5730
5731else
5732	{ echo "$as_me:$LINENO: result: no" >&5
5733echo "${ECHO_T}no" >&6; }
5734fi
5735
5736
5737# Check whether --with-ssh1 was given.
5738if test "${with_ssh1+set}" = set; then
5739  withval=$with_ssh1;
5740		if test "x$withval" = "xno" ; then
5741			ssh1=no
5742		elif test "x$openssl" = "xno" ; then
5743			{ { echo "$as_me:$LINENO: error: Cannot enable SSH protocol 1 with OpenSSL disabled" >&5
5744echo "$as_me: error: Cannot enable SSH protocol 1 with OpenSSL disabled" >&2;}
5745   { (exit 1); exit 1; }; }
5746		fi
5747
5748
5749fi
5750
5751{ echo "$as_me:$LINENO: checking whether SSH protocol 1 support is enabled" >&5
5752echo $ECHO_N "checking whether SSH protocol 1 support is enabled... $ECHO_C" >&6; }
5753if test "x$ssh1" = "xyes" ; then
5754	{ echo "$as_me:$LINENO: result: yes" >&5
5755echo "${ECHO_T}yes" >&6; }
5756
5757cat >>confdefs.h <<_ACEOF
5758#define WITH_SSH1 1
5759_ACEOF
5760
5761else
5762	{ echo "$as_me:$LINENO: result: no" >&5
5763echo "${ECHO_T}no" >&6; }
5764fi
5765
5766use_stack_protector=1
5767use_toolchain_hardening=1
5768
5769# Check whether --with-stackprotect was given.
5770if test "${with_stackprotect+set}" = set; then
5771  withval=$with_stackprotect;
5772    if test "x$withval" = "xno"; then
5773	use_stack_protector=0
5774    fi
5775fi
5776
5777
5778# Check whether --with-hardening was given.
5779if test "${with_hardening+set}" = set; then
5780  withval=$with_hardening;
5781    if test "x$withval" = "xno"; then
5782	use_toolchain_hardening=0
5783    fi
5784fi
5785
5786
5787# We use -Werror for the tests only so that we catch warnings like "this is
5788# on by default" for things like -fPIE.
5789{ echo "$as_me:$LINENO: checking if $CC supports -Werror" >&5
5790echo $ECHO_N "checking if $CC supports -Werror... $ECHO_C" >&6; }
5791saved_CFLAGS="$CFLAGS"
5792CFLAGS="$CFLAGS -Werror"
5793cat >conftest.$ac_ext <<_ACEOF
5794/* confdefs.h.  */
5795_ACEOF
5796cat confdefs.h >>conftest.$ac_ext
5797cat >>conftest.$ac_ext <<_ACEOF
5798/* end confdefs.h.  */
5799int main(void) { return 0; }
5800_ACEOF
5801rm -f conftest.$ac_objext
5802if { (ac_try="$ac_compile"
5803case "(($ac_try" in
5804  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5805  *) ac_try_echo=$ac_try;;
5806esac
5807eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5808  (eval "$ac_compile") 2>conftest.er1
5809  ac_status=$?
5810  grep -v '^ *+' conftest.er1 >conftest.err
5811  rm -f conftest.er1
5812  cat conftest.err >&5
5813  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5814  (exit $ac_status); } && {
5815	 test -z "$ac_c_werror_flag" ||
5816	 test ! -s conftest.err
5817       } && test -s conftest.$ac_objext; then
5818   { echo "$as_me:$LINENO: result: yes" >&5
5819echo "${ECHO_T}yes" >&6; }
5820	  WERROR="-Werror"
5821else
5822  echo "$as_me: failed program was:" >&5
5823sed 's/^/| /' conftest.$ac_ext >&5
5824
5825	 { echo "$as_me:$LINENO: result: no" >&5
5826echo "${ECHO_T}no" >&6; }
5827	  WERROR=""
5828
5829fi
5830
5831rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5832CFLAGS="$saved_CFLAGS"
5833
5834if test "$GCC" = "yes" || test "$GCC" = "egcs"; then
5835	{
5836	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -Qunused-arguments" >&5
5837echo $ECHO_N "checking if $CC supports compile flag -Qunused-arguments... $ECHO_C" >&6; }
5838	saved_CFLAGS="$CFLAGS"
5839	CFLAGS="$CFLAGS $WERROR -Qunused-arguments"
5840	_define_flag=""
5841	test "x$_define_flag" = "x" && _define_flag="-Qunused-arguments"
5842	cat >conftest.$ac_ext <<_ACEOF
5843/* confdefs.h.  */
5844_ACEOF
5845cat confdefs.h >>conftest.$ac_ext
5846cat >>conftest.$ac_ext <<_ACEOF
5847/* end confdefs.h.  */
5848
5849#include <stdlib.h>
5850#include <stdio.h>
5851int main(int argc, char **argv) {
5852	/* Some math to catch -ftrapv problems in the toolchain */
5853	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
5854	float l = i * 2.1;
5855	double m = l / 0.5;
5856	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
5857	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
5858	exit(0);
5859}
5860
5861_ACEOF
5862rm -f conftest.$ac_objext
5863if { (ac_try="$ac_compile"
5864case "(($ac_try" in
5865  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5866  *) ac_try_echo=$ac_try;;
5867esac
5868eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5869  (eval "$ac_compile") 2>conftest.er1
5870  ac_status=$?
5871  grep -v '^ *+' conftest.er1 >conftest.err
5872  rm -f conftest.er1
5873  cat conftest.err >&5
5874  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5875  (exit $ac_status); } && {
5876	 test -z "$ac_c_werror_flag" ||
5877	 test ! -s conftest.err
5878       } && test -s conftest.$ac_objext; then
5879
5880if `grep -i "unrecognized option" conftest.err >/dev/null`
5881then
5882		{ echo "$as_me:$LINENO: result: no" >&5
5883echo "${ECHO_T}no" >&6; }
5884		CFLAGS="$saved_CFLAGS"
5885else
5886		{ echo "$as_me:$LINENO: result: yes" >&5
5887echo "${ECHO_T}yes" >&6; }
5888		 CFLAGS="$saved_CFLAGS $_define_flag"
5889fi
5890else
5891  echo "$as_me: failed program was:" >&5
5892sed 's/^/| /' conftest.$ac_ext >&5
5893
5894	 { echo "$as_me:$LINENO: result: no" >&5
5895echo "${ECHO_T}no" >&6; }
5896		  CFLAGS="$saved_CFLAGS"
5897
5898fi
5899
5900rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5901}
5902	{
5903	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -Wunknown-warning-option" >&5
5904echo $ECHO_N "checking if $CC supports compile flag -Wunknown-warning-option... $ECHO_C" >&6; }
5905	saved_CFLAGS="$CFLAGS"
5906	CFLAGS="$CFLAGS $WERROR -Wunknown-warning-option"
5907	_define_flag=""
5908	test "x$_define_flag" = "x" && _define_flag="-Wunknown-warning-option"
5909	cat >conftest.$ac_ext <<_ACEOF
5910/* confdefs.h.  */
5911_ACEOF
5912cat confdefs.h >>conftest.$ac_ext
5913cat >>conftest.$ac_ext <<_ACEOF
5914/* end confdefs.h.  */
5915
5916#include <stdlib.h>
5917#include <stdio.h>
5918int main(int argc, char **argv) {
5919	/* Some math to catch -ftrapv problems in the toolchain */
5920	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
5921	float l = i * 2.1;
5922	double m = l / 0.5;
5923	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
5924	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
5925	exit(0);
5926}
5927
5928_ACEOF
5929rm -f conftest.$ac_objext
5930if { (ac_try="$ac_compile"
5931case "(($ac_try" in
5932  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5933  *) ac_try_echo=$ac_try;;
5934esac
5935eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
5936  (eval "$ac_compile") 2>conftest.er1
5937  ac_status=$?
5938  grep -v '^ *+' conftest.er1 >conftest.err
5939  rm -f conftest.er1
5940  cat conftest.err >&5
5941  echo "$as_me:$LINENO: \$? = $ac_status" >&5
5942  (exit $ac_status); } && {
5943	 test -z "$ac_c_werror_flag" ||
5944	 test ! -s conftest.err
5945       } && test -s conftest.$ac_objext; then
5946
5947if `grep -i "unrecognized option" conftest.err >/dev/null`
5948then
5949		{ echo "$as_me:$LINENO: result: no" >&5
5950echo "${ECHO_T}no" >&6; }
5951		CFLAGS="$saved_CFLAGS"
5952else
5953		{ echo "$as_me:$LINENO: result: yes" >&5
5954echo "${ECHO_T}yes" >&6; }
5955		 CFLAGS="$saved_CFLAGS $_define_flag"
5956fi
5957else
5958  echo "$as_me: failed program was:" >&5
5959sed 's/^/| /' conftest.$ac_ext >&5
5960
5961	 { echo "$as_me:$LINENO: result: no" >&5
5962echo "${ECHO_T}no" >&6; }
5963		  CFLAGS="$saved_CFLAGS"
5964
5965fi
5966
5967rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
5968}
5969	{
5970	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -Wall" >&5
5971echo $ECHO_N "checking if $CC supports compile flag -Wall... $ECHO_C" >&6; }
5972	saved_CFLAGS="$CFLAGS"
5973	CFLAGS="$CFLAGS $WERROR -Wall"
5974	_define_flag=""
5975	test "x$_define_flag" = "x" && _define_flag="-Wall"
5976	cat >conftest.$ac_ext <<_ACEOF
5977/* confdefs.h.  */
5978_ACEOF
5979cat confdefs.h >>conftest.$ac_ext
5980cat >>conftest.$ac_ext <<_ACEOF
5981/* end confdefs.h.  */
5982
5983#include <stdlib.h>
5984#include <stdio.h>
5985int main(int argc, char **argv) {
5986	/* Some math to catch -ftrapv problems in the toolchain */
5987	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
5988	float l = i * 2.1;
5989	double m = l / 0.5;
5990	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
5991	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
5992	exit(0);
5993}
5994
5995_ACEOF
5996rm -f conftest.$ac_objext
5997if { (ac_try="$ac_compile"
5998case "(($ac_try" in
5999  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6000  *) ac_try_echo=$ac_try;;
6001esac
6002eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6003  (eval "$ac_compile") 2>conftest.er1
6004  ac_status=$?
6005  grep -v '^ *+' conftest.er1 >conftest.err
6006  rm -f conftest.er1
6007  cat conftest.err >&5
6008  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6009  (exit $ac_status); } && {
6010	 test -z "$ac_c_werror_flag" ||
6011	 test ! -s conftest.err
6012       } && test -s conftest.$ac_objext; then
6013
6014if `grep -i "unrecognized option" conftest.err >/dev/null`
6015then
6016		{ echo "$as_me:$LINENO: result: no" >&5
6017echo "${ECHO_T}no" >&6; }
6018		CFLAGS="$saved_CFLAGS"
6019else
6020		{ echo "$as_me:$LINENO: result: yes" >&5
6021echo "${ECHO_T}yes" >&6; }
6022		 CFLAGS="$saved_CFLAGS $_define_flag"
6023fi
6024else
6025  echo "$as_me: failed program was:" >&5
6026sed 's/^/| /' conftest.$ac_ext >&5
6027
6028	 { echo "$as_me:$LINENO: result: no" >&5
6029echo "${ECHO_T}no" >&6; }
6030		  CFLAGS="$saved_CFLAGS"
6031
6032fi
6033
6034rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6035}
6036	{
6037	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -Wpointer-arith" >&5
6038echo $ECHO_N "checking if $CC supports compile flag -Wpointer-arith... $ECHO_C" >&6; }
6039	saved_CFLAGS="$CFLAGS"
6040	CFLAGS="$CFLAGS $WERROR -Wpointer-arith"
6041	_define_flag=""
6042	test "x$_define_flag" = "x" && _define_flag="-Wpointer-arith"
6043	cat >conftest.$ac_ext <<_ACEOF
6044/* confdefs.h.  */
6045_ACEOF
6046cat confdefs.h >>conftest.$ac_ext
6047cat >>conftest.$ac_ext <<_ACEOF
6048/* end confdefs.h.  */
6049
6050#include <stdlib.h>
6051#include <stdio.h>
6052int main(int argc, char **argv) {
6053	/* Some math to catch -ftrapv problems in the toolchain */
6054	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
6055	float l = i * 2.1;
6056	double m = l / 0.5;
6057	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
6058	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
6059	exit(0);
6060}
6061
6062_ACEOF
6063rm -f conftest.$ac_objext
6064if { (ac_try="$ac_compile"
6065case "(($ac_try" in
6066  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6067  *) ac_try_echo=$ac_try;;
6068esac
6069eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6070  (eval "$ac_compile") 2>conftest.er1
6071  ac_status=$?
6072  grep -v '^ *+' conftest.er1 >conftest.err
6073  rm -f conftest.er1
6074  cat conftest.err >&5
6075  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6076  (exit $ac_status); } && {
6077	 test -z "$ac_c_werror_flag" ||
6078	 test ! -s conftest.err
6079       } && test -s conftest.$ac_objext; then
6080
6081if `grep -i "unrecognized option" conftest.err >/dev/null`
6082then
6083		{ echo "$as_me:$LINENO: result: no" >&5
6084echo "${ECHO_T}no" >&6; }
6085		CFLAGS="$saved_CFLAGS"
6086else
6087		{ echo "$as_me:$LINENO: result: yes" >&5
6088echo "${ECHO_T}yes" >&6; }
6089		 CFLAGS="$saved_CFLAGS $_define_flag"
6090fi
6091else
6092  echo "$as_me: failed program was:" >&5
6093sed 's/^/| /' conftest.$ac_ext >&5
6094
6095	 { echo "$as_me:$LINENO: result: no" >&5
6096echo "${ECHO_T}no" >&6; }
6097		  CFLAGS="$saved_CFLAGS"
6098
6099fi
6100
6101rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6102}
6103	{
6104	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -Wuninitialized" >&5
6105echo $ECHO_N "checking if $CC supports compile flag -Wuninitialized... $ECHO_C" >&6; }
6106	saved_CFLAGS="$CFLAGS"
6107	CFLAGS="$CFLAGS $WERROR -Wuninitialized"
6108	_define_flag=""
6109	test "x$_define_flag" = "x" && _define_flag="-Wuninitialized"
6110	cat >conftest.$ac_ext <<_ACEOF
6111/* confdefs.h.  */
6112_ACEOF
6113cat confdefs.h >>conftest.$ac_ext
6114cat >>conftest.$ac_ext <<_ACEOF
6115/* end confdefs.h.  */
6116
6117#include <stdlib.h>
6118#include <stdio.h>
6119int main(int argc, char **argv) {
6120	/* Some math to catch -ftrapv problems in the toolchain */
6121	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
6122	float l = i * 2.1;
6123	double m = l / 0.5;
6124	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
6125	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
6126	exit(0);
6127}
6128
6129_ACEOF
6130rm -f conftest.$ac_objext
6131if { (ac_try="$ac_compile"
6132case "(($ac_try" in
6133  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6134  *) ac_try_echo=$ac_try;;
6135esac
6136eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6137  (eval "$ac_compile") 2>conftest.er1
6138  ac_status=$?
6139  grep -v '^ *+' conftest.er1 >conftest.err
6140  rm -f conftest.er1
6141  cat conftest.err >&5
6142  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6143  (exit $ac_status); } && {
6144	 test -z "$ac_c_werror_flag" ||
6145	 test ! -s conftest.err
6146       } && test -s conftest.$ac_objext; then
6147
6148if `grep -i "unrecognized option" conftest.err >/dev/null`
6149then
6150		{ echo "$as_me:$LINENO: result: no" >&5
6151echo "${ECHO_T}no" >&6; }
6152		CFLAGS="$saved_CFLAGS"
6153else
6154		{ echo "$as_me:$LINENO: result: yes" >&5
6155echo "${ECHO_T}yes" >&6; }
6156		 CFLAGS="$saved_CFLAGS $_define_flag"
6157fi
6158else
6159  echo "$as_me: failed program was:" >&5
6160sed 's/^/| /' conftest.$ac_ext >&5
6161
6162	 { echo "$as_me:$LINENO: result: no" >&5
6163echo "${ECHO_T}no" >&6; }
6164		  CFLAGS="$saved_CFLAGS"
6165
6166fi
6167
6168rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6169}
6170	{
6171	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -Wsign-compare" >&5
6172echo $ECHO_N "checking if $CC supports compile flag -Wsign-compare... $ECHO_C" >&6; }
6173	saved_CFLAGS="$CFLAGS"
6174	CFLAGS="$CFLAGS $WERROR -Wsign-compare"
6175	_define_flag=""
6176	test "x$_define_flag" = "x" && _define_flag="-Wsign-compare"
6177	cat >conftest.$ac_ext <<_ACEOF
6178/* confdefs.h.  */
6179_ACEOF
6180cat confdefs.h >>conftest.$ac_ext
6181cat >>conftest.$ac_ext <<_ACEOF
6182/* end confdefs.h.  */
6183
6184#include <stdlib.h>
6185#include <stdio.h>
6186int main(int argc, char **argv) {
6187	/* Some math to catch -ftrapv problems in the toolchain */
6188	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
6189	float l = i * 2.1;
6190	double m = l / 0.5;
6191	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
6192	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
6193	exit(0);
6194}
6195
6196_ACEOF
6197rm -f conftest.$ac_objext
6198if { (ac_try="$ac_compile"
6199case "(($ac_try" in
6200  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6201  *) ac_try_echo=$ac_try;;
6202esac
6203eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6204  (eval "$ac_compile") 2>conftest.er1
6205  ac_status=$?
6206  grep -v '^ *+' conftest.er1 >conftest.err
6207  rm -f conftest.er1
6208  cat conftest.err >&5
6209  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6210  (exit $ac_status); } && {
6211	 test -z "$ac_c_werror_flag" ||
6212	 test ! -s conftest.err
6213       } && test -s conftest.$ac_objext; then
6214
6215if `grep -i "unrecognized option" conftest.err >/dev/null`
6216then
6217		{ echo "$as_me:$LINENO: result: no" >&5
6218echo "${ECHO_T}no" >&6; }
6219		CFLAGS="$saved_CFLAGS"
6220else
6221		{ echo "$as_me:$LINENO: result: yes" >&5
6222echo "${ECHO_T}yes" >&6; }
6223		 CFLAGS="$saved_CFLAGS $_define_flag"
6224fi
6225else
6226  echo "$as_me: failed program was:" >&5
6227sed 's/^/| /' conftest.$ac_ext >&5
6228
6229	 { echo "$as_me:$LINENO: result: no" >&5
6230echo "${ECHO_T}no" >&6; }
6231		  CFLAGS="$saved_CFLAGS"
6232
6233fi
6234
6235rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6236}
6237	{
6238	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -Wformat-security" >&5
6239echo $ECHO_N "checking if $CC supports compile flag -Wformat-security... $ECHO_C" >&6; }
6240	saved_CFLAGS="$CFLAGS"
6241	CFLAGS="$CFLAGS $WERROR -Wformat-security"
6242	_define_flag=""
6243	test "x$_define_flag" = "x" && _define_flag="-Wformat-security"
6244	cat >conftest.$ac_ext <<_ACEOF
6245/* confdefs.h.  */
6246_ACEOF
6247cat confdefs.h >>conftest.$ac_ext
6248cat >>conftest.$ac_ext <<_ACEOF
6249/* end confdefs.h.  */
6250
6251#include <stdlib.h>
6252#include <stdio.h>
6253int main(int argc, char **argv) {
6254	/* Some math to catch -ftrapv problems in the toolchain */
6255	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
6256	float l = i * 2.1;
6257	double m = l / 0.5;
6258	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
6259	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
6260	exit(0);
6261}
6262
6263_ACEOF
6264rm -f conftest.$ac_objext
6265if { (ac_try="$ac_compile"
6266case "(($ac_try" in
6267  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6268  *) ac_try_echo=$ac_try;;
6269esac
6270eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6271  (eval "$ac_compile") 2>conftest.er1
6272  ac_status=$?
6273  grep -v '^ *+' conftest.er1 >conftest.err
6274  rm -f conftest.er1
6275  cat conftest.err >&5
6276  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6277  (exit $ac_status); } && {
6278	 test -z "$ac_c_werror_flag" ||
6279	 test ! -s conftest.err
6280       } && test -s conftest.$ac_objext; then
6281
6282if `grep -i "unrecognized option" conftest.err >/dev/null`
6283then
6284		{ echo "$as_me:$LINENO: result: no" >&5
6285echo "${ECHO_T}no" >&6; }
6286		CFLAGS="$saved_CFLAGS"
6287else
6288		{ echo "$as_me:$LINENO: result: yes" >&5
6289echo "${ECHO_T}yes" >&6; }
6290		 CFLAGS="$saved_CFLAGS $_define_flag"
6291fi
6292else
6293  echo "$as_me: failed program was:" >&5
6294sed 's/^/| /' conftest.$ac_ext >&5
6295
6296	 { echo "$as_me:$LINENO: result: no" >&5
6297echo "${ECHO_T}no" >&6; }
6298		  CFLAGS="$saved_CFLAGS"
6299
6300fi
6301
6302rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6303}
6304	{
6305	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -Wsizeof-pointer-memaccess" >&5
6306echo $ECHO_N "checking if $CC supports compile flag -Wsizeof-pointer-memaccess... $ECHO_C" >&6; }
6307	saved_CFLAGS="$CFLAGS"
6308	CFLAGS="$CFLAGS $WERROR -Wsizeof-pointer-memaccess"
6309	_define_flag=""
6310	test "x$_define_flag" = "x" && _define_flag="-Wsizeof-pointer-memaccess"
6311	cat >conftest.$ac_ext <<_ACEOF
6312/* confdefs.h.  */
6313_ACEOF
6314cat confdefs.h >>conftest.$ac_ext
6315cat >>conftest.$ac_ext <<_ACEOF
6316/* end confdefs.h.  */
6317
6318#include <stdlib.h>
6319#include <stdio.h>
6320int main(int argc, char **argv) {
6321	/* Some math to catch -ftrapv problems in the toolchain */
6322	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
6323	float l = i * 2.1;
6324	double m = l / 0.5;
6325	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
6326	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
6327	exit(0);
6328}
6329
6330_ACEOF
6331rm -f conftest.$ac_objext
6332if { (ac_try="$ac_compile"
6333case "(($ac_try" in
6334  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6335  *) ac_try_echo=$ac_try;;
6336esac
6337eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6338  (eval "$ac_compile") 2>conftest.er1
6339  ac_status=$?
6340  grep -v '^ *+' conftest.er1 >conftest.err
6341  rm -f conftest.er1
6342  cat conftest.err >&5
6343  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6344  (exit $ac_status); } && {
6345	 test -z "$ac_c_werror_flag" ||
6346	 test ! -s conftest.err
6347       } && test -s conftest.$ac_objext; then
6348
6349if `grep -i "unrecognized option" conftest.err >/dev/null`
6350then
6351		{ echo "$as_me:$LINENO: result: no" >&5
6352echo "${ECHO_T}no" >&6; }
6353		CFLAGS="$saved_CFLAGS"
6354else
6355		{ echo "$as_me:$LINENO: result: yes" >&5
6356echo "${ECHO_T}yes" >&6; }
6357		 CFLAGS="$saved_CFLAGS $_define_flag"
6358fi
6359else
6360  echo "$as_me: failed program was:" >&5
6361sed 's/^/| /' conftest.$ac_ext >&5
6362
6363	 { echo "$as_me:$LINENO: result: no" >&5
6364echo "${ECHO_T}no" >&6; }
6365		  CFLAGS="$saved_CFLAGS"
6366
6367fi
6368
6369rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6370}
6371	{
6372	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -Wpointer-sign" >&5
6373echo $ECHO_N "checking if $CC supports compile flag -Wpointer-sign... $ECHO_C" >&6; }
6374	saved_CFLAGS="$CFLAGS"
6375	CFLAGS="$CFLAGS $WERROR -Wpointer-sign"
6376	_define_flag="-Wno-pointer-sign"
6377	test "x$_define_flag" = "x" && _define_flag="-Wpointer-sign"
6378	cat >conftest.$ac_ext <<_ACEOF
6379/* confdefs.h.  */
6380_ACEOF
6381cat confdefs.h >>conftest.$ac_ext
6382cat >>conftest.$ac_ext <<_ACEOF
6383/* end confdefs.h.  */
6384
6385#include <stdlib.h>
6386#include <stdio.h>
6387int main(int argc, char **argv) {
6388	/* Some math to catch -ftrapv problems in the toolchain */
6389	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
6390	float l = i * 2.1;
6391	double m = l / 0.5;
6392	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
6393	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
6394	exit(0);
6395}
6396
6397_ACEOF
6398rm -f conftest.$ac_objext
6399if { (ac_try="$ac_compile"
6400case "(($ac_try" in
6401  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6402  *) ac_try_echo=$ac_try;;
6403esac
6404eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6405  (eval "$ac_compile") 2>conftest.er1
6406  ac_status=$?
6407  grep -v '^ *+' conftest.er1 >conftest.err
6408  rm -f conftest.er1
6409  cat conftest.err >&5
6410  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6411  (exit $ac_status); } && {
6412	 test -z "$ac_c_werror_flag" ||
6413	 test ! -s conftest.err
6414       } && test -s conftest.$ac_objext; then
6415
6416if `grep -i "unrecognized option" conftest.err >/dev/null`
6417then
6418		{ echo "$as_me:$LINENO: result: no" >&5
6419echo "${ECHO_T}no" >&6; }
6420		CFLAGS="$saved_CFLAGS"
6421else
6422		{ echo "$as_me:$LINENO: result: yes" >&5
6423echo "${ECHO_T}yes" >&6; }
6424		 CFLAGS="$saved_CFLAGS $_define_flag"
6425fi
6426else
6427  echo "$as_me: failed program was:" >&5
6428sed 's/^/| /' conftest.$ac_ext >&5
6429
6430	 { echo "$as_me:$LINENO: result: no" >&5
6431echo "${ECHO_T}no" >&6; }
6432		  CFLAGS="$saved_CFLAGS"
6433
6434fi
6435
6436rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6437}
6438	{
6439	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -Wunused-result" >&5
6440echo $ECHO_N "checking if $CC supports compile flag -Wunused-result... $ECHO_C" >&6; }
6441	saved_CFLAGS="$CFLAGS"
6442	CFLAGS="$CFLAGS $WERROR -Wunused-result"
6443	_define_flag="-Wno-unused-result"
6444	test "x$_define_flag" = "x" && _define_flag="-Wunused-result"
6445	cat >conftest.$ac_ext <<_ACEOF
6446/* confdefs.h.  */
6447_ACEOF
6448cat confdefs.h >>conftest.$ac_ext
6449cat >>conftest.$ac_ext <<_ACEOF
6450/* end confdefs.h.  */
6451
6452#include <stdlib.h>
6453#include <stdio.h>
6454int main(int argc, char **argv) {
6455	/* Some math to catch -ftrapv problems in the toolchain */
6456	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
6457	float l = i * 2.1;
6458	double m = l / 0.5;
6459	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
6460	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
6461	exit(0);
6462}
6463
6464_ACEOF
6465rm -f conftest.$ac_objext
6466if { (ac_try="$ac_compile"
6467case "(($ac_try" in
6468  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6469  *) ac_try_echo=$ac_try;;
6470esac
6471eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6472  (eval "$ac_compile") 2>conftest.er1
6473  ac_status=$?
6474  grep -v '^ *+' conftest.er1 >conftest.err
6475  rm -f conftest.er1
6476  cat conftest.err >&5
6477  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6478  (exit $ac_status); } && {
6479	 test -z "$ac_c_werror_flag" ||
6480	 test ! -s conftest.err
6481       } && test -s conftest.$ac_objext; then
6482
6483if `grep -i "unrecognized option" conftest.err >/dev/null`
6484then
6485		{ echo "$as_me:$LINENO: result: no" >&5
6486echo "${ECHO_T}no" >&6; }
6487		CFLAGS="$saved_CFLAGS"
6488else
6489		{ echo "$as_me:$LINENO: result: yes" >&5
6490echo "${ECHO_T}yes" >&6; }
6491		 CFLAGS="$saved_CFLAGS $_define_flag"
6492fi
6493else
6494  echo "$as_me: failed program was:" >&5
6495sed 's/^/| /' conftest.$ac_ext >&5
6496
6497	 { echo "$as_me:$LINENO: result: no" >&5
6498echo "${ECHO_T}no" >&6; }
6499		  CFLAGS="$saved_CFLAGS"
6500
6501fi
6502
6503rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6504}
6505	{
6506	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -fno-strict-aliasing" >&5
6507echo $ECHO_N "checking if $CC supports compile flag -fno-strict-aliasing... $ECHO_C" >&6; }
6508	saved_CFLAGS="$CFLAGS"
6509	CFLAGS="$CFLAGS $WERROR -fno-strict-aliasing"
6510	_define_flag=""
6511	test "x$_define_flag" = "x" && _define_flag="-fno-strict-aliasing"
6512	cat >conftest.$ac_ext <<_ACEOF
6513/* confdefs.h.  */
6514_ACEOF
6515cat confdefs.h >>conftest.$ac_ext
6516cat >>conftest.$ac_ext <<_ACEOF
6517/* end confdefs.h.  */
6518
6519#include <stdlib.h>
6520#include <stdio.h>
6521int main(int argc, char **argv) {
6522	/* Some math to catch -ftrapv problems in the toolchain */
6523	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
6524	float l = i * 2.1;
6525	double m = l / 0.5;
6526	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
6527	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
6528	exit(0);
6529}
6530
6531_ACEOF
6532rm -f conftest.$ac_objext
6533if { (ac_try="$ac_compile"
6534case "(($ac_try" in
6535  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6536  *) ac_try_echo=$ac_try;;
6537esac
6538eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6539  (eval "$ac_compile") 2>conftest.er1
6540  ac_status=$?
6541  grep -v '^ *+' conftest.er1 >conftest.err
6542  rm -f conftest.er1
6543  cat conftest.err >&5
6544  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6545  (exit $ac_status); } && {
6546	 test -z "$ac_c_werror_flag" ||
6547	 test ! -s conftest.err
6548       } && test -s conftest.$ac_objext; then
6549
6550if `grep -i "unrecognized option" conftest.err >/dev/null`
6551then
6552		{ echo "$as_me:$LINENO: result: no" >&5
6553echo "${ECHO_T}no" >&6; }
6554		CFLAGS="$saved_CFLAGS"
6555else
6556		{ echo "$as_me:$LINENO: result: yes" >&5
6557echo "${ECHO_T}yes" >&6; }
6558		 CFLAGS="$saved_CFLAGS $_define_flag"
6559fi
6560else
6561  echo "$as_me: failed program was:" >&5
6562sed 's/^/| /' conftest.$ac_ext >&5
6563
6564	 { echo "$as_me:$LINENO: result: no" >&5
6565echo "${ECHO_T}no" >&6; }
6566		  CFLAGS="$saved_CFLAGS"
6567
6568fi
6569
6570rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6571}
6572	{
6573	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -D_FORTIFY_SOURCE=2" >&5
6574echo $ECHO_N "checking if $CC supports compile flag -D_FORTIFY_SOURCE=2... $ECHO_C" >&6; }
6575	saved_CFLAGS="$CFLAGS"
6576	CFLAGS="$CFLAGS $WERROR -D_FORTIFY_SOURCE=2"
6577	_define_flag=""
6578	test "x$_define_flag" = "x" && _define_flag="-D_FORTIFY_SOURCE=2"
6579	cat >conftest.$ac_ext <<_ACEOF
6580/* confdefs.h.  */
6581_ACEOF
6582cat confdefs.h >>conftest.$ac_ext
6583cat >>conftest.$ac_ext <<_ACEOF
6584/* end confdefs.h.  */
6585
6586#include <stdlib.h>
6587#include <stdio.h>
6588int main(int argc, char **argv) {
6589	/* Some math to catch -ftrapv problems in the toolchain */
6590	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
6591	float l = i * 2.1;
6592	double m = l / 0.5;
6593	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
6594	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
6595	exit(0);
6596}
6597
6598_ACEOF
6599rm -f conftest.$ac_objext
6600if { (ac_try="$ac_compile"
6601case "(($ac_try" in
6602  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6603  *) ac_try_echo=$ac_try;;
6604esac
6605eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6606  (eval "$ac_compile") 2>conftest.er1
6607  ac_status=$?
6608  grep -v '^ *+' conftest.er1 >conftest.err
6609  rm -f conftest.er1
6610  cat conftest.err >&5
6611  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6612  (exit $ac_status); } && {
6613	 test -z "$ac_c_werror_flag" ||
6614	 test ! -s conftest.err
6615       } && test -s conftest.$ac_objext; then
6616
6617if `grep -i "unrecognized option" conftest.err >/dev/null`
6618then
6619		{ echo "$as_me:$LINENO: result: no" >&5
6620echo "${ECHO_T}no" >&6; }
6621		CFLAGS="$saved_CFLAGS"
6622else
6623		{ echo "$as_me:$LINENO: result: yes" >&5
6624echo "${ECHO_T}yes" >&6; }
6625		 CFLAGS="$saved_CFLAGS $_define_flag"
6626fi
6627else
6628  echo "$as_me: failed program was:" >&5
6629sed 's/^/| /' conftest.$ac_ext >&5
6630
6631	 { echo "$as_me:$LINENO: result: no" >&5
6632echo "${ECHO_T}no" >&6; }
6633		  CFLAGS="$saved_CFLAGS"
6634
6635fi
6636
6637rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
6638}
6639    if test "x$use_toolchain_hardening" = "x1"; then
6640	{
6641	{ echo "$as_me:$LINENO: checking if $LD supports link flag -Wl,-z,relro" >&5
6642echo $ECHO_N "checking if $LD supports link flag -Wl,-z,relro... $ECHO_C" >&6; }
6643	saved_LDFLAGS="$LDFLAGS"
6644	LDFLAGS="$LDFLAGS $WERROR -Wl,-z,relro"
6645	_define_flag=""
6646	test "x$_define_flag" = "x" && _define_flag="-Wl,-z,relro"
6647	cat >conftest.$ac_ext <<_ACEOF
6648/* confdefs.h.  */
6649_ACEOF
6650cat confdefs.h >>conftest.$ac_ext
6651cat >>conftest.$ac_ext <<_ACEOF
6652/* end confdefs.h.  */
6653
6654#include <stdlib.h>
6655#include <stdio.h>
6656int main(int argc, char **argv) {
6657	/* Some math to catch -ftrapv problems in the toolchain */
6658	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
6659	float l = i * 2.1;
6660	double m = l / 0.5;
6661	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
6662	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
6663	exit(0);
6664}
6665
6666_ACEOF
6667rm -f conftest.$ac_objext conftest$ac_exeext
6668if { (ac_try="$ac_link"
6669case "(($ac_try" in
6670  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6671  *) ac_try_echo=$ac_try;;
6672esac
6673eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6674  (eval "$ac_link") 2>conftest.er1
6675  ac_status=$?
6676  grep -v '^ *+' conftest.er1 >conftest.err
6677  rm -f conftest.er1
6678  cat conftest.err >&5
6679  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6680  (exit $ac_status); } && {
6681	 test -z "$ac_c_werror_flag" ||
6682	 test ! -s conftest.err
6683       } && test -s conftest$ac_exeext &&
6684       $as_test_x conftest$ac_exeext; then
6685   { echo "$as_me:$LINENO: result: yes" >&5
6686echo "${ECHO_T}yes" >&6; }
6687		  LDFLAGS="$saved_LDFLAGS $_define_flag"
6688else
6689  echo "$as_me: failed program was:" >&5
6690sed 's/^/| /' conftest.$ac_ext >&5
6691
6692	 { echo "$as_me:$LINENO: result: no" >&5
6693echo "${ECHO_T}no" >&6; }
6694		  LDFLAGS="$saved_LDFLAGS"
6695
6696fi
6697
6698rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6699      conftest$ac_exeext conftest.$ac_ext
6700}
6701	{
6702	{ echo "$as_me:$LINENO: checking if $LD supports link flag -Wl,-z,now" >&5
6703echo $ECHO_N "checking if $LD supports link flag -Wl,-z,now... $ECHO_C" >&6; }
6704	saved_LDFLAGS="$LDFLAGS"
6705	LDFLAGS="$LDFLAGS $WERROR -Wl,-z,now"
6706	_define_flag=""
6707	test "x$_define_flag" = "x" && _define_flag="-Wl,-z,now"
6708	cat >conftest.$ac_ext <<_ACEOF
6709/* confdefs.h.  */
6710_ACEOF
6711cat confdefs.h >>conftest.$ac_ext
6712cat >>conftest.$ac_ext <<_ACEOF
6713/* end confdefs.h.  */
6714
6715#include <stdlib.h>
6716#include <stdio.h>
6717int main(int argc, char **argv) {
6718	/* Some math to catch -ftrapv problems in the toolchain */
6719	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
6720	float l = i * 2.1;
6721	double m = l / 0.5;
6722	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
6723	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
6724	exit(0);
6725}
6726
6727_ACEOF
6728rm -f conftest.$ac_objext conftest$ac_exeext
6729if { (ac_try="$ac_link"
6730case "(($ac_try" in
6731  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6732  *) ac_try_echo=$ac_try;;
6733esac
6734eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6735  (eval "$ac_link") 2>conftest.er1
6736  ac_status=$?
6737  grep -v '^ *+' conftest.er1 >conftest.err
6738  rm -f conftest.er1
6739  cat conftest.err >&5
6740  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6741  (exit $ac_status); } && {
6742	 test -z "$ac_c_werror_flag" ||
6743	 test ! -s conftest.err
6744       } && test -s conftest$ac_exeext &&
6745       $as_test_x conftest$ac_exeext; then
6746   { echo "$as_me:$LINENO: result: yes" >&5
6747echo "${ECHO_T}yes" >&6; }
6748		  LDFLAGS="$saved_LDFLAGS $_define_flag"
6749else
6750  echo "$as_me: failed program was:" >&5
6751sed 's/^/| /' conftest.$ac_ext >&5
6752
6753	 { echo "$as_me:$LINENO: result: no" >&5
6754echo "${ECHO_T}no" >&6; }
6755		  LDFLAGS="$saved_LDFLAGS"
6756
6757fi
6758
6759rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6760      conftest$ac_exeext conftest.$ac_ext
6761}
6762	{
6763	{ echo "$as_me:$LINENO: checking if $LD supports link flag -Wl,-z,noexecstack" >&5
6764echo $ECHO_N "checking if $LD supports link flag -Wl,-z,noexecstack... $ECHO_C" >&6; }
6765	saved_LDFLAGS="$LDFLAGS"
6766	LDFLAGS="$LDFLAGS $WERROR -Wl,-z,noexecstack"
6767	_define_flag=""
6768	test "x$_define_flag" = "x" && _define_flag="-Wl,-z,noexecstack"
6769	cat >conftest.$ac_ext <<_ACEOF
6770/* confdefs.h.  */
6771_ACEOF
6772cat confdefs.h >>conftest.$ac_ext
6773cat >>conftest.$ac_ext <<_ACEOF
6774/* end confdefs.h.  */
6775
6776#include <stdlib.h>
6777#include <stdio.h>
6778int main(int argc, char **argv) {
6779	/* Some math to catch -ftrapv problems in the toolchain */
6780	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
6781	float l = i * 2.1;
6782	double m = l / 0.5;
6783	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
6784	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
6785	exit(0);
6786}
6787
6788_ACEOF
6789rm -f conftest.$ac_objext conftest$ac_exeext
6790if { (ac_try="$ac_link"
6791case "(($ac_try" in
6792  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6793  *) ac_try_echo=$ac_try;;
6794esac
6795eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6796  (eval "$ac_link") 2>conftest.er1
6797  ac_status=$?
6798  grep -v '^ *+' conftest.er1 >conftest.err
6799  rm -f conftest.er1
6800  cat conftest.err >&5
6801  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6802  (exit $ac_status); } && {
6803	 test -z "$ac_c_werror_flag" ||
6804	 test ! -s conftest.err
6805       } && test -s conftest$ac_exeext &&
6806       $as_test_x conftest$ac_exeext; then
6807   { echo "$as_me:$LINENO: result: yes" >&5
6808echo "${ECHO_T}yes" >&6; }
6809		  LDFLAGS="$saved_LDFLAGS $_define_flag"
6810else
6811  echo "$as_me: failed program was:" >&5
6812sed 's/^/| /' conftest.$ac_ext >&5
6813
6814	 { echo "$as_me:$LINENO: result: no" >&5
6815echo "${ECHO_T}no" >&6; }
6816		  LDFLAGS="$saved_LDFLAGS"
6817
6818fi
6819
6820rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6821      conftest$ac_exeext conftest.$ac_ext
6822}
6823	# NB. -ftrapv expects certain support functions to be present in
6824	# the compiler library (libgcc or similar) to detect integer operations
6825	# that can overflow. We must check that the result of enabling it
6826	# actually links. The test program compiled/linked includes a number
6827	# of integer operations that should exercise this.
6828	{
6829	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -ftrapv and linking succeeds" >&5
6830echo $ECHO_N "checking if $CC supports compile flag -ftrapv and linking succeeds... $ECHO_C" >&6; }
6831	saved_CFLAGS="$CFLAGS"
6832	CFLAGS="$CFLAGS $WERROR -ftrapv"
6833	_define_flag=""
6834	test "x$_define_flag" = "x" && _define_flag="-ftrapv"
6835	cat >conftest.$ac_ext <<_ACEOF
6836/* confdefs.h.  */
6837_ACEOF
6838cat confdefs.h >>conftest.$ac_ext
6839cat >>conftest.$ac_ext <<_ACEOF
6840/* end confdefs.h.  */
6841
6842#include <stdlib.h>
6843#include <stdio.h>
6844int main(int argc, char **argv) {
6845	/* Some math to catch -ftrapv problems in the toolchain */
6846	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
6847	float l = i * 2.1;
6848	double m = l / 0.5;
6849	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
6850	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
6851	exit(0);
6852}
6853
6854_ACEOF
6855rm -f conftest.$ac_objext conftest$ac_exeext
6856if { (ac_try="$ac_link"
6857case "(($ac_try" in
6858  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6859  *) ac_try_echo=$ac_try;;
6860esac
6861eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6862  (eval "$ac_link") 2>conftest.er1
6863  ac_status=$?
6864  grep -v '^ *+' conftest.er1 >conftest.err
6865  rm -f conftest.er1
6866  cat conftest.err >&5
6867  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6868  (exit $ac_status); } && {
6869	 test -z "$ac_c_werror_flag" ||
6870	 test ! -s conftest.err
6871       } && test -s conftest$ac_exeext &&
6872       $as_test_x conftest$ac_exeext; then
6873
6874if `grep -i "unrecognized option" conftest.err >/dev/null`
6875then
6876		{ echo "$as_me:$LINENO: result: no" >&5
6877echo "${ECHO_T}no" >&6; }
6878		CFLAGS="$saved_CFLAGS"
6879else
6880		{ echo "$as_me:$LINENO: result: yes" >&5
6881echo "${ECHO_T}yes" >&6; }
6882		 CFLAGS="$saved_CFLAGS $_define_flag"
6883fi
6884else
6885  echo "$as_me: failed program was:" >&5
6886sed 's/^/| /' conftest.$ac_ext >&5
6887
6888	 { echo "$as_me:$LINENO: result: no" >&5
6889echo "${ECHO_T}no" >&6; }
6890		  CFLAGS="$saved_CFLAGS"
6891
6892fi
6893
6894rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6895      conftest$ac_exeext conftest.$ac_ext
6896}
6897    fi
6898	{ echo "$as_me:$LINENO: checking gcc version" >&5
6899echo $ECHO_N "checking gcc version... $ECHO_C" >&6; }
6900	GCC_VER=`$CC -v 2>&1 | $AWK '/gcc version /{print $3}'`
6901	case $GCC_VER in
6902		1.*) no_attrib_nonnull=1 ;;
6903		2.8* | 2.9*)
6904		     no_attrib_nonnull=1
6905		     ;;
6906		2.*) no_attrib_nonnull=1 ;;
6907		*) ;;
6908	esac
6909	{ echo "$as_me:$LINENO: result: $GCC_VER" >&5
6910echo "${ECHO_T}$GCC_VER" >&6; }
6911
6912	{ echo "$as_me:$LINENO: checking if $CC accepts -fno-builtin-memset" >&5
6913echo $ECHO_N "checking if $CC accepts -fno-builtin-memset... $ECHO_C" >&6; }
6914	saved_CFLAGS="$CFLAGS"
6915	CFLAGS="$CFLAGS -fno-builtin-memset"
6916	cat >conftest.$ac_ext <<_ACEOF
6917/* confdefs.h.  */
6918_ACEOF
6919cat confdefs.h >>conftest.$ac_ext
6920cat >>conftest.$ac_ext <<_ACEOF
6921/* end confdefs.h.  */
6922 #include <string.h>
6923int
6924main ()
6925{
6926 char b[10]; memset(b, 0, sizeof(b));
6927  ;
6928  return 0;
6929}
6930_ACEOF
6931rm -f conftest.$ac_objext conftest$ac_exeext
6932if { (ac_try="$ac_link"
6933case "(($ac_try" in
6934  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6935  *) ac_try_echo=$ac_try;;
6936esac
6937eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
6938  (eval "$ac_link") 2>conftest.er1
6939  ac_status=$?
6940  grep -v '^ *+' conftest.er1 >conftest.err
6941  rm -f conftest.er1
6942  cat conftest.err >&5
6943  echo "$as_me:$LINENO: \$? = $ac_status" >&5
6944  (exit $ac_status); } && {
6945	 test -z "$ac_c_werror_flag" ||
6946	 test ! -s conftest.err
6947       } && test -s conftest$ac_exeext &&
6948       $as_test_x conftest$ac_exeext; then
6949   { echo "$as_me:$LINENO: result: yes" >&5
6950echo "${ECHO_T}yes" >&6; }
6951else
6952  echo "$as_me: failed program was:" >&5
6953sed 's/^/| /' conftest.$ac_ext >&5
6954
6955	 { echo "$as_me:$LINENO: result: no" >&5
6956echo "${ECHO_T}no" >&6; }
6957		  CFLAGS="$saved_CFLAGS"
6958
6959fi
6960
6961rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6962      conftest$ac_exeext conftest.$ac_ext
6963
6964	# -fstack-protector-all doesn't always work for some GCC versions
6965	# and/or platforms, so we test if we can.  If it's not supported
6966	# on a given platform gcc will emit a warning so we use -Werror.
6967	if test "x$use_stack_protector" = "x1"; then
6968	    for t in -fstack-protector-strong -fstack-protector-all \
6969		    -fstack-protector; do
6970		{ echo "$as_me:$LINENO: checking if $CC supports $t" >&5
6971echo $ECHO_N "checking if $CC supports $t... $ECHO_C" >&6; }
6972		saved_CFLAGS="$CFLAGS"
6973		saved_LDFLAGS="$LDFLAGS"
6974		CFLAGS="$CFLAGS $t -Werror"
6975		LDFLAGS="$LDFLAGS $t -Werror"
6976		cat >conftest.$ac_ext <<_ACEOF
6977/* confdefs.h.  */
6978_ACEOF
6979cat confdefs.h >>conftest.$ac_ext
6980cat >>conftest.$ac_ext <<_ACEOF
6981/* end confdefs.h.  */
6982 #include <stdio.h>
6983int
6984main ()
6985{
6986
6987	char x[256];
6988	snprintf(x, sizeof(x), "XXX");
6989
6990  ;
6991  return 0;
6992}
6993_ACEOF
6994rm -f conftest.$ac_objext conftest$ac_exeext
6995if { (ac_try="$ac_link"
6996case "(($ac_try" in
6997  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6998  *) ac_try_echo=$ac_try;;
6999esac
7000eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7001  (eval "$ac_link") 2>conftest.er1
7002  ac_status=$?
7003  grep -v '^ *+' conftest.er1 >conftest.err
7004  rm -f conftest.er1
7005  cat conftest.err >&5
7006  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7007  (exit $ac_status); } && {
7008	 test -z "$ac_c_werror_flag" ||
7009	 test ! -s conftest.err
7010       } && test -s conftest$ac_exeext &&
7011       $as_test_x conftest$ac_exeext; then
7012   { echo "$as_me:$LINENO: result: yes" >&5
7013echo "${ECHO_T}yes" >&6; }
7014		      CFLAGS="$saved_CFLAGS $t"
7015		      LDFLAGS="$saved_LDFLAGS $t"
7016		      { echo "$as_me:$LINENO: checking if $t works" >&5
7017echo $ECHO_N "checking if $t works... $ECHO_C" >&6; }
7018		      if test "$cross_compiling" = yes; then
7019   { echo "$as_me:$LINENO: WARNING: cross compiling: cannot test" >&5
7020echo "$as_me: WARNING: cross compiling: cannot test" >&2;}
7021			  break
7022
7023else
7024  cat >conftest.$ac_ext <<_ACEOF
7025/* confdefs.h.  */
7026_ACEOF
7027cat confdefs.h >>conftest.$ac_ext
7028cat >>conftest.$ac_ext <<_ACEOF
7029/* end confdefs.h.  */
7030 #include <stdio.h>
7031int
7032main ()
7033{
7034
7035	char x[256];
7036	snprintf(x, sizeof(x), "XXX");
7037
7038  ;
7039  return 0;
7040}
7041_ACEOF
7042rm -f conftest$ac_exeext
7043if { (ac_try="$ac_link"
7044case "(($ac_try" in
7045  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7046  *) ac_try_echo=$ac_try;;
7047esac
7048eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7049  (eval "$ac_link") 2>&5
7050  ac_status=$?
7051  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7052  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
7053  { (case "(($ac_try" in
7054  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7055  *) ac_try_echo=$ac_try;;
7056esac
7057eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7058  (eval "$ac_try") 2>&5
7059  ac_status=$?
7060  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7061  (exit $ac_status); }; }; then
7062   { echo "$as_me:$LINENO: result: yes" >&5
7063echo "${ECHO_T}yes" >&6; }
7064			  break
7065else
7066  echo "$as_me: program exited with status $ac_status" >&5
7067echo "$as_me: failed program was:" >&5
7068sed 's/^/| /' conftest.$ac_ext >&5
7069
7070( exit $ac_status )
7071 { echo "$as_me:$LINENO: result: no" >&5
7072echo "${ECHO_T}no" >&6; }
7073fi
7074rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
7075fi
7076
7077
7078
7079else
7080  echo "$as_me: failed program was:" >&5
7081sed 's/^/| /' conftest.$ac_ext >&5
7082
7083	 { echo "$as_me:$LINENO: result: no" >&5
7084echo "${ECHO_T}no" >&6; }
7085
7086fi
7087
7088rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7089      conftest$ac_exeext conftest.$ac_ext
7090		CFLAGS="$saved_CFLAGS"
7091		LDFLAGS="$saved_LDFLAGS"
7092	    done
7093	fi
7094
7095	if test -z "$have_llong_max"; then
7096		# retry LLONG_MAX with -std=gnu99, needed on some Linuxes
7097		unset ac_cv_have_decl_LLONG_MAX
7098		saved_CFLAGS="$CFLAGS"
7099		CFLAGS="$CFLAGS -std=gnu99"
7100		{ echo "$as_me:$LINENO: checking whether LLONG_MAX is declared" >&5
7101echo $ECHO_N "checking whether LLONG_MAX is declared... $ECHO_C" >&6; }
7102if test "${ac_cv_have_decl_LLONG_MAX+set}" = set; then
7103  echo $ECHO_N "(cached) $ECHO_C" >&6
7104else
7105  cat >conftest.$ac_ext <<_ACEOF
7106/* confdefs.h.  */
7107_ACEOF
7108cat confdefs.h >>conftest.$ac_ext
7109cat >>conftest.$ac_ext <<_ACEOF
7110/* end confdefs.h.  */
7111#include <limits.h>
7112
7113
7114int
7115main ()
7116{
7117#ifndef LLONG_MAX
7118  (void) LLONG_MAX;
7119#endif
7120
7121  ;
7122  return 0;
7123}
7124_ACEOF
7125rm -f conftest.$ac_objext
7126if { (ac_try="$ac_compile"
7127case "(($ac_try" in
7128  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7129  *) ac_try_echo=$ac_try;;
7130esac
7131eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7132  (eval "$ac_compile") 2>conftest.er1
7133  ac_status=$?
7134  grep -v '^ *+' conftest.er1 >conftest.err
7135  rm -f conftest.er1
7136  cat conftest.err >&5
7137  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7138  (exit $ac_status); } && {
7139	 test -z "$ac_c_werror_flag" ||
7140	 test ! -s conftest.err
7141       } && test -s conftest.$ac_objext; then
7142  ac_cv_have_decl_LLONG_MAX=yes
7143else
7144  echo "$as_me: failed program was:" >&5
7145sed 's/^/| /' conftest.$ac_ext >&5
7146
7147	ac_cv_have_decl_LLONG_MAX=no
7148fi
7149
7150rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7151fi
7152{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_LLONG_MAX" >&5
7153echo "${ECHO_T}$ac_cv_have_decl_LLONG_MAX" >&6; }
7154if test $ac_cv_have_decl_LLONG_MAX = yes; then
7155  have_llong_max=1
7156else
7157  CFLAGS="$saved_CFLAGS"
7158fi
7159
7160	fi
7161fi
7162
7163{ echo "$as_me:$LINENO: checking if compiler allows __attribute__ on return types" >&5
7164echo $ECHO_N "checking if compiler allows __attribute__ on return types... $ECHO_C" >&6; }
7165cat >conftest.$ac_ext <<_ACEOF
7166/* confdefs.h.  */
7167_ACEOF
7168cat confdefs.h >>conftest.$ac_ext
7169cat >>conftest.$ac_ext <<_ACEOF
7170/* end confdefs.h.  */
7171
7172#include <stdlib.h>
7173__attribute__((__unused__)) static void foo(void){return;}
7174int
7175main ()
7176{
7177 exit(0);
7178  ;
7179  return 0;
7180}
7181_ACEOF
7182rm -f conftest.$ac_objext
7183if { (ac_try="$ac_compile"
7184case "(($ac_try" in
7185  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7186  *) ac_try_echo=$ac_try;;
7187esac
7188eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7189  (eval "$ac_compile") 2>conftest.er1
7190  ac_status=$?
7191  grep -v '^ *+' conftest.er1 >conftest.err
7192  rm -f conftest.er1
7193  cat conftest.err >&5
7194  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7195  (exit $ac_status); } && {
7196	 test -z "$ac_c_werror_flag" ||
7197	 test ! -s conftest.err
7198       } && test -s conftest.$ac_objext; then
7199   { echo "$as_me:$LINENO: result: yes" >&5
7200echo "${ECHO_T}yes" >&6; }
7201else
7202  echo "$as_me: failed program was:" >&5
7203sed 's/^/| /' conftest.$ac_ext >&5
7204
7205	 { echo "$as_me:$LINENO: result: no" >&5
7206echo "${ECHO_T}no" >&6; }
7207
7208cat >>confdefs.h <<\_ACEOF
7209#define NO_ATTRIBUTE_ON_RETURN_TYPE 1
7210_ACEOF
7211
7212
7213fi
7214
7215rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7216
7217if test "x$no_attrib_nonnull" != "x1" ; then
7218
7219cat >>confdefs.h <<\_ACEOF
7220#define HAVE_ATTRIBUTE__NONNULL__ 1
7221_ACEOF
7222
7223fi
7224
7225
7226# Check whether --with-rpath was given.
7227if test "${with_rpath+set}" = set; then
7228  withval=$with_rpath;
7229		if test "x$withval" = "xno" ; then
7230			need_dash_r=""
7231		fi
7232		if test "x$withval" = "xyes" ; then
7233			need_dash_r=1
7234		fi
7235
7236
7237fi
7238
7239
7240# Allow user to specify flags
7241
7242# Check whether --with-cflags was given.
7243if test "${with_cflags+set}" = set; then
7244  withval=$with_cflags;
7245		if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
7246		    test "x${withval}" != "xyes"; then
7247			CFLAGS="$CFLAGS $withval"
7248		fi
7249
7250
7251fi
7252
7253
7254# Check whether --with-cppflags was given.
7255if test "${with_cppflags+set}" = set; then
7256  withval=$with_cppflags;
7257		if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
7258		    test "x${withval}" != "xyes"; then
7259			CPPFLAGS="$CPPFLAGS $withval"
7260		fi
7261
7262
7263fi
7264
7265
7266# Check whether --with-ldflags was given.
7267if test "${with_ldflags+set}" = set; then
7268  withval=$with_ldflags;
7269		if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
7270		    test "x${withval}" != "xyes"; then
7271			LDFLAGS="$LDFLAGS $withval"
7272		fi
7273
7274
7275fi
7276
7277
7278# Check whether --with-libs was given.
7279if test "${with_libs+set}" = set; then
7280  withval=$with_libs;
7281		if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
7282		    test "x${withval}" != "xyes"; then
7283			LIBS="$LIBS $withval"
7284		fi
7285
7286
7287fi
7288
7289
7290# Check whether --with-Werror was given.
7291if test "${with_Werror+set}" = set; then
7292  withval=$with_Werror;
7293		if test -n "$withval"  &&  test "x$withval" != "xno"; then
7294			werror_flags="-Werror"
7295			if test "x${withval}" != "xyes"; then
7296				werror_flags="$withval"
7297			fi
7298		fi
7299
7300
7301fi
7302
7303
7304
7305
7306
7307
7308
7309
7310
7311
7312
7313
7314
7315
7316
7317
7318
7319
7320
7321
7322
7323
7324
7325
7326
7327
7328
7329
7330
7331
7332
7333
7334
7335
7336
7337
7338
7339
7340
7341
7342
7343
7344
7345
7346
7347
7348
7349
7350
7351
7352
7353
7354
7355
7356
7357
7358
7359
7360
7361
7362
7363
7364
7365
7366
7367
7368
7369
7370
7371for ac_header in  \
7372	blf.h \
7373	bstring.h \
7374	crypt.h \
7375	crypto/sha2.h \
7376	dirent.h \
7377	endian.h \
7378	elf.h \
7379	features.h \
7380	fcntl.h \
7381	floatingpoint.h \
7382	getopt.h \
7383	glob.h \
7384	ia.h \
7385	iaf.h \
7386	inttypes.h \
7387	limits.h \
7388	locale.h \
7389	login.h \
7390	maillock.h \
7391	ndir.h \
7392	net/if_tun.h \
7393	netdb.h \
7394	netgroup.h \
7395	pam/pam_appl.h \
7396	paths.h \
7397	poll.h \
7398	pty.h \
7399	readpassphrase.h \
7400	rpc/types.h \
7401	security/pam_appl.h \
7402	sha2.h \
7403	shadow.h \
7404	stddef.h \
7405	stdint.h \
7406	string.h \
7407	strings.h \
7408	sys/audit.h \
7409	sys/bitypes.h \
7410	sys/bsdtty.h \
7411	sys/capability.h \
7412	sys/cdefs.h \
7413	sys/dir.h \
7414	sys/mman.h \
7415	sys/ndir.h \
7416	sys/poll.h \
7417	sys/prctl.h \
7418	sys/pstat.h \
7419	sys/select.h \
7420	sys/stat.h \
7421	sys/stream.h \
7422	sys/stropts.h \
7423	sys/strtio.h \
7424	sys/statvfs.h \
7425	sys/sysmacros.h \
7426	sys/time.h \
7427	sys/timers.h \
7428	time.h \
7429	tmpdir.h \
7430	ttyent.h \
7431	ucred.h \
7432	unistd.h \
7433	usersec.h \
7434	util.h \
7435	utime.h \
7436	utmp.h \
7437	utmpx.h \
7438	vis.h \
7439
7440do
7441as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7442if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
7443  { echo "$as_me:$LINENO: checking for $ac_header" >&5
7444echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
7445if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
7446  echo $ECHO_N "(cached) $ECHO_C" >&6
7447fi
7448ac_res=`eval echo '${'$as_ac_Header'}'`
7449	       { echo "$as_me:$LINENO: result: $ac_res" >&5
7450echo "${ECHO_T}$ac_res" >&6; }
7451else
7452  # Is the header compilable?
7453{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
7454echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
7455cat >conftest.$ac_ext <<_ACEOF
7456/* confdefs.h.  */
7457_ACEOF
7458cat confdefs.h >>conftest.$ac_ext
7459cat >>conftest.$ac_ext <<_ACEOF
7460/* end confdefs.h.  */
7461$ac_includes_default
7462#include <$ac_header>
7463_ACEOF
7464rm -f conftest.$ac_objext
7465if { (ac_try="$ac_compile"
7466case "(($ac_try" in
7467  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7468  *) ac_try_echo=$ac_try;;
7469esac
7470eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7471  (eval "$ac_compile") 2>conftest.er1
7472  ac_status=$?
7473  grep -v '^ *+' conftest.er1 >conftest.err
7474  rm -f conftest.er1
7475  cat conftest.err >&5
7476  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7477  (exit $ac_status); } && {
7478	 test -z "$ac_c_werror_flag" ||
7479	 test ! -s conftest.err
7480       } && test -s conftest.$ac_objext; then
7481  ac_header_compiler=yes
7482else
7483  echo "$as_me: failed program was:" >&5
7484sed 's/^/| /' conftest.$ac_ext >&5
7485
7486	ac_header_compiler=no
7487fi
7488
7489rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7490{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
7491echo "${ECHO_T}$ac_header_compiler" >&6; }
7492
7493# Is the header present?
7494{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
7495echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
7496cat >conftest.$ac_ext <<_ACEOF
7497/* confdefs.h.  */
7498_ACEOF
7499cat confdefs.h >>conftest.$ac_ext
7500cat >>conftest.$ac_ext <<_ACEOF
7501/* end confdefs.h.  */
7502#include <$ac_header>
7503_ACEOF
7504if { (ac_try="$ac_cpp conftest.$ac_ext"
7505case "(($ac_try" in
7506  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7507  *) ac_try_echo=$ac_try;;
7508esac
7509eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7510  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
7511  ac_status=$?
7512  grep -v '^ *+' conftest.er1 >conftest.err
7513  rm -f conftest.er1
7514  cat conftest.err >&5
7515  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7516  (exit $ac_status); } >/dev/null && {
7517	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
7518	 test ! -s conftest.err
7519       }; then
7520  ac_header_preproc=yes
7521else
7522  echo "$as_me: failed program was:" >&5
7523sed 's/^/| /' conftest.$ac_ext >&5
7524
7525  ac_header_preproc=no
7526fi
7527
7528rm -f conftest.err conftest.$ac_ext
7529{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
7530echo "${ECHO_T}$ac_header_preproc" >&6; }
7531
7532# So?  What about this header?
7533case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
7534  yes:no: )
7535    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
7536echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
7537    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
7538echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
7539    ac_header_preproc=yes
7540    ;;
7541  no:yes:* )
7542    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
7543echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
7544    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
7545echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
7546    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
7547echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
7548    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
7549echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
7550    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
7551echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
7552    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
7553echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
7554    ( cat <<\_ASBOX
7555## ------------------------------------------- ##
7556## Report this to openssh-unix-dev@mindrot.org ##
7557## ------------------------------------------- ##
7558_ASBOX
7559     ) | sed "s/^/$as_me: WARNING:     /" >&2
7560    ;;
7561esac
7562{ echo "$as_me:$LINENO: checking for $ac_header" >&5
7563echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
7564if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
7565  echo $ECHO_N "(cached) $ECHO_C" >&6
7566else
7567  eval "$as_ac_Header=\$ac_header_preproc"
7568fi
7569ac_res=`eval echo '${'$as_ac_Header'}'`
7570	       { echo "$as_me:$LINENO: result: $ac_res" >&5
7571echo "${ECHO_T}$ac_res" >&6; }
7572
7573fi
7574if test `eval echo '${'$as_ac_Header'}'` = yes; then
7575  cat >>confdefs.h <<_ACEOF
7576#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7577_ACEOF
7578
7579fi
7580
7581done
7582
7583
7584# lastlog.h requires sys/time.h to be included first on Solaris
7585
7586for ac_header in lastlog.h
7587do
7588as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7589{ echo "$as_me:$LINENO: checking for $ac_header" >&5
7590echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
7591if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
7592  echo $ECHO_N "(cached) $ECHO_C" >&6
7593else
7594  cat >conftest.$ac_ext <<_ACEOF
7595/* confdefs.h.  */
7596_ACEOF
7597cat confdefs.h >>conftest.$ac_ext
7598cat >>conftest.$ac_ext <<_ACEOF
7599/* end confdefs.h.  */
7600
7601#ifdef HAVE_SYS_TIME_H
7602# include <sys/time.h>
7603#endif
7604
7605
7606#include <$ac_header>
7607_ACEOF
7608rm -f conftest.$ac_objext
7609if { (ac_try="$ac_compile"
7610case "(($ac_try" in
7611  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7612  *) ac_try_echo=$ac_try;;
7613esac
7614eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7615  (eval "$ac_compile") 2>conftest.er1
7616  ac_status=$?
7617  grep -v '^ *+' conftest.er1 >conftest.err
7618  rm -f conftest.er1
7619  cat conftest.err >&5
7620  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7621  (exit $ac_status); } && {
7622	 test -z "$ac_c_werror_flag" ||
7623	 test ! -s conftest.err
7624       } && test -s conftest.$ac_objext; then
7625  eval "$as_ac_Header=yes"
7626else
7627  echo "$as_me: failed program was:" >&5
7628sed 's/^/| /' conftest.$ac_ext >&5
7629
7630	eval "$as_ac_Header=no"
7631fi
7632
7633rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7634fi
7635ac_res=`eval echo '${'$as_ac_Header'}'`
7636	       { echo "$as_me:$LINENO: result: $ac_res" >&5
7637echo "${ECHO_T}$ac_res" >&6; }
7638if test `eval echo '${'$as_ac_Header'}'` = yes; then
7639  cat >>confdefs.h <<_ACEOF
7640#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7641_ACEOF
7642
7643fi
7644
7645done
7646
7647
7648# sys/ptms.h requires sys/stream.h to be included first on Solaris
7649
7650for ac_header in sys/ptms.h
7651do
7652as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7653{ echo "$as_me:$LINENO: checking for $ac_header" >&5
7654echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
7655if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
7656  echo $ECHO_N "(cached) $ECHO_C" >&6
7657else
7658  cat >conftest.$ac_ext <<_ACEOF
7659/* confdefs.h.  */
7660_ACEOF
7661cat confdefs.h >>conftest.$ac_ext
7662cat >>conftest.$ac_ext <<_ACEOF
7663/* end confdefs.h.  */
7664
7665#ifdef HAVE_SYS_STREAM_H
7666# include <sys/stream.h>
7667#endif
7668
7669
7670#include <$ac_header>
7671_ACEOF
7672rm -f conftest.$ac_objext
7673if { (ac_try="$ac_compile"
7674case "(($ac_try" in
7675  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7676  *) ac_try_echo=$ac_try;;
7677esac
7678eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7679  (eval "$ac_compile") 2>conftest.er1
7680  ac_status=$?
7681  grep -v '^ *+' conftest.er1 >conftest.err
7682  rm -f conftest.er1
7683  cat conftest.err >&5
7684  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7685  (exit $ac_status); } && {
7686	 test -z "$ac_c_werror_flag" ||
7687	 test ! -s conftest.err
7688       } && test -s conftest.$ac_objext; then
7689  eval "$as_ac_Header=yes"
7690else
7691  echo "$as_me: failed program was:" >&5
7692sed 's/^/| /' conftest.$ac_ext >&5
7693
7694	eval "$as_ac_Header=no"
7695fi
7696
7697rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7698fi
7699ac_res=`eval echo '${'$as_ac_Header'}'`
7700	       { echo "$as_me:$LINENO: result: $ac_res" >&5
7701echo "${ECHO_T}$ac_res" >&6; }
7702if test `eval echo '${'$as_ac_Header'}'` = yes; then
7703  cat >>confdefs.h <<_ACEOF
7704#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7705_ACEOF
7706
7707fi
7708
7709done
7710
7711
7712# login_cap.h requires sys/types.h on NetBSD
7713
7714for ac_header in login_cap.h
7715do
7716as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7717{ echo "$as_me:$LINENO: checking for $ac_header" >&5
7718echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
7719if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
7720  echo $ECHO_N "(cached) $ECHO_C" >&6
7721else
7722  cat >conftest.$ac_ext <<_ACEOF
7723/* confdefs.h.  */
7724_ACEOF
7725cat confdefs.h >>conftest.$ac_ext
7726cat >>conftest.$ac_ext <<_ACEOF
7727/* end confdefs.h.  */
7728
7729#include <sys/types.h>
7730
7731
7732#include <$ac_header>
7733_ACEOF
7734rm -f conftest.$ac_objext
7735if { (ac_try="$ac_compile"
7736case "(($ac_try" in
7737  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7738  *) ac_try_echo=$ac_try;;
7739esac
7740eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7741  (eval "$ac_compile") 2>conftest.er1
7742  ac_status=$?
7743  grep -v '^ *+' conftest.er1 >conftest.err
7744  rm -f conftest.er1
7745  cat conftest.err >&5
7746  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7747  (exit $ac_status); } && {
7748	 test -z "$ac_c_werror_flag" ||
7749	 test ! -s conftest.err
7750       } && test -s conftest.$ac_objext; then
7751  eval "$as_ac_Header=yes"
7752else
7753  echo "$as_me: failed program was:" >&5
7754sed 's/^/| /' conftest.$ac_ext >&5
7755
7756	eval "$as_ac_Header=no"
7757fi
7758
7759rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7760fi
7761ac_res=`eval echo '${'$as_ac_Header'}'`
7762	       { echo "$as_me:$LINENO: result: $ac_res" >&5
7763echo "${ECHO_T}$ac_res" >&6; }
7764if test `eval echo '${'$as_ac_Header'}'` = yes; then
7765  cat >>confdefs.h <<_ACEOF
7766#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7767_ACEOF
7768
7769fi
7770
7771done
7772
7773
7774# older BSDs need sys/param.h before sys/mount.h
7775
7776for ac_header in sys/mount.h
7777do
7778as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7779{ echo "$as_me:$LINENO: checking for $ac_header" >&5
7780echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
7781if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
7782  echo $ECHO_N "(cached) $ECHO_C" >&6
7783else
7784  cat >conftest.$ac_ext <<_ACEOF
7785/* confdefs.h.  */
7786_ACEOF
7787cat confdefs.h >>conftest.$ac_ext
7788cat >>conftest.$ac_ext <<_ACEOF
7789/* end confdefs.h.  */
7790
7791#include <sys/param.h>
7792
7793
7794#include <$ac_header>
7795_ACEOF
7796rm -f conftest.$ac_objext
7797if { (ac_try="$ac_compile"
7798case "(($ac_try" in
7799  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7800  *) ac_try_echo=$ac_try;;
7801esac
7802eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7803  (eval "$ac_compile") 2>conftest.er1
7804  ac_status=$?
7805  grep -v '^ *+' conftest.er1 >conftest.err
7806  rm -f conftest.er1
7807  cat conftest.err >&5
7808  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7809  (exit $ac_status); } && {
7810	 test -z "$ac_c_werror_flag" ||
7811	 test ! -s conftest.err
7812       } && test -s conftest.$ac_objext; then
7813  eval "$as_ac_Header=yes"
7814else
7815  echo "$as_me: failed program was:" >&5
7816sed 's/^/| /' conftest.$ac_ext >&5
7817
7818	eval "$as_ac_Header=no"
7819fi
7820
7821rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7822fi
7823ac_res=`eval echo '${'$as_ac_Header'}'`
7824	       { echo "$as_me:$LINENO: result: $ac_res" >&5
7825echo "${ECHO_T}$ac_res" >&6; }
7826if test `eval echo '${'$as_ac_Header'}'` = yes; then
7827  cat >>confdefs.h <<_ACEOF
7828#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7829_ACEOF
7830
7831fi
7832
7833done
7834
7835
7836# Android requires sys/socket.h to be included before sys/un.h
7837
7838for ac_header in sys/un.h
7839do
7840as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
7841{ echo "$as_me:$LINENO: checking for $ac_header" >&5
7842echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
7843if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
7844  echo $ECHO_N "(cached) $ECHO_C" >&6
7845else
7846  cat >conftest.$ac_ext <<_ACEOF
7847/* confdefs.h.  */
7848_ACEOF
7849cat confdefs.h >>conftest.$ac_ext
7850cat >>conftest.$ac_ext <<_ACEOF
7851/* end confdefs.h.  */
7852
7853#include <sys/types.h>
7854#include <sys/socket.h>
7855
7856
7857#include <$ac_header>
7858_ACEOF
7859rm -f conftest.$ac_objext
7860if { (ac_try="$ac_compile"
7861case "(($ac_try" in
7862  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7863  *) ac_try_echo=$ac_try;;
7864esac
7865eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7866  (eval "$ac_compile") 2>conftest.er1
7867  ac_status=$?
7868  grep -v '^ *+' conftest.er1 >conftest.err
7869  rm -f conftest.er1
7870  cat conftest.err >&5
7871  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7872  (exit $ac_status); } && {
7873	 test -z "$ac_c_werror_flag" ||
7874	 test ! -s conftest.err
7875       } && test -s conftest.$ac_objext; then
7876  eval "$as_ac_Header=yes"
7877else
7878  echo "$as_me: failed program was:" >&5
7879sed 's/^/| /' conftest.$ac_ext >&5
7880
7881	eval "$as_ac_Header=no"
7882fi
7883
7884rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7885fi
7886ac_res=`eval echo '${'$as_ac_Header'}'`
7887	       { echo "$as_me:$LINENO: result: $ac_res" >&5
7888echo "${ECHO_T}$ac_res" >&6; }
7889if test `eval echo '${'$as_ac_Header'}'` = yes; then
7890  cat >>confdefs.h <<_ACEOF
7891#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
7892_ACEOF
7893
7894fi
7895
7896done
7897
7898
7899# Messages for features tested for in target-specific section
7900SIA_MSG="no"
7901SPC_MSG="no"
7902SP_MSG="no"
7903
7904# Check for some target-specific stuff
7905case "$host" in
7906*-*-aix*)
7907	# Some versions of VAC won't allow macro redefinitions at
7908	# -qlanglevel=ansi, and autoconf 2.60 sometimes insists on using that
7909	# particularly with older versions of vac or xlc.
7910	# It also throws errors about null macro argments, but these are
7911	# not fatal.
7912	{ echo "$as_me:$LINENO: checking if compiler allows macro redefinitions" >&5
7913echo $ECHO_N "checking if compiler allows macro redefinitions... $ECHO_C" >&6; }
7914	cat >conftest.$ac_ext <<_ACEOF
7915/* confdefs.h.  */
7916_ACEOF
7917cat confdefs.h >>conftest.$ac_ext
7918cat >>conftest.$ac_ext <<_ACEOF
7919/* end confdefs.h.  */
7920
7921#define testmacro foo
7922#define testmacro bar
7923int
7924main ()
7925{
7926 exit(0);
7927  ;
7928  return 0;
7929}
7930_ACEOF
7931rm -f conftest.$ac_objext
7932if { (ac_try="$ac_compile"
7933case "(($ac_try" in
7934  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7935  *) ac_try_echo=$ac_try;;
7936esac
7937eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
7938  (eval "$ac_compile") 2>conftest.er1
7939  ac_status=$?
7940  grep -v '^ *+' conftest.er1 >conftest.err
7941  rm -f conftest.er1
7942  cat conftest.err >&5
7943  echo "$as_me:$LINENO: \$? = $ac_status" >&5
7944  (exit $ac_status); } && {
7945	 test -z "$ac_c_werror_flag" ||
7946	 test ! -s conftest.err
7947       } && test -s conftest.$ac_objext; then
7948   { echo "$as_me:$LINENO: result: yes" >&5
7949echo "${ECHO_T}yes" >&6; }
7950else
7951  echo "$as_me: failed program was:" >&5
7952sed 's/^/| /' conftest.$ac_ext >&5
7953
7954	 { echo "$as_me:$LINENO: result: no" >&5
7955echo "${ECHO_T}no" >&6; }
7956	      CC="`echo $CC | sed 's/-qlanglvl\=ansi//g'`"
7957	      LD="`echo $LD | sed 's/-qlanglvl\=ansi//g'`"
7958	      CFLAGS="`echo $CFLAGS | sed 's/-qlanglvl\=ansi//g'`"
7959	      CPPFLAGS="`echo $CPPFLAGS | sed 's/-qlanglvl\=ansi//g'`"
7960
7961
7962fi
7963
7964rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
7965
7966	{ echo "$as_me:$LINENO: checking how to specify blibpath for linker ($LD)" >&5
7967echo $ECHO_N "checking how to specify blibpath for linker ($LD)... $ECHO_C" >&6; }
7968	if (test -z "$blibpath"); then
7969		blibpath="/usr/lib:/lib"
7970	fi
7971	saved_LDFLAGS="$LDFLAGS"
7972	if test "$GCC" = "yes"; then
7973		flags="-Wl,-blibpath: -Wl,-rpath, -blibpath:"
7974	else
7975		flags="-blibpath: -Wl,-blibpath: -Wl,-rpath,"
7976	fi
7977	for tryflags in $flags ;do
7978		if (test -z "$blibflags"); then
7979			LDFLAGS="$saved_LDFLAGS $tryflags$blibpath"
7980			cat >conftest.$ac_ext <<_ACEOF
7981/* confdefs.h.  */
7982_ACEOF
7983cat confdefs.h >>conftest.$ac_ext
7984cat >>conftest.$ac_ext <<_ACEOF
7985/* end confdefs.h.  */
7986
7987int
7988main ()
7989{
7990
7991  ;
7992  return 0;
7993}
7994_ACEOF
7995rm -f conftest.$ac_objext conftest$ac_exeext
7996if { (ac_try="$ac_link"
7997case "(($ac_try" in
7998  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7999  *) ac_try_echo=$ac_try;;
8000esac
8001eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8002  (eval "$ac_link") 2>conftest.er1
8003  ac_status=$?
8004  grep -v '^ *+' conftest.er1 >conftest.err
8005  rm -f conftest.er1
8006  cat conftest.err >&5
8007  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8008  (exit $ac_status); } && {
8009	 test -z "$ac_c_werror_flag" ||
8010	 test ! -s conftest.err
8011       } && test -s conftest$ac_exeext &&
8012       $as_test_x conftest$ac_exeext; then
8013  blibflags=$tryflags
8014else
8015  echo "$as_me: failed program was:" >&5
8016sed 's/^/| /' conftest.$ac_ext >&5
8017
8018
8019fi
8020
8021rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8022      conftest$ac_exeext conftest.$ac_ext
8023		fi
8024	done
8025	if (test -z "$blibflags"); then
8026		{ echo "$as_me:$LINENO: result: not found" >&5
8027echo "${ECHO_T}not found" >&6; }
8028		{ { echo "$as_me:$LINENO: error: *** must be able to specify blibpath on AIX - check config.log" >&5
8029echo "$as_me: error: *** must be able to specify blibpath on AIX - check config.log" >&2;}
8030   { (exit 1); exit 1; }; }
8031	else
8032		{ echo "$as_me:$LINENO: result: $blibflags" >&5
8033echo "${ECHO_T}$blibflags" >&6; }
8034	fi
8035	LDFLAGS="$saved_LDFLAGS"
8036		{ echo "$as_me:$LINENO: checking for authenticate" >&5
8037echo $ECHO_N "checking for authenticate... $ECHO_C" >&6; }
8038if test "${ac_cv_func_authenticate+set}" = set; then
8039  echo $ECHO_N "(cached) $ECHO_C" >&6
8040else
8041  cat >conftest.$ac_ext <<_ACEOF
8042/* confdefs.h.  */
8043_ACEOF
8044cat confdefs.h >>conftest.$ac_ext
8045cat >>conftest.$ac_ext <<_ACEOF
8046/* end confdefs.h.  */
8047/* Define authenticate to an innocuous variant, in case <limits.h> declares authenticate.
8048   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
8049#define authenticate innocuous_authenticate
8050
8051/* System header to define __stub macros and hopefully few prototypes,
8052    which can conflict with char authenticate (); below.
8053    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8054    <limits.h> exists even on freestanding compilers.  */
8055
8056#ifdef __STDC__
8057# include <limits.h>
8058#else
8059# include <assert.h>
8060#endif
8061
8062#undef authenticate
8063
8064/* Override any GCC internal prototype to avoid an error.
8065   Use char because int might match the return type of a GCC
8066   builtin and then its argument prototype would still apply.  */
8067#ifdef __cplusplus
8068extern "C"
8069#endif
8070char authenticate ();
8071/* The GNU C library defines this for functions which it implements
8072    to always fail with ENOSYS.  Some functions are actually named
8073    something starting with __ and the normal name is an alias.  */
8074#if defined __stub_authenticate || defined __stub___authenticate
8075choke me
8076#endif
8077
8078int
8079main ()
8080{
8081return authenticate ();
8082  ;
8083  return 0;
8084}
8085_ACEOF
8086rm -f conftest.$ac_objext conftest$ac_exeext
8087if { (ac_try="$ac_link"
8088case "(($ac_try" in
8089  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8090  *) ac_try_echo=$ac_try;;
8091esac
8092eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8093  (eval "$ac_link") 2>conftest.er1
8094  ac_status=$?
8095  grep -v '^ *+' conftest.er1 >conftest.err
8096  rm -f conftest.er1
8097  cat conftest.err >&5
8098  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8099  (exit $ac_status); } && {
8100	 test -z "$ac_c_werror_flag" ||
8101	 test ! -s conftest.err
8102       } && test -s conftest$ac_exeext &&
8103       $as_test_x conftest$ac_exeext; then
8104  ac_cv_func_authenticate=yes
8105else
8106  echo "$as_me: failed program was:" >&5
8107sed 's/^/| /' conftest.$ac_ext >&5
8108
8109	ac_cv_func_authenticate=no
8110fi
8111
8112rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8113      conftest$ac_exeext conftest.$ac_ext
8114fi
8115{ echo "$as_me:$LINENO: result: $ac_cv_func_authenticate" >&5
8116echo "${ECHO_T}$ac_cv_func_authenticate" >&6; }
8117if test $ac_cv_func_authenticate = yes; then
8118
8119cat >>confdefs.h <<\_ACEOF
8120#define WITH_AIXAUTHENTICATE 1
8121_ACEOF
8122
8123else
8124  { echo "$as_me:$LINENO: checking for authenticate in -ls" >&5
8125echo $ECHO_N "checking for authenticate in -ls... $ECHO_C" >&6; }
8126if test "${ac_cv_lib_s_authenticate+set}" = set; then
8127  echo $ECHO_N "(cached) $ECHO_C" >&6
8128else
8129  ac_check_lib_save_LIBS=$LIBS
8130LIBS="-ls  $LIBS"
8131cat >conftest.$ac_ext <<_ACEOF
8132/* confdefs.h.  */
8133_ACEOF
8134cat confdefs.h >>conftest.$ac_ext
8135cat >>conftest.$ac_ext <<_ACEOF
8136/* end confdefs.h.  */
8137
8138/* Override any GCC internal prototype to avoid an error.
8139   Use char because int might match the return type of a GCC
8140   builtin and then its argument prototype would still apply.  */
8141#ifdef __cplusplus
8142extern "C"
8143#endif
8144char authenticate ();
8145int
8146main ()
8147{
8148return authenticate ();
8149  ;
8150  return 0;
8151}
8152_ACEOF
8153rm -f conftest.$ac_objext conftest$ac_exeext
8154if { (ac_try="$ac_link"
8155case "(($ac_try" in
8156  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8157  *) ac_try_echo=$ac_try;;
8158esac
8159eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8160  (eval "$ac_link") 2>conftest.er1
8161  ac_status=$?
8162  grep -v '^ *+' conftest.er1 >conftest.err
8163  rm -f conftest.er1
8164  cat conftest.err >&5
8165  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8166  (exit $ac_status); } && {
8167	 test -z "$ac_c_werror_flag" ||
8168	 test ! -s conftest.err
8169       } && test -s conftest$ac_exeext &&
8170       $as_test_x conftest$ac_exeext; then
8171  ac_cv_lib_s_authenticate=yes
8172else
8173  echo "$as_me: failed program was:" >&5
8174sed 's/^/| /' conftest.$ac_ext >&5
8175
8176	ac_cv_lib_s_authenticate=no
8177fi
8178
8179rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8180      conftest$ac_exeext conftest.$ac_ext
8181LIBS=$ac_check_lib_save_LIBS
8182fi
8183{ echo "$as_me:$LINENO: result: $ac_cv_lib_s_authenticate" >&5
8184echo "${ECHO_T}$ac_cv_lib_s_authenticate" >&6; }
8185if test $ac_cv_lib_s_authenticate = yes; then
8186   cat >>confdefs.h <<\_ACEOF
8187#define WITH_AIXAUTHENTICATE 1
8188_ACEOF
8189
8190				LIBS="$LIBS -ls"
8191
8192fi
8193
8194
8195fi
8196
8197		{ echo "$as_me:$LINENO: checking whether authenticate is declared" >&5
8198echo $ECHO_N "checking whether authenticate is declared... $ECHO_C" >&6; }
8199if test "${ac_cv_have_decl_authenticate+set}" = set; then
8200  echo $ECHO_N "(cached) $ECHO_C" >&6
8201else
8202  cat >conftest.$ac_ext <<_ACEOF
8203/* confdefs.h.  */
8204_ACEOF
8205cat confdefs.h >>conftest.$ac_ext
8206cat >>conftest.$ac_ext <<_ACEOF
8207/* end confdefs.h.  */
8208#include <usersec.h>
8209
8210int
8211main ()
8212{
8213#ifndef authenticate
8214  (void) authenticate;
8215#endif
8216
8217  ;
8218  return 0;
8219}
8220_ACEOF
8221rm -f conftest.$ac_objext
8222if { (ac_try="$ac_compile"
8223case "(($ac_try" in
8224  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8225  *) ac_try_echo=$ac_try;;
8226esac
8227eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8228  (eval "$ac_compile") 2>conftest.er1
8229  ac_status=$?
8230  grep -v '^ *+' conftest.er1 >conftest.err
8231  rm -f conftest.er1
8232  cat conftest.err >&5
8233  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8234  (exit $ac_status); } && {
8235	 test -z "$ac_c_werror_flag" ||
8236	 test ! -s conftest.err
8237       } && test -s conftest.$ac_objext; then
8238  ac_cv_have_decl_authenticate=yes
8239else
8240  echo "$as_me: failed program was:" >&5
8241sed 's/^/| /' conftest.$ac_ext >&5
8242
8243	ac_cv_have_decl_authenticate=no
8244fi
8245
8246rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8247fi
8248{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_authenticate" >&5
8249echo "${ECHO_T}$ac_cv_have_decl_authenticate" >&6; }
8250if test $ac_cv_have_decl_authenticate = yes; then
8251
8252cat >>confdefs.h <<_ACEOF
8253#define HAVE_DECL_AUTHENTICATE 1
8254_ACEOF
8255
8256
8257else
8258  cat >>confdefs.h <<_ACEOF
8259#define HAVE_DECL_AUTHENTICATE 0
8260_ACEOF
8261
8262
8263fi
8264{ echo "$as_me:$LINENO: checking whether loginrestrictions is declared" >&5
8265echo $ECHO_N "checking whether loginrestrictions is declared... $ECHO_C" >&6; }
8266if test "${ac_cv_have_decl_loginrestrictions+set}" = set; then
8267  echo $ECHO_N "(cached) $ECHO_C" >&6
8268else
8269  cat >conftest.$ac_ext <<_ACEOF
8270/* confdefs.h.  */
8271_ACEOF
8272cat confdefs.h >>conftest.$ac_ext
8273cat >>conftest.$ac_ext <<_ACEOF
8274/* end confdefs.h.  */
8275#include <usersec.h>
8276
8277int
8278main ()
8279{
8280#ifndef loginrestrictions
8281  (void) loginrestrictions;
8282#endif
8283
8284  ;
8285  return 0;
8286}
8287_ACEOF
8288rm -f conftest.$ac_objext
8289if { (ac_try="$ac_compile"
8290case "(($ac_try" in
8291  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8292  *) ac_try_echo=$ac_try;;
8293esac
8294eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8295  (eval "$ac_compile") 2>conftest.er1
8296  ac_status=$?
8297  grep -v '^ *+' conftest.er1 >conftest.err
8298  rm -f conftest.er1
8299  cat conftest.err >&5
8300  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8301  (exit $ac_status); } && {
8302	 test -z "$ac_c_werror_flag" ||
8303	 test ! -s conftest.err
8304       } && test -s conftest.$ac_objext; then
8305  ac_cv_have_decl_loginrestrictions=yes
8306else
8307  echo "$as_me: failed program was:" >&5
8308sed 's/^/| /' conftest.$ac_ext >&5
8309
8310	ac_cv_have_decl_loginrestrictions=no
8311fi
8312
8313rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8314fi
8315{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_loginrestrictions" >&5
8316echo "${ECHO_T}$ac_cv_have_decl_loginrestrictions" >&6; }
8317if test $ac_cv_have_decl_loginrestrictions = yes; then
8318
8319cat >>confdefs.h <<_ACEOF
8320#define HAVE_DECL_LOGINRESTRICTIONS 1
8321_ACEOF
8322
8323
8324else
8325  cat >>confdefs.h <<_ACEOF
8326#define HAVE_DECL_LOGINRESTRICTIONS 0
8327_ACEOF
8328
8329
8330fi
8331{ echo "$as_me:$LINENO: checking whether loginsuccess is declared" >&5
8332echo $ECHO_N "checking whether loginsuccess is declared... $ECHO_C" >&6; }
8333if test "${ac_cv_have_decl_loginsuccess+set}" = set; then
8334  echo $ECHO_N "(cached) $ECHO_C" >&6
8335else
8336  cat >conftest.$ac_ext <<_ACEOF
8337/* confdefs.h.  */
8338_ACEOF
8339cat confdefs.h >>conftest.$ac_ext
8340cat >>conftest.$ac_ext <<_ACEOF
8341/* end confdefs.h.  */
8342#include <usersec.h>
8343
8344int
8345main ()
8346{
8347#ifndef loginsuccess
8348  (void) loginsuccess;
8349#endif
8350
8351  ;
8352  return 0;
8353}
8354_ACEOF
8355rm -f conftest.$ac_objext
8356if { (ac_try="$ac_compile"
8357case "(($ac_try" in
8358  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8359  *) ac_try_echo=$ac_try;;
8360esac
8361eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8362  (eval "$ac_compile") 2>conftest.er1
8363  ac_status=$?
8364  grep -v '^ *+' conftest.er1 >conftest.err
8365  rm -f conftest.er1
8366  cat conftest.err >&5
8367  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8368  (exit $ac_status); } && {
8369	 test -z "$ac_c_werror_flag" ||
8370	 test ! -s conftest.err
8371       } && test -s conftest.$ac_objext; then
8372  ac_cv_have_decl_loginsuccess=yes
8373else
8374  echo "$as_me: failed program was:" >&5
8375sed 's/^/| /' conftest.$ac_ext >&5
8376
8377	ac_cv_have_decl_loginsuccess=no
8378fi
8379
8380rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8381fi
8382{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_loginsuccess" >&5
8383echo "${ECHO_T}$ac_cv_have_decl_loginsuccess" >&6; }
8384if test $ac_cv_have_decl_loginsuccess = yes; then
8385
8386cat >>confdefs.h <<_ACEOF
8387#define HAVE_DECL_LOGINSUCCESS 1
8388_ACEOF
8389
8390
8391else
8392  cat >>confdefs.h <<_ACEOF
8393#define HAVE_DECL_LOGINSUCCESS 0
8394_ACEOF
8395
8396
8397fi
8398{ echo "$as_me:$LINENO: checking whether passwdexpired is declared" >&5
8399echo $ECHO_N "checking whether passwdexpired is declared... $ECHO_C" >&6; }
8400if test "${ac_cv_have_decl_passwdexpired+set}" = set; then
8401  echo $ECHO_N "(cached) $ECHO_C" >&6
8402else
8403  cat >conftest.$ac_ext <<_ACEOF
8404/* confdefs.h.  */
8405_ACEOF
8406cat confdefs.h >>conftest.$ac_ext
8407cat >>conftest.$ac_ext <<_ACEOF
8408/* end confdefs.h.  */
8409#include <usersec.h>
8410
8411int
8412main ()
8413{
8414#ifndef passwdexpired
8415  (void) passwdexpired;
8416#endif
8417
8418  ;
8419  return 0;
8420}
8421_ACEOF
8422rm -f conftest.$ac_objext
8423if { (ac_try="$ac_compile"
8424case "(($ac_try" in
8425  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8426  *) ac_try_echo=$ac_try;;
8427esac
8428eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8429  (eval "$ac_compile") 2>conftest.er1
8430  ac_status=$?
8431  grep -v '^ *+' conftest.er1 >conftest.err
8432  rm -f conftest.er1
8433  cat conftest.err >&5
8434  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8435  (exit $ac_status); } && {
8436	 test -z "$ac_c_werror_flag" ||
8437	 test ! -s conftest.err
8438       } && test -s conftest.$ac_objext; then
8439  ac_cv_have_decl_passwdexpired=yes
8440else
8441  echo "$as_me: failed program was:" >&5
8442sed 's/^/| /' conftest.$ac_ext >&5
8443
8444	ac_cv_have_decl_passwdexpired=no
8445fi
8446
8447rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8448fi
8449{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_passwdexpired" >&5
8450echo "${ECHO_T}$ac_cv_have_decl_passwdexpired" >&6; }
8451if test $ac_cv_have_decl_passwdexpired = yes; then
8452
8453cat >>confdefs.h <<_ACEOF
8454#define HAVE_DECL_PASSWDEXPIRED 1
8455_ACEOF
8456
8457
8458else
8459  cat >>confdefs.h <<_ACEOF
8460#define HAVE_DECL_PASSWDEXPIRED 0
8461_ACEOF
8462
8463
8464fi
8465{ echo "$as_me:$LINENO: checking whether setauthdb is declared" >&5
8466echo $ECHO_N "checking whether setauthdb is declared... $ECHO_C" >&6; }
8467if test "${ac_cv_have_decl_setauthdb+set}" = set; then
8468  echo $ECHO_N "(cached) $ECHO_C" >&6
8469else
8470  cat >conftest.$ac_ext <<_ACEOF
8471/* confdefs.h.  */
8472_ACEOF
8473cat confdefs.h >>conftest.$ac_ext
8474cat >>conftest.$ac_ext <<_ACEOF
8475/* end confdefs.h.  */
8476#include <usersec.h>
8477
8478int
8479main ()
8480{
8481#ifndef setauthdb
8482  (void) setauthdb;
8483#endif
8484
8485  ;
8486  return 0;
8487}
8488_ACEOF
8489rm -f conftest.$ac_objext
8490if { (ac_try="$ac_compile"
8491case "(($ac_try" in
8492  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8493  *) ac_try_echo=$ac_try;;
8494esac
8495eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8496  (eval "$ac_compile") 2>conftest.er1
8497  ac_status=$?
8498  grep -v '^ *+' conftest.er1 >conftest.err
8499  rm -f conftest.er1
8500  cat conftest.err >&5
8501  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8502  (exit $ac_status); } && {
8503	 test -z "$ac_c_werror_flag" ||
8504	 test ! -s conftest.err
8505       } && test -s conftest.$ac_objext; then
8506  ac_cv_have_decl_setauthdb=yes
8507else
8508  echo "$as_me: failed program was:" >&5
8509sed 's/^/| /' conftest.$ac_ext >&5
8510
8511	ac_cv_have_decl_setauthdb=no
8512fi
8513
8514rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8515fi
8516{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_setauthdb" >&5
8517echo "${ECHO_T}$ac_cv_have_decl_setauthdb" >&6; }
8518if test $ac_cv_have_decl_setauthdb = yes; then
8519
8520cat >>confdefs.h <<_ACEOF
8521#define HAVE_DECL_SETAUTHDB 1
8522_ACEOF
8523
8524
8525else
8526  cat >>confdefs.h <<_ACEOF
8527#define HAVE_DECL_SETAUTHDB 0
8528_ACEOF
8529
8530
8531fi
8532
8533
8534		{ echo "$as_me:$LINENO: checking whether loginfailed is declared" >&5
8535echo $ECHO_N "checking whether loginfailed is declared... $ECHO_C" >&6; }
8536if test "${ac_cv_have_decl_loginfailed+set}" = set; then
8537  echo $ECHO_N "(cached) $ECHO_C" >&6
8538else
8539  cat >conftest.$ac_ext <<_ACEOF
8540/* confdefs.h.  */
8541_ACEOF
8542cat confdefs.h >>conftest.$ac_ext
8543cat >>conftest.$ac_ext <<_ACEOF
8544/* end confdefs.h.  */
8545#include <usersec.h>
8546
8547
8548int
8549main ()
8550{
8551#ifndef loginfailed
8552  (void) loginfailed;
8553#endif
8554
8555  ;
8556  return 0;
8557}
8558_ACEOF
8559rm -f conftest.$ac_objext
8560if { (ac_try="$ac_compile"
8561case "(($ac_try" in
8562  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8563  *) ac_try_echo=$ac_try;;
8564esac
8565eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8566  (eval "$ac_compile") 2>conftest.er1
8567  ac_status=$?
8568  grep -v '^ *+' conftest.er1 >conftest.err
8569  rm -f conftest.er1
8570  cat conftest.err >&5
8571  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8572  (exit $ac_status); } && {
8573	 test -z "$ac_c_werror_flag" ||
8574	 test ! -s conftest.err
8575       } && test -s conftest.$ac_objext; then
8576  ac_cv_have_decl_loginfailed=yes
8577else
8578  echo "$as_me: failed program was:" >&5
8579sed 's/^/| /' conftest.$ac_ext >&5
8580
8581	ac_cv_have_decl_loginfailed=no
8582fi
8583
8584rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8585fi
8586{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_loginfailed" >&5
8587echo "${ECHO_T}$ac_cv_have_decl_loginfailed" >&6; }
8588if test $ac_cv_have_decl_loginfailed = yes; then
8589
8590cat >>confdefs.h <<_ACEOF
8591#define HAVE_DECL_LOGINFAILED 1
8592_ACEOF
8593
8594{ echo "$as_me:$LINENO: checking if loginfailed takes 4 arguments" >&5
8595echo $ECHO_N "checking if loginfailed takes 4 arguments... $ECHO_C" >&6; }
8596	    cat >conftest.$ac_ext <<_ACEOF
8597/* confdefs.h.  */
8598_ACEOF
8599cat confdefs.h >>conftest.$ac_ext
8600cat >>conftest.$ac_ext <<_ACEOF
8601/* end confdefs.h.  */
8602 #include <usersec.h>
8603int
8604main ()
8605{
8606 (void)loginfailed("user","host","tty",0);
8607  ;
8608  return 0;
8609}
8610_ACEOF
8611rm -f conftest.$ac_objext
8612if { (ac_try="$ac_compile"
8613case "(($ac_try" in
8614  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8615  *) ac_try_echo=$ac_try;;
8616esac
8617eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8618  (eval "$ac_compile") 2>conftest.er1
8619  ac_status=$?
8620  grep -v '^ *+' conftest.er1 >conftest.err
8621  rm -f conftest.er1
8622  cat conftest.err >&5
8623  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8624  (exit $ac_status); } && {
8625	 test -z "$ac_c_werror_flag" ||
8626	 test ! -s conftest.err
8627       } && test -s conftest.$ac_objext; then
8628  { echo "$as_me:$LINENO: result: yes" >&5
8629echo "${ECHO_T}yes" >&6; }
8630
8631cat >>confdefs.h <<\_ACEOF
8632#define AIX_LOGINFAILED_4ARG 1
8633_ACEOF
8634
8635else
8636  echo "$as_me: failed program was:" >&5
8637sed 's/^/| /' conftest.$ac_ext >&5
8638
8639	{ echo "$as_me:$LINENO: result: no" >&5
8640echo "${ECHO_T}no" >&6; }
8641
8642fi
8643
8644rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8645else
8646  cat >>confdefs.h <<_ACEOF
8647#define HAVE_DECL_LOGINFAILED 0
8648_ACEOF
8649
8650
8651fi
8652
8653
8654
8655
8656for ac_func in getgrset setauthdb
8657do
8658as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
8659{ echo "$as_me:$LINENO: checking for $ac_func" >&5
8660echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
8661if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
8662  echo $ECHO_N "(cached) $ECHO_C" >&6
8663else
8664  cat >conftest.$ac_ext <<_ACEOF
8665/* confdefs.h.  */
8666_ACEOF
8667cat confdefs.h >>conftest.$ac_ext
8668cat >>conftest.$ac_ext <<_ACEOF
8669/* end confdefs.h.  */
8670/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
8671   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
8672#define $ac_func innocuous_$ac_func
8673
8674/* System header to define __stub macros and hopefully few prototypes,
8675    which can conflict with char $ac_func (); below.
8676    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
8677    <limits.h> exists even on freestanding compilers.  */
8678
8679#ifdef __STDC__
8680# include <limits.h>
8681#else
8682# include <assert.h>
8683#endif
8684
8685#undef $ac_func
8686
8687/* Override any GCC internal prototype to avoid an error.
8688   Use char because int might match the return type of a GCC
8689   builtin and then its argument prototype would still apply.  */
8690#ifdef __cplusplus
8691extern "C"
8692#endif
8693char $ac_func ();
8694/* The GNU C library defines this for functions which it implements
8695    to always fail with ENOSYS.  Some functions are actually named
8696    something starting with __ and the normal name is an alias.  */
8697#if defined __stub_$ac_func || defined __stub___$ac_func
8698choke me
8699#endif
8700
8701int
8702main ()
8703{
8704return $ac_func ();
8705  ;
8706  return 0;
8707}
8708_ACEOF
8709rm -f conftest.$ac_objext conftest$ac_exeext
8710if { (ac_try="$ac_link"
8711case "(($ac_try" in
8712  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8713  *) ac_try_echo=$ac_try;;
8714esac
8715eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8716  (eval "$ac_link") 2>conftest.er1
8717  ac_status=$?
8718  grep -v '^ *+' conftest.er1 >conftest.err
8719  rm -f conftest.er1
8720  cat conftest.err >&5
8721  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8722  (exit $ac_status); } && {
8723	 test -z "$ac_c_werror_flag" ||
8724	 test ! -s conftest.err
8725       } && test -s conftest$ac_exeext &&
8726       $as_test_x conftest$ac_exeext; then
8727  eval "$as_ac_var=yes"
8728else
8729  echo "$as_me: failed program was:" >&5
8730sed 's/^/| /' conftest.$ac_ext >&5
8731
8732	eval "$as_ac_var=no"
8733fi
8734
8735rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8736      conftest$ac_exeext conftest.$ac_ext
8737fi
8738ac_res=`eval echo '${'$as_ac_var'}'`
8739	       { echo "$as_me:$LINENO: result: $ac_res" >&5
8740echo "${ECHO_T}$ac_res" >&6; }
8741if test `eval echo '${'$as_ac_var'}'` = yes; then
8742  cat >>confdefs.h <<_ACEOF
8743#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
8744_ACEOF
8745
8746fi
8747done
8748
8749	{ echo "$as_me:$LINENO: checking whether F_CLOSEM is declared" >&5
8750echo $ECHO_N "checking whether F_CLOSEM is declared... $ECHO_C" >&6; }
8751if test "${ac_cv_have_decl_F_CLOSEM+set}" = set; then
8752  echo $ECHO_N "(cached) $ECHO_C" >&6
8753else
8754  cat >conftest.$ac_ext <<_ACEOF
8755/* confdefs.h.  */
8756_ACEOF
8757cat confdefs.h >>conftest.$ac_ext
8758cat >>conftest.$ac_ext <<_ACEOF
8759/* end confdefs.h.  */
8760 #include <limits.h>
8761	      #include <fcntl.h>
8762
8763
8764int
8765main ()
8766{
8767#ifndef F_CLOSEM
8768  (void) F_CLOSEM;
8769#endif
8770
8771  ;
8772  return 0;
8773}
8774_ACEOF
8775rm -f conftest.$ac_objext
8776if { (ac_try="$ac_compile"
8777case "(($ac_try" in
8778  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8779  *) ac_try_echo=$ac_try;;
8780esac
8781eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8782  (eval "$ac_compile") 2>conftest.er1
8783  ac_status=$?
8784  grep -v '^ *+' conftest.er1 >conftest.err
8785  rm -f conftest.er1
8786  cat conftest.err >&5
8787  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8788  (exit $ac_status); } && {
8789	 test -z "$ac_c_werror_flag" ||
8790	 test ! -s conftest.err
8791       } && test -s conftest.$ac_objext; then
8792  ac_cv_have_decl_F_CLOSEM=yes
8793else
8794  echo "$as_me: failed program was:" >&5
8795sed 's/^/| /' conftest.$ac_ext >&5
8796
8797	ac_cv_have_decl_F_CLOSEM=no
8798fi
8799
8800rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8801fi
8802{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_F_CLOSEM" >&5
8803echo "${ECHO_T}$ac_cv_have_decl_F_CLOSEM" >&6; }
8804if test $ac_cv_have_decl_F_CLOSEM = yes; then
8805
8806cat >>confdefs.h <<\_ACEOF
8807#define HAVE_FCNTL_CLOSEM 1
8808_ACEOF
8809
8810fi
8811
8812	check_for_aix_broken_getaddrinfo=1
8813
8814cat >>confdefs.h <<\_ACEOF
8815#define BROKEN_REALPATH 1
8816_ACEOF
8817
8818
8819cat >>confdefs.h <<\_ACEOF
8820#define SETEUID_BREAKS_SETUID 1
8821_ACEOF
8822
8823
8824cat >>confdefs.h <<\_ACEOF
8825#define BROKEN_SETREUID 1
8826_ACEOF
8827
8828
8829cat >>confdefs.h <<\_ACEOF
8830#define BROKEN_SETREGID 1
8831_ACEOF
8832
8833
8834cat >>confdefs.h <<\_ACEOF
8835#define DISABLE_LASTLOG 1
8836_ACEOF
8837
8838
8839cat >>confdefs.h <<\_ACEOF
8840#define LOGIN_NEEDS_UTMPX 1
8841_ACEOF
8842
8843
8844cat >>confdefs.h <<\_ACEOF
8845#define SPT_TYPE SPT_REUSEARGV
8846_ACEOF
8847
8848
8849cat >>confdefs.h <<\_ACEOF
8850#define SSHPAM_CHAUTHTOK_NEEDS_RUID 1
8851_ACEOF
8852
8853
8854cat >>confdefs.h <<\_ACEOF
8855#define PTY_ZEROREAD 1
8856_ACEOF
8857
8858
8859cat >>confdefs.h <<\_ACEOF
8860#define PLATFORM_SYS_DIR_UID 2
8861_ACEOF
8862
8863	;;
8864*-*-android*)
8865
8866cat >>confdefs.h <<\_ACEOF
8867#define DISABLE_UTMP 1
8868_ACEOF
8869
8870
8871cat >>confdefs.h <<\_ACEOF
8872#define DISABLE_WTMP 1
8873_ACEOF
8874
8875	;;
8876*-*-cygwin*)
8877	check_for_libcrypt_later=1
8878	LIBS="$LIBS /usr/lib/textreadmode.o"
8879
8880cat >>confdefs.h <<\_ACEOF
8881#define HAVE_CYGWIN 1
8882_ACEOF
8883
8884
8885cat >>confdefs.h <<\_ACEOF
8886#define USE_PIPES 1
8887_ACEOF
8888
8889
8890cat >>confdefs.h <<\_ACEOF
8891#define DISABLE_SHADOW 1
8892_ACEOF
8893
8894
8895cat >>confdefs.h <<\_ACEOF
8896#define NO_X11_UNIX_SOCKETS 1
8897_ACEOF
8898
8899
8900cat >>confdefs.h <<\_ACEOF
8901#define NO_IPPORT_RESERVED_CONCEPT 1
8902_ACEOF
8903
8904
8905cat >>confdefs.h <<\_ACEOF
8906#define DISABLE_FD_PASSING 1
8907_ACEOF
8908
8909
8910cat >>confdefs.h <<\_ACEOF
8911#define SSH_IOBUFSZ 65535
8912_ACEOF
8913
8914
8915cat >>confdefs.h <<\_ACEOF
8916#define FILESYSTEM_NO_BACKSLASH 1
8917_ACEOF
8918
8919	# Cygwin defines optargs, optargs as declspec(dllimport) for historical
8920	# reasons which cause compile warnings, so we disable those warnings.
8921	{
8922	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -Wno-attributes" >&5
8923echo $ECHO_N "checking if $CC supports compile flag -Wno-attributes... $ECHO_C" >&6; }
8924	saved_CFLAGS="$CFLAGS"
8925	CFLAGS="$CFLAGS $WERROR -Wno-attributes"
8926	_define_flag=""
8927	test "x$_define_flag" = "x" && _define_flag="-Wno-attributes"
8928	cat >conftest.$ac_ext <<_ACEOF
8929/* confdefs.h.  */
8930_ACEOF
8931cat confdefs.h >>conftest.$ac_ext
8932cat >>conftest.$ac_ext <<_ACEOF
8933/* end confdefs.h.  */
8934
8935#include <stdlib.h>
8936#include <stdio.h>
8937int main(int argc, char **argv) {
8938	/* Some math to catch -ftrapv problems in the toolchain */
8939	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
8940	float l = i * 2.1;
8941	double m = l / 0.5;
8942	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
8943	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
8944	exit(0);
8945}
8946
8947_ACEOF
8948rm -f conftest.$ac_objext
8949if { (ac_try="$ac_compile"
8950case "(($ac_try" in
8951  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8952  *) ac_try_echo=$ac_try;;
8953esac
8954eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
8955  (eval "$ac_compile") 2>conftest.er1
8956  ac_status=$?
8957  grep -v '^ *+' conftest.er1 >conftest.err
8958  rm -f conftest.er1
8959  cat conftest.err >&5
8960  echo "$as_me:$LINENO: \$? = $ac_status" >&5
8961  (exit $ac_status); } && {
8962	 test -z "$ac_c_werror_flag" ||
8963	 test ! -s conftest.err
8964       } && test -s conftest.$ac_objext; then
8965
8966if `grep -i "unrecognized option" conftest.err >/dev/null`
8967then
8968		{ echo "$as_me:$LINENO: result: no" >&5
8969echo "${ECHO_T}no" >&6; }
8970		CFLAGS="$saved_CFLAGS"
8971else
8972		{ echo "$as_me:$LINENO: result: yes" >&5
8973echo "${ECHO_T}yes" >&6; }
8974		 CFLAGS="$saved_CFLAGS $_define_flag"
8975fi
8976else
8977  echo "$as_me: failed program was:" >&5
8978sed 's/^/| /' conftest.$ac_ext >&5
8979
8980	 { echo "$as_me:$LINENO: result: no" >&5
8981echo "${ECHO_T}no" >&6; }
8982		  CFLAGS="$saved_CFLAGS"
8983
8984fi
8985
8986rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
8987}
8988	;;
8989*-*-dgux*)
8990
8991cat >>confdefs.h <<\_ACEOF
8992#define IP_TOS_IS_BROKEN 1
8993_ACEOF
8994
8995	cat >>confdefs.h <<\_ACEOF
8996#define SETEUID_BREAKS_SETUID 1
8997_ACEOF
8998
8999	cat >>confdefs.h <<\_ACEOF
9000#define BROKEN_SETREUID 1
9001_ACEOF
9002
9003	cat >>confdefs.h <<\_ACEOF
9004#define BROKEN_SETREGID 1
9005_ACEOF
9006
9007	;;
9008*-*-darwin*)
9009	use_pie=auto
9010	{ echo "$as_me:$LINENO: checking if we have working getaddrinfo" >&5
9011echo $ECHO_N "checking if we have working getaddrinfo... $ECHO_C" >&6; }
9012	if test "$cross_compiling" = yes; then
9013  { echo "$as_me:$LINENO: result: assume it is working" >&5
9014echo "${ECHO_T}assume it is working" >&6; }
9015else
9016  cat >conftest.$ac_ext <<_ACEOF
9017/* confdefs.h.  */
9018_ACEOF
9019cat confdefs.h >>conftest.$ac_ext
9020cat >>conftest.$ac_ext <<_ACEOF
9021/* end confdefs.h.  */
9022 #include <mach-o/dyld.h>
9023main() { if (NSVersionOfRunTimeLibrary("System") >= (60 << 16))
9024		exit(0);
9025	else
9026		exit(1);
9027}
9028
9029_ACEOF
9030rm -f conftest$ac_exeext
9031if { (ac_try="$ac_link"
9032case "(($ac_try" in
9033  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9034  *) ac_try_echo=$ac_try;;
9035esac
9036eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9037  (eval "$ac_link") 2>&5
9038  ac_status=$?
9039  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9040  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9041  { (case "(($ac_try" in
9042  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9043  *) ac_try_echo=$ac_try;;
9044esac
9045eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9046  (eval "$ac_try") 2>&5
9047  ac_status=$?
9048  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9049  (exit $ac_status); }; }; then
9050  { echo "$as_me:$LINENO: result: working" >&5
9051echo "${ECHO_T}working" >&6; }
9052else
9053  echo "$as_me: program exited with status $ac_status" >&5
9054echo "$as_me: failed program was:" >&5
9055sed 's/^/| /' conftest.$ac_ext >&5
9056
9057( exit $ac_status )
9058{ echo "$as_me:$LINENO: result: buggy" >&5
9059echo "${ECHO_T}buggy" >&6; }
9060
9061cat >>confdefs.h <<\_ACEOF
9062#define BROKEN_GETADDRINFO 1
9063_ACEOF
9064
9065
9066fi
9067rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9068fi
9069
9070
9071	cat >>confdefs.h <<\_ACEOF
9072#define SETEUID_BREAKS_SETUID 1
9073_ACEOF
9074
9075	cat >>confdefs.h <<\_ACEOF
9076#define BROKEN_SETREUID 1
9077_ACEOF
9078
9079	cat >>confdefs.h <<\_ACEOF
9080#define BROKEN_SETREGID 1
9081_ACEOF
9082
9083
9084cat >>confdefs.h <<\_ACEOF
9085#define BROKEN_GLOB 1
9086_ACEOF
9087
9088
9089cat >>confdefs.h <<_ACEOF
9090#define BIND_8_COMPAT 1
9091_ACEOF
9092
9093
9094cat >>confdefs.h <<\_ACEOF
9095#define SSH_TUN_FREEBSD 1
9096_ACEOF
9097
9098
9099cat >>confdefs.h <<\_ACEOF
9100#define SSH_TUN_COMPAT_AF 1
9101_ACEOF
9102
9103
9104cat >>confdefs.h <<\_ACEOF
9105#define SSH_TUN_PREPEND_AF 1
9106_ACEOF
9107
9108
9109	{ echo "$as_me:$LINENO: checking whether AU_IPv4 is declared" >&5
9110echo $ECHO_N "checking whether AU_IPv4 is declared... $ECHO_C" >&6; }
9111if test "${ac_cv_have_decl_AU_IPv4+set}" = set; then
9112  echo $ECHO_N "(cached) $ECHO_C" >&6
9113else
9114  cat >conftest.$ac_ext <<_ACEOF
9115/* confdefs.h.  */
9116_ACEOF
9117cat confdefs.h >>conftest.$ac_ext
9118cat >>conftest.$ac_ext <<_ACEOF
9119/* end confdefs.h.  */
9120$ac_includes_default
9121int
9122main ()
9123{
9124#ifndef AU_IPv4
9125  (void) AU_IPv4;
9126#endif
9127
9128  ;
9129  return 0;
9130}
9131_ACEOF
9132rm -f conftest.$ac_objext
9133if { (ac_try="$ac_compile"
9134case "(($ac_try" in
9135  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9136  *) ac_try_echo=$ac_try;;
9137esac
9138eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9139  (eval "$ac_compile") 2>conftest.er1
9140  ac_status=$?
9141  grep -v '^ *+' conftest.er1 >conftest.err
9142  rm -f conftest.er1
9143  cat conftest.err >&5
9144  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9145  (exit $ac_status); } && {
9146	 test -z "$ac_c_werror_flag" ||
9147	 test ! -s conftest.err
9148       } && test -s conftest.$ac_objext; then
9149  ac_cv_have_decl_AU_IPv4=yes
9150else
9151  echo "$as_me: failed program was:" >&5
9152sed 's/^/| /' conftest.$ac_ext >&5
9153
9154	ac_cv_have_decl_AU_IPv4=no
9155fi
9156
9157rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9158fi
9159{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_AU_IPv4" >&5
9160echo "${ECHO_T}$ac_cv_have_decl_AU_IPv4" >&6; }
9161if test $ac_cv_have_decl_AU_IPv4 = yes; then
9162  :
9163else
9164
9165cat >>confdefs.h <<\_ACEOF
9166#define AU_IPv4 0
9167_ACEOF
9168
9169	    #include <bsm/audit.h>
9170
9171cat >>confdefs.h <<\_ACEOF
9172#define LASTLOG_WRITE_PUTUTXLINE 1
9173_ACEOF
9174
9175
9176fi
9177
9178
9179cat >>confdefs.h <<\_ACEOF
9180#define SPT_TYPE SPT_REUSEARGV
9181_ACEOF
9182
9183
9184for ac_func in sandbox_init
9185do
9186as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
9187{ echo "$as_me:$LINENO: checking for $ac_func" >&5
9188echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
9189if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
9190  echo $ECHO_N "(cached) $ECHO_C" >&6
9191else
9192  cat >conftest.$ac_ext <<_ACEOF
9193/* confdefs.h.  */
9194_ACEOF
9195cat confdefs.h >>conftest.$ac_ext
9196cat >>conftest.$ac_ext <<_ACEOF
9197/* end confdefs.h.  */
9198/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
9199   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
9200#define $ac_func innocuous_$ac_func
9201
9202/* System header to define __stub macros and hopefully few prototypes,
9203    which can conflict with char $ac_func (); below.
9204    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9205    <limits.h> exists even on freestanding compilers.  */
9206
9207#ifdef __STDC__
9208# include <limits.h>
9209#else
9210# include <assert.h>
9211#endif
9212
9213#undef $ac_func
9214
9215/* Override any GCC internal prototype to avoid an error.
9216   Use char because int might match the return type of a GCC
9217   builtin and then its argument prototype would still apply.  */
9218#ifdef __cplusplus
9219extern "C"
9220#endif
9221char $ac_func ();
9222/* The GNU C library defines this for functions which it implements
9223    to always fail with ENOSYS.  Some functions are actually named
9224    something starting with __ and the normal name is an alias.  */
9225#if defined __stub_$ac_func || defined __stub___$ac_func
9226choke me
9227#endif
9228
9229int
9230main ()
9231{
9232return $ac_func ();
9233  ;
9234  return 0;
9235}
9236_ACEOF
9237rm -f conftest.$ac_objext conftest$ac_exeext
9238if { (ac_try="$ac_link"
9239case "(($ac_try" in
9240  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9241  *) ac_try_echo=$ac_try;;
9242esac
9243eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9244  (eval "$ac_link") 2>conftest.er1
9245  ac_status=$?
9246  grep -v '^ *+' conftest.er1 >conftest.err
9247  rm -f conftest.er1
9248  cat conftest.err >&5
9249  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9250  (exit $ac_status); } && {
9251	 test -z "$ac_c_werror_flag" ||
9252	 test ! -s conftest.err
9253       } && test -s conftest$ac_exeext &&
9254       $as_test_x conftest$ac_exeext; then
9255  eval "$as_ac_var=yes"
9256else
9257  echo "$as_me: failed program was:" >&5
9258sed 's/^/| /' conftest.$ac_ext >&5
9259
9260	eval "$as_ac_var=no"
9261fi
9262
9263rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9264      conftest$ac_exeext conftest.$ac_ext
9265fi
9266ac_res=`eval echo '${'$as_ac_var'}'`
9267	       { echo "$as_me:$LINENO: result: $ac_res" >&5
9268echo "${ECHO_T}$ac_res" >&6; }
9269if test `eval echo '${'$as_ac_var'}'` = yes; then
9270  cat >>confdefs.h <<_ACEOF
9271#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
9272_ACEOF
9273
9274fi
9275done
9276
9277
9278for ac_header in sandbox.h
9279do
9280as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9281if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9282  { echo "$as_me:$LINENO: checking for $ac_header" >&5
9283echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9284if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9285  echo $ECHO_N "(cached) $ECHO_C" >&6
9286fi
9287ac_res=`eval echo '${'$as_ac_Header'}'`
9288	       { echo "$as_me:$LINENO: result: $ac_res" >&5
9289echo "${ECHO_T}$ac_res" >&6; }
9290else
9291  # Is the header compilable?
9292{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
9293echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9294cat >conftest.$ac_ext <<_ACEOF
9295/* confdefs.h.  */
9296_ACEOF
9297cat confdefs.h >>conftest.$ac_ext
9298cat >>conftest.$ac_ext <<_ACEOF
9299/* end confdefs.h.  */
9300$ac_includes_default
9301#include <$ac_header>
9302_ACEOF
9303rm -f conftest.$ac_objext
9304if { (ac_try="$ac_compile"
9305case "(($ac_try" in
9306  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9307  *) ac_try_echo=$ac_try;;
9308esac
9309eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9310  (eval "$ac_compile") 2>conftest.er1
9311  ac_status=$?
9312  grep -v '^ *+' conftest.er1 >conftest.err
9313  rm -f conftest.er1
9314  cat conftest.err >&5
9315  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9316  (exit $ac_status); } && {
9317	 test -z "$ac_c_werror_flag" ||
9318	 test ! -s conftest.err
9319       } && test -s conftest.$ac_objext; then
9320  ac_header_compiler=yes
9321else
9322  echo "$as_me: failed program was:" >&5
9323sed 's/^/| /' conftest.$ac_ext >&5
9324
9325	ac_header_compiler=no
9326fi
9327
9328rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9329{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9330echo "${ECHO_T}$ac_header_compiler" >&6; }
9331
9332# Is the header present?
9333{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
9334echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9335cat >conftest.$ac_ext <<_ACEOF
9336/* confdefs.h.  */
9337_ACEOF
9338cat confdefs.h >>conftest.$ac_ext
9339cat >>conftest.$ac_ext <<_ACEOF
9340/* end confdefs.h.  */
9341#include <$ac_header>
9342_ACEOF
9343if { (ac_try="$ac_cpp conftest.$ac_ext"
9344case "(($ac_try" in
9345  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9346  *) ac_try_echo=$ac_try;;
9347esac
9348eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9349  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9350  ac_status=$?
9351  grep -v '^ *+' conftest.er1 >conftest.err
9352  rm -f conftest.er1
9353  cat conftest.err >&5
9354  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9355  (exit $ac_status); } >/dev/null && {
9356	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9357	 test ! -s conftest.err
9358       }; then
9359  ac_header_preproc=yes
9360else
9361  echo "$as_me: failed program was:" >&5
9362sed 's/^/| /' conftest.$ac_ext >&5
9363
9364  ac_header_preproc=no
9365fi
9366
9367rm -f conftest.err conftest.$ac_ext
9368{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9369echo "${ECHO_T}$ac_header_preproc" >&6; }
9370
9371# So?  What about this header?
9372case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9373  yes:no: )
9374    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9375echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9376    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9377echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9378    ac_header_preproc=yes
9379    ;;
9380  no:yes:* )
9381    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9382echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9383    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9384echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9385    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9386echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9387    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9388echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9389    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9390echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9391    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9392echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9393    ( cat <<\_ASBOX
9394## ------------------------------------------- ##
9395## Report this to openssh-unix-dev@mindrot.org ##
9396## ------------------------------------------- ##
9397_ASBOX
9398     ) | sed "s/^/$as_me: WARNING:     /" >&2
9399    ;;
9400esac
9401{ echo "$as_me:$LINENO: checking for $ac_header" >&5
9402echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9403if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9404  echo $ECHO_N "(cached) $ECHO_C" >&6
9405else
9406  eval "$as_ac_Header=\$ac_header_preproc"
9407fi
9408ac_res=`eval echo '${'$as_ac_Header'}'`
9409	       { echo "$as_me:$LINENO: result: $ac_res" >&5
9410echo "${ECHO_T}$ac_res" >&6; }
9411
9412fi
9413if test `eval echo '${'$as_ac_Header'}'` = yes; then
9414  cat >>confdefs.h <<_ACEOF
9415#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
9416_ACEOF
9417
9418fi
9419
9420done
9421
9422	;;
9423*-*-dragonfly*)
9424	SSHDLIBS="$SSHDLIBS -lcrypt"
9425	TEST_MALLOC_OPTIONS="AFGJPRX"
9426	;;
9427*-*-haiku*)
9428    LIBS="$LIBS -lbsd "
9429
9430{ echo "$as_me:$LINENO: checking for socket in -lnetwork" >&5
9431echo $ECHO_N "checking for socket in -lnetwork... $ECHO_C" >&6; }
9432if test "${ac_cv_lib_network_socket+set}" = set; then
9433  echo $ECHO_N "(cached) $ECHO_C" >&6
9434else
9435  ac_check_lib_save_LIBS=$LIBS
9436LIBS="-lnetwork  $LIBS"
9437cat >conftest.$ac_ext <<_ACEOF
9438/* confdefs.h.  */
9439_ACEOF
9440cat confdefs.h >>conftest.$ac_ext
9441cat >>conftest.$ac_ext <<_ACEOF
9442/* end confdefs.h.  */
9443
9444/* Override any GCC internal prototype to avoid an error.
9445   Use char because int might match the return type of a GCC
9446   builtin and then its argument prototype would still apply.  */
9447#ifdef __cplusplus
9448extern "C"
9449#endif
9450char socket ();
9451int
9452main ()
9453{
9454return socket ();
9455  ;
9456  return 0;
9457}
9458_ACEOF
9459rm -f conftest.$ac_objext conftest$ac_exeext
9460if { (ac_try="$ac_link"
9461case "(($ac_try" in
9462  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9463  *) ac_try_echo=$ac_try;;
9464esac
9465eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9466  (eval "$ac_link") 2>conftest.er1
9467  ac_status=$?
9468  grep -v '^ *+' conftest.er1 >conftest.err
9469  rm -f conftest.er1
9470  cat conftest.err >&5
9471  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9472  (exit $ac_status); } && {
9473	 test -z "$ac_c_werror_flag" ||
9474	 test ! -s conftest.err
9475       } && test -s conftest$ac_exeext &&
9476       $as_test_x conftest$ac_exeext; then
9477  ac_cv_lib_network_socket=yes
9478else
9479  echo "$as_me: failed program was:" >&5
9480sed 's/^/| /' conftest.$ac_ext >&5
9481
9482	ac_cv_lib_network_socket=no
9483fi
9484
9485rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9486      conftest$ac_exeext conftest.$ac_ext
9487LIBS=$ac_check_lib_save_LIBS
9488fi
9489{ echo "$as_me:$LINENO: result: $ac_cv_lib_network_socket" >&5
9490echo "${ECHO_T}$ac_cv_lib_network_socket" >&6; }
9491if test $ac_cv_lib_network_socket = yes; then
9492  cat >>confdefs.h <<_ACEOF
9493#define HAVE_LIBNETWORK 1
9494_ACEOF
9495
9496  LIBS="-lnetwork $LIBS"
9497
9498fi
9499
9500    cat >>confdefs.h <<\_ACEOF
9501#define HAVE_U_INT64_T 1
9502_ACEOF
9503
9504    MANTYPE=man
9505    ;;
9506*-*-hpux*)
9507	# first we define all of the options common to all HP-UX releases
9508	CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED=1"
9509	IPADDR_IN_DISPLAY=yes
9510	cat >>confdefs.h <<\_ACEOF
9511#define USE_PIPES 1
9512_ACEOF
9513
9514
9515cat >>confdefs.h <<\_ACEOF
9516#define LOGIN_NO_ENDOPT 1
9517_ACEOF
9518
9519	cat >>confdefs.h <<\_ACEOF
9520#define LOGIN_NEEDS_UTMPX 1
9521_ACEOF
9522
9523
9524cat >>confdefs.h <<\_ACEOF
9525#define LOCKED_PASSWD_STRING "*"
9526_ACEOF
9527
9528	cat >>confdefs.h <<\_ACEOF
9529#define SPT_TYPE SPT_PSTAT
9530_ACEOF
9531
9532
9533cat >>confdefs.h <<\_ACEOF
9534#define PLATFORM_SYS_DIR_UID 2
9535_ACEOF
9536
9537	maildir="/var/mail"
9538	LIBS="$LIBS -lsec"
9539
9540{ echo "$as_me:$LINENO: checking for t_error in -lxnet" >&5
9541echo $ECHO_N "checking for t_error in -lxnet... $ECHO_C" >&6; }
9542if test "${ac_cv_lib_xnet_t_error+set}" = set; then
9543  echo $ECHO_N "(cached) $ECHO_C" >&6
9544else
9545  ac_check_lib_save_LIBS=$LIBS
9546LIBS="-lxnet  $LIBS"
9547cat >conftest.$ac_ext <<_ACEOF
9548/* confdefs.h.  */
9549_ACEOF
9550cat confdefs.h >>conftest.$ac_ext
9551cat >>conftest.$ac_ext <<_ACEOF
9552/* end confdefs.h.  */
9553
9554/* Override any GCC internal prototype to avoid an error.
9555   Use char because int might match the return type of a GCC
9556   builtin and then its argument prototype would still apply.  */
9557#ifdef __cplusplus
9558extern "C"
9559#endif
9560char t_error ();
9561int
9562main ()
9563{
9564return t_error ();
9565  ;
9566  return 0;
9567}
9568_ACEOF
9569rm -f conftest.$ac_objext conftest$ac_exeext
9570if { (ac_try="$ac_link"
9571case "(($ac_try" in
9572  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9573  *) ac_try_echo=$ac_try;;
9574esac
9575eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9576  (eval "$ac_link") 2>conftest.er1
9577  ac_status=$?
9578  grep -v '^ *+' conftest.er1 >conftest.err
9579  rm -f conftest.er1
9580  cat conftest.err >&5
9581  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9582  (exit $ac_status); } && {
9583	 test -z "$ac_c_werror_flag" ||
9584	 test ! -s conftest.err
9585       } && test -s conftest$ac_exeext &&
9586       $as_test_x conftest$ac_exeext; then
9587  ac_cv_lib_xnet_t_error=yes
9588else
9589  echo "$as_me: failed program was:" >&5
9590sed 's/^/| /' conftest.$ac_ext >&5
9591
9592	ac_cv_lib_xnet_t_error=no
9593fi
9594
9595rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9596      conftest$ac_exeext conftest.$ac_ext
9597LIBS=$ac_check_lib_save_LIBS
9598fi
9599{ echo "$as_me:$LINENO: result: $ac_cv_lib_xnet_t_error" >&5
9600echo "${ECHO_T}$ac_cv_lib_xnet_t_error" >&6; }
9601if test $ac_cv_lib_xnet_t_error = yes; then
9602  cat >>confdefs.h <<_ACEOF
9603#define HAVE_LIBXNET 1
9604_ACEOF
9605
9606  LIBS="-lxnet $LIBS"
9607
9608else
9609  { { echo "$as_me:$LINENO: error: *** -lxnet needed on HP-UX - check config.log ***" >&5
9610echo "$as_me: error: *** -lxnet needed on HP-UX - check config.log ***" >&2;}
9611   { (exit 1); exit 1; }; }
9612fi
9613
9614
9615	# next, we define all of the options specific to major releases
9616	case "$host" in
9617	*-*-hpux10*)
9618		if test -z "$GCC"; then
9619			CFLAGS="$CFLAGS -Ae"
9620		fi
9621		;;
9622	*-*-hpux11*)
9623
9624cat >>confdefs.h <<\_ACEOF
9625#define PAM_SUN_CODEBASE 1
9626_ACEOF
9627
9628
9629cat >>confdefs.h <<\_ACEOF
9630#define DISABLE_UTMP 1
9631_ACEOF
9632
9633
9634cat >>confdefs.h <<\_ACEOF
9635#define USE_BTMP 1
9636_ACEOF
9637
9638		check_for_hpux_broken_getaddrinfo=1
9639		check_for_conflicting_getspnam=1
9640		;;
9641	esac
9642
9643	# lastly, we define options specific to minor releases
9644	case "$host" in
9645	*-*-hpux10.26)
9646
9647cat >>confdefs.h <<\_ACEOF
9648#define HAVE_SECUREWARE 1
9649_ACEOF
9650
9651		disable_ptmx_check=yes
9652		LIBS="$LIBS -lsecpw"
9653		;;
9654	esac
9655	;;
9656*-*-irix5*)
9657	PATH="$PATH:/usr/etc"
9658
9659cat >>confdefs.h <<\_ACEOF
9660#define BROKEN_INET_NTOA 1
9661_ACEOF
9662
9663	cat >>confdefs.h <<\_ACEOF
9664#define SETEUID_BREAKS_SETUID 1
9665_ACEOF
9666
9667	cat >>confdefs.h <<\_ACEOF
9668#define BROKEN_SETREUID 1
9669_ACEOF
9670
9671	cat >>confdefs.h <<\_ACEOF
9672#define BROKEN_SETREGID 1
9673_ACEOF
9674
9675
9676cat >>confdefs.h <<\_ACEOF
9677#define WITH_ABBREV_NO_TTY 1
9678_ACEOF
9679
9680	cat >>confdefs.h <<\_ACEOF
9681#define LOCKED_PASSWD_STRING "*LK*"
9682_ACEOF
9683
9684	;;
9685*-*-irix6*)
9686	PATH="$PATH:/usr/etc"
9687
9688cat >>confdefs.h <<\_ACEOF
9689#define WITH_IRIX_ARRAY 1
9690_ACEOF
9691
9692
9693cat >>confdefs.h <<\_ACEOF
9694#define WITH_IRIX_PROJECT 1
9695_ACEOF
9696
9697
9698cat >>confdefs.h <<\_ACEOF
9699#define WITH_IRIX_AUDIT 1
9700_ACEOF
9701
9702	{ echo "$as_me:$LINENO: checking for jlimit_startjob" >&5
9703echo $ECHO_N "checking for jlimit_startjob... $ECHO_C" >&6; }
9704if test "${ac_cv_func_jlimit_startjob+set}" = set; then
9705  echo $ECHO_N "(cached) $ECHO_C" >&6
9706else
9707  cat >conftest.$ac_ext <<_ACEOF
9708/* confdefs.h.  */
9709_ACEOF
9710cat confdefs.h >>conftest.$ac_ext
9711cat >>conftest.$ac_ext <<_ACEOF
9712/* end confdefs.h.  */
9713/* Define jlimit_startjob to an innocuous variant, in case <limits.h> declares jlimit_startjob.
9714   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
9715#define jlimit_startjob innocuous_jlimit_startjob
9716
9717/* System header to define __stub macros and hopefully few prototypes,
9718    which can conflict with char jlimit_startjob (); below.
9719    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
9720    <limits.h> exists even on freestanding compilers.  */
9721
9722#ifdef __STDC__
9723# include <limits.h>
9724#else
9725# include <assert.h>
9726#endif
9727
9728#undef jlimit_startjob
9729
9730/* Override any GCC internal prototype to avoid an error.
9731   Use char because int might match the return type of a GCC
9732   builtin and then its argument prototype would still apply.  */
9733#ifdef __cplusplus
9734extern "C"
9735#endif
9736char jlimit_startjob ();
9737/* The GNU C library defines this for functions which it implements
9738    to always fail with ENOSYS.  Some functions are actually named
9739    something starting with __ and the normal name is an alias.  */
9740#if defined __stub_jlimit_startjob || defined __stub___jlimit_startjob
9741choke me
9742#endif
9743
9744int
9745main ()
9746{
9747return jlimit_startjob ();
9748  ;
9749  return 0;
9750}
9751_ACEOF
9752rm -f conftest.$ac_objext conftest$ac_exeext
9753if { (ac_try="$ac_link"
9754case "(($ac_try" in
9755  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9756  *) ac_try_echo=$ac_try;;
9757esac
9758eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9759  (eval "$ac_link") 2>conftest.er1
9760  ac_status=$?
9761  grep -v '^ *+' conftest.er1 >conftest.err
9762  rm -f conftest.er1
9763  cat conftest.err >&5
9764  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9765  (exit $ac_status); } && {
9766	 test -z "$ac_c_werror_flag" ||
9767	 test ! -s conftest.err
9768       } && test -s conftest$ac_exeext &&
9769       $as_test_x conftest$ac_exeext; then
9770  ac_cv_func_jlimit_startjob=yes
9771else
9772  echo "$as_me: failed program was:" >&5
9773sed 's/^/| /' conftest.$ac_ext >&5
9774
9775	ac_cv_func_jlimit_startjob=no
9776fi
9777
9778rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9779      conftest$ac_exeext conftest.$ac_ext
9780fi
9781{ echo "$as_me:$LINENO: result: $ac_cv_func_jlimit_startjob" >&5
9782echo "${ECHO_T}$ac_cv_func_jlimit_startjob" >&6; }
9783if test $ac_cv_func_jlimit_startjob = yes; then
9784
9785cat >>confdefs.h <<\_ACEOF
9786#define WITH_IRIX_JOBS 1
9787_ACEOF
9788
9789fi
9790
9791	cat >>confdefs.h <<\_ACEOF
9792#define BROKEN_INET_NTOA 1
9793_ACEOF
9794
9795	cat >>confdefs.h <<\_ACEOF
9796#define SETEUID_BREAKS_SETUID 1
9797_ACEOF
9798
9799	cat >>confdefs.h <<\_ACEOF
9800#define BROKEN_SETREUID 1
9801_ACEOF
9802
9803	cat >>confdefs.h <<\_ACEOF
9804#define BROKEN_SETREGID 1
9805_ACEOF
9806
9807
9808cat >>confdefs.h <<\_ACEOF
9809#define BROKEN_UPDWTMPX 1
9810_ACEOF
9811
9812	cat >>confdefs.h <<\_ACEOF
9813#define WITH_ABBREV_NO_TTY 1
9814_ACEOF
9815
9816	cat >>confdefs.h <<\_ACEOF
9817#define LOCKED_PASSWD_STRING "*LK*"
9818_ACEOF
9819
9820	;;
9821*-*-k*bsd*-gnu | *-*-kopensolaris*-gnu)
9822	check_for_libcrypt_later=1
9823	cat >>confdefs.h <<\_ACEOF
9824#define PAM_TTY_KLUDGE 1
9825_ACEOF
9826
9827	cat >>confdefs.h <<\_ACEOF
9828#define LOCKED_PASSWD_PREFIX "!"
9829_ACEOF
9830
9831	cat >>confdefs.h <<\_ACEOF
9832#define SPT_TYPE SPT_REUSEARGV
9833_ACEOF
9834
9835
9836cat >>confdefs.h <<\_ACEOF
9837#define _PATH_BTMP "/var/log/btmp"
9838_ACEOF
9839
9840
9841cat >>confdefs.h <<\_ACEOF
9842#define USE_BTMP 1
9843_ACEOF
9844
9845	;;
9846*-*-linux*)
9847	no_dev_ptmx=1
9848	use_pie=auto
9849	check_for_libcrypt_later=1
9850	check_for_openpty_ctty_bug=1
9851
9852cat >>confdefs.h <<\_ACEOF
9853#define PAM_TTY_KLUDGE 1
9854_ACEOF
9855
9856
9857cat >>confdefs.h <<\_ACEOF
9858#define LOCKED_PASSWD_PREFIX "!"
9859_ACEOF
9860
9861	cat >>confdefs.h <<\_ACEOF
9862#define SPT_TYPE SPT_REUSEARGV
9863_ACEOF
9864
9865
9866cat >>confdefs.h <<\_ACEOF
9867#define LINK_OPNOTSUPP_ERRNO EPERM
9868_ACEOF
9869
9870
9871cat >>confdefs.h <<\_ACEOF
9872#define _PATH_BTMP "/var/log/btmp"
9873_ACEOF
9874
9875	cat >>confdefs.h <<\_ACEOF
9876#define USE_BTMP 1
9877_ACEOF
9878
9879
9880cat >>confdefs.h <<\_ACEOF
9881#define LINUX_OOM_ADJUST 1
9882_ACEOF
9883
9884	inet6_default_4in6=yes
9885	case `uname -r` in
9886	1.*|2.0.*)
9887
9888cat >>confdefs.h <<\_ACEOF
9889#define BROKEN_CMSG_TYPE 1
9890_ACEOF
9891
9892		;;
9893	esac
9894	# tun(4) forwarding compat code
9895
9896for ac_header in linux/if_tun.h
9897do
9898as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
9899if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9900  { echo "$as_me:$LINENO: checking for $ac_header" >&5
9901echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
9902if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9903  echo $ECHO_N "(cached) $ECHO_C" >&6
9904fi
9905ac_res=`eval echo '${'$as_ac_Header'}'`
9906	       { echo "$as_me:$LINENO: result: $ac_res" >&5
9907echo "${ECHO_T}$ac_res" >&6; }
9908else
9909  # Is the header compilable?
9910{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
9911echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
9912cat >conftest.$ac_ext <<_ACEOF
9913/* confdefs.h.  */
9914_ACEOF
9915cat confdefs.h >>conftest.$ac_ext
9916cat >>conftest.$ac_ext <<_ACEOF
9917/* end confdefs.h.  */
9918$ac_includes_default
9919#include <$ac_header>
9920_ACEOF
9921rm -f conftest.$ac_objext
9922if { (ac_try="$ac_compile"
9923case "(($ac_try" in
9924  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9925  *) ac_try_echo=$ac_try;;
9926esac
9927eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9928  (eval "$ac_compile") 2>conftest.er1
9929  ac_status=$?
9930  grep -v '^ *+' conftest.er1 >conftest.err
9931  rm -f conftest.er1
9932  cat conftest.err >&5
9933  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9934  (exit $ac_status); } && {
9935	 test -z "$ac_c_werror_flag" ||
9936	 test ! -s conftest.err
9937       } && test -s conftest.$ac_objext; then
9938  ac_header_compiler=yes
9939else
9940  echo "$as_me: failed program was:" >&5
9941sed 's/^/| /' conftest.$ac_ext >&5
9942
9943	ac_header_compiler=no
9944fi
9945
9946rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9947{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9948echo "${ECHO_T}$ac_header_compiler" >&6; }
9949
9950# Is the header present?
9951{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
9952echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
9953cat >conftest.$ac_ext <<_ACEOF
9954/* confdefs.h.  */
9955_ACEOF
9956cat confdefs.h >>conftest.$ac_ext
9957cat >>conftest.$ac_ext <<_ACEOF
9958/* end confdefs.h.  */
9959#include <$ac_header>
9960_ACEOF
9961if { (ac_try="$ac_cpp conftest.$ac_ext"
9962case "(($ac_try" in
9963  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9964  *) ac_try_echo=$ac_try;;
9965esac
9966eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
9967  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9968  ac_status=$?
9969  grep -v '^ *+' conftest.er1 >conftest.err
9970  rm -f conftest.er1
9971  cat conftest.err >&5
9972  echo "$as_me:$LINENO: \$? = $ac_status" >&5
9973  (exit $ac_status); } >/dev/null && {
9974	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9975	 test ! -s conftest.err
9976       }; then
9977  ac_header_preproc=yes
9978else
9979  echo "$as_me: failed program was:" >&5
9980sed 's/^/| /' conftest.$ac_ext >&5
9981
9982  ac_header_preproc=no
9983fi
9984
9985rm -f conftest.err conftest.$ac_ext
9986{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9987echo "${ECHO_T}$ac_header_preproc" >&6; }
9988
9989# So?  What about this header?
9990case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9991  yes:no: )
9992    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9993echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9994    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9995echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9996    ac_header_preproc=yes
9997    ;;
9998  no:yes:* )
9999    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10000echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10001    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10002echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10003    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10004echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10005    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10006echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10007    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10008echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10009    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10010echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10011    ( cat <<\_ASBOX
10012## ------------------------------------------- ##
10013## Report this to openssh-unix-dev@mindrot.org ##
10014## ------------------------------------------- ##
10015_ASBOX
10016     ) | sed "s/^/$as_me: WARNING:     /" >&2
10017    ;;
10018esac
10019{ echo "$as_me:$LINENO: checking for $ac_header" >&5
10020echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10021if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10022  echo $ECHO_N "(cached) $ECHO_C" >&6
10023else
10024  eval "$as_ac_Header=\$ac_header_preproc"
10025fi
10026ac_res=`eval echo '${'$as_ac_Header'}'`
10027	       { echo "$as_me:$LINENO: result: $ac_res" >&5
10028echo "${ECHO_T}$ac_res" >&6; }
10029
10030fi
10031if test `eval echo '${'$as_ac_Header'}'` = yes; then
10032  cat >>confdefs.h <<_ACEOF
10033#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10034_ACEOF
10035
10036fi
10037
10038done
10039
10040	if test "x$ac_cv_header_linux_if_tun_h" = "xyes" ; then
10041
10042cat >>confdefs.h <<\_ACEOF
10043#define SSH_TUN_LINUX 1
10044_ACEOF
10045
10046
10047cat >>confdefs.h <<\_ACEOF
10048#define SSH_TUN_COMPAT_AF 1
10049_ACEOF
10050
10051
10052cat >>confdefs.h <<\_ACEOF
10053#define SSH_TUN_PREPEND_AF 1
10054_ACEOF
10055
10056	fi
10057
10058
10059
10060for ac_header in linux/seccomp.h linux/filter.h linux/audit.h
10061do
10062as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10063{ echo "$as_me:$LINENO: checking for $ac_header" >&5
10064echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
10065if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10066  echo $ECHO_N "(cached) $ECHO_C" >&6
10067else
10068  cat >conftest.$ac_ext <<_ACEOF
10069/* confdefs.h.  */
10070_ACEOF
10071cat confdefs.h >>conftest.$ac_ext
10072cat >>conftest.$ac_ext <<_ACEOF
10073/* end confdefs.h.  */
10074#include <linux/types.h>
10075
10076#include <$ac_header>
10077_ACEOF
10078rm -f conftest.$ac_objext
10079if { (ac_try="$ac_compile"
10080case "(($ac_try" in
10081  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10082  *) ac_try_echo=$ac_try;;
10083esac
10084eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10085  (eval "$ac_compile") 2>conftest.er1
10086  ac_status=$?
10087  grep -v '^ *+' conftest.er1 >conftest.err
10088  rm -f conftest.er1
10089  cat conftest.err >&5
10090  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10091  (exit $ac_status); } && {
10092	 test -z "$ac_c_werror_flag" ||
10093	 test ! -s conftest.err
10094       } && test -s conftest.$ac_objext; then
10095  eval "$as_ac_Header=yes"
10096else
10097  echo "$as_me: failed program was:" >&5
10098sed 's/^/| /' conftest.$ac_ext >&5
10099
10100	eval "$as_ac_Header=no"
10101fi
10102
10103rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10104fi
10105ac_res=`eval echo '${'$as_ac_Header'}'`
10106	       { echo "$as_me:$LINENO: result: $ac_res" >&5
10107echo "${ECHO_T}$ac_res" >&6; }
10108if test `eval echo '${'$as_ac_Header'}'` = yes; then
10109  cat >>confdefs.h <<_ACEOF
10110#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10111_ACEOF
10112
10113fi
10114
10115done
10116
10117
10118for ac_func in prctl
10119do
10120as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10121{ echo "$as_me:$LINENO: checking for $ac_func" >&5
10122echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
10123if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
10124  echo $ECHO_N "(cached) $ECHO_C" >&6
10125else
10126  cat >conftest.$ac_ext <<_ACEOF
10127/* confdefs.h.  */
10128_ACEOF
10129cat confdefs.h >>conftest.$ac_ext
10130cat >>conftest.$ac_ext <<_ACEOF
10131/* end confdefs.h.  */
10132/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
10133   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
10134#define $ac_func innocuous_$ac_func
10135
10136/* System header to define __stub macros and hopefully few prototypes,
10137    which can conflict with char $ac_func (); below.
10138    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10139    <limits.h> exists even on freestanding compilers.  */
10140
10141#ifdef __STDC__
10142# include <limits.h>
10143#else
10144# include <assert.h>
10145#endif
10146
10147#undef $ac_func
10148
10149/* Override any GCC internal prototype to avoid an error.
10150   Use char because int might match the return type of a GCC
10151   builtin and then its argument prototype would still apply.  */
10152#ifdef __cplusplus
10153extern "C"
10154#endif
10155char $ac_func ();
10156/* The GNU C library defines this for functions which it implements
10157    to always fail with ENOSYS.  Some functions are actually named
10158    something starting with __ and the normal name is an alias.  */
10159#if defined __stub_$ac_func || defined __stub___$ac_func
10160choke me
10161#endif
10162
10163int
10164main ()
10165{
10166return $ac_func ();
10167  ;
10168  return 0;
10169}
10170_ACEOF
10171rm -f conftest.$ac_objext conftest$ac_exeext
10172if { (ac_try="$ac_link"
10173case "(($ac_try" in
10174  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10175  *) ac_try_echo=$ac_try;;
10176esac
10177eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10178  (eval "$ac_link") 2>conftest.er1
10179  ac_status=$?
10180  grep -v '^ *+' conftest.er1 >conftest.err
10181  rm -f conftest.er1
10182  cat conftest.err >&5
10183  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10184  (exit $ac_status); } && {
10185	 test -z "$ac_c_werror_flag" ||
10186	 test ! -s conftest.err
10187       } && test -s conftest$ac_exeext &&
10188       $as_test_x conftest$ac_exeext; then
10189  eval "$as_ac_var=yes"
10190else
10191  echo "$as_me: failed program was:" >&5
10192sed 's/^/| /' conftest.$ac_ext >&5
10193
10194	eval "$as_ac_var=no"
10195fi
10196
10197rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10198      conftest$ac_exeext conftest.$ac_ext
10199fi
10200ac_res=`eval echo '${'$as_ac_var'}'`
10201	       { echo "$as_me:$LINENO: result: $ac_res" >&5
10202echo "${ECHO_T}$ac_res" >&6; }
10203if test `eval echo '${'$as_ac_var'}'` = yes; then
10204  cat >>confdefs.h <<_ACEOF
10205#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10206_ACEOF
10207
10208fi
10209done
10210
10211	{ echo "$as_me:$LINENO: checking for seccomp architecture" >&5
10212echo $ECHO_N "checking for seccomp architecture... $ECHO_C" >&6; }
10213	seccomp_audit_arch=
10214	case "$host" in
10215	x86_64-*)
10216		seccomp_audit_arch=AUDIT_ARCH_X86_64
10217		;;
10218	i*86-*)
10219		seccomp_audit_arch=AUDIT_ARCH_I386
10220		;;
10221        arm*-*)
10222		seccomp_audit_arch=AUDIT_ARCH_ARM
10223                ;;
10224	esac
10225	if test "x$seccomp_audit_arch" != "x" ; then
10226		{ echo "$as_me:$LINENO: result: \"$seccomp_audit_arch\"" >&5
10227echo "${ECHO_T}\"$seccomp_audit_arch\"" >&6; }
10228
10229cat >>confdefs.h <<_ACEOF
10230#define SECCOMP_AUDIT_ARCH $seccomp_audit_arch
10231_ACEOF
10232
10233	else
10234		{ echo "$as_me:$LINENO: result: architecture not supported" >&5
10235echo "${ECHO_T}architecture not supported" >&6; }
10236	fi
10237	;;
10238mips-sony-bsd|mips-sony-newsos4)
10239
10240cat >>confdefs.h <<\_ACEOF
10241#define NEED_SETPGRP 1
10242_ACEOF
10243
10244	SONY=1
10245	;;
10246*-*-netbsd*)
10247	check_for_libcrypt_before=1
10248	if test "x$withval" != "xno" ; then
10249		need_dash_r=1
10250	fi
10251
10252cat >>confdefs.h <<\_ACEOF
10253#define SSH_TUN_FREEBSD 1
10254_ACEOF
10255
10256	if test "${ac_cv_header_net_if_tap_h+set}" = set; then
10257  { echo "$as_me:$LINENO: checking for net/if_tap.h" >&5
10258echo $ECHO_N "checking for net/if_tap.h... $ECHO_C" >&6; }
10259if test "${ac_cv_header_net_if_tap_h+set}" = set; then
10260  echo $ECHO_N "(cached) $ECHO_C" >&6
10261fi
10262{ echo "$as_me:$LINENO: result: $ac_cv_header_net_if_tap_h" >&5
10263echo "${ECHO_T}$ac_cv_header_net_if_tap_h" >&6; }
10264else
10265  # Is the header compilable?
10266{ echo "$as_me:$LINENO: checking net/if_tap.h usability" >&5
10267echo $ECHO_N "checking net/if_tap.h usability... $ECHO_C" >&6; }
10268cat >conftest.$ac_ext <<_ACEOF
10269/* confdefs.h.  */
10270_ACEOF
10271cat confdefs.h >>conftest.$ac_ext
10272cat >>conftest.$ac_ext <<_ACEOF
10273/* end confdefs.h.  */
10274$ac_includes_default
10275#include <net/if_tap.h>
10276_ACEOF
10277rm -f conftest.$ac_objext
10278if { (ac_try="$ac_compile"
10279case "(($ac_try" in
10280  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10281  *) ac_try_echo=$ac_try;;
10282esac
10283eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10284  (eval "$ac_compile") 2>conftest.er1
10285  ac_status=$?
10286  grep -v '^ *+' conftest.er1 >conftest.err
10287  rm -f conftest.er1
10288  cat conftest.err >&5
10289  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10290  (exit $ac_status); } && {
10291	 test -z "$ac_c_werror_flag" ||
10292	 test ! -s conftest.err
10293       } && test -s conftest.$ac_objext; then
10294  ac_header_compiler=yes
10295else
10296  echo "$as_me: failed program was:" >&5
10297sed 's/^/| /' conftest.$ac_ext >&5
10298
10299	ac_header_compiler=no
10300fi
10301
10302rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10303{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10304echo "${ECHO_T}$ac_header_compiler" >&6; }
10305
10306# Is the header present?
10307{ echo "$as_me:$LINENO: checking net/if_tap.h presence" >&5
10308echo $ECHO_N "checking net/if_tap.h presence... $ECHO_C" >&6; }
10309cat >conftest.$ac_ext <<_ACEOF
10310/* confdefs.h.  */
10311_ACEOF
10312cat confdefs.h >>conftest.$ac_ext
10313cat >>conftest.$ac_ext <<_ACEOF
10314/* end confdefs.h.  */
10315#include <net/if_tap.h>
10316_ACEOF
10317if { (ac_try="$ac_cpp conftest.$ac_ext"
10318case "(($ac_try" in
10319  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10320  *) ac_try_echo=$ac_try;;
10321esac
10322eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10323  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10324  ac_status=$?
10325  grep -v '^ *+' conftest.er1 >conftest.err
10326  rm -f conftest.er1
10327  cat conftest.err >&5
10328  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10329  (exit $ac_status); } >/dev/null && {
10330	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10331	 test ! -s conftest.err
10332       }; then
10333  ac_header_preproc=yes
10334else
10335  echo "$as_me: failed program was:" >&5
10336sed 's/^/| /' conftest.$ac_ext >&5
10337
10338  ac_header_preproc=no
10339fi
10340
10341rm -f conftest.err conftest.$ac_ext
10342{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10343echo "${ECHO_T}$ac_header_preproc" >&6; }
10344
10345# So?  What about this header?
10346case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10347  yes:no: )
10348    { echo "$as_me:$LINENO: WARNING: net/if_tap.h: accepted by the compiler, rejected by the preprocessor!" >&5
10349echo "$as_me: WARNING: net/if_tap.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10350    { echo "$as_me:$LINENO: WARNING: net/if_tap.h: proceeding with the compiler's result" >&5
10351echo "$as_me: WARNING: net/if_tap.h: proceeding with the compiler's result" >&2;}
10352    ac_header_preproc=yes
10353    ;;
10354  no:yes:* )
10355    { echo "$as_me:$LINENO: WARNING: net/if_tap.h: present but cannot be compiled" >&5
10356echo "$as_me: WARNING: net/if_tap.h: present but cannot be compiled" >&2;}
10357    { echo "$as_me:$LINENO: WARNING: net/if_tap.h:     check for missing prerequisite headers?" >&5
10358echo "$as_me: WARNING: net/if_tap.h:     check for missing prerequisite headers?" >&2;}
10359    { echo "$as_me:$LINENO: WARNING: net/if_tap.h: see the Autoconf documentation" >&5
10360echo "$as_me: WARNING: net/if_tap.h: see the Autoconf documentation" >&2;}
10361    { echo "$as_me:$LINENO: WARNING: net/if_tap.h:     section \"Present But Cannot Be Compiled\"" >&5
10362echo "$as_me: WARNING: net/if_tap.h:     section \"Present But Cannot Be Compiled\"" >&2;}
10363    { echo "$as_me:$LINENO: WARNING: net/if_tap.h: proceeding with the preprocessor's result" >&5
10364echo "$as_me: WARNING: net/if_tap.h: proceeding with the preprocessor's result" >&2;}
10365    { echo "$as_me:$LINENO: WARNING: net/if_tap.h: in the future, the compiler will take precedence" >&5
10366echo "$as_me: WARNING: net/if_tap.h: in the future, the compiler will take precedence" >&2;}
10367    ( cat <<\_ASBOX
10368## ------------------------------------------- ##
10369## Report this to openssh-unix-dev@mindrot.org ##
10370## ------------------------------------------- ##
10371_ASBOX
10372     ) | sed "s/^/$as_me: WARNING:     /" >&2
10373    ;;
10374esac
10375{ echo "$as_me:$LINENO: checking for net/if_tap.h" >&5
10376echo $ECHO_N "checking for net/if_tap.h... $ECHO_C" >&6; }
10377if test "${ac_cv_header_net_if_tap_h+set}" = set; then
10378  echo $ECHO_N "(cached) $ECHO_C" >&6
10379else
10380  ac_cv_header_net_if_tap_h=$ac_header_preproc
10381fi
10382{ echo "$as_me:$LINENO: result: $ac_cv_header_net_if_tap_h" >&5
10383echo "${ECHO_T}$ac_cv_header_net_if_tap_h" >&6; }
10384
10385fi
10386if test $ac_cv_header_net_if_tap_h = yes; then
10387  :
10388else
10389
10390cat >>confdefs.h <<\_ACEOF
10391#define SSH_TUN_NO_L2 1
10392_ACEOF
10393
10394fi
10395
10396
10397
10398cat >>confdefs.h <<\_ACEOF
10399#define SSH_TUN_PREPEND_AF 1
10400_ACEOF
10401
10402	TEST_MALLOC_OPTIONS="AJRX"
10403
10404cat >>confdefs.h <<\_ACEOF
10405#define BROKEN_STRNVIS 1
10406_ACEOF
10407
10408
10409cat >>confdefs.h <<\_ACEOF
10410#define BROKEN_READ_COMPARISON 1
10411_ACEOF
10412
10413	;;
10414*-*-freebsd*)
10415	check_for_libcrypt_later=1
10416
10417cat >>confdefs.h <<\_ACEOF
10418#define LOCKED_PASSWD_PREFIX "*LOCKED*"
10419_ACEOF
10420
10421
10422cat >>confdefs.h <<\_ACEOF
10423#define SSH_TUN_FREEBSD 1
10424_ACEOF
10425
10426	if test "${ac_cv_header_net_if_tap_h+set}" = set; then
10427  { echo "$as_me:$LINENO: checking for net/if_tap.h" >&5
10428echo $ECHO_N "checking for net/if_tap.h... $ECHO_C" >&6; }
10429if test "${ac_cv_header_net_if_tap_h+set}" = set; then
10430  echo $ECHO_N "(cached) $ECHO_C" >&6
10431fi
10432{ echo "$as_me:$LINENO: result: $ac_cv_header_net_if_tap_h" >&5
10433echo "${ECHO_T}$ac_cv_header_net_if_tap_h" >&6; }
10434else
10435  # Is the header compilable?
10436{ echo "$as_me:$LINENO: checking net/if_tap.h usability" >&5
10437echo $ECHO_N "checking net/if_tap.h usability... $ECHO_C" >&6; }
10438cat >conftest.$ac_ext <<_ACEOF
10439/* confdefs.h.  */
10440_ACEOF
10441cat confdefs.h >>conftest.$ac_ext
10442cat >>conftest.$ac_ext <<_ACEOF
10443/* end confdefs.h.  */
10444$ac_includes_default
10445#include <net/if_tap.h>
10446_ACEOF
10447rm -f conftest.$ac_objext
10448if { (ac_try="$ac_compile"
10449case "(($ac_try" in
10450  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10451  *) ac_try_echo=$ac_try;;
10452esac
10453eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10454  (eval "$ac_compile") 2>conftest.er1
10455  ac_status=$?
10456  grep -v '^ *+' conftest.er1 >conftest.err
10457  rm -f conftest.er1
10458  cat conftest.err >&5
10459  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10460  (exit $ac_status); } && {
10461	 test -z "$ac_c_werror_flag" ||
10462	 test ! -s conftest.err
10463       } && test -s conftest.$ac_objext; then
10464  ac_header_compiler=yes
10465else
10466  echo "$as_me: failed program was:" >&5
10467sed 's/^/| /' conftest.$ac_ext >&5
10468
10469	ac_header_compiler=no
10470fi
10471
10472rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10473{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10474echo "${ECHO_T}$ac_header_compiler" >&6; }
10475
10476# Is the header present?
10477{ echo "$as_me:$LINENO: checking net/if_tap.h presence" >&5
10478echo $ECHO_N "checking net/if_tap.h presence... $ECHO_C" >&6; }
10479cat >conftest.$ac_ext <<_ACEOF
10480/* confdefs.h.  */
10481_ACEOF
10482cat confdefs.h >>conftest.$ac_ext
10483cat >>conftest.$ac_ext <<_ACEOF
10484/* end confdefs.h.  */
10485#include <net/if_tap.h>
10486_ACEOF
10487if { (ac_try="$ac_cpp conftest.$ac_ext"
10488case "(($ac_try" in
10489  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10490  *) ac_try_echo=$ac_try;;
10491esac
10492eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10493  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10494  ac_status=$?
10495  grep -v '^ *+' conftest.er1 >conftest.err
10496  rm -f conftest.er1
10497  cat conftest.err >&5
10498  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10499  (exit $ac_status); } >/dev/null && {
10500	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10501	 test ! -s conftest.err
10502       }; then
10503  ac_header_preproc=yes
10504else
10505  echo "$as_me: failed program was:" >&5
10506sed 's/^/| /' conftest.$ac_ext >&5
10507
10508  ac_header_preproc=no
10509fi
10510
10511rm -f conftest.err conftest.$ac_ext
10512{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10513echo "${ECHO_T}$ac_header_preproc" >&6; }
10514
10515# So?  What about this header?
10516case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10517  yes:no: )
10518    { echo "$as_me:$LINENO: WARNING: net/if_tap.h: accepted by the compiler, rejected by the preprocessor!" >&5
10519echo "$as_me: WARNING: net/if_tap.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10520    { echo "$as_me:$LINENO: WARNING: net/if_tap.h: proceeding with the compiler's result" >&5
10521echo "$as_me: WARNING: net/if_tap.h: proceeding with the compiler's result" >&2;}
10522    ac_header_preproc=yes
10523    ;;
10524  no:yes:* )
10525    { echo "$as_me:$LINENO: WARNING: net/if_tap.h: present but cannot be compiled" >&5
10526echo "$as_me: WARNING: net/if_tap.h: present but cannot be compiled" >&2;}
10527    { echo "$as_me:$LINENO: WARNING: net/if_tap.h:     check for missing prerequisite headers?" >&5
10528echo "$as_me: WARNING: net/if_tap.h:     check for missing prerequisite headers?" >&2;}
10529    { echo "$as_me:$LINENO: WARNING: net/if_tap.h: see the Autoconf documentation" >&5
10530echo "$as_me: WARNING: net/if_tap.h: see the Autoconf documentation" >&2;}
10531    { echo "$as_me:$LINENO: WARNING: net/if_tap.h:     section \"Present But Cannot Be Compiled\"" >&5
10532echo "$as_me: WARNING: net/if_tap.h:     section \"Present But Cannot Be Compiled\"" >&2;}
10533    { echo "$as_me:$LINENO: WARNING: net/if_tap.h: proceeding with the preprocessor's result" >&5
10534echo "$as_me: WARNING: net/if_tap.h: proceeding with the preprocessor's result" >&2;}
10535    { echo "$as_me:$LINENO: WARNING: net/if_tap.h: in the future, the compiler will take precedence" >&5
10536echo "$as_me: WARNING: net/if_tap.h: in the future, the compiler will take precedence" >&2;}
10537    ( cat <<\_ASBOX
10538## ------------------------------------------- ##
10539## Report this to openssh-unix-dev@mindrot.org ##
10540## ------------------------------------------- ##
10541_ASBOX
10542     ) | sed "s/^/$as_me: WARNING:     /" >&2
10543    ;;
10544esac
10545{ echo "$as_me:$LINENO: checking for net/if_tap.h" >&5
10546echo $ECHO_N "checking for net/if_tap.h... $ECHO_C" >&6; }
10547if test "${ac_cv_header_net_if_tap_h+set}" = set; then
10548  echo $ECHO_N "(cached) $ECHO_C" >&6
10549else
10550  ac_cv_header_net_if_tap_h=$ac_header_preproc
10551fi
10552{ echo "$as_me:$LINENO: result: $ac_cv_header_net_if_tap_h" >&5
10553echo "${ECHO_T}$ac_cv_header_net_if_tap_h" >&6; }
10554
10555fi
10556if test $ac_cv_header_net_if_tap_h = yes; then
10557  :
10558else
10559
10560cat >>confdefs.h <<\_ACEOF
10561#define SSH_TUN_NO_L2 1
10562_ACEOF
10563
10564fi
10565
10566
10567
10568cat >>confdefs.h <<\_ACEOF
10569#define BROKEN_GLOB 1
10570_ACEOF
10571
10572
10573cat >>confdefs.h <<\_ACEOF
10574#define BROKEN_STRNVIS 1
10575_ACEOF
10576
10577	TEST_MALLOC_OPTIONS="AJRX"
10578	# Preauth crypto occasionally uses file descriptors for crypto offload
10579	# and will crash if they cannot be opened.
10580
10581cat >>confdefs.h <<\_ACEOF
10582#define SANDBOX_SKIP_RLIMIT_NOFILE 1
10583_ACEOF
10584
10585	;;
10586*-*-bsdi*)
10587	cat >>confdefs.h <<\_ACEOF
10588#define SETEUID_BREAKS_SETUID 1
10589_ACEOF
10590
10591	cat >>confdefs.h <<\_ACEOF
10592#define BROKEN_SETREUID 1
10593_ACEOF
10594
10595	cat >>confdefs.h <<\_ACEOF
10596#define BROKEN_SETREGID 1
10597_ACEOF
10598
10599	;;
10600*-next-*)
10601	conf_lastlog_location="/usr/adm/lastlog"
10602	conf_utmp_location=/etc/utmp
10603	conf_wtmp_location=/usr/adm/wtmp
10604	maildir=/usr/spool/mail
10605
10606cat >>confdefs.h <<\_ACEOF
10607#define HAVE_NEXT 1
10608_ACEOF
10609
10610	cat >>confdefs.h <<\_ACEOF
10611#define BROKEN_REALPATH 1
10612_ACEOF
10613
10614	cat >>confdefs.h <<\_ACEOF
10615#define USE_PIPES 1
10616_ACEOF
10617
10618
10619cat >>confdefs.h <<\_ACEOF
10620#define BROKEN_SAVED_UIDS 1
10621_ACEOF
10622
10623	;;
10624*-*-openbsd*)
10625	use_pie=auto
10626
10627cat >>confdefs.h <<\_ACEOF
10628#define HAVE_ATTRIBUTE__SENTINEL__ 1
10629_ACEOF
10630
10631
10632cat >>confdefs.h <<\_ACEOF
10633#define HAVE_ATTRIBUTE__BOUNDED__ 1
10634_ACEOF
10635
10636
10637cat >>confdefs.h <<\_ACEOF
10638#define SSH_TUN_OPENBSD 1
10639_ACEOF
10640
10641
10642cat >>confdefs.h <<\_ACEOF
10643#define SYSLOG_R_SAFE_IN_SIGHAND 1
10644_ACEOF
10645
10646	TEST_MALLOC_OPTIONS="AFGJPRX"
10647	;;
10648*-*-solaris*)
10649	if test "x$withval" != "xno" ; then
10650		need_dash_r=1
10651	fi
10652	cat >>confdefs.h <<\_ACEOF
10653#define PAM_SUN_CODEBASE 1
10654_ACEOF
10655
10656	cat >>confdefs.h <<\_ACEOF
10657#define LOGIN_NEEDS_UTMPX 1
10658_ACEOF
10659
10660
10661cat >>confdefs.h <<\_ACEOF
10662#define LOGIN_NEEDS_TERM 1
10663_ACEOF
10664
10665	cat >>confdefs.h <<\_ACEOF
10666#define PAM_TTY_KLUDGE 1
10667_ACEOF
10668
10669
10670cat >>confdefs.h <<\_ACEOF
10671#define SSHPAM_CHAUTHTOK_NEEDS_RUID 1
10672_ACEOF
10673
10674	cat >>confdefs.h <<\_ACEOF
10675#define LOCKED_PASSWD_STRING "*LK*"
10676_ACEOF
10677
10678	# Pushing STREAMS modules will cause sshd to acquire a controlling tty.
10679
10680cat >>confdefs.h <<\_ACEOF
10681#define SSHD_ACQUIRES_CTTY 1
10682_ACEOF
10683
10684
10685cat >>confdefs.h <<\_ACEOF
10686#define PASSWD_NEEDS_USERNAME 1
10687_ACEOF
10688
10689
10690cat >>confdefs.h <<\_ACEOF
10691#define BROKEN_TCGETATTR_ICANON 1
10692_ACEOF
10693
10694	external_path_file=/etc/default/login
10695	# hardwire lastlog location (can't detect it on some versions)
10696	conf_lastlog_location="/var/adm/lastlog"
10697	{ echo "$as_me:$LINENO: checking for obsolete utmp and wtmp in solaris2.x" >&5
10698echo $ECHO_N "checking for obsolete utmp and wtmp in solaris2.x... $ECHO_C" >&6; }
10699	sol2ver=`echo "$host"| sed -e 's/.*[0-9]\.//'`
10700	if test "$sol2ver" -ge 8; then
10701		{ echo "$as_me:$LINENO: result: yes" >&5
10702echo "${ECHO_T}yes" >&6; }
10703		cat >>confdefs.h <<\_ACEOF
10704#define DISABLE_UTMP 1
10705_ACEOF
10706
10707
10708cat >>confdefs.h <<\_ACEOF
10709#define DISABLE_WTMP 1
10710_ACEOF
10711
10712	else
10713		{ echo "$as_me:$LINENO: result: no" >&5
10714echo "${ECHO_T}no" >&6; }
10715	fi
10716
10717# Check whether --with-solaris-contracts was given.
10718if test "${with_solaris_contracts+set}" = set; then
10719  withval=$with_solaris_contracts;
10720		{ echo "$as_me:$LINENO: checking for ct_tmpl_activate in -lcontract" >&5
10721echo $ECHO_N "checking for ct_tmpl_activate in -lcontract... $ECHO_C" >&6; }
10722if test "${ac_cv_lib_contract_ct_tmpl_activate+set}" = set; then
10723  echo $ECHO_N "(cached) $ECHO_C" >&6
10724else
10725  ac_check_lib_save_LIBS=$LIBS
10726LIBS="-lcontract  $LIBS"
10727cat >conftest.$ac_ext <<_ACEOF
10728/* confdefs.h.  */
10729_ACEOF
10730cat confdefs.h >>conftest.$ac_ext
10731cat >>conftest.$ac_ext <<_ACEOF
10732/* end confdefs.h.  */
10733
10734/* Override any GCC internal prototype to avoid an error.
10735   Use char because int might match the return type of a GCC
10736   builtin and then its argument prototype would still apply.  */
10737#ifdef __cplusplus
10738extern "C"
10739#endif
10740char ct_tmpl_activate ();
10741int
10742main ()
10743{
10744return ct_tmpl_activate ();
10745  ;
10746  return 0;
10747}
10748_ACEOF
10749rm -f conftest.$ac_objext conftest$ac_exeext
10750if { (ac_try="$ac_link"
10751case "(($ac_try" in
10752  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10753  *) ac_try_echo=$ac_try;;
10754esac
10755eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10756  (eval "$ac_link") 2>conftest.er1
10757  ac_status=$?
10758  grep -v '^ *+' conftest.er1 >conftest.err
10759  rm -f conftest.er1
10760  cat conftest.err >&5
10761  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10762  (exit $ac_status); } && {
10763	 test -z "$ac_c_werror_flag" ||
10764	 test ! -s conftest.err
10765       } && test -s conftest$ac_exeext &&
10766       $as_test_x conftest$ac_exeext; then
10767  ac_cv_lib_contract_ct_tmpl_activate=yes
10768else
10769  echo "$as_me: failed program was:" >&5
10770sed 's/^/| /' conftest.$ac_ext >&5
10771
10772	ac_cv_lib_contract_ct_tmpl_activate=no
10773fi
10774
10775rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10776      conftest$ac_exeext conftest.$ac_ext
10777LIBS=$ac_check_lib_save_LIBS
10778fi
10779{ echo "$as_me:$LINENO: result: $ac_cv_lib_contract_ct_tmpl_activate" >&5
10780echo "${ECHO_T}$ac_cv_lib_contract_ct_tmpl_activate" >&6; }
10781if test $ac_cv_lib_contract_ct_tmpl_activate = yes; then
10782
10783cat >>confdefs.h <<\_ACEOF
10784#define USE_SOLARIS_PROCESS_CONTRACTS 1
10785_ACEOF
10786
10787			  SSHDLIBS="$SSHDLIBS -lcontract"
10788			  SPC_MSG="yes"
10789fi
10790
10791
10792fi
10793
10794
10795# Check whether --with-solaris-projects was given.
10796if test "${with_solaris_projects+set}" = set; then
10797  withval=$with_solaris_projects;
10798		{ echo "$as_me:$LINENO: checking for setproject in -lproject" >&5
10799echo $ECHO_N "checking for setproject in -lproject... $ECHO_C" >&6; }
10800if test "${ac_cv_lib_project_setproject+set}" = set; then
10801  echo $ECHO_N "(cached) $ECHO_C" >&6
10802else
10803  ac_check_lib_save_LIBS=$LIBS
10804LIBS="-lproject  $LIBS"
10805cat >conftest.$ac_ext <<_ACEOF
10806/* confdefs.h.  */
10807_ACEOF
10808cat confdefs.h >>conftest.$ac_ext
10809cat >>conftest.$ac_ext <<_ACEOF
10810/* end confdefs.h.  */
10811
10812/* Override any GCC internal prototype to avoid an error.
10813   Use char because int might match the return type of a GCC
10814   builtin and then its argument prototype would still apply.  */
10815#ifdef __cplusplus
10816extern "C"
10817#endif
10818char setproject ();
10819int
10820main ()
10821{
10822return setproject ();
10823  ;
10824  return 0;
10825}
10826_ACEOF
10827rm -f conftest.$ac_objext conftest$ac_exeext
10828if { (ac_try="$ac_link"
10829case "(($ac_try" in
10830  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10831  *) ac_try_echo=$ac_try;;
10832esac
10833eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10834  (eval "$ac_link") 2>conftest.er1
10835  ac_status=$?
10836  grep -v '^ *+' conftest.er1 >conftest.err
10837  rm -f conftest.er1
10838  cat conftest.err >&5
10839  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10840  (exit $ac_status); } && {
10841	 test -z "$ac_c_werror_flag" ||
10842	 test ! -s conftest.err
10843       } && test -s conftest$ac_exeext &&
10844       $as_test_x conftest$ac_exeext; then
10845  ac_cv_lib_project_setproject=yes
10846else
10847  echo "$as_me: failed program was:" >&5
10848sed 's/^/| /' conftest.$ac_ext >&5
10849
10850	ac_cv_lib_project_setproject=no
10851fi
10852
10853rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10854      conftest$ac_exeext conftest.$ac_ext
10855LIBS=$ac_check_lib_save_LIBS
10856fi
10857{ echo "$as_me:$LINENO: result: $ac_cv_lib_project_setproject" >&5
10858echo "${ECHO_T}$ac_cv_lib_project_setproject" >&6; }
10859if test $ac_cv_lib_project_setproject = yes; then
10860
10861cat >>confdefs.h <<\_ACEOF
10862#define USE_SOLARIS_PROJECTS 1
10863_ACEOF
10864
10865			SSHDLIBS="$SSHDLIBS -lproject"
10866			SP_MSG="yes"
10867fi
10868
10869
10870fi
10871
10872	TEST_SHELL=$SHELL	# let configure find us a capable shell
10873	;;
10874*-*-sunos4*)
10875	CPPFLAGS="$CPPFLAGS -DSUNOS4"
10876
10877for ac_func in getpwanam
10878do
10879as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10880{ echo "$as_me:$LINENO: checking for $ac_func" >&5
10881echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
10882if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
10883  echo $ECHO_N "(cached) $ECHO_C" >&6
10884else
10885  cat >conftest.$ac_ext <<_ACEOF
10886/* confdefs.h.  */
10887_ACEOF
10888cat confdefs.h >>conftest.$ac_ext
10889cat >>conftest.$ac_ext <<_ACEOF
10890/* end confdefs.h.  */
10891/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
10892   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
10893#define $ac_func innocuous_$ac_func
10894
10895/* System header to define __stub macros and hopefully few prototypes,
10896    which can conflict with char $ac_func (); below.
10897    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10898    <limits.h> exists even on freestanding compilers.  */
10899
10900#ifdef __STDC__
10901# include <limits.h>
10902#else
10903# include <assert.h>
10904#endif
10905
10906#undef $ac_func
10907
10908/* Override any GCC internal prototype to avoid an error.
10909   Use char because int might match the return type of a GCC
10910   builtin and then its argument prototype would still apply.  */
10911#ifdef __cplusplus
10912extern "C"
10913#endif
10914char $ac_func ();
10915/* The GNU C library defines this for functions which it implements
10916    to always fail with ENOSYS.  Some functions are actually named
10917    something starting with __ and the normal name is an alias.  */
10918#if defined __stub_$ac_func || defined __stub___$ac_func
10919choke me
10920#endif
10921
10922int
10923main ()
10924{
10925return $ac_func ();
10926  ;
10927  return 0;
10928}
10929_ACEOF
10930rm -f conftest.$ac_objext conftest$ac_exeext
10931if { (ac_try="$ac_link"
10932case "(($ac_try" in
10933  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10934  *) ac_try_echo=$ac_try;;
10935esac
10936eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
10937  (eval "$ac_link") 2>conftest.er1
10938  ac_status=$?
10939  grep -v '^ *+' conftest.er1 >conftest.err
10940  rm -f conftest.er1
10941  cat conftest.err >&5
10942  echo "$as_me:$LINENO: \$? = $ac_status" >&5
10943  (exit $ac_status); } && {
10944	 test -z "$ac_c_werror_flag" ||
10945	 test ! -s conftest.err
10946       } && test -s conftest$ac_exeext &&
10947       $as_test_x conftest$ac_exeext; then
10948  eval "$as_ac_var=yes"
10949else
10950  echo "$as_me: failed program was:" >&5
10951sed 's/^/| /' conftest.$ac_ext >&5
10952
10953	eval "$as_ac_var=no"
10954fi
10955
10956rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
10957      conftest$ac_exeext conftest.$ac_ext
10958fi
10959ac_res=`eval echo '${'$as_ac_var'}'`
10960	       { echo "$as_me:$LINENO: result: $ac_res" >&5
10961echo "${ECHO_T}$ac_res" >&6; }
10962if test `eval echo '${'$as_ac_var'}'` = yes; then
10963  cat >>confdefs.h <<_ACEOF
10964#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10965_ACEOF
10966
10967fi
10968done
10969
10970	cat >>confdefs.h <<\_ACEOF
10971#define PAM_SUN_CODEBASE 1
10972_ACEOF
10973
10974	conf_utmp_location=/etc/utmp
10975	conf_wtmp_location=/var/adm/wtmp
10976	conf_lastlog_location=/var/adm/lastlog
10977	cat >>confdefs.h <<\_ACEOF
10978#define USE_PIPES 1
10979_ACEOF
10980
10981	;;
10982*-ncr-sysv*)
10983	LIBS="$LIBS -lc89"
10984	cat >>confdefs.h <<\_ACEOF
10985#define USE_PIPES 1
10986_ACEOF
10987
10988	cat >>confdefs.h <<\_ACEOF
10989#define SSHD_ACQUIRES_CTTY 1
10990_ACEOF
10991
10992	cat >>confdefs.h <<\_ACEOF
10993#define SETEUID_BREAKS_SETUID 1
10994_ACEOF
10995
10996	cat >>confdefs.h <<\_ACEOF
10997#define BROKEN_SETREUID 1
10998_ACEOF
10999
11000	cat >>confdefs.h <<\_ACEOF
11001#define BROKEN_SETREGID 1
11002_ACEOF
11003
11004	;;
11005*-sni-sysv*)
11006	# /usr/ucblib MUST NOT be searched on ReliantUNIX
11007
11008{ echo "$as_me:$LINENO: checking for dlsym in -ldl" >&5
11009echo $ECHO_N "checking for dlsym in -ldl... $ECHO_C" >&6; }
11010if test "${ac_cv_lib_dl_dlsym+set}" = set; then
11011  echo $ECHO_N "(cached) $ECHO_C" >&6
11012else
11013  ac_check_lib_save_LIBS=$LIBS
11014LIBS="-ldl  $LIBS"
11015cat >conftest.$ac_ext <<_ACEOF
11016/* confdefs.h.  */
11017_ACEOF
11018cat confdefs.h >>conftest.$ac_ext
11019cat >>conftest.$ac_ext <<_ACEOF
11020/* end confdefs.h.  */
11021
11022/* Override any GCC internal prototype to avoid an error.
11023   Use char because int might match the return type of a GCC
11024   builtin and then its argument prototype would still apply.  */
11025#ifdef __cplusplus
11026extern "C"
11027#endif
11028char dlsym ();
11029int
11030main ()
11031{
11032return dlsym ();
11033  ;
11034  return 0;
11035}
11036_ACEOF
11037rm -f conftest.$ac_objext conftest$ac_exeext
11038if { (ac_try="$ac_link"
11039case "(($ac_try" in
11040  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11041  *) ac_try_echo=$ac_try;;
11042esac
11043eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11044  (eval "$ac_link") 2>conftest.er1
11045  ac_status=$?
11046  grep -v '^ *+' conftest.er1 >conftest.err
11047  rm -f conftest.er1
11048  cat conftest.err >&5
11049  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11050  (exit $ac_status); } && {
11051	 test -z "$ac_c_werror_flag" ||
11052	 test ! -s conftest.err
11053       } && test -s conftest$ac_exeext &&
11054       $as_test_x conftest$ac_exeext; then
11055  ac_cv_lib_dl_dlsym=yes
11056else
11057  echo "$as_me: failed program was:" >&5
11058sed 's/^/| /' conftest.$ac_ext >&5
11059
11060	ac_cv_lib_dl_dlsym=no
11061fi
11062
11063rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11064      conftest$ac_exeext conftest.$ac_ext
11065LIBS=$ac_check_lib_save_LIBS
11066fi
11067{ echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlsym" >&5
11068echo "${ECHO_T}$ac_cv_lib_dl_dlsym" >&6; }
11069if test $ac_cv_lib_dl_dlsym = yes; then
11070  cat >>confdefs.h <<_ACEOF
11071#define HAVE_LIBDL 1
11072_ACEOF
11073
11074  LIBS="-ldl $LIBS"
11075
11076fi
11077
11078	# -lresolv needs to be at the end of LIBS or DNS lookups break
11079	{ echo "$as_me:$LINENO: checking for res_query in -lresolv" >&5
11080echo $ECHO_N "checking for res_query in -lresolv... $ECHO_C" >&6; }
11081if test "${ac_cv_lib_resolv_res_query+set}" = set; then
11082  echo $ECHO_N "(cached) $ECHO_C" >&6
11083else
11084  ac_check_lib_save_LIBS=$LIBS
11085LIBS="-lresolv  $LIBS"
11086cat >conftest.$ac_ext <<_ACEOF
11087/* confdefs.h.  */
11088_ACEOF
11089cat confdefs.h >>conftest.$ac_ext
11090cat >>conftest.$ac_ext <<_ACEOF
11091/* end confdefs.h.  */
11092
11093/* Override any GCC internal prototype to avoid an error.
11094   Use char because int might match the return type of a GCC
11095   builtin and then its argument prototype would still apply.  */
11096#ifdef __cplusplus
11097extern "C"
11098#endif
11099char res_query ();
11100int
11101main ()
11102{
11103return res_query ();
11104  ;
11105  return 0;
11106}
11107_ACEOF
11108rm -f conftest.$ac_objext conftest$ac_exeext
11109if { (ac_try="$ac_link"
11110case "(($ac_try" in
11111  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11112  *) ac_try_echo=$ac_try;;
11113esac
11114eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11115  (eval "$ac_link") 2>conftest.er1
11116  ac_status=$?
11117  grep -v '^ *+' conftest.er1 >conftest.err
11118  rm -f conftest.er1
11119  cat conftest.err >&5
11120  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11121  (exit $ac_status); } && {
11122	 test -z "$ac_c_werror_flag" ||
11123	 test ! -s conftest.err
11124       } && test -s conftest$ac_exeext &&
11125       $as_test_x conftest$ac_exeext; then
11126  ac_cv_lib_resolv_res_query=yes
11127else
11128  echo "$as_me: failed program was:" >&5
11129sed 's/^/| /' conftest.$ac_ext >&5
11130
11131	ac_cv_lib_resolv_res_query=no
11132fi
11133
11134rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11135      conftest$ac_exeext conftest.$ac_ext
11136LIBS=$ac_check_lib_save_LIBS
11137fi
11138{ echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_res_query" >&5
11139echo "${ECHO_T}$ac_cv_lib_resolv_res_query" >&6; }
11140if test $ac_cv_lib_resolv_res_query = yes; then
11141   LIBS="$LIBS -lresolv"
11142fi
11143
11144	IPADDR_IN_DISPLAY=yes
11145	cat >>confdefs.h <<\_ACEOF
11146#define USE_PIPES 1
11147_ACEOF
11148
11149	cat >>confdefs.h <<\_ACEOF
11150#define IP_TOS_IS_BROKEN 1
11151_ACEOF
11152
11153	cat >>confdefs.h <<\_ACEOF
11154#define SETEUID_BREAKS_SETUID 1
11155_ACEOF
11156
11157	cat >>confdefs.h <<\_ACEOF
11158#define BROKEN_SETREUID 1
11159_ACEOF
11160
11161	cat >>confdefs.h <<\_ACEOF
11162#define BROKEN_SETREGID 1
11163_ACEOF
11164
11165	cat >>confdefs.h <<\_ACEOF
11166#define SSHD_ACQUIRES_CTTY 1
11167_ACEOF
11168
11169	external_path_file=/etc/default/login
11170	# /usr/ucblib/libucb.a no longer needed on ReliantUNIX
11171	# Attention: always take care to bind libsocket and libnsl before libc,
11172	# otherwise you will find lots of "SIOCGPGRP errno 22" on syslog
11173	;;
11174# UnixWare 1.x, UnixWare 2.x, and others based on code from Univel.
11175*-*-sysv4.2*)
11176	cat >>confdefs.h <<\_ACEOF
11177#define USE_PIPES 1
11178_ACEOF
11179
11180	cat >>confdefs.h <<\_ACEOF
11181#define SETEUID_BREAKS_SETUID 1
11182_ACEOF
11183
11184	cat >>confdefs.h <<\_ACEOF
11185#define BROKEN_SETREUID 1
11186_ACEOF
11187
11188	cat >>confdefs.h <<\_ACEOF
11189#define BROKEN_SETREGID 1
11190_ACEOF
11191
11192
11193cat >>confdefs.h <<\_ACEOF
11194#define PASSWD_NEEDS_USERNAME 1
11195_ACEOF
11196
11197	cat >>confdefs.h <<\_ACEOF
11198#define LOCKED_PASSWD_STRING "*LK*"
11199_ACEOF
11200
11201	TEST_SHELL=$SHELL	# let configure find us a capable shell
11202	;;
11203# UnixWare 7.x, OpenUNIX 8
11204*-*-sysv5*)
11205	CPPFLAGS="$CPPFLAGS -Dvsnprintf=_xvsnprintf -Dsnprintf=_xsnprintf"
11206
11207cat >>confdefs.h <<\_ACEOF
11208#define UNIXWARE_LONG_PASSWORDS 1
11209_ACEOF
11210
11211	cat >>confdefs.h <<\_ACEOF
11212#define USE_PIPES 1
11213_ACEOF
11214
11215	cat >>confdefs.h <<\_ACEOF
11216#define SETEUID_BREAKS_SETUID 1
11217_ACEOF
11218
11219	cat >>confdefs.h <<\_ACEOF
11220#define BROKEN_GETADDRINFO 1
11221_ACEOF
11222
11223	cat >>confdefs.h <<\_ACEOF
11224#define BROKEN_SETREUID 1
11225_ACEOF
11226
11227	cat >>confdefs.h <<\_ACEOF
11228#define BROKEN_SETREGID 1
11229_ACEOF
11230
11231	cat >>confdefs.h <<\_ACEOF
11232#define PASSWD_NEEDS_USERNAME 1
11233_ACEOF
11234
11235	TEST_SHELL=$SHELL	# let configure find us a capable shell
11236	case "$host" in
11237	*-*-sysv5SCO_SV*)	# SCO OpenServer 6.x
11238		maildir=/var/spool/mail
11239
11240cat >>confdefs.h <<\_ACEOF
11241#define BROKEN_LIBIAF 1
11242_ACEOF
11243
11244		cat >>confdefs.h <<\_ACEOF
11245#define BROKEN_UPDWTMPX 1
11246_ACEOF
11247
11248		{ echo "$as_me:$LINENO: checking for getluid in -lprot" >&5
11249echo $ECHO_N "checking for getluid in -lprot... $ECHO_C" >&6; }
11250if test "${ac_cv_lib_prot_getluid+set}" = set; then
11251  echo $ECHO_N "(cached) $ECHO_C" >&6
11252else
11253  ac_check_lib_save_LIBS=$LIBS
11254LIBS="-lprot  $LIBS"
11255cat >conftest.$ac_ext <<_ACEOF
11256/* confdefs.h.  */
11257_ACEOF
11258cat confdefs.h >>conftest.$ac_ext
11259cat >>conftest.$ac_ext <<_ACEOF
11260/* end confdefs.h.  */
11261
11262/* Override any GCC internal prototype to avoid an error.
11263   Use char because int might match the return type of a GCC
11264   builtin and then its argument prototype would still apply.  */
11265#ifdef __cplusplus
11266extern "C"
11267#endif
11268char getluid ();
11269int
11270main ()
11271{
11272return getluid ();
11273  ;
11274  return 0;
11275}
11276_ACEOF
11277rm -f conftest.$ac_objext conftest$ac_exeext
11278if { (ac_try="$ac_link"
11279case "(($ac_try" in
11280  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11281  *) ac_try_echo=$ac_try;;
11282esac
11283eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11284  (eval "$ac_link") 2>conftest.er1
11285  ac_status=$?
11286  grep -v '^ *+' conftest.er1 >conftest.err
11287  rm -f conftest.er1
11288  cat conftest.err >&5
11289  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11290  (exit $ac_status); } && {
11291	 test -z "$ac_c_werror_flag" ||
11292	 test ! -s conftest.err
11293       } && test -s conftest$ac_exeext &&
11294       $as_test_x conftest$ac_exeext; then
11295  ac_cv_lib_prot_getluid=yes
11296else
11297  echo "$as_me: failed program was:" >&5
11298sed 's/^/| /' conftest.$ac_ext >&5
11299
11300	ac_cv_lib_prot_getluid=no
11301fi
11302
11303rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11304      conftest$ac_exeext conftest.$ac_ext
11305LIBS=$ac_check_lib_save_LIBS
11306fi
11307{ echo "$as_me:$LINENO: result: $ac_cv_lib_prot_getluid" >&5
11308echo "${ECHO_T}$ac_cv_lib_prot_getluid" >&6; }
11309if test $ac_cv_lib_prot_getluid = yes; then
11310   LIBS="$LIBS -lprot"
11311
11312
11313for ac_func in getluid setluid
11314do
11315as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11316{ echo "$as_me:$LINENO: checking for $ac_func" >&5
11317echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
11318if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
11319  echo $ECHO_N "(cached) $ECHO_C" >&6
11320else
11321  cat >conftest.$ac_ext <<_ACEOF
11322/* confdefs.h.  */
11323_ACEOF
11324cat confdefs.h >>conftest.$ac_ext
11325cat >>conftest.$ac_ext <<_ACEOF
11326/* end confdefs.h.  */
11327/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
11328   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
11329#define $ac_func innocuous_$ac_func
11330
11331/* System header to define __stub macros and hopefully few prototypes,
11332    which can conflict with char $ac_func (); below.
11333    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11334    <limits.h> exists even on freestanding compilers.  */
11335
11336#ifdef __STDC__
11337# include <limits.h>
11338#else
11339# include <assert.h>
11340#endif
11341
11342#undef $ac_func
11343
11344/* Override any GCC internal prototype to avoid an error.
11345   Use char because int might match the return type of a GCC
11346   builtin and then its argument prototype would still apply.  */
11347#ifdef __cplusplus
11348extern "C"
11349#endif
11350char $ac_func ();
11351/* The GNU C library defines this for functions which it implements
11352    to always fail with ENOSYS.  Some functions are actually named
11353    something starting with __ and the normal name is an alias.  */
11354#if defined __stub_$ac_func || defined __stub___$ac_func
11355choke me
11356#endif
11357
11358int
11359main ()
11360{
11361return $ac_func ();
11362  ;
11363  return 0;
11364}
11365_ACEOF
11366rm -f conftest.$ac_objext conftest$ac_exeext
11367if { (ac_try="$ac_link"
11368case "(($ac_try" in
11369  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11370  *) ac_try_echo=$ac_try;;
11371esac
11372eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11373  (eval "$ac_link") 2>conftest.er1
11374  ac_status=$?
11375  grep -v '^ *+' conftest.er1 >conftest.err
11376  rm -f conftest.er1
11377  cat conftest.err >&5
11378  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11379  (exit $ac_status); } && {
11380	 test -z "$ac_c_werror_flag" ||
11381	 test ! -s conftest.err
11382       } && test -s conftest$ac_exeext &&
11383       $as_test_x conftest$ac_exeext; then
11384  eval "$as_ac_var=yes"
11385else
11386  echo "$as_me: failed program was:" >&5
11387sed 's/^/| /' conftest.$ac_ext >&5
11388
11389	eval "$as_ac_var=no"
11390fi
11391
11392rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11393      conftest$ac_exeext conftest.$ac_ext
11394fi
11395ac_res=`eval echo '${'$as_ac_var'}'`
11396	       { echo "$as_me:$LINENO: result: $ac_res" >&5
11397echo "${ECHO_T}$ac_res" >&6; }
11398if test `eval echo '${'$as_ac_var'}'` = yes; then
11399  cat >>confdefs.h <<_ACEOF
11400#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11401_ACEOF
11402
11403fi
11404done
11405
11406			cat >>confdefs.h <<\_ACEOF
11407#define HAVE_SECUREWARE 1
11408_ACEOF
11409
11410			cat >>confdefs.h <<\_ACEOF
11411#define DISABLE_SHADOW 1
11412_ACEOF
11413
11414
11415fi
11416
11417		;;
11418	*)	cat >>confdefs.h <<\_ACEOF
11419#define LOCKED_PASSWD_STRING "*LK*"
11420_ACEOF
11421
11422		check_for_libcrypt_later=1
11423		;;
11424	esac
11425	;;
11426*-*-sysv*)
11427	;;
11428# SCO UNIX and OEM versions of SCO UNIX
11429*-*-sco3.2v4*)
11430	{ { echo "$as_me:$LINENO: error: \"This Platform is no longer supported.\"" >&5
11431echo "$as_me: error: \"This Platform is no longer supported.\"" >&2;}
11432   { (exit 1); exit 1; }; }
11433	;;
11434# SCO OpenServer 5.x
11435*-*-sco3.2v5*)
11436	if test -z "$GCC"; then
11437		CFLAGS="$CFLAGS -belf"
11438	fi
11439	LIBS="$LIBS -lprot -lx -ltinfo -lm"
11440	no_dev_ptmx=1
11441	cat >>confdefs.h <<\_ACEOF
11442#define USE_PIPES 1
11443_ACEOF
11444
11445	cat >>confdefs.h <<\_ACEOF
11446#define HAVE_SECUREWARE 1
11447_ACEOF
11448
11449	cat >>confdefs.h <<\_ACEOF
11450#define DISABLE_SHADOW 1
11451_ACEOF
11452
11453	cat >>confdefs.h <<\_ACEOF
11454#define DISABLE_FD_PASSING 1
11455_ACEOF
11456
11457	cat >>confdefs.h <<\_ACEOF
11458#define SETEUID_BREAKS_SETUID 1
11459_ACEOF
11460
11461	cat >>confdefs.h <<\_ACEOF
11462#define BROKEN_GETADDRINFO 1
11463_ACEOF
11464
11465	cat >>confdefs.h <<\_ACEOF
11466#define BROKEN_SETREUID 1
11467_ACEOF
11468
11469	cat >>confdefs.h <<\_ACEOF
11470#define BROKEN_SETREGID 1
11471_ACEOF
11472
11473	cat >>confdefs.h <<\_ACEOF
11474#define WITH_ABBREV_NO_TTY 1
11475_ACEOF
11476
11477	cat >>confdefs.h <<\_ACEOF
11478#define BROKEN_UPDWTMPX 1
11479_ACEOF
11480
11481	cat >>confdefs.h <<\_ACEOF
11482#define PASSWD_NEEDS_USERNAME 1
11483_ACEOF
11484
11485
11486
11487for ac_func in getluid setluid
11488do
11489as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
11490{ echo "$as_me:$LINENO: checking for $ac_func" >&5
11491echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
11492if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
11493  echo $ECHO_N "(cached) $ECHO_C" >&6
11494else
11495  cat >conftest.$ac_ext <<_ACEOF
11496/* confdefs.h.  */
11497_ACEOF
11498cat confdefs.h >>conftest.$ac_ext
11499cat >>conftest.$ac_ext <<_ACEOF
11500/* end confdefs.h.  */
11501/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
11502   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
11503#define $ac_func innocuous_$ac_func
11504
11505/* System header to define __stub macros and hopefully few prototypes,
11506    which can conflict with char $ac_func (); below.
11507    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11508    <limits.h> exists even on freestanding compilers.  */
11509
11510#ifdef __STDC__
11511# include <limits.h>
11512#else
11513# include <assert.h>
11514#endif
11515
11516#undef $ac_func
11517
11518/* Override any GCC internal prototype to avoid an error.
11519   Use char because int might match the return type of a GCC
11520   builtin and then its argument prototype would still apply.  */
11521#ifdef __cplusplus
11522extern "C"
11523#endif
11524char $ac_func ();
11525/* The GNU C library defines this for functions which it implements
11526    to always fail with ENOSYS.  Some functions are actually named
11527    something starting with __ and the normal name is an alias.  */
11528#if defined __stub_$ac_func || defined __stub___$ac_func
11529choke me
11530#endif
11531
11532int
11533main ()
11534{
11535return $ac_func ();
11536  ;
11537  return 0;
11538}
11539_ACEOF
11540rm -f conftest.$ac_objext conftest$ac_exeext
11541if { (ac_try="$ac_link"
11542case "(($ac_try" in
11543  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11544  *) ac_try_echo=$ac_try;;
11545esac
11546eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11547  (eval "$ac_link") 2>conftest.er1
11548  ac_status=$?
11549  grep -v '^ *+' conftest.er1 >conftest.err
11550  rm -f conftest.er1
11551  cat conftest.err >&5
11552  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11553  (exit $ac_status); } && {
11554	 test -z "$ac_c_werror_flag" ||
11555	 test ! -s conftest.err
11556       } && test -s conftest$ac_exeext &&
11557       $as_test_x conftest$ac_exeext; then
11558  eval "$as_ac_var=yes"
11559else
11560  echo "$as_me: failed program was:" >&5
11561sed 's/^/| /' conftest.$ac_ext >&5
11562
11563	eval "$as_ac_var=no"
11564fi
11565
11566rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11567      conftest$ac_exeext conftest.$ac_ext
11568fi
11569ac_res=`eval echo '${'$as_ac_var'}'`
11570	       { echo "$as_me:$LINENO: result: $ac_res" >&5
11571echo "${ECHO_T}$ac_res" >&6; }
11572if test `eval echo '${'$as_ac_var'}'` = yes; then
11573  cat >>confdefs.h <<_ACEOF
11574#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
11575_ACEOF
11576
11577fi
11578done
11579
11580	MANTYPE=man
11581	TEST_SHELL=$SHELL	# let configure find us a capable shell
11582	SKIP_DISABLE_LASTLOG_DEFINE=yes
11583	;;
11584*-*-unicosmk*)
11585
11586cat >>confdefs.h <<\_ACEOF
11587#define NO_SSH_LASTLOG 1
11588_ACEOF
11589
11590	cat >>confdefs.h <<\_ACEOF
11591#define SETEUID_BREAKS_SETUID 1
11592_ACEOF
11593
11594	cat >>confdefs.h <<\_ACEOF
11595#define BROKEN_SETREUID 1
11596_ACEOF
11597
11598	cat >>confdefs.h <<\_ACEOF
11599#define BROKEN_SETREGID 1
11600_ACEOF
11601
11602	cat >>confdefs.h <<\_ACEOF
11603#define USE_PIPES 1
11604_ACEOF
11605
11606	cat >>confdefs.h <<\_ACEOF
11607#define DISABLE_FD_PASSING 1
11608_ACEOF
11609
11610	LDFLAGS="$LDFLAGS"
11611	LIBS="$LIBS -lgen -lrsc -lshare -luex -lacm"
11612	MANTYPE=cat
11613	;;
11614*-*-unicosmp*)
11615	cat >>confdefs.h <<\_ACEOF
11616#define SETEUID_BREAKS_SETUID 1
11617_ACEOF
11618
11619	cat >>confdefs.h <<\_ACEOF
11620#define BROKEN_SETREUID 1
11621_ACEOF
11622
11623	cat >>confdefs.h <<\_ACEOF
11624#define BROKEN_SETREGID 1
11625_ACEOF
11626
11627	cat >>confdefs.h <<\_ACEOF
11628#define WITH_ABBREV_NO_TTY 1
11629_ACEOF
11630
11631	cat >>confdefs.h <<\_ACEOF
11632#define USE_PIPES 1
11633_ACEOF
11634
11635	cat >>confdefs.h <<\_ACEOF
11636#define DISABLE_FD_PASSING 1
11637_ACEOF
11638
11639	LDFLAGS="$LDFLAGS"
11640	LIBS="$LIBS -lgen -lacid -ldb"
11641	MANTYPE=cat
11642	;;
11643*-*-unicos*)
11644	cat >>confdefs.h <<\_ACEOF
11645#define SETEUID_BREAKS_SETUID 1
11646_ACEOF
11647
11648	cat >>confdefs.h <<\_ACEOF
11649#define BROKEN_SETREUID 1
11650_ACEOF
11651
11652	cat >>confdefs.h <<\_ACEOF
11653#define BROKEN_SETREGID 1
11654_ACEOF
11655
11656	cat >>confdefs.h <<\_ACEOF
11657#define USE_PIPES 1
11658_ACEOF
11659
11660	cat >>confdefs.h <<\_ACEOF
11661#define DISABLE_FD_PASSING 1
11662_ACEOF
11663
11664	cat >>confdefs.h <<\_ACEOF
11665#define NO_SSH_LASTLOG 1
11666_ACEOF
11667
11668	LDFLAGS="$LDFLAGS -Wl,-Dmsglevel=334:fatal"
11669	LIBS="$LIBS -lgen -lrsc -lshare -luex -lacm"
11670	MANTYPE=cat
11671	;;
11672*-dec-osf*)
11673	{ echo "$as_me:$LINENO: checking for Digital Unix SIA" >&5
11674echo $ECHO_N "checking for Digital Unix SIA... $ECHO_C" >&6; }
11675	no_osfsia=""
11676
11677# Check whether --with-osfsia was given.
11678if test "${with_osfsia+set}" = set; then
11679  withval=$with_osfsia;
11680			if test "x$withval" = "xno" ; then
11681				{ echo "$as_me:$LINENO: result: disabled" >&5
11682echo "${ECHO_T}disabled" >&6; }
11683				no_osfsia=1
11684			fi
11685
11686fi
11687
11688	if test -z "$no_osfsia" ; then
11689		if test -f /etc/sia/matrix.conf; then
11690			{ echo "$as_me:$LINENO: result: yes" >&5
11691echo "${ECHO_T}yes" >&6; }
11692
11693cat >>confdefs.h <<\_ACEOF
11694#define HAVE_OSF_SIA 1
11695_ACEOF
11696
11697
11698cat >>confdefs.h <<\_ACEOF
11699#define DISABLE_LOGIN 1
11700_ACEOF
11701
11702			cat >>confdefs.h <<\_ACEOF
11703#define DISABLE_FD_PASSING 1
11704_ACEOF
11705
11706			LIBS="$LIBS -lsecurity -ldb -lm -laud"
11707			SIA_MSG="yes"
11708		else
11709			{ echo "$as_me:$LINENO: result: no" >&5
11710echo "${ECHO_T}no" >&6; }
11711
11712cat >>confdefs.h <<\_ACEOF
11713#define LOCKED_PASSWD_SUBSTR "Nologin"
11714_ACEOF
11715
11716		fi
11717	fi
11718	cat >>confdefs.h <<\_ACEOF
11719#define BROKEN_GETADDRINFO 1
11720_ACEOF
11721
11722	cat >>confdefs.h <<\_ACEOF
11723#define SETEUID_BREAKS_SETUID 1
11724_ACEOF
11725
11726	cat >>confdefs.h <<\_ACEOF
11727#define BROKEN_SETREUID 1
11728_ACEOF
11729
11730	cat >>confdefs.h <<\_ACEOF
11731#define BROKEN_SETREGID 1
11732_ACEOF
11733
11734
11735cat >>confdefs.h <<\_ACEOF
11736#define BROKEN_READV_COMPARISON 1
11737_ACEOF
11738
11739	;;
11740
11741*-*-nto-qnx*)
11742	cat >>confdefs.h <<\_ACEOF
11743#define USE_PIPES 1
11744_ACEOF
11745
11746	cat >>confdefs.h <<\_ACEOF
11747#define NO_X11_UNIX_SOCKETS 1
11748_ACEOF
11749
11750	cat >>confdefs.h <<\_ACEOF
11751#define DISABLE_LASTLOG 1
11752_ACEOF
11753
11754	cat >>confdefs.h <<\_ACEOF
11755#define SSHD_ACQUIRES_CTTY 1
11756_ACEOF
11757
11758
11759cat >>confdefs.h <<\_ACEOF
11760#define BROKEN_SHADOW_EXPIRE 1
11761_ACEOF
11762
11763	enable_etc_default_login=no	# has incompatible /etc/default/login
11764	case "$host" in
11765	*-*-nto-qnx6*)
11766		cat >>confdefs.h <<\_ACEOF
11767#define DISABLE_FD_PASSING 1
11768_ACEOF
11769
11770		;;
11771	esac
11772	;;
11773
11774*-*-ultrix*)
11775
11776cat >>confdefs.h <<\_ACEOF
11777#define BROKEN_GETGROUPS 1
11778_ACEOF
11779
11780
11781cat >>confdefs.h <<\_ACEOF
11782#define BROKEN_MMAP 1
11783_ACEOF
11784
11785	cat >>confdefs.h <<\_ACEOF
11786#define NEED_SETPGRP 1
11787_ACEOF
11788
11789
11790cat >>confdefs.h <<\_ACEOF
11791#define HAVE_SYS_SYSLOG_H 1
11792_ACEOF
11793
11794	;;
11795
11796*-*-lynxos)
11797        CFLAGS="$CFLAGS -D__NO_INCLUDE_WARN__"
11798
11799cat >>confdefs.h <<\_ACEOF
11800#define BROKEN_SETVBUF 1
11801_ACEOF
11802
11803        ;;
11804esac
11805
11806{ echo "$as_me:$LINENO: checking compiler and flags for sanity" >&5
11807echo $ECHO_N "checking compiler and flags for sanity... $ECHO_C" >&6; }
11808if test "$cross_compiling" = yes; then
11809  	{ echo "$as_me:$LINENO: WARNING: cross compiling: not checking compiler sanity" >&5
11810echo "$as_me: WARNING: cross compiling: not checking compiler sanity" >&2;}
11811
11812else
11813  cat >conftest.$ac_ext <<_ACEOF
11814/* confdefs.h.  */
11815_ACEOF
11816cat confdefs.h >>conftest.$ac_ext
11817cat >>conftest.$ac_ext <<_ACEOF
11818/* end confdefs.h.  */
11819 #include <stdio.h>
11820int
11821main ()
11822{
11823 exit(0);
11824  ;
11825  return 0;
11826}
11827_ACEOF
11828rm -f conftest$ac_exeext
11829if { (ac_try="$ac_link"
11830case "(($ac_try" in
11831  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11832  *) ac_try_echo=$ac_try;;
11833esac
11834eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11835  (eval "$ac_link") 2>&5
11836  ac_status=$?
11837  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11838  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11839  { (case "(($ac_try" in
11840  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11841  *) ac_try_echo=$ac_try;;
11842esac
11843eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11844  (eval "$ac_try") 2>&5
11845  ac_status=$?
11846  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11847  (exit $ac_status); }; }; then
11848  	{ echo "$as_me:$LINENO: result: yes" >&5
11849echo "${ECHO_T}yes" >&6; }
11850else
11851  echo "$as_me: program exited with status $ac_status" >&5
11852echo "$as_me: failed program was:" >&5
11853sed 's/^/| /' conftest.$ac_ext >&5
11854
11855( exit $ac_status )
11856
11857		{ echo "$as_me:$LINENO: result: no" >&5
11858echo "${ECHO_T}no" >&6; }
11859		{ { echo "$as_me:$LINENO: error: *** compiler cannot create working executables, check config.log ***" >&5
11860echo "$as_me: error: *** compiler cannot create working executables, check config.log ***" >&2;}
11861   { (exit 1); exit 1; }; }
11862
11863fi
11864rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11865fi
11866
11867
11868
11869# Checks for libraries.
11870{ echo "$as_me:$LINENO: checking for yp_match" >&5
11871echo $ECHO_N "checking for yp_match... $ECHO_C" >&6; }
11872if test "${ac_cv_func_yp_match+set}" = set; then
11873  echo $ECHO_N "(cached) $ECHO_C" >&6
11874else
11875  cat >conftest.$ac_ext <<_ACEOF
11876/* confdefs.h.  */
11877_ACEOF
11878cat confdefs.h >>conftest.$ac_ext
11879cat >>conftest.$ac_ext <<_ACEOF
11880/* end confdefs.h.  */
11881/* Define yp_match to an innocuous variant, in case <limits.h> declares yp_match.
11882   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
11883#define yp_match innocuous_yp_match
11884
11885/* System header to define __stub macros and hopefully few prototypes,
11886    which can conflict with char yp_match (); below.
11887    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
11888    <limits.h> exists even on freestanding compilers.  */
11889
11890#ifdef __STDC__
11891# include <limits.h>
11892#else
11893# include <assert.h>
11894#endif
11895
11896#undef yp_match
11897
11898/* Override any GCC internal prototype to avoid an error.
11899   Use char because int might match the return type of a GCC
11900   builtin and then its argument prototype would still apply.  */
11901#ifdef __cplusplus
11902extern "C"
11903#endif
11904char yp_match ();
11905/* The GNU C library defines this for functions which it implements
11906    to always fail with ENOSYS.  Some functions are actually named
11907    something starting with __ and the normal name is an alias.  */
11908#if defined __stub_yp_match || defined __stub___yp_match
11909choke me
11910#endif
11911
11912int
11913main ()
11914{
11915return yp_match ();
11916  ;
11917  return 0;
11918}
11919_ACEOF
11920rm -f conftest.$ac_objext conftest$ac_exeext
11921if { (ac_try="$ac_link"
11922case "(($ac_try" in
11923  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11924  *) ac_try_echo=$ac_try;;
11925esac
11926eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11927  (eval "$ac_link") 2>conftest.er1
11928  ac_status=$?
11929  grep -v '^ *+' conftest.er1 >conftest.err
11930  rm -f conftest.er1
11931  cat conftest.err >&5
11932  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11933  (exit $ac_status); } && {
11934	 test -z "$ac_c_werror_flag" ||
11935	 test ! -s conftest.err
11936       } && test -s conftest$ac_exeext &&
11937       $as_test_x conftest$ac_exeext; then
11938  ac_cv_func_yp_match=yes
11939else
11940  echo "$as_me: failed program was:" >&5
11941sed 's/^/| /' conftest.$ac_ext >&5
11942
11943	ac_cv_func_yp_match=no
11944fi
11945
11946rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
11947      conftest$ac_exeext conftest.$ac_ext
11948fi
11949{ echo "$as_me:$LINENO: result: $ac_cv_func_yp_match" >&5
11950echo "${ECHO_T}$ac_cv_func_yp_match" >&6; }
11951if test $ac_cv_func_yp_match = yes; then
11952  :
11953else
11954
11955{ echo "$as_me:$LINENO: checking for yp_match in -lnsl" >&5
11956echo $ECHO_N "checking for yp_match in -lnsl... $ECHO_C" >&6; }
11957if test "${ac_cv_lib_nsl_yp_match+set}" = set; then
11958  echo $ECHO_N "(cached) $ECHO_C" >&6
11959else
11960  ac_check_lib_save_LIBS=$LIBS
11961LIBS="-lnsl  $LIBS"
11962cat >conftest.$ac_ext <<_ACEOF
11963/* confdefs.h.  */
11964_ACEOF
11965cat confdefs.h >>conftest.$ac_ext
11966cat >>conftest.$ac_ext <<_ACEOF
11967/* end confdefs.h.  */
11968
11969/* Override any GCC internal prototype to avoid an error.
11970   Use char because int might match the return type of a GCC
11971   builtin and then its argument prototype would still apply.  */
11972#ifdef __cplusplus
11973extern "C"
11974#endif
11975char yp_match ();
11976int
11977main ()
11978{
11979return yp_match ();
11980  ;
11981  return 0;
11982}
11983_ACEOF
11984rm -f conftest.$ac_objext conftest$ac_exeext
11985if { (ac_try="$ac_link"
11986case "(($ac_try" in
11987  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11988  *) ac_try_echo=$ac_try;;
11989esac
11990eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
11991  (eval "$ac_link") 2>conftest.er1
11992  ac_status=$?
11993  grep -v '^ *+' conftest.er1 >conftest.err
11994  rm -f conftest.er1
11995  cat conftest.err >&5
11996  echo "$as_me:$LINENO: \$? = $ac_status" >&5
11997  (exit $ac_status); } && {
11998	 test -z "$ac_c_werror_flag" ||
11999	 test ! -s conftest.err
12000       } && test -s conftest$ac_exeext &&
12001       $as_test_x conftest$ac_exeext; then
12002  ac_cv_lib_nsl_yp_match=yes
12003else
12004  echo "$as_me: failed program was:" >&5
12005sed 's/^/| /' conftest.$ac_ext >&5
12006
12007	ac_cv_lib_nsl_yp_match=no
12008fi
12009
12010rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12011      conftest$ac_exeext conftest.$ac_ext
12012LIBS=$ac_check_lib_save_LIBS
12013fi
12014{ echo "$as_me:$LINENO: result: $ac_cv_lib_nsl_yp_match" >&5
12015echo "${ECHO_T}$ac_cv_lib_nsl_yp_match" >&6; }
12016if test $ac_cv_lib_nsl_yp_match = yes; then
12017  cat >>confdefs.h <<_ACEOF
12018#define HAVE_LIBNSL 1
12019_ACEOF
12020
12021  LIBS="-lnsl $LIBS"
12022
12023fi
12024
12025fi
12026
12027{ echo "$as_me:$LINENO: checking for setsockopt" >&5
12028echo $ECHO_N "checking for setsockopt... $ECHO_C" >&6; }
12029if test "${ac_cv_func_setsockopt+set}" = set; then
12030  echo $ECHO_N "(cached) $ECHO_C" >&6
12031else
12032  cat >conftest.$ac_ext <<_ACEOF
12033/* confdefs.h.  */
12034_ACEOF
12035cat confdefs.h >>conftest.$ac_ext
12036cat >>conftest.$ac_ext <<_ACEOF
12037/* end confdefs.h.  */
12038/* Define setsockopt to an innocuous variant, in case <limits.h> declares setsockopt.
12039   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
12040#define setsockopt innocuous_setsockopt
12041
12042/* System header to define __stub macros and hopefully few prototypes,
12043    which can conflict with char setsockopt (); below.
12044    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12045    <limits.h> exists even on freestanding compilers.  */
12046
12047#ifdef __STDC__
12048# include <limits.h>
12049#else
12050# include <assert.h>
12051#endif
12052
12053#undef setsockopt
12054
12055/* Override any GCC internal prototype to avoid an error.
12056   Use char because int might match the return type of a GCC
12057   builtin and then its argument prototype would still apply.  */
12058#ifdef __cplusplus
12059extern "C"
12060#endif
12061char setsockopt ();
12062/* The GNU C library defines this for functions which it implements
12063    to always fail with ENOSYS.  Some functions are actually named
12064    something starting with __ and the normal name is an alias.  */
12065#if defined __stub_setsockopt || defined __stub___setsockopt
12066choke me
12067#endif
12068
12069int
12070main ()
12071{
12072return setsockopt ();
12073  ;
12074  return 0;
12075}
12076_ACEOF
12077rm -f conftest.$ac_objext conftest$ac_exeext
12078if { (ac_try="$ac_link"
12079case "(($ac_try" in
12080  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12081  *) ac_try_echo=$ac_try;;
12082esac
12083eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12084  (eval "$ac_link") 2>conftest.er1
12085  ac_status=$?
12086  grep -v '^ *+' conftest.er1 >conftest.err
12087  rm -f conftest.er1
12088  cat conftest.err >&5
12089  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12090  (exit $ac_status); } && {
12091	 test -z "$ac_c_werror_flag" ||
12092	 test ! -s conftest.err
12093       } && test -s conftest$ac_exeext &&
12094       $as_test_x conftest$ac_exeext; then
12095  ac_cv_func_setsockopt=yes
12096else
12097  echo "$as_me: failed program was:" >&5
12098sed 's/^/| /' conftest.$ac_ext >&5
12099
12100	ac_cv_func_setsockopt=no
12101fi
12102
12103rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12104      conftest$ac_exeext conftest.$ac_ext
12105fi
12106{ echo "$as_me:$LINENO: result: $ac_cv_func_setsockopt" >&5
12107echo "${ECHO_T}$ac_cv_func_setsockopt" >&6; }
12108if test $ac_cv_func_setsockopt = yes; then
12109  :
12110else
12111
12112{ echo "$as_me:$LINENO: checking for setsockopt in -lsocket" >&5
12113echo $ECHO_N "checking for setsockopt in -lsocket... $ECHO_C" >&6; }
12114if test "${ac_cv_lib_socket_setsockopt+set}" = set; then
12115  echo $ECHO_N "(cached) $ECHO_C" >&6
12116else
12117  ac_check_lib_save_LIBS=$LIBS
12118LIBS="-lsocket  $LIBS"
12119cat >conftest.$ac_ext <<_ACEOF
12120/* confdefs.h.  */
12121_ACEOF
12122cat confdefs.h >>conftest.$ac_ext
12123cat >>conftest.$ac_ext <<_ACEOF
12124/* end confdefs.h.  */
12125
12126/* Override any GCC internal prototype to avoid an error.
12127   Use char because int might match the return type of a GCC
12128   builtin and then its argument prototype would still apply.  */
12129#ifdef __cplusplus
12130extern "C"
12131#endif
12132char setsockopt ();
12133int
12134main ()
12135{
12136return setsockopt ();
12137  ;
12138  return 0;
12139}
12140_ACEOF
12141rm -f conftest.$ac_objext conftest$ac_exeext
12142if { (ac_try="$ac_link"
12143case "(($ac_try" in
12144  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12145  *) ac_try_echo=$ac_try;;
12146esac
12147eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12148  (eval "$ac_link") 2>conftest.er1
12149  ac_status=$?
12150  grep -v '^ *+' conftest.er1 >conftest.err
12151  rm -f conftest.er1
12152  cat conftest.err >&5
12153  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12154  (exit $ac_status); } && {
12155	 test -z "$ac_c_werror_flag" ||
12156	 test ! -s conftest.err
12157       } && test -s conftest$ac_exeext &&
12158       $as_test_x conftest$ac_exeext; then
12159  ac_cv_lib_socket_setsockopt=yes
12160else
12161  echo "$as_me: failed program was:" >&5
12162sed 's/^/| /' conftest.$ac_ext >&5
12163
12164	ac_cv_lib_socket_setsockopt=no
12165fi
12166
12167rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12168      conftest$ac_exeext conftest.$ac_ext
12169LIBS=$ac_check_lib_save_LIBS
12170fi
12171{ echo "$as_me:$LINENO: result: $ac_cv_lib_socket_setsockopt" >&5
12172echo "${ECHO_T}$ac_cv_lib_socket_setsockopt" >&6; }
12173if test $ac_cv_lib_socket_setsockopt = yes; then
12174  cat >>confdefs.h <<_ACEOF
12175#define HAVE_LIBSOCKET 1
12176_ACEOF
12177
12178  LIBS="-lsocket $LIBS"
12179
12180fi
12181
12182fi
12183
12184
12185
12186for ac_func in dirname
12187do
12188as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12189{ echo "$as_me:$LINENO: checking for $ac_func" >&5
12190echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
12191if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
12192  echo $ECHO_N "(cached) $ECHO_C" >&6
12193else
12194  cat >conftest.$ac_ext <<_ACEOF
12195/* confdefs.h.  */
12196_ACEOF
12197cat confdefs.h >>conftest.$ac_ext
12198cat >>conftest.$ac_ext <<_ACEOF
12199/* end confdefs.h.  */
12200/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
12201   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
12202#define $ac_func innocuous_$ac_func
12203
12204/* System header to define __stub macros and hopefully few prototypes,
12205    which can conflict with char $ac_func (); below.
12206    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12207    <limits.h> exists even on freestanding compilers.  */
12208
12209#ifdef __STDC__
12210# include <limits.h>
12211#else
12212# include <assert.h>
12213#endif
12214
12215#undef $ac_func
12216
12217/* Override any GCC internal prototype to avoid an error.
12218   Use char because int might match the return type of a GCC
12219   builtin and then its argument prototype would still apply.  */
12220#ifdef __cplusplus
12221extern "C"
12222#endif
12223char $ac_func ();
12224/* The GNU C library defines this for functions which it implements
12225    to always fail with ENOSYS.  Some functions are actually named
12226    something starting with __ and the normal name is an alias.  */
12227#if defined __stub_$ac_func || defined __stub___$ac_func
12228choke me
12229#endif
12230
12231int
12232main ()
12233{
12234return $ac_func ();
12235  ;
12236  return 0;
12237}
12238_ACEOF
12239rm -f conftest.$ac_objext conftest$ac_exeext
12240if { (ac_try="$ac_link"
12241case "(($ac_try" in
12242  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12243  *) ac_try_echo=$ac_try;;
12244esac
12245eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12246  (eval "$ac_link") 2>conftest.er1
12247  ac_status=$?
12248  grep -v '^ *+' conftest.er1 >conftest.err
12249  rm -f conftest.er1
12250  cat conftest.err >&5
12251  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12252  (exit $ac_status); } && {
12253	 test -z "$ac_c_werror_flag" ||
12254	 test ! -s conftest.err
12255       } && test -s conftest$ac_exeext &&
12256       $as_test_x conftest$ac_exeext; then
12257  eval "$as_ac_var=yes"
12258else
12259  echo "$as_me: failed program was:" >&5
12260sed 's/^/| /' conftest.$ac_ext >&5
12261
12262	eval "$as_ac_var=no"
12263fi
12264
12265rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12266      conftest$ac_exeext conftest.$ac_ext
12267fi
12268ac_res=`eval echo '${'$as_ac_var'}'`
12269	       { echo "$as_me:$LINENO: result: $ac_res" >&5
12270echo "${ECHO_T}$ac_res" >&6; }
12271if test `eval echo '${'$as_ac_var'}'` = yes; then
12272  cat >>confdefs.h <<_ACEOF
12273#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12274_ACEOF
12275
12276for ac_header in libgen.h
12277do
12278as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12279if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12280  { echo "$as_me:$LINENO: checking for $ac_header" >&5
12281echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12282if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12283  echo $ECHO_N "(cached) $ECHO_C" >&6
12284fi
12285ac_res=`eval echo '${'$as_ac_Header'}'`
12286	       { echo "$as_me:$LINENO: result: $ac_res" >&5
12287echo "${ECHO_T}$ac_res" >&6; }
12288else
12289  # Is the header compilable?
12290{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
12291echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
12292cat >conftest.$ac_ext <<_ACEOF
12293/* confdefs.h.  */
12294_ACEOF
12295cat confdefs.h >>conftest.$ac_ext
12296cat >>conftest.$ac_ext <<_ACEOF
12297/* end confdefs.h.  */
12298$ac_includes_default
12299#include <$ac_header>
12300_ACEOF
12301rm -f conftest.$ac_objext
12302if { (ac_try="$ac_compile"
12303case "(($ac_try" in
12304  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12305  *) ac_try_echo=$ac_try;;
12306esac
12307eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12308  (eval "$ac_compile") 2>conftest.er1
12309  ac_status=$?
12310  grep -v '^ *+' conftest.er1 >conftest.err
12311  rm -f conftest.er1
12312  cat conftest.err >&5
12313  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12314  (exit $ac_status); } && {
12315	 test -z "$ac_c_werror_flag" ||
12316	 test ! -s conftest.err
12317       } && test -s conftest.$ac_objext; then
12318  ac_header_compiler=yes
12319else
12320  echo "$as_me: failed program was:" >&5
12321sed 's/^/| /' conftest.$ac_ext >&5
12322
12323	ac_header_compiler=no
12324fi
12325
12326rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12327{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12328echo "${ECHO_T}$ac_header_compiler" >&6; }
12329
12330# Is the header present?
12331{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
12332echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
12333cat >conftest.$ac_ext <<_ACEOF
12334/* confdefs.h.  */
12335_ACEOF
12336cat confdefs.h >>conftest.$ac_ext
12337cat >>conftest.$ac_ext <<_ACEOF
12338/* end confdefs.h.  */
12339#include <$ac_header>
12340_ACEOF
12341if { (ac_try="$ac_cpp conftest.$ac_ext"
12342case "(($ac_try" in
12343  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12344  *) ac_try_echo=$ac_try;;
12345esac
12346eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12347  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12348  ac_status=$?
12349  grep -v '^ *+' conftest.er1 >conftest.err
12350  rm -f conftest.er1
12351  cat conftest.err >&5
12352  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12353  (exit $ac_status); } >/dev/null && {
12354	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12355	 test ! -s conftest.err
12356       }; then
12357  ac_header_preproc=yes
12358else
12359  echo "$as_me: failed program was:" >&5
12360sed 's/^/| /' conftest.$ac_ext >&5
12361
12362  ac_header_preproc=no
12363fi
12364
12365rm -f conftest.err conftest.$ac_ext
12366{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12367echo "${ECHO_T}$ac_header_preproc" >&6; }
12368
12369# So?  What about this header?
12370case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12371  yes:no: )
12372    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12373echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12374    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12375echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12376    ac_header_preproc=yes
12377    ;;
12378  no:yes:* )
12379    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12380echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12381    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12382echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12383    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12384echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12385    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12386echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12387    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12388echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12389    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12390echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12391    ( cat <<\_ASBOX
12392## ------------------------------------------- ##
12393## Report this to openssh-unix-dev@mindrot.org ##
12394## ------------------------------------------- ##
12395_ASBOX
12396     ) | sed "s/^/$as_me: WARNING:     /" >&2
12397    ;;
12398esac
12399{ echo "$as_me:$LINENO: checking for $ac_header" >&5
12400echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12401if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12402  echo $ECHO_N "(cached) $ECHO_C" >&6
12403else
12404  eval "$as_ac_Header=\$ac_header_preproc"
12405fi
12406ac_res=`eval echo '${'$as_ac_Header'}'`
12407	       { echo "$as_me:$LINENO: result: $ac_res" >&5
12408echo "${ECHO_T}$ac_res" >&6; }
12409
12410fi
12411if test `eval echo '${'$as_ac_Header'}'` = yes; then
12412  cat >>confdefs.h <<_ACEOF
12413#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12414_ACEOF
12415
12416fi
12417
12418done
12419
12420else
12421
12422	{ echo "$as_me:$LINENO: checking for dirname in -lgen" >&5
12423echo $ECHO_N "checking for dirname in -lgen... $ECHO_C" >&6; }
12424if test "${ac_cv_lib_gen_dirname+set}" = set; then
12425  echo $ECHO_N "(cached) $ECHO_C" >&6
12426else
12427  ac_check_lib_save_LIBS=$LIBS
12428LIBS="-lgen  $LIBS"
12429cat >conftest.$ac_ext <<_ACEOF
12430/* confdefs.h.  */
12431_ACEOF
12432cat confdefs.h >>conftest.$ac_ext
12433cat >>conftest.$ac_ext <<_ACEOF
12434/* end confdefs.h.  */
12435
12436/* Override any GCC internal prototype to avoid an error.
12437   Use char because int might match the return type of a GCC
12438   builtin and then its argument prototype would still apply.  */
12439#ifdef __cplusplus
12440extern "C"
12441#endif
12442char dirname ();
12443int
12444main ()
12445{
12446return dirname ();
12447  ;
12448  return 0;
12449}
12450_ACEOF
12451rm -f conftest.$ac_objext conftest$ac_exeext
12452if { (ac_try="$ac_link"
12453case "(($ac_try" in
12454  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12455  *) ac_try_echo=$ac_try;;
12456esac
12457eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12458  (eval "$ac_link") 2>conftest.er1
12459  ac_status=$?
12460  grep -v '^ *+' conftest.er1 >conftest.err
12461  rm -f conftest.er1
12462  cat conftest.err >&5
12463  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12464  (exit $ac_status); } && {
12465	 test -z "$ac_c_werror_flag" ||
12466	 test ! -s conftest.err
12467       } && test -s conftest$ac_exeext &&
12468       $as_test_x conftest$ac_exeext; then
12469  ac_cv_lib_gen_dirname=yes
12470else
12471  echo "$as_me: failed program was:" >&5
12472sed 's/^/| /' conftest.$ac_ext >&5
12473
12474	ac_cv_lib_gen_dirname=no
12475fi
12476
12477rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12478      conftest$ac_exeext conftest.$ac_ext
12479LIBS=$ac_check_lib_save_LIBS
12480fi
12481{ echo "$as_me:$LINENO: result: $ac_cv_lib_gen_dirname" >&5
12482echo "${ECHO_T}$ac_cv_lib_gen_dirname" >&6; }
12483if test $ac_cv_lib_gen_dirname = yes; then
12484
12485		{ echo "$as_me:$LINENO: checking for broken dirname" >&5
12486echo $ECHO_N "checking for broken dirname... $ECHO_C" >&6; }
12487if test "${ac_cv_have_broken_dirname+set}" = set; then
12488  echo $ECHO_N "(cached) $ECHO_C" >&6
12489else
12490
12491			save_LIBS="$LIBS"
12492			LIBS="$LIBS -lgen"
12493			if test "$cross_compiling" = yes; then
12494   ac_cv_have_broken_dirname="no"
12495else
12496  cat >conftest.$ac_ext <<_ACEOF
12497/* confdefs.h.  */
12498_ACEOF
12499cat confdefs.h >>conftest.$ac_ext
12500cat >>conftest.$ac_ext <<_ACEOF
12501/* end confdefs.h.  */
12502
12503#include <libgen.h>
12504#include <string.h>
12505
12506int main(int argc, char **argv) {
12507    char *s, buf[32];
12508
12509    strncpy(buf,"/etc", 32);
12510    s = dirname(buf);
12511    if (!s || strncmp(s, "/", 32) != 0) {
12512	exit(1);
12513    } else {
12514	exit(0);
12515    }
12516}
12517
12518_ACEOF
12519rm -f conftest$ac_exeext
12520if { (ac_try="$ac_link"
12521case "(($ac_try" in
12522  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12523  *) ac_try_echo=$ac_try;;
12524esac
12525eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12526  (eval "$ac_link") 2>&5
12527  ac_status=$?
12528  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12529  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
12530  { (case "(($ac_try" in
12531  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12532  *) ac_try_echo=$ac_try;;
12533esac
12534eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12535  (eval "$ac_try") 2>&5
12536  ac_status=$?
12537  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12538  (exit $ac_status); }; }; then
12539   ac_cv_have_broken_dirname="no"
12540else
12541  echo "$as_me: program exited with status $ac_status" >&5
12542echo "$as_me: failed program was:" >&5
12543sed 's/^/| /' conftest.$ac_ext >&5
12544
12545( exit $ac_status )
12546 ac_cv_have_broken_dirname="yes"
12547fi
12548rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
12549fi
12550
12551
12552			LIBS="$save_LIBS"
12553
12554fi
12555{ echo "$as_me:$LINENO: result: $ac_cv_have_broken_dirname" >&5
12556echo "${ECHO_T}$ac_cv_have_broken_dirname" >&6; }
12557		if test "x$ac_cv_have_broken_dirname" = "xno" ; then
12558			LIBS="$LIBS -lgen"
12559			cat >>confdefs.h <<\_ACEOF
12560#define HAVE_DIRNAME 1
12561_ACEOF
12562
12563
12564for ac_header in libgen.h
12565do
12566as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12567if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12568  { echo "$as_me:$LINENO: checking for $ac_header" >&5
12569echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12570if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12571  echo $ECHO_N "(cached) $ECHO_C" >&6
12572fi
12573ac_res=`eval echo '${'$as_ac_Header'}'`
12574	       { echo "$as_me:$LINENO: result: $ac_res" >&5
12575echo "${ECHO_T}$ac_res" >&6; }
12576else
12577  # Is the header compilable?
12578{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
12579echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
12580cat >conftest.$ac_ext <<_ACEOF
12581/* confdefs.h.  */
12582_ACEOF
12583cat confdefs.h >>conftest.$ac_ext
12584cat >>conftest.$ac_ext <<_ACEOF
12585/* end confdefs.h.  */
12586$ac_includes_default
12587#include <$ac_header>
12588_ACEOF
12589rm -f conftest.$ac_objext
12590if { (ac_try="$ac_compile"
12591case "(($ac_try" in
12592  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12593  *) ac_try_echo=$ac_try;;
12594esac
12595eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12596  (eval "$ac_compile") 2>conftest.er1
12597  ac_status=$?
12598  grep -v '^ *+' conftest.er1 >conftest.err
12599  rm -f conftest.er1
12600  cat conftest.err >&5
12601  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12602  (exit $ac_status); } && {
12603	 test -z "$ac_c_werror_flag" ||
12604	 test ! -s conftest.err
12605       } && test -s conftest.$ac_objext; then
12606  ac_header_compiler=yes
12607else
12608  echo "$as_me: failed program was:" >&5
12609sed 's/^/| /' conftest.$ac_ext >&5
12610
12611	ac_header_compiler=no
12612fi
12613
12614rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12615{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12616echo "${ECHO_T}$ac_header_compiler" >&6; }
12617
12618# Is the header present?
12619{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
12620echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
12621cat >conftest.$ac_ext <<_ACEOF
12622/* confdefs.h.  */
12623_ACEOF
12624cat confdefs.h >>conftest.$ac_ext
12625cat >>conftest.$ac_ext <<_ACEOF
12626/* end confdefs.h.  */
12627#include <$ac_header>
12628_ACEOF
12629if { (ac_try="$ac_cpp conftest.$ac_ext"
12630case "(($ac_try" in
12631  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12632  *) ac_try_echo=$ac_try;;
12633esac
12634eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12635  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12636  ac_status=$?
12637  grep -v '^ *+' conftest.er1 >conftest.err
12638  rm -f conftest.er1
12639  cat conftest.err >&5
12640  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12641  (exit $ac_status); } >/dev/null && {
12642	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12643	 test ! -s conftest.err
12644       }; then
12645  ac_header_preproc=yes
12646else
12647  echo "$as_me: failed program was:" >&5
12648sed 's/^/| /' conftest.$ac_ext >&5
12649
12650  ac_header_preproc=no
12651fi
12652
12653rm -f conftest.err conftest.$ac_ext
12654{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12655echo "${ECHO_T}$ac_header_preproc" >&6; }
12656
12657# So?  What about this header?
12658case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12659  yes:no: )
12660    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12661echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12662    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12663echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12664    ac_header_preproc=yes
12665    ;;
12666  no:yes:* )
12667    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12668echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12669    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12670echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12671    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12672echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12673    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12674echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12675    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12676echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12677    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12678echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12679    ( cat <<\_ASBOX
12680## ------------------------------------------- ##
12681## Report this to openssh-unix-dev@mindrot.org ##
12682## ------------------------------------------- ##
12683_ASBOX
12684     ) | sed "s/^/$as_me: WARNING:     /" >&2
12685    ;;
12686esac
12687{ echo "$as_me:$LINENO: checking for $ac_header" >&5
12688echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
12689if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12690  echo $ECHO_N "(cached) $ECHO_C" >&6
12691else
12692  eval "$as_ac_Header=\$ac_header_preproc"
12693fi
12694ac_res=`eval echo '${'$as_ac_Header'}'`
12695	       { echo "$as_me:$LINENO: result: $ac_res" >&5
12696echo "${ECHO_T}$ac_res" >&6; }
12697
12698fi
12699if test `eval echo '${'$as_ac_Header'}'` = yes; then
12700  cat >>confdefs.h <<_ACEOF
12701#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12702_ACEOF
12703
12704fi
12705
12706done
12707
12708		fi
12709
12710fi
12711
12712
12713fi
12714done
12715
12716
12717{ echo "$as_me:$LINENO: checking for getspnam" >&5
12718echo $ECHO_N "checking for getspnam... $ECHO_C" >&6; }
12719if test "${ac_cv_func_getspnam+set}" = set; then
12720  echo $ECHO_N "(cached) $ECHO_C" >&6
12721else
12722  cat >conftest.$ac_ext <<_ACEOF
12723/* confdefs.h.  */
12724_ACEOF
12725cat confdefs.h >>conftest.$ac_ext
12726cat >>conftest.$ac_ext <<_ACEOF
12727/* end confdefs.h.  */
12728/* Define getspnam to an innocuous variant, in case <limits.h> declares getspnam.
12729   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
12730#define getspnam innocuous_getspnam
12731
12732/* System header to define __stub macros and hopefully few prototypes,
12733    which can conflict with char getspnam (); below.
12734    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12735    <limits.h> exists even on freestanding compilers.  */
12736
12737#ifdef __STDC__
12738# include <limits.h>
12739#else
12740# include <assert.h>
12741#endif
12742
12743#undef getspnam
12744
12745/* Override any GCC internal prototype to avoid an error.
12746   Use char because int might match the return type of a GCC
12747   builtin and then its argument prototype would still apply.  */
12748#ifdef __cplusplus
12749extern "C"
12750#endif
12751char getspnam ();
12752/* The GNU C library defines this for functions which it implements
12753    to always fail with ENOSYS.  Some functions are actually named
12754    something starting with __ and the normal name is an alias.  */
12755#if defined __stub_getspnam || defined __stub___getspnam
12756choke me
12757#endif
12758
12759int
12760main ()
12761{
12762return getspnam ();
12763  ;
12764  return 0;
12765}
12766_ACEOF
12767rm -f conftest.$ac_objext conftest$ac_exeext
12768if { (ac_try="$ac_link"
12769case "(($ac_try" in
12770  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12771  *) ac_try_echo=$ac_try;;
12772esac
12773eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12774  (eval "$ac_link") 2>conftest.er1
12775  ac_status=$?
12776  grep -v '^ *+' conftest.er1 >conftest.err
12777  rm -f conftest.er1
12778  cat conftest.err >&5
12779  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12780  (exit $ac_status); } && {
12781	 test -z "$ac_c_werror_flag" ||
12782	 test ! -s conftest.err
12783       } && test -s conftest$ac_exeext &&
12784       $as_test_x conftest$ac_exeext; then
12785  ac_cv_func_getspnam=yes
12786else
12787  echo "$as_me: failed program was:" >&5
12788sed 's/^/| /' conftest.$ac_ext >&5
12789
12790	ac_cv_func_getspnam=no
12791fi
12792
12793rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12794      conftest$ac_exeext conftest.$ac_ext
12795fi
12796{ echo "$as_me:$LINENO: result: $ac_cv_func_getspnam" >&5
12797echo "${ECHO_T}$ac_cv_func_getspnam" >&6; }
12798if test $ac_cv_func_getspnam = yes; then
12799  :
12800else
12801  { echo "$as_me:$LINENO: checking for getspnam in -lgen" >&5
12802echo $ECHO_N "checking for getspnam in -lgen... $ECHO_C" >&6; }
12803if test "${ac_cv_lib_gen_getspnam+set}" = set; then
12804  echo $ECHO_N "(cached) $ECHO_C" >&6
12805else
12806  ac_check_lib_save_LIBS=$LIBS
12807LIBS="-lgen  $LIBS"
12808cat >conftest.$ac_ext <<_ACEOF
12809/* confdefs.h.  */
12810_ACEOF
12811cat confdefs.h >>conftest.$ac_ext
12812cat >>conftest.$ac_ext <<_ACEOF
12813/* end confdefs.h.  */
12814
12815/* Override any GCC internal prototype to avoid an error.
12816   Use char because int might match the return type of a GCC
12817   builtin and then its argument prototype would still apply.  */
12818#ifdef __cplusplus
12819extern "C"
12820#endif
12821char getspnam ();
12822int
12823main ()
12824{
12825return getspnam ();
12826  ;
12827  return 0;
12828}
12829_ACEOF
12830rm -f conftest.$ac_objext conftest$ac_exeext
12831if { (ac_try="$ac_link"
12832case "(($ac_try" in
12833  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12834  *) ac_try_echo=$ac_try;;
12835esac
12836eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12837  (eval "$ac_link") 2>conftest.er1
12838  ac_status=$?
12839  grep -v '^ *+' conftest.er1 >conftest.err
12840  rm -f conftest.er1
12841  cat conftest.err >&5
12842  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12843  (exit $ac_status); } && {
12844	 test -z "$ac_c_werror_flag" ||
12845	 test ! -s conftest.err
12846       } && test -s conftest$ac_exeext &&
12847       $as_test_x conftest$ac_exeext; then
12848  ac_cv_lib_gen_getspnam=yes
12849else
12850  echo "$as_me: failed program was:" >&5
12851sed 's/^/| /' conftest.$ac_ext >&5
12852
12853	ac_cv_lib_gen_getspnam=no
12854fi
12855
12856rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12857      conftest$ac_exeext conftest.$ac_ext
12858LIBS=$ac_check_lib_save_LIBS
12859fi
12860{ echo "$as_me:$LINENO: result: $ac_cv_lib_gen_getspnam" >&5
12861echo "${ECHO_T}$ac_cv_lib_gen_getspnam" >&6; }
12862if test $ac_cv_lib_gen_getspnam = yes; then
12863  LIBS="$LIBS -lgen"
12864fi
12865
12866fi
12867
12868{ echo "$as_me:$LINENO: checking for library containing basename" >&5
12869echo $ECHO_N "checking for library containing basename... $ECHO_C" >&6; }
12870if test "${ac_cv_search_basename+set}" = set; then
12871  echo $ECHO_N "(cached) $ECHO_C" >&6
12872else
12873  ac_func_search_save_LIBS=$LIBS
12874cat >conftest.$ac_ext <<_ACEOF
12875/* confdefs.h.  */
12876_ACEOF
12877cat confdefs.h >>conftest.$ac_ext
12878cat >>conftest.$ac_ext <<_ACEOF
12879/* end confdefs.h.  */
12880
12881/* Override any GCC internal prototype to avoid an error.
12882   Use char because int might match the return type of a GCC
12883   builtin and then its argument prototype would still apply.  */
12884#ifdef __cplusplus
12885extern "C"
12886#endif
12887char basename ();
12888int
12889main ()
12890{
12891return basename ();
12892  ;
12893  return 0;
12894}
12895_ACEOF
12896for ac_lib in '' gen; do
12897  if test -z "$ac_lib"; then
12898    ac_res="none required"
12899  else
12900    ac_res=-l$ac_lib
12901    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
12902  fi
12903  rm -f conftest.$ac_objext conftest$ac_exeext
12904if { (ac_try="$ac_link"
12905case "(($ac_try" in
12906  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12907  *) ac_try_echo=$ac_try;;
12908esac
12909eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
12910  (eval "$ac_link") 2>conftest.er1
12911  ac_status=$?
12912  grep -v '^ *+' conftest.er1 >conftest.err
12913  rm -f conftest.er1
12914  cat conftest.err >&5
12915  echo "$as_me:$LINENO: \$? = $ac_status" >&5
12916  (exit $ac_status); } && {
12917	 test -z "$ac_c_werror_flag" ||
12918	 test ! -s conftest.err
12919       } && test -s conftest$ac_exeext &&
12920       $as_test_x conftest$ac_exeext; then
12921  ac_cv_search_basename=$ac_res
12922else
12923  echo "$as_me: failed program was:" >&5
12924sed 's/^/| /' conftest.$ac_ext >&5
12925
12926
12927fi
12928
12929rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12930      conftest$ac_exeext
12931  if test "${ac_cv_search_basename+set}" = set; then
12932  break
12933fi
12934done
12935if test "${ac_cv_search_basename+set}" = set; then
12936  :
12937else
12938  ac_cv_search_basename=no
12939fi
12940rm conftest.$ac_ext
12941LIBS=$ac_func_search_save_LIBS
12942fi
12943{ echo "$as_me:$LINENO: result: $ac_cv_search_basename" >&5
12944echo "${ECHO_T}$ac_cv_search_basename" >&6; }
12945ac_res=$ac_cv_search_basename
12946if test "$ac_res" != no; then
12947  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
12948
12949cat >>confdefs.h <<\_ACEOF
12950#define HAVE_BASENAME 1
12951_ACEOF
12952
12953fi
12954
12955
12956
12957# Check whether --with-zlib was given.
12958if test "${with_zlib+set}" = set; then
12959  withval=$with_zlib;  if test "x$withval" = "xno" ; then
12960		{ { echo "$as_me:$LINENO: error: *** zlib is required ***" >&5
12961echo "$as_me: error: *** zlib is required ***" >&2;}
12962   { (exit 1); exit 1; }; }
12963	  elif test "x$withval" != "xyes"; then
12964		if test -d "$withval/lib"; then
12965			if test -n "${need_dash_r}"; then
12966				LDFLAGS="-L${withval}/lib -R${withval}/lib ${LDFLAGS}"
12967			else
12968				LDFLAGS="-L${withval}/lib ${LDFLAGS}"
12969			fi
12970		else
12971			if test -n "${need_dash_r}"; then
12972				LDFLAGS="-L${withval} -R${withval} ${LDFLAGS}"
12973			else
12974				LDFLAGS="-L${withval} ${LDFLAGS}"
12975			fi
12976		fi
12977		if test -d "$withval/include"; then
12978			CPPFLAGS="-I${withval}/include ${CPPFLAGS}"
12979		else
12980			CPPFLAGS="-I${withval} ${CPPFLAGS}"
12981		fi
12982	fi
12983
12984fi
12985
12986
12987if test "${ac_cv_header_zlib_h+set}" = set; then
12988  { echo "$as_me:$LINENO: checking for zlib.h" >&5
12989echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6; }
12990if test "${ac_cv_header_zlib_h+set}" = set; then
12991  echo $ECHO_N "(cached) $ECHO_C" >&6
12992fi
12993{ echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
12994echo "${ECHO_T}$ac_cv_header_zlib_h" >&6; }
12995else
12996  # Is the header compilable?
12997{ echo "$as_me:$LINENO: checking zlib.h usability" >&5
12998echo $ECHO_N "checking zlib.h usability... $ECHO_C" >&6; }
12999cat >conftest.$ac_ext <<_ACEOF
13000/* confdefs.h.  */
13001_ACEOF
13002cat confdefs.h >>conftest.$ac_ext
13003cat >>conftest.$ac_ext <<_ACEOF
13004/* end confdefs.h.  */
13005$ac_includes_default
13006#include <zlib.h>
13007_ACEOF
13008rm -f conftest.$ac_objext
13009if { (ac_try="$ac_compile"
13010case "(($ac_try" in
13011  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13012  *) ac_try_echo=$ac_try;;
13013esac
13014eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13015  (eval "$ac_compile") 2>conftest.er1
13016  ac_status=$?
13017  grep -v '^ *+' conftest.er1 >conftest.err
13018  rm -f conftest.er1
13019  cat conftest.err >&5
13020  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13021  (exit $ac_status); } && {
13022	 test -z "$ac_c_werror_flag" ||
13023	 test ! -s conftest.err
13024       } && test -s conftest.$ac_objext; then
13025  ac_header_compiler=yes
13026else
13027  echo "$as_me: failed program was:" >&5
13028sed 's/^/| /' conftest.$ac_ext >&5
13029
13030	ac_header_compiler=no
13031fi
13032
13033rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13034{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13035echo "${ECHO_T}$ac_header_compiler" >&6; }
13036
13037# Is the header present?
13038{ echo "$as_me:$LINENO: checking zlib.h presence" >&5
13039echo $ECHO_N "checking zlib.h presence... $ECHO_C" >&6; }
13040cat >conftest.$ac_ext <<_ACEOF
13041/* confdefs.h.  */
13042_ACEOF
13043cat confdefs.h >>conftest.$ac_ext
13044cat >>conftest.$ac_ext <<_ACEOF
13045/* end confdefs.h.  */
13046#include <zlib.h>
13047_ACEOF
13048if { (ac_try="$ac_cpp conftest.$ac_ext"
13049case "(($ac_try" in
13050  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13051  *) ac_try_echo=$ac_try;;
13052esac
13053eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13054  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13055  ac_status=$?
13056  grep -v '^ *+' conftest.er1 >conftest.err
13057  rm -f conftest.er1
13058  cat conftest.err >&5
13059  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13060  (exit $ac_status); } >/dev/null && {
13061	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13062	 test ! -s conftest.err
13063       }; then
13064  ac_header_preproc=yes
13065else
13066  echo "$as_me: failed program was:" >&5
13067sed 's/^/| /' conftest.$ac_ext >&5
13068
13069  ac_header_preproc=no
13070fi
13071
13072rm -f conftest.err conftest.$ac_ext
13073{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13074echo "${ECHO_T}$ac_header_preproc" >&6; }
13075
13076# So?  What about this header?
13077case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13078  yes:no: )
13079    { echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
13080echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13081    { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
13082echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
13083    ac_header_preproc=yes
13084    ;;
13085  no:yes:* )
13086    { echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
13087echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
13088    { echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
13089echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
13090    { echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
13091echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
13092    { echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
13093echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13094    { echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
13095echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
13096    { echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
13097echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
13098    ( cat <<\_ASBOX
13099## ------------------------------------------- ##
13100## Report this to openssh-unix-dev@mindrot.org ##
13101## ------------------------------------------- ##
13102_ASBOX
13103     ) | sed "s/^/$as_me: WARNING:     /" >&2
13104    ;;
13105esac
13106{ echo "$as_me:$LINENO: checking for zlib.h" >&5
13107echo $ECHO_N "checking for zlib.h... $ECHO_C" >&6; }
13108if test "${ac_cv_header_zlib_h+set}" = set; then
13109  echo $ECHO_N "(cached) $ECHO_C" >&6
13110else
13111  ac_cv_header_zlib_h=$ac_header_preproc
13112fi
13113{ echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
13114echo "${ECHO_T}$ac_cv_header_zlib_h" >&6; }
13115
13116fi
13117if test $ac_cv_header_zlib_h = yes; then
13118  :
13119else
13120  { { echo "$as_me:$LINENO: error: *** zlib.h missing - please install first or check config.log ***" >&5
13121echo "$as_me: error: *** zlib.h missing - please install first or check config.log ***" >&2;}
13122   { (exit 1); exit 1; }; }
13123fi
13124
13125
13126
13127{ echo "$as_me:$LINENO: checking for deflate in -lz" >&5
13128echo $ECHO_N "checking for deflate in -lz... $ECHO_C" >&6; }
13129if test "${ac_cv_lib_z_deflate+set}" = set; then
13130  echo $ECHO_N "(cached) $ECHO_C" >&6
13131else
13132  ac_check_lib_save_LIBS=$LIBS
13133LIBS="-lz  $LIBS"
13134cat >conftest.$ac_ext <<_ACEOF
13135/* confdefs.h.  */
13136_ACEOF
13137cat confdefs.h >>conftest.$ac_ext
13138cat >>conftest.$ac_ext <<_ACEOF
13139/* end confdefs.h.  */
13140
13141/* Override any GCC internal prototype to avoid an error.
13142   Use char because int might match the return type of a GCC
13143   builtin and then its argument prototype would still apply.  */
13144#ifdef __cplusplus
13145extern "C"
13146#endif
13147char deflate ();
13148int
13149main ()
13150{
13151return deflate ();
13152  ;
13153  return 0;
13154}
13155_ACEOF
13156rm -f conftest.$ac_objext conftest$ac_exeext
13157if { (ac_try="$ac_link"
13158case "(($ac_try" in
13159  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13160  *) ac_try_echo=$ac_try;;
13161esac
13162eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13163  (eval "$ac_link") 2>conftest.er1
13164  ac_status=$?
13165  grep -v '^ *+' conftest.er1 >conftest.err
13166  rm -f conftest.er1
13167  cat conftest.err >&5
13168  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13169  (exit $ac_status); } && {
13170	 test -z "$ac_c_werror_flag" ||
13171	 test ! -s conftest.err
13172       } && test -s conftest$ac_exeext &&
13173       $as_test_x conftest$ac_exeext; then
13174  ac_cv_lib_z_deflate=yes
13175else
13176  echo "$as_me: failed program was:" >&5
13177sed 's/^/| /' conftest.$ac_ext >&5
13178
13179	ac_cv_lib_z_deflate=no
13180fi
13181
13182rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13183      conftest$ac_exeext conftest.$ac_ext
13184LIBS=$ac_check_lib_save_LIBS
13185fi
13186{ echo "$as_me:$LINENO: result: $ac_cv_lib_z_deflate" >&5
13187echo "${ECHO_T}$ac_cv_lib_z_deflate" >&6; }
13188if test $ac_cv_lib_z_deflate = yes; then
13189  cat >>confdefs.h <<_ACEOF
13190#define HAVE_LIBZ 1
13191_ACEOF
13192
13193  LIBS="-lz $LIBS"
13194
13195else
13196
13197		saved_CPPFLAGS="$CPPFLAGS"
13198		saved_LDFLAGS="$LDFLAGS"
13199		save_LIBS="$LIBS"
13200				if test -n "${need_dash_r}"; then
13201			LDFLAGS="-L/usr/local/lib -R/usr/local/lib ${saved_LDFLAGS}"
13202		else
13203			LDFLAGS="-L/usr/local/lib ${saved_LDFLAGS}"
13204		fi
13205		CPPFLAGS="-I/usr/local/include ${saved_CPPFLAGS}"
13206		LIBS="$LIBS -lz"
13207		cat >conftest.$ac_ext <<_ACEOF
13208/* confdefs.h.  */
13209_ACEOF
13210cat confdefs.h >>conftest.$ac_ext
13211cat >>conftest.$ac_ext <<_ACEOF
13212/* end confdefs.h.  */
13213
13214/* Override any GCC internal prototype to avoid an error.
13215   Use char because int might match the return type of a GCC
13216   builtin and then its argument prototype would still apply.  */
13217#ifdef __cplusplus
13218extern "C"
13219#endif
13220char deflate ();
13221int
13222main ()
13223{
13224return deflate ();
13225  ;
13226  return 0;
13227}
13228_ACEOF
13229rm -f conftest.$ac_objext conftest$ac_exeext
13230if { (ac_try="$ac_link"
13231case "(($ac_try" in
13232  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13233  *) ac_try_echo=$ac_try;;
13234esac
13235eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13236  (eval "$ac_link") 2>conftest.er1
13237  ac_status=$?
13238  grep -v '^ *+' conftest.er1 >conftest.err
13239  rm -f conftest.er1
13240  cat conftest.err >&5
13241  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13242  (exit $ac_status); } && {
13243	 test -z "$ac_c_werror_flag" ||
13244	 test ! -s conftest.err
13245       } && test -s conftest$ac_exeext &&
13246       $as_test_x conftest$ac_exeext; then
13247  cat >>confdefs.h <<\_ACEOF
13248#define HAVE_LIBZ 1
13249_ACEOF
13250
13251else
13252  echo "$as_me: failed program was:" >&5
13253sed 's/^/| /' conftest.$ac_ext >&5
13254
13255
13256				{ { echo "$as_me:$LINENO: error: *** zlib missing - please install first or check config.log ***" >&5
13257echo "$as_me: error: *** zlib missing - please install first or check config.log ***" >&2;}
13258   { (exit 1); exit 1; }; }
13259
13260
13261fi
13262
13263rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13264      conftest$ac_exeext conftest.$ac_ext
13265
13266
13267fi
13268
13269
13270
13271# Check whether --with-zlib-version-check was given.
13272if test "${with_zlib_version_check+set}" = set; then
13273  withval=$with_zlib_version_check;   if test "x$withval" = "xno" ; then
13274		zlib_check_nonfatal=1
13275	   fi
13276
13277
13278fi
13279
13280
13281{ echo "$as_me:$LINENO: checking for possibly buggy zlib" >&5
13282echo $ECHO_N "checking for possibly buggy zlib... $ECHO_C" >&6; }
13283if test "$cross_compiling" = yes; then
13284  	{ echo "$as_me:$LINENO: WARNING: cross compiling: not checking zlib version" >&5
13285echo "$as_me: WARNING: cross compiling: not checking zlib version" >&2;}
13286
13287else
13288  cat >conftest.$ac_ext <<_ACEOF
13289/* confdefs.h.  */
13290_ACEOF
13291cat confdefs.h >>conftest.$ac_ext
13292cat >>conftest.$ac_ext <<_ACEOF
13293/* end confdefs.h.  */
13294
13295#include <stdio.h>
13296#include <stdlib.h>
13297#include <zlib.h>
13298
13299int
13300main ()
13301{
13302
13303	int a=0, b=0, c=0, d=0, n, v;
13304	n = sscanf(ZLIB_VERSION, "%d.%d.%d.%d", &a, &b, &c, &d);
13305	if (n != 3 && n != 4)
13306		exit(1);
13307	v = a*1000000 + b*10000 + c*100 + d;
13308	fprintf(stderr, "found zlib version %s (%d)\n", ZLIB_VERSION, v);
13309
13310	/* 1.1.4 is OK */
13311	if (a == 1 && b == 1 && c >= 4)
13312		exit(0);
13313
13314	/* 1.2.3 and up are OK */
13315	if (v >= 1020300)
13316		exit(0);
13317
13318	exit(2);
13319
13320  ;
13321  return 0;
13322}
13323_ACEOF
13324rm -f conftest$ac_exeext
13325if { (ac_try="$ac_link"
13326case "(($ac_try" in
13327  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13328  *) ac_try_echo=$ac_try;;
13329esac
13330eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13331  (eval "$ac_link") 2>&5
13332  ac_status=$?
13333  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13334  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
13335  { (case "(($ac_try" in
13336  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13337  *) ac_try_echo=$ac_try;;
13338esac
13339eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13340  (eval "$ac_try") 2>&5
13341  ac_status=$?
13342  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13343  (exit $ac_status); }; }; then
13344  { echo "$as_me:$LINENO: result: no" >&5
13345echo "${ECHO_T}no" >&6; }
13346else
13347  echo "$as_me: program exited with status $ac_status" >&5
13348echo "$as_me: failed program was:" >&5
13349sed 's/^/| /' conftest.$ac_ext >&5
13350
13351( exit $ac_status )
13352 { echo "$as_me:$LINENO: result: yes" >&5
13353echo "${ECHO_T}yes" >&6; }
13354	  if test -z "$zlib_check_nonfatal" ; then
13355		{ { echo "$as_me:$LINENO: error: *** zlib too old - check config.log ***
13356Your reported zlib version has known security problems.  It's possible your
13357vendor has fixed these problems without changing the version number.  If you
13358are sure this is the case, you can disable the check by running
13359\"./configure --without-zlib-version-check\".
13360If you are in doubt, upgrade zlib to version 1.2.3 or greater.
13361See http://www.gzip.org/zlib/ for details." >&5
13362echo "$as_me: error: *** zlib too old - check config.log ***
13363Your reported zlib version has known security problems.  It's possible your
13364vendor has fixed these problems without changing the version number.  If you
13365are sure this is the case, you can disable the check by running
13366\"./configure --without-zlib-version-check\".
13367If you are in doubt, upgrade zlib to version 1.2.3 or greater.
13368See http://www.gzip.org/zlib/ for details." >&2;}
13369   { (exit 1); exit 1; }; }
13370	  else
13371		{ echo "$as_me:$LINENO: WARNING: zlib version may have security problems" >&5
13372echo "$as_me: WARNING: zlib version may have security problems" >&2;}
13373	  fi
13374
13375fi
13376rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
13377fi
13378
13379
13380
13381{ echo "$as_me:$LINENO: checking for strcasecmp" >&5
13382echo $ECHO_N "checking for strcasecmp... $ECHO_C" >&6; }
13383if test "${ac_cv_func_strcasecmp+set}" = set; then
13384  echo $ECHO_N "(cached) $ECHO_C" >&6
13385else
13386  cat >conftest.$ac_ext <<_ACEOF
13387/* confdefs.h.  */
13388_ACEOF
13389cat confdefs.h >>conftest.$ac_ext
13390cat >>conftest.$ac_ext <<_ACEOF
13391/* end confdefs.h.  */
13392/* Define strcasecmp to an innocuous variant, in case <limits.h> declares strcasecmp.
13393   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
13394#define strcasecmp innocuous_strcasecmp
13395
13396/* System header to define __stub macros and hopefully few prototypes,
13397    which can conflict with char strcasecmp (); below.
13398    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13399    <limits.h> exists even on freestanding compilers.  */
13400
13401#ifdef __STDC__
13402# include <limits.h>
13403#else
13404# include <assert.h>
13405#endif
13406
13407#undef strcasecmp
13408
13409/* Override any GCC internal prototype to avoid an error.
13410   Use char because int might match the return type of a GCC
13411   builtin and then its argument prototype would still apply.  */
13412#ifdef __cplusplus
13413extern "C"
13414#endif
13415char strcasecmp ();
13416/* The GNU C library defines this for functions which it implements
13417    to always fail with ENOSYS.  Some functions are actually named
13418    something starting with __ and the normal name is an alias.  */
13419#if defined __stub_strcasecmp || defined __stub___strcasecmp
13420choke me
13421#endif
13422
13423int
13424main ()
13425{
13426return strcasecmp ();
13427  ;
13428  return 0;
13429}
13430_ACEOF
13431rm -f conftest.$ac_objext conftest$ac_exeext
13432if { (ac_try="$ac_link"
13433case "(($ac_try" in
13434  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13435  *) ac_try_echo=$ac_try;;
13436esac
13437eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13438  (eval "$ac_link") 2>conftest.er1
13439  ac_status=$?
13440  grep -v '^ *+' conftest.er1 >conftest.err
13441  rm -f conftest.er1
13442  cat conftest.err >&5
13443  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13444  (exit $ac_status); } && {
13445	 test -z "$ac_c_werror_flag" ||
13446	 test ! -s conftest.err
13447       } && test -s conftest$ac_exeext &&
13448       $as_test_x conftest$ac_exeext; then
13449  ac_cv_func_strcasecmp=yes
13450else
13451  echo "$as_me: failed program was:" >&5
13452sed 's/^/| /' conftest.$ac_ext >&5
13453
13454	ac_cv_func_strcasecmp=no
13455fi
13456
13457rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13458      conftest$ac_exeext conftest.$ac_ext
13459fi
13460{ echo "$as_me:$LINENO: result: $ac_cv_func_strcasecmp" >&5
13461echo "${ECHO_T}$ac_cv_func_strcasecmp" >&6; }
13462if test $ac_cv_func_strcasecmp = yes; then
13463  :
13464else
13465   { echo "$as_me:$LINENO: checking for strcasecmp in -lresolv" >&5
13466echo $ECHO_N "checking for strcasecmp in -lresolv... $ECHO_C" >&6; }
13467if test "${ac_cv_lib_resolv_strcasecmp+set}" = set; then
13468  echo $ECHO_N "(cached) $ECHO_C" >&6
13469else
13470  ac_check_lib_save_LIBS=$LIBS
13471LIBS="-lresolv  $LIBS"
13472cat >conftest.$ac_ext <<_ACEOF
13473/* confdefs.h.  */
13474_ACEOF
13475cat confdefs.h >>conftest.$ac_ext
13476cat >>conftest.$ac_ext <<_ACEOF
13477/* end confdefs.h.  */
13478
13479/* Override any GCC internal prototype to avoid an error.
13480   Use char because int might match the return type of a GCC
13481   builtin and then its argument prototype would still apply.  */
13482#ifdef __cplusplus
13483extern "C"
13484#endif
13485char strcasecmp ();
13486int
13487main ()
13488{
13489return strcasecmp ();
13490  ;
13491  return 0;
13492}
13493_ACEOF
13494rm -f conftest.$ac_objext conftest$ac_exeext
13495if { (ac_try="$ac_link"
13496case "(($ac_try" in
13497  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13498  *) ac_try_echo=$ac_try;;
13499esac
13500eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13501  (eval "$ac_link") 2>conftest.er1
13502  ac_status=$?
13503  grep -v '^ *+' conftest.er1 >conftest.err
13504  rm -f conftest.er1
13505  cat conftest.err >&5
13506  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13507  (exit $ac_status); } && {
13508	 test -z "$ac_c_werror_flag" ||
13509	 test ! -s conftest.err
13510       } && test -s conftest$ac_exeext &&
13511       $as_test_x conftest$ac_exeext; then
13512  ac_cv_lib_resolv_strcasecmp=yes
13513else
13514  echo "$as_me: failed program was:" >&5
13515sed 's/^/| /' conftest.$ac_ext >&5
13516
13517	ac_cv_lib_resolv_strcasecmp=no
13518fi
13519
13520rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13521      conftest$ac_exeext conftest.$ac_ext
13522LIBS=$ac_check_lib_save_LIBS
13523fi
13524{ echo "$as_me:$LINENO: result: $ac_cv_lib_resolv_strcasecmp" >&5
13525echo "${ECHO_T}$ac_cv_lib_resolv_strcasecmp" >&6; }
13526if test $ac_cv_lib_resolv_strcasecmp = yes; then
13527  LIBS="$LIBS -lresolv"
13528fi
13529
13530
13531fi
13532
13533
13534for ac_func in utimes
13535do
13536as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
13537{ echo "$as_me:$LINENO: checking for $ac_func" >&5
13538echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
13539if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
13540  echo $ECHO_N "(cached) $ECHO_C" >&6
13541else
13542  cat >conftest.$ac_ext <<_ACEOF
13543/* confdefs.h.  */
13544_ACEOF
13545cat confdefs.h >>conftest.$ac_ext
13546cat >>conftest.$ac_ext <<_ACEOF
13547/* end confdefs.h.  */
13548/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
13549   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
13550#define $ac_func innocuous_$ac_func
13551
13552/* System header to define __stub macros and hopefully few prototypes,
13553    which can conflict with char $ac_func (); below.
13554    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
13555    <limits.h> exists even on freestanding compilers.  */
13556
13557#ifdef __STDC__
13558# include <limits.h>
13559#else
13560# include <assert.h>
13561#endif
13562
13563#undef $ac_func
13564
13565/* Override any GCC internal prototype to avoid an error.
13566   Use char because int might match the return type of a GCC
13567   builtin and then its argument prototype would still apply.  */
13568#ifdef __cplusplus
13569extern "C"
13570#endif
13571char $ac_func ();
13572/* The GNU C library defines this for functions which it implements
13573    to always fail with ENOSYS.  Some functions are actually named
13574    something starting with __ and the normal name is an alias.  */
13575#if defined __stub_$ac_func || defined __stub___$ac_func
13576choke me
13577#endif
13578
13579int
13580main ()
13581{
13582return $ac_func ();
13583  ;
13584  return 0;
13585}
13586_ACEOF
13587rm -f conftest.$ac_objext conftest$ac_exeext
13588if { (ac_try="$ac_link"
13589case "(($ac_try" in
13590  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13591  *) ac_try_echo=$ac_try;;
13592esac
13593eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13594  (eval "$ac_link") 2>conftest.er1
13595  ac_status=$?
13596  grep -v '^ *+' conftest.er1 >conftest.err
13597  rm -f conftest.er1
13598  cat conftest.err >&5
13599  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13600  (exit $ac_status); } && {
13601	 test -z "$ac_c_werror_flag" ||
13602	 test ! -s conftest.err
13603       } && test -s conftest$ac_exeext &&
13604       $as_test_x conftest$ac_exeext; then
13605  eval "$as_ac_var=yes"
13606else
13607  echo "$as_me: failed program was:" >&5
13608sed 's/^/| /' conftest.$ac_ext >&5
13609
13610	eval "$as_ac_var=no"
13611fi
13612
13613rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13614      conftest$ac_exeext conftest.$ac_ext
13615fi
13616ac_res=`eval echo '${'$as_ac_var'}'`
13617	       { echo "$as_me:$LINENO: result: $ac_res" >&5
13618echo "${ECHO_T}$ac_res" >&6; }
13619if test `eval echo '${'$as_ac_var'}'` = yes; then
13620  cat >>confdefs.h <<_ACEOF
13621#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
13622_ACEOF
13623
13624else
13625   { echo "$as_me:$LINENO: checking for utimes in -lc89" >&5
13626echo $ECHO_N "checking for utimes in -lc89... $ECHO_C" >&6; }
13627if test "${ac_cv_lib_c89_utimes+set}" = set; then
13628  echo $ECHO_N "(cached) $ECHO_C" >&6
13629else
13630  ac_check_lib_save_LIBS=$LIBS
13631LIBS="-lc89  $LIBS"
13632cat >conftest.$ac_ext <<_ACEOF
13633/* confdefs.h.  */
13634_ACEOF
13635cat confdefs.h >>conftest.$ac_ext
13636cat >>conftest.$ac_ext <<_ACEOF
13637/* end confdefs.h.  */
13638
13639/* Override any GCC internal prototype to avoid an error.
13640   Use char because int might match the return type of a GCC
13641   builtin and then its argument prototype would still apply.  */
13642#ifdef __cplusplus
13643extern "C"
13644#endif
13645char utimes ();
13646int
13647main ()
13648{
13649return utimes ();
13650  ;
13651  return 0;
13652}
13653_ACEOF
13654rm -f conftest.$ac_objext conftest$ac_exeext
13655if { (ac_try="$ac_link"
13656case "(($ac_try" in
13657  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13658  *) ac_try_echo=$ac_try;;
13659esac
13660eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13661  (eval "$ac_link") 2>conftest.er1
13662  ac_status=$?
13663  grep -v '^ *+' conftest.er1 >conftest.err
13664  rm -f conftest.er1
13665  cat conftest.err >&5
13666  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13667  (exit $ac_status); } && {
13668	 test -z "$ac_c_werror_flag" ||
13669	 test ! -s conftest.err
13670       } && test -s conftest$ac_exeext &&
13671       $as_test_x conftest$ac_exeext; then
13672  ac_cv_lib_c89_utimes=yes
13673else
13674  echo "$as_me: failed program was:" >&5
13675sed 's/^/| /' conftest.$ac_ext >&5
13676
13677	ac_cv_lib_c89_utimes=no
13678fi
13679
13680rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13681      conftest$ac_exeext conftest.$ac_ext
13682LIBS=$ac_check_lib_save_LIBS
13683fi
13684{ echo "$as_me:$LINENO: result: $ac_cv_lib_c89_utimes" >&5
13685echo "${ECHO_T}$ac_cv_lib_c89_utimes" >&6; }
13686if test $ac_cv_lib_c89_utimes = yes; then
13687  cat >>confdefs.h <<\_ACEOF
13688#define HAVE_UTIMES 1
13689_ACEOF
13690
13691					LIBS="$LIBS -lc89"
13692fi
13693
13694
13695fi
13696done
13697
13698
13699
13700
13701for ac_header in bsd/libutil.h libutil.h
13702do
13703as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
13704if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13705  { echo "$as_me:$LINENO: checking for $ac_header" >&5
13706echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
13707if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13708  echo $ECHO_N "(cached) $ECHO_C" >&6
13709fi
13710ac_res=`eval echo '${'$as_ac_Header'}'`
13711	       { echo "$as_me:$LINENO: result: $ac_res" >&5
13712echo "${ECHO_T}$ac_res" >&6; }
13713else
13714  # Is the header compilable?
13715{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
13716echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
13717cat >conftest.$ac_ext <<_ACEOF
13718/* confdefs.h.  */
13719_ACEOF
13720cat confdefs.h >>conftest.$ac_ext
13721cat >>conftest.$ac_ext <<_ACEOF
13722/* end confdefs.h.  */
13723$ac_includes_default
13724#include <$ac_header>
13725_ACEOF
13726rm -f conftest.$ac_objext
13727if { (ac_try="$ac_compile"
13728case "(($ac_try" in
13729  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13730  *) ac_try_echo=$ac_try;;
13731esac
13732eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13733  (eval "$ac_compile") 2>conftest.er1
13734  ac_status=$?
13735  grep -v '^ *+' conftest.er1 >conftest.err
13736  rm -f conftest.er1
13737  cat conftest.err >&5
13738  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13739  (exit $ac_status); } && {
13740	 test -z "$ac_c_werror_flag" ||
13741	 test ! -s conftest.err
13742       } && test -s conftest.$ac_objext; then
13743  ac_header_compiler=yes
13744else
13745  echo "$as_me: failed program was:" >&5
13746sed 's/^/| /' conftest.$ac_ext >&5
13747
13748	ac_header_compiler=no
13749fi
13750
13751rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13752{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13753echo "${ECHO_T}$ac_header_compiler" >&6; }
13754
13755# Is the header present?
13756{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
13757echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
13758cat >conftest.$ac_ext <<_ACEOF
13759/* confdefs.h.  */
13760_ACEOF
13761cat confdefs.h >>conftest.$ac_ext
13762cat >>conftest.$ac_ext <<_ACEOF
13763/* end confdefs.h.  */
13764#include <$ac_header>
13765_ACEOF
13766if { (ac_try="$ac_cpp conftest.$ac_ext"
13767case "(($ac_try" in
13768  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13769  *) ac_try_echo=$ac_try;;
13770esac
13771eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13772  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13773  ac_status=$?
13774  grep -v '^ *+' conftest.er1 >conftest.err
13775  rm -f conftest.er1
13776  cat conftest.err >&5
13777  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13778  (exit $ac_status); } >/dev/null && {
13779	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13780	 test ! -s conftest.err
13781       }; then
13782  ac_header_preproc=yes
13783else
13784  echo "$as_me: failed program was:" >&5
13785sed 's/^/| /' conftest.$ac_ext >&5
13786
13787  ac_header_preproc=no
13788fi
13789
13790rm -f conftest.err conftest.$ac_ext
13791{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13792echo "${ECHO_T}$ac_header_preproc" >&6; }
13793
13794# So?  What about this header?
13795case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13796  yes:no: )
13797    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13798echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13799    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13800echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13801    ac_header_preproc=yes
13802    ;;
13803  no:yes:* )
13804    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13805echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13806    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13807echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13808    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13809echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13810    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13811echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13812    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13813echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13814    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13815echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13816    ( cat <<\_ASBOX
13817## ------------------------------------------- ##
13818## Report this to openssh-unix-dev@mindrot.org ##
13819## ------------------------------------------- ##
13820_ASBOX
13821     ) | sed "s/^/$as_me: WARNING:     /" >&2
13822    ;;
13823esac
13824{ echo "$as_me:$LINENO: checking for $ac_header" >&5
13825echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
13826if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13827  echo $ECHO_N "(cached) $ECHO_C" >&6
13828else
13829  eval "$as_ac_Header=\$ac_header_preproc"
13830fi
13831ac_res=`eval echo '${'$as_ac_Header'}'`
13832	       { echo "$as_me:$LINENO: result: $ac_res" >&5
13833echo "${ECHO_T}$ac_res" >&6; }
13834
13835fi
13836if test `eval echo '${'$as_ac_Header'}'` = yes; then
13837  cat >>confdefs.h <<_ACEOF
13838#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
13839_ACEOF
13840
13841fi
13842
13843done
13844
13845{ echo "$as_me:$LINENO: checking for library containing fmt_scaled" >&5
13846echo $ECHO_N "checking for library containing fmt_scaled... $ECHO_C" >&6; }
13847if test "${ac_cv_search_fmt_scaled+set}" = set; then
13848  echo $ECHO_N "(cached) $ECHO_C" >&6
13849else
13850  ac_func_search_save_LIBS=$LIBS
13851cat >conftest.$ac_ext <<_ACEOF
13852/* confdefs.h.  */
13853_ACEOF
13854cat confdefs.h >>conftest.$ac_ext
13855cat >>conftest.$ac_ext <<_ACEOF
13856/* end confdefs.h.  */
13857
13858/* Override any GCC internal prototype to avoid an error.
13859   Use char because int might match the return type of a GCC
13860   builtin and then its argument prototype would still apply.  */
13861#ifdef __cplusplus
13862extern "C"
13863#endif
13864char fmt_scaled ();
13865int
13866main ()
13867{
13868return fmt_scaled ();
13869  ;
13870  return 0;
13871}
13872_ACEOF
13873for ac_lib in '' util bsd; do
13874  if test -z "$ac_lib"; then
13875    ac_res="none required"
13876  else
13877    ac_res=-l$ac_lib
13878    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
13879  fi
13880  rm -f conftest.$ac_objext conftest$ac_exeext
13881if { (ac_try="$ac_link"
13882case "(($ac_try" in
13883  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13884  *) ac_try_echo=$ac_try;;
13885esac
13886eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13887  (eval "$ac_link") 2>conftest.er1
13888  ac_status=$?
13889  grep -v '^ *+' conftest.er1 >conftest.err
13890  rm -f conftest.er1
13891  cat conftest.err >&5
13892  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13893  (exit $ac_status); } && {
13894	 test -z "$ac_c_werror_flag" ||
13895	 test ! -s conftest.err
13896       } && test -s conftest$ac_exeext &&
13897       $as_test_x conftest$ac_exeext; then
13898  ac_cv_search_fmt_scaled=$ac_res
13899else
13900  echo "$as_me: failed program was:" >&5
13901sed 's/^/| /' conftest.$ac_ext >&5
13902
13903
13904fi
13905
13906rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13907      conftest$ac_exeext
13908  if test "${ac_cv_search_fmt_scaled+set}" = set; then
13909  break
13910fi
13911done
13912if test "${ac_cv_search_fmt_scaled+set}" = set; then
13913  :
13914else
13915  ac_cv_search_fmt_scaled=no
13916fi
13917rm conftest.$ac_ext
13918LIBS=$ac_func_search_save_LIBS
13919fi
13920{ echo "$as_me:$LINENO: result: $ac_cv_search_fmt_scaled" >&5
13921echo "${ECHO_T}$ac_cv_search_fmt_scaled" >&6; }
13922ac_res=$ac_cv_search_fmt_scaled
13923if test "$ac_res" != no; then
13924  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
13925
13926fi
13927
13928{ echo "$as_me:$LINENO: checking for library containing scan_scaled" >&5
13929echo $ECHO_N "checking for library containing scan_scaled... $ECHO_C" >&6; }
13930if test "${ac_cv_search_scan_scaled+set}" = set; then
13931  echo $ECHO_N "(cached) $ECHO_C" >&6
13932else
13933  ac_func_search_save_LIBS=$LIBS
13934cat >conftest.$ac_ext <<_ACEOF
13935/* confdefs.h.  */
13936_ACEOF
13937cat confdefs.h >>conftest.$ac_ext
13938cat >>conftest.$ac_ext <<_ACEOF
13939/* end confdefs.h.  */
13940
13941/* Override any GCC internal prototype to avoid an error.
13942   Use char because int might match the return type of a GCC
13943   builtin and then its argument prototype would still apply.  */
13944#ifdef __cplusplus
13945extern "C"
13946#endif
13947char scan_scaled ();
13948int
13949main ()
13950{
13951return scan_scaled ();
13952  ;
13953  return 0;
13954}
13955_ACEOF
13956for ac_lib in '' util bsd; do
13957  if test -z "$ac_lib"; then
13958    ac_res="none required"
13959  else
13960    ac_res=-l$ac_lib
13961    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
13962  fi
13963  rm -f conftest.$ac_objext conftest$ac_exeext
13964if { (ac_try="$ac_link"
13965case "(($ac_try" in
13966  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13967  *) ac_try_echo=$ac_try;;
13968esac
13969eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
13970  (eval "$ac_link") 2>conftest.er1
13971  ac_status=$?
13972  grep -v '^ *+' conftest.er1 >conftest.err
13973  rm -f conftest.er1
13974  cat conftest.err >&5
13975  echo "$as_me:$LINENO: \$? = $ac_status" >&5
13976  (exit $ac_status); } && {
13977	 test -z "$ac_c_werror_flag" ||
13978	 test ! -s conftest.err
13979       } && test -s conftest$ac_exeext &&
13980       $as_test_x conftest$ac_exeext; then
13981  ac_cv_search_scan_scaled=$ac_res
13982else
13983  echo "$as_me: failed program was:" >&5
13984sed 's/^/| /' conftest.$ac_ext >&5
13985
13986
13987fi
13988
13989rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
13990      conftest$ac_exeext
13991  if test "${ac_cv_search_scan_scaled+set}" = set; then
13992  break
13993fi
13994done
13995if test "${ac_cv_search_scan_scaled+set}" = set; then
13996  :
13997else
13998  ac_cv_search_scan_scaled=no
13999fi
14000rm conftest.$ac_ext
14001LIBS=$ac_func_search_save_LIBS
14002fi
14003{ echo "$as_me:$LINENO: result: $ac_cv_search_scan_scaled" >&5
14004echo "${ECHO_T}$ac_cv_search_scan_scaled" >&6; }
14005ac_res=$ac_cv_search_scan_scaled
14006if test "$ac_res" != no; then
14007  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14008
14009fi
14010
14011{ echo "$as_me:$LINENO: checking for library containing login" >&5
14012echo $ECHO_N "checking for library containing login... $ECHO_C" >&6; }
14013if test "${ac_cv_search_login+set}" = set; then
14014  echo $ECHO_N "(cached) $ECHO_C" >&6
14015else
14016  ac_func_search_save_LIBS=$LIBS
14017cat >conftest.$ac_ext <<_ACEOF
14018/* confdefs.h.  */
14019_ACEOF
14020cat confdefs.h >>conftest.$ac_ext
14021cat >>conftest.$ac_ext <<_ACEOF
14022/* end confdefs.h.  */
14023
14024/* Override any GCC internal prototype to avoid an error.
14025   Use char because int might match the return type of a GCC
14026   builtin and then its argument prototype would still apply.  */
14027#ifdef __cplusplus
14028extern "C"
14029#endif
14030char login ();
14031int
14032main ()
14033{
14034return login ();
14035  ;
14036  return 0;
14037}
14038_ACEOF
14039for ac_lib in '' util bsd; do
14040  if test -z "$ac_lib"; then
14041    ac_res="none required"
14042  else
14043    ac_res=-l$ac_lib
14044    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14045  fi
14046  rm -f conftest.$ac_objext conftest$ac_exeext
14047if { (ac_try="$ac_link"
14048case "(($ac_try" in
14049  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14050  *) ac_try_echo=$ac_try;;
14051esac
14052eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14053  (eval "$ac_link") 2>conftest.er1
14054  ac_status=$?
14055  grep -v '^ *+' conftest.er1 >conftest.err
14056  rm -f conftest.er1
14057  cat conftest.err >&5
14058  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14059  (exit $ac_status); } && {
14060	 test -z "$ac_c_werror_flag" ||
14061	 test ! -s conftest.err
14062       } && test -s conftest$ac_exeext &&
14063       $as_test_x conftest$ac_exeext; then
14064  ac_cv_search_login=$ac_res
14065else
14066  echo "$as_me: failed program was:" >&5
14067sed 's/^/| /' conftest.$ac_ext >&5
14068
14069
14070fi
14071
14072rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14073      conftest$ac_exeext
14074  if test "${ac_cv_search_login+set}" = set; then
14075  break
14076fi
14077done
14078if test "${ac_cv_search_login+set}" = set; then
14079  :
14080else
14081  ac_cv_search_login=no
14082fi
14083rm conftest.$ac_ext
14084LIBS=$ac_func_search_save_LIBS
14085fi
14086{ echo "$as_me:$LINENO: result: $ac_cv_search_login" >&5
14087echo "${ECHO_T}$ac_cv_search_login" >&6; }
14088ac_res=$ac_cv_search_login
14089if test "$ac_res" != no; then
14090  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14091
14092fi
14093
14094{ echo "$as_me:$LINENO: checking for library containing logout" >&5
14095echo $ECHO_N "checking for library containing logout... $ECHO_C" >&6; }
14096if test "${ac_cv_search_logout+set}" = set; then
14097  echo $ECHO_N "(cached) $ECHO_C" >&6
14098else
14099  ac_func_search_save_LIBS=$LIBS
14100cat >conftest.$ac_ext <<_ACEOF
14101/* confdefs.h.  */
14102_ACEOF
14103cat confdefs.h >>conftest.$ac_ext
14104cat >>conftest.$ac_ext <<_ACEOF
14105/* end confdefs.h.  */
14106
14107/* Override any GCC internal prototype to avoid an error.
14108   Use char because int might match the return type of a GCC
14109   builtin and then its argument prototype would still apply.  */
14110#ifdef __cplusplus
14111extern "C"
14112#endif
14113char logout ();
14114int
14115main ()
14116{
14117return logout ();
14118  ;
14119  return 0;
14120}
14121_ACEOF
14122for ac_lib in '' util bsd; do
14123  if test -z "$ac_lib"; then
14124    ac_res="none required"
14125  else
14126    ac_res=-l$ac_lib
14127    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14128  fi
14129  rm -f conftest.$ac_objext conftest$ac_exeext
14130if { (ac_try="$ac_link"
14131case "(($ac_try" in
14132  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14133  *) ac_try_echo=$ac_try;;
14134esac
14135eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14136  (eval "$ac_link") 2>conftest.er1
14137  ac_status=$?
14138  grep -v '^ *+' conftest.er1 >conftest.err
14139  rm -f conftest.er1
14140  cat conftest.err >&5
14141  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14142  (exit $ac_status); } && {
14143	 test -z "$ac_c_werror_flag" ||
14144	 test ! -s conftest.err
14145       } && test -s conftest$ac_exeext &&
14146       $as_test_x conftest$ac_exeext; then
14147  ac_cv_search_logout=$ac_res
14148else
14149  echo "$as_me: failed program was:" >&5
14150sed 's/^/| /' conftest.$ac_ext >&5
14151
14152
14153fi
14154
14155rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14156      conftest$ac_exeext
14157  if test "${ac_cv_search_logout+set}" = set; then
14158  break
14159fi
14160done
14161if test "${ac_cv_search_logout+set}" = set; then
14162  :
14163else
14164  ac_cv_search_logout=no
14165fi
14166rm conftest.$ac_ext
14167LIBS=$ac_func_search_save_LIBS
14168fi
14169{ echo "$as_me:$LINENO: result: $ac_cv_search_logout" >&5
14170echo "${ECHO_T}$ac_cv_search_logout" >&6; }
14171ac_res=$ac_cv_search_logout
14172if test "$ac_res" != no; then
14173  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14174
14175fi
14176
14177{ echo "$as_me:$LINENO: checking for library containing logwtmp" >&5
14178echo $ECHO_N "checking for library containing logwtmp... $ECHO_C" >&6; }
14179if test "${ac_cv_search_logwtmp+set}" = set; then
14180  echo $ECHO_N "(cached) $ECHO_C" >&6
14181else
14182  ac_func_search_save_LIBS=$LIBS
14183cat >conftest.$ac_ext <<_ACEOF
14184/* confdefs.h.  */
14185_ACEOF
14186cat confdefs.h >>conftest.$ac_ext
14187cat >>conftest.$ac_ext <<_ACEOF
14188/* end confdefs.h.  */
14189
14190/* Override any GCC internal prototype to avoid an error.
14191   Use char because int might match the return type of a GCC
14192   builtin and then its argument prototype would still apply.  */
14193#ifdef __cplusplus
14194extern "C"
14195#endif
14196char logwtmp ();
14197int
14198main ()
14199{
14200return logwtmp ();
14201  ;
14202  return 0;
14203}
14204_ACEOF
14205for ac_lib in '' util bsd; do
14206  if test -z "$ac_lib"; then
14207    ac_res="none required"
14208  else
14209    ac_res=-l$ac_lib
14210    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14211  fi
14212  rm -f conftest.$ac_objext conftest$ac_exeext
14213if { (ac_try="$ac_link"
14214case "(($ac_try" in
14215  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14216  *) ac_try_echo=$ac_try;;
14217esac
14218eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14219  (eval "$ac_link") 2>conftest.er1
14220  ac_status=$?
14221  grep -v '^ *+' conftest.er1 >conftest.err
14222  rm -f conftest.er1
14223  cat conftest.err >&5
14224  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14225  (exit $ac_status); } && {
14226	 test -z "$ac_c_werror_flag" ||
14227	 test ! -s conftest.err
14228       } && test -s conftest$ac_exeext &&
14229       $as_test_x conftest$ac_exeext; then
14230  ac_cv_search_logwtmp=$ac_res
14231else
14232  echo "$as_me: failed program was:" >&5
14233sed 's/^/| /' conftest.$ac_ext >&5
14234
14235
14236fi
14237
14238rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14239      conftest$ac_exeext
14240  if test "${ac_cv_search_logwtmp+set}" = set; then
14241  break
14242fi
14243done
14244if test "${ac_cv_search_logwtmp+set}" = set; then
14245  :
14246else
14247  ac_cv_search_logwtmp=no
14248fi
14249rm conftest.$ac_ext
14250LIBS=$ac_func_search_save_LIBS
14251fi
14252{ echo "$as_me:$LINENO: result: $ac_cv_search_logwtmp" >&5
14253echo "${ECHO_T}$ac_cv_search_logwtmp" >&6; }
14254ac_res=$ac_cv_search_logwtmp
14255if test "$ac_res" != no; then
14256  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14257
14258fi
14259
14260{ echo "$as_me:$LINENO: checking for library containing openpty" >&5
14261echo $ECHO_N "checking for library containing openpty... $ECHO_C" >&6; }
14262if test "${ac_cv_search_openpty+set}" = set; then
14263  echo $ECHO_N "(cached) $ECHO_C" >&6
14264else
14265  ac_func_search_save_LIBS=$LIBS
14266cat >conftest.$ac_ext <<_ACEOF
14267/* confdefs.h.  */
14268_ACEOF
14269cat confdefs.h >>conftest.$ac_ext
14270cat >>conftest.$ac_ext <<_ACEOF
14271/* end confdefs.h.  */
14272
14273/* Override any GCC internal prototype to avoid an error.
14274   Use char because int might match the return type of a GCC
14275   builtin and then its argument prototype would still apply.  */
14276#ifdef __cplusplus
14277extern "C"
14278#endif
14279char openpty ();
14280int
14281main ()
14282{
14283return openpty ();
14284  ;
14285  return 0;
14286}
14287_ACEOF
14288for ac_lib in '' util bsd; do
14289  if test -z "$ac_lib"; then
14290    ac_res="none required"
14291  else
14292    ac_res=-l$ac_lib
14293    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14294  fi
14295  rm -f conftest.$ac_objext conftest$ac_exeext
14296if { (ac_try="$ac_link"
14297case "(($ac_try" in
14298  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14299  *) ac_try_echo=$ac_try;;
14300esac
14301eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14302  (eval "$ac_link") 2>conftest.er1
14303  ac_status=$?
14304  grep -v '^ *+' conftest.er1 >conftest.err
14305  rm -f conftest.er1
14306  cat conftest.err >&5
14307  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14308  (exit $ac_status); } && {
14309	 test -z "$ac_c_werror_flag" ||
14310	 test ! -s conftest.err
14311       } && test -s conftest$ac_exeext &&
14312       $as_test_x conftest$ac_exeext; then
14313  ac_cv_search_openpty=$ac_res
14314else
14315  echo "$as_me: failed program was:" >&5
14316sed 's/^/| /' conftest.$ac_ext >&5
14317
14318
14319fi
14320
14321rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14322      conftest$ac_exeext
14323  if test "${ac_cv_search_openpty+set}" = set; then
14324  break
14325fi
14326done
14327if test "${ac_cv_search_openpty+set}" = set; then
14328  :
14329else
14330  ac_cv_search_openpty=no
14331fi
14332rm conftest.$ac_ext
14333LIBS=$ac_func_search_save_LIBS
14334fi
14335{ echo "$as_me:$LINENO: result: $ac_cv_search_openpty" >&5
14336echo "${ECHO_T}$ac_cv_search_openpty" >&6; }
14337ac_res=$ac_cv_search_openpty
14338if test "$ac_res" != no; then
14339  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14340
14341fi
14342
14343{ echo "$as_me:$LINENO: checking for library containing updwtmp" >&5
14344echo $ECHO_N "checking for library containing updwtmp... $ECHO_C" >&6; }
14345if test "${ac_cv_search_updwtmp+set}" = set; then
14346  echo $ECHO_N "(cached) $ECHO_C" >&6
14347else
14348  ac_func_search_save_LIBS=$LIBS
14349cat >conftest.$ac_ext <<_ACEOF
14350/* confdefs.h.  */
14351_ACEOF
14352cat confdefs.h >>conftest.$ac_ext
14353cat >>conftest.$ac_ext <<_ACEOF
14354/* end confdefs.h.  */
14355
14356/* Override any GCC internal prototype to avoid an error.
14357   Use char because int might match the return type of a GCC
14358   builtin and then its argument prototype would still apply.  */
14359#ifdef __cplusplus
14360extern "C"
14361#endif
14362char updwtmp ();
14363int
14364main ()
14365{
14366return updwtmp ();
14367  ;
14368  return 0;
14369}
14370_ACEOF
14371for ac_lib in '' util bsd; do
14372  if test -z "$ac_lib"; then
14373    ac_res="none required"
14374  else
14375    ac_res=-l$ac_lib
14376    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14377  fi
14378  rm -f conftest.$ac_objext conftest$ac_exeext
14379if { (ac_try="$ac_link"
14380case "(($ac_try" in
14381  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14382  *) ac_try_echo=$ac_try;;
14383esac
14384eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14385  (eval "$ac_link") 2>conftest.er1
14386  ac_status=$?
14387  grep -v '^ *+' conftest.er1 >conftest.err
14388  rm -f conftest.er1
14389  cat conftest.err >&5
14390  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14391  (exit $ac_status); } && {
14392	 test -z "$ac_c_werror_flag" ||
14393	 test ! -s conftest.err
14394       } && test -s conftest$ac_exeext &&
14395       $as_test_x conftest$ac_exeext; then
14396  ac_cv_search_updwtmp=$ac_res
14397else
14398  echo "$as_me: failed program was:" >&5
14399sed 's/^/| /' conftest.$ac_ext >&5
14400
14401
14402fi
14403
14404rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14405      conftest$ac_exeext
14406  if test "${ac_cv_search_updwtmp+set}" = set; then
14407  break
14408fi
14409done
14410if test "${ac_cv_search_updwtmp+set}" = set; then
14411  :
14412else
14413  ac_cv_search_updwtmp=no
14414fi
14415rm conftest.$ac_ext
14416LIBS=$ac_func_search_save_LIBS
14417fi
14418{ echo "$as_me:$LINENO: result: $ac_cv_search_updwtmp" >&5
14419echo "${ECHO_T}$ac_cv_search_updwtmp" >&6; }
14420ac_res=$ac_cv_search_updwtmp
14421if test "$ac_res" != no; then
14422  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14423
14424fi
14425
14426
14427
14428
14429
14430
14431
14432
14433for ac_func in fmt_scaled scan_scaled login logout openpty updwtmp logwtmp
14434do
14435as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14436{ echo "$as_me:$LINENO: checking for $ac_func" >&5
14437echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
14438if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
14439  echo $ECHO_N "(cached) $ECHO_C" >&6
14440else
14441  cat >conftest.$ac_ext <<_ACEOF
14442/* confdefs.h.  */
14443_ACEOF
14444cat confdefs.h >>conftest.$ac_ext
14445cat >>conftest.$ac_ext <<_ACEOF
14446/* end confdefs.h.  */
14447/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14448   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14449#define $ac_func innocuous_$ac_func
14450
14451/* System header to define __stub macros and hopefully few prototypes,
14452    which can conflict with char $ac_func (); below.
14453    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14454    <limits.h> exists even on freestanding compilers.  */
14455
14456#ifdef __STDC__
14457# include <limits.h>
14458#else
14459# include <assert.h>
14460#endif
14461
14462#undef $ac_func
14463
14464/* Override any GCC internal prototype to avoid an error.
14465   Use char because int might match the return type of a GCC
14466   builtin and then its argument prototype would still apply.  */
14467#ifdef __cplusplus
14468extern "C"
14469#endif
14470char $ac_func ();
14471/* The GNU C library defines this for functions which it implements
14472    to always fail with ENOSYS.  Some functions are actually named
14473    something starting with __ and the normal name is an alias.  */
14474#if defined __stub_$ac_func || defined __stub___$ac_func
14475choke me
14476#endif
14477
14478int
14479main ()
14480{
14481return $ac_func ();
14482  ;
14483  return 0;
14484}
14485_ACEOF
14486rm -f conftest.$ac_objext conftest$ac_exeext
14487if { (ac_try="$ac_link"
14488case "(($ac_try" in
14489  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14490  *) ac_try_echo=$ac_try;;
14491esac
14492eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14493  (eval "$ac_link") 2>conftest.er1
14494  ac_status=$?
14495  grep -v '^ *+' conftest.er1 >conftest.err
14496  rm -f conftest.er1
14497  cat conftest.err >&5
14498  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14499  (exit $ac_status); } && {
14500	 test -z "$ac_c_werror_flag" ||
14501	 test ! -s conftest.err
14502       } && test -s conftest$ac_exeext &&
14503       $as_test_x conftest$ac_exeext; then
14504  eval "$as_ac_var=yes"
14505else
14506  echo "$as_me: failed program was:" >&5
14507sed 's/^/| /' conftest.$ac_ext >&5
14508
14509	eval "$as_ac_var=no"
14510fi
14511
14512rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14513      conftest$ac_exeext conftest.$ac_ext
14514fi
14515ac_res=`eval echo '${'$as_ac_var'}'`
14516	       { echo "$as_me:$LINENO: result: $ac_res" >&5
14517echo "${ECHO_T}$ac_res" >&6; }
14518if test `eval echo '${'$as_ac_var'}'` = yes; then
14519  cat >>confdefs.h <<_ACEOF
14520#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14521_ACEOF
14522
14523fi
14524done
14525
14526
14527# On some platforms, inet_ntop may be found in libresolv or libnsl.
14528{ echo "$as_me:$LINENO: checking for library containing inet_ntop" >&5
14529echo $ECHO_N "checking for library containing inet_ntop... $ECHO_C" >&6; }
14530if test "${ac_cv_search_inet_ntop+set}" = set; then
14531  echo $ECHO_N "(cached) $ECHO_C" >&6
14532else
14533  ac_func_search_save_LIBS=$LIBS
14534cat >conftest.$ac_ext <<_ACEOF
14535/* confdefs.h.  */
14536_ACEOF
14537cat confdefs.h >>conftest.$ac_ext
14538cat >>conftest.$ac_ext <<_ACEOF
14539/* end confdefs.h.  */
14540
14541/* Override any GCC internal prototype to avoid an error.
14542   Use char because int might match the return type of a GCC
14543   builtin and then its argument prototype would still apply.  */
14544#ifdef __cplusplus
14545extern "C"
14546#endif
14547char inet_ntop ();
14548int
14549main ()
14550{
14551return inet_ntop ();
14552  ;
14553  return 0;
14554}
14555_ACEOF
14556for ac_lib in '' resolv nsl; do
14557  if test -z "$ac_lib"; then
14558    ac_res="none required"
14559  else
14560    ac_res=-l$ac_lib
14561    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
14562  fi
14563  rm -f conftest.$ac_objext conftest$ac_exeext
14564if { (ac_try="$ac_link"
14565case "(($ac_try" in
14566  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14567  *) ac_try_echo=$ac_try;;
14568esac
14569eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14570  (eval "$ac_link") 2>conftest.er1
14571  ac_status=$?
14572  grep -v '^ *+' conftest.er1 >conftest.err
14573  rm -f conftest.er1
14574  cat conftest.err >&5
14575  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14576  (exit $ac_status); } && {
14577	 test -z "$ac_c_werror_flag" ||
14578	 test ! -s conftest.err
14579       } && test -s conftest$ac_exeext &&
14580       $as_test_x conftest$ac_exeext; then
14581  ac_cv_search_inet_ntop=$ac_res
14582else
14583  echo "$as_me: failed program was:" >&5
14584sed 's/^/| /' conftest.$ac_ext >&5
14585
14586
14587fi
14588
14589rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14590      conftest$ac_exeext
14591  if test "${ac_cv_search_inet_ntop+set}" = set; then
14592  break
14593fi
14594done
14595if test "${ac_cv_search_inet_ntop+set}" = set; then
14596  :
14597else
14598  ac_cv_search_inet_ntop=no
14599fi
14600rm conftest.$ac_ext
14601LIBS=$ac_func_search_save_LIBS
14602fi
14603{ echo "$as_me:$LINENO: result: $ac_cv_search_inet_ntop" >&5
14604echo "${ECHO_T}$ac_cv_search_inet_ntop" >&6; }
14605ac_res=$ac_cv_search_inet_ntop
14606if test "$ac_res" != no; then
14607  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
14608
14609fi
14610
14611
14612
14613for ac_func in strftime
14614do
14615as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
14616{ echo "$as_me:$LINENO: checking for $ac_func" >&5
14617echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
14618if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
14619  echo $ECHO_N "(cached) $ECHO_C" >&6
14620else
14621  cat >conftest.$ac_ext <<_ACEOF
14622/* confdefs.h.  */
14623_ACEOF
14624cat confdefs.h >>conftest.$ac_ext
14625cat >>conftest.$ac_ext <<_ACEOF
14626/* end confdefs.h.  */
14627/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
14628   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
14629#define $ac_func innocuous_$ac_func
14630
14631/* System header to define __stub macros and hopefully few prototypes,
14632    which can conflict with char $ac_func (); below.
14633    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
14634    <limits.h> exists even on freestanding compilers.  */
14635
14636#ifdef __STDC__
14637# include <limits.h>
14638#else
14639# include <assert.h>
14640#endif
14641
14642#undef $ac_func
14643
14644/* Override any GCC internal prototype to avoid an error.
14645   Use char because int might match the return type of a GCC
14646   builtin and then its argument prototype would still apply.  */
14647#ifdef __cplusplus
14648extern "C"
14649#endif
14650char $ac_func ();
14651/* The GNU C library defines this for functions which it implements
14652    to always fail with ENOSYS.  Some functions are actually named
14653    something starting with __ and the normal name is an alias.  */
14654#if defined __stub_$ac_func || defined __stub___$ac_func
14655choke me
14656#endif
14657
14658int
14659main ()
14660{
14661return $ac_func ();
14662  ;
14663  return 0;
14664}
14665_ACEOF
14666rm -f conftest.$ac_objext conftest$ac_exeext
14667if { (ac_try="$ac_link"
14668case "(($ac_try" in
14669  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14670  *) ac_try_echo=$ac_try;;
14671esac
14672eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14673  (eval "$ac_link") 2>conftest.er1
14674  ac_status=$?
14675  grep -v '^ *+' conftest.er1 >conftest.err
14676  rm -f conftest.er1
14677  cat conftest.err >&5
14678  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14679  (exit $ac_status); } && {
14680	 test -z "$ac_c_werror_flag" ||
14681	 test ! -s conftest.err
14682       } && test -s conftest$ac_exeext &&
14683       $as_test_x conftest$ac_exeext; then
14684  eval "$as_ac_var=yes"
14685else
14686  echo "$as_me: failed program was:" >&5
14687sed 's/^/| /' conftest.$ac_ext >&5
14688
14689	eval "$as_ac_var=no"
14690fi
14691
14692rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14693      conftest$ac_exeext conftest.$ac_ext
14694fi
14695ac_res=`eval echo '${'$as_ac_var'}'`
14696	       { echo "$as_me:$LINENO: result: $ac_res" >&5
14697echo "${ECHO_T}$ac_res" >&6; }
14698if test `eval echo '${'$as_ac_var'}'` = yes; then
14699  cat >>confdefs.h <<_ACEOF
14700#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
14701_ACEOF
14702
14703else
14704  # strftime is in -lintl on SCO UNIX.
14705{ echo "$as_me:$LINENO: checking for strftime in -lintl" >&5
14706echo $ECHO_N "checking for strftime in -lintl... $ECHO_C" >&6; }
14707if test "${ac_cv_lib_intl_strftime+set}" = set; then
14708  echo $ECHO_N "(cached) $ECHO_C" >&6
14709else
14710  ac_check_lib_save_LIBS=$LIBS
14711LIBS="-lintl  $LIBS"
14712cat >conftest.$ac_ext <<_ACEOF
14713/* confdefs.h.  */
14714_ACEOF
14715cat confdefs.h >>conftest.$ac_ext
14716cat >>conftest.$ac_ext <<_ACEOF
14717/* end confdefs.h.  */
14718
14719/* Override any GCC internal prototype to avoid an error.
14720   Use char because int might match the return type of a GCC
14721   builtin and then its argument prototype would still apply.  */
14722#ifdef __cplusplus
14723extern "C"
14724#endif
14725char strftime ();
14726int
14727main ()
14728{
14729return strftime ();
14730  ;
14731  return 0;
14732}
14733_ACEOF
14734rm -f conftest.$ac_objext conftest$ac_exeext
14735if { (ac_try="$ac_link"
14736case "(($ac_try" in
14737  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14738  *) ac_try_echo=$ac_try;;
14739esac
14740eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14741  (eval "$ac_link") 2>conftest.er1
14742  ac_status=$?
14743  grep -v '^ *+' conftest.er1 >conftest.err
14744  rm -f conftest.er1
14745  cat conftest.err >&5
14746  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14747  (exit $ac_status); } && {
14748	 test -z "$ac_c_werror_flag" ||
14749	 test ! -s conftest.err
14750       } && test -s conftest$ac_exeext &&
14751       $as_test_x conftest$ac_exeext; then
14752  ac_cv_lib_intl_strftime=yes
14753else
14754  echo "$as_me: failed program was:" >&5
14755sed 's/^/| /' conftest.$ac_ext >&5
14756
14757	ac_cv_lib_intl_strftime=no
14758fi
14759
14760rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14761      conftest$ac_exeext conftest.$ac_ext
14762LIBS=$ac_check_lib_save_LIBS
14763fi
14764{ echo "$as_me:$LINENO: result: $ac_cv_lib_intl_strftime" >&5
14765echo "${ECHO_T}$ac_cv_lib_intl_strftime" >&6; }
14766if test $ac_cv_lib_intl_strftime = yes; then
14767  cat >>confdefs.h <<\_ACEOF
14768#define HAVE_STRFTIME 1
14769_ACEOF
14770
14771LIBS="-lintl $LIBS"
14772fi
14773
14774fi
14775done
14776
14777
14778# Check for ALTDIRFUNC glob() extension
14779{ echo "$as_me:$LINENO: checking for GLOB_ALTDIRFUNC support" >&5
14780echo $ECHO_N "checking for GLOB_ALTDIRFUNC support... $ECHO_C" >&6; }
14781cat >conftest.$ac_ext <<_ACEOF
14782/* confdefs.h.  */
14783_ACEOF
14784cat confdefs.h >>conftest.$ac_ext
14785cat >>conftest.$ac_ext <<_ACEOF
14786/* end confdefs.h.  */
14787
14788		#include <glob.h>
14789		#ifdef GLOB_ALTDIRFUNC
14790		FOUNDIT
14791		#endif
14792
14793_ACEOF
14794if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14795  $EGREP "FOUNDIT" >/dev/null 2>&1; then
14796
14797
14798cat >>confdefs.h <<\_ACEOF
14799#define GLOB_HAS_ALTDIRFUNC 1
14800_ACEOF
14801
14802		{ echo "$as_me:$LINENO: result: yes" >&5
14803echo "${ECHO_T}yes" >&6; }
14804
14805else
14806
14807		{ echo "$as_me:$LINENO: result: no" >&5
14808echo "${ECHO_T}no" >&6; }
14809
14810
14811fi
14812rm -f conftest*
14813
14814
14815# Check for g.gl_matchc glob() extension
14816{ echo "$as_me:$LINENO: checking for gl_matchc field in glob_t" >&5
14817echo $ECHO_N "checking for gl_matchc field in glob_t... $ECHO_C" >&6; }
14818cat >conftest.$ac_ext <<_ACEOF
14819/* confdefs.h.  */
14820_ACEOF
14821cat confdefs.h >>conftest.$ac_ext
14822cat >>conftest.$ac_ext <<_ACEOF
14823/* end confdefs.h.  */
14824 #include <glob.h>
14825int
14826main ()
14827{
14828 glob_t g; g.gl_matchc = 1;
14829  ;
14830  return 0;
14831}
14832_ACEOF
14833rm -f conftest.$ac_objext
14834if { (ac_try="$ac_compile"
14835case "(($ac_try" in
14836  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14837  *) ac_try_echo=$ac_try;;
14838esac
14839eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14840  (eval "$ac_compile") 2>conftest.er1
14841  ac_status=$?
14842  grep -v '^ *+' conftest.er1 >conftest.err
14843  rm -f conftest.er1
14844  cat conftest.err >&5
14845  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14846  (exit $ac_status); } && {
14847	 test -z "$ac_c_werror_flag" ||
14848	 test ! -s conftest.err
14849       } && test -s conftest.$ac_objext; then
14850
14851
14852cat >>confdefs.h <<\_ACEOF
14853#define GLOB_HAS_GL_MATCHC 1
14854_ACEOF
14855
14856		{ echo "$as_me:$LINENO: result: yes" >&5
14857echo "${ECHO_T}yes" >&6; }
14858
14859else
14860  echo "$as_me: failed program was:" >&5
14861sed 's/^/| /' conftest.$ac_ext >&5
14862
14863
14864		{ echo "$as_me:$LINENO: result: no" >&5
14865echo "${ECHO_T}no" >&6; }
14866
14867fi
14868
14869rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14870
14871# Check for g.gl_statv glob() extension
14872{ echo "$as_me:$LINENO: checking for gl_statv and GLOB_KEEPSTAT extensions for glob" >&5
14873echo $ECHO_N "checking for gl_statv and GLOB_KEEPSTAT extensions for glob... $ECHO_C" >&6; }
14874cat >conftest.$ac_ext <<_ACEOF
14875/* confdefs.h.  */
14876_ACEOF
14877cat confdefs.h >>conftest.$ac_ext
14878cat >>conftest.$ac_ext <<_ACEOF
14879/* end confdefs.h.  */
14880 #include <glob.h>
14881int
14882main ()
14883{
14884
14885#ifndef GLOB_KEEPSTAT
14886#error "glob does not support GLOB_KEEPSTAT extension"
14887#endif
14888glob_t g;
14889g.gl_statv = NULL;
14890
14891  ;
14892  return 0;
14893}
14894_ACEOF
14895rm -f conftest.$ac_objext
14896if { (ac_try="$ac_compile"
14897case "(($ac_try" in
14898  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14899  *) ac_try_echo=$ac_try;;
14900esac
14901eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14902  (eval "$ac_compile") 2>conftest.er1
14903  ac_status=$?
14904  grep -v '^ *+' conftest.er1 >conftest.err
14905  rm -f conftest.er1
14906  cat conftest.err >&5
14907  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14908  (exit $ac_status); } && {
14909	 test -z "$ac_c_werror_flag" ||
14910	 test ! -s conftest.err
14911       } && test -s conftest.$ac_objext; then
14912
14913
14914cat >>confdefs.h <<\_ACEOF
14915#define GLOB_HAS_GL_STATV 1
14916_ACEOF
14917
14918		{ echo "$as_me:$LINENO: result: yes" >&5
14919echo "${ECHO_T}yes" >&6; }
14920
14921else
14922  echo "$as_me: failed program was:" >&5
14923sed 's/^/| /' conftest.$ac_ext >&5
14924
14925
14926		{ echo "$as_me:$LINENO: result: no" >&5
14927echo "${ECHO_T}no" >&6; }
14928
14929
14930fi
14931
14932rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14933
14934{ echo "$as_me:$LINENO: checking whether GLOB_NOMATCH is declared" >&5
14935echo $ECHO_N "checking whether GLOB_NOMATCH is declared... $ECHO_C" >&6; }
14936if test "${ac_cv_have_decl_GLOB_NOMATCH+set}" = set; then
14937  echo $ECHO_N "(cached) $ECHO_C" >&6
14938else
14939  cat >conftest.$ac_ext <<_ACEOF
14940/* confdefs.h.  */
14941_ACEOF
14942cat confdefs.h >>conftest.$ac_ext
14943cat >>conftest.$ac_ext <<_ACEOF
14944/* end confdefs.h.  */
14945#include <glob.h>
14946
14947int
14948main ()
14949{
14950#ifndef GLOB_NOMATCH
14951  (void) GLOB_NOMATCH;
14952#endif
14953
14954  ;
14955  return 0;
14956}
14957_ACEOF
14958rm -f conftest.$ac_objext
14959if { (ac_try="$ac_compile"
14960case "(($ac_try" in
14961  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14962  *) ac_try_echo=$ac_try;;
14963esac
14964eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
14965  (eval "$ac_compile") 2>conftest.er1
14966  ac_status=$?
14967  grep -v '^ *+' conftest.er1 >conftest.err
14968  rm -f conftest.er1
14969  cat conftest.err >&5
14970  echo "$as_me:$LINENO: \$? = $ac_status" >&5
14971  (exit $ac_status); } && {
14972	 test -z "$ac_c_werror_flag" ||
14973	 test ! -s conftest.err
14974       } && test -s conftest.$ac_objext; then
14975  ac_cv_have_decl_GLOB_NOMATCH=yes
14976else
14977  echo "$as_me: failed program was:" >&5
14978sed 's/^/| /' conftest.$ac_ext >&5
14979
14980	ac_cv_have_decl_GLOB_NOMATCH=no
14981fi
14982
14983rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14984fi
14985{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_GLOB_NOMATCH" >&5
14986echo "${ECHO_T}$ac_cv_have_decl_GLOB_NOMATCH" >&6; }
14987if test $ac_cv_have_decl_GLOB_NOMATCH = yes; then
14988
14989cat >>confdefs.h <<_ACEOF
14990#define HAVE_DECL_GLOB_NOMATCH 1
14991_ACEOF
14992
14993
14994else
14995  cat >>confdefs.h <<_ACEOF
14996#define HAVE_DECL_GLOB_NOMATCH 0
14997_ACEOF
14998
14999
15000fi
15001
15002
15003
15004{ echo "$as_me:$LINENO: checking whether struct dirent allocates space for d_name" >&5
15005echo $ECHO_N "checking whether struct dirent allocates space for d_name... $ECHO_C" >&6; }
15006if test "$cross_compiling" = yes; then
15007
15008		{ echo "$as_me:$LINENO: WARNING: cross compiling: assuming BROKEN_ONE_BYTE_DIRENT_D_NAME" >&5
15009echo "$as_me: WARNING: cross compiling: assuming BROKEN_ONE_BYTE_DIRENT_D_NAME" >&2;}
15010		cat >>confdefs.h <<\_ACEOF
15011#define BROKEN_ONE_BYTE_DIRENT_D_NAME 1
15012_ACEOF
15013
15014
15015
15016else
15017  cat >conftest.$ac_ext <<_ACEOF
15018/* confdefs.h.  */
15019_ACEOF
15020cat confdefs.h >>conftest.$ac_ext
15021cat >>conftest.$ac_ext <<_ACEOF
15022/* end confdefs.h.  */
15023
15024#include <sys/types.h>
15025#include <dirent.h>
15026int
15027main ()
15028{
15029
15030	struct dirent d;
15031	exit(sizeof(d.d_name)<=sizeof(char));
15032
15033  ;
15034  return 0;
15035}
15036_ACEOF
15037rm -f conftest$ac_exeext
15038if { (ac_try="$ac_link"
15039case "(($ac_try" in
15040  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15041  *) ac_try_echo=$ac_try;;
15042esac
15043eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15044  (eval "$ac_link") 2>&5
15045  ac_status=$?
15046  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15047  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
15048  { (case "(($ac_try" in
15049  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15050  *) ac_try_echo=$ac_try;;
15051esac
15052eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15053  (eval "$ac_try") 2>&5
15054  ac_status=$?
15055  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15056  (exit $ac_status); }; }; then
15057  { echo "$as_me:$LINENO: result: yes" >&5
15058echo "${ECHO_T}yes" >&6; }
15059else
15060  echo "$as_me: program exited with status $ac_status" >&5
15061echo "$as_me: failed program was:" >&5
15062sed 's/^/| /' conftest.$ac_ext >&5
15063
15064( exit $ac_status )
15065
15066		{ echo "$as_me:$LINENO: result: no" >&5
15067echo "${ECHO_T}no" >&6; }
15068
15069cat >>confdefs.h <<\_ACEOF
15070#define BROKEN_ONE_BYTE_DIRENT_D_NAME 1
15071_ACEOF
15072
15073
15074fi
15075rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
15076fi
15077
15078
15079
15080{ echo "$as_me:$LINENO: checking for /proc/pid/fd directory" >&5
15081echo $ECHO_N "checking for /proc/pid/fd directory... $ECHO_C" >&6; }
15082if test -d "/proc/$$/fd" ; then
15083
15084cat >>confdefs.h <<\_ACEOF
15085#define HAVE_PROC_PID 1
15086_ACEOF
15087
15088	{ echo "$as_me:$LINENO: result: yes" >&5
15089echo "${ECHO_T}yes" >&6; }
15090else
15091	{ echo "$as_me:$LINENO: result: no" >&5
15092echo "${ECHO_T}no" >&6; }
15093fi
15094
15095# Check whether user wants S/Key support
15096SKEY_MSG="no"
15097
15098# Check whether --with-skey was given.
15099if test "${with_skey+set}" = set; then
15100  withval=$with_skey;
15101		if test "x$withval" != "xno" ; then
15102
15103			if test "x$withval" != "xyes" ; then
15104				CPPFLAGS="$CPPFLAGS -I${withval}/include"
15105				LDFLAGS="$LDFLAGS -L${withval}/lib"
15106			fi
15107
15108
15109cat >>confdefs.h <<\_ACEOF
15110#define SKEY 1
15111_ACEOF
15112
15113			LIBS="-lskey $LIBS"
15114			SKEY_MSG="yes"
15115
15116			{ echo "$as_me:$LINENO: checking for s/key support" >&5
15117echo $ECHO_N "checking for s/key support... $ECHO_C" >&6; }
15118			cat >conftest.$ac_ext <<_ACEOF
15119/* confdefs.h.  */
15120_ACEOF
15121cat confdefs.h >>conftest.$ac_ext
15122cat >>conftest.$ac_ext <<_ACEOF
15123/* end confdefs.h.  */
15124
15125#include <stdio.h>
15126#include <skey.h>
15127
15128int
15129main ()
15130{
15131
15132	char *ff = skey_keyinfo(""); ff="";
15133	exit(0);
15134
15135  ;
15136  return 0;
15137}
15138_ACEOF
15139rm -f conftest.$ac_objext conftest$ac_exeext
15140if { (ac_try="$ac_link"
15141case "(($ac_try" in
15142  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15143  *) ac_try_echo=$ac_try;;
15144esac
15145eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15146  (eval "$ac_link") 2>conftest.er1
15147  ac_status=$?
15148  grep -v '^ *+' conftest.er1 >conftest.err
15149  rm -f conftest.er1
15150  cat conftest.err >&5
15151  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15152  (exit $ac_status); } && {
15153	 test -z "$ac_c_werror_flag" ||
15154	 test ! -s conftest.err
15155       } && test -s conftest$ac_exeext &&
15156       $as_test_x conftest$ac_exeext; then
15157  { echo "$as_me:$LINENO: result: yes" >&5
15158echo "${ECHO_T}yes" >&6; }
15159else
15160  echo "$as_me: failed program was:" >&5
15161sed 's/^/| /' conftest.$ac_ext >&5
15162
15163
15164					{ echo "$as_me:$LINENO: result: no" >&5
15165echo "${ECHO_T}no" >&6; }
15166					{ { echo "$as_me:$LINENO: error: ** Incomplete or missing s/key libraries." >&5
15167echo "$as_me: error: ** Incomplete or missing s/key libraries." >&2;}
15168   { (exit 1); exit 1; }; }
15169
15170fi
15171
15172rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15173      conftest$ac_exeext conftest.$ac_ext
15174                 	{ echo "$as_me:$LINENO: checking if skeychallenge takes 4 arguments" >&5
15175echo $ECHO_N "checking if skeychallenge takes 4 arguments... $ECHO_C" >&6; }
15176			cat >conftest.$ac_ext <<_ACEOF
15177/* confdefs.h.  */
15178_ACEOF
15179cat confdefs.h >>conftest.$ac_ext
15180cat >>conftest.$ac_ext <<_ACEOF
15181/* end confdefs.h.  */
15182
15183#include <stdio.h>
15184#include <skey.h>
15185
15186int
15187main ()
15188{
15189
15190	(void)skeychallenge(NULL,"name","",0);
15191
15192  ;
15193  return 0;
15194}
15195_ACEOF
15196rm -f conftest.$ac_objext
15197if { (ac_try="$ac_compile"
15198case "(($ac_try" in
15199  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15200  *) ac_try_echo=$ac_try;;
15201esac
15202eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15203  (eval "$ac_compile") 2>conftest.er1
15204  ac_status=$?
15205  grep -v '^ *+' conftest.er1 >conftest.err
15206  rm -f conftest.er1
15207  cat conftest.err >&5
15208  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15209  (exit $ac_status); } && {
15210	 test -z "$ac_c_werror_flag" ||
15211	 test ! -s conftest.err
15212       } && test -s conftest.$ac_objext; then
15213
15214				{ echo "$as_me:$LINENO: result: yes" >&5
15215echo "${ECHO_T}yes" >&6; }
15216
15217cat >>confdefs.h <<\_ACEOF
15218#define SKEYCHALLENGE_4ARG 1
15219_ACEOF
15220
15221else
15222  echo "$as_me: failed program was:" >&5
15223sed 's/^/| /' conftest.$ac_ext >&5
15224
15225
15226				{ echo "$as_me:$LINENO: result: no" >&5
15227echo "${ECHO_T}no" >&6; }
15228
15229fi
15230
15231rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15232		fi
15233
15234
15235fi
15236
15237
15238# Check whether user wants to use ldns
15239LDNS_MSG="no"
15240
15241# Check whether --with-ldns was given.
15242if test "${with_ldns+set}" = set; then
15243  withval=$with_ldns;
15244        if test "x$withval" != "xno" ; then
15245
15246			if test "x$withval" != "xyes" ; then
15247				CPPFLAGS="$CPPFLAGS -I${withval}/include"
15248				LDFLAGS="$LDFLAGS -L${withval}/lib"
15249			fi
15250
15251
15252cat >>confdefs.h <<\_ACEOF
15253#define HAVE_LDNS 1
15254_ACEOF
15255
15256            LIBS="-lldns $LIBS"
15257            LDNS_MSG="yes"
15258
15259            { echo "$as_me:$LINENO: checking for ldns support" >&5
15260echo $ECHO_N "checking for ldns support... $ECHO_C" >&6; }
15261            cat >conftest.$ac_ext <<_ACEOF
15262/* confdefs.h.  */
15263_ACEOF
15264cat confdefs.h >>conftest.$ac_ext
15265cat >>conftest.$ac_ext <<_ACEOF
15266/* end confdefs.h.  */
15267
15268#include <stdio.h>
15269#include <stdlib.h>
15270#include <stdint.h>
15271#include <ldns/ldns.h>
15272int main() { ldns_status status = ldns_verify_trusted(NULL, NULL, NULL, NULL); status=LDNS_STATUS_OK; exit(0); }
15273
15274
15275_ACEOF
15276rm -f conftest.$ac_objext conftest$ac_exeext
15277if { (ac_try="$ac_link"
15278case "(($ac_try" in
15279  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15280  *) ac_try_echo=$ac_try;;
15281esac
15282eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15283  (eval "$ac_link") 2>conftest.er1
15284  ac_status=$?
15285  grep -v '^ *+' conftest.er1 >conftest.err
15286  rm -f conftest.er1
15287  cat conftest.err >&5
15288  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15289  (exit $ac_status); } && {
15290	 test -z "$ac_c_werror_flag" ||
15291	 test ! -s conftest.err
15292       } && test -s conftest$ac_exeext &&
15293       $as_test_x conftest$ac_exeext; then
15294  { echo "$as_me:$LINENO: result: yes" >&5
15295echo "${ECHO_T}yes" >&6; }
15296else
15297  echo "$as_me: failed program was:" >&5
15298sed 's/^/| /' conftest.$ac_ext >&5
15299
15300
15301					{ echo "$as_me:$LINENO: result: no" >&5
15302echo "${ECHO_T}no" >&6; }
15303					{ { echo "$as_me:$LINENO: error: ** Incomplete or missing ldns libraries." >&5
15304echo "$as_me: error: ** Incomplete or missing ldns libraries." >&2;}
15305   { (exit 1); exit 1; }; }
15306
15307fi
15308
15309rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15310      conftest$ac_exeext conftest.$ac_ext
15311        fi
15312
15313
15314fi
15315
15316
15317# Check whether user wants libedit support
15318LIBEDIT_MSG="no"
15319
15320# Check whether --with-libedit was given.
15321if test "${with_libedit+set}" = set; then
15322  withval=$with_libedit;  if test "x$withval" != "xno" ; then
15323		if test "x$withval" = "xyes" ; then
15324			if test -n "$ac_tool_prefix"; then
15325  # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
15326set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
15327{ echo "$as_me:$LINENO: checking for $ac_word" >&5
15328echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
15329if test "${ac_cv_path_PKGCONFIG+set}" = set; then
15330  echo $ECHO_N "(cached) $ECHO_C" >&6
15331else
15332  case $PKGCONFIG in
15333  [\\/]* | ?:[\\/]*)
15334  ac_cv_path_PKGCONFIG="$PKGCONFIG" # Let the user override the test with a path.
15335  ;;
15336  *)
15337  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15338for as_dir in $PATH
15339do
15340  IFS=$as_save_IFS
15341  test -z "$as_dir" && as_dir=.
15342  for ac_exec_ext in '' $ac_executable_extensions; do
15343  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
15344    ac_cv_path_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
15345    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15346    break 2
15347  fi
15348done
15349done
15350IFS=$as_save_IFS
15351
15352  ;;
15353esac
15354fi
15355PKGCONFIG=$ac_cv_path_PKGCONFIG
15356if test -n "$PKGCONFIG"; then
15357  { echo "$as_me:$LINENO: result: $PKGCONFIG" >&5
15358echo "${ECHO_T}$PKGCONFIG" >&6; }
15359else
15360  { echo "$as_me:$LINENO: result: no" >&5
15361echo "${ECHO_T}no" >&6; }
15362fi
15363
15364
15365fi
15366if test -z "$ac_cv_path_PKGCONFIG"; then
15367  ac_pt_PKGCONFIG=$PKGCONFIG
15368  # Extract the first word of "pkg-config", so it can be a program name with args.
15369set dummy pkg-config; ac_word=$2
15370{ echo "$as_me:$LINENO: checking for $ac_word" >&5
15371echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
15372if test "${ac_cv_path_ac_pt_PKGCONFIG+set}" = set; then
15373  echo $ECHO_N "(cached) $ECHO_C" >&6
15374else
15375  case $ac_pt_PKGCONFIG in
15376  [\\/]* | ?:[\\/]*)
15377  ac_cv_path_ac_pt_PKGCONFIG="$ac_pt_PKGCONFIG" # Let the user override the test with a path.
15378  ;;
15379  *)
15380  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
15381for as_dir in $PATH
15382do
15383  IFS=$as_save_IFS
15384  test -z "$as_dir" && as_dir=.
15385  for ac_exec_ext in '' $ac_executable_extensions; do
15386  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
15387    ac_cv_path_ac_pt_PKGCONFIG="$as_dir/$ac_word$ac_exec_ext"
15388    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
15389    break 2
15390  fi
15391done
15392done
15393IFS=$as_save_IFS
15394
15395  ;;
15396esac
15397fi
15398ac_pt_PKGCONFIG=$ac_cv_path_ac_pt_PKGCONFIG
15399if test -n "$ac_pt_PKGCONFIG"; then
15400  { echo "$as_me:$LINENO: result: $ac_pt_PKGCONFIG" >&5
15401echo "${ECHO_T}$ac_pt_PKGCONFIG" >&6; }
15402else
15403  { echo "$as_me:$LINENO: result: no" >&5
15404echo "${ECHO_T}no" >&6; }
15405fi
15406
15407  if test "x$ac_pt_PKGCONFIG" = x; then
15408    PKGCONFIG="no"
15409  else
15410    case $cross_compiling:$ac_tool_warned in
15411yes:)
15412{ echo "$as_me:$LINENO: WARNING: In the future, Autoconf will not detect cross-tools
15413whose name does not start with the host triplet.  If you think this
15414configuration is useful to you, please write to autoconf@gnu.org." >&5
15415echo "$as_me: WARNING: In the future, Autoconf will not detect cross-tools
15416whose name does not start with the host triplet.  If you think this
15417configuration is useful to you, please write to autoconf@gnu.org." >&2;}
15418ac_tool_warned=yes ;;
15419esac
15420    PKGCONFIG=$ac_pt_PKGCONFIG
15421  fi
15422else
15423  PKGCONFIG="$ac_cv_path_PKGCONFIG"
15424fi
15425
15426			if test "x$PKGCONFIG" != "xno"; then
15427				{ echo "$as_me:$LINENO: checking if $PKGCONFIG knows about libedit" >&5
15428echo $ECHO_N "checking if $PKGCONFIG knows about libedit... $ECHO_C" >&6; }
15429			 	if "$PKGCONFIG" libedit; then
15430					{ echo "$as_me:$LINENO: result: yes" >&5
15431echo "${ECHO_T}yes" >&6; }
15432					use_pkgconfig_for_libedit=yes
15433				else
15434					{ echo "$as_me:$LINENO: result: no" >&5
15435echo "${ECHO_T}no" >&6; }
15436				fi
15437			fi
15438		else
15439			CPPFLAGS="$CPPFLAGS -I${withval}/include"
15440			if test -n "${need_dash_r}"; then
15441				LDFLAGS="-L${withval}/lib -R${withval}/lib ${LDFLAGS}"
15442			else
15443				LDFLAGS="-L${withval}/lib ${LDFLAGS}"
15444			fi
15445		fi
15446		if test "x$use_pkgconfig_for_libedit" = "xyes"; then
15447			LIBEDIT=`$PKGCONFIG --libs libedit`
15448			CPPFLAGS="$CPPFLAGS `$PKGCONFIG --cflags libedit`"
15449		else
15450			LIBEDIT="-ledit -lcurses"
15451		fi
15452		OTHERLIBS=`echo $LIBEDIT | sed 's/-ledit//'`
15453		{ echo "$as_me:$LINENO: checking for el_init in -ledit" >&5
15454echo $ECHO_N "checking for el_init in -ledit... $ECHO_C" >&6; }
15455if test "${ac_cv_lib_edit_el_init+set}" = set; then
15456  echo $ECHO_N "(cached) $ECHO_C" >&6
15457else
15458  ac_check_lib_save_LIBS=$LIBS
15459LIBS="-ledit  $OTHERLIBS
15460		 $LIBS"
15461cat >conftest.$ac_ext <<_ACEOF
15462/* confdefs.h.  */
15463_ACEOF
15464cat confdefs.h >>conftest.$ac_ext
15465cat >>conftest.$ac_ext <<_ACEOF
15466/* end confdefs.h.  */
15467
15468/* Override any GCC internal prototype to avoid an error.
15469   Use char because int might match the return type of a GCC
15470   builtin and then its argument prototype would still apply.  */
15471#ifdef __cplusplus
15472extern "C"
15473#endif
15474char el_init ();
15475int
15476main ()
15477{
15478return el_init ();
15479  ;
15480  return 0;
15481}
15482_ACEOF
15483rm -f conftest.$ac_objext conftest$ac_exeext
15484if { (ac_try="$ac_link"
15485case "(($ac_try" in
15486  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15487  *) ac_try_echo=$ac_try;;
15488esac
15489eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15490  (eval "$ac_link") 2>conftest.er1
15491  ac_status=$?
15492  grep -v '^ *+' conftest.er1 >conftest.err
15493  rm -f conftest.er1
15494  cat conftest.err >&5
15495  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15496  (exit $ac_status); } && {
15497	 test -z "$ac_c_werror_flag" ||
15498	 test ! -s conftest.err
15499       } && test -s conftest$ac_exeext &&
15500       $as_test_x conftest$ac_exeext; then
15501  ac_cv_lib_edit_el_init=yes
15502else
15503  echo "$as_me: failed program was:" >&5
15504sed 's/^/| /' conftest.$ac_ext >&5
15505
15506	ac_cv_lib_edit_el_init=no
15507fi
15508
15509rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15510      conftest$ac_exeext conftest.$ac_ext
15511LIBS=$ac_check_lib_save_LIBS
15512fi
15513{ echo "$as_me:$LINENO: result: $ac_cv_lib_edit_el_init" >&5
15514echo "${ECHO_T}$ac_cv_lib_edit_el_init" >&6; }
15515if test $ac_cv_lib_edit_el_init = yes; then
15516
15517cat >>confdefs.h <<\_ACEOF
15518#define USE_LIBEDIT 1
15519_ACEOF
15520
15521			  LIBEDIT_MSG="yes"
15522
15523
15524else
15525   { { echo "$as_me:$LINENO: error: libedit not found" >&5
15526echo "$as_me: error: libedit not found" >&2;}
15527   { (exit 1); exit 1; }; }
15528fi
15529
15530		{ echo "$as_me:$LINENO: checking if libedit version is compatible" >&5
15531echo $ECHO_N "checking if libedit version is compatible... $ECHO_C" >&6; }
15532		cat >conftest.$ac_ext <<_ACEOF
15533/* confdefs.h.  */
15534_ACEOF
15535cat confdefs.h >>conftest.$ac_ext
15536cat >>conftest.$ac_ext <<_ACEOF
15537/* end confdefs.h.  */
15538 #include <histedit.h>
15539int
15540main ()
15541{
15542
15543	int i = H_SETSIZE;
15544	el_init("", NULL, NULL, NULL);
15545	exit(0);
15546
15547  ;
15548  return 0;
15549}
15550_ACEOF
15551rm -f conftest.$ac_objext
15552if { (ac_try="$ac_compile"
15553case "(($ac_try" in
15554  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15555  *) ac_try_echo=$ac_try;;
15556esac
15557eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15558  (eval "$ac_compile") 2>conftest.er1
15559  ac_status=$?
15560  grep -v '^ *+' conftest.er1 >conftest.err
15561  rm -f conftest.er1
15562  cat conftest.err >&5
15563  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15564  (exit $ac_status); } && {
15565	 test -z "$ac_c_werror_flag" ||
15566	 test ! -s conftest.err
15567       } && test -s conftest.$ac_objext; then
15568   { echo "$as_me:$LINENO: result: yes" >&5
15569echo "${ECHO_T}yes" >&6; }
15570else
15571  echo "$as_me: failed program was:" >&5
15572sed 's/^/| /' conftest.$ac_ext >&5
15573
15574	 { echo "$as_me:$LINENO: result: no" >&5
15575echo "${ECHO_T}no" >&6; }
15576		      { { echo "$as_me:$LINENO: error: libedit version is not compatible" >&5
15577echo "$as_me: error: libedit version is not compatible" >&2;}
15578   { (exit 1); exit 1; }; }
15579
15580fi
15581
15582rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15583	fi
15584
15585fi
15586
15587
15588AUDIT_MODULE=none
15589
15590# Check whether --with-audit was given.
15591if test "${with_audit+set}" = set; then
15592  withval=$with_audit;
15593	  { echo "$as_me:$LINENO: checking for supported audit module" >&5
15594echo $ECHO_N "checking for supported audit module... $ECHO_C" >&6; }
15595	  case "$withval" in
15596	  bsm)
15597		{ echo "$as_me:$LINENO: result: bsm" >&5
15598echo "${ECHO_T}bsm" >&6; }
15599		AUDIT_MODULE=bsm
15600
15601for ac_header in bsm/audit.h
15602do
15603as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15604{ echo "$as_me:$LINENO: checking for $ac_header" >&5
15605echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
15606if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
15607  echo $ECHO_N "(cached) $ECHO_C" >&6
15608else
15609  cat >conftest.$ac_ext <<_ACEOF
15610/* confdefs.h.  */
15611_ACEOF
15612cat confdefs.h >>conftest.$ac_ext
15613cat >>conftest.$ac_ext <<_ACEOF
15614/* end confdefs.h.  */
15615
15616#ifdef HAVE_TIME_H
15617# include <time.h>
15618#endif
15619
15620
15621
15622#include <$ac_header>
15623_ACEOF
15624rm -f conftest.$ac_objext
15625if { (ac_try="$ac_compile"
15626case "(($ac_try" in
15627  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15628  *) ac_try_echo=$ac_try;;
15629esac
15630eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15631  (eval "$ac_compile") 2>conftest.er1
15632  ac_status=$?
15633  grep -v '^ *+' conftest.er1 >conftest.err
15634  rm -f conftest.er1
15635  cat conftest.err >&5
15636  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15637  (exit $ac_status); } && {
15638	 test -z "$ac_c_werror_flag" ||
15639	 test ! -s conftest.err
15640       } && test -s conftest.$ac_objext; then
15641  eval "$as_ac_Header=yes"
15642else
15643  echo "$as_me: failed program was:" >&5
15644sed 's/^/| /' conftest.$ac_ext >&5
15645
15646	eval "$as_ac_Header=no"
15647fi
15648
15649rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15650fi
15651ac_res=`eval echo '${'$as_ac_Header'}'`
15652	       { echo "$as_me:$LINENO: result: $ac_res" >&5
15653echo "${ECHO_T}$ac_res" >&6; }
15654if test `eval echo '${'$as_ac_Header'}'` = yes; then
15655  cat >>confdefs.h <<_ACEOF
15656#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
15657_ACEOF
15658
15659else
15660  { { echo "$as_me:$LINENO: error: BSM enabled and bsm/audit.h not found" >&5
15661echo "$as_me: error: BSM enabled and bsm/audit.h not found" >&2;}
15662   { (exit 1); exit 1; }; }
15663fi
15664
15665done
15666
15667
15668{ echo "$as_me:$LINENO: checking for getaudit in -lbsm" >&5
15669echo $ECHO_N "checking for getaudit in -lbsm... $ECHO_C" >&6; }
15670if test "${ac_cv_lib_bsm_getaudit+set}" = set; then
15671  echo $ECHO_N "(cached) $ECHO_C" >&6
15672else
15673  ac_check_lib_save_LIBS=$LIBS
15674LIBS="-lbsm  $LIBS"
15675cat >conftest.$ac_ext <<_ACEOF
15676/* confdefs.h.  */
15677_ACEOF
15678cat confdefs.h >>conftest.$ac_ext
15679cat >>conftest.$ac_ext <<_ACEOF
15680/* end confdefs.h.  */
15681
15682/* Override any GCC internal prototype to avoid an error.
15683   Use char because int might match the return type of a GCC
15684   builtin and then its argument prototype would still apply.  */
15685#ifdef __cplusplus
15686extern "C"
15687#endif
15688char getaudit ();
15689int
15690main ()
15691{
15692return getaudit ();
15693  ;
15694  return 0;
15695}
15696_ACEOF
15697rm -f conftest.$ac_objext conftest$ac_exeext
15698if { (ac_try="$ac_link"
15699case "(($ac_try" in
15700  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15701  *) ac_try_echo=$ac_try;;
15702esac
15703eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15704  (eval "$ac_link") 2>conftest.er1
15705  ac_status=$?
15706  grep -v '^ *+' conftest.er1 >conftest.err
15707  rm -f conftest.er1
15708  cat conftest.err >&5
15709  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15710  (exit $ac_status); } && {
15711	 test -z "$ac_c_werror_flag" ||
15712	 test ! -s conftest.err
15713       } && test -s conftest$ac_exeext &&
15714       $as_test_x conftest$ac_exeext; then
15715  ac_cv_lib_bsm_getaudit=yes
15716else
15717  echo "$as_me: failed program was:" >&5
15718sed 's/^/| /' conftest.$ac_ext >&5
15719
15720	ac_cv_lib_bsm_getaudit=no
15721fi
15722
15723rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15724      conftest$ac_exeext conftest.$ac_ext
15725LIBS=$ac_check_lib_save_LIBS
15726fi
15727{ echo "$as_me:$LINENO: result: $ac_cv_lib_bsm_getaudit" >&5
15728echo "${ECHO_T}$ac_cv_lib_bsm_getaudit" >&6; }
15729if test $ac_cv_lib_bsm_getaudit = yes; then
15730  cat >>confdefs.h <<_ACEOF
15731#define HAVE_LIBBSM 1
15732_ACEOF
15733
15734  LIBS="-lbsm $LIBS"
15735
15736else
15737  { { echo "$as_me:$LINENO: error: BSM enabled and required library not found" >&5
15738echo "$as_me: error: BSM enabled and required library not found" >&2;}
15739   { (exit 1); exit 1; }; }
15740fi
15741
15742
15743for ac_func in getaudit
15744do
15745as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15746{ echo "$as_me:$LINENO: checking for $ac_func" >&5
15747echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
15748if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
15749  echo $ECHO_N "(cached) $ECHO_C" >&6
15750else
15751  cat >conftest.$ac_ext <<_ACEOF
15752/* confdefs.h.  */
15753_ACEOF
15754cat confdefs.h >>conftest.$ac_ext
15755cat >>conftest.$ac_ext <<_ACEOF
15756/* end confdefs.h.  */
15757/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15758   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15759#define $ac_func innocuous_$ac_func
15760
15761/* System header to define __stub macros and hopefully few prototypes,
15762    which can conflict with char $ac_func (); below.
15763    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15764    <limits.h> exists even on freestanding compilers.  */
15765
15766#ifdef __STDC__
15767# include <limits.h>
15768#else
15769# include <assert.h>
15770#endif
15771
15772#undef $ac_func
15773
15774/* Override any GCC internal prototype to avoid an error.
15775   Use char because int might match the return type of a GCC
15776   builtin and then its argument prototype would still apply.  */
15777#ifdef __cplusplus
15778extern "C"
15779#endif
15780char $ac_func ();
15781/* The GNU C library defines this for functions which it implements
15782    to always fail with ENOSYS.  Some functions are actually named
15783    something starting with __ and the normal name is an alias.  */
15784#if defined __stub_$ac_func || defined __stub___$ac_func
15785choke me
15786#endif
15787
15788int
15789main ()
15790{
15791return $ac_func ();
15792  ;
15793  return 0;
15794}
15795_ACEOF
15796rm -f conftest.$ac_objext conftest$ac_exeext
15797if { (ac_try="$ac_link"
15798case "(($ac_try" in
15799  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15800  *) ac_try_echo=$ac_try;;
15801esac
15802eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15803  (eval "$ac_link") 2>conftest.er1
15804  ac_status=$?
15805  grep -v '^ *+' conftest.er1 >conftest.err
15806  rm -f conftest.er1
15807  cat conftest.err >&5
15808  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15809  (exit $ac_status); } && {
15810	 test -z "$ac_c_werror_flag" ||
15811	 test ! -s conftest.err
15812       } && test -s conftest$ac_exeext &&
15813       $as_test_x conftest$ac_exeext; then
15814  eval "$as_ac_var=yes"
15815else
15816  echo "$as_me: failed program was:" >&5
15817sed 's/^/| /' conftest.$ac_ext >&5
15818
15819	eval "$as_ac_var=no"
15820fi
15821
15822rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15823      conftest$ac_exeext conftest.$ac_ext
15824fi
15825ac_res=`eval echo '${'$as_ac_var'}'`
15826	       { echo "$as_me:$LINENO: result: $ac_res" >&5
15827echo "${ECHO_T}$ac_res" >&6; }
15828if test `eval echo '${'$as_ac_var'}'` = yes; then
15829  cat >>confdefs.h <<_ACEOF
15830#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15831_ACEOF
15832
15833else
15834  { { echo "$as_me:$LINENO: error: BSM enabled and required function not found" >&5
15835echo "$as_me: error: BSM enabled and required function not found" >&2;}
15836   { (exit 1); exit 1; }; }
15837fi
15838done
15839
15840		# These are optional
15841
15842
15843for ac_func in getaudit_addr aug_get_machine
15844do
15845as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
15846{ echo "$as_me:$LINENO: checking for $ac_func" >&5
15847echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
15848if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
15849  echo $ECHO_N "(cached) $ECHO_C" >&6
15850else
15851  cat >conftest.$ac_ext <<_ACEOF
15852/* confdefs.h.  */
15853_ACEOF
15854cat confdefs.h >>conftest.$ac_ext
15855cat >>conftest.$ac_ext <<_ACEOF
15856/* end confdefs.h.  */
15857/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
15858   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
15859#define $ac_func innocuous_$ac_func
15860
15861/* System header to define __stub macros and hopefully few prototypes,
15862    which can conflict with char $ac_func (); below.
15863    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
15864    <limits.h> exists even on freestanding compilers.  */
15865
15866#ifdef __STDC__
15867# include <limits.h>
15868#else
15869# include <assert.h>
15870#endif
15871
15872#undef $ac_func
15873
15874/* Override any GCC internal prototype to avoid an error.
15875   Use char because int might match the return type of a GCC
15876   builtin and then its argument prototype would still apply.  */
15877#ifdef __cplusplus
15878extern "C"
15879#endif
15880char $ac_func ();
15881/* The GNU C library defines this for functions which it implements
15882    to always fail with ENOSYS.  Some functions are actually named
15883    something starting with __ and the normal name is an alias.  */
15884#if defined __stub_$ac_func || defined __stub___$ac_func
15885choke me
15886#endif
15887
15888int
15889main ()
15890{
15891return $ac_func ();
15892  ;
15893  return 0;
15894}
15895_ACEOF
15896rm -f conftest.$ac_objext conftest$ac_exeext
15897if { (ac_try="$ac_link"
15898case "(($ac_try" in
15899  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15900  *) ac_try_echo=$ac_try;;
15901esac
15902eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15903  (eval "$ac_link") 2>conftest.er1
15904  ac_status=$?
15905  grep -v '^ *+' conftest.er1 >conftest.err
15906  rm -f conftest.er1
15907  cat conftest.err >&5
15908  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15909  (exit $ac_status); } && {
15910	 test -z "$ac_c_werror_flag" ||
15911	 test ! -s conftest.err
15912       } && test -s conftest$ac_exeext &&
15913       $as_test_x conftest$ac_exeext; then
15914  eval "$as_ac_var=yes"
15915else
15916  echo "$as_me: failed program was:" >&5
15917sed 's/^/| /' conftest.$ac_ext >&5
15918
15919	eval "$as_ac_var=no"
15920fi
15921
15922rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15923      conftest$ac_exeext conftest.$ac_ext
15924fi
15925ac_res=`eval echo '${'$as_ac_var'}'`
15926	       { echo "$as_me:$LINENO: result: $ac_res" >&5
15927echo "${ECHO_T}$ac_res" >&6; }
15928if test `eval echo '${'$as_ac_var'}'` = yes; then
15929  cat >>confdefs.h <<_ACEOF
15930#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
15931_ACEOF
15932
15933fi
15934done
15935
15936
15937cat >>confdefs.h <<\_ACEOF
15938#define USE_BSM_AUDIT 1
15939_ACEOF
15940
15941		if test "$sol2ver" -ge 11; then
15942		   	SSHDLIBS="$SSHDLIBS -lscf"
15943
15944cat >>confdefs.h <<\_ACEOF
15945#define BROKEN_BSM_API 1
15946_ACEOF
15947
15948		fi
15949		;;
15950	  linux)
15951		{ echo "$as_me:$LINENO: result: linux" >&5
15952echo "${ECHO_T}linux" >&6; }
15953		AUDIT_MODULE=linux
15954
15955for ac_header in libaudit.h
15956do
15957as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
15958if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
15959  { echo "$as_me:$LINENO: checking for $ac_header" >&5
15960echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
15961if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
15962  echo $ECHO_N "(cached) $ECHO_C" >&6
15963fi
15964ac_res=`eval echo '${'$as_ac_Header'}'`
15965	       { echo "$as_me:$LINENO: result: $ac_res" >&5
15966echo "${ECHO_T}$ac_res" >&6; }
15967else
15968  # Is the header compilable?
15969{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
15970echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
15971cat >conftest.$ac_ext <<_ACEOF
15972/* confdefs.h.  */
15973_ACEOF
15974cat confdefs.h >>conftest.$ac_ext
15975cat >>conftest.$ac_ext <<_ACEOF
15976/* end confdefs.h.  */
15977$ac_includes_default
15978#include <$ac_header>
15979_ACEOF
15980rm -f conftest.$ac_objext
15981if { (ac_try="$ac_compile"
15982case "(($ac_try" in
15983  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15984  *) ac_try_echo=$ac_try;;
15985esac
15986eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
15987  (eval "$ac_compile") 2>conftest.er1
15988  ac_status=$?
15989  grep -v '^ *+' conftest.er1 >conftest.err
15990  rm -f conftest.er1
15991  cat conftest.err >&5
15992  echo "$as_me:$LINENO: \$? = $ac_status" >&5
15993  (exit $ac_status); } && {
15994	 test -z "$ac_c_werror_flag" ||
15995	 test ! -s conftest.err
15996       } && test -s conftest.$ac_objext; then
15997  ac_header_compiler=yes
15998else
15999  echo "$as_me: failed program was:" >&5
16000sed 's/^/| /' conftest.$ac_ext >&5
16001
16002	ac_header_compiler=no
16003fi
16004
16005rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16006{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
16007echo "${ECHO_T}$ac_header_compiler" >&6; }
16008
16009# Is the header present?
16010{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
16011echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
16012cat >conftest.$ac_ext <<_ACEOF
16013/* confdefs.h.  */
16014_ACEOF
16015cat confdefs.h >>conftest.$ac_ext
16016cat >>conftest.$ac_ext <<_ACEOF
16017/* end confdefs.h.  */
16018#include <$ac_header>
16019_ACEOF
16020if { (ac_try="$ac_cpp conftest.$ac_ext"
16021case "(($ac_try" in
16022  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16023  *) ac_try_echo=$ac_try;;
16024esac
16025eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16026  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
16027  ac_status=$?
16028  grep -v '^ *+' conftest.er1 >conftest.err
16029  rm -f conftest.er1
16030  cat conftest.err >&5
16031  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16032  (exit $ac_status); } >/dev/null && {
16033	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
16034	 test ! -s conftest.err
16035       }; then
16036  ac_header_preproc=yes
16037else
16038  echo "$as_me: failed program was:" >&5
16039sed 's/^/| /' conftest.$ac_ext >&5
16040
16041  ac_header_preproc=no
16042fi
16043
16044rm -f conftest.err conftest.$ac_ext
16045{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
16046echo "${ECHO_T}$ac_header_preproc" >&6; }
16047
16048# So?  What about this header?
16049case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
16050  yes:no: )
16051    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
16052echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
16053    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
16054echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
16055    ac_header_preproc=yes
16056    ;;
16057  no:yes:* )
16058    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
16059echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
16060    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
16061echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
16062    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
16063echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
16064    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
16065echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
16066    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
16067echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
16068    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
16069echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
16070    ( cat <<\_ASBOX
16071## ------------------------------------------- ##
16072## Report this to openssh-unix-dev@mindrot.org ##
16073## ------------------------------------------- ##
16074_ASBOX
16075     ) | sed "s/^/$as_me: WARNING:     /" >&2
16076    ;;
16077esac
16078{ echo "$as_me:$LINENO: checking for $ac_header" >&5
16079echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
16080if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
16081  echo $ECHO_N "(cached) $ECHO_C" >&6
16082else
16083  eval "$as_ac_Header=\$ac_header_preproc"
16084fi
16085ac_res=`eval echo '${'$as_ac_Header'}'`
16086	       { echo "$as_me:$LINENO: result: $ac_res" >&5
16087echo "${ECHO_T}$ac_res" >&6; }
16088
16089fi
16090if test `eval echo '${'$as_ac_Header'}'` = yes; then
16091  cat >>confdefs.h <<_ACEOF
16092#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
16093_ACEOF
16094
16095fi
16096
16097done
16098
16099		SSHDLIBS="$SSHDLIBS -laudit"
16100
16101cat >>confdefs.h <<\_ACEOF
16102#define USE_LINUX_AUDIT 1
16103_ACEOF
16104
16105		;;
16106	  debug)
16107		AUDIT_MODULE=debug
16108		{ echo "$as_me:$LINENO: result: debug" >&5
16109echo "${ECHO_T}debug" >&6; }
16110
16111cat >>confdefs.h <<\_ACEOF
16112#define SSH_AUDIT_EVENTS 1
16113_ACEOF
16114
16115		;;
16116	  no)
16117		{ echo "$as_me:$LINENO: result: no" >&5
16118echo "${ECHO_T}no" >&6; }
16119		;;
16120	  *)
16121		{ { echo "$as_me:$LINENO: error: Unknown audit module $withval" >&5
16122echo "$as_me: error: Unknown audit module $withval" >&2;}
16123   { (exit 1); exit 1; }; }
16124		;;
16125	esac
16126
16127fi
16128
16129
16130
16131# Check whether --with-pie was given.
16132if test "${with_pie+set}" = set; then
16133  withval=$with_pie;
16134	if test "x$withval" = "xno"; then
16135		use_pie=no
16136	fi
16137	if test "x$withval" = "xyes"; then
16138		use_pie=yes
16139	fi
16140
16141
16142fi
16143
16144if test "x$use_pie" = "x"; then
16145	use_pie=no
16146fi
16147if test "x$use_toolchain_hardening" != "x1" && test "x$use_pie" = "xauto"; then
16148	# Turn off automatic PIE when toolchain hardening is off.
16149	use_pie=no
16150fi
16151if test "x$use_pie" = "xauto"; then
16152	# Automatic PIE requires gcc >= 4.x
16153	{ echo "$as_me:$LINENO: checking for gcc >= 4.x" >&5
16154echo $ECHO_N "checking for gcc >= 4.x... $ECHO_C" >&6; }
16155	cat >conftest.$ac_ext <<_ACEOF
16156/* confdefs.h.  */
16157_ACEOF
16158cat confdefs.h >>conftest.$ac_ext
16159cat >>conftest.$ac_ext <<_ACEOF
16160/* end confdefs.h.  */
16161
16162#if !defined(__GNUC__) || __GNUC__ < 4
16163#error gcc is too old
16164#endif
16165
16166_ACEOF
16167rm -f conftest.$ac_objext
16168if { (ac_try="$ac_compile"
16169case "(($ac_try" in
16170  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16171  *) ac_try_echo=$ac_try;;
16172esac
16173eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16174  (eval "$ac_compile") 2>conftest.er1
16175  ac_status=$?
16176  grep -v '^ *+' conftest.er1 >conftest.err
16177  rm -f conftest.er1
16178  cat conftest.err >&5
16179  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16180  (exit $ac_status); } && {
16181	 test -z "$ac_c_werror_flag" ||
16182	 test ! -s conftest.err
16183       } && test -s conftest.$ac_objext; then
16184   { echo "$as_me:$LINENO: result: yes" >&5
16185echo "${ECHO_T}yes" >&6; }
16186else
16187  echo "$as_me: failed program was:" >&5
16188sed 's/^/| /' conftest.$ac_ext >&5
16189
16190	 { echo "$as_me:$LINENO: result: no" >&5
16191echo "${ECHO_T}no" >&6; }
16192	  use_pie=no
16193
16194fi
16195
16196rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16197fi
16198if test "x$use_pie" != "xno"; then
16199	SAVED_CFLAGS="$CFLAGS"
16200	SAVED_LDFLAGS="$LDFLAGS"
16201	{
16202	{ echo "$as_me:$LINENO: checking if $CC supports compile flag -fPIE" >&5
16203echo $ECHO_N "checking if $CC supports compile flag -fPIE... $ECHO_C" >&6; }
16204	saved_CFLAGS="$CFLAGS"
16205	CFLAGS="$CFLAGS $WERROR -fPIE"
16206	_define_flag=""
16207	test "x$_define_flag" = "x" && _define_flag="-fPIE"
16208	cat >conftest.$ac_ext <<_ACEOF
16209/* confdefs.h.  */
16210_ACEOF
16211cat confdefs.h >>conftest.$ac_ext
16212cat >>conftest.$ac_ext <<_ACEOF
16213/* end confdefs.h.  */
16214
16215#include <stdlib.h>
16216#include <stdio.h>
16217int main(int argc, char **argv) {
16218	/* Some math to catch -ftrapv problems in the toolchain */
16219	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
16220	float l = i * 2.1;
16221	double m = l / 0.5;
16222	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
16223	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
16224	exit(0);
16225}
16226
16227_ACEOF
16228rm -f conftest.$ac_objext
16229if { (ac_try="$ac_compile"
16230case "(($ac_try" in
16231  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16232  *) ac_try_echo=$ac_try;;
16233esac
16234eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16235  (eval "$ac_compile") 2>conftest.er1
16236  ac_status=$?
16237  grep -v '^ *+' conftest.er1 >conftest.err
16238  rm -f conftest.er1
16239  cat conftest.err >&5
16240  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16241  (exit $ac_status); } && {
16242	 test -z "$ac_c_werror_flag" ||
16243	 test ! -s conftest.err
16244       } && test -s conftest.$ac_objext; then
16245
16246if `grep -i "unrecognized option" conftest.err >/dev/null`
16247then
16248		{ echo "$as_me:$LINENO: result: no" >&5
16249echo "${ECHO_T}no" >&6; }
16250		CFLAGS="$saved_CFLAGS"
16251else
16252		{ echo "$as_me:$LINENO: result: yes" >&5
16253echo "${ECHO_T}yes" >&6; }
16254		 CFLAGS="$saved_CFLAGS $_define_flag"
16255fi
16256else
16257  echo "$as_me: failed program was:" >&5
16258sed 's/^/| /' conftest.$ac_ext >&5
16259
16260	 { echo "$as_me:$LINENO: result: no" >&5
16261echo "${ECHO_T}no" >&6; }
16262		  CFLAGS="$saved_CFLAGS"
16263
16264fi
16265
16266rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16267}
16268	{
16269	{ echo "$as_me:$LINENO: checking if $LD supports link flag -pie" >&5
16270echo $ECHO_N "checking if $LD supports link flag -pie... $ECHO_C" >&6; }
16271	saved_LDFLAGS="$LDFLAGS"
16272	LDFLAGS="$LDFLAGS $WERROR -pie"
16273	_define_flag=""
16274	test "x$_define_flag" = "x" && _define_flag="-pie"
16275	cat >conftest.$ac_ext <<_ACEOF
16276/* confdefs.h.  */
16277_ACEOF
16278cat confdefs.h >>conftest.$ac_ext
16279cat >>conftest.$ac_ext <<_ACEOF
16280/* end confdefs.h.  */
16281
16282#include <stdlib.h>
16283#include <stdio.h>
16284int main(int argc, char **argv) {
16285	/* Some math to catch -ftrapv problems in the toolchain */
16286	int i = 123 * argc, j = 456 + argc, k = 789 - argc;
16287	float l = i * 2.1;
16288	double m = l / 0.5;
16289	long long int n = argc * 12345LL, o = 12345LL * (long long int)argc;
16290	printf("%d %d %d %f %f %lld %lld\n", i, j, k, l, m, n, o);
16291	exit(0);
16292}
16293
16294_ACEOF
16295rm -f conftest.$ac_objext conftest$ac_exeext
16296if { (ac_try="$ac_link"
16297case "(($ac_try" in
16298  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16299  *) ac_try_echo=$ac_try;;
16300esac
16301eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16302  (eval "$ac_link") 2>conftest.er1
16303  ac_status=$?
16304  grep -v '^ *+' conftest.er1 >conftest.err
16305  rm -f conftest.er1
16306  cat conftest.err >&5
16307  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16308  (exit $ac_status); } && {
16309	 test -z "$ac_c_werror_flag" ||
16310	 test ! -s conftest.err
16311       } && test -s conftest$ac_exeext &&
16312       $as_test_x conftest$ac_exeext; then
16313   { echo "$as_me:$LINENO: result: yes" >&5
16314echo "${ECHO_T}yes" >&6; }
16315		  LDFLAGS="$saved_LDFLAGS $_define_flag"
16316else
16317  echo "$as_me: failed program was:" >&5
16318sed 's/^/| /' conftest.$ac_ext >&5
16319
16320	 { echo "$as_me:$LINENO: result: no" >&5
16321echo "${ECHO_T}no" >&6; }
16322		  LDFLAGS="$saved_LDFLAGS"
16323
16324fi
16325
16326rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16327      conftest$ac_exeext conftest.$ac_ext
16328}
16329	# We use both -fPIE and -pie or neither.
16330	{ echo "$as_me:$LINENO: checking whether both -fPIE and -pie are supported" >&5
16331echo $ECHO_N "checking whether both -fPIE and -pie are supported... $ECHO_C" >&6; }
16332	if echo "x $CFLAGS"  | grep ' -fPIE' >/dev/null 2>&1 && \
16333	   echo "x $LDFLAGS" | grep ' -pie'  >/dev/null 2>&1 ; then
16334		{ echo "$as_me:$LINENO: result: yes" >&5
16335echo "${ECHO_T}yes" >&6; }
16336	else
16337		{ echo "$as_me:$LINENO: result: no" >&5
16338echo "${ECHO_T}no" >&6; }
16339		CFLAGS="$SAVED_CFLAGS"
16340		LDFLAGS="$SAVED_LDFLAGS"
16341	fi
16342fi
16343
16344
16345
16346
16347
16348
16349
16350
16351
16352
16353
16354
16355
16356
16357
16358
16359
16360
16361
16362
16363
16364
16365
16366
16367
16368
16369
16370
16371
16372
16373
16374
16375
16376
16377
16378
16379
16380
16381
16382
16383
16384
16385
16386
16387
16388
16389
16390
16391
16392
16393
16394
16395
16396
16397
16398
16399
16400
16401
16402
16403
16404
16405
16406
16407
16408
16409
16410
16411
16412
16413
16414
16415
16416
16417
16418
16419
16420
16421
16422
16423
16424
16425
16426
16427
16428
16429
16430
16431
16432
16433
16434
16435
16436
16437
16438
16439
16440
16441
16442
16443
16444
16445
16446
16447
16448
16449
16450
16451
16452
16453for ac_func in  \
16454	Blowfish_initstate \
16455	Blowfish_expandstate \
16456	Blowfish_expand0state \
16457	Blowfish_stream2word \
16458	asprintf \
16459	b64_ntop \
16460	__b64_ntop \
16461	b64_pton \
16462	__b64_pton \
16463	bcopy \
16464	bcrypt_pbkdf \
16465	bindresvport_sa \
16466	blf_enc \
16467	cap_rights_limit \
16468	clock \
16469	closefrom \
16470	dirfd \
16471	endgrent \
16472	explicit_bzero \
16473	fchmod \
16474	fchown \
16475	freeaddrinfo \
16476	fstatfs \
16477	fstatvfs \
16478	futimes \
16479	getaddrinfo \
16480	getcwd \
16481	getgrouplist \
16482	getnameinfo \
16483	getopt \
16484	getpeereid \
16485	getpeerucred \
16486	getpgid \
16487	getpgrp \
16488	_getpty \
16489	getrlimit \
16490	getttyent \
16491	glob \
16492	group_from_gid \
16493	inet_aton \
16494	inet_ntoa \
16495	inet_ntop \
16496	innetgr \
16497	login_getcapbool \
16498	mblen \
16499	md5_crypt \
16500	memmove \
16501	memset_s \
16502	mkdtemp \
16503	mmap \
16504	ngetaddrinfo \
16505	nsleep \
16506	ogetaddrinfo \
16507	openlog_r \
16508	poll \
16509	prctl \
16510	pstat \
16511	readpassphrase \
16512	reallocarray \
16513	realpath \
16514	recvmsg \
16515	rresvport_af \
16516	sendmsg \
16517	setdtablesize \
16518	setegid \
16519	setenv \
16520	seteuid \
16521	setgroupent \
16522	setgroups \
16523	setlinebuf \
16524	setlogin \
16525	setpassent\
16526	setpcred \
16527	setproctitle \
16528	setregid \
16529	setreuid \
16530	setrlimit \
16531	setsid \
16532	setvbuf \
16533	sigaction \
16534	sigvec \
16535	snprintf \
16536	socketpair \
16537	statfs \
16538	statvfs \
16539	strdup \
16540	strerror \
16541	strlcat \
16542	strlcpy \
16543	strmode \
16544	strnlen \
16545	strnvis \
16546	strptime \
16547	strtonum \
16548	strtoll \
16549	strtoul \
16550	strtoull \
16551	swap32 \
16552	sysconf \
16553	tcgetpgrp \
16554	timingsafe_bcmp \
16555	truncate \
16556	unsetenv \
16557	updwtmpx \
16558	user_from_uid \
16559	usleep \
16560	vasprintf \
16561	vsnprintf \
16562	waitpid \
16563
16564do
16565as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16566{ echo "$as_me:$LINENO: checking for $ac_func" >&5
16567echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16568if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16569  echo $ECHO_N "(cached) $ECHO_C" >&6
16570else
16571  cat >conftest.$ac_ext <<_ACEOF
16572/* confdefs.h.  */
16573_ACEOF
16574cat confdefs.h >>conftest.$ac_ext
16575cat >>conftest.$ac_ext <<_ACEOF
16576/* end confdefs.h.  */
16577/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16578   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16579#define $ac_func innocuous_$ac_func
16580
16581/* System header to define __stub macros and hopefully few prototypes,
16582    which can conflict with char $ac_func (); below.
16583    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16584    <limits.h> exists even on freestanding compilers.  */
16585
16586#ifdef __STDC__
16587# include <limits.h>
16588#else
16589# include <assert.h>
16590#endif
16591
16592#undef $ac_func
16593
16594/* Override any GCC internal prototype to avoid an error.
16595   Use char because int might match the return type of a GCC
16596   builtin and then its argument prototype would still apply.  */
16597#ifdef __cplusplus
16598extern "C"
16599#endif
16600char $ac_func ();
16601/* The GNU C library defines this for functions which it implements
16602    to always fail with ENOSYS.  Some functions are actually named
16603    something starting with __ and the normal name is an alias.  */
16604#if defined __stub_$ac_func || defined __stub___$ac_func
16605choke me
16606#endif
16607
16608int
16609main ()
16610{
16611return $ac_func ();
16612  ;
16613  return 0;
16614}
16615_ACEOF
16616rm -f conftest.$ac_objext conftest$ac_exeext
16617if { (ac_try="$ac_link"
16618case "(($ac_try" in
16619  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16620  *) ac_try_echo=$ac_try;;
16621esac
16622eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16623  (eval "$ac_link") 2>conftest.er1
16624  ac_status=$?
16625  grep -v '^ *+' conftest.er1 >conftest.err
16626  rm -f conftest.er1
16627  cat conftest.err >&5
16628  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16629  (exit $ac_status); } && {
16630	 test -z "$ac_c_werror_flag" ||
16631	 test ! -s conftest.err
16632       } && test -s conftest$ac_exeext &&
16633       $as_test_x conftest$ac_exeext; then
16634  eval "$as_ac_var=yes"
16635else
16636  echo "$as_me: failed program was:" >&5
16637sed 's/^/| /' conftest.$ac_ext >&5
16638
16639	eval "$as_ac_var=no"
16640fi
16641
16642rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16643      conftest$ac_exeext conftest.$ac_ext
16644fi
16645ac_res=`eval echo '${'$as_ac_var'}'`
16646	       { echo "$as_me:$LINENO: result: $ac_res" >&5
16647echo "${ECHO_T}$ac_res" >&6; }
16648if test `eval echo '${'$as_ac_var'}'` = yes; then
16649  cat >>confdefs.h <<_ACEOF
16650#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16651_ACEOF
16652
16653fi
16654done
16655
16656
16657cat >conftest.$ac_ext <<_ACEOF
16658/* confdefs.h.  */
16659_ACEOF
16660cat confdefs.h >>conftest.$ac_ext
16661cat >>conftest.$ac_ext <<_ACEOF
16662/* end confdefs.h.  */
16663 #include <ctype.h>
16664int
16665main ()
16666{
16667 return (isblank('a'));
16668  ;
16669  return 0;
16670}
16671_ACEOF
16672rm -f conftest.$ac_objext conftest$ac_exeext
16673if { (ac_try="$ac_link"
16674case "(($ac_try" in
16675  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16676  *) ac_try_echo=$ac_try;;
16677esac
16678eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16679  (eval "$ac_link") 2>conftest.er1
16680  ac_status=$?
16681  grep -v '^ *+' conftest.er1 >conftest.err
16682  rm -f conftest.er1
16683  cat conftest.err >&5
16684  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16685  (exit $ac_status); } && {
16686	 test -z "$ac_c_werror_flag" ||
16687	 test ! -s conftest.err
16688       } && test -s conftest$ac_exeext &&
16689       $as_test_x conftest$ac_exeext; then
16690
16691cat >>confdefs.h <<\_ACEOF
16692#define HAVE_ISBLANK 1
16693_ACEOF
16694
16695
16696else
16697  echo "$as_me: failed program was:" >&5
16698sed 's/^/| /' conftest.$ac_ext >&5
16699
16700
16701fi
16702
16703rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16704      conftest$ac_exeext conftest.$ac_ext
16705
16706# PKCS11 depends on OpenSSL.
16707if test "x$openssl" = "xyes" ; then
16708	# PKCS#11 support requires dlopen() and co
16709	{ echo "$as_me:$LINENO: checking for library containing dlopen" >&5
16710echo $ECHO_N "checking for library containing dlopen... $ECHO_C" >&6; }
16711if test "${ac_cv_search_dlopen+set}" = set; then
16712  echo $ECHO_N "(cached) $ECHO_C" >&6
16713else
16714  ac_func_search_save_LIBS=$LIBS
16715cat >conftest.$ac_ext <<_ACEOF
16716/* confdefs.h.  */
16717_ACEOF
16718cat confdefs.h >>conftest.$ac_ext
16719cat >>conftest.$ac_ext <<_ACEOF
16720/* end confdefs.h.  */
16721
16722/* Override any GCC internal prototype to avoid an error.
16723   Use char because int might match the return type of a GCC
16724   builtin and then its argument prototype would still apply.  */
16725#ifdef __cplusplus
16726extern "C"
16727#endif
16728char dlopen ();
16729int
16730main ()
16731{
16732return dlopen ();
16733  ;
16734  return 0;
16735}
16736_ACEOF
16737for ac_lib in '' dl; do
16738  if test -z "$ac_lib"; then
16739    ac_res="none required"
16740  else
16741    ac_res=-l$ac_lib
16742    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
16743  fi
16744  rm -f conftest.$ac_objext conftest$ac_exeext
16745if { (ac_try="$ac_link"
16746case "(($ac_try" in
16747  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16748  *) ac_try_echo=$ac_try;;
16749esac
16750eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16751  (eval "$ac_link") 2>conftest.er1
16752  ac_status=$?
16753  grep -v '^ *+' conftest.er1 >conftest.err
16754  rm -f conftest.er1
16755  cat conftest.err >&5
16756  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16757  (exit $ac_status); } && {
16758	 test -z "$ac_c_werror_flag" ||
16759	 test ! -s conftest.err
16760       } && test -s conftest$ac_exeext &&
16761       $as_test_x conftest$ac_exeext; then
16762  ac_cv_search_dlopen=$ac_res
16763else
16764  echo "$as_me: failed program was:" >&5
16765sed 's/^/| /' conftest.$ac_ext >&5
16766
16767
16768fi
16769
16770rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16771      conftest$ac_exeext
16772  if test "${ac_cv_search_dlopen+set}" = set; then
16773  break
16774fi
16775done
16776if test "${ac_cv_search_dlopen+set}" = set; then
16777  :
16778else
16779  ac_cv_search_dlopen=no
16780fi
16781rm conftest.$ac_ext
16782LIBS=$ac_func_search_save_LIBS
16783fi
16784{ echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5
16785echo "${ECHO_T}$ac_cv_search_dlopen" >&6; }
16786ac_res=$ac_cv_search_dlopen
16787if test "$ac_res" != no; then
16788  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
16789
16790cat >>confdefs.h <<\_ACEOF
16791#define ENABLE_PKCS11
16792_ACEOF
16793
16794
16795fi
16796
16797fi
16798
16799# IRIX has a const char return value for gai_strerror()
16800
16801for ac_func in gai_strerror
16802do
16803as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
16804{ echo "$as_me:$LINENO: checking for $ac_func" >&5
16805echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
16806if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
16807  echo $ECHO_N "(cached) $ECHO_C" >&6
16808else
16809  cat >conftest.$ac_ext <<_ACEOF
16810/* confdefs.h.  */
16811_ACEOF
16812cat confdefs.h >>conftest.$ac_ext
16813cat >>conftest.$ac_ext <<_ACEOF
16814/* end confdefs.h.  */
16815/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
16816   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
16817#define $ac_func innocuous_$ac_func
16818
16819/* System header to define __stub macros and hopefully few prototypes,
16820    which can conflict with char $ac_func (); below.
16821    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
16822    <limits.h> exists even on freestanding compilers.  */
16823
16824#ifdef __STDC__
16825# include <limits.h>
16826#else
16827# include <assert.h>
16828#endif
16829
16830#undef $ac_func
16831
16832/* Override any GCC internal prototype to avoid an error.
16833   Use char because int might match the return type of a GCC
16834   builtin and then its argument prototype would still apply.  */
16835#ifdef __cplusplus
16836extern "C"
16837#endif
16838char $ac_func ();
16839/* The GNU C library defines this for functions which it implements
16840    to always fail with ENOSYS.  Some functions are actually named
16841    something starting with __ and the normal name is an alias.  */
16842#if defined __stub_$ac_func || defined __stub___$ac_func
16843choke me
16844#endif
16845
16846int
16847main ()
16848{
16849return $ac_func ();
16850  ;
16851  return 0;
16852}
16853_ACEOF
16854rm -f conftest.$ac_objext conftest$ac_exeext
16855if { (ac_try="$ac_link"
16856case "(($ac_try" in
16857  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16858  *) ac_try_echo=$ac_try;;
16859esac
16860eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16861  (eval "$ac_link") 2>conftest.er1
16862  ac_status=$?
16863  grep -v '^ *+' conftest.er1 >conftest.err
16864  rm -f conftest.er1
16865  cat conftest.err >&5
16866  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16867  (exit $ac_status); } && {
16868	 test -z "$ac_c_werror_flag" ||
16869	 test ! -s conftest.err
16870       } && test -s conftest$ac_exeext &&
16871       $as_test_x conftest$ac_exeext; then
16872  eval "$as_ac_var=yes"
16873else
16874  echo "$as_me: failed program was:" >&5
16875sed 's/^/| /' conftest.$ac_ext >&5
16876
16877	eval "$as_ac_var=no"
16878fi
16879
16880rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16881      conftest$ac_exeext conftest.$ac_ext
16882fi
16883ac_res=`eval echo '${'$as_ac_var'}'`
16884	       { echo "$as_me:$LINENO: result: $ac_res" >&5
16885echo "${ECHO_T}$ac_res" >&6; }
16886if test `eval echo '${'$as_ac_var'}'` = yes; then
16887  cat >>confdefs.h <<_ACEOF
16888#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
16889_ACEOF
16890
16891	cat >>confdefs.h <<\_ACEOF
16892#define HAVE_GAI_STRERROR 1
16893_ACEOF
16894
16895	cat >conftest.$ac_ext <<_ACEOF
16896/* confdefs.h.  */
16897_ACEOF
16898cat confdefs.h >>conftest.$ac_ext
16899cat >>conftest.$ac_ext <<_ACEOF
16900/* end confdefs.h.  */
16901
16902#include <sys/types.h>
16903#include <sys/socket.h>
16904#include <netdb.h>
16905
16906const char *gai_strerror(int);
16907
16908int
16909main ()
16910{
16911
16912	char *str;
16913	str = gai_strerror(0);
16914
16915  ;
16916  return 0;
16917}
16918_ACEOF
16919rm -f conftest.$ac_objext
16920if { (ac_try="$ac_compile"
16921case "(($ac_try" in
16922  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16923  *) ac_try_echo=$ac_try;;
16924esac
16925eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16926  (eval "$ac_compile") 2>conftest.er1
16927  ac_status=$?
16928  grep -v '^ *+' conftest.er1 >conftest.err
16929  rm -f conftest.er1
16930  cat conftest.err >&5
16931  echo "$as_me:$LINENO: \$? = $ac_status" >&5
16932  (exit $ac_status); } && {
16933	 test -z "$ac_c_werror_flag" ||
16934	 test ! -s conftest.err
16935       } && test -s conftest.$ac_objext; then
16936
16937
16938cat >>confdefs.h <<\_ACEOF
16939#define HAVE_CONST_GAI_STRERROR_PROTO 1
16940_ACEOF
16941
16942else
16943  echo "$as_me: failed program was:" >&5
16944sed 's/^/| /' conftest.$ac_ext >&5
16945
16946
16947fi
16948
16949rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16950fi
16951done
16952
16953
16954{ echo "$as_me:$LINENO: checking for library containing nanosleep" >&5
16955echo $ECHO_N "checking for library containing nanosleep... $ECHO_C" >&6; }
16956if test "${ac_cv_search_nanosleep+set}" = set; then
16957  echo $ECHO_N "(cached) $ECHO_C" >&6
16958else
16959  ac_func_search_save_LIBS=$LIBS
16960cat >conftest.$ac_ext <<_ACEOF
16961/* confdefs.h.  */
16962_ACEOF
16963cat confdefs.h >>conftest.$ac_ext
16964cat >>conftest.$ac_ext <<_ACEOF
16965/* end confdefs.h.  */
16966
16967/* Override any GCC internal prototype to avoid an error.
16968   Use char because int might match the return type of a GCC
16969   builtin and then its argument prototype would still apply.  */
16970#ifdef __cplusplus
16971extern "C"
16972#endif
16973char nanosleep ();
16974int
16975main ()
16976{
16977return nanosleep ();
16978  ;
16979  return 0;
16980}
16981_ACEOF
16982for ac_lib in '' rt posix4; do
16983  if test -z "$ac_lib"; then
16984    ac_res="none required"
16985  else
16986    ac_res=-l$ac_lib
16987    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
16988  fi
16989  rm -f conftest.$ac_objext conftest$ac_exeext
16990if { (ac_try="$ac_link"
16991case "(($ac_try" in
16992  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16993  *) ac_try_echo=$ac_try;;
16994esac
16995eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
16996  (eval "$ac_link") 2>conftest.er1
16997  ac_status=$?
16998  grep -v '^ *+' conftest.er1 >conftest.err
16999  rm -f conftest.er1
17000  cat conftest.err >&5
17001  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17002  (exit $ac_status); } && {
17003	 test -z "$ac_c_werror_flag" ||
17004	 test ! -s conftest.err
17005       } && test -s conftest$ac_exeext &&
17006       $as_test_x conftest$ac_exeext; then
17007  ac_cv_search_nanosleep=$ac_res
17008else
17009  echo "$as_me: failed program was:" >&5
17010sed 's/^/| /' conftest.$ac_ext >&5
17011
17012
17013fi
17014
17015rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17016      conftest$ac_exeext
17017  if test "${ac_cv_search_nanosleep+set}" = set; then
17018  break
17019fi
17020done
17021if test "${ac_cv_search_nanosleep+set}" = set; then
17022  :
17023else
17024  ac_cv_search_nanosleep=no
17025fi
17026rm conftest.$ac_ext
17027LIBS=$ac_func_search_save_LIBS
17028fi
17029{ echo "$as_me:$LINENO: result: $ac_cv_search_nanosleep" >&5
17030echo "${ECHO_T}$ac_cv_search_nanosleep" >&6; }
17031ac_res=$ac_cv_search_nanosleep
17032if test "$ac_res" != no; then
17033  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17034
17035cat >>confdefs.h <<\_ACEOF
17036#define HAVE_NANOSLEEP 1
17037_ACEOF
17038
17039fi
17040
17041
17042{ echo "$as_me:$LINENO: checking for library containing clock_gettime" >&5
17043echo $ECHO_N "checking for library containing clock_gettime... $ECHO_C" >&6; }
17044if test "${ac_cv_search_clock_gettime+set}" = set; then
17045  echo $ECHO_N "(cached) $ECHO_C" >&6
17046else
17047  ac_func_search_save_LIBS=$LIBS
17048cat >conftest.$ac_ext <<_ACEOF
17049/* confdefs.h.  */
17050_ACEOF
17051cat confdefs.h >>conftest.$ac_ext
17052cat >>conftest.$ac_ext <<_ACEOF
17053/* end confdefs.h.  */
17054
17055/* Override any GCC internal prototype to avoid an error.
17056   Use char because int might match the return type of a GCC
17057   builtin and then its argument prototype would still apply.  */
17058#ifdef __cplusplus
17059extern "C"
17060#endif
17061char clock_gettime ();
17062int
17063main ()
17064{
17065return clock_gettime ();
17066  ;
17067  return 0;
17068}
17069_ACEOF
17070for ac_lib in '' rt; do
17071  if test -z "$ac_lib"; then
17072    ac_res="none required"
17073  else
17074    ac_res=-l$ac_lib
17075    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
17076  fi
17077  rm -f conftest.$ac_objext conftest$ac_exeext
17078if { (ac_try="$ac_link"
17079case "(($ac_try" in
17080  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17081  *) ac_try_echo=$ac_try;;
17082esac
17083eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17084  (eval "$ac_link") 2>conftest.er1
17085  ac_status=$?
17086  grep -v '^ *+' conftest.er1 >conftest.err
17087  rm -f conftest.er1
17088  cat conftest.err >&5
17089  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17090  (exit $ac_status); } && {
17091	 test -z "$ac_c_werror_flag" ||
17092	 test ! -s conftest.err
17093       } && test -s conftest$ac_exeext &&
17094       $as_test_x conftest$ac_exeext; then
17095  ac_cv_search_clock_gettime=$ac_res
17096else
17097  echo "$as_me: failed program was:" >&5
17098sed 's/^/| /' conftest.$ac_ext >&5
17099
17100
17101fi
17102
17103rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17104      conftest$ac_exeext
17105  if test "${ac_cv_search_clock_gettime+set}" = set; then
17106  break
17107fi
17108done
17109if test "${ac_cv_search_clock_gettime+set}" = set; then
17110  :
17111else
17112  ac_cv_search_clock_gettime=no
17113fi
17114rm conftest.$ac_ext
17115LIBS=$ac_func_search_save_LIBS
17116fi
17117{ echo "$as_me:$LINENO: result: $ac_cv_search_clock_gettime" >&5
17118echo "${ECHO_T}$ac_cv_search_clock_gettime" >&6; }
17119ac_res=$ac_cv_search_clock_gettime
17120if test "$ac_res" != no; then
17121  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
17122
17123cat >>confdefs.h <<\_ACEOF
17124#define HAVE_CLOCK_GETTIME 1
17125_ACEOF
17126
17127fi
17128
17129
17130{ echo "$as_me:$LINENO: checking whether getrusage is declared" >&5
17131echo $ECHO_N "checking whether getrusage is declared... $ECHO_C" >&6; }
17132if test "${ac_cv_have_decl_getrusage+set}" = set; then
17133  echo $ECHO_N "(cached) $ECHO_C" >&6
17134else
17135  cat >conftest.$ac_ext <<_ACEOF
17136/* confdefs.h.  */
17137_ACEOF
17138cat confdefs.h >>conftest.$ac_ext
17139cat >>conftest.$ac_ext <<_ACEOF
17140/* end confdefs.h.  */
17141$ac_includes_default
17142int
17143main ()
17144{
17145#ifndef getrusage
17146  (void) getrusage;
17147#endif
17148
17149  ;
17150  return 0;
17151}
17152_ACEOF
17153rm -f conftest.$ac_objext
17154if { (ac_try="$ac_compile"
17155case "(($ac_try" in
17156  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17157  *) ac_try_echo=$ac_try;;
17158esac
17159eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17160  (eval "$ac_compile") 2>conftest.er1
17161  ac_status=$?
17162  grep -v '^ *+' conftest.er1 >conftest.err
17163  rm -f conftest.er1
17164  cat conftest.err >&5
17165  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17166  (exit $ac_status); } && {
17167	 test -z "$ac_c_werror_flag" ||
17168	 test ! -s conftest.err
17169       } && test -s conftest.$ac_objext; then
17170  ac_cv_have_decl_getrusage=yes
17171else
17172  echo "$as_me: failed program was:" >&5
17173sed 's/^/| /' conftest.$ac_ext >&5
17174
17175	ac_cv_have_decl_getrusage=no
17176fi
17177
17178rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17179fi
17180{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_getrusage" >&5
17181echo "${ECHO_T}$ac_cv_have_decl_getrusage" >&6; }
17182if test $ac_cv_have_decl_getrusage = yes; then
17183
17184for ac_func in getrusage
17185do
17186as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17187{ echo "$as_me:$LINENO: checking for $ac_func" >&5
17188echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17189if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17190  echo $ECHO_N "(cached) $ECHO_C" >&6
17191else
17192  cat >conftest.$ac_ext <<_ACEOF
17193/* confdefs.h.  */
17194_ACEOF
17195cat confdefs.h >>conftest.$ac_ext
17196cat >>conftest.$ac_ext <<_ACEOF
17197/* end confdefs.h.  */
17198/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17199   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17200#define $ac_func innocuous_$ac_func
17201
17202/* System header to define __stub macros and hopefully few prototypes,
17203    which can conflict with char $ac_func (); below.
17204    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17205    <limits.h> exists even on freestanding compilers.  */
17206
17207#ifdef __STDC__
17208# include <limits.h>
17209#else
17210# include <assert.h>
17211#endif
17212
17213#undef $ac_func
17214
17215/* Override any GCC internal prototype to avoid an error.
17216   Use char because int might match the return type of a GCC
17217   builtin and then its argument prototype would still apply.  */
17218#ifdef __cplusplus
17219extern "C"
17220#endif
17221char $ac_func ();
17222/* The GNU C library defines this for functions which it implements
17223    to always fail with ENOSYS.  Some functions are actually named
17224    something starting with __ and the normal name is an alias.  */
17225#if defined __stub_$ac_func || defined __stub___$ac_func
17226choke me
17227#endif
17228
17229int
17230main ()
17231{
17232return $ac_func ();
17233  ;
17234  return 0;
17235}
17236_ACEOF
17237rm -f conftest.$ac_objext conftest$ac_exeext
17238if { (ac_try="$ac_link"
17239case "(($ac_try" in
17240  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17241  *) ac_try_echo=$ac_try;;
17242esac
17243eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17244  (eval "$ac_link") 2>conftest.er1
17245  ac_status=$?
17246  grep -v '^ *+' conftest.er1 >conftest.err
17247  rm -f conftest.er1
17248  cat conftest.err >&5
17249  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17250  (exit $ac_status); } && {
17251	 test -z "$ac_c_werror_flag" ||
17252	 test ! -s conftest.err
17253       } && test -s conftest$ac_exeext &&
17254       $as_test_x conftest$ac_exeext; then
17255  eval "$as_ac_var=yes"
17256else
17257  echo "$as_me: failed program was:" >&5
17258sed 's/^/| /' conftest.$ac_ext >&5
17259
17260	eval "$as_ac_var=no"
17261fi
17262
17263rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17264      conftest$ac_exeext conftest.$ac_ext
17265fi
17266ac_res=`eval echo '${'$as_ac_var'}'`
17267	       { echo "$as_me:$LINENO: result: $ac_res" >&5
17268echo "${ECHO_T}$ac_res" >&6; }
17269if test `eval echo '${'$as_ac_var'}'` = yes; then
17270  cat >>confdefs.h <<_ACEOF
17271#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17272_ACEOF
17273
17274fi
17275done
17276
17277fi
17278
17279{ echo "$as_me:$LINENO: checking whether strsep is declared" >&5
17280echo $ECHO_N "checking whether strsep is declared... $ECHO_C" >&6; }
17281if test "${ac_cv_have_decl_strsep+set}" = set; then
17282  echo $ECHO_N "(cached) $ECHO_C" >&6
17283else
17284  cat >conftest.$ac_ext <<_ACEOF
17285/* confdefs.h.  */
17286_ACEOF
17287cat confdefs.h >>conftest.$ac_ext
17288cat >>conftest.$ac_ext <<_ACEOF
17289/* end confdefs.h.  */
17290
17291#ifdef HAVE_STRING_H
17292# include <string.h>
17293#endif
17294
17295
17296int
17297main ()
17298{
17299#ifndef strsep
17300  (void) strsep;
17301#endif
17302
17303  ;
17304  return 0;
17305}
17306_ACEOF
17307rm -f conftest.$ac_objext
17308if { (ac_try="$ac_compile"
17309case "(($ac_try" in
17310  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17311  *) ac_try_echo=$ac_try;;
17312esac
17313eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17314  (eval "$ac_compile") 2>conftest.er1
17315  ac_status=$?
17316  grep -v '^ *+' conftest.er1 >conftest.err
17317  rm -f conftest.er1
17318  cat conftest.err >&5
17319  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17320  (exit $ac_status); } && {
17321	 test -z "$ac_c_werror_flag" ||
17322	 test ! -s conftest.err
17323       } && test -s conftest.$ac_objext; then
17324  ac_cv_have_decl_strsep=yes
17325else
17326  echo "$as_me: failed program was:" >&5
17327sed 's/^/| /' conftest.$ac_ext >&5
17328
17329	ac_cv_have_decl_strsep=no
17330fi
17331
17332rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17333fi
17334{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_strsep" >&5
17335echo "${ECHO_T}$ac_cv_have_decl_strsep" >&6; }
17336if test $ac_cv_have_decl_strsep = yes; then
17337
17338for ac_func in strsep
17339do
17340as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17341{ echo "$as_me:$LINENO: checking for $ac_func" >&5
17342echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17343if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17344  echo $ECHO_N "(cached) $ECHO_C" >&6
17345else
17346  cat >conftest.$ac_ext <<_ACEOF
17347/* confdefs.h.  */
17348_ACEOF
17349cat confdefs.h >>conftest.$ac_ext
17350cat >>conftest.$ac_ext <<_ACEOF
17351/* end confdefs.h.  */
17352/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17353   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17354#define $ac_func innocuous_$ac_func
17355
17356/* System header to define __stub macros and hopefully few prototypes,
17357    which can conflict with char $ac_func (); below.
17358    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17359    <limits.h> exists even on freestanding compilers.  */
17360
17361#ifdef __STDC__
17362# include <limits.h>
17363#else
17364# include <assert.h>
17365#endif
17366
17367#undef $ac_func
17368
17369/* Override any GCC internal prototype to avoid an error.
17370   Use char because int might match the return type of a GCC
17371   builtin and then its argument prototype would still apply.  */
17372#ifdef __cplusplus
17373extern "C"
17374#endif
17375char $ac_func ();
17376/* The GNU C library defines this for functions which it implements
17377    to always fail with ENOSYS.  Some functions are actually named
17378    something starting with __ and the normal name is an alias.  */
17379#if defined __stub_$ac_func || defined __stub___$ac_func
17380choke me
17381#endif
17382
17383int
17384main ()
17385{
17386return $ac_func ();
17387  ;
17388  return 0;
17389}
17390_ACEOF
17391rm -f conftest.$ac_objext conftest$ac_exeext
17392if { (ac_try="$ac_link"
17393case "(($ac_try" in
17394  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17395  *) ac_try_echo=$ac_try;;
17396esac
17397eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17398  (eval "$ac_link") 2>conftest.er1
17399  ac_status=$?
17400  grep -v '^ *+' conftest.er1 >conftest.err
17401  rm -f conftest.er1
17402  cat conftest.err >&5
17403  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17404  (exit $ac_status); } && {
17405	 test -z "$ac_c_werror_flag" ||
17406	 test ! -s conftest.err
17407       } && test -s conftest$ac_exeext &&
17408       $as_test_x conftest$ac_exeext; then
17409  eval "$as_ac_var=yes"
17410else
17411  echo "$as_me: failed program was:" >&5
17412sed 's/^/| /' conftest.$ac_ext >&5
17413
17414	eval "$as_ac_var=no"
17415fi
17416
17417rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17418      conftest$ac_exeext conftest.$ac_ext
17419fi
17420ac_res=`eval echo '${'$as_ac_var'}'`
17421	       { echo "$as_me:$LINENO: result: $ac_res" >&5
17422echo "${ECHO_T}$ac_res" >&6; }
17423if test `eval echo '${'$as_ac_var'}'` = yes; then
17424  cat >>confdefs.h <<_ACEOF
17425#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17426_ACEOF
17427
17428fi
17429done
17430
17431fi
17432
17433
17434{ echo "$as_me:$LINENO: checking whether tcsendbreak is declared" >&5
17435echo $ECHO_N "checking whether tcsendbreak is declared... $ECHO_C" >&6; }
17436if test "${ac_cv_have_decl_tcsendbreak+set}" = set; then
17437  echo $ECHO_N "(cached) $ECHO_C" >&6
17438else
17439  cat >conftest.$ac_ext <<_ACEOF
17440/* confdefs.h.  */
17441_ACEOF
17442cat confdefs.h >>conftest.$ac_ext
17443cat >>conftest.$ac_ext <<_ACEOF
17444/* end confdefs.h.  */
17445#include <termios.h>
17446
17447
17448int
17449main ()
17450{
17451#ifndef tcsendbreak
17452  (void) tcsendbreak;
17453#endif
17454
17455  ;
17456  return 0;
17457}
17458_ACEOF
17459rm -f conftest.$ac_objext
17460if { (ac_try="$ac_compile"
17461case "(($ac_try" in
17462  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17463  *) ac_try_echo=$ac_try;;
17464esac
17465eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17466  (eval "$ac_compile") 2>conftest.er1
17467  ac_status=$?
17468  grep -v '^ *+' conftest.er1 >conftest.err
17469  rm -f conftest.er1
17470  cat conftest.err >&5
17471  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17472  (exit $ac_status); } && {
17473	 test -z "$ac_c_werror_flag" ||
17474	 test ! -s conftest.err
17475       } && test -s conftest.$ac_objext; then
17476  ac_cv_have_decl_tcsendbreak=yes
17477else
17478  echo "$as_me: failed program was:" >&5
17479sed 's/^/| /' conftest.$ac_ext >&5
17480
17481	ac_cv_have_decl_tcsendbreak=no
17482fi
17483
17484rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17485fi
17486{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_tcsendbreak" >&5
17487echo "${ECHO_T}$ac_cv_have_decl_tcsendbreak" >&6; }
17488if test $ac_cv_have_decl_tcsendbreak = yes; then
17489  cat >>confdefs.h <<\_ACEOF
17490#define HAVE_TCSENDBREAK 1
17491_ACEOF
17492
17493else
17494
17495for ac_func in tcsendbreak
17496do
17497as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
17498{ echo "$as_me:$LINENO: checking for $ac_func" >&5
17499echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
17500if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
17501  echo $ECHO_N "(cached) $ECHO_C" >&6
17502else
17503  cat >conftest.$ac_ext <<_ACEOF
17504/* confdefs.h.  */
17505_ACEOF
17506cat confdefs.h >>conftest.$ac_ext
17507cat >>conftest.$ac_ext <<_ACEOF
17508/* end confdefs.h.  */
17509/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
17510   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
17511#define $ac_func innocuous_$ac_func
17512
17513/* System header to define __stub macros and hopefully few prototypes,
17514    which can conflict with char $ac_func (); below.
17515    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
17516    <limits.h> exists even on freestanding compilers.  */
17517
17518#ifdef __STDC__
17519# include <limits.h>
17520#else
17521# include <assert.h>
17522#endif
17523
17524#undef $ac_func
17525
17526/* Override any GCC internal prototype to avoid an error.
17527   Use char because int might match the return type of a GCC
17528   builtin and then its argument prototype would still apply.  */
17529#ifdef __cplusplus
17530extern "C"
17531#endif
17532char $ac_func ();
17533/* The GNU C library defines this for functions which it implements
17534    to always fail with ENOSYS.  Some functions are actually named
17535    something starting with __ and the normal name is an alias.  */
17536#if defined __stub_$ac_func || defined __stub___$ac_func
17537choke me
17538#endif
17539
17540int
17541main ()
17542{
17543return $ac_func ();
17544  ;
17545  return 0;
17546}
17547_ACEOF
17548rm -f conftest.$ac_objext conftest$ac_exeext
17549if { (ac_try="$ac_link"
17550case "(($ac_try" in
17551  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17552  *) ac_try_echo=$ac_try;;
17553esac
17554eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17555  (eval "$ac_link") 2>conftest.er1
17556  ac_status=$?
17557  grep -v '^ *+' conftest.er1 >conftest.err
17558  rm -f conftest.er1
17559  cat conftest.err >&5
17560  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17561  (exit $ac_status); } && {
17562	 test -z "$ac_c_werror_flag" ||
17563	 test ! -s conftest.err
17564       } && test -s conftest$ac_exeext &&
17565       $as_test_x conftest$ac_exeext; then
17566  eval "$as_ac_var=yes"
17567else
17568  echo "$as_me: failed program was:" >&5
17569sed 's/^/| /' conftest.$ac_ext >&5
17570
17571	eval "$as_ac_var=no"
17572fi
17573
17574rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17575      conftest$ac_exeext conftest.$ac_ext
17576fi
17577ac_res=`eval echo '${'$as_ac_var'}'`
17578	       { echo "$as_me:$LINENO: result: $ac_res" >&5
17579echo "${ECHO_T}$ac_res" >&6; }
17580if test `eval echo '${'$as_ac_var'}'` = yes; then
17581  cat >>confdefs.h <<_ACEOF
17582#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
17583_ACEOF
17584
17585fi
17586done
17587
17588fi
17589
17590
17591{ echo "$as_me:$LINENO: checking whether h_errno is declared" >&5
17592echo $ECHO_N "checking whether h_errno is declared... $ECHO_C" >&6; }
17593if test "${ac_cv_have_decl_h_errno+set}" = set; then
17594  echo $ECHO_N "(cached) $ECHO_C" >&6
17595else
17596  cat >conftest.$ac_ext <<_ACEOF
17597/* confdefs.h.  */
17598_ACEOF
17599cat confdefs.h >>conftest.$ac_ext
17600cat >>conftest.$ac_ext <<_ACEOF
17601/* end confdefs.h.  */
17602#include <netdb.h>
17603
17604int
17605main ()
17606{
17607#ifndef h_errno
17608  (void) h_errno;
17609#endif
17610
17611  ;
17612  return 0;
17613}
17614_ACEOF
17615rm -f conftest.$ac_objext
17616if { (ac_try="$ac_compile"
17617case "(($ac_try" in
17618  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17619  *) ac_try_echo=$ac_try;;
17620esac
17621eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17622  (eval "$ac_compile") 2>conftest.er1
17623  ac_status=$?
17624  grep -v '^ *+' conftest.er1 >conftest.err
17625  rm -f conftest.er1
17626  cat conftest.err >&5
17627  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17628  (exit $ac_status); } && {
17629	 test -z "$ac_c_werror_flag" ||
17630	 test ! -s conftest.err
17631       } && test -s conftest.$ac_objext; then
17632  ac_cv_have_decl_h_errno=yes
17633else
17634  echo "$as_me: failed program was:" >&5
17635sed 's/^/| /' conftest.$ac_ext >&5
17636
17637	ac_cv_have_decl_h_errno=no
17638fi
17639
17640rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17641fi
17642{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_h_errno" >&5
17643echo "${ECHO_T}$ac_cv_have_decl_h_errno" >&6; }
17644if test $ac_cv_have_decl_h_errno = yes; then
17645
17646cat >>confdefs.h <<_ACEOF
17647#define HAVE_DECL_H_ERRNO 1
17648_ACEOF
17649
17650
17651else
17652  cat >>confdefs.h <<_ACEOF
17653#define HAVE_DECL_H_ERRNO 0
17654_ACEOF
17655
17656
17657fi
17658
17659
17660
17661{ echo "$as_me:$LINENO: checking whether SHUT_RD is declared" >&5
17662echo $ECHO_N "checking whether SHUT_RD is declared... $ECHO_C" >&6; }
17663if test "${ac_cv_have_decl_SHUT_RD+set}" = set; then
17664  echo $ECHO_N "(cached) $ECHO_C" >&6
17665else
17666  cat >conftest.$ac_ext <<_ACEOF
17667/* confdefs.h.  */
17668_ACEOF
17669cat confdefs.h >>conftest.$ac_ext
17670cat >>conftest.$ac_ext <<_ACEOF
17671/* end confdefs.h.  */
17672
17673#include <sys/types.h>
17674#include <sys/socket.h>
17675
17676
17677int
17678main ()
17679{
17680#ifndef SHUT_RD
17681  (void) SHUT_RD;
17682#endif
17683
17684  ;
17685  return 0;
17686}
17687_ACEOF
17688rm -f conftest.$ac_objext
17689if { (ac_try="$ac_compile"
17690case "(($ac_try" in
17691  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17692  *) ac_try_echo=$ac_try;;
17693esac
17694eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17695  (eval "$ac_compile") 2>conftest.er1
17696  ac_status=$?
17697  grep -v '^ *+' conftest.er1 >conftest.err
17698  rm -f conftest.er1
17699  cat conftest.err >&5
17700  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17701  (exit $ac_status); } && {
17702	 test -z "$ac_c_werror_flag" ||
17703	 test ! -s conftest.err
17704       } && test -s conftest.$ac_objext; then
17705  ac_cv_have_decl_SHUT_RD=yes
17706else
17707  echo "$as_me: failed program was:" >&5
17708sed 's/^/| /' conftest.$ac_ext >&5
17709
17710	ac_cv_have_decl_SHUT_RD=no
17711fi
17712
17713rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17714fi
17715{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_SHUT_RD" >&5
17716echo "${ECHO_T}$ac_cv_have_decl_SHUT_RD" >&6; }
17717if test $ac_cv_have_decl_SHUT_RD = yes; then
17718
17719cat >>confdefs.h <<_ACEOF
17720#define HAVE_DECL_SHUT_RD 1
17721_ACEOF
17722
17723
17724else
17725  cat >>confdefs.h <<_ACEOF
17726#define HAVE_DECL_SHUT_RD 0
17727_ACEOF
17728
17729
17730fi
17731
17732
17733
17734{ echo "$as_me:$LINENO: checking whether O_NONBLOCK is declared" >&5
17735echo $ECHO_N "checking whether O_NONBLOCK is declared... $ECHO_C" >&6; }
17736if test "${ac_cv_have_decl_O_NONBLOCK+set}" = set; then
17737  echo $ECHO_N "(cached) $ECHO_C" >&6
17738else
17739  cat >conftest.$ac_ext <<_ACEOF
17740/* confdefs.h.  */
17741_ACEOF
17742cat confdefs.h >>conftest.$ac_ext
17743cat >>conftest.$ac_ext <<_ACEOF
17744/* end confdefs.h.  */
17745
17746#include <sys/types.h>
17747#ifdef HAVE_SYS_STAT_H
17748# include <sys/stat.h>
17749#endif
17750#ifdef HAVE_FCNTL_H
17751# include <fcntl.h>
17752#endif
17753
17754
17755int
17756main ()
17757{
17758#ifndef O_NONBLOCK
17759  (void) O_NONBLOCK;
17760#endif
17761
17762  ;
17763  return 0;
17764}
17765_ACEOF
17766rm -f conftest.$ac_objext
17767if { (ac_try="$ac_compile"
17768case "(($ac_try" in
17769  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17770  *) ac_try_echo=$ac_try;;
17771esac
17772eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17773  (eval "$ac_compile") 2>conftest.er1
17774  ac_status=$?
17775  grep -v '^ *+' conftest.er1 >conftest.err
17776  rm -f conftest.er1
17777  cat conftest.err >&5
17778  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17779  (exit $ac_status); } && {
17780	 test -z "$ac_c_werror_flag" ||
17781	 test ! -s conftest.err
17782       } && test -s conftest.$ac_objext; then
17783  ac_cv_have_decl_O_NONBLOCK=yes
17784else
17785  echo "$as_me: failed program was:" >&5
17786sed 's/^/| /' conftest.$ac_ext >&5
17787
17788	ac_cv_have_decl_O_NONBLOCK=no
17789fi
17790
17791rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17792fi
17793{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_O_NONBLOCK" >&5
17794echo "${ECHO_T}$ac_cv_have_decl_O_NONBLOCK" >&6; }
17795if test $ac_cv_have_decl_O_NONBLOCK = yes; then
17796
17797cat >>confdefs.h <<_ACEOF
17798#define HAVE_DECL_O_NONBLOCK 1
17799_ACEOF
17800
17801
17802else
17803  cat >>confdefs.h <<_ACEOF
17804#define HAVE_DECL_O_NONBLOCK 0
17805_ACEOF
17806
17807
17808fi
17809
17810
17811
17812{ echo "$as_me:$LINENO: checking whether writev is declared" >&5
17813echo $ECHO_N "checking whether writev is declared... $ECHO_C" >&6; }
17814if test "${ac_cv_have_decl_writev+set}" = set; then
17815  echo $ECHO_N "(cached) $ECHO_C" >&6
17816else
17817  cat >conftest.$ac_ext <<_ACEOF
17818/* confdefs.h.  */
17819_ACEOF
17820cat confdefs.h >>conftest.$ac_ext
17821cat >>conftest.$ac_ext <<_ACEOF
17822/* end confdefs.h.  */
17823
17824#include <sys/types.h>
17825#include <sys/uio.h>
17826#include <unistd.h>
17827
17828
17829int
17830main ()
17831{
17832#ifndef writev
17833  (void) writev;
17834#endif
17835
17836  ;
17837  return 0;
17838}
17839_ACEOF
17840rm -f conftest.$ac_objext
17841if { (ac_try="$ac_compile"
17842case "(($ac_try" in
17843  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17844  *) ac_try_echo=$ac_try;;
17845esac
17846eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17847  (eval "$ac_compile") 2>conftest.er1
17848  ac_status=$?
17849  grep -v '^ *+' conftest.er1 >conftest.err
17850  rm -f conftest.er1
17851  cat conftest.err >&5
17852  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17853  (exit $ac_status); } && {
17854	 test -z "$ac_c_werror_flag" ||
17855	 test ! -s conftest.err
17856       } && test -s conftest.$ac_objext; then
17857  ac_cv_have_decl_writev=yes
17858else
17859  echo "$as_me: failed program was:" >&5
17860sed 's/^/| /' conftest.$ac_ext >&5
17861
17862	ac_cv_have_decl_writev=no
17863fi
17864
17865rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17866fi
17867{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_writev" >&5
17868echo "${ECHO_T}$ac_cv_have_decl_writev" >&6; }
17869if test $ac_cv_have_decl_writev = yes; then
17870
17871cat >>confdefs.h <<_ACEOF
17872#define HAVE_DECL_WRITEV 1
17873_ACEOF
17874
17875
17876else
17877  cat >>confdefs.h <<_ACEOF
17878#define HAVE_DECL_WRITEV 0
17879_ACEOF
17880
17881
17882fi
17883
17884
17885
17886{ echo "$as_me:$LINENO: checking whether MAXSYMLINKS is declared" >&5
17887echo $ECHO_N "checking whether MAXSYMLINKS is declared... $ECHO_C" >&6; }
17888if test "${ac_cv_have_decl_MAXSYMLINKS+set}" = set; then
17889  echo $ECHO_N "(cached) $ECHO_C" >&6
17890else
17891  cat >conftest.$ac_ext <<_ACEOF
17892/* confdefs.h.  */
17893_ACEOF
17894cat confdefs.h >>conftest.$ac_ext
17895cat >>conftest.$ac_ext <<_ACEOF
17896/* end confdefs.h.  */
17897
17898#include <sys/param.h>
17899
17900
17901int
17902main ()
17903{
17904#ifndef MAXSYMLINKS
17905  (void) MAXSYMLINKS;
17906#endif
17907
17908  ;
17909  return 0;
17910}
17911_ACEOF
17912rm -f conftest.$ac_objext
17913if { (ac_try="$ac_compile"
17914case "(($ac_try" in
17915  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17916  *) ac_try_echo=$ac_try;;
17917esac
17918eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17919  (eval "$ac_compile") 2>conftest.er1
17920  ac_status=$?
17921  grep -v '^ *+' conftest.er1 >conftest.err
17922  rm -f conftest.er1
17923  cat conftest.err >&5
17924  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17925  (exit $ac_status); } && {
17926	 test -z "$ac_c_werror_flag" ||
17927	 test ! -s conftest.err
17928       } && test -s conftest.$ac_objext; then
17929  ac_cv_have_decl_MAXSYMLINKS=yes
17930else
17931  echo "$as_me: failed program was:" >&5
17932sed 's/^/| /' conftest.$ac_ext >&5
17933
17934	ac_cv_have_decl_MAXSYMLINKS=no
17935fi
17936
17937rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17938fi
17939{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_MAXSYMLINKS" >&5
17940echo "${ECHO_T}$ac_cv_have_decl_MAXSYMLINKS" >&6; }
17941if test $ac_cv_have_decl_MAXSYMLINKS = yes; then
17942
17943cat >>confdefs.h <<_ACEOF
17944#define HAVE_DECL_MAXSYMLINKS 1
17945_ACEOF
17946
17947
17948else
17949  cat >>confdefs.h <<_ACEOF
17950#define HAVE_DECL_MAXSYMLINKS 0
17951_ACEOF
17952
17953
17954fi
17955
17956
17957
17958{ echo "$as_me:$LINENO: checking whether offsetof is declared" >&5
17959echo $ECHO_N "checking whether offsetof is declared... $ECHO_C" >&6; }
17960if test "${ac_cv_have_decl_offsetof+set}" = set; then
17961  echo $ECHO_N "(cached) $ECHO_C" >&6
17962else
17963  cat >conftest.$ac_ext <<_ACEOF
17964/* confdefs.h.  */
17965_ACEOF
17966cat confdefs.h >>conftest.$ac_ext
17967cat >>conftest.$ac_ext <<_ACEOF
17968/* end confdefs.h.  */
17969
17970#include <stddef.h>
17971
17972
17973int
17974main ()
17975{
17976#ifndef offsetof
17977  (void) offsetof;
17978#endif
17979
17980  ;
17981  return 0;
17982}
17983_ACEOF
17984rm -f conftest.$ac_objext
17985if { (ac_try="$ac_compile"
17986case "(($ac_try" in
17987  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17988  *) ac_try_echo=$ac_try;;
17989esac
17990eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
17991  (eval "$ac_compile") 2>conftest.er1
17992  ac_status=$?
17993  grep -v '^ *+' conftest.er1 >conftest.err
17994  rm -f conftest.er1
17995  cat conftest.err >&5
17996  echo "$as_me:$LINENO: \$? = $ac_status" >&5
17997  (exit $ac_status); } && {
17998	 test -z "$ac_c_werror_flag" ||
17999	 test ! -s conftest.err
18000       } && test -s conftest.$ac_objext; then
18001  ac_cv_have_decl_offsetof=yes
18002else
18003  echo "$as_me: failed program was:" >&5
18004sed 's/^/| /' conftest.$ac_ext >&5
18005
18006	ac_cv_have_decl_offsetof=no
18007fi
18008
18009rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18010fi
18011{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_offsetof" >&5
18012echo "${ECHO_T}$ac_cv_have_decl_offsetof" >&6; }
18013if test $ac_cv_have_decl_offsetof = yes; then
18014
18015cat >>confdefs.h <<_ACEOF
18016#define HAVE_DECL_OFFSETOF 1
18017_ACEOF
18018
18019
18020else
18021  cat >>confdefs.h <<_ACEOF
18022#define HAVE_DECL_OFFSETOF 0
18023_ACEOF
18024
18025
18026fi
18027
18028
18029
18030# extra bits for select(2)
18031{ echo "$as_me:$LINENO: checking whether howmany is declared" >&5
18032echo $ECHO_N "checking whether howmany is declared... $ECHO_C" >&6; }
18033if test "${ac_cv_have_decl_howmany+set}" = set; then
18034  echo $ECHO_N "(cached) $ECHO_C" >&6
18035else
18036  cat >conftest.$ac_ext <<_ACEOF
18037/* confdefs.h.  */
18038_ACEOF
18039cat confdefs.h >>conftest.$ac_ext
18040cat >>conftest.$ac_ext <<_ACEOF
18041/* end confdefs.h.  */
18042
18043#include <sys/param.h>
18044#include <sys/types.h>
18045#ifdef HAVE_SYS_SYSMACROS_H
18046#include <sys/sysmacros.h>
18047#endif
18048#ifdef HAVE_SYS_SELECT_H
18049#include <sys/select.h>
18050#endif
18051#ifdef HAVE_SYS_TIME_H
18052#include <sys/time.h>
18053#endif
18054#ifdef HAVE_UNISTD_H
18055#include <unistd.h>
18056#endif
18057
18058
18059int
18060main ()
18061{
18062#ifndef howmany
18063  (void) howmany;
18064#endif
18065
18066  ;
18067  return 0;
18068}
18069_ACEOF
18070rm -f conftest.$ac_objext
18071if { (ac_try="$ac_compile"
18072case "(($ac_try" in
18073  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18074  *) ac_try_echo=$ac_try;;
18075esac
18076eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18077  (eval "$ac_compile") 2>conftest.er1
18078  ac_status=$?
18079  grep -v '^ *+' conftest.er1 >conftest.err
18080  rm -f conftest.er1
18081  cat conftest.err >&5
18082  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18083  (exit $ac_status); } && {
18084	 test -z "$ac_c_werror_flag" ||
18085	 test ! -s conftest.err
18086       } && test -s conftest.$ac_objext; then
18087  ac_cv_have_decl_howmany=yes
18088else
18089  echo "$as_me: failed program was:" >&5
18090sed 's/^/| /' conftest.$ac_ext >&5
18091
18092	ac_cv_have_decl_howmany=no
18093fi
18094
18095rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18096fi
18097{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_howmany" >&5
18098echo "${ECHO_T}$ac_cv_have_decl_howmany" >&6; }
18099if test $ac_cv_have_decl_howmany = yes; then
18100
18101cat >>confdefs.h <<_ACEOF
18102#define HAVE_DECL_HOWMANY 1
18103_ACEOF
18104
18105
18106else
18107  cat >>confdefs.h <<_ACEOF
18108#define HAVE_DECL_HOWMANY 0
18109_ACEOF
18110
18111
18112fi
18113{ echo "$as_me:$LINENO: checking whether NFDBITS is declared" >&5
18114echo $ECHO_N "checking whether NFDBITS is declared... $ECHO_C" >&6; }
18115if test "${ac_cv_have_decl_NFDBITS+set}" = set; then
18116  echo $ECHO_N "(cached) $ECHO_C" >&6
18117else
18118  cat >conftest.$ac_ext <<_ACEOF
18119/* confdefs.h.  */
18120_ACEOF
18121cat confdefs.h >>conftest.$ac_ext
18122cat >>conftest.$ac_ext <<_ACEOF
18123/* end confdefs.h.  */
18124
18125#include <sys/param.h>
18126#include <sys/types.h>
18127#ifdef HAVE_SYS_SYSMACROS_H
18128#include <sys/sysmacros.h>
18129#endif
18130#ifdef HAVE_SYS_SELECT_H
18131#include <sys/select.h>
18132#endif
18133#ifdef HAVE_SYS_TIME_H
18134#include <sys/time.h>
18135#endif
18136#ifdef HAVE_UNISTD_H
18137#include <unistd.h>
18138#endif
18139
18140
18141int
18142main ()
18143{
18144#ifndef NFDBITS
18145  (void) NFDBITS;
18146#endif
18147
18148  ;
18149  return 0;
18150}
18151_ACEOF
18152rm -f conftest.$ac_objext
18153if { (ac_try="$ac_compile"
18154case "(($ac_try" in
18155  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18156  *) ac_try_echo=$ac_try;;
18157esac
18158eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18159  (eval "$ac_compile") 2>conftest.er1
18160  ac_status=$?
18161  grep -v '^ *+' conftest.er1 >conftest.err
18162  rm -f conftest.er1
18163  cat conftest.err >&5
18164  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18165  (exit $ac_status); } && {
18166	 test -z "$ac_c_werror_flag" ||
18167	 test ! -s conftest.err
18168       } && test -s conftest.$ac_objext; then
18169  ac_cv_have_decl_NFDBITS=yes
18170else
18171  echo "$as_me: failed program was:" >&5
18172sed 's/^/| /' conftest.$ac_ext >&5
18173
18174	ac_cv_have_decl_NFDBITS=no
18175fi
18176
18177rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18178fi
18179{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_NFDBITS" >&5
18180echo "${ECHO_T}$ac_cv_have_decl_NFDBITS" >&6; }
18181if test $ac_cv_have_decl_NFDBITS = yes; then
18182
18183cat >>confdefs.h <<_ACEOF
18184#define HAVE_DECL_NFDBITS 1
18185_ACEOF
18186
18187
18188else
18189  cat >>confdefs.h <<_ACEOF
18190#define HAVE_DECL_NFDBITS 0
18191_ACEOF
18192
18193
18194fi
18195
18196
18197{ echo "$as_me:$LINENO: checking for fd_mask" >&5
18198echo $ECHO_N "checking for fd_mask... $ECHO_C" >&6; }
18199if test "${ac_cv_type_fd_mask+set}" = set; then
18200  echo $ECHO_N "(cached) $ECHO_C" >&6
18201else
18202  cat >conftest.$ac_ext <<_ACEOF
18203/* confdefs.h.  */
18204_ACEOF
18205cat confdefs.h >>conftest.$ac_ext
18206cat >>conftest.$ac_ext <<_ACEOF
18207/* end confdefs.h.  */
18208
18209#include <sys/param.h>
18210#include <sys/types.h>
18211#ifdef HAVE_SYS_SELECT_H
18212#include <sys/select.h>
18213#endif
18214#ifdef HAVE_SYS_TIME_H
18215#include <sys/time.h>
18216#endif
18217#ifdef HAVE_UNISTD_H
18218#include <unistd.h>
18219#endif
18220
18221
18222typedef fd_mask ac__type_new_;
18223int
18224main ()
18225{
18226if ((ac__type_new_ *) 0)
18227  return 0;
18228if (sizeof (ac__type_new_))
18229  return 0;
18230  ;
18231  return 0;
18232}
18233_ACEOF
18234rm -f conftest.$ac_objext
18235if { (ac_try="$ac_compile"
18236case "(($ac_try" in
18237  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18238  *) ac_try_echo=$ac_try;;
18239esac
18240eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18241  (eval "$ac_compile") 2>conftest.er1
18242  ac_status=$?
18243  grep -v '^ *+' conftest.er1 >conftest.err
18244  rm -f conftest.er1
18245  cat conftest.err >&5
18246  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18247  (exit $ac_status); } && {
18248	 test -z "$ac_c_werror_flag" ||
18249	 test ! -s conftest.err
18250       } && test -s conftest.$ac_objext; then
18251  ac_cv_type_fd_mask=yes
18252else
18253  echo "$as_me: failed program was:" >&5
18254sed 's/^/| /' conftest.$ac_ext >&5
18255
18256	ac_cv_type_fd_mask=no
18257fi
18258
18259rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18260fi
18261{ echo "$as_me:$LINENO: result: $ac_cv_type_fd_mask" >&5
18262echo "${ECHO_T}$ac_cv_type_fd_mask" >&6; }
18263if test $ac_cv_type_fd_mask = yes; then
18264
18265cat >>confdefs.h <<_ACEOF
18266#define HAVE_FD_MASK 1
18267_ACEOF
18268
18269
18270fi
18271
18272
18273
18274for ac_func in setresuid
18275do
18276as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18277{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18278echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18279if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18280  echo $ECHO_N "(cached) $ECHO_C" >&6
18281else
18282  cat >conftest.$ac_ext <<_ACEOF
18283/* confdefs.h.  */
18284_ACEOF
18285cat confdefs.h >>conftest.$ac_ext
18286cat >>conftest.$ac_ext <<_ACEOF
18287/* end confdefs.h.  */
18288/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18289   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18290#define $ac_func innocuous_$ac_func
18291
18292/* System header to define __stub macros and hopefully few prototypes,
18293    which can conflict with char $ac_func (); below.
18294    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18295    <limits.h> exists even on freestanding compilers.  */
18296
18297#ifdef __STDC__
18298# include <limits.h>
18299#else
18300# include <assert.h>
18301#endif
18302
18303#undef $ac_func
18304
18305/* Override any GCC internal prototype to avoid an error.
18306   Use char because int might match the return type of a GCC
18307   builtin and then its argument prototype would still apply.  */
18308#ifdef __cplusplus
18309extern "C"
18310#endif
18311char $ac_func ();
18312/* The GNU C library defines this for functions which it implements
18313    to always fail with ENOSYS.  Some functions are actually named
18314    something starting with __ and the normal name is an alias.  */
18315#if defined __stub_$ac_func || defined __stub___$ac_func
18316choke me
18317#endif
18318
18319int
18320main ()
18321{
18322return $ac_func ();
18323  ;
18324  return 0;
18325}
18326_ACEOF
18327rm -f conftest.$ac_objext conftest$ac_exeext
18328if { (ac_try="$ac_link"
18329case "(($ac_try" in
18330  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18331  *) ac_try_echo=$ac_try;;
18332esac
18333eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18334  (eval "$ac_link") 2>conftest.er1
18335  ac_status=$?
18336  grep -v '^ *+' conftest.er1 >conftest.err
18337  rm -f conftest.er1
18338  cat conftest.err >&5
18339  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18340  (exit $ac_status); } && {
18341	 test -z "$ac_c_werror_flag" ||
18342	 test ! -s conftest.err
18343       } && test -s conftest$ac_exeext &&
18344       $as_test_x conftest$ac_exeext; then
18345  eval "$as_ac_var=yes"
18346else
18347  echo "$as_me: failed program was:" >&5
18348sed 's/^/| /' conftest.$ac_ext >&5
18349
18350	eval "$as_ac_var=no"
18351fi
18352
18353rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18354      conftest$ac_exeext conftest.$ac_ext
18355fi
18356ac_res=`eval echo '${'$as_ac_var'}'`
18357	       { echo "$as_me:$LINENO: result: $ac_res" >&5
18358echo "${ECHO_T}$ac_res" >&6; }
18359if test `eval echo '${'$as_ac_var'}'` = yes; then
18360  cat >>confdefs.h <<_ACEOF
18361#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18362_ACEOF
18363
18364		{ echo "$as_me:$LINENO: checking if setresuid seems to work" >&5
18365echo $ECHO_N "checking if setresuid seems to work... $ECHO_C" >&6; }
18366	if test "$cross_compiling" = yes; then
18367  { echo "$as_me:$LINENO: WARNING: cross compiling: not checking setresuid" >&5
18368echo "$as_me: WARNING: cross compiling: not checking setresuid" >&2;}
18369
18370else
18371  cat >conftest.$ac_ext <<_ACEOF
18372/* confdefs.h.  */
18373_ACEOF
18374cat confdefs.h >>conftest.$ac_ext
18375cat >>conftest.$ac_ext <<_ACEOF
18376/* end confdefs.h.  */
18377
18378#include <stdlib.h>
18379#include <errno.h>
18380
18381int
18382main ()
18383{
18384
18385	errno=0;
18386	setresuid(0,0,0);
18387	if (errno==ENOSYS)
18388		exit(1);
18389	else
18390		exit(0);
18391
18392  ;
18393  return 0;
18394}
18395_ACEOF
18396rm -f conftest$ac_exeext
18397if { (ac_try="$ac_link"
18398case "(($ac_try" in
18399  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18400  *) ac_try_echo=$ac_try;;
18401esac
18402eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18403  (eval "$ac_link") 2>&5
18404  ac_status=$?
18405  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18406  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18407  { (case "(($ac_try" in
18408  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18409  *) ac_try_echo=$ac_try;;
18410esac
18411eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18412  (eval "$ac_try") 2>&5
18413  ac_status=$?
18414  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18415  (exit $ac_status); }; }; then
18416  { echo "$as_me:$LINENO: result: yes" >&5
18417echo "${ECHO_T}yes" >&6; }
18418else
18419  echo "$as_me: program exited with status $ac_status" >&5
18420echo "$as_me: failed program was:" >&5
18421sed 's/^/| /' conftest.$ac_ext >&5
18422
18423( exit $ac_status )
18424
18425cat >>confdefs.h <<\_ACEOF
18426#define BROKEN_SETRESUID 1
18427_ACEOF
18428
18429		 { echo "$as_me:$LINENO: result: not implemented" >&5
18430echo "${ECHO_T}not implemented" >&6; }
18431fi
18432rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18433fi
18434
18435
18436
18437fi
18438done
18439
18440
18441
18442for ac_func in setresgid
18443do
18444as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18445{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18446echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18447if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18448  echo $ECHO_N "(cached) $ECHO_C" >&6
18449else
18450  cat >conftest.$ac_ext <<_ACEOF
18451/* confdefs.h.  */
18452_ACEOF
18453cat confdefs.h >>conftest.$ac_ext
18454cat >>conftest.$ac_ext <<_ACEOF
18455/* end confdefs.h.  */
18456/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18457   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18458#define $ac_func innocuous_$ac_func
18459
18460/* System header to define __stub macros and hopefully few prototypes,
18461    which can conflict with char $ac_func (); below.
18462    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18463    <limits.h> exists even on freestanding compilers.  */
18464
18465#ifdef __STDC__
18466# include <limits.h>
18467#else
18468# include <assert.h>
18469#endif
18470
18471#undef $ac_func
18472
18473/* Override any GCC internal prototype to avoid an error.
18474   Use char because int might match the return type of a GCC
18475   builtin and then its argument prototype would still apply.  */
18476#ifdef __cplusplus
18477extern "C"
18478#endif
18479char $ac_func ();
18480/* The GNU C library defines this for functions which it implements
18481    to always fail with ENOSYS.  Some functions are actually named
18482    something starting with __ and the normal name is an alias.  */
18483#if defined __stub_$ac_func || defined __stub___$ac_func
18484choke me
18485#endif
18486
18487int
18488main ()
18489{
18490return $ac_func ();
18491  ;
18492  return 0;
18493}
18494_ACEOF
18495rm -f conftest.$ac_objext conftest$ac_exeext
18496if { (ac_try="$ac_link"
18497case "(($ac_try" in
18498  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18499  *) ac_try_echo=$ac_try;;
18500esac
18501eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18502  (eval "$ac_link") 2>conftest.er1
18503  ac_status=$?
18504  grep -v '^ *+' conftest.er1 >conftest.err
18505  rm -f conftest.er1
18506  cat conftest.err >&5
18507  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18508  (exit $ac_status); } && {
18509	 test -z "$ac_c_werror_flag" ||
18510	 test ! -s conftest.err
18511       } && test -s conftest$ac_exeext &&
18512       $as_test_x conftest$ac_exeext; then
18513  eval "$as_ac_var=yes"
18514else
18515  echo "$as_me: failed program was:" >&5
18516sed 's/^/| /' conftest.$ac_ext >&5
18517
18518	eval "$as_ac_var=no"
18519fi
18520
18521rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18522      conftest$ac_exeext conftest.$ac_ext
18523fi
18524ac_res=`eval echo '${'$as_ac_var'}'`
18525	       { echo "$as_me:$LINENO: result: $ac_res" >&5
18526echo "${ECHO_T}$ac_res" >&6; }
18527if test `eval echo '${'$as_ac_var'}'` = yes; then
18528  cat >>confdefs.h <<_ACEOF
18529#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18530_ACEOF
18531
18532		{ echo "$as_me:$LINENO: checking if setresgid seems to work" >&5
18533echo $ECHO_N "checking if setresgid seems to work... $ECHO_C" >&6; }
18534	if test "$cross_compiling" = yes; then
18535  { echo "$as_me:$LINENO: WARNING: cross compiling: not checking setresuid" >&5
18536echo "$as_me: WARNING: cross compiling: not checking setresuid" >&2;}
18537
18538else
18539  cat >conftest.$ac_ext <<_ACEOF
18540/* confdefs.h.  */
18541_ACEOF
18542cat confdefs.h >>conftest.$ac_ext
18543cat >>conftest.$ac_ext <<_ACEOF
18544/* end confdefs.h.  */
18545
18546#include <stdlib.h>
18547#include <errno.h>
18548
18549int
18550main ()
18551{
18552
18553	errno=0;
18554	setresgid(0,0,0);
18555	if (errno==ENOSYS)
18556		exit(1);
18557	else
18558		exit(0);
18559
18560  ;
18561  return 0;
18562}
18563_ACEOF
18564rm -f conftest$ac_exeext
18565if { (ac_try="$ac_link"
18566case "(($ac_try" in
18567  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18568  *) ac_try_echo=$ac_try;;
18569esac
18570eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18571  (eval "$ac_link") 2>&5
18572  ac_status=$?
18573  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18574  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18575  { (case "(($ac_try" in
18576  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18577  *) ac_try_echo=$ac_try;;
18578esac
18579eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18580  (eval "$ac_try") 2>&5
18581  ac_status=$?
18582  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18583  (exit $ac_status); }; }; then
18584  { echo "$as_me:$LINENO: result: yes" >&5
18585echo "${ECHO_T}yes" >&6; }
18586else
18587  echo "$as_me: program exited with status $ac_status" >&5
18588echo "$as_me: failed program was:" >&5
18589sed 's/^/| /' conftest.$ac_ext >&5
18590
18591( exit $ac_status )
18592
18593cat >>confdefs.h <<\_ACEOF
18594#define BROKEN_SETRESGID 1
18595_ACEOF
18596
18597		 { echo "$as_me:$LINENO: result: not implemented" >&5
18598echo "${ECHO_T}not implemented" >&6; }
18599fi
18600rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18601fi
18602
18603
18604
18605fi
18606done
18607
18608
18609
18610
18611for ac_func in gettimeofday time
18612do
18613as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18614{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18615echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18616if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18617  echo $ECHO_N "(cached) $ECHO_C" >&6
18618else
18619  cat >conftest.$ac_ext <<_ACEOF
18620/* confdefs.h.  */
18621_ACEOF
18622cat confdefs.h >>conftest.$ac_ext
18623cat >>conftest.$ac_ext <<_ACEOF
18624/* end confdefs.h.  */
18625/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18626   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18627#define $ac_func innocuous_$ac_func
18628
18629/* System header to define __stub macros and hopefully few prototypes,
18630    which can conflict with char $ac_func (); below.
18631    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18632    <limits.h> exists even on freestanding compilers.  */
18633
18634#ifdef __STDC__
18635# include <limits.h>
18636#else
18637# include <assert.h>
18638#endif
18639
18640#undef $ac_func
18641
18642/* Override any GCC internal prototype to avoid an error.
18643   Use char because int might match the return type of a GCC
18644   builtin and then its argument prototype would still apply.  */
18645#ifdef __cplusplus
18646extern "C"
18647#endif
18648char $ac_func ();
18649/* The GNU C library defines this for functions which it implements
18650    to always fail with ENOSYS.  Some functions are actually named
18651    something starting with __ and the normal name is an alias.  */
18652#if defined __stub_$ac_func || defined __stub___$ac_func
18653choke me
18654#endif
18655
18656int
18657main ()
18658{
18659return $ac_func ();
18660  ;
18661  return 0;
18662}
18663_ACEOF
18664rm -f conftest.$ac_objext conftest$ac_exeext
18665if { (ac_try="$ac_link"
18666case "(($ac_try" in
18667  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18668  *) ac_try_echo=$ac_try;;
18669esac
18670eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18671  (eval "$ac_link") 2>conftest.er1
18672  ac_status=$?
18673  grep -v '^ *+' conftest.er1 >conftest.err
18674  rm -f conftest.er1
18675  cat conftest.err >&5
18676  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18677  (exit $ac_status); } && {
18678	 test -z "$ac_c_werror_flag" ||
18679	 test ! -s conftest.err
18680       } && test -s conftest$ac_exeext &&
18681       $as_test_x conftest$ac_exeext; then
18682  eval "$as_ac_var=yes"
18683else
18684  echo "$as_me: failed program was:" >&5
18685sed 's/^/| /' conftest.$ac_ext >&5
18686
18687	eval "$as_ac_var=no"
18688fi
18689
18690rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18691      conftest$ac_exeext conftest.$ac_ext
18692fi
18693ac_res=`eval echo '${'$as_ac_var'}'`
18694	       { echo "$as_me:$LINENO: result: $ac_res" >&5
18695echo "${ECHO_T}$ac_res" >&6; }
18696if test `eval echo '${'$as_ac_var'}'` = yes; then
18697  cat >>confdefs.h <<_ACEOF
18698#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18699_ACEOF
18700
18701fi
18702done
18703
18704
18705
18706
18707
18708
18709
18710for ac_func in endutent getutent getutid getutline pututline setutent
18711do
18712as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18713{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18714echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18715if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18716  echo $ECHO_N "(cached) $ECHO_C" >&6
18717else
18718  cat >conftest.$ac_ext <<_ACEOF
18719/* confdefs.h.  */
18720_ACEOF
18721cat confdefs.h >>conftest.$ac_ext
18722cat >>conftest.$ac_ext <<_ACEOF
18723/* end confdefs.h.  */
18724/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18725   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18726#define $ac_func innocuous_$ac_func
18727
18728/* System header to define __stub macros and hopefully few prototypes,
18729    which can conflict with char $ac_func (); below.
18730    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18731    <limits.h> exists even on freestanding compilers.  */
18732
18733#ifdef __STDC__
18734# include <limits.h>
18735#else
18736# include <assert.h>
18737#endif
18738
18739#undef $ac_func
18740
18741/* Override any GCC internal prototype to avoid an error.
18742   Use char because int might match the return type of a GCC
18743   builtin and then its argument prototype would still apply.  */
18744#ifdef __cplusplus
18745extern "C"
18746#endif
18747char $ac_func ();
18748/* The GNU C library defines this for functions which it implements
18749    to always fail with ENOSYS.  Some functions are actually named
18750    something starting with __ and the normal name is an alias.  */
18751#if defined __stub_$ac_func || defined __stub___$ac_func
18752choke me
18753#endif
18754
18755int
18756main ()
18757{
18758return $ac_func ();
18759  ;
18760  return 0;
18761}
18762_ACEOF
18763rm -f conftest.$ac_objext conftest$ac_exeext
18764if { (ac_try="$ac_link"
18765case "(($ac_try" in
18766  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18767  *) ac_try_echo=$ac_try;;
18768esac
18769eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18770  (eval "$ac_link") 2>conftest.er1
18771  ac_status=$?
18772  grep -v '^ *+' conftest.er1 >conftest.err
18773  rm -f conftest.er1
18774  cat conftest.err >&5
18775  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18776  (exit $ac_status); } && {
18777	 test -z "$ac_c_werror_flag" ||
18778	 test ! -s conftest.err
18779       } && test -s conftest$ac_exeext &&
18780       $as_test_x conftest$ac_exeext; then
18781  eval "$as_ac_var=yes"
18782else
18783  echo "$as_me: failed program was:" >&5
18784sed 's/^/| /' conftest.$ac_ext >&5
18785
18786	eval "$as_ac_var=no"
18787fi
18788
18789rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18790      conftest$ac_exeext conftest.$ac_ext
18791fi
18792ac_res=`eval echo '${'$as_ac_var'}'`
18793	       { echo "$as_me:$LINENO: result: $ac_res" >&5
18794echo "${ECHO_T}$ac_res" >&6; }
18795if test `eval echo '${'$as_ac_var'}'` = yes; then
18796  cat >>confdefs.h <<_ACEOF
18797#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18798_ACEOF
18799
18800fi
18801done
18802
18803
18804for ac_func in utmpname
18805do
18806as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18807{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18808echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18809if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18810  echo $ECHO_N "(cached) $ECHO_C" >&6
18811else
18812  cat >conftest.$ac_ext <<_ACEOF
18813/* confdefs.h.  */
18814_ACEOF
18815cat confdefs.h >>conftest.$ac_ext
18816cat >>conftest.$ac_ext <<_ACEOF
18817/* end confdefs.h.  */
18818/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18819   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18820#define $ac_func innocuous_$ac_func
18821
18822/* System header to define __stub macros and hopefully few prototypes,
18823    which can conflict with char $ac_func (); below.
18824    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18825    <limits.h> exists even on freestanding compilers.  */
18826
18827#ifdef __STDC__
18828# include <limits.h>
18829#else
18830# include <assert.h>
18831#endif
18832
18833#undef $ac_func
18834
18835/* Override any GCC internal prototype to avoid an error.
18836   Use char because int might match the return type of a GCC
18837   builtin and then its argument prototype would still apply.  */
18838#ifdef __cplusplus
18839extern "C"
18840#endif
18841char $ac_func ();
18842/* The GNU C library defines this for functions which it implements
18843    to always fail with ENOSYS.  Some functions are actually named
18844    something starting with __ and the normal name is an alias.  */
18845#if defined __stub_$ac_func || defined __stub___$ac_func
18846choke me
18847#endif
18848
18849int
18850main ()
18851{
18852return $ac_func ();
18853  ;
18854  return 0;
18855}
18856_ACEOF
18857rm -f conftest.$ac_objext conftest$ac_exeext
18858if { (ac_try="$ac_link"
18859case "(($ac_try" in
18860  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18861  *) ac_try_echo=$ac_try;;
18862esac
18863eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18864  (eval "$ac_link") 2>conftest.er1
18865  ac_status=$?
18866  grep -v '^ *+' conftest.er1 >conftest.err
18867  rm -f conftest.er1
18868  cat conftest.err >&5
18869  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18870  (exit $ac_status); } && {
18871	 test -z "$ac_c_werror_flag" ||
18872	 test ! -s conftest.err
18873       } && test -s conftest$ac_exeext &&
18874       $as_test_x conftest$ac_exeext; then
18875  eval "$as_ac_var=yes"
18876else
18877  echo "$as_me: failed program was:" >&5
18878sed 's/^/| /' conftest.$ac_ext >&5
18879
18880	eval "$as_ac_var=no"
18881fi
18882
18883rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18884      conftest$ac_exeext conftest.$ac_ext
18885fi
18886ac_res=`eval echo '${'$as_ac_var'}'`
18887	       { echo "$as_me:$LINENO: result: $ac_res" >&5
18888echo "${ECHO_T}$ac_res" >&6; }
18889if test `eval echo '${'$as_ac_var'}'` = yes; then
18890  cat >>confdefs.h <<_ACEOF
18891#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18892_ACEOF
18893
18894fi
18895done
18896
18897
18898
18899
18900
18901
18902
18903for ac_func in endutxent getutxent getutxid getutxline getutxuser pututxline
18904do
18905as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
18906{ echo "$as_me:$LINENO: checking for $ac_func" >&5
18907echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
18908if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18909  echo $ECHO_N "(cached) $ECHO_C" >&6
18910else
18911  cat >conftest.$ac_ext <<_ACEOF
18912/* confdefs.h.  */
18913_ACEOF
18914cat confdefs.h >>conftest.$ac_ext
18915cat >>conftest.$ac_ext <<_ACEOF
18916/* end confdefs.h.  */
18917/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18918   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18919#define $ac_func innocuous_$ac_func
18920
18921/* System header to define __stub macros and hopefully few prototypes,
18922    which can conflict with char $ac_func (); below.
18923    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18924    <limits.h> exists even on freestanding compilers.  */
18925
18926#ifdef __STDC__
18927# include <limits.h>
18928#else
18929# include <assert.h>
18930#endif
18931
18932#undef $ac_func
18933
18934/* Override any GCC internal prototype to avoid an error.
18935   Use char because int might match the return type of a GCC
18936   builtin and then its argument prototype would still apply.  */
18937#ifdef __cplusplus
18938extern "C"
18939#endif
18940char $ac_func ();
18941/* The GNU C library defines this for functions which it implements
18942    to always fail with ENOSYS.  Some functions are actually named
18943    something starting with __ and the normal name is an alias.  */
18944#if defined __stub_$ac_func || defined __stub___$ac_func
18945choke me
18946#endif
18947
18948int
18949main ()
18950{
18951return $ac_func ();
18952  ;
18953  return 0;
18954}
18955_ACEOF
18956rm -f conftest.$ac_objext conftest$ac_exeext
18957if { (ac_try="$ac_link"
18958case "(($ac_try" in
18959  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18960  *) ac_try_echo=$ac_try;;
18961esac
18962eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
18963  (eval "$ac_link") 2>conftest.er1
18964  ac_status=$?
18965  grep -v '^ *+' conftest.er1 >conftest.err
18966  rm -f conftest.er1
18967  cat conftest.err >&5
18968  echo "$as_me:$LINENO: \$? = $ac_status" >&5
18969  (exit $ac_status); } && {
18970	 test -z "$ac_c_werror_flag" ||
18971	 test ! -s conftest.err
18972       } && test -s conftest$ac_exeext &&
18973       $as_test_x conftest$ac_exeext; then
18974  eval "$as_ac_var=yes"
18975else
18976  echo "$as_me: failed program was:" >&5
18977sed 's/^/| /' conftest.$ac_ext >&5
18978
18979	eval "$as_ac_var=no"
18980fi
18981
18982rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18983      conftest$ac_exeext conftest.$ac_ext
18984fi
18985ac_res=`eval echo '${'$as_ac_var'}'`
18986	       { echo "$as_me:$LINENO: result: $ac_res" >&5
18987echo "${ECHO_T}$ac_res" >&6; }
18988if test `eval echo '${'$as_ac_var'}'` = yes; then
18989  cat >>confdefs.h <<_ACEOF
18990#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
18991_ACEOF
18992
18993fi
18994done
18995
18996
18997
18998
18999for ac_func in setutxdb setutxent utmpxname
19000do
19001as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
19002{ echo "$as_me:$LINENO: checking for $ac_func" >&5
19003echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
19004if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19005  echo $ECHO_N "(cached) $ECHO_C" >&6
19006else
19007  cat >conftest.$ac_ext <<_ACEOF
19008/* confdefs.h.  */
19009_ACEOF
19010cat confdefs.h >>conftest.$ac_ext
19011cat >>conftest.$ac_ext <<_ACEOF
19012/* end confdefs.h.  */
19013/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19014   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19015#define $ac_func innocuous_$ac_func
19016
19017/* System header to define __stub macros and hopefully few prototypes,
19018    which can conflict with char $ac_func (); below.
19019    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19020    <limits.h> exists even on freestanding compilers.  */
19021
19022#ifdef __STDC__
19023# include <limits.h>
19024#else
19025# include <assert.h>
19026#endif
19027
19028#undef $ac_func
19029
19030/* Override any GCC internal prototype to avoid an error.
19031   Use char because int might match the return type of a GCC
19032   builtin and then its argument prototype would still apply.  */
19033#ifdef __cplusplus
19034extern "C"
19035#endif
19036char $ac_func ();
19037/* The GNU C library defines this for functions which it implements
19038    to always fail with ENOSYS.  Some functions are actually named
19039    something starting with __ and the normal name is an alias.  */
19040#if defined __stub_$ac_func || defined __stub___$ac_func
19041choke me
19042#endif
19043
19044int
19045main ()
19046{
19047return $ac_func ();
19048  ;
19049  return 0;
19050}
19051_ACEOF
19052rm -f conftest.$ac_objext conftest$ac_exeext
19053if { (ac_try="$ac_link"
19054case "(($ac_try" in
19055  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19056  *) ac_try_echo=$ac_try;;
19057esac
19058eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19059  (eval "$ac_link") 2>conftest.er1
19060  ac_status=$?
19061  grep -v '^ *+' conftest.er1 >conftest.err
19062  rm -f conftest.er1
19063  cat conftest.err >&5
19064  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19065  (exit $ac_status); } && {
19066	 test -z "$ac_c_werror_flag" ||
19067	 test ! -s conftest.err
19068       } && test -s conftest$ac_exeext &&
19069       $as_test_x conftest$ac_exeext; then
19070  eval "$as_ac_var=yes"
19071else
19072  echo "$as_me: failed program was:" >&5
19073sed 's/^/| /' conftest.$ac_ext >&5
19074
19075	eval "$as_ac_var=no"
19076fi
19077
19078rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19079      conftest$ac_exeext conftest.$ac_ext
19080fi
19081ac_res=`eval echo '${'$as_ac_var'}'`
19082	       { echo "$as_me:$LINENO: result: $ac_res" >&5
19083echo "${ECHO_T}$ac_res" >&6; }
19084if test `eval echo '${'$as_ac_var'}'` = yes; then
19085  cat >>confdefs.h <<_ACEOF
19086#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
19087_ACEOF
19088
19089fi
19090done
19091
19092
19093for ac_func in getlastlogxbyname
19094do
19095as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
19096{ echo "$as_me:$LINENO: checking for $ac_func" >&5
19097echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
19098if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19099  echo $ECHO_N "(cached) $ECHO_C" >&6
19100else
19101  cat >conftest.$ac_ext <<_ACEOF
19102/* confdefs.h.  */
19103_ACEOF
19104cat confdefs.h >>conftest.$ac_ext
19105cat >>conftest.$ac_ext <<_ACEOF
19106/* end confdefs.h.  */
19107/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19108   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19109#define $ac_func innocuous_$ac_func
19110
19111/* System header to define __stub macros and hopefully few prototypes,
19112    which can conflict with char $ac_func (); below.
19113    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19114    <limits.h> exists even on freestanding compilers.  */
19115
19116#ifdef __STDC__
19117# include <limits.h>
19118#else
19119# include <assert.h>
19120#endif
19121
19122#undef $ac_func
19123
19124/* Override any GCC internal prototype to avoid an error.
19125   Use char because int might match the return type of a GCC
19126   builtin and then its argument prototype would still apply.  */
19127#ifdef __cplusplus
19128extern "C"
19129#endif
19130char $ac_func ();
19131/* The GNU C library defines this for functions which it implements
19132    to always fail with ENOSYS.  Some functions are actually named
19133    something starting with __ and the normal name is an alias.  */
19134#if defined __stub_$ac_func || defined __stub___$ac_func
19135choke me
19136#endif
19137
19138int
19139main ()
19140{
19141return $ac_func ();
19142  ;
19143  return 0;
19144}
19145_ACEOF
19146rm -f conftest.$ac_objext conftest$ac_exeext
19147if { (ac_try="$ac_link"
19148case "(($ac_try" in
19149  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19150  *) ac_try_echo=$ac_try;;
19151esac
19152eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19153  (eval "$ac_link") 2>conftest.er1
19154  ac_status=$?
19155  grep -v '^ *+' conftest.er1 >conftest.err
19156  rm -f conftest.er1
19157  cat conftest.err >&5
19158  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19159  (exit $ac_status); } && {
19160	 test -z "$ac_c_werror_flag" ||
19161	 test ! -s conftest.err
19162       } && test -s conftest$ac_exeext &&
19163       $as_test_x conftest$ac_exeext; then
19164  eval "$as_ac_var=yes"
19165else
19166  echo "$as_me: failed program was:" >&5
19167sed 's/^/| /' conftest.$ac_ext >&5
19168
19169	eval "$as_ac_var=no"
19170fi
19171
19172rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19173      conftest$ac_exeext conftest.$ac_ext
19174fi
19175ac_res=`eval echo '${'$as_ac_var'}'`
19176	       { echo "$as_me:$LINENO: result: $ac_res" >&5
19177echo "${ECHO_T}$ac_res" >&6; }
19178if test `eval echo '${'$as_ac_var'}'` = yes; then
19179  cat >>confdefs.h <<_ACEOF
19180#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
19181_ACEOF
19182
19183fi
19184done
19185
19186
19187{ echo "$as_me:$LINENO: checking for daemon" >&5
19188echo $ECHO_N "checking for daemon... $ECHO_C" >&6; }
19189if test "${ac_cv_func_daemon+set}" = set; then
19190  echo $ECHO_N "(cached) $ECHO_C" >&6
19191else
19192  cat >conftest.$ac_ext <<_ACEOF
19193/* confdefs.h.  */
19194_ACEOF
19195cat confdefs.h >>conftest.$ac_ext
19196cat >>conftest.$ac_ext <<_ACEOF
19197/* end confdefs.h.  */
19198/* Define daemon to an innocuous variant, in case <limits.h> declares daemon.
19199   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19200#define daemon innocuous_daemon
19201
19202/* System header to define __stub macros and hopefully few prototypes,
19203    which can conflict with char daemon (); below.
19204    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19205    <limits.h> exists even on freestanding compilers.  */
19206
19207#ifdef __STDC__
19208# include <limits.h>
19209#else
19210# include <assert.h>
19211#endif
19212
19213#undef daemon
19214
19215/* Override any GCC internal prototype to avoid an error.
19216   Use char because int might match the return type of a GCC
19217   builtin and then its argument prototype would still apply.  */
19218#ifdef __cplusplus
19219extern "C"
19220#endif
19221char daemon ();
19222/* The GNU C library defines this for functions which it implements
19223    to always fail with ENOSYS.  Some functions are actually named
19224    something starting with __ and the normal name is an alias.  */
19225#if defined __stub_daemon || defined __stub___daemon
19226choke me
19227#endif
19228
19229int
19230main ()
19231{
19232return daemon ();
19233  ;
19234  return 0;
19235}
19236_ACEOF
19237rm -f conftest.$ac_objext conftest$ac_exeext
19238if { (ac_try="$ac_link"
19239case "(($ac_try" in
19240  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19241  *) ac_try_echo=$ac_try;;
19242esac
19243eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19244  (eval "$ac_link") 2>conftest.er1
19245  ac_status=$?
19246  grep -v '^ *+' conftest.er1 >conftest.err
19247  rm -f conftest.er1
19248  cat conftest.err >&5
19249  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19250  (exit $ac_status); } && {
19251	 test -z "$ac_c_werror_flag" ||
19252	 test ! -s conftest.err
19253       } && test -s conftest$ac_exeext &&
19254       $as_test_x conftest$ac_exeext; then
19255  ac_cv_func_daemon=yes
19256else
19257  echo "$as_me: failed program was:" >&5
19258sed 's/^/| /' conftest.$ac_ext >&5
19259
19260	ac_cv_func_daemon=no
19261fi
19262
19263rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19264      conftest$ac_exeext conftest.$ac_ext
19265fi
19266{ echo "$as_me:$LINENO: result: $ac_cv_func_daemon" >&5
19267echo "${ECHO_T}$ac_cv_func_daemon" >&6; }
19268if test $ac_cv_func_daemon = yes; then
19269
19270cat >>confdefs.h <<\_ACEOF
19271#define HAVE_DAEMON 1
19272_ACEOF
19273
19274else
19275  { echo "$as_me:$LINENO: checking for daemon in -lbsd" >&5
19276echo $ECHO_N "checking for daemon in -lbsd... $ECHO_C" >&6; }
19277if test "${ac_cv_lib_bsd_daemon+set}" = set; then
19278  echo $ECHO_N "(cached) $ECHO_C" >&6
19279else
19280  ac_check_lib_save_LIBS=$LIBS
19281LIBS="-lbsd  $LIBS"
19282cat >conftest.$ac_ext <<_ACEOF
19283/* confdefs.h.  */
19284_ACEOF
19285cat confdefs.h >>conftest.$ac_ext
19286cat >>conftest.$ac_ext <<_ACEOF
19287/* end confdefs.h.  */
19288
19289/* Override any GCC internal prototype to avoid an error.
19290   Use char because int might match the return type of a GCC
19291   builtin and then its argument prototype would still apply.  */
19292#ifdef __cplusplus
19293extern "C"
19294#endif
19295char daemon ();
19296int
19297main ()
19298{
19299return daemon ();
19300  ;
19301  return 0;
19302}
19303_ACEOF
19304rm -f conftest.$ac_objext conftest$ac_exeext
19305if { (ac_try="$ac_link"
19306case "(($ac_try" in
19307  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19308  *) ac_try_echo=$ac_try;;
19309esac
19310eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19311  (eval "$ac_link") 2>conftest.er1
19312  ac_status=$?
19313  grep -v '^ *+' conftest.er1 >conftest.err
19314  rm -f conftest.er1
19315  cat conftest.err >&5
19316  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19317  (exit $ac_status); } && {
19318	 test -z "$ac_c_werror_flag" ||
19319	 test ! -s conftest.err
19320       } && test -s conftest$ac_exeext &&
19321       $as_test_x conftest$ac_exeext; then
19322  ac_cv_lib_bsd_daemon=yes
19323else
19324  echo "$as_me: failed program was:" >&5
19325sed 's/^/| /' conftest.$ac_ext >&5
19326
19327	ac_cv_lib_bsd_daemon=no
19328fi
19329
19330rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19331      conftest$ac_exeext conftest.$ac_ext
19332LIBS=$ac_check_lib_save_LIBS
19333fi
19334{ echo "$as_me:$LINENO: result: $ac_cv_lib_bsd_daemon" >&5
19335echo "${ECHO_T}$ac_cv_lib_bsd_daemon" >&6; }
19336if test $ac_cv_lib_bsd_daemon = yes; then
19337  LIBS="$LIBS -lbsd"; cat >>confdefs.h <<\_ACEOF
19338#define HAVE_DAEMON 1
19339_ACEOF
19340
19341fi
19342
19343
19344fi
19345
19346
19347{ echo "$as_me:$LINENO: checking for getpagesize" >&5
19348echo $ECHO_N "checking for getpagesize... $ECHO_C" >&6; }
19349if test "${ac_cv_func_getpagesize+set}" = set; then
19350  echo $ECHO_N "(cached) $ECHO_C" >&6
19351else
19352  cat >conftest.$ac_ext <<_ACEOF
19353/* confdefs.h.  */
19354_ACEOF
19355cat confdefs.h >>conftest.$ac_ext
19356cat >>conftest.$ac_ext <<_ACEOF
19357/* end confdefs.h.  */
19358/* Define getpagesize to an innocuous variant, in case <limits.h> declares getpagesize.
19359   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19360#define getpagesize innocuous_getpagesize
19361
19362/* System header to define __stub macros and hopefully few prototypes,
19363    which can conflict with char getpagesize (); below.
19364    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19365    <limits.h> exists even on freestanding compilers.  */
19366
19367#ifdef __STDC__
19368# include <limits.h>
19369#else
19370# include <assert.h>
19371#endif
19372
19373#undef getpagesize
19374
19375/* Override any GCC internal prototype to avoid an error.
19376   Use char because int might match the return type of a GCC
19377   builtin and then its argument prototype would still apply.  */
19378#ifdef __cplusplus
19379extern "C"
19380#endif
19381char getpagesize ();
19382/* The GNU C library defines this for functions which it implements
19383    to always fail with ENOSYS.  Some functions are actually named
19384    something starting with __ and the normal name is an alias.  */
19385#if defined __stub_getpagesize || defined __stub___getpagesize
19386choke me
19387#endif
19388
19389int
19390main ()
19391{
19392return getpagesize ();
19393  ;
19394  return 0;
19395}
19396_ACEOF
19397rm -f conftest.$ac_objext conftest$ac_exeext
19398if { (ac_try="$ac_link"
19399case "(($ac_try" in
19400  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19401  *) ac_try_echo=$ac_try;;
19402esac
19403eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19404  (eval "$ac_link") 2>conftest.er1
19405  ac_status=$?
19406  grep -v '^ *+' conftest.er1 >conftest.err
19407  rm -f conftest.er1
19408  cat conftest.err >&5
19409  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19410  (exit $ac_status); } && {
19411	 test -z "$ac_c_werror_flag" ||
19412	 test ! -s conftest.err
19413       } && test -s conftest$ac_exeext &&
19414       $as_test_x conftest$ac_exeext; then
19415  ac_cv_func_getpagesize=yes
19416else
19417  echo "$as_me: failed program was:" >&5
19418sed 's/^/| /' conftest.$ac_ext >&5
19419
19420	ac_cv_func_getpagesize=no
19421fi
19422
19423rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19424      conftest$ac_exeext conftest.$ac_ext
19425fi
19426{ echo "$as_me:$LINENO: result: $ac_cv_func_getpagesize" >&5
19427echo "${ECHO_T}$ac_cv_func_getpagesize" >&6; }
19428if test $ac_cv_func_getpagesize = yes; then
19429
19430cat >>confdefs.h <<\_ACEOF
19431#define HAVE_GETPAGESIZE 1
19432_ACEOF
19433
19434else
19435  { echo "$as_me:$LINENO: checking for getpagesize in -lucb" >&5
19436echo $ECHO_N "checking for getpagesize in -lucb... $ECHO_C" >&6; }
19437if test "${ac_cv_lib_ucb_getpagesize+set}" = set; then
19438  echo $ECHO_N "(cached) $ECHO_C" >&6
19439else
19440  ac_check_lib_save_LIBS=$LIBS
19441LIBS="-lucb  $LIBS"
19442cat >conftest.$ac_ext <<_ACEOF
19443/* confdefs.h.  */
19444_ACEOF
19445cat confdefs.h >>conftest.$ac_ext
19446cat >>conftest.$ac_ext <<_ACEOF
19447/* end confdefs.h.  */
19448
19449/* Override any GCC internal prototype to avoid an error.
19450   Use char because int might match the return type of a GCC
19451   builtin and then its argument prototype would still apply.  */
19452#ifdef __cplusplus
19453extern "C"
19454#endif
19455char getpagesize ();
19456int
19457main ()
19458{
19459return getpagesize ();
19460  ;
19461  return 0;
19462}
19463_ACEOF
19464rm -f conftest.$ac_objext conftest$ac_exeext
19465if { (ac_try="$ac_link"
19466case "(($ac_try" in
19467  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19468  *) ac_try_echo=$ac_try;;
19469esac
19470eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19471  (eval "$ac_link") 2>conftest.er1
19472  ac_status=$?
19473  grep -v '^ *+' conftest.er1 >conftest.err
19474  rm -f conftest.er1
19475  cat conftest.err >&5
19476  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19477  (exit $ac_status); } && {
19478	 test -z "$ac_c_werror_flag" ||
19479	 test ! -s conftest.err
19480       } && test -s conftest$ac_exeext &&
19481       $as_test_x conftest$ac_exeext; then
19482  ac_cv_lib_ucb_getpagesize=yes
19483else
19484  echo "$as_me: failed program was:" >&5
19485sed 's/^/| /' conftest.$ac_ext >&5
19486
19487	ac_cv_lib_ucb_getpagesize=no
19488fi
19489
19490rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19491      conftest$ac_exeext conftest.$ac_ext
19492LIBS=$ac_check_lib_save_LIBS
19493fi
19494{ echo "$as_me:$LINENO: result: $ac_cv_lib_ucb_getpagesize" >&5
19495echo "${ECHO_T}$ac_cv_lib_ucb_getpagesize" >&6; }
19496if test $ac_cv_lib_ucb_getpagesize = yes; then
19497  LIBS="$LIBS -lucb"; cat >>confdefs.h <<\_ACEOF
19498#define HAVE_GETPAGESIZE 1
19499_ACEOF
19500
19501fi
19502
19503
19504fi
19505
19506
19507# Check for broken snprintf
19508if test "x$ac_cv_func_snprintf" = "xyes" ; then
19509	{ echo "$as_me:$LINENO: checking whether snprintf correctly terminates long strings" >&5
19510echo $ECHO_N "checking whether snprintf correctly terminates long strings... $ECHO_C" >&6; }
19511	if test "$cross_compiling" = yes; then
19512   { echo "$as_me:$LINENO: WARNING: cross compiling: Assuming working snprintf()" >&5
19513echo "$as_me: WARNING: cross compiling: Assuming working snprintf()" >&2;}
19514
19515else
19516  cat >conftest.$ac_ext <<_ACEOF
19517/* confdefs.h.  */
19518_ACEOF
19519cat confdefs.h >>conftest.$ac_ext
19520cat >>conftest.$ac_ext <<_ACEOF
19521/* end confdefs.h.  */
19522 #include <stdio.h>
19523int
19524main ()
19525{
19526
19527	char b[5];
19528	snprintf(b,5,"123456789");
19529	exit(b[4]!='\0');
19530
19531  ;
19532  return 0;
19533}
19534_ACEOF
19535rm -f conftest$ac_exeext
19536if { (ac_try="$ac_link"
19537case "(($ac_try" in
19538  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19539  *) ac_try_echo=$ac_try;;
19540esac
19541eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19542  (eval "$ac_link") 2>&5
19543  ac_status=$?
19544  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19545  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19546  { (case "(($ac_try" in
19547  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19548  *) ac_try_echo=$ac_try;;
19549esac
19550eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19551  (eval "$ac_try") 2>&5
19552  ac_status=$?
19553  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19554  (exit $ac_status); }; }; then
19555  { echo "$as_me:$LINENO: result: yes" >&5
19556echo "${ECHO_T}yes" >&6; }
19557else
19558  echo "$as_me: program exited with status $ac_status" >&5
19559echo "$as_me: failed program was:" >&5
19560sed 's/^/| /' conftest.$ac_ext >&5
19561
19562( exit $ac_status )
19563
19564			{ echo "$as_me:$LINENO: result: no" >&5
19565echo "${ECHO_T}no" >&6; }
19566
19567cat >>confdefs.h <<\_ACEOF
19568#define BROKEN_SNPRINTF 1
19569_ACEOF
19570
19571			{ echo "$as_me:$LINENO: WARNING: ****** Your snprintf() function is broken, complain to your vendor" >&5
19572echo "$as_me: WARNING: ****** Your snprintf() function is broken, complain to your vendor" >&2;}
19573
19574fi
19575rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19576fi
19577
19578
19579fi
19580
19581# We depend on vsnprintf returning the right thing on overflow: the
19582# number of characters it tried to create (as per SUSv3)
19583if test "x$ac_cv_func_vsnprintf" = "xyes" ; then
19584	{ echo "$as_me:$LINENO: checking whether vsnprintf returns correct values on overflow" >&5
19585echo $ECHO_N "checking whether vsnprintf returns correct values on overflow... $ECHO_C" >&6; }
19586	if test "$cross_compiling" = yes; then
19587   { echo "$as_me:$LINENO: WARNING: cross compiling: Assuming working vsnprintf()" >&5
19588echo "$as_me: WARNING: cross compiling: Assuming working vsnprintf()" >&2;}
19589
19590else
19591  cat >conftest.$ac_ext <<_ACEOF
19592/* confdefs.h.  */
19593_ACEOF
19594cat confdefs.h >>conftest.$ac_ext
19595cat >>conftest.$ac_ext <<_ACEOF
19596/* end confdefs.h.  */
19597
19598#include <sys/types.h>
19599#include <stdio.h>
19600#include <stdarg.h>
19601
19602int x_snprintf(char *str, size_t count, const char *fmt, ...)
19603{
19604	size_t ret;
19605	va_list ap;
19606
19607	va_start(ap, fmt);
19608	ret = vsnprintf(str, count, fmt, ap);
19609	va_end(ap);
19610	return ret;
19611}
19612
19613int
19614main ()
19615{
19616
19617char x[1];
19618if (x_snprintf(x, 1, "%s %d", "hello", 12345) != 11)
19619	return 1;
19620if (x_snprintf(NULL, 0, "%s %d", "hello", 12345) != 11)
19621	return 1;
19622return 0;
19623
19624  ;
19625  return 0;
19626}
19627_ACEOF
19628rm -f conftest$ac_exeext
19629if { (ac_try="$ac_link"
19630case "(($ac_try" in
19631  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19632  *) ac_try_echo=$ac_try;;
19633esac
19634eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19635  (eval "$ac_link") 2>&5
19636  ac_status=$?
19637  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19638  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19639  { (case "(($ac_try" in
19640  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19641  *) ac_try_echo=$ac_try;;
19642esac
19643eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19644  (eval "$ac_try") 2>&5
19645  ac_status=$?
19646  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19647  (exit $ac_status); }; }; then
19648  { echo "$as_me:$LINENO: result: yes" >&5
19649echo "${ECHO_T}yes" >&6; }
19650else
19651  echo "$as_me: program exited with status $ac_status" >&5
19652echo "$as_me: failed program was:" >&5
19653sed 's/^/| /' conftest.$ac_ext >&5
19654
19655( exit $ac_status )
19656
19657			{ echo "$as_me:$LINENO: result: no" >&5
19658echo "${ECHO_T}no" >&6; }
19659
19660cat >>confdefs.h <<\_ACEOF
19661#define BROKEN_SNPRINTF 1
19662_ACEOF
19663
19664			{ echo "$as_me:$LINENO: WARNING: ****** Your vsnprintf() function is broken, complain to your vendor" >&5
19665echo "$as_me: WARNING: ****** Your vsnprintf() function is broken, complain to your vendor" >&2;}
19666
19667fi
19668rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19669fi
19670
19671
19672fi
19673
19674# On systems where [v]snprintf is broken, but is declared in stdio,
19675# check that the fmt argument is const char * or just char *.
19676# This is only useful for when BROKEN_SNPRINTF
19677{ echo "$as_me:$LINENO: checking whether snprintf can declare const char *fmt" >&5
19678echo $ECHO_N "checking whether snprintf can declare const char *fmt... $ECHO_C" >&6; }
19679cat >conftest.$ac_ext <<_ACEOF
19680/* confdefs.h.  */
19681_ACEOF
19682cat confdefs.h >>conftest.$ac_ext
19683cat >>conftest.$ac_ext <<_ACEOF
19684/* end confdefs.h.  */
19685
19686#include <stdio.h>
19687int snprintf(char *a, size_t b, const char *c, ...) { return 0; }
19688
19689int
19690main ()
19691{
19692
19693	snprintf(0, 0, 0);
19694
19695  ;
19696  return 0;
19697}
19698_ACEOF
19699rm -f conftest.$ac_objext
19700if { (ac_try="$ac_compile"
19701case "(($ac_try" in
19702  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19703  *) ac_try_echo=$ac_try;;
19704esac
19705eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19706  (eval "$ac_compile") 2>conftest.er1
19707  ac_status=$?
19708  grep -v '^ *+' conftest.er1 >conftest.err
19709  rm -f conftest.er1
19710  cat conftest.err >&5
19711  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19712  (exit $ac_status); } && {
19713	 test -z "$ac_c_werror_flag" ||
19714	 test ! -s conftest.err
19715       } && test -s conftest.$ac_objext; then
19716  { echo "$as_me:$LINENO: result: yes" >&5
19717echo "${ECHO_T}yes" >&6; }
19718
19719cat >>confdefs.h <<\_ACEOF
19720#define SNPRINTF_CONST const
19721_ACEOF
19722
19723else
19724  echo "$as_me: failed program was:" >&5
19725sed 's/^/| /' conftest.$ac_ext >&5
19726
19727	{ echo "$as_me:$LINENO: result: no" >&5
19728echo "${ECHO_T}no" >&6; }
19729    cat >>confdefs.h <<\_ACEOF
19730#define SNPRINTF_CONST /* not const */
19731_ACEOF
19732
19733fi
19734
19735rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19736
19737# Check for missing getpeereid (or equiv) support
19738NO_PEERCHECK=""
19739if test "x$ac_cv_func_getpeereid" != "xyes" -a "x$ac_cv_func_getpeerucred" != "xyes"; then
19740	{ echo "$as_me:$LINENO: checking whether system supports SO_PEERCRED getsockopt" >&5
19741echo $ECHO_N "checking whether system supports SO_PEERCRED getsockopt... $ECHO_C" >&6; }
19742	cat >conftest.$ac_ext <<_ACEOF
19743/* confdefs.h.  */
19744_ACEOF
19745cat confdefs.h >>conftest.$ac_ext
19746cat >>conftest.$ac_ext <<_ACEOF
19747/* end confdefs.h.  */
19748
19749#include <sys/types.h>
19750#include <sys/socket.h>
19751int
19752main ()
19753{
19754int i = SO_PEERCRED;
19755  ;
19756  return 0;
19757}
19758_ACEOF
19759rm -f conftest.$ac_objext
19760if { (ac_try="$ac_compile"
19761case "(($ac_try" in
19762  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19763  *) ac_try_echo=$ac_try;;
19764esac
19765eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19766  (eval "$ac_compile") 2>conftest.er1
19767  ac_status=$?
19768  grep -v '^ *+' conftest.er1 >conftest.err
19769  rm -f conftest.er1
19770  cat conftest.err >&5
19771  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19772  (exit $ac_status); } && {
19773	 test -z "$ac_c_werror_flag" ||
19774	 test ! -s conftest.err
19775       } && test -s conftest.$ac_objext; then
19776   { echo "$as_me:$LINENO: result: yes" >&5
19777echo "${ECHO_T}yes" >&6; }
19778
19779cat >>confdefs.h <<\_ACEOF
19780#define HAVE_SO_PEERCRED 1
19781_ACEOF
19782
19783
19784else
19785  echo "$as_me: failed program was:" >&5
19786sed 's/^/| /' conftest.$ac_ext >&5
19787
19788	{ echo "$as_me:$LINENO: result: no" >&5
19789echo "${ECHO_T}no" >&6; }
19790		NO_PEERCHECK=1
19791
19792fi
19793
19794rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19795fi
19796
19797if test "x$ac_cv_func_mkdtemp" = "xyes" ; then
19798{ echo "$as_me:$LINENO: checking for (overly) strict mkstemp" >&5
19799echo $ECHO_N "checking for (overly) strict mkstemp... $ECHO_C" >&6; }
19800if test "$cross_compiling" = yes; then
19801
19802		{ echo "$as_me:$LINENO: result: yes" >&5
19803echo "${ECHO_T}yes" >&6; }
19804		cat >>confdefs.h <<\_ACEOF
19805#define HAVE_STRICT_MKSTEMP 1
19806_ACEOF
19807
19808
19809
19810else
19811  cat >conftest.$ac_ext <<_ACEOF
19812/* confdefs.h.  */
19813_ACEOF
19814cat confdefs.h >>conftest.$ac_ext
19815cat >>conftest.$ac_ext <<_ACEOF
19816/* end confdefs.h.  */
19817
19818#include <stdlib.h>
19819
19820int
19821main ()
19822{
19823
19824	char template[]="conftest.mkstemp-test";
19825	if (mkstemp(template) == -1)
19826		exit(1);
19827	unlink(template);
19828	exit(0);
19829
19830  ;
19831  return 0;
19832}
19833_ACEOF
19834rm -f conftest$ac_exeext
19835if { (ac_try="$ac_link"
19836case "(($ac_try" in
19837  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19838  *) ac_try_echo=$ac_try;;
19839esac
19840eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19841  (eval "$ac_link") 2>&5
19842  ac_status=$?
19843  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19844  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19845  { (case "(($ac_try" in
19846  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19847  *) ac_try_echo=$ac_try;;
19848esac
19849eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19850  (eval "$ac_try") 2>&5
19851  ac_status=$?
19852  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19853  (exit $ac_status); }; }; then
19854
19855		{ echo "$as_me:$LINENO: result: no" >&5
19856echo "${ECHO_T}no" >&6; }
19857
19858else
19859  echo "$as_me: program exited with status $ac_status" >&5
19860echo "$as_me: failed program was:" >&5
19861sed 's/^/| /' conftest.$ac_ext >&5
19862
19863( exit $ac_status )
19864
19865		{ echo "$as_me:$LINENO: result: yes" >&5
19866echo "${ECHO_T}yes" >&6; }
19867
19868cat >>confdefs.h <<\_ACEOF
19869#define HAVE_STRICT_MKSTEMP 1
19870_ACEOF
19871
19872
19873fi
19874rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19875fi
19876
19877
19878fi
19879
19880if test ! -z "$check_for_openpty_ctty_bug"; then
19881	{ echo "$as_me:$LINENO: checking if openpty correctly handles controlling tty" >&5
19882echo $ECHO_N "checking if openpty correctly handles controlling tty... $ECHO_C" >&6; }
19883	if test "$cross_compiling" = yes; then
19884
19885			{ echo "$as_me:$LINENO: result: cross-compiling, assuming yes" >&5
19886echo "${ECHO_T}cross-compiling, assuming yes" >&6; }
19887
19888
19889else
19890  cat >conftest.$ac_ext <<_ACEOF
19891/* confdefs.h.  */
19892_ACEOF
19893cat confdefs.h >>conftest.$ac_ext
19894cat >>conftest.$ac_ext <<_ACEOF
19895/* end confdefs.h.  */
19896
19897#include <stdio.h>
19898#include <sys/fcntl.h>
19899#include <sys/types.h>
19900#include <sys/wait.h>
19901
19902int
19903main ()
19904{
19905
19906	pid_t pid;
19907	int fd, ptyfd, ttyfd, status;
19908
19909	pid = fork();
19910	if (pid < 0) {		/* failed */
19911		exit(1);
19912	} else if (pid > 0) {	/* parent */
19913		waitpid(pid, &status, 0);
19914		if (WIFEXITED(status))
19915			exit(WEXITSTATUS(status));
19916		else
19917			exit(2);
19918	} else {		/* child */
19919		close(0); close(1); close(2);
19920		setsid();
19921		openpty(&ptyfd, &ttyfd, NULL, NULL, NULL);
19922		fd = open("/dev/tty", O_RDWR | O_NOCTTY);
19923		if (fd >= 0)
19924			exit(3);	/* Acquired ctty: broken */
19925		else
19926			exit(0);	/* Did not acquire ctty: OK */
19927	}
19928
19929  ;
19930  return 0;
19931}
19932_ACEOF
19933rm -f conftest$ac_exeext
19934if { (ac_try="$ac_link"
19935case "(($ac_try" in
19936  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19937  *) ac_try_echo=$ac_try;;
19938esac
19939eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19940  (eval "$ac_link") 2>&5
19941  ac_status=$?
19942  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19943  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
19944  { (case "(($ac_try" in
19945  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19946  *) ac_try_echo=$ac_try;;
19947esac
19948eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
19949  (eval "$ac_try") 2>&5
19950  ac_status=$?
19951  echo "$as_me:$LINENO: \$? = $ac_status" >&5
19952  (exit $ac_status); }; }; then
19953
19954			{ echo "$as_me:$LINENO: result: yes" >&5
19955echo "${ECHO_T}yes" >&6; }
19956
19957else
19958  echo "$as_me: program exited with status $ac_status" >&5
19959echo "$as_me: failed program was:" >&5
19960sed 's/^/| /' conftest.$ac_ext >&5
19961
19962( exit $ac_status )
19963
19964			{ echo "$as_me:$LINENO: result: no" >&5
19965echo "${ECHO_T}no" >&6; }
19966			cat >>confdefs.h <<\_ACEOF
19967#define SSHD_ACQUIRES_CTTY 1
19968_ACEOF
19969
19970
19971fi
19972rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
19973fi
19974
19975
19976fi
19977
19978if test "x$ac_cv_func_getaddrinfo" = "xyes" && \
19979    test "x$check_for_hpux_broken_getaddrinfo" = "x1"; then
19980	{ echo "$as_me:$LINENO: checking if getaddrinfo seems to work" >&5
19981echo $ECHO_N "checking if getaddrinfo seems to work... $ECHO_C" >&6; }
19982	if test "$cross_compiling" = yes; then
19983
19984			{ echo "$as_me:$LINENO: result: cross-compiling, assuming yes" >&5
19985echo "${ECHO_T}cross-compiling, assuming yes" >&6; }
19986
19987
19988else
19989  cat >conftest.$ac_ext <<_ACEOF
19990/* confdefs.h.  */
19991_ACEOF
19992cat confdefs.h >>conftest.$ac_ext
19993cat >>conftest.$ac_ext <<_ACEOF
19994/* end confdefs.h.  */
19995
19996#include <stdio.h>
19997#include <sys/socket.h>
19998#include <netdb.h>
19999#include <errno.h>
20000#include <netinet/in.h>
20001
20002#define TEST_PORT "2222"
20003
20004int
20005main ()
20006{
20007
20008	int err, sock;
20009	struct addrinfo *gai_ai, *ai, hints;
20010	char ntop[NI_MAXHOST], strport[NI_MAXSERV], *name = NULL;
20011
20012	memset(&hints, 0, sizeof(hints));
20013	hints.ai_family = PF_UNSPEC;
20014	hints.ai_socktype = SOCK_STREAM;
20015	hints.ai_flags = AI_PASSIVE;
20016
20017	err = getaddrinfo(name, TEST_PORT, &hints, &gai_ai);
20018	if (err != 0) {
20019		fprintf(stderr, "getaddrinfo failed (%s)", gai_strerror(err));
20020		exit(1);
20021	}
20022
20023	for (ai = gai_ai; ai != NULL; ai = ai->ai_next) {
20024		if (ai->ai_family != AF_INET6)
20025			continue;
20026
20027		err = getnameinfo(ai->ai_addr, ai->ai_addrlen, ntop,
20028		    sizeof(ntop), strport, sizeof(strport),
20029		    NI_NUMERICHOST|NI_NUMERICSERV);
20030
20031		if (err != 0) {
20032			if (err == EAI_SYSTEM)
20033				perror("getnameinfo EAI_SYSTEM");
20034			else
20035				fprintf(stderr, "getnameinfo failed: %s\n",
20036				    gai_strerror(err));
20037			exit(2);
20038		}
20039
20040		sock = socket(ai->ai_family, ai->ai_socktype, ai->ai_protocol);
20041		if (sock < 0)
20042			perror("socket");
20043		if (bind(sock, ai->ai_addr, ai->ai_addrlen) < 0) {
20044			if (errno == EBADF)
20045				exit(3);
20046		}
20047	}
20048	exit(0);
20049
20050  ;
20051  return 0;
20052}
20053_ACEOF
20054rm -f conftest$ac_exeext
20055if { (ac_try="$ac_link"
20056case "(($ac_try" in
20057  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20058  *) ac_try_echo=$ac_try;;
20059esac
20060eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20061  (eval "$ac_link") 2>&5
20062  ac_status=$?
20063  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20064  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20065  { (case "(($ac_try" in
20066  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20067  *) ac_try_echo=$ac_try;;
20068esac
20069eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20070  (eval "$ac_try") 2>&5
20071  ac_status=$?
20072  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20073  (exit $ac_status); }; }; then
20074
20075			{ echo "$as_me:$LINENO: result: yes" >&5
20076echo "${ECHO_T}yes" >&6; }
20077
20078else
20079  echo "$as_me: program exited with status $ac_status" >&5
20080echo "$as_me: failed program was:" >&5
20081sed 's/^/| /' conftest.$ac_ext >&5
20082
20083( exit $ac_status )
20084
20085			{ echo "$as_me:$LINENO: result: no" >&5
20086echo "${ECHO_T}no" >&6; }
20087			cat >>confdefs.h <<\_ACEOF
20088#define BROKEN_GETADDRINFO 1
20089_ACEOF
20090
20091
20092fi
20093rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20094fi
20095
20096
20097fi
20098
20099if test "x$ac_cv_func_getaddrinfo" = "xyes" && \
20100    test "x$check_for_aix_broken_getaddrinfo" = "x1"; then
20101	{ echo "$as_me:$LINENO: checking if getaddrinfo seems to work" >&5
20102echo $ECHO_N "checking if getaddrinfo seems to work... $ECHO_C" >&6; }
20103	if test "$cross_compiling" = yes; then
20104
20105			{ echo "$as_me:$LINENO: result: cross-compiling, assuming no" >&5
20106echo "${ECHO_T}cross-compiling, assuming no" >&6; }
20107
20108
20109else
20110  cat >conftest.$ac_ext <<_ACEOF
20111/* confdefs.h.  */
20112_ACEOF
20113cat confdefs.h >>conftest.$ac_ext
20114cat >>conftest.$ac_ext <<_ACEOF
20115/* end confdefs.h.  */
20116
20117#include <stdio.h>
20118#include <sys/socket.h>
20119#include <netdb.h>
20120#include <errno.h>
20121#include <netinet/in.h>
20122
20123#define TEST_PORT "2222"
20124
20125int
20126main ()
20127{
20128
20129	int err, sock;
20130	struct addrinfo *gai_ai, *ai, hints;
20131	char ntop[NI_MAXHOST], strport[NI_MAXSERV], *name = NULL;
20132
20133	memset(&hints, 0, sizeof(hints));
20134	hints.ai_family = PF_UNSPEC;
20135	hints.ai_socktype = SOCK_STREAM;
20136	hints.ai_flags = AI_PASSIVE;
20137
20138	err = getaddrinfo(name, TEST_PORT, &hints, &gai_ai);
20139	if (err != 0) {
20140		fprintf(stderr, "getaddrinfo failed (%s)", gai_strerror(err));
20141		exit(1);
20142	}
20143
20144	for (ai = gai_ai; ai != NULL; ai = ai->ai_next) {
20145		if (ai->ai_family != AF_INET && ai->ai_family != AF_INET6)
20146			continue;
20147
20148		err = getnameinfo(ai->ai_addr, ai->ai_addrlen, ntop,
20149		    sizeof(ntop), strport, sizeof(strport),
20150		    NI_NUMERICHOST|NI_NUMERICSERV);
20151
20152		if (ai->ai_family == AF_INET && err != 0) {
20153			perror("getnameinfo");
20154			exit(2);
20155		}
20156	}
20157	exit(0);
20158
20159  ;
20160  return 0;
20161}
20162_ACEOF
20163rm -f conftest$ac_exeext
20164if { (ac_try="$ac_link"
20165case "(($ac_try" in
20166  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20167  *) ac_try_echo=$ac_try;;
20168esac
20169eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20170  (eval "$ac_link") 2>&5
20171  ac_status=$?
20172  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20173  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20174  { (case "(($ac_try" in
20175  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20176  *) ac_try_echo=$ac_try;;
20177esac
20178eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20179  (eval "$ac_try") 2>&5
20180  ac_status=$?
20181  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20182  (exit $ac_status); }; }; then
20183
20184			{ echo "$as_me:$LINENO: result: yes" >&5
20185echo "${ECHO_T}yes" >&6; }
20186
20187cat >>confdefs.h <<\_ACEOF
20188#define AIX_GETNAMEINFO_HACK 1
20189_ACEOF
20190
20191
20192else
20193  echo "$as_me: program exited with status $ac_status" >&5
20194echo "$as_me: failed program was:" >&5
20195sed 's/^/| /' conftest.$ac_ext >&5
20196
20197( exit $ac_status )
20198
20199			{ echo "$as_me:$LINENO: result: no" >&5
20200echo "${ECHO_T}no" >&6; }
20201			cat >>confdefs.h <<\_ACEOF
20202#define BROKEN_GETADDRINFO 1
20203_ACEOF
20204
20205
20206fi
20207rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20208fi
20209
20210
20211fi
20212
20213if test "x$ac_cv_func_getaddrinfo" = "xyes"; then
20214	{ echo "$as_me:$LINENO: checking whether AI_NUMERICSERV is declared" >&5
20215echo $ECHO_N "checking whether AI_NUMERICSERV is declared... $ECHO_C" >&6; }
20216if test "${ac_cv_have_decl_AI_NUMERICSERV+set}" = set; then
20217  echo $ECHO_N "(cached) $ECHO_C" >&6
20218else
20219  cat >conftest.$ac_ext <<_ACEOF
20220/* confdefs.h.  */
20221_ACEOF
20222cat confdefs.h >>conftest.$ac_ext
20223cat >>conftest.$ac_ext <<_ACEOF
20224/* end confdefs.h.  */
20225#include <sys/types.h>
20226	     #include <sys/socket.h>
20227	     #include <netdb.h>
20228
20229int
20230main ()
20231{
20232#ifndef AI_NUMERICSERV
20233  (void) AI_NUMERICSERV;
20234#endif
20235
20236  ;
20237  return 0;
20238}
20239_ACEOF
20240rm -f conftest.$ac_objext
20241if { (ac_try="$ac_compile"
20242case "(($ac_try" in
20243  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20244  *) ac_try_echo=$ac_try;;
20245esac
20246eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20247  (eval "$ac_compile") 2>conftest.er1
20248  ac_status=$?
20249  grep -v '^ *+' conftest.er1 >conftest.err
20250  rm -f conftest.er1
20251  cat conftest.err >&5
20252  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20253  (exit $ac_status); } && {
20254	 test -z "$ac_c_werror_flag" ||
20255	 test ! -s conftest.err
20256       } && test -s conftest.$ac_objext; then
20257  ac_cv_have_decl_AI_NUMERICSERV=yes
20258else
20259  echo "$as_me: failed program was:" >&5
20260sed 's/^/| /' conftest.$ac_ext >&5
20261
20262	ac_cv_have_decl_AI_NUMERICSERV=no
20263fi
20264
20265rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20266fi
20267{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_AI_NUMERICSERV" >&5
20268echo "${ECHO_T}$ac_cv_have_decl_AI_NUMERICSERV" >&6; }
20269if test $ac_cv_have_decl_AI_NUMERICSERV = yes; then
20270
20271cat >>confdefs.h <<_ACEOF
20272#define HAVE_DECL_AI_NUMERICSERV 1
20273_ACEOF
20274
20275
20276else
20277  cat >>confdefs.h <<_ACEOF
20278#define HAVE_DECL_AI_NUMERICSERV 0
20279_ACEOF
20280
20281
20282fi
20283
20284
20285fi
20286
20287if test "x$check_for_conflicting_getspnam" = "x1"; then
20288	{ echo "$as_me:$LINENO: checking for conflicting getspnam in shadow.h" >&5
20289echo $ECHO_N "checking for conflicting getspnam in shadow.h... $ECHO_C" >&6; }
20290	cat >conftest.$ac_ext <<_ACEOF
20291/* confdefs.h.  */
20292_ACEOF
20293cat confdefs.h >>conftest.$ac_ext
20294cat >>conftest.$ac_ext <<_ACEOF
20295/* end confdefs.h.  */
20296 #include <shadow.h>
20297int
20298main ()
20299{
20300 exit(0);
20301  ;
20302  return 0;
20303}
20304_ACEOF
20305rm -f conftest.$ac_objext
20306if { (ac_try="$ac_compile"
20307case "(($ac_try" in
20308  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20309  *) ac_try_echo=$ac_try;;
20310esac
20311eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20312  (eval "$ac_compile") 2>conftest.er1
20313  ac_status=$?
20314  grep -v '^ *+' conftest.er1 >conftest.err
20315  rm -f conftest.er1
20316  cat conftest.err >&5
20317  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20318  (exit $ac_status); } && {
20319	 test -z "$ac_c_werror_flag" ||
20320	 test ! -s conftest.err
20321       } && test -s conftest.$ac_objext; then
20322
20323			{ echo "$as_me:$LINENO: result: no" >&5
20324echo "${ECHO_T}no" >&6; }
20325
20326else
20327  echo "$as_me: failed program was:" >&5
20328sed 's/^/| /' conftest.$ac_ext >&5
20329
20330
20331			{ echo "$as_me:$LINENO: result: yes" >&5
20332echo "${ECHO_T}yes" >&6; }
20333
20334cat >>confdefs.h <<\_ACEOF
20335#define GETSPNAM_CONFLICTING_DEFS 1
20336_ACEOF
20337
20338
20339
20340fi
20341
20342rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20343fi
20344
20345{ echo "$as_me:$LINENO: checking whether getpgrp requires zero arguments" >&5
20346echo $ECHO_N "checking whether getpgrp requires zero arguments... $ECHO_C" >&6; }
20347if test "${ac_cv_func_getpgrp_void+set}" = set; then
20348  echo $ECHO_N "(cached) $ECHO_C" >&6
20349else
20350  # Use it with a single arg.
20351cat >conftest.$ac_ext <<_ACEOF
20352/* confdefs.h.  */
20353_ACEOF
20354cat confdefs.h >>conftest.$ac_ext
20355cat >>conftest.$ac_ext <<_ACEOF
20356/* end confdefs.h.  */
20357$ac_includes_default
20358int
20359main ()
20360{
20361getpgrp (0);
20362  ;
20363  return 0;
20364}
20365_ACEOF
20366rm -f conftest.$ac_objext
20367if { (ac_try="$ac_compile"
20368case "(($ac_try" in
20369  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20370  *) ac_try_echo=$ac_try;;
20371esac
20372eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20373  (eval "$ac_compile") 2>conftest.er1
20374  ac_status=$?
20375  grep -v '^ *+' conftest.er1 >conftest.err
20376  rm -f conftest.er1
20377  cat conftest.err >&5
20378  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20379  (exit $ac_status); } && {
20380	 test -z "$ac_c_werror_flag" ||
20381	 test ! -s conftest.err
20382       } && test -s conftest.$ac_objext; then
20383  ac_cv_func_getpgrp_void=no
20384else
20385  echo "$as_me: failed program was:" >&5
20386sed 's/^/| /' conftest.$ac_ext >&5
20387
20388	ac_cv_func_getpgrp_void=yes
20389fi
20390
20391rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20392
20393fi
20394{ echo "$as_me:$LINENO: result: $ac_cv_func_getpgrp_void" >&5
20395echo "${ECHO_T}$ac_cv_func_getpgrp_void" >&6; }
20396if test $ac_cv_func_getpgrp_void = yes; then
20397
20398cat >>confdefs.h <<\_ACEOF
20399#define GETPGRP_VOID 1
20400_ACEOF
20401
20402fi
20403
20404
20405# Search for OpenSSL
20406saved_CPPFLAGS="$CPPFLAGS"
20407saved_LDFLAGS="$LDFLAGS"
20408
20409# Check whether --with-ssl-dir was given.
20410if test "${with_ssl_dir+set}" = set; then
20411  withval=$with_ssl_dir;
20412		if test "x$openssl" = "xno" ; then
20413			{ { echo "$as_me:$LINENO: error: cannot use --with-ssl-dir when OpenSSL disabled" >&5
20414echo "$as_me: error: cannot use --with-ssl-dir when OpenSSL disabled" >&2;}
20415   { (exit 1); exit 1; }; }
20416		fi
20417		if test "x$withval" != "xno" ; then
20418			case "$withval" in
20419				# Relative paths
20420				./*|../*)	withval="`pwd`/$withval"
20421			esac
20422			if test -d "$withval/lib"; then
20423				if test -n "${need_dash_r}"; then
20424					LDFLAGS="-L${withval}/lib -R${withval}/lib ${LDFLAGS}"
20425				else
20426					LDFLAGS="-L${withval}/lib ${LDFLAGS}"
20427				fi
20428			elif test -d "$withval/lib64"; then
20429				if test -n "${need_dash_r}"; then
20430					LDFLAGS="-L${withval}/lib64 -R${withval}/lib64 ${LDFLAGS}"
20431				else
20432					LDFLAGS="-L${withval}/lib64 ${LDFLAGS}"
20433				fi
20434			else
20435				if test -n "${need_dash_r}"; then
20436					LDFLAGS="-L${withval} -R${withval} ${LDFLAGS}"
20437				else
20438					LDFLAGS="-L${withval} ${LDFLAGS}"
20439				fi
20440			fi
20441			if test -d "$withval/include"; then
20442				CPPFLAGS="-I${withval}/include ${CPPFLAGS}"
20443			else
20444				CPPFLAGS="-I${withval} ${CPPFLAGS}"
20445			fi
20446		fi
20447
20448
20449fi
20450
20451
20452
20453# Check whether --with-openssl-header-check was given.
20454if test "${with_openssl_header_check+set}" = set; then
20455  withval=$with_openssl_header_check;
20456		if test "x$withval" = "xno" ; then
20457			openssl_check_nonfatal=1
20458		fi
20459
20460
20461fi
20462
20463
20464openssl_engine=no
20465
20466# Check whether --with-ssl-engine was given.
20467if test "${with_ssl_engine+set}" = set; then
20468  withval=$with_ssl_engine;
20469		if test "x$openssl" = "xno" ; then
20470			{ { echo "$as_me:$LINENO: error: cannot use --with-ssl-engine when OpenSSL disabled" >&5
20471echo "$as_me: error: cannot use --with-ssl-engine when OpenSSL disabled" >&2;}
20472   { (exit 1); exit 1; }; }
20473		fi
20474		if test "x$withval" != "xno" ; then
20475			openssl_engine=yes
20476		fi
20477
20478
20479fi
20480
20481
20482if test "x$openssl" = "xyes" ; then
20483	LIBS="-lcrypto $LIBS"
20484	cat >conftest.$ac_ext <<_ACEOF
20485/* confdefs.h.  */
20486_ACEOF
20487cat confdefs.h >>conftest.$ac_ext
20488cat >>conftest.$ac_ext <<_ACEOF
20489/* end confdefs.h.  */
20490
20491/* Override any GCC internal prototype to avoid an error.
20492   Use char because int might match the return type of a GCC
20493   builtin and then its argument prototype would still apply.  */
20494#ifdef __cplusplus
20495extern "C"
20496#endif
20497char RAND_add ();
20498int
20499main ()
20500{
20501return RAND_add ();
20502  ;
20503  return 0;
20504}
20505_ACEOF
20506rm -f conftest.$ac_objext conftest$ac_exeext
20507if { (ac_try="$ac_link"
20508case "(($ac_try" in
20509  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20510  *) ac_try_echo=$ac_try;;
20511esac
20512eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20513  (eval "$ac_link") 2>conftest.er1
20514  ac_status=$?
20515  grep -v '^ *+' conftest.er1 >conftest.err
20516  rm -f conftest.er1
20517  cat conftest.err >&5
20518  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20519  (exit $ac_status); } && {
20520	 test -z "$ac_c_werror_flag" ||
20521	 test ! -s conftest.err
20522       } && test -s conftest$ac_exeext &&
20523       $as_test_x conftest$ac_exeext; then
20524
20525cat >>confdefs.h <<\_ACEOF
20526#define HAVE_OPENSSL 1
20527_ACEOF
20528
20529else
20530  echo "$as_me: failed program was:" >&5
20531sed 's/^/| /' conftest.$ac_ext >&5
20532
20533
20534						if test -n "${need_dash_r}"; then
20535				LDFLAGS="-L/usr/local/ssl/lib -R/usr/local/ssl/lib ${saved_LDFLAGS}"
20536			else
20537				LDFLAGS="-L/usr/local/ssl/lib ${saved_LDFLAGS}"
20538			fi
20539			CPPFLAGS="-I/usr/local/ssl/include ${saved_CPPFLAGS}"
20540			if test "${ac_cv_header_openssl_opensslv_h+set}" = set; then
20541  { echo "$as_me:$LINENO: checking for openssl/opensslv.h" >&5
20542echo $ECHO_N "checking for openssl/opensslv.h... $ECHO_C" >&6; }
20543if test "${ac_cv_header_openssl_opensslv_h+set}" = set; then
20544  echo $ECHO_N "(cached) $ECHO_C" >&6
20545fi
20546{ echo "$as_me:$LINENO: result: $ac_cv_header_openssl_opensslv_h" >&5
20547echo "${ECHO_T}$ac_cv_header_openssl_opensslv_h" >&6; }
20548else
20549  # Is the header compilable?
20550{ echo "$as_me:$LINENO: checking openssl/opensslv.h usability" >&5
20551echo $ECHO_N "checking openssl/opensslv.h usability... $ECHO_C" >&6; }
20552cat >conftest.$ac_ext <<_ACEOF
20553/* confdefs.h.  */
20554_ACEOF
20555cat confdefs.h >>conftest.$ac_ext
20556cat >>conftest.$ac_ext <<_ACEOF
20557/* end confdefs.h.  */
20558$ac_includes_default
20559#include <openssl/opensslv.h>
20560_ACEOF
20561rm -f conftest.$ac_objext
20562if { (ac_try="$ac_compile"
20563case "(($ac_try" in
20564  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20565  *) ac_try_echo=$ac_try;;
20566esac
20567eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20568  (eval "$ac_compile") 2>conftest.er1
20569  ac_status=$?
20570  grep -v '^ *+' conftest.er1 >conftest.err
20571  rm -f conftest.er1
20572  cat conftest.err >&5
20573  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20574  (exit $ac_status); } && {
20575	 test -z "$ac_c_werror_flag" ||
20576	 test ! -s conftest.err
20577       } && test -s conftest.$ac_objext; then
20578  ac_header_compiler=yes
20579else
20580  echo "$as_me: failed program was:" >&5
20581sed 's/^/| /' conftest.$ac_ext >&5
20582
20583	ac_header_compiler=no
20584fi
20585
20586rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20587{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
20588echo "${ECHO_T}$ac_header_compiler" >&6; }
20589
20590# Is the header present?
20591{ echo "$as_me:$LINENO: checking openssl/opensslv.h presence" >&5
20592echo $ECHO_N "checking openssl/opensslv.h presence... $ECHO_C" >&6; }
20593cat >conftest.$ac_ext <<_ACEOF
20594/* confdefs.h.  */
20595_ACEOF
20596cat confdefs.h >>conftest.$ac_ext
20597cat >>conftest.$ac_ext <<_ACEOF
20598/* end confdefs.h.  */
20599#include <openssl/opensslv.h>
20600_ACEOF
20601if { (ac_try="$ac_cpp conftest.$ac_ext"
20602case "(($ac_try" in
20603  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20604  *) ac_try_echo=$ac_try;;
20605esac
20606eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20607  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
20608  ac_status=$?
20609  grep -v '^ *+' conftest.er1 >conftest.err
20610  rm -f conftest.er1
20611  cat conftest.err >&5
20612  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20613  (exit $ac_status); } >/dev/null && {
20614	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
20615	 test ! -s conftest.err
20616       }; then
20617  ac_header_preproc=yes
20618else
20619  echo "$as_me: failed program was:" >&5
20620sed 's/^/| /' conftest.$ac_ext >&5
20621
20622  ac_header_preproc=no
20623fi
20624
20625rm -f conftest.err conftest.$ac_ext
20626{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
20627echo "${ECHO_T}$ac_header_preproc" >&6; }
20628
20629# So?  What about this header?
20630case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
20631  yes:no: )
20632    { echo "$as_me:$LINENO: WARNING: openssl/opensslv.h: accepted by the compiler, rejected by the preprocessor!" >&5
20633echo "$as_me: WARNING: openssl/opensslv.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
20634    { echo "$as_me:$LINENO: WARNING: openssl/opensslv.h: proceeding with the compiler's result" >&5
20635echo "$as_me: WARNING: openssl/opensslv.h: proceeding with the compiler's result" >&2;}
20636    ac_header_preproc=yes
20637    ;;
20638  no:yes:* )
20639    { echo "$as_me:$LINENO: WARNING: openssl/opensslv.h: present but cannot be compiled" >&5
20640echo "$as_me: WARNING: openssl/opensslv.h: present but cannot be compiled" >&2;}
20641    { echo "$as_me:$LINENO: WARNING: openssl/opensslv.h:     check for missing prerequisite headers?" >&5
20642echo "$as_me: WARNING: openssl/opensslv.h:     check for missing prerequisite headers?" >&2;}
20643    { echo "$as_me:$LINENO: WARNING: openssl/opensslv.h: see the Autoconf documentation" >&5
20644echo "$as_me: WARNING: openssl/opensslv.h: see the Autoconf documentation" >&2;}
20645    { echo "$as_me:$LINENO: WARNING: openssl/opensslv.h:     section \"Present But Cannot Be Compiled\"" >&5
20646echo "$as_me: WARNING: openssl/opensslv.h:     section \"Present But Cannot Be Compiled\"" >&2;}
20647    { echo "$as_me:$LINENO: WARNING: openssl/opensslv.h: proceeding with the preprocessor's result" >&5
20648echo "$as_me: WARNING: openssl/opensslv.h: proceeding with the preprocessor's result" >&2;}
20649    { echo "$as_me:$LINENO: WARNING: openssl/opensslv.h: in the future, the compiler will take precedence" >&5
20650echo "$as_me: WARNING: openssl/opensslv.h: in the future, the compiler will take precedence" >&2;}
20651    ( cat <<\_ASBOX
20652## ------------------------------------------- ##
20653## Report this to openssh-unix-dev@mindrot.org ##
20654## ------------------------------------------- ##
20655_ASBOX
20656     ) | sed "s/^/$as_me: WARNING:     /" >&2
20657    ;;
20658esac
20659{ echo "$as_me:$LINENO: checking for openssl/opensslv.h" >&5
20660echo $ECHO_N "checking for openssl/opensslv.h... $ECHO_C" >&6; }
20661if test "${ac_cv_header_openssl_opensslv_h+set}" = set; then
20662  echo $ECHO_N "(cached) $ECHO_C" >&6
20663else
20664  ac_cv_header_openssl_opensslv_h=$ac_header_preproc
20665fi
20666{ echo "$as_me:$LINENO: result: $ac_cv_header_openssl_opensslv_h" >&5
20667echo "${ECHO_T}$ac_cv_header_openssl_opensslv_h" >&6; }
20668
20669fi
20670if test $ac_cv_header_openssl_opensslv_h = yes; then
20671  :
20672else
20673  { { echo "$as_me:$LINENO: error: *** OpenSSL headers missing - please install first or check config.log ***" >&5
20674echo "$as_me: error: *** OpenSSL headers missing - please install first or check config.log ***" >&2;}
20675   { (exit 1); exit 1; }; }
20676fi
20677
20678
20679			cat >conftest.$ac_ext <<_ACEOF
20680/* confdefs.h.  */
20681_ACEOF
20682cat confdefs.h >>conftest.$ac_ext
20683cat >>conftest.$ac_ext <<_ACEOF
20684/* end confdefs.h.  */
20685
20686/* Override any GCC internal prototype to avoid an error.
20687   Use char because int might match the return type of a GCC
20688   builtin and then its argument prototype would still apply.  */
20689#ifdef __cplusplus
20690extern "C"
20691#endif
20692char RAND_add ();
20693int
20694main ()
20695{
20696return RAND_add ();
20697  ;
20698  return 0;
20699}
20700_ACEOF
20701rm -f conftest.$ac_objext conftest$ac_exeext
20702if { (ac_try="$ac_link"
20703case "(($ac_try" in
20704  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20705  *) ac_try_echo=$ac_try;;
20706esac
20707eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20708  (eval "$ac_link") 2>conftest.er1
20709  ac_status=$?
20710  grep -v '^ *+' conftest.er1 >conftest.err
20711  rm -f conftest.er1
20712  cat conftest.err >&5
20713  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20714  (exit $ac_status); } && {
20715	 test -z "$ac_c_werror_flag" ||
20716	 test ! -s conftest.err
20717       } && test -s conftest$ac_exeext &&
20718       $as_test_x conftest$ac_exeext; then
20719  cat >>confdefs.h <<\_ACEOF
20720#define HAVE_OPENSSL 1
20721_ACEOF
20722
20723else
20724  echo "$as_me: failed program was:" >&5
20725sed 's/^/| /' conftest.$ac_ext >&5
20726
20727
20728					{ { echo "$as_me:$LINENO: error: *** Can't find recent OpenSSL libcrypto (see config.log for details) ***" >&5
20729echo "$as_me: error: *** Can't find recent OpenSSL libcrypto (see config.log for details) ***" >&2;}
20730   { (exit 1); exit 1; }; }
20731
20732
20733fi
20734
20735rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20736      conftest$ac_exeext conftest.$ac_ext
20737
20738
20739fi
20740
20741rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20742      conftest$ac_exeext conftest.$ac_ext
20743
20744	# Determine OpenSSL header version
20745	{ echo "$as_me:$LINENO: checking OpenSSL header version" >&5
20746echo $ECHO_N "checking OpenSSL header version... $ECHO_C" >&6; }
20747	if test "$cross_compiling" = yes; then
20748
20749			{ echo "$as_me:$LINENO: WARNING: cross compiling: not checking" >&5
20750echo "$as_me: WARNING: cross compiling: not checking" >&2;}
20751
20752
20753else
20754  cat >conftest.$ac_ext <<_ACEOF
20755/* confdefs.h.  */
20756_ACEOF
20757cat confdefs.h >>conftest.$ac_ext
20758cat >>conftest.$ac_ext <<_ACEOF
20759/* end confdefs.h.  */
20760
20761	#include <stdio.h>
20762	#include <string.h>
20763	#include <openssl/opensslv.h>
20764	#define DATA "conftest.sslincver"
20765
20766int
20767main ()
20768{
20769
20770		FILE *fd;
20771		int rc;
20772
20773		fd = fopen(DATA,"w");
20774		if(fd == NULL)
20775			exit(1);
20776
20777		if ((rc = fprintf(fd ,"%08x (%s)\n", OPENSSL_VERSION_NUMBER, OPENSSL_VERSION_TEXT)) <0)
20778			exit(1);
20779
20780		exit(0);
20781
20782  ;
20783  return 0;
20784}
20785_ACEOF
20786rm -f conftest$ac_exeext
20787if { (ac_try="$ac_link"
20788case "(($ac_try" in
20789  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20790  *) ac_try_echo=$ac_try;;
20791esac
20792eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20793  (eval "$ac_link") 2>&5
20794  ac_status=$?
20795  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20796  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20797  { (case "(($ac_try" in
20798  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20799  *) ac_try_echo=$ac_try;;
20800esac
20801eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20802  (eval "$ac_try") 2>&5
20803  ac_status=$?
20804  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20805  (exit $ac_status); }; }; then
20806
20807			ssl_header_ver=`cat conftest.sslincver`
20808			{ echo "$as_me:$LINENO: result: $ssl_header_ver" >&5
20809echo "${ECHO_T}$ssl_header_ver" >&6; }
20810
20811else
20812  echo "$as_me: program exited with status $ac_status" >&5
20813echo "$as_me: failed program was:" >&5
20814sed 's/^/| /' conftest.$ac_ext >&5
20815
20816( exit $ac_status )
20817
20818			{ echo "$as_me:$LINENO: result: not found" >&5
20819echo "${ECHO_T}not found" >&6; }
20820			{ { echo "$as_me:$LINENO: error: OpenSSL version header not found." >&5
20821echo "$as_me: error: OpenSSL version header not found." >&2;}
20822   { (exit 1); exit 1; }; }
20823
20824fi
20825rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20826fi
20827
20828
20829
20830	# Determine OpenSSL library version
20831	{ echo "$as_me:$LINENO: checking OpenSSL library version" >&5
20832echo $ECHO_N "checking OpenSSL library version... $ECHO_C" >&6; }
20833	if test "$cross_compiling" = yes; then
20834
20835			{ echo "$as_me:$LINENO: WARNING: cross compiling: not checking" >&5
20836echo "$as_me: WARNING: cross compiling: not checking" >&2;}
20837
20838
20839else
20840  cat >conftest.$ac_ext <<_ACEOF
20841/* confdefs.h.  */
20842_ACEOF
20843cat confdefs.h >>conftest.$ac_ext
20844cat >>conftest.$ac_ext <<_ACEOF
20845/* end confdefs.h.  */
20846
20847	#include <stdio.h>
20848	#include <string.h>
20849	#include <openssl/opensslv.h>
20850	#include <openssl/crypto.h>
20851	#define DATA "conftest.ssllibver"
20852
20853int
20854main ()
20855{
20856
20857		FILE *fd;
20858		int rc;
20859
20860		fd = fopen(DATA,"w");
20861		if(fd == NULL)
20862			exit(1);
20863
20864		if ((rc = fprintf(fd ,"%08x (%s)\n", SSLeay(),
20865		    SSLeay_version(SSLEAY_VERSION))) <0)
20866			exit(1);
20867
20868		exit(0);
20869
20870  ;
20871  return 0;
20872}
20873_ACEOF
20874rm -f conftest$ac_exeext
20875if { (ac_try="$ac_link"
20876case "(($ac_try" in
20877  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20878  *) ac_try_echo=$ac_try;;
20879esac
20880eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20881  (eval "$ac_link") 2>&5
20882  ac_status=$?
20883  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20884  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20885  { (case "(($ac_try" in
20886  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20887  *) ac_try_echo=$ac_try;;
20888esac
20889eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20890  (eval "$ac_try") 2>&5
20891  ac_status=$?
20892  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20893  (exit $ac_status); }; }; then
20894
20895			ssl_library_ver=`cat conftest.ssllibver`
20896			# Check version is supported.
20897			case "$ssl_library_ver" in
20898				0090[0-7]*|009080[0-5]*)
20899					{ { echo "$as_me:$LINENO: error: OpenSSL >= 0.9.8f required (have \"$ssl_library_ver\")" >&5
20900echo "$as_me: error: OpenSSL >= 0.9.8f required (have \"$ssl_library_ver\")" >&2;}
20901   { (exit 1); exit 1; }; }
20902			                ;;
20903			        *) ;;
20904			esac
20905			{ echo "$as_me:$LINENO: result: $ssl_library_ver" >&5
20906echo "${ECHO_T}$ssl_library_ver" >&6; }
20907
20908else
20909  echo "$as_me: program exited with status $ac_status" >&5
20910echo "$as_me: failed program was:" >&5
20911sed 's/^/| /' conftest.$ac_ext >&5
20912
20913( exit $ac_status )
20914
20915			{ echo "$as_me:$LINENO: result: not found" >&5
20916echo "${ECHO_T}not found" >&6; }
20917			{ { echo "$as_me:$LINENO: error: OpenSSL library not found." >&5
20918echo "$as_me: error: OpenSSL library not found." >&2;}
20919   { (exit 1); exit 1; }; }
20920
20921fi
20922rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
20923fi
20924
20925
20926
20927	# Sanity check OpenSSL headers
20928	{ echo "$as_me:$LINENO: checking whether OpenSSL's headers match the library" >&5
20929echo $ECHO_N "checking whether OpenSSL's headers match the library... $ECHO_C" >&6; }
20930	if test "$cross_compiling" = yes; then
20931
20932			{ echo "$as_me:$LINENO: WARNING: cross compiling: not checking" >&5
20933echo "$as_me: WARNING: cross compiling: not checking" >&2;}
20934
20935
20936else
20937  cat >conftest.$ac_ext <<_ACEOF
20938/* confdefs.h.  */
20939_ACEOF
20940cat confdefs.h >>conftest.$ac_ext
20941cat >>conftest.$ac_ext <<_ACEOF
20942/* end confdefs.h.  */
20943
20944	#include <string.h>
20945	#include <openssl/opensslv.h>
20946
20947int
20948main ()
20949{
20950
20951		exit(SSLeay() == OPENSSL_VERSION_NUMBER ? 0 : 1);
20952
20953  ;
20954  return 0;
20955}
20956_ACEOF
20957rm -f conftest$ac_exeext
20958if { (ac_try="$ac_link"
20959case "(($ac_try" in
20960  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20961  *) ac_try_echo=$ac_try;;
20962esac
20963eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20964  (eval "$ac_link") 2>&5
20965  ac_status=$?
20966  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20967  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
20968  { (case "(($ac_try" in
20969  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20970  *) ac_try_echo=$ac_try;;
20971esac
20972eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
20973  (eval "$ac_try") 2>&5
20974  ac_status=$?
20975  echo "$as_me:$LINENO: \$? = $ac_status" >&5
20976  (exit $ac_status); }; }; then
20977
20978			{ echo "$as_me:$LINENO: result: yes" >&5
20979echo "${ECHO_T}yes" >&6; }
20980
20981else
20982  echo "$as_me: program exited with status $ac_status" >&5
20983echo "$as_me: failed program was:" >&5
20984sed 's/^/| /' conftest.$ac_ext >&5
20985
20986( exit $ac_status )
20987
20988			{ echo "$as_me:$LINENO: result: no" >&5
20989echo "${ECHO_T}no" >&6; }
20990			if test "x$openssl_check_nonfatal" = "x"; then
20991				{ { echo "$as_me:$LINENO: error: Your OpenSSL headers do not match your
20992	library. Check config.log for details.
20993	If you are sure your installation is consistent, you can disable the check
20994	by running \"./configure --without-openssl-header-check\".
20995	Also see contrib/findssl.sh for help identifying header/library mismatches.
20996	" >&5
20997echo "$as_me: error: Your OpenSSL headers do not match your
20998	library. Check config.log for details.
20999	If you are sure your installation is consistent, you can disable the check
21000	by running \"./configure --without-openssl-header-check\".
21001	Also see contrib/findssl.sh for help identifying header/library mismatches.
21002	" >&2;}
21003   { (exit 1); exit 1; }; }
21004			else
21005				{ echo "$as_me:$LINENO: WARNING: Your OpenSSL headers do not match your
21006	library. Check config.log for details.
21007	Also see contrib/findssl.sh for help identifying header/library mismatches." >&5
21008echo "$as_me: WARNING: Your OpenSSL headers do not match your
21009	library. Check config.log for details.
21010	Also see contrib/findssl.sh for help identifying header/library mismatches." >&2;}
21011			fi
21012
21013fi
21014rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
21015fi
21016
21017
21018
21019	{ echo "$as_me:$LINENO: checking if programs using OpenSSL functions will link" >&5
21020echo $ECHO_N "checking if programs using OpenSSL functions will link... $ECHO_C" >&6; }
21021	cat >conftest.$ac_ext <<_ACEOF
21022/* confdefs.h.  */
21023_ACEOF
21024cat confdefs.h >>conftest.$ac_ext
21025cat >>conftest.$ac_ext <<_ACEOF
21026/* end confdefs.h.  */
21027 #include <openssl/evp.h>
21028int
21029main ()
21030{
21031 SSLeay_add_all_algorithms();
21032  ;
21033  return 0;
21034}
21035_ACEOF
21036rm -f conftest.$ac_objext conftest$ac_exeext
21037if { (ac_try="$ac_link"
21038case "(($ac_try" in
21039  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21040  *) ac_try_echo=$ac_try;;
21041esac
21042eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21043  (eval "$ac_link") 2>conftest.er1
21044  ac_status=$?
21045  grep -v '^ *+' conftest.er1 >conftest.err
21046  rm -f conftest.er1
21047  cat conftest.err >&5
21048  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21049  (exit $ac_status); } && {
21050	 test -z "$ac_c_werror_flag" ||
21051	 test ! -s conftest.err
21052       } && test -s conftest$ac_exeext &&
21053       $as_test_x conftest$ac_exeext; then
21054
21055			{ echo "$as_me:$LINENO: result: yes" >&5
21056echo "${ECHO_T}yes" >&6; }
21057
21058else
21059  echo "$as_me: failed program was:" >&5
21060sed 's/^/| /' conftest.$ac_ext >&5
21061
21062
21063			{ echo "$as_me:$LINENO: result: no" >&5
21064echo "${ECHO_T}no" >&6; }
21065			saved_LIBS="$LIBS"
21066			LIBS="$LIBS -ldl"
21067			{ echo "$as_me:$LINENO: checking if programs using OpenSSL need -ldl" >&5
21068echo $ECHO_N "checking if programs using OpenSSL need -ldl... $ECHO_C" >&6; }
21069			cat >conftest.$ac_ext <<_ACEOF
21070/* confdefs.h.  */
21071_ACEOF
21072cat confdefs.h >>conftest.$ac_ext
21073cat >>conftest.$ac_ext <<_ACEOF
21074/* end confdefs.h.  */
21075 #include <openssl/evp.h>
21076int
21077main ()
21078{
21079 SSLeay_add_all_algorithms();
21080  ;
21081  return 0;
21082}
21083_ACEOF
21084rm -f conftest.$ac_objext conftest$ac_exeext
21085if { (ac_try="$ac_link"
21086case "(($ac_try" in
21087  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21088  *) ac_try_echo=$ac_try;;
21089esac
21090eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21091  (eval "$ac_link") 2>conftest.er1
21092  ac_status=$?
21093  grep -v '^ *+' conftest.er1 >conftest.err
21094  rm -f conftest.er1
21095  cat conftest.err >&5
21096  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21097  (exit $ac_status); } && {
21098	 test -z "$ac_c_werror_flag" ||
21099	 test ! -s conftest.err
21100       } && test -s conftest$ac_exeext &&
21101       $as_test_x conftest$ac_exeext; then
21102
21103					{ echo "$as_me:$LINENO: result: yes" >&5
21104echo "${ECHO_T}yes" >&6; }
21105
21106else
21107  echo "$as_me: failed program was:" >&5
21108sed 's/^/| /' conftest.$ac_ext >&5
21109
21110
21111					{ echo "$as_me:$LINENO: result: no" >&5
21112echo "${ECHO_T}no" >&6; }
21113					LIBS="$saved_LIBS"
21114
21115
21116fi
21117
21118rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21119      conftest$ac_exeext conftest.$ac_ext
21120
21121
21122fi
21123
21124rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21125      conftest$ac_exeext conftest.$ac_ext
21126
21127
21128
21129
21130
21131
21132
21133
21134
21135
21136
21137for ac_func in  \
21138		BN_is_prime_ex \
21139		DSA_generate_parameters_ex \
21140		EVP_DigestInit_ex \
21141		EVP_DigestFinal_ex \
21142		EVP_MD_CTX_init \
21143		EVP_MD_CTX_cleanup \
21144		EVP_MD_CTX_copy_ex \
21145		HMAC_CTX_init \
21146		RSA_generate_key_ex \
21147		RSA_get_default_method \
21148
21149do
21150as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
21151{ echo "$as_me:$LINENO: checking for $ac_func" >&5
21152echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
21153if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21154  echo $ECHO_N "(cached) $ECHO_C" >&6
21155else
21156  cat >conftest.$ac_ext <<_ACEOF
21157/* confdefs.h.  */
21158_ACEOF
21159cat confdefs.h >>conftest.$ac_ext
21160cat >>conftest.$ac_ext <<_ACEOF
21161/* end confdefs.h.  */
21162/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21163   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21164#define $ac_func innocuous_$ac_func
21165
21166/* System header to define __stub macros and hopefully few prototypes,
21167    which can conflict with char $ac_func (); below.
21168    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21169    <limits.h> exists even on freestanding compilers.  */
21170
21171#ifdef __STDC__
21172# include <limits.h>
21173#else
21174# include <assert.h>
21175#endif
21176
21177#undef $ac_func
21178
21179/* Override any GCC internal prototype to avoid an error.
21180   Use char because int might match the return type of a GCC
21181   builtin and then its argument prototype would still apply.  */
21182#ifdef __cplusplus
21183extern "C"
21184#endif
21185char $ac_func ();
21186/* The GNU C library defines this for functions which it implements
21187    to always fail with ENOSYS.  Some functions are actually named
21188    something starting with __ and the normal name is an alias.  */
21189#if defined __stub_$ac_func || defined __stub___$ac_func
21190choke me
21191#endif
21192
21193int
21194main ()
21195{
21196return $ac_func ();
21197  ;
21198  return 0;
21199}
21200_ACEOF
21201rm -f conftest.$ac_objext conftest$ac_exeext
21202if { (ac_try="$ac_link"
21203case "(($ac_try" in
21204  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21205  *) ac_try_echo=$ac_try;;
21206esac
21207eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21208  (eval "$ac_link") 2>conftest.er1
21209  ac_status=$?
21210  grep -v '^ *+' conftest.er1 >conftest.err
21211  rm -f conftest.er1
21212  cat conftest.err >&5
21213  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21214  (exit $ac_status); } && {
21215	 test -z "$ac_c_werror_flag" ||
21216	 test ! -s conftest.err
21217       } && test -s conftest$ac_exeext &&
21218       $as_test_x conftest$ac_exeext; then
21219  eval "$as_ac_var=yes"
21220else
21221  echo "$as_me: failed program was:" >&5
21222sed 's/^/| /' conftest.$ac_ext >&5
21223
21224	eval "$as_ac_var=no"
21225fi
21226
21227rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21228      conftest$ac_exeext conftest.$ac_ext
21229fi
21230ac_res=`eval echo '${'$as_ac_var'}'`
21231	       { echo "$as_me:$LINENO: result: $ac_res" >&5
21232echo "${ECHO_T}$ac_res" >&6; }
21233if test `eval echo '${'$as_ac_var'}'` = yes; then
21234  cat >>confdefs.h <<_ACEOF
21235#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
21236_ACEOF
21237
21238fi
21239done
21240
21241
21242	if test "x$openssl_engine" = "xyes" ; then
21243		{ echo "$as_me:$LINENO: checking for OpenSSL ENGINE support" >&5
21244echo $ECHO_N "checking for OpenSSL ENGINE support... $ECHO_C" >&6; }
21245		cat >conftest.$ac_ext <<_ACEOF
21246/* confdefs.h.  */
21247_ACEOF
21248cat confdefs.h >>conftest.$ac_ext
21249cat >>conftest.$ac_ext <<_ACEOF
21250/* end confdefs.h.  */
21251
21252	#include <openssl/engine.h>
21253
21254int
21255main ()
21256{
21257
21258				ENGINE_load_builtin_engines();
21259				ENGINE_register_all_complete();
21260
21261  ;
21262  return 0;
21263}
21264_ACEOF
21265rm -f conftest.$ac_objext
21266if { (ac_try="$ac_compile"
21267case "(($ac_try" in
21268  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21269  *) ac_try_echo=$ac_try;;
21270esac
21271eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21272  (eval "$ac_compile") 2>conftest.er1
21273  ac_status=$?
21274  grep -v '^ *+' conftest.er1 >conftest.err
21275  rm -f conftest.er1
21276  cat conftest.err >&5
21277  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21278  (exit $ac_status); } && {
21279	 test -z "$ac_c_werror_flag" ||
21280	 test ! -s conftest.err
21281       } && test -s conftest.$ac_objext; then
21282   { echo "$as_me:$LINENO: result: yes" >&5
21283echo "${ECHO_T}yes" >&6; }
21284
21285cat >>confdefs.h <<\_ACEOF
21286#define USE_OPENSSL_ENGINE 1
21287_ACEOF
21288
21289
21290else
21291  echo "$as_me: failed program was:" >&5
21292sed 's/^/| /' conftest.$ac_ext >&5
21293
21294	 { { echo "$as_me:$LINENO: error: OpenSSL ENGINE support not found" >&5
21295echo "$as_me: error: OpenSSL ENGINE support not found" >&2;}
21296   { (exit 1); exit 1; }; }
21297
21298fi
21299
21300rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21301	fi
21302
21303	# Check for OpenSSL without EVP_aes_{192,256}_cbc
21304	{ echo "$as_me:$LINENO: checking whether OpenSSL has crippled AES support" >&5
21305echo $ECHO_N "checking whether OpenSSL has crippled AES support... $ECHO_C" >&6; }
21306	cat >conftest.$ac_ext <<_ACEOF
21307/* confdefs.h.  */
21308_ACEOF
21309cat confdefs.h >>conftest.$ac_ext
21310cat >>conftest.$ac_ext <<_ACEOF
21311/* end confdefs.h.  */
21312
21313	#include <string.h>
21314	#include <openssl/evp.h>
21315
21316int
21317main ()
21318{
21319
21320		exit(EVP_aes_192_cbc() == NULL || EVP_aes_256_cbc() == NULL);
21321
21322  ;
21323  return 0;
21324}
21325_ACEOF
21326rm -f conftest.$ac_objext conftest$ac_exeext
21327if { (ac_try="$ac_link"
21328case "(($ac_try" in
21329  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21330  *) ac_try_echo=$ac_try;;
21331esac
21332eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21333  (eval "$ac_link") 2>conftest.er1
21334  ac_status=$?
21335  grep -v '^ *+' conftest.er1 >conftest.err
21336  rm -f conftest.er1
21337  cat conftest.err >&5
21338  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21339  (exit $ac_status); } && {
21340	 test -z "$ac_c_werror_flag" ||
21341	 test ! -s conftest.err
21342       } && test -s conftest$ac_exeext &&
21343       $as_test_x conftest$ac_exeext; then
21344
21345			{ echo "$as_me:$LINENO: result: no" >&5
21346echo "${ECHO_T}no" >&6; }
21347
21348else
21349  echo "$as_me: failed program was:" >&5
21350sed 's/^/| /' conftest.$ac_ext >&5
21351
21352
21353			{ echo "$as_me:$LINENO: result: yes" >&5
21354echo "${ECHO_T}yes" >&6; }
21355
21356cat >>confdefs.h <<\_ACEOF
21357#define OPENSSL_LOBOTOMISED_AES 1
21358_ACEOF
21359
21360
21361
21362fi
21363
21364rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21365      conftest$ac_exeext conftest.$ac_ext
21366
21367	# Check for OpenSSL with EVP_aes_*ctr
21368	{ echo "$as_me:$LINENO: checking whether OpenSSL has AES CTR via EVP" >&5
21369echo $ECHO_N "checking whether OpenSSL has AES CTR via EVP... $ECHO_C" >&6; }
21370	cat >conftest.$ac_ext <<_ACEOF
21371/* confdefs.h.  */
21372_ACEOF
21373cat confdefs.h >>conftest.$ac_ext
21374cat >>conftest.$ac_ext <<_ACEOF
21375/* end confdefs.h.  */
21376
21377	#include <string.h>
21378	#include <openssl/evp.h>
21379
21380int
21381main ()
21382{
21383
21384		exit(EVP_aes_128_ctr() == NULL ||
21385		    EVP_aes_192_cbc() == NULL ||
21386		    EVP_aes_256_cbc() == NULL);
21387
21388  ;
21389  return 0;
21390}
21391_ACEOF
21392rm -f conftest.$ac_objext conftest$ac_exeext
21393if { (ac_try="$ac_link"
21394case "(($ac_try" in
21395  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21396  *) ac_try_echo=$ac_try;;
21397esac
21398eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21399  (eval "$ac_link") 2>conftest.er1
21400  ac_status=$?
21401  grep -v '^ *+' conftest.er1 >conftest.err
21402  rm -f conftest.er1
21403  cat conftest.err >&5
21404  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21405  (exit $ac_status); } && {
21406	 test -z "$ac_c_werror_flag" ||
21407	 test ! -s conftest.err
21408       } && test -s conftest$ac_exeext &&
21409       $as_test_x conftest$ac_exeext; then
21410
21411			{ echo "$as_me:$LINENO: result: yes" >&5
21412echo "${ECHO_T}yes" >&6; }
21413
21414cat >>confdefs.h <<\_ACEOF
21415#define OPENSSL_HAVE_EVPCTR 1
21416_ACEOF
21417
21418
21419else
21420  echo "$as_me: failed program was:" >&5
21421sed 's/^/| /' conftest.$ac_ext >&5
21422
21423
21424			{ echo "$as_me:$LINENO: result: no" >&5
21425echo "${ECHO_T}no" >&6; }
21426
21427
21428fi
21429
21430rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21431      conftest$ac_exeext conftest.$ac_ext
21432
21433	# Check for OpenSSL with EVP_aes_*gcm
21434	{ echo "$as_me:$LINENO: checking whether OpenSSL has AES GCM via EVP" >&5
21435echo $ECHO_N "checking whether OpenSSL has AES GCM via EVP... $ECHO_C" >&6; }
21436	cat >conftest.$ac_ext <<_ACEOF
21437/* confdefs.h.  */
21438_ACEOF
21439cat confdefs.h >>conftest.$ac_ext
21440cat >>conftest.$ac_ext <<_ACEOF
21441/* end confdefs.h.  */
21442
21443	#include <string.h>
21444	#include <openssl/evp.h>
21445
21446int
21447main ()
21448{
21449
21450		exit(EVP_aes_128_gcm() == NULL ||
21451		    EVP_aes_256_gcm() == NULL ||
21452		    EVP_CTRL_GCM_SET_IV_FIXED == 0 ||
21453		    EVP_CTRL_GCM_IV_GEN == 0 ||
21454		    EVP_CTRL_GCM_SET_TAG == 0 ||
21455		    EVP_CTRL_GCM_GET_TAG == 0 ||
21456		    EVP_CIPHER_CTX_ctrl(NULL, 0, 0, NULL) == 0);
21457
21458  ;
21459  return 0;
21460}
21461_ACEOF
21462rm -f conftest.$ac_objext conftest$ac_exeext
21463if { (ac_try="$ac_link"
21464case "(($ac_try" in
21465  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21466  *) ac_try_echo=$ac_try;;
21467esac
21468eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21469  (eval "$ac_link") 2>conftest.er1
21470  ac_status=$?
21471  grep -v '^ *+' conftest.er1 >conftest.err
21472  rm -f conftest.er1
21473  cat conftest.err >&5
21474  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21475  (exit $ac_status); } && {
21476	 test -z "$ac_c_werror_flag" ||
21477	 test ! -s conftest.err
21478       } && test -s conftest$ac_exeext &&
21479       $as_test_x conftest$ac_exeext; then
21480
21481			{ echo "$as_me:$LINENO: result: yes" >&5
21482echo "${ECHO_T}yes" >&6; }
21483
21484cat >>confdefs.h <<\_ACEOF
21485#define OPENSSL_HAVE_EVPGCM 1
21486_ACEOF
21487
21488
21489else
21490  echo "$as_me: failed program was:" >&5
21491sed 's/^/| /' conftest.$ac_ext >&5
21492
21493
21494			{ echo "$as_me:$LINENO: result: no" >&5
21495echo "${ECHO_T}no" >&6; }
21496			unsupported_algorithms="$unsupported_cipers \
21497			   aes128-gcm@openssh.com aes256-gcm@openssh.com"
21498
21499
21500fi
21501
21502rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21503      conftest$ac_exeext conftest.$ac_ext
21504
21505	{ echo "$as_me:$LINENO: checking for library containing EVP_CIPHER_CTX_ctrl" >&5
21506echo $ECHO_N "checking for library containing EVP_CIPHER_CTX_ctrl... $ECHO_C" >&6; }
21507if test "${ac_cv_search_EVP_CIPHER_CTX_ctrl+set}" = set; then
21508  echo $ECHO_N "(cached) $ECHO_C" >&6
21509else
21510  ac_func_search_save_LIBS=$LIBS
21511cat >conftest.$ac_ext <<_ACEOF
21512/* confdefs.h.  */
21513_ACEOF
21514cat confdefs.h >>conftest.$ac_ext
21515cat >>conftest.$ac_ext <<_ACEOF
21516/* end confdefs.h.  */
21517
21518/* Override any GCC internal prototype to avoid an error.
21519   Use char because int might match the return type of a GCC
21520   builtin and then its argument prototype would still apply.  */
21521#ifdef __cplusplus
21522extern "C"
21523#endif
21524char EVP_CIPHER_CTX_ctrl ();
21525int
21526main ()
21527{
21528return EVP_CIPHER_CTX_ctrl ();
21529  ;
21530  return 0;
21531}
21532_ACEOF
21533for ac_lib in '' crypto; do
21534  if test -z "$ac_lib"; then
21535    ac_res="none required"
21536  else
21537    ac_res=-l$ac_lib
21538    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
21539  fi
21540  rm -f conftest.$ac_objext conftest$ac_exeext
21541if { (ac_try="$ac_link"
21542case "(($ac_try" in
21543  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21544  *) ac_try_echo=$ac_try;;
21545esac
21546eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21547  (eval "$ac_link") 2>conftest.er1
21548  ac_status=$?
21549  grep -v '^ *+' conftest.er1 >conftest.err
21550  rm -f conftest.er1
21551  cat conftest.err >&5
21552  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21553  (exit $ac_status); } && {
21554	 test -z "$ac_c_werror_flag" ||
21555	 test ! -s conftest.err
21556       } && test -s conftest$ac_exeext &&
21557       $as_test_x conftest$ac_exeext; then
21558  ac_cv_search_EVP_CIPHER_CTX_ctrl=$ac_res
21559else
21560  echo "$as_me: failed program was:" >&5
21561sed 's/^/| /' conftest.$ac_ext >&5
21562
21563
21564fi
21565
21566rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21567      conftest$ac_exeext
21568  if test "${ac_cv_search_EVP_CIPHER_CTX_ctrl+set}" = set; then
21569  break
21570fi
21571done
21572if test "${ac_cv_search_EVP_CIPHER_CTX_ctrl+set}" = set; then
21573  :
21574else
21575  ac_cv_search_EVP_CIPHER_CTX_ctrl=no
21576fi
21577rm conftest.$ac_ext
21578LIBS=$ac_func_search_save_LIBS
21579fi
21580{ echo "$as_me:$LINENO: result: $ac_cv_search_EVP_CIPHER_CTX_ctrl" >&5
21581echo "${ECHO_T}$ac_cv_search_EVP_CIPHER_CTX_ctrl" >&6; }
21582ac_res=$ac_cv_search_EVP_CIPHER_CTX_ctrl
21583if test "$ac_res" != no; then
21584  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
21585
21586cat >>confdefs.h <<\_ACEOF
21587#define HAVE_EVP_CIPHER_CTX_CTRL 1
21588_ACEOF
21589
21590fi
21591
21592
21593	{ echo "$as_me:$LINENO: checking if EVP_DigestUpdate returns an int" >&5
21594echo $ECHO_N "checking if EVP_DigestUpdate returns an int... $ECHO_C" >&6; }
21595	cat >conftest.$ac_ext <<_ACEOF
21596/* confdefs.h.  */
21597_ACEOF
21598cat confdefs.h >>conftest.$ac_ext
21599cat >>conftest.$ac_ext <<_ACEOF
21600/* end confdefs.h.  */
21601
21602	#include <string.h>
21603	#include <openssl/evp.h>
21604
21605int
21606main ()
21607{
21608
21609		if(EVP_DigestUpdate(NULL, NULL,0))
21610			exit(0);
21611
21612  ;
21613  return 0;
21614}
21615_ACEOF
21616rm -f conftest.$ac_objext conftest$ac_exeext
21617if { (ac_try="$ac_link"
21618case "(($ac_try" in
21619  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21620  *) ac_try_echo=$ac_try;;
21621esac
21622eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21623  (eval "$ac_link") 2>conftest.er1
21624  ac_status=$?
21625  grep -v '^ *+' conftest.er1 >conftest.err
21626  rm -f conftest.er1
21627  cat conftest.err >&5
21628  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21629  (exit $ac_status); } && {
21630	 test -z "$ac_c_werror_flag" ||
21631	 test ! -s conftest.err
21632       } && test -s conftest$ac_exeext &&
21633       $as_test_x conftest$ac_exeext; then
21634
21635			{ echo "$as_me:$LINENO: result: yes" >&5
21636echo "${ECHO_T}yes" >&6; }
21637
21638else
21639  echo "$as_me: failed program was:" >&5
21640sed 's/^/| /' conftest.$ac_ext >&5
21641
21642
21643			{ echo "$as_me:$LINENO: result: no" >&5
21644echo "${ECHO_T}no" >&6; }
21645
21646cat >>confdefs.h <<\_ACEOF
21647#define OPENSSL_EVP_DIGESTUPDATE_VOID 1
21648_ACEOF
21649
21650
21651
21652fi
21653
21654rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21655      conftest$ac_exeext conftest.$ac_ext
21656
21657	# Some systems want crypt() from libcrypt, *not* the version in OpenSSL,
21658	# because the system crypt() is more featureful.
21659	if test "x$check_for_libcrypt_before" = "x1"; then
21660
21661{ echo "$as_me:$LINENO: checking for crypt in -lcrypt" >&5
21662echo $ECHO_N "checking for crypt in -lcrypt... $ECHO_C" >&6; }
21663if test "${ac_cv_lib_crypt_crypt+set}" = set; then
21664  echo $ECHO_N "(cached) $ECHO_C" >&6
21665else
21666  ac_check_lib_save_LIBS=$LIBS
21667LIBS="-lcrypt  $LIBS"
21668cat >conftest.$ac_ext <<_ACEOF
21669/* confdefs.h.  */
21670_ACEOF
21671cat confdefs.h >>conftest.$ac_ext
21672cat >>conftest.$ac_ext <<_ACEOF
21673/* end confdefs.h.  */
21674
21675/* Override any GCC internal prototype to avoid an error.
21676   Use char because int might match the return type of a GCC
21677   builtin and then its argument prototype would still apply.  */
21678#ifdef __cplusplus
21679extern "C"
21680#endif
21681char crypt ();
21682int
21683main ()
21684{
21685return crypt ();
21686  ;
21687  return 0;
21688}
21689_ACEOF
21690rm -f conftest.$ac_objext conftest$ac_exeext
21691if { (ac_try="$ac_link"
21692case "(($ac_try" in
21693  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21694  *) ac_try_echo=$ac_try;;
21695esac
21696eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21697  (eval "$ac_link") 2>conftest.er1
21698  ac_status=$?
21699  grep -v '^ *+' conftest.er1 >conftest.err
21700  rm -f conftest.er1
21701  cat conftest.err >&5
21702  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21703  (exit $ac_status); } && {
21704	 test -z "$ac_c_werror_flag" ||
21705	 test ! -s conftest.err
21706       } && test -s conftest$ac_exeext &&
21707       $as_test_x conftest$ac_exeext; then
21708  ac_cv_lib_crypt_crypt=yes
21709else
21710  echo "$as_me: failed program was:" >&5
21711sed 's/^/| /' conftest.$ac_ext >&5
21712
21713	ac_cv_lib_crypt_crypt=no
21714fi
21715
21716rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21717      conftest$ac_exeext conftest.$ac_ext
21718LIBS=$ac_check_lib_save_LIBS
21719fi
21720{ echo "$as_me:$LINENO: result: $ac_cv_lib_crypt_crypt" >&5
21721echo "${ECHO_T}$ac_cv_lib_crypt_crypt" >&6; }
21722if test $ac_cv_lib_crypt_crypt = yes; then
21723  cat >>confdefs.h <<_ACEOF
21724#define HAVE_LIBCRYPT 1
21725_ACEOF
21726
21727  LIBS="-lcrypt $LIBS"
21728
21729fi
21730
21731	fi
21732
21733	# Some Linux systems (Slackware) need crypt() from libcrypt, *not* the
21734	# version in OpenSSL.
21735	if test "x$check_for_libcrypt_later" = "x1"; then
21736		{ echo "$as_me:$LINENO: checking for crypt in -lcrypt" >&5
21737echo $ECHO_N "checking for crypt in -lcrypt... $ECHO_C" >&6; }
21738if test "${ac_cv_lib_crypt_crypt+set}" = set; then
21739  echo $ECHO_N "(cached) $ECHO_C" >&6
21740else
21741  ac_check_lib_save_LIBS=$LIBS
21742LIBS="-lcrypt  $LIBS"
21743cat >conftest.$ac_ext <<_ACEOF
21744/* confdefs.h.  */
21745_ACEOF
21746cat confdefs.h >>conftest.$ac_ext
21747cat >>conftest.$ac_ext <<_ACEOF
21748/* end confdefs.h.  */
21749
21750/* Override any GCC internal prototype to avoid an error.
21751   Use char because int might match the return type of a GCC
21752   builtin and then its argument prototype would still apply.  */
21753#ifdef __cplusplus
21754extern "C"
21755#endif
21756char crypt ();
21757int
21758main ()
21759{
21760return crypt ();
21761  ;
21762  return 0;
21763}
21764_ACEOF
21765rm -f conftest.$ac_objext conftest$ac_exeext
21766if { (ac_try="$ac_link"
21767case "(($ac_try" in
21768  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21769  *) ac_try_echo=$ac_try;;
21770esac
21771eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21772  (eval "$ac_link") 2>conftest.er1
21773  ac_status=$?
21774  grep -v '^ *+' conftest.er1 >conftest.err
21775  rm -f conftest.er1
21776  cat conftest.err >&5
21777  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21778  (exit $ac_status); } && {
21779	 test -z "$ac_c_werror_flag" ||
21780	 test ! -s conftest.err
21781       } && test -s conftest$ac_exeext &&
21782       $as_test_x conftest$ac_exeext; then
21783  ac_cv_lib_crypt_crypt=yes
21784else
21785  echo "$as_me: failed program was:" >&5
21786sed 's/^/| /' conftest.$ac_ext >&5
21787
21788	ac_cv_lib_crypt_crypt=no
21789fi
21790
21791rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21792      conftest$ac_exeext conftest.$ac_ext
21793LIBS=$ac_check_lib_save_LIBS
21794fi
21795{ echo "$as_me:$LINENO: result: $ac_cv_lib_crypt_crypt" >&5
21796echo "${ECHO_T}$ac_cv_lib_crypt_crypt" >&6; }
21797if test $ac_cv_lib_crypt_crypt = yes; then
21798  LIBS="$LIBS -lcrypt"
21799fi
21800
21801	fi
21802
21803
21804for ac_func in crypt DES_crypt
21805do
21806as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
21807{ echo "$as_me:$LINENO: checking for $ac_func" >&5
21808echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
21809if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21810  echo $ECHO_N "(cached) $ECHO_C" >&6
21811else
21812  cat >conftest.$ac_ext <<_ACEOF
21813/* confdefs.h.  */
21814_ACEOF
21815cat confdefs.h >>conftest.$ac_ext
21816cat >>conftest.$ac_ext <<_ACEOF
21817/* end confdefs.h.  */
21818/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21819   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21820#define $ac_func innocuous_$ac_func
21821
21822/* System header to define __stub macros and hopefully few prototypes,
21823    which can conflict with char $ac_func (); below.
21824    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21825    <limits.h> exists even on freestanding compilers.  */
21826
21827#ifdef __STDC__
21828# include <limits.h>
21829#else
21830# include <assert.h>
21831#endif
21832
21833#undef $ac_func
21834
21835/* Override any GCC internal prototype to avoid an error.
21836   Use char because int might match the return type of a GCC
21837   builtin and then its argument prototype would still apply.  */
21838#ifdef __cplusplus
21839extern "C"
21840#endif
21841char $ac_func ();
21842/* The GNU C library defines this for functions which it implements
21843    to always fail with ENOSYS.  Some functions are actually named
21844    something starting with __ and the normal name is an alias.  */
21845#if defined __stub_$ac_func || defined __stub___$ac_func
21846choke me
21847#endif
21848
21849int
21850main ()
21851{
21852return $ac_func ();
21853  ;
21854  return 0;
21855}
21856_ACEOF
21857rm -f conftest.$ac_objext conftest$ac_exeext
21858if { (ac_try="$ac_link"
21859case "(($ac_try" in
21860  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21861  *) ac_try_echo=$ac_try;;
21862esac
21863eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21864  (eval "$ac_link") 2>conftest.er1
21865  ac_status=$?
21866  grep -v '^ *+' conftest.er1 >conftest.err
21867  rm -f conftest.er1
21868  cat conftest.err >&5
21869  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21870  (exit $ac_status); } && {
21871	 test -z "$ac_c_werror_flag" ||
21872	 test ! -s conftest.err
21873       } && test -s conftest$ac_exeext &&
21874       $as_test_x conftest$ac_exeext; then
21875  eval "$as_ac_var=yes"
21876else
21877  echo "$as_me: failed program was:" >&5
21878sed 's/^/| /' conftest.$ac_ext >&5
21879
21880	eval "$as_ac_var=no"
21881fi
21882
21883rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21884      conftest$ac_exeext conftest.$ac_ext
21885fi
21886ac_res=`eval echo '${'$as_ac_var'}'`
21887	       { echo "$as_me:$LINENO: result: $ac_res" >&5
21888echo "${ECHO_T}$ac_res" >&6; }
21889if test `eval echo '${'$as_ac_var'}'` = yes; then
21890  cat >>confdefs.h <<_ACEOF
21891#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
21892_ACEOF
21893
21894fi
21895done
21896
21897
21898	# Search for SHA256 support in libc and/or OpenSSL
21899
21900
21901for ac_func in SHA256_Update EVP_sha256
21902do
21903as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
21904{ echo "$as_me:$LINENO: checking for $ac_func" >&5
21905echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
21906if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21907  echo $ECHO_N "(cached) $ECHO_C" >&6
21908else
21909  cat >conftest.$ac_ext <<_ACEOF
21910/* confdefs.h.  */
21911_ACEOF
21912cat confdefs.h >>conftest.$ac_ext
21913cat >>conftest.$ac_ext <<_ACEOF
21914/* end confdefs.h.  */
21915/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21916   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21917#define $ac_func innocuous_$ac_func
21918
21919/* System header to define __stub macros and hopefully few prototypes,
21920    which can conflict with char $ac_func (); below.
21921    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21922    <limits.h> exists even on freestanding compilers.  */
21923
21924#ifdef __STDC__
21925# include <limits.h>
21926#else
21927# include <assert.h>
21928#endif
21929
21930#undef $ac_func
21931
21932/* Override any GCC internal prototype to avoid an error.
21933   Use char because int might match the return type of a GCC
21934   builtin and then its argument prototype would still apply.  */
21935#ifdef __cplusplus
21936extern "C"
21937#endif
21938char $ac_func ();
21939/* The GNU C library defines this for functions which it implements
21940    to always fail with ENOSYS.  Some functions are actually named
21941    something starting with __ and the normal name is an alias.  */
21942#if defined __stub_$ac_func || defined __stub___$ac_func
21943choke me
21944#endif
21945
21946int
21947main ()
21948{
21949return $ac_func ();
21950  ;
21951  return 0;
21952}
21953_ACEOF
21954rm -f conftest.$ac_objext conftest$ac_exeext
21955if { (ac_try="$ac_link"
21956case "(($ac_try" in
21957  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21958  *) ac_try_echo=$ac_try;;
21959esac
21960eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
21961  (eval "$ac_link") 2>conftest.er1
21962  ac_status=$?
21963  grep -v '^ *+' conftest.er1 >conftest.err
21964  rm -f conftest.er1
21965  cat conftest.err >&5
21966  echo "$as_me:$LINENO: \$? = $ac_status" >&5
21967  (exit $ac_status); } && {
21968	 test -z "$ac_c_werror_flag" ||
21969	 test ! -s conftest.err
21970       } && test -s conftest$ac_exeext &&
21971       $as_test_x conftest$ac_exeext; then
21972  eval "$as_ac_var=yes"
21973else
21974  echo "$as_me: failed program was:" >&5
21975sed 's/^/| /' conftest.$ac_ext >&5
21976
21977	eval "$as_ac_var=no"
21978fi
21979
21980rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21981      conftest$ac_exeext conftest.$ac_ext
21982fi
21983ac_res=`eval echo '${'$as_ac_var'}'`
21984	       { echo "$as_me:$LINENO: result: $ac_res" >&5
21985echo "${ECHO_T}$ac_res" >&6; }
21986if test `eval echo '${'$as_ac_var'}'` = yes; then
21987  cat >>confdefs.h <<_ACEOF
21988#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
21989_ACEOF
21990
21991else
21992  unsupported_algorithms="$unsupported_algorithms \
21993		hmac-sha2-256 hmac-sha2-512 \
21994		diffie-hellman-group-exchange-sha256 \
21995		hmac-sha2-256-etm@openssh.com hmac-sha2-512-etm@openssh.com"
21996
21997
21998fi
21999done
22000
22001	# Search for RIPE-MD support in OpenSSL
22002
22003for ac_func in EVP_ripemd160
22004do
22005as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
22006{ echo "$as_me:$LINENO: checking for $ac_func" >&5
22007echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
22008if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22009  echo $ECHO_N "(cached) $ECHO_C" >&6
22010else
22011  cat >conftest.$ac_ext <<_ACEOF
22012/* confdefs.h.  */
22013_ACEOF
22014cat confdefs.h >>conftest.$ac_ext
22015cat >>conftest.$ac_ext <<_ACEOF
22016/* end confdefs.h.  */
22017/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22018   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22019#define $ac_func innocuous_$ac_func
22020
22021/* System header to define __stub macros and hopefully few prototypes,
22022    which can conflict with char $ac_func (); below.
22023    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22024    <limits.h> exists even on freestanding compilers.  */
22025
22026#ifdef __STDC__
22027# include <limits.h>
22028#else
22029# include <assert.h>
22030#endif
22031
22032#undef $ac_func
22033
22034/* Override any GCC internal prototype to avoid an error.
22035   Use char because int might match the return type of a GCC
22036   builtin and then its argument prototype would still apply.  */
22037#ifdef __cplusplus
22038extern "C"
22039#endif
22040char $ac_func ();
22041/* The GNU C library defines this for functions which it implements
22042    to always fail with ENOSYS.  Some functions are actually named
22043    something starting with __ and the normal name is an alias.  */
22044#if defined __stub_$ac_func || defined __stub___$ac_func
22045choke me
22046#endif
22047
22048int
22049main ()
22050{
22051return $ac_func ();
22052  ;
22053  return 0;
22054}
22055_ACEOF
22056rm -f conftest.$ac_objext conftest$ac_exeext
22057if { (ac_try="$ac_link"
22058case "(($ac_try" in
22059  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22060  *) ac_try_echo=$ac_try;;
22061esac
22062eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22063  (eval "$ac_link") 2>conftest.er1
22064  ac_status=$?
22065  grep -v '^ *+' conftest.er1 >conftest.err
22066  rm -f conftest.er1
22067  cat conftest.err >&5
22068  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22069  (exit $ac_status); } && {
22070	 test -z "$ac_c_werror_flag" ||
22071	 test ! -s conftest.err
22072       } && test -s conftest$ac_exeext &&
22073       $as_test_x conftest$ac_exeext; then
22074  eval "$as_ac_var=yes"
22075else
22076  echo "$as_me: failed program was:" >&5
22077sed 's/^/| /' conftest.$ac_ext >&5
22078
22079	eval "$as_ac_var=no"
22080fi
22081
22082rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22083      conftest$ac_exeext conftest.$ac_ext
22084fi
22085ac_res=`eval echo '${'$as_ac_var'}'`
22086	       { echo "$as_me:$LINENO: result: $ac_res" >&5
22087echo "${ECHO_T}$ac_res" >&6; }
22088if test `eval echo '${'$as_ac_var'}'` = yes; then
22089  cat >>confdefs.h <<_ACEOF
22090#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
22091_ACEOF
22092
22093else
22094  unsupported_algorithms="$unsupported_algorithms \
22095		hmac-ripemd160
22096		hmac-ripemd160@openssh.com
22097		hmac-ripemd160-etm@openssh.com"
22098
22099
22100fi
22101done
22102
22103
22104	# Check complete ECC support in OpenSSL
22105	{ echo "$as_me:$LINENO: checking whether OpenSSL has NID_X9_62_prime256v1" >&5
22106echo $ECHO_N "checking whether OpenSSL has NID_X9_62_prime256v1... $ECHO_C" >&6; }
22107	cat >conftest.$ac_ext <<_ACEOF
22108/* confdefs.h.  */
22109_ACEOF
22110cat confdefs.h >>conftest.$ac_ext
22111cat >>conftest.$ac_ext <<_ACEOF
22112/* end confdefs.h.  */
22113
22114	#include <openssl/ec.h>
22115	#include <openssl/ecdh.h>
22116	#include <openssl/ecdsa.h>
22117	#include <openssl/evp.h>
22118	#include <openssl/objects.h>
22119	#include <openssl/opensslv.h>
22120	#if OPENSSL_VERSION_NUMBER < 0x0090807f /* 0.9.8g */
22121	# error "OpenSSL < 0.9.8g has unreliable ECC code"
22122	#endif
22123
22124int
22125main ()
22126{
22127
22128		EC_KEY *e = EC_KEY_new_by_curve_name(NID_X9_62_prime256v1);
22129		const EVP_MD *m = EVP_sha256(); /* We need this too */
22130
22131  ;
22132  return 0;
22133}
22134_ACEOF
22135rm -f conftest.$ac_objext conftest$ac_exeext
22136if { (ac_try="$ac_link"
22137case "(($ac_try" in
22138  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22139  *) ac_try_echo=$ac_try;;
22140esac
22141eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22142  (eval "$ac_link") 2>conftest.er1
22143  ac_status=$?
22144  grep -v '^ *+' conftest.er1 >conftest.err
22145  rm -f conftest.er1
22146  cat conftest.err >&5
22147  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22148  (exit $ac_status); } && {
22149	 test -z "$ac_c_werror_flag" ||
22150	 test ! -s conftest.err
22151       } && test -s conftest$ac_exeext &&
22152       $as_test_x conftest$ac_exeext; then
22153   { echo "$as_me:$LINENO: result: yes" >&5
22154echo "${ECHO_T}yes" >&6; }
22155		  enable_nistp256=1
22156else
22157  echo "$as_me: failed program was:" >&5
22158sed 's/^/| /' conftest.$ac_ext >&5
22159
22160	 { echo "$as_me:$LINENO: result: no" >&5
22161echo "${ECHO_T}no" >&6; }
22162
22163fi
22164
22165rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22166      conftest$ac_exeext conftest.$ac_ext
22167
22168	{ echo "$as_me:$LINENO: checking whether OpenSSL has NID_secp384r1" >&5
22169echo $ECHO_N "checking whether OpenSSL has NID_secp384r1... $ECHO_C" >&6; }
22170	cat >conftest.$ac_ext <<_ACEOF
22171/* confdefs.h.  */
22172_ACEOF
22173cat confdefs.h >>conftest.$ac_ext
22174cat >>conftest.$ac_ext <<_ACEOF
22175/* end confdefs.h.  */
22176
22177	#include <openssl/ec.h>
22178	#include <openssl/ecdh.h>
22179	#include <openssl/ecdsa.h>
22180	#include <openssl/evp.h>
22181	#include <openssl/objects.h>
22182	#include <openssl/opensslv.h>
22183	#if OPENSSL_VERSION_NUMBER < 0x0090807f /* 0.9.8g */
22184	# error "OpenSSL < 0.9.8g has unreliable ECC code"
22185	#endif
22186
22187int
22188main ()
22189{
22190
22191		EC_KEY *e = EC_KEY_new_by_curve_name(NID_secp384r1);
22192		const EVP_MD *m = EVP_sha384(); /* We need this too */
22193
22194  ;
22195  return 0;
22196}
22197_ACEOF
22198rm -f conftest.$ac_objext conftest$ac_exeext
22199if { (ac_try="$ac_link"
22200case "(($ac_try" in
22201  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22202  *) ac_try_echo=$ac_try;;
22203esac
22204eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22205  (eval "$ac_link") 2>conftest.er1
22206  ac_status=$?
22207  grep -v '^ *+' conftest.er1 >conftest.err
22208  rm -f conftest.er1
22209  cat conftest.err >&5
22210  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22211  (exit $ac_status); } && {
22212	 test -z "$ac_c_werror_flag" ||
22213	 test ! -s conftest.err
22214       } && test -s conftest$ac_exeext &&
22215       $as_test_x conftest$ac_exeext; then
22216   { echo "$as_me:$LINENO: result: yes" >&5
22217echo "${ECHO_T}yes" >&6; }
22218		  enable_nistp384=1
22219else
22220  echo "$as_me: failed program was:" >&5
22221sed 's/^/| /' conftest.$ac_ext >&5
22222
22223	 { echo "$as_me:$LINENO: result: no" >&5
22224echo "${ECHO_T}no" >&6; }
22225
22226fi
22227
22228rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22229      conftest$ac_exeext conftest.$ac_ext
22230
22231	{ echo "$as_me:$LINENO: checking whether OpenSSL has NID_secp521r1" >&5
22232echo $ECHO_N "checking whether OpenSSL has NID_secp521r1... $ECHO_C" >&6; }
22233	cat >conftest.$ac_ext <<_ACEOF
22234/* confdefs.h.  */
22235_ACEOF
22236cat confdefs.h >>conftest.$ac_ext
22237cat >>conftest.$ac_ext <<_ACEOF
22238/* end confdefs.h.  */
22239
22240	#include <openssl/ec.h>
22241	#include <openssl/ecdh.h>
22242	#include <openssl/ecdsa.h>
22243	#include <openssl/evp.h>
22244	#include <openssl/objects.h>
22245	#include <openssl/opensslv.h>
22246	#if OPENSSL_VERSION_NUMBER < 0x0090807f /* 0.9.8g */
22247	# error "OpenSSL < 0.9.8g has unreliable ECC code"
22248	#endif
22249
22250int
22251main ()
22252{
22253
22254		EC_KEY *e = EC_KEY_new_by_curve_name(NID_secp521r1);
22255		const EVP_MD *m = EVP_sha512(); /* We need this too */
22256
22257  ;
22258  return 0;
22259}
22260_ACEOF
22261rm -f conftest.$ac_objext conftest$ac_exeext
22262if { (ac_try="$ac_link"
22263case "(($ac_try" in
22264  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22265  *) ac_try_echo=$ac_try;;
22266esac
22267eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22268  (eval "$ac_link") 2>conftest.er1
22269  ac_status=$?
22270  grep -v '^ *+' conftest.er1 >conftest.err
22271  rm -f conftest.er1
22272  cat conftest.err >&5
22273  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22274  (exit $ac_status); } && {
22275	 test -z "$ac_c_werror_flag" ||
22276	 test ! -s conftest.err
22277       } && test -s conftest$ac_exeext &&
22278       $as_test_x conftest$ac_exeext; then
22279   { echo "$as_me:$LINENO: result: yes" >&5
22280echo "${ECHO_T}yes" >&6; }
22281		  { echo "$as_me:$LINENO: checking if OpenSSL's NID_secp521r1 is functional" >&5
22282echo $ECHO_N "checking if OpenSSL's NID_secp521r1 is functional... $ECHO_C" >&6; }
22283		  if test "$cross_compiling" = yes; then
22284   { echo "$as_me:$LINENO: WARNING: cross-compiling: assuming yes" >&5
22285echo "$as_me: WARNING: cross-compiling: assuming yes" >&2;}
22286			  enable_nistp521=1
22287
22288else
22289  cat >conftest.$ac_ext <<_ACEOF
22290/* confdefs.h.  */
22291_ACEOF
22292cat confdefs.h >>conftest.$ac_ext
22293cat >>conftest.$ac_ext <<_ACEOF
22294/* end confdefs.h.  */
22295
22296	#include <openssl/ec.h>
22297	#include <openssl/ecdh.h>
22298	#include <openssl/ecdsa.h>
22299	#include <openssl/evp.h>
22300	#include <openssl/objects.h>
22301	#include <openssl/opensslv.h>
22302
22303int
22304main ()
22305{
22306
22307			EC_KEY *e = EC_KEY_new_by_curve_name(NID_secp521r1);
22308			const EVP_MD *m = EVP_sha512(); /* We need this too */
22309			exit(e == NULL || m == NULL);
22310
22311  ;
22312  return 0;
22313}
22314_ACEOF
22315rm -f conftest$ac_exeext
22316if { (ac_try="$ac_link"
22317case "(($ac_try" in
22318  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22319  *) ac_try_echo=$ac_try;;
22320esac
22321eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22322  (eval "$ac_link") 2>&5
22323  ac_status=$?
22324  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22325  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22326  { (case "(($ac_try" in
22327  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22328  *) ac_try_echo=$ac_try;;
22329esac
22330eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22331  (eval "$ac_try") 2>&5
22332  ac_status=$?
22333  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22334  (exit $ac_status); }; }; then
22335   { echo "$as_me:$LINENO: result: yes" >&5
22336echo "${ECHO_T}yes" >&6; }
22337			  enable_nistp521=1
22338else
22339  echo "$as_me: program exited with status $ac_status" >&5
22340echo "$as_me: failed program was:" >&5
22341sed 's/^/| /' conftest.$ac_ext >&5
22342
22343( exit $ac_status )
22344 { echo "$as_me:$LINENO: result: no" >&5
22345echo "${ECHO_T}no" >&6; }
22346fi
22347rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22348fi
22349
22350
22351else
22352  echo "$as_me: failed program was:" >&5
22353sed 's/^/| /' conftest.$ac_ext >&5
22354
22355	{ echo "$as_me:$LINENO: result: no" >&5
22356echo "${ECHO_T}no" >&6; }
22357
22358fi
22359
22360rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22361      conftest$ac_exeext conftest.$ac_ext
22362
22363	COMMENT_OUT_ECC="#no ecc#"
22364	TEST_SSH_ECC=no
22365
22366	if test x$enable_nistp256 = x1 || test x$enable_nistp384 = x1 || \
22367	    test x$enable_nistp521 = x1; then
22368
22369cat >>confdefs.h <<\_ACEOF
22370#define OPENSSL_HAS_ECC 1
22371_ACEOF
22372
22373	fi
22374	if test x$enable_nistp256 = x1; then
22375
22376cat >>confdefs.h <<\_ACEOF
22377#define OPENSSL_HAS_NISTP256 1
22378_ACEOF
22379
22380		TEST_SSH_ECC=yes
22381		COMMENT_OUT_ECC=""
22382	else
22383		unsupported_algorithms="$unsupported_algorithms ecdsa-sha2-nistp256 \
22384		    ecdh-sha2-nistp256 ecdsa-sha2-nistp256-cert-v01@openssh.com"
22385	fi
22386	if test x$enable_nistp384 = x1; then
22387
22388cat >>confdefs.h <<\_ACEOF
22389#define OPENSSL_HAS_NISTP384 1
22390_ACEOF
22391
22392		TEST_SSH_ECC=yes
22393		COMMENT_OUT_ECC=""
22394	else
22395		unsupported_algorithms="$unsupported_algorithms ecdsa-sha2-nistp384 \
22396		    ecdh-sha2-nistp384 ecdsa-sha2-nistp384-cert-v01@openssh.com"
22397	fi
22398	if test x$enable_nistp521 = x1; then
22399
22400cat >>confdefs.h <<\_ACEOF
22401#define OPENSSL_HAS_NISTP521 1
22402_ACEOF
22403
22404		TEST_SSH_ECC=yes
22405		COMMENT_OUT_ECC=""
22406	else
22407		unsupported_algorithms="$unsupported_algorithms ecdh-sha2-nistp521 \
22408		    ecdsa-sha2-nistp521 ecdsa-sha2-nistp521-cert-v01@openssh.com"
22409	fi
22410
22411
22412
22413else
22414	{ echo "$as_me:$LINENO: checking for crypt in -lcrypt" >&5
22415echo $ECHO_N "checking for crypt in -lcrypt... $ECHO_C" >&6; }
22416if test "${ac_cv_lib_crypt_crypt+set}" = set; then
22417  echo $ECHO_N "(cached) $ECHO_C" >&6
22418else
22419  ac_check_lib_save_LIBS=$LIBS
22420LIBS="-lcrypt  $LIBS"
22421cat >conftest.$ac_ext <<_ACEOF
22422/* confdefs.h.  */
22423_ACEOF
22424cat confdefs.h >>conftest.$ac_ext
22425cat >>conftest.$ac_ext <<_ACEOF
22426/* end confdefs.h.  */
22427
22428/* Override any GCC internal prototype to avoid an error.
22429   Use char because int might match the return type of a GCC
22430   builtin and then its argument prototype would still apply.  */
22431#ifdef __cplusplus
22432extern "C"
22433#endif
22434char crypt ();
22435int
22436main ()
22437{
22438return crypt ();
22439  ;
22440  return 0;
22441}
22442_ACEOF
22443rm -f conftest.$ac_objext conftest$ac_exeext
22444if { (ac_try="$ac_link"
22445case "(($ac_try" in
22446  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22447  *) ac_try_echo=$ac_try;;
22448esac
22449eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22450  (eval "$ac_link") 2>conftest.er1
22451  ac_status=$?
22452  grep -v '^ *+' conftest.er1 >conftest.err
22453  rm -f conftest.er1
22454  cat conftest.err >&5
22455  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22456  (exit $ac_status); } && {
22457	 test -z "$ac_c_werror_flag" ||
22458	 test ! -s conftest.err
22459       } && test -s conftest$ac_exeext &&
22460       $as_test_x conftest$ac_exeext; then
22461  ac_cv_lib_crypt_crypt=yes
22462else
22463  echo "$as_me: failed program was:" >&5
22464sed 's/^/| /' conftest.$ac_ext >&5
22465
22466	ac_cv_lib_crypt_crypt=no
22467fi
22468
22469rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22470      conftest$ac_exeext conftest.$ac_ext
22471LIBS=$ac_check_lib_save_LIBS
22472fi
22473{ echo "$as_me:$LINENO: result: $ac_cv_lib_crypt_crypt" >&5
22474echo "${ECHO_T}$ac_cv_lib_crypt_crypt" >&6; }
22475if test $ac_cv_lib_crypt_crypt = yes; then
22476  LIBS="$LIBS -lcrypt"
22477fi
22478
22479
22480for ac_func in crypt
22481do
22482as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
22483{ echo "$as_me:$LINENO: checking for $ac_func" >&5
22484echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
22485if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22486  echo $ECHO_N "(cached) $ECHO_C" >&6
22487else
22488  cat >conftest.$ac_ext <<_ACEOF
22489/* confdefs.h.  */
22490_ACEOF
22491cat confdefs.h >>conftest.$ac_ext
22492cat >>conftest.$ac_ext <<_ACEOF
22493/* end confdefs.h.  */
22494/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22495   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22496#define $ac_func innocuous_$ac_func
22497
22498/* System header to define __stub macros and hopefully few prototypes,
22499    which can conflict with char $ac_func (); below.
22500    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22501    <limits.h> exists even on freestanding compilers.  */
22502
22503#ifdef __STDC__
22504# include <limits.h>
22505#else
22506# include <assert.h>
22507#endif
22508
22509#undef $ac_func
22510
22511/* Override any GCC internal prototype to avoid an error.
22512   Use char because int might match the return type of a GCC
22513   builtin and then its argument prototype would still apply.  */
22514#ifdef __cplusplus
22515extern "C"
22516#endif
22517char $ac_func ();
22518/* The GNU C library defines this for functions which it implements
22519    to always fail with ENOSYS.  Some functions are actually named
22520    something starting with __ and the normal name is an alias.  */
22521#if defined __stub_$ac_func || defined __stub___$ac_func
22522choke me
22523#endif
22524
22525int
22526main ()
22527{
22528return $ac_func ();
22529  ;
22530  return 0;
22531}
22532_ACEOF
22533rm -f conftest.$ac_objext conftest$ac_exeext
22534if { (ac_try="$ac_link"
22535case "(($ac_try" in
22536  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22537  *) ac_try_echo=$ac_try;;
22538esac
22539eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22540  (eval "$ac_link") 2>conftest.er1
22541  ac_status=$?
22542  grep -v '^ *+' conftest.er1 >conftest.err
22543  rm -f conftest.er1
22544  cat conftest.err >&5
22545  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22546  (exit $ac_status); } && {
22547	 test -z "$ac_c_werror_flag" ||
22548	 test ! -s conftest.err
22549       } && test -s conftest$ac_exeext &&
22550       $as_test_x conftest$ac_exeext; then
22551  eval "$as_ac_var=yes"
22552else
22553  echo "$as_me: failed program was:" >&5
22554sed 's/^/| /' conftest.$ac_ext >&5
22555
22556	eval "$as_ac_var=no"
22557fi
22558
22559rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22560      conftest$ac_exeext conftest.$ac_ext
22561fi
22562ac_res=`eval echo '${'$as_ac_var'}'`
22563	       { echo "$as_me:$LINENO: result: $ac_res" >&5
22564echo "${ECHO_T}$ac_res" >&6; }
22565if test `eval echo '${'$as_ac_var'}'` = yes; then
22566  cat >>confdefs.h <<_ACEOF
22567#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
22568_ACEOF
22569
22570fi
22571done
22572
22573fi
22574
22575
22576
22577
22578
22579for ac_func in  \
22580	arc4random \
22581	arc4random_buf \
22582	arc4random_stir \
22583	arc4random_uniform \
22584
22585do
22586as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
22587{ echo "$as_me:$LINENO: checking for $ac_func" >&5
22588echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
22589if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22590  echo $ECHO_N "(cached) $ECHO_C" >&6
22591else
22592  cat >conftest.$ac_ext <<_ACEOF
22593/* confdefs.h.  */
22594_ACEOF
22595cat confdefs.h >>conftest.$ac_ext
22596cat >>conftest.$ac_ext <<_ACEOF
22597/* end confdefs.h.  */
22598/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22599   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22600#define $ac_func innocuous_$ac_func
22601
22602/* System header to define __stub macros and hopefully few prototypes,
22603    which can conflict with char $ac_func (); below.
22604    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22605    <limits.h> exists even on freestanding compilers.  */
22606
22607#ifdef __STDC__
22608# include <limits.h>
22609#else
22610# include <assert.h>
22611#endif
22612
22613#undef $ac_func
22614
22615/* Override any GCC internal prototype to avoid an error.
22616   Use char because int might match the return type of a GCC
22617   builtin and then its argument prototype would still apply.  */
22618#ifdef __cplusplus
22619extern "C"
22620#endif
22621char $ac_func ();
22622/* The GNU C library defines this for functions which it implements
22623    to always fail with ENOSYS.  Some functions are actually named
22624    something starting with __ and the normal name is an alias.  */
22625#if defined __stub_$ac_func || defined __stub___$ac_func
22626choke me
22627#endif
22628
22629int
22630main ()
22631{
22632return $ac_func ();
22633  ;
22634  return 0;
22635}
22636_ACEOF
22637rm -f conftest.$ac_objext conftest$ac_exeext
22638if { (ac_try="$ac_link"
22639case "(($ac_try" in
22640  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22641  *) ac_try_echo=$ac_try;;
22642esac
22643eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22644  (eval "$ac_link") 2>conftest.er1
22645  ac_status=$?
22646  grep -v '^ *+' conftest.er1 >conftest.err
22647  rm -f conftest.er1
22648  cat conftest.err >&5
22649  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22650  (exit $ac_status); } && {
22651	 test -z "$ac_c_werror_flag" ||
22652	 test ! -s conftest.err
22653       } && test -s conftest$ac_exeext &&
22654       $as_test_x conftest$ac_exeext; then
22655  eval "$as_ac_var=yes"
22656else
22657  echo "$as_me: failed program was:" >&5
22658sed 's/^/| /' conftest.$ac_ext >&5
22659
22660	eval "$as_ac_var=no"
22661fi
22662
22663rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22664      conftest$ac_exeext conftest.$ac_ext
22665fi
22666ac_res=`eval echo '${'$as_ac_var'}'`
22667	       { echo "$as_me:$LINENO: result: $ac_res" >&5
22668echo "${ECHO_T}$ac_res" >&6; }
22669if test `eval echo '${'$as_ac_var'}'` = yes; then
22670  cat >>confdefs.h <<_ACEOF
22671#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
22672_ACEOF
22673
22674fi
22675done
22676
22677
22678saved_LIBS="$LIBS"
22679{ echo "$as_me:$LINENO: checking for ia_openinfo in -liaf" >&5
22680echo $ECHO_N "checking for ia_openinfo in -liaf... $ECHO_C" >&6; }
22681if test "${ac_cv_lib_iaf_ia_openinfo+set}" = set; then
22682  echo $ECHO_N "(cached) $ECHO_C" >&6
22683else
22684  ac_check_lib_save_LIBS=$LIBS
22685LIBS="-liaf  $LIBS"
22686cat >conftest.$ac_ext <<_ACEOF
22687/* confdefs.h.  */
22688_ACEOF
22689cat confdefs.h >>conftest.$ac_ext
22690cat >>conftest.$ac_ext <<_ACEOF
22691/* end confdefs.h.  */
22692
22693/* Override any GCC internal prototype to avoid an error.
22694   Use char because int might match the return type of a GCC
22695   builtin and then its argument prototype would still apply.  */
22696#ifdef __cplusplus
22697extern "C"
22698#endif
22699char ia_openinfo ();
22700int
22701main ()
22702{
22703return ia_openinfo ();
22704  ;
22705  return 0;
22706}
22707_ACEOF
22708rm -f conftest.$ac_objext conftest$ac_exeext
22709if { (ac_try="$ac_link"
22710case "(($ac_try" in
22711  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22712  *) ac_try_echo=$ac_try;;
22713esac
22714eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22715  (eval "$ac_link") 2>conftest.er1
22716  ac_status=$?
22717  grep -v '^ *+' conftest.er1 >conftest.err
22718  rm -f conftest.er1
22719  cat conftest.err >&5
22720  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22721  (exit $ac_status); } && {
22722	 test -z "$ac_c_werror_flag" ||
22723	 test ! -s conftest.err
22724       } && test -s conftest$ac_exeext &&
22725       $as_test_x conftest$ac_exeext; then
22726  ac_cv_lib_iaf_ia_openinfo=yes
22727else
22728  echo "$as_me: failed program was:" >&5
22729sed 's/^/| /' conftest.$ac_ext >&5
22730
22731	ac_cv_lib_iaf_ia_openinfo=no
22732fi
22733
22734rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22735      conftest$ac_exeext conftest.$ac_ext
22736LIBS=$ac_check_lib_save_LIBS
22737fi
22738{ echo "$as_me:$LINENO: result: $ac_cv_lib_iaf_ia_openinfo" >&5
22739echo "${ECHO_T}$ac_cv_lib_iaf_ia_openinfo" >&6; }
22740if test $ac_cv_lib_iaf_ia_openinfo = yes; then
22741
22742	LIBS="$LIBS -liaf"
22743
22744for ac_func in set_id
22745do
22746as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
22747{ echo "$as_me:$LINENO: checking for $ac_func" >&5
22748echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
22749if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22750  echo $ECHO_N "(cached) $ECHO_C" >&6
22751else
22752  cat >conftest.$ac_ext <<_ACEOF
22753/* confdefs.h.  */
22754_ACEOF
22755cat confdefs.h >>conftest.$ac_ext
22756cat >>conftest.$ac_ext <<_ACEOF
22757/* end confdefs.h.  */
22758/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22759   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22760#define $ac_func innocuous_$ac_func
22761
22762/* System header to define __stub macros and hopefully few prototypes,
22763    which can conflict with char $ac_func (); below.
22764    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22765    <limits.h> exists even on freestanding compilers.  */
22766
22767#ifdef __STDC__
22768# include <limits.h>
22769#else
22770# include <assert.h>
22771#endif
22772
22773#undef $ac_func
22774
22775/* Override any GCC internal prototype to avoid an error.
22776   Use char because int might match the return type of a GCC
22777   builtin and then its argument prototype would still apply.  */
22778#ifdef __cplusplus
22779extern "C"
22780#endif
22781char $ac_func ();
22782/* The GNU C library defines this for functions which it implements
22783    to always fail with ENOSYS.  Some functions are actually named
22784    something starting with __ and the normal name is an alias.  */
22785#if defined __stub_$ac_func || defined __stub___$ac_func
22786choke me
22787#endif
22788
22789int
22790main ()
22791{
22792return $ac_func ();
22793  ;
22794  return 0;
22795}
22796_ACEOF
22797rm -f conftest.$ac_objext conftest$ac_exeext
22798if { (ac_try="$ac_link"
22799case "(($ac_try" in
22800  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22801  *) ac_try_echo=$ac_try;;
22802esac
22803eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22804  (eval "$ac_link") 2>conftest.er1
22805  ac_status=$?
22806  grep -v '^ *+' conftest.er1 >conftest.err
22807  rm -f conftest.er1
22808  cat conftest.err >&5
22809  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22810  (exit $ac_status); } && {
22811	 test -z "$ac_c_werror_flag" ||
22812	 test ! -s conftest.err
22813       } && test -s conftest$ac_exeext &&
22814       $as_test_x conftest$ac_exeext; then
22815  eval "$as_ac_var=yes"
22816else
22817  echo "$as_me: failed program was:" >&5
22818sed 's/^/| /' conftest.$ac_ext >&5
22819
22820	eval "$as_ac_var=no"
22821fi
22822
22823rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22824      conftest$ac_exeext conftest.$ac_ext
22825fi
22826ac_res=`eval echo '${'$as_ac_var'}'`
22827	       { echo "$as_me:$LINENO: result: $ac_res" >&5
22828echo "${ECHO_T}$ac_res" >&6; }
22829if test `eval echo '${'$as_ac_var'}'` = yes; then
22830  cat >>confdefs.h <<_ACEOF
22831#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
22832_ACEOF
22833 SSHDLIBS="$SSHDLIBS -liaf"
22834
22835cat >>confdefs.h <<\_ACEOF
22836#define HAVE_LIBIAF 1
22837_ACEOF
22838
22839
22840fi
22841done
22842
22843
22844fi
22845
22846LIBS="$saved_LIBS"
22847
22848### Configure cryptographic random number support
22849
22850# Check wheter OpenSSL seeds itself
22851if test "x$openssl" = "xyes" ; then
22852	{ echo "$as_me:$LINENO: checking whether OpenSSL's PRNG is internally seeded" >&5
22853echo $ECHO_N "checking whether OpenSSL's PRNG is internally seeded... $ECHO_C" >&6; }
22854	if test "$cross_compiling" = yes; then
22855
22856			{ echo "$as_me:$LINENO: WARNING: cross compiling: assuming yes" >&5
22857echo "$as_me: WARNING: cross compiling: assuming yes" >&2;}
22858			# This is safe, since we will fatal() at runtime if
22859			# OpenSSL is not seeded correctly.
22860			OPENSSL_SEEDS_ITSELF=yes
22861
22862
22863else
22864  cat >conftest.$ac_ext <<_ACEOF
22865/* confdefs.h.  */
22866_ACEOF
22867cat confdefs.h >>conftest.$ac_ext
22868cat >>conftest.$ac_ext <<_ACEOF
22869/* end confdefs.h.  */
22870
22871	#include <string.h>
22872	#include <openssl/rand.h>
22873
22874int
22875main ()
22876{
22877
22878		exit(RAND_status() == 1 ? 0 : 1);
22879
22880  ;
22881  return 0;
22882}
22883_ACEOF
22884rm -f conftest$ac_exeext
22885if { (ac_try="$ac_link"
22886case "(($ac_try" in
22887  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22888  *) ac_try_echo=$ac_try;;
22889esac
22890eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22891  (eval "$ac_link") 2>&5
22892  ac_status=$?
22893  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22894  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
22895  { (case "(($ac_try" in
22896  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22897  *) ac_try_echo=$ac_try;;
22898esac
22899eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
22900  (eval "$ac_try") 2>&5
22901  ac_status=$?
22902  echo "$as_me:$LINENO: \$? = $ac_status" >&5
22903  (exit $ac_status); }; }; then
22904
22905			OPENSSL_SEEDS_ITSELF=yes
22906			{ echo "$as_me:$LINENO: result: yes" >&5
22907echo "${ECHO_T}yes" >&6; }
22908
22909else
22910  echo "$as_me: program exited with status $ac_status" >&5
22911echo "$as_me: failed program was:" >&5
22912sed 's/^/| /' conftest.$ac_ext >&5
22913
22914( exit $ac_status )
22915
22916			{ echo "$as_me:$LINENO: result: no" >&5
22917echo "${ECHO_T}no" >&6; }
22918
22919fi
22920rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
22921fi
22922
22923
22924fi
22925
22926# PRNGD TCP socket
22927
22928# Check whether --with-prngd-port was given.
22929if test "${with_prngd_port+set}" = set; then
22930  withval=$with_prngd_port;
22931		case "$withval" in
22932		no)
22933			withval=""
22934			;;
22935		[0-9]*)
22936			;;
22937		*)
22938			{ { echo "$as_me:$LINENO: error: You must specify a numeric port number for --with-prngd-port" >&5
22939echo "$as_me: error: You must specify a numeric port number for --with-prngd-port" >&2;}
22940   { (exit 1); exit 1; }; }
22941			;;
22942		esac
22943		if test ! -z "$withval" ; then
22944			PRNGD_PORT="$withval"
22945
22946cat >>confdefs.h <<_ACEOF
22947#define PRNGD_PORT $PRNGD_PORT
22948_ACEOF
22949
22950		fi
22951
22952
22953fi
22954
22955
22956# PRNGD Unix domain socket
22957
22958# Check whether --with-prngd-socket was given.
22959if test "${with_prngd_socket+set}" = set; then
22960  withval=$with_prngd_socket;
22961		case "$withval" in
22962		yes)
22963			withval="/var/run/egd-pool"
22964			;;
22965		no)
22966			withval=""
22967			;;
22968		/*)
22969			;;
22970		*)
22971			{ { echo "$as_me:$LINENO: error: You must specify an absolute path to the entropy socket" >&5
22972echo "$as_me: error: You must specify an absolute path to the entropy socket" >&2;}
22973   { (exit 1); exit 1; }; }
22974			;;
22975		esac
22976
22977		if test ! -z "$withval" ; then
22978			if test ! -z "$PRNGD_PORT" ; then
22979				{ { echo "$as_me:$LINENO: error: You may not specify both a PRNGD/EGD port and socket" >&5
22980echo "$as_me: error: You may not specify both a PRNGD/EGD port and socket" >&2;}
22981   { (exit 1); exit 1; }; }
22982			fi
22983			if test ! -r "$withval" ; then
22984				{ echo "$as_me:$LINENO: WARNING: Entropy socket is not readable" >&5
22985echo "$as_me: WARNING: Entropy socket is not readable" >&2;}
22986			fi
22987			PRNGD_SOCKET="$withval"
22988
22989cat >>confdefs.h <<_ACEOF
22990#define PRNGD_SOCKET "$PRNGD_SOCKET"
22991_ACEOF
22992
22993		fi
22994
22995else
22996
22997		# Check for existing socket only if we don't have a random device already
22998		if test "x$OPENSSL_SEEDS_ITSELF" != "xyes" ; then
22999			{ echo "$as_me:$LINENO: checking for PRNGD/EGD socket" >&5
23000echo $ECHO_N "checking for PRNGD/EGD socket... $ECHO_C" >&6; }
23001			# Insert other locations here
23002			for sock in /var/run/egd-pool /dev/egd-pool /etc/entropy; do
23003				if test -r $sock && $TEST_MINUS_S_SH -c "test -S $sock -o -p $sock" ; then
23004					PRNGD_SOCKET="$sock"
23005					cat >>confdefs.h <<_ACEOF
23006#define PRNGD_SOCKET "$PRNGD_SOCKET"
23007_ACEOF
23008
23009					break;
23010				fi
23011			done
23012			if test ! -z "$PRNGD_SOCKET" ; then
23013				{ echo "$as_me:$LINENO: result: $PRNGD_SOCKET" >&5
23014echo "${ECHO_T}$PRNGD_SOCKET" >&6; }
23015			else
23016				{ echo "$as_me:$LINENO: result: not found" >&5
23017echo "${ECHO_T}not found" >&6; }
23018			fi
23019		fi
23020
23021
23022fi
23023
23024
23025# Which randomness source do we use?
23026if test ! -z "$PRNGD_PORT" ; then
23027	RAND_MSG="PRNGd port $PRNGD_PORT"
23028elif test ! -z "$PRNGD_SOCKET" ; then
23029	RAND_MSG="PRNGd socket $PRNGD_SOCKET"
23030elif test ! -z "$OPENSSL_SEEDS_ITSELF" ; then
23031
23032cat >>confdefs.h <<\_ACEOF
23033#define OPENSSL_PRNG_ONLY 1
23034_ACEOF
23035
23036	RAND_MSG="OpenSSL internal ONLY"
23037elif test "x$openssl" = "xno" ; then
23038	{ echo "$as_me:$LINENO: WARNING: OpenSSH will use /dev/urandom as a source of random numbers. It will fail if this device is not supported or accessible" >&5
23039echo "$as_me: WARNING: OpenSSH will use /dev/urandom as a source of random numbers. It will fail if this device is not supported or accessible" >&2;}
23040else
23041	{ { echo "$as_me:$LINENO: 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" >&5
23042echo "$as_me: 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" >&2;}
23043   { (exit 1); exit 1; }; }
23044fi
23045
23046# Check for PAM libs
23047PAM_MSG="no"
23048
23049# Check whether --with-pam was given.
23050if test "${with_pam+set}" = set; then
23051  withval=$with_pam;
23052		if test "x$withval" != "xno" ; then
23053			if test "x$ac_cv_header_security_pam_appl_h" != "xyes" && \
23054			   test "x$ac_cv_header_pam_pam_appl_h" != "xyes" ; then
23055				{ { echo "$as_me:$LINENO: error: PAM headers not found" >&5
23056echo "$as_me: error: PAM headers not found" >&2;}
23057   { (exit 1); exit 1; }; }
23058			fi
23059
23060			saved_LIBS="$LIBS"
23061
23062{ echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
23063echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6; }
23064if test "${ac_cv_lib_dl_dlopen+set}" = set; then
23065  echo $ECHO_N "(cached) $ECHO_C" >&6
23066else
23067  ac_check_lib_save_LIBS=$LIBS
23068LIBS="-ldl  $LIBS"
23069cat >conftest.$ac_ext <<_ACEOF
23070/* confdefs.h.  */
23071_ACEOF
23072cat confdefs.h >>conftest.$ac_ext
23073cat >>conftest.$ac_ext <<_ACEOF
23074/* end confdefs.h.  */
23075
23076/* Override any GCC internal prototype to avoid an error.
23077   Use char because int might match the return type of a GCC
23078   builtin and then its argument prototype would still apply.  */
23079#ifdef __cplusplus
23080extern "C"
23081#endif
23082char dlopen ();
23083int
23084main ()
23085{
23086return dlopen ();
23087  ;
23088  return 0;
23089}
23090_ACEOF
23091rm -f conftest.$ac_objext conftest$ac_exeext
23092if { (ac_try="$ac_link"
23093case "(($ac_try" in
23094  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23095  *) ac_try_echo=$ac_try;;
23096esac
23097eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23098  (eval "$ac_link") 2>conftest.er1
23099  ac_status=$?
23100  grep -v '^ *+' conftest.er1 >conftest.err
23101  rm -f conftest.er1
23102  cat conftest.err >&5
23103  echo "$as_me:$LINENO: \$? = $ac_status" >&5
23104  (exit $ac_status); } && {
23105	 test -z "$ac_c_werror_flag" ||
23106	 test ! -s conftest.err
23107       } && test -s conftest$ac_exeext &&
23108       $as_test_x conftest$ac_exeext; then
23109  ac_cv_lib_dl_dlopen=yes
23110else
23111  echo "$as_me: failed program was:" >&5
23112sed 's/^/| /' conftest.$ac_ext >&5
23113
23114	ac_cv_lib_dl_dlopen=no
23115fi
23116
23117rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23118      conftest$ac_exeext conftest.$ac_ext
23119LIBS=$ac_check_lib_save_LIBS
23120fi
23121{ echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
23122echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6; }
23123if test $ac_cv_lib_dl_dlopen = yes; then
23124  cat >>confdefs.h <<_ACEOF
23125#define HAVE_LIBDL 1
23126_ACEOF
23127
23128  LIBS="-ldl $LIBS"
23129
23130fi
23131
23132
23133{ echo "$as_me:$LINENO: checking for pam_set_item in -lpam" >&5
23134echo $ECHO_N "checking for pam_set_item in -lpam... $ECHO_C" >&6; }
23135if test "${ac_cv_lib_pam_pam_set_item+set}" = set; then
23136  echo $ECHO_N "(cached) $ECHO_C" >&6
23137else
23138  ac_check_lib_save_LIBS=$LIBS
23139LIBS="-lpam  $LIBS"
23140cat >conftest.$ac_ext <<_ACEOF
23141/* confdefs.h.  */
23142_ACEOF
23143cat confdefs.h >>conftest.$ac_ext
23144cat >>conftest.$ac_ext <<_ACEOF
23145/* end confdefs.h.  */
23146
23147/* Override any GCC internal prototype to avoid an error.
23148   Use char because int might match the return type of a GCC
23149   builtin and then its argument prototype would still apply.  */
23150#ifdef __cplusplus
23151extern "C"
23152#endif
23153char pam_set_item ();
23154int
23155main ()
23156{
23157return pam_set_item ();
23158  ;
23159  return 0;
23160}
23161_ACEOF
23162rm -f conftest.$ac_objext conftest$ac_exeext
23163if { (ac_try="$ac_link"
23164case "(($ac_try" in
23165  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23166  *) ac_try_echo=$ac_try;;
23167esac
23168eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23169  (eval "$ac_link") 2>conftest.er1
23170  ac_status=$?
23171  grep -v '^ *+' conftest.er1 >conftest.err
23172  rm -f conftest.er1
23173  cat conftest.err >&5
23174  echo "$as_me:$LINENO: \$? = $ac_status" >&5
23175  (exit $ac_status); } && {
23176	 test -z "$ac_c_werror_flag" ||
23177	 test ! -s conftest.err
23178       } && test -s conftest$ac_exeext &&
23179       $as_test_x conftest$ac_exeext; then
23180  ac_cv_lib_pam_pam_set_item=yes
23181else
23182  echo "$as_me: failed program was:" >&5
23183sed 's/^/| /' conftest.$ac_ext >&5
23184
23185	ac_cv_lib_pam_pam_set_item=no
23186fi
23187
23188rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23189      conftest$ac_exeext conftest.$ac_ext
23190LIBS=$ac_check_lib_save_LIBS
23191fi
23192{ echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_set_item" >&5
23193echo "${ECHO_T}$ac_cv_lib_pam_pam_set_item" >&6; }
23194if test $ac_cv_lib_pam_pam_set_item = yes; then
23195  cat >>confdefs.h <<_ACEOF
23196#define HAVE_LIBPAM 1
23197_ACEOF
23198
23199  LIBS="-lpam $LIBS"
23200
23201else
23202  { { echo "$as_me:$LINENO: error: *** libpam missing" >&5
23203echo "$as_me: error: *** libpam missing" >&2;}
23204   { (exit 1); exit 1; }; }
23205fi
23206
23207
23208for ac_func in pam_getenvlist
23209do
23210as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
23211{ echo "$as_me:$LINENO: checking for $ac_func" >&5
23212echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
23213if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
23214  echo $ECHO_N "(cached) $ECHO_C" >&6
23215else
23216  cat >conftest.$ac_ext <<_ACEOF
23217/* confdefs.h.  */
23218_ACEOF
23219cat confdefs.h >>conftest.$ac_ext
23220cat >>conftest.$ac_ext <<_ACEOF
23221/* end confdefs.h.  */
23222/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23223   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23224#define $ac_func innocuous_$ac_func
23225
23226/* System header to define __stub macros and hopefully few prototypes,
23227    which can conflict with char $ac_func (); below.
23228    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23229    <limits.h> exists even on freestanding compilers.  */
23230
23231#ifdef __STDC__
23232# include <limits.h>
23233#else
23234# include <assert.h>
23235#endif
23236
23237#undef $ac_func
23238
23239/* Override any GCC internal prototype to avoid an error.
23240   Use char because int might match the return type of a GCC
23241   builtin and then its argument prototype would still apply.  */
23242#ifdef __cplusplus
23243extern "C"
23244#endif
23245char $ac_func ();
23246/* The GNU C library defines this for functions which it implements
23247    to always fail with ENOSYS.  Some functions are actually named
23248    something starting with __ and the normal name is an alias.  */
23249#if defined __stub_$ac_func || defined __stub___$ac_func
23250choke me
23251#endif
23252
23253int
23254main ()
23255{
23256return $ac_func ();
23257  ;
23258  return 0;
23259}
23260_ACEOF
23261rm -f conftest.$ac_objext conftest$ac_exeext
23262if { (ac_try="$ac_link"
23263case "(($ac_try" in
23264  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23265  *) ac_try_echo=$ac_try;;
23266esac
23267eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23268  (eval "$ac_link") 2>conftest.er1
23269  ac_status=$?
23270  grep -v '^ *+' conftest.er1 >conftest.err
23271  rm -f conftest.er1
23272  cat conftest.err >&5
23273  echo "$as_me:$LINENO: \$? = $ac_status" >&5
23274  (exit $ac_status); } && {
23275	 test -z "$ac_c_werror_flag" ||
23276	 test ! -s conftest.err
23277       } && test -s conftest$ac_exeext &&
23278       $as_test_x conftest$ac_exeext; then
23279  eval "$as_ac_var=yes"
23280else
23281  echo "$as_me: failed program was:" >&5
23282sed 's/^/| /' conftest.$ac_ext >&5
23283
23284	eval "$as_ac_var=no"
23285fi
23286
23287rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23288      conftest$ac_exeext conftest.$ac_ext
23289fi
23290ac_res=`eval echo '${'$as_ac_var'}'`
23291	       { echo "$as_me:$LINENO: result: $ac_res" >&5
23292echo "${ECHO_T}$ac_res" >&6; }
23293if test `eval echo '${'$as_ac_var'}'` = yes; then
23294  cat >>confdefs.h <<_ACEOF
23295#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
23296_ACEOF
23297
23298fi
23299done
23300
23301
23302for ac_func in pam_putenv
23303do
23304as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
23305{ echo "$as_me:$LINENO: checking for $ac_func" >&5
23306echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
23307if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
23308  echo $ECHO_N "(cached) $ECHO_C" >&6
23309else
23310  cat >conftest.$ac_ext <<_ACEOF
23311/* confdefs.h.  */
23312_ACEOF
23313cat confdefs.h >>conftest.$ac_ext
23314cat >>conftest.$ac_ext <<_ACEOF
23315/* end confdefs.h.  */
23316/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23317   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23318#define $ac_func innocuous_$ac_func
23319
23320/* System header to define __stub macros and hopefully few prototypes,
23321    which can conflict with char $ac_func (); below.
23322    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23323    <limits.h> exists even on freestanding compilers.  */
23324
23325#ifdef __STDC__
23326# include <limits.h>
23327#else
23328# include <assert.h>
23329#endif
23330
23331#undef $ac_func
23332
23333/* Override any GCC internal prototype to avoid an error.
23334   Use char because int might match the return type of a GCC
23335   builtin and then its argument prototype would still apply.  */
23336#ifdef __cplusplus
23337extern "C"
23338#endif
23339char $ac_func ();
23340/* The GNU C library defines this for functions which it implements
23341    to always fail with ENOSYS.  Some functions are actually named
23342    something starting with __ and the normal name is an alias.  */
23343#if defined __stub_$ac_func || defined __stub___$ac_func
23344choke me
23345#endif
23346
23347int
23348main ()
23349{
23350return $ac_func ();
23351  ;
23352  return 0;
23353}
23354_ACEOF
23355rm -f conftest.$ac_objext conftest$ac_exeext
23356if { (ac_try="$ac_link"
23357case "(($ac_try" in
23358  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23359  *) ac_try_echo=$ac_try;;
23360esac
23361eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23362  (eval "$ac_link") 2>conftest.er1
23363  ac_status=$?
23364  grep -v '^ *+' conftest.er1 >conftest.err
23365  rm -f conftest.er1
23366  cat conftest.err >&5
23367  echo "$as_me:$LINENO: \$? = $ac_status" >&5
23368  (exit $ac_status); } && {
23369	 test -z "$ac_c_werror_flag" ||
23370	 test ! -s conftest.err
23371       } && test -s conftest$ac_exeext &&
23372       $as_test_x conftest$ac_exeext; then
23373  eval "$as_ac_var=yes"
23374else
23375  echo "$as_me: failed program was:" >&5
23376sed 's/^/| /' conftest.$ac_ext >&5
23377
23378	eval "$as_ac_var=no"
23379fi
23380
23381rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23382      conftest$ac_exeext conftest.$ac_ext
23383fi
23384ac_res=`eval echo '${'$as_ac_var'}'`
23385	       { echo "$as_me:$LINENO: result: $ac_res" >&5
23386echo "${ECHO_T}$ac_res" >&6; }
23387if test `eval echo '${'$as_ac_var'}'` = yes; then
23388  cat >>confdefs.h <<_ACEOF
23389#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
23390_ACEOF
23391
23392fi
23393done
23394
23395			LIBS="$saved_LIBS"
23396
23397			PAM_MSG="yes"
23398
23399			SSHDLIBS="$SSHDLIBS -lpam"
23400
23401cat >>confdefs.h <<\_ACEOF
23402#define USE_PAM 1
23403_ACEOF
23404
23405
23406			if test $ac_cv_lib_dl_dlopen = yes; then
23407				case "$LIBS" in
23408				*-ldl*)
23409					# libdl already in LIBS
23410					;;
23411				*)
23412					SSHDLIBS="$SSHDLIBS -ldl"
23413					;;
23414				esac
23415			fi
23416		fi
23417
23418
23419fi
23420
23421
23422# Check for older PAM
23423if test "x$PAM_MSG" = "xyes" ; then
23424	# Check PAM strerror arguments (old PAM)
23425	{ echo "$as_me:$LINENO: checking whether pam_strerror takes only one argument" >&5
23426echo $ECHO_N "checking whether pam_strerror takes only one argument... $ECHO_C" >&6; }
23427	cat >conftest.$ac_ext <<_ACEOF
23428/* confdefs.h.  */
23429_ACEOF
23430cat confdefs.h >>conftest.$ac_ext
23431cat >>conftest.$ac_ext <<_ACEOF
23432/* end confdefs.h.  */
23433
23434#include <stdlib.h>
23435#if defined(HAVE_SECURITY_PAM_APPL_H)
23436#include <security/pam_appl.h>
23437#elif defined (HAVE_PAM_PAM_APPL_H)
23438#include <pam/pam_appl.h>
23439#endif
23440
23441int
23442main ()
23443{
23444
23445(void)pam_strerror((pam_handle_t *)NULL, -1);
23446
23447  ;
23448  return 0;
23449}
23450_ACEOF
23451rm -f conftest.$ac_objext
23452if { (ac_try="$ac_compile"
23453case "(($ac_try" in
23454  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23455  *) ac_try_echo=$ac_try;;
23456esac
23457eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23458  (eval "$ac_compile") 2>conftest.er1
23459  ac_status=$?
23460  grep -v '^ *+' conftest.er1 >conftest.err
23461  rm -f conftest.er1
23462  cat conftest.err >&5
23463  echo "$as_me:$LINENO: \$? = $ac_status" >&5
23464  (exit $ac_status); } && {
23465	 test -z "$ac_c_werror_flag" ||
23466	 test ! -s conftest.err
23467       } && test -s conftest.$ac_objext; then
23468  { echo "$as_me:$LINENO: result: no" >&5
23469echo "${ECHO_T}no" >&6; }
23470else
23471  echo "$as_me: failed program was:" >&5
23472sed 's/^/| /' conftest.$ac_ext >&5
23473
23474
23475
23476cat >>confdefs.h <<\_ACEOF
23477#define HAVE_OLD_PAM 1
23478_ACEOF
23479
23480			{ echo "$as_me:$LINENO: result: yes" >&5
23481echo "${ECHO_T}yes" >&6; }
23482			PAM_MSG="yes (old library)"
23483
23484
23485fi
23486
23487rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23488fi
23489
23490case "$host" in
23491*-*-cygwin*)
23492	SSH_PRIVSEP_USER=CYGWIN_SSH_PRIVSEP_USER
23493	;;
23494*)
23495	SSH_PRIVSEP_USER=sshd
23496	;;
23497esac
23498
23499# Check whether --with-privsep-user was given.
23500if test "${with_privsep_user+set}" = set; then
23501  withval=$with_privsep_user;
23502		if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
23503		    test "x${withval}" != "xyes"; then
23504			SSH_PRIVSEP_USER=$withval
23505		fi
23506
23507
23508fi
23509
23510if test "x$SSH_PRIVSEP_USER" = "xCYGWIN_SSH_PRIVSEP_USER" ; then
23511
23512cat >>confdefs.h <<_ACEOF
23513#define SSH_PRIVSEP_USER CYGWIN_SSH_PRIVSEP_USER
23514_ACEOF
23515
23516else
23517
23518cat >>confdefs.h <<_ACEOF
23519#define SSH_PRIVSEP_USER "$SSH_PRIVSEP_USER"
23520_ACEOF
23521
23522fi
23523
23524
23525if test "x$have_linux_no_new_privs" = "x1" ; then
23526{ echo "$as_me:$LINENO: checking whether SECCOMP_MODE_FILTER is declared" >&5
23527echo $ECHO_N "checking whether SECCOMP_MODE_FILTER is declared... $ECHO_C" >&6; }
23528if test "${ac_cv_have_decl_SECCOMP_MODE_FILTER+set}" = set; then
23529  echo $ECHO_N "(cached) $ECHO_C" >&6
23530else
23531  cat >conftest.$ac_ext <<_ACEOF
23532/* confdefs.h.  */
23533_ACEOF
23534cat confdefs.h >>conftest.$ac_ext
23535cat >>conftest.$ac_ext <<_ACEOF
23536/* end confdefs.h.  */
23537
23538	#include <sys/types.h>
23539	#include <linux/seccomp.h>
23540
23541
23542int
23543main ()
23544{
23545#ifndef SECCOMP_MODE_FILTER
23546  (void) SECCOMP_MODE_FILTER;
23547#endif
23548
23549  ;
23550  return 0;
23551}
23552_ACEOF
23553rm -f conftest.$ac_objext
23554if { (ac_try="$ac_compile"
23555case "(($ac_try" in
23556  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23557  *) ac_try_echo=$ac_try;;
23558esac
23559eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23560  (eval "$ac_compile") 2>conftest.er1
23561  ac_status=$?
23562  grep -v '^ *+' conftest.er1 >conftest.err
23563  rm -f conftest.er1
23564  cat conftest.err >&5
23565  echo "$as_me:$LINENO: \$? = $ac_status" >&5
23566  (exit $ac_status); } && {
23567	 test -z "$ac_c_werror_flag" ||
23568	 test ! -s conftest.err
23569       } && test -s conftest.$ac_objext; then
23570  ac_cv_have_decl_SECCOMP_MODE_FILTER=yes
23571else
23572  echo "$as_me: failed program was:" >&5
23573sed 's/^/| /' conftest.$ac_ext >&5
23574
23575	ac_cv_have_decl_SECCOMP_MODE_FILTER=no
23576fi
23577
23578rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23579fi
23580{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_SECCOMP_MODE_FILTER" >&5
23581echo "${ECHO_T}$ac_cv_have_decl_SECCOMP_MODE_FILTER" >&6; }
23582if test $ac_cv_have_decl_SECCOMP_MODE_FILTER = yes; then
23583  have_seccomp_filter=1
23584fi
23585
23586fi
23587if test "x$have_seccomp_filter" = "x1" ; then
23588{ echo "$as_me:$LINENO: checking kernel for seccomp_filter support" >&5
23589echo $ECHO_N "checking kernel for seccomp_filter support... $ECHO_C" >&6; }
23590cat >conftest.$ac_ext <<_ACEOF
23591/* confdefs.h.  */
23592_ACEOF
23593cat confdefs.h >>conftest.$ac_ext
23594cat >>conftest.$ac_ext <<_ACEOF
23595/* end confdefs.h.  */
23596
23597		#include <errno.h>
23598		#include <elf.h>
23599		#include <linux/audit.h>
23600		#include <linux/seccomp.h>
23601		#include <stdlib.h>
23602		#include <sys/prctl.h>
23603
23604int
23605main ()
23606{
23607 int i = $seccomp_audit_arch;
23608	   errno = 0;
23609	   prctl(PR_SET_SECCOMP, SECCOMP_MODE_FILTER, NULL, 0, 0);
23610	   exit(errno == EFAULT ? 0 : 1);
23611  ;
23612  return 0;
23613}
23614_ACEOF
23615rm -f conftest.$ac_objext conftest$ac_exeext
23616if { (ac_try="$ac_link"
23617case "(($ac_try" in
23618  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23619  *) ac_try_echo=$ac_try;;
23620esac
23621eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23622  (eval "$ac_link") 2>conftest.er1
23623  ac_status=$?
23624  grep -v '^ *+' conftest.er1 >conftest.err
23625  rm -f conftest.er1
23626  cat conftest.err >&5
23627  echo "$as_me:$LINENO: \$? = $ac_status" >&5
23628  (exit $ac_status); } && {
23629	 test -z "$ac_c_werror_flag" ||
23630	 test ! -s conftest.err
23631       } && test -s conftest$ac_exeext &&
23632       $as_test_x conftest$ac_exeext; then
23633   { echo "$as_me:$LINENO: result: yes" >&5
23634echo "${ECHO_T}yes" >&6; }
23635else
23636  echo "$as_me: failed program was:" >&5
23637sed 's/^/| /' conftest.$ac_ext >&5
23638
23639
23640		{ echo "$as_me:$LINENO: result: no" >&5
23641echo "${ECHO_T}no" >&6; }
23642		# Disable seccomp filter as a target
23643		have_seccomp_filter=0
23644
23645
23646fi
23647
23648rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23649      conftest$ac_exeext conftest.$ac_ext
23650fi
23651
23652# Decide which sandbox style to use
23653sandbox_arg=""
23654
23655# Check whether --with-sandbox was given.
23656if test "${with_sandbox+set}" = set; then
23657  withval=$with_sandbox;
23658		if test "x$withval" = "xyes" ; then
23659			sandbox_arg=""
23660		else
23661			sandbox_arg="$withval"
23662		fi
23663
23664
23665fi
23666
23667
23668# Some platforms (seems to be the ones that have a kernel poll(2)-type
23669# function with which they implement select(2)) use an extra file descriptor
23670# when calling select(2), which means we can't use the rlimit sandbox.
23671{ echo "$as_me:$LINENO: checking if select works with descriptor rlimit" >&5
23672echo $ECHO_N "checking if select works with descriptor rlimit... $ECHO_C" >&6; }
23673if test "$cross_compiling" = yes; then
23674  { echo "$as_me:$LINENO: WARNING: cross compiling: assuming yes" >&5
23675echo "$as_me: WARNING: cross compiling: assuming yes" >&2;}
23676
23677else
23678  cat >conftest.$ac_ext <<_ACEOF
23679/* confdefs.h.  */
23680_ACEOF
23681cat confdefs.h >>conftest.$ac_ext
23682cat >>conftest.$ac_ext <<_ACEOF
23683/* end confdefs.h.  */
23684
23685#include <sys/types.h>
23686#ifdef HAVE_SYS_TIME_H
23687# include <sys/time.h>
23688#endif
23689#include <sys/resource.h>
23690#ifdef HAVE_SYS_SELECT_H
23691# include <sys/select.h>
23692#endif
23693#include <errno.h>
23694#include <fcntl.h>
23695#include <stdlib.h>
23696
23697int
23698main ()
23699{
23700
23701	struct rlimit rl_zero;
23702	int fd, r;
23703	fd_set fds;
23704	struct timeval tv;
23705
23706	fd = open("/dev/null", O_RDONLY);
23707	FD_ZERO(&fds);
23708	FD_SET(fd, &fds);
23709	rl_zero.rlim_cur = rl_zero.rlim_max = 0;
23710	setrlimit(RLIMIT_FSIZE, &rl_zero);
23711	setrlimit(RLIMIT_NOFILE, &rl_zero);
23712	tv.tv_sec = 1;
23713	tv.tv_usec = 0;
23714	r = select(fd+1, &fds, NULL, NULL, &tv);
23715	exit (r == -1 ? 1 : 0);
23716
23717  ;
23718  return 0;
23719}
23720_ACEOF
23721rm -f conftest$ac_exeext
23722if { (ac_try="$ac_link"
23723case "(($ac_try" in
23724  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23725  *) ac_try_echo=$ac_try;;
23726esac
23727eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23728  (eval "$ac_link") 2>&5
23729  ac_status=$?
23730  echo "$as_me:$LINENO: \$? = $ac_status" >&5
23731  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23732  { (case "(($ac_try" in
23733  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23734  *) ac_try_echo=$ac_try;;
23735esac
23736eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23737  (eval "$ac_try") 2>&5
23738  ac_status=$?
23739  echo "$as_me:$LINENO: \$? = $ac_status" >&5
23740  (exit $ac_status); }; }; then
23741  { echo "$as_me:$LINENO: result: yes" >&5
23742echo "${ECHO_T}yes" >&6; }
23743	 select_works_with_rlimit=yes
23744else
23745  echo "$as_me: program exited with status $ac_status" >&5
23746echo "$as_me: failed program was:" >&5
23747sed 's/^/| /' conftest.$ac_ext >&5
23748
23749( exit $ac_status )
23750{ echo "$as_me:$LINENO: result: no" >&5
23751echo "${ECHO_T}no" >&6; }
23752	 select_works_with_rlimit=no
23753fi
23754rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23755fi
23756
23757
23758
23759{ echo "$as_me:$LINENO: checking if setrlimit(RLIMIT_NOFILE,{0,0}) works" >&5
23760echo $ECHO_N "checking if setrlimit(RLIMIT_NOFILE,{0,0}) works... $ECHO_C" >&6; }
23761if test "$cross_compiling" = yes; then
23762  { echo "$as_me:$LINENO: WARNING: cross compiling: assuming yes" >&5
23763echo "$as_me: WARNING: cross compiling: assuming yes" >&2;}
23764
23765else
23766  cat >conftest.$ac_ext <<_ACEOF
23767/* confdefs.h.  */
23768_ACEOF
23769cat confdefs.h >>conftest.$ac_ext
23770cat >>conftest.$ac_ext <<_ACEOF
23771/* end confdefs.h.  */
23772
23773#include <sys/types.h>
23774#ifdef HAVE_SYS_TIME_H
23775# include <sys/time.h>
23776#endif
23777#include <sys/resource.h>
23778#include <errno.h>
23779#include <stdlib.h>
23780
23781int
23782main ()
23783{
23784
23785	struct rlimit rl_zero;
23786	int fd, r;
23787	fd_set fds;
23788
23789	rl_zero.rlim_cur = rl_zero.rlim_max = 0;
23790	r = setrlimit(RLIMIT_NOFILE, &rl_zero);
23791	exit (r == -1 ? 1 : 0);
23792
23793  ;
23794  return 0;
23795}
23796_ACEOF
23797rm -f conftest$ac_exeext
23798if { (ac_try="$ac_link"
23799case "(($ac_try" in
23800  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23801  *) ac_try_echo=$ac_try;;
23802esac
23803eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23804  (eval "$ac_link") 2>&5
23805  ac_status=$?
23806  echo "$as_me:$LINENO: \$? = $ac_status" >&5
23807  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23808  { (case "(($ac_try" in
23809  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23810  *) ac_try_echo=$ac_try;;
23811esac
23812eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23813  (eval "$ac_try") 2>&5
23814  ac_status=$?
23815  echo "$as_me:$LINENO: \$? = $ac_status" >&5
23816  (exit $ac_status); }; }; then
23817  { echo "$as_me:$LINENO: result: yes" >&5
23818echo "${ECHO_T}yes" >&6; }
23819	 rlimit_nofile_zero_works=yes
23820else
23821  echo "$as_me: program exited with status $ac_status" >&5
23822echo "$as_me: failed program was:" >&5
23823sed 's/^/| /' conftest.$ac_ext >&5
23824
23825( exit $ac_status )
23826{ echo "$as_me:$LINENO: result: no" >&5
23827echo "${ECHO_T}no" >&6; }
23828	 rlimit_nofile_zero_works=no
23829fi
23830rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23831fi
23832
23833
23834
23835{ echo "$as_me:$LINENO: checking if setrlimit RLIMIT_FSIZE works" >&5
23836echo $ECHO_N "checking if setrlimit RLIMIT_FSIZE works... $ECHO_C" >&6; }
23837if test "$cross_compiling" = yes; then
23838  { echo "$as_me:$LINENO: WARNING: cross compiling: assuming yes" >&5
23839echo "$as_me: WARNING: cross compiling: assuming yes" >&2;}
23840
23841else
23842  cat >conftest.$ac_ext <<_ACEOF
23843/* confdefs.h.  */
23844_ACEOF
23845cat confdefs.h >>conftest.$ac_ext
23846cat >>conftest.$ac_ext <<_ACEOF
23847/* end confdefs.h.  */
23848
23849#include <sys/types.h>
23850#include <sys/resource.h>
23851#include <stdlib.h>
23852
23853int
23854main ()
23855{
23856
23857		struct rlimit rl_zero;
23858
23859		rl_zero.rlim_cur = rl_zero.rlim_max = 0;
23860		exit(setrlimit(RLIMIT_FSIZE, &rl_zero) != 0);
23861
23862  ;
23863  return 0;
23864}
23865_ACEOF
23866rm -f conftest$ac_exeext
23867if { (ac_try="$ac_link"
23868case "(($ac_try" in
23869  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23870  *) ac_try_echo=$ac_try;;
23871esac
23872eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23873  (eval "$ac_link") 2>&5
23874  ac_status=$?
23875  echo "$as_me:$LINENO: \$? = $ac_status" >&5
23876  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23877  { (case "(($ac_try" in
23878  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23879  *) ac_try_echo=$ac_try;;
23880esac
23881eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
23882  (eval "$ac_try") 2>&5
23883  ac_status=$?
23884  echo "$as_me:$LINENO: \$? = $ac_status" >&5
23885  (exit $ac_status); }; }; then
23886  { echo "$as_me:$LINENO: result: yes" >&5
23887echo "${ECHO_T}yes" >&6; }
23888else
23889  echo "$as_me: program exited with status $ac_status" >&5
23890echo "$as_me: failed program was:" >&5
23891sed 's/^/| /' conftest.$ac_ext >&5
23892
23893( exit $ac_status )
23894{ echo "$as_me:$LINENO: result: no" >&5
23895echo "${ECHO_T}no" >&6; }
23896
23897cat >>confdefs.h <<\_ACEOF
23898#define SANDBOX_SKIP_RLIMIT_FSIZE 1
23899_ACEOF
23900
23901fi
23902rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23903fi
23904
23905
23906
23907if test "x$sandbox_arg" = "xsystrace" || \
23908   ( test -z "$sandbox_arg" && test "x$have_systr_policy_kill" = "x1" ) ; then
23909	test "x$have_systr_policy_kill" != "x1" && \
23910		{ { echo "$as_me:$LINENO: error: systrace sandbox requires systrace headers and SYSTR_POLICY_KILL support" >&5
23911echo "$as_me: error: systrace sandbox requires systrace headers and SYSTR_POLICY_KILL support" >&2;}
23912   { (exit 1); exit 1; }; }
23913	SANDBOX_STYLE="systrace"
23914
23915cat >>confdefs.h <<\_ACEOF
23916#define SANDBOX_SYSTRACE 1
23917_ACEOF
23918
23919elif test "x$sandbox_arg" = "xdarwin" || \
23920     ( test -z "$sandbox_arg" && test "x$ac_cv_func_sandbox_init" = "xyes" && \
23921       test "x$ac_cv_header_sandbox_h" = "xyes") ; then
23922	test "x$ac_cv_func_sandbox_init" != "xyes" -o \
23923	     "x$ac_cv_header_sandbox_h" != "xyes" && \
23924		{ { echo "$as_me:$LINENO: error: Darwin seatbelt sandbox requires sandbox.h and sandbox_init function" >&5
23925echo "$as_me: error: Darwin seatbelt sandbox requires sandbox.h and sandbox_init function" >&2;}
23926   { (exit 1); exit 1; }; }
23927	SANDBOX_STYLE="darwin"
23928
23929cat >>confdefs.h <<\_ACEOF
23930#define SANDBOX_DARWIN 1
23931_ACEOF
23932
23933elif test "x$sandbox_arg" = "xseccomp_filter" || \
23934     ( test -z "$sandbox_arg" && \
23935       test "x$have_seccomp_filter" = "x1" && \
23936       test "x$ac_cv_header_elf_h" = "xyes" && \
23937       test "x$ac_cv_header_linux_audit_h" = "xyes" && \
23938       test "x$ac_cv_header_linux_filter_h" = "xyes" && \
23939       test "x$seccomp_audit_arch" != "x" && \
23940       test "x$have_linux_no_new_privs" = "x1" && \
23941       test "x$ac_cv_func_prctl" = "xyes" ) ; then
23942	test "x$seccomp_audit_arch" = "x" && \
23943		{ { echo "$as_me:$LINENO: error: seccomp_filter sandbox not supported on $host" >&5
23944echo "$as_me: error: seccomp_filter sandbox not supported on $host" >&2;}
23945   { (exit 1); exit 1; }; }
23946	test "x$have_linux_no_new_privs" != "x1" && \
23947		{ { echo "$as_me:$LINENO: error: seccomp_filter sandbox requires PR_SET_NO_NEW_PRIVS" >&5
23948echo "$as_me: error: seccomp_filter sandbox requires PR_SET_NO_NEW_PRIVS" >&2;}
23949   { (exit 1); exit 1; }; }
23950	test "x$have_seccomp_filter" != "x1" && \
23951		{ { echo "$as_me:$LINENO: error: seccomp_filter sandbox requires seccomp headers" >&5
23952echo "$as_me: error: seccomp_filter sandbox requires seccomp headers" >&2;}
23953   { (exit 1); exit 1; }; }
23954	test "x$ac_cv_func_prctl" != "xyes" && \
23955		{ { echo "$as_me:$LINENO: error: seccomp_filter sandbox requires prctl function" >&5
23956echo "$as_me: error: seccomp_filter sandbox requires prctl function" >&2;}
23957   { (exit 1); exit 1; }; }
23958	SANDBOX_STYLE="seccomp_filter"
23959
23960cat >>confdefs.h <<\_ACEOF
23961#define SANDBOX_SECCOMP_FILTER 1
23962_ACEOF
23963
23964elif test "x$sandbox_arg" = "xcapsicum" || \
23965     ( test -z "$sandbox_arg" && \
23966       test "x$ac_cv_header_sys_capability_h" = "xyes" && \
23967       test "x$ac_cv_func_cap_rights_limit" = "xyes") ; then
23968       test "x$ac_cv_header_sys_capability_h" != "xyes" && \
23969		{ { echo "$as_me:$LINENO: error: capsicum sandbox requires sys/capability.h header" >&5
23970echo "$as_me: error: capsicum sandbox requires sys/capability.h header" >&2;}
23971   { (exit 1); exit 1; }; }
23972       test "x$ac_cv_func_cap_rights_limit" != "xyes" && \
23973		{ { echo "$as_me:$LINENO: error: capsicum sandbox requires cap_rights_limit function" >&5
23974echo "$as_me: error: capsicum sandbox requires cap_rights_limit function" >&2;}
23975   { (exit 1); exit 1; }; }
23976       SANDBOX_STYLE="capsicum"
23977
23978cat >>confdefs.h <<\_ACEOF
23979#define SANDBOX_CAPSICUM 1
23980_ACEOF
23981
23982elif test "x$sandbox_arg" = "xrlimit" || \
23983     ( test -z "$sandbox_arg" && test "x$ac_cv_func_setrlimit" = "xyes" && \
23984       test "x$select_works_with_rlimit" = "xyes" && \
23985       test "x$rlimit_nofile_zero_works" = "xyes" ) ; then
23986	test "x$ac_cv_func_setrlimit" != "xyes" && \
23987		{ { echo "$as_me:$LINENO: error: rlimit sandbox requires setrlimit function" >&5
23988echo "$as_me: error: rlimit sandbox requires setrlimit function" >&2;}
23989   { (exit 1); exit 1; }; }
23990	test "x$select_works_with_rlimit" != "xyes" && \
23991		{ { echo "$as_me:$LINENO: error: rlimit sandbox requires select to work with rlimit" >&5
23992echo "$as_me: error: rlimit sandbox requires select to work with rlimit" >&2;}
23993   { (exit 1); exit 1; }; }
23994	SANDBOX_STYLE="rlimit"
23995
23996cat >>confdefs.h <<\_ACEOF
23997#define SANDBOX_RLIMIT 1
23998_ACEOF
23999
24000elif test -z "$sandbox_arg" || test "x$sandbox_arg" = "xno" || \
24001     test "x$sandbox_arg" = "xnone" || test "x$sandbox_arg" = "xnull" ; then
24002	SANDBOX_STYLE="none"
24003
24004cat >>confdefs.h <<\_ACEOF
24005#define SANDBOX_NULL 1
24006_ACEOF
24007
24008else
24009	{ { echo "$as_me:$LINENO: error: unsupported --with-sandbox" >&5
24010echo "$as_me: error: unsupported --with-sandbox" >&2;}
24011   { (exit 1); exit 1; }; }
24012fi
24013
24014# Cheap hack to ensure NEWS-OS libraries are arranged right.
24015if test ! -z "$SONY" ; then
24016  LIBS="$LIBS -liberty";
24017fi
24018
24019# Check for  long long datatypes
24020{ echo "$as_me:$LINENO: checking for long long" >&5
24021echo $ECHO_N "checking for long long... $ECHO_C" >&6; }
24022if test "${ac_cv_type_long_long+set}" = set; then
24023  echo $ECHO_N "(cached) $ECHO_C" >&6
24024else
24025  cat >conftest.$ac_ext <<_ACEOF
24026/* confdefs.h.  */
24027_ACEOF
24028cat confdefs.h >>conftest.$ac_ext
24029cat >>conftest.$ac_ext <<_ACEOF
24030/* end confdefs.h.  */
24031$ac_includes_default
24032typedef long long ac__type_new_;
24033int
24034main ()
24035{
24036if ((ac__type_new_ *) 0)
24037  return 0;
24038if (sizeof (ac__type_new_))
24039  return 0;
24040  ;
24041  return 0;
24042}
24043_ACEOF
24044rm -f conftest.$ac_objext
24045if { (ac_try="$ac_compile"
24046case "(($ac_try" in
24047  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24048  *) ac_try_echo=$ac_try;;
24049esac
24050eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24051  (eval "$ac_compile") 2>conftest.er1
24052  ac_status=$?
24053  grep -v '^ *+' conftest.er1 >conftest.err
24054  rm -f conftest.er1
24055  cat conftest.err >&5
24056  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24057  (exit $ac_status); } && {
24058	 test -z "$ac_c_werror_flag" ||
24059	 test ! -s conftest.err
24060       } && test -s conftest.$ac_objext; then
24061  ac_cv_type_long_long=yes
24062else
24063  echo "$as_me: failed program was:" >&5
24064sed 's/^/| /' conftest.$ac_ext >&5
24065
24066	ac_cv_type_long_long=no
24067fi
24068
24069rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24070fi
24071{ echo "$as_me:$LINENO: result: $ac_cv_type_long_long" >&5
24072echo "${ECHO_T}$ac_cv_type_long_long" >&6; }
24073if test $ac_cv_type_long_long = yes; then
24074
24075cat >>confdefs.h <<_ACEOF
24076#define HAVE_LONG_LONG 1
24077_ACEOF
24078
24079
24080fi
24081{ echo "$as_me:$LINENO: checking for unsigned long long" >&5
24082echo $ECHO_N "checking for unsigned long long... $ECHO_C" >&6; }
24083if test "${ac_cv_type_unsigned_long_long+set}" = set; then
24084  echo $ECHO_N "(cached) $ECHO_C" >&6
24085else
24086  cat >conftest.$ac_ext <<_ACEOF
24087/* confdefs.h.  */
24088_ACEOF
24089cat confdefs.h >>conftest.$ac_ext
24090cat >>conftest.$ac_ext <<_ACEOF
24091/* end confdefs.h.  */
24092$ac_includes_default
24093typedef unsigned long long ac__type_new_;
24094int
24095main ()
24096{
24097if ((ac__type_new_ *) 0)
24098  return 0;
24099if (sizeof (ac__type_new_))
24100  return 0;
24101  ;
24102  return 0;
24103}
24104_ACEOF
24105rm -f conftest.$ac_objext
24106if { (ac_try="$ac_compile"
24107case "(($ac_try" in
24108  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24109  *) ac_try_echo=$ac_try;;
24110esac
24111eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24112  (eval "$ac_compile") 2>conftest.er1
24113  ac_status=$?
24114  grep -v '^ *+' conftest.er1 >conftest.err
24115  rm -f conftest.er1
24116  cat conftest.err >&5
24117  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24118  (exit $ac_status); } && {
24119	 test -z "$ac_c_werror_flag" ||
24120	 test ! -s conftest.err
24121       } && test -s conftest.$ac_objext; then
24122  ac_cv_type_unsigned_long_long=yes
24123else
24124  echo "$as_me: failed program was:" >&5
24125sed 's/^/| /' conftest.$ac_ext >&5
24126
24127	ac_cv_type_unsigned_long_long=no
24128fi
24129
24130rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24131fi
24132{ echo "$as_me:$LINENO: result: $ac_cv_type_unsigned_long_long" >&5
24133echo "${ECHO_T}$ac_cv_type_unsigned_long_long" >&6; }
24134if test $ac_cv_type_unsigned_long_long = yes; then
24135
24136cat >>confdefs.h <<_ACEOF
24137#define HAVE_UNSIGNED_LONG_LONG 1
24138_ACEOF
24139
24140
24141fi
24142{ echo "$as_me:$LINENO: checking for long double" >&5
24143echo $ECHO_N "checking for long double... $ECHO_C" >&6; }
24144if test "${ac_cv_type_long_double+set}" = set; then
24145  echo $ECHO_N "(cached) $ECHO_C" >&6
24146else
24147  cat >conftest.$ac_ext <<_ACEOF
24148/* confdefs.h.  */
24149_ACEOF
24150cat confdefs.h >>conftest.$ac_ext
24151cat >>conftest.$ac_ext <<_ACEOF
24152/* end confdefs.h.  */
24153$ac_includes_default
24154typedef long double ac__type_new_;
24155int
24156main ()
24157{
24158if ((ac__type_new_ *) 0)
24159  return 0;
24160if (sizeof (ac__type_new_))
24161  return 0;
24162  ;
24163  return 0;
24164}
24165_ACEOF
24166rm -f conftest.$ac_objext
24167if { (ac_try="$ac_compile"
24168case "(($ac_try" in
24169  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24170  *) ac_try_echo=$ac_try;;
24171esac
24172eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24173  (eval "$ac_compile") 2>conftest.er1
24174  ac_status=$?
24175  grep -v '^ *+' conftest.er1 >conftest.err
24176  rm -f conftest.er1
24177  cat conftest.err >&5
24178  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24179  (exit $ac_status); } && {
24180	 test -z "$ac_c_werror_flag" ||
24181	 test ! -s conftest.err
24182       } && test -s conftest.$ac_objext; then
24183  ac_cv_type_long_double=yes
24184else
24185  echo "$as_me: failed program was:" >&5
24186sed 's/^/| /' conftest.$ac_ext >&5
24187
24188	ac_cv_type_long_double=no
24189fi
24190
24191rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24192fi
24193{ echo "$as_me:$LINENO: result: $ac_cv_type_long_double" >&5
24194echo "${ECHO_T}$ac_cv_type_long_double" >&6; }
24195if test $ac_cv_type_long_double = yes; then
24196
24197cat >>confdefs.h <<_ACEOF
24198#define HAVE_LONG_DOUBLE 1
24199_ACEOF
24200
24201
24202fi
24203
24204
24205# Check datatype sizes
24206{ echo "$as_me:$LINENO: checking for short int" >&5
24207echo $ECHO_N "checking for short int... $ECHO_C" >&6; }
24208if test "${ac_cv_type_short_int+set}" = set; then
24209  echo $ECHO_N "(cached) $ECHO_C" >&6
24210else
24211  cat >conftest.$ac_ext <<_ACEOF
24212/* confdefs.h.  */
24213_ACEOF
24214cat confdefs.h >>conftest.$ac_ext
24215cat >>conftest.$ac_ext <<_ACEOF
24216/* end confdefs.h.  */
24217$ac_includes_default
24218typedef short int ac__type_new_;
24219int
24220main ()
24221{
24222if ((ac__type_new_ *) 0)
24223  return 0;
24224if (sizeof (ac__type_new_))
24225  return 0;
24226  ;
24227  return 0;
24228}
24229_ACEOF
24230rm -f conftest.$ac_objext
24231if { (ac_try="$ac_compile"
24232case "(($ac_try" in
24233  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24234  *) ac_try_echo=$ac_try;;
24235esac
24236eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24237  (eval "$ac_compile") 2>conftest.er1
24238  ac_status=$?
24239  grep -v '^ *+' conftest.er1 >conftest.err
24240  rm -f conftest.er1
24241  cat conftest.err >&5
24242  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24243  (exit $ac_status); } && {
24244	 test -z "$ac_c_werror_flag" ||
24245	 test ! -s conftest.err
24246       } && test -s conftest.$ac_objext; then
24247  ac_cv_type_short_int=yes
24248else
24249  echo "$as_me: failed program was:" >&5
24250sed 's/^/| /' conftest.$ac_ext >&5
24251
24252	ac_cv_type_short_int=no
24253fi
24254
24255rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24256fi
24257{ echo "$as_me:$LINENO: result: $ac_cv_type_short_int" >&5
24258echo "${ECHO_T}$ac_cv_type_short_int" >&6; }
24259
24260# The cast to long int works around a bug in the HP C Compiler
24261# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24262# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24263# This bug is HP SR number 8606223364.
24264{ echo "$as_me:$LINENO: checking size of short int" >&5
24265echo $ECHO_N "checking size of short int... $ECHO_C" >&6; }
24266if test "${ac_cv_sizeof_short_int+set}" = set; then
24267  echo $ECHO_N "(cached) $ECHO_C" >&6
24268else
24269  if test "$cross_compiling" = yes; then
24270  # Depending upon the size, compute the lo and hi bounds.
24271cat >conftest.$ac_ext <<_ACEOF
24272/* confdefs.h.  */
24273_ACEOF
24274cat confdefs.h >>conftest.$ac_ext
24275cat >>conftest.$ac_ext <<_ACEOF
24276/* end confdefs.h.  */
24277$ac_includes_default
24278   typedef short int ac__type_sizeof_;
24279int
24280main ()
24281{
24282static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
24283test_array [0] = 0
24284
24285  ;
24286  return 0;
24287}
24288_ACEOF
24289rm -f conftest.$ac_objext
24290if { (ac_try="$ac_compile"
24291case "(($ac_try" in
24292  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24293  *) ac_try_echo=$ac_try;;
24294esac
24295eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24296  (eval "$ac_compile") 2>conftest.er1
24297  ac_status=$?
24298  grep -v '^ *+' conftest.er1 >conftest.err
24299  rm -f conftest.er1
24300  cat conftest.err >&5
24301  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24302  (exit $ac_status); } && {
24303	 test -z "$ac_c_werror_flag" ||
24304	 test ! -s conftest.err
24305       } && test -s conftest.$ac_objext; then
24306  ac_lo=0 ac_mid=0
24307  while :; do
24308    cat >conftest.$ac_ext <<_ACEOF
24309/* confdefs.h.  */
24310_ACEOF
24311cat confdefs.h >>conftest.$ac_ext
24312cat >>conftest.$ac_ext <<_ACEOF
24313/* end confdefs.h.  */
24314$ac_includes_default
24315   typedef short int ac__type_sizeof_;
24316int
24317main ()
24318{
24319static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
24320test_array [0] = 0
24321
24322  ;
24323  return 0;
24324}
24325_ACEOF
24326rm -f conftest.$ac_objext
24327if { (ac_try="$ac_compile"
24328case "(($ac_try" in
24329  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24330  *) ac_try_echo=$ac_try;;
24331esac
24332eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24333  (eval "$ac_compile") 2>conftest.er1
24334  ac_status=$?
24335  grep -v '^ *+' conftest.er1 >conftest.err
24336  rm -f conftest.er1
24337  cat conftest.err >&5
24338  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24339  (exit $ac_status); } && {
24340	 test -z "$ac_c_werror_flag" ||
24341	 test ! -s conftest.err
24342       } && test -s conftest.$ac_objext; then
24343  ac_hi=$ac_mid; break
24344else
24345  echo "$as_me: failed program was:" >&5
24346sed 's/^/| /' conftest.$ac_ext >&5
24347
24348	ac_lo=`expr $ac_mid + 1`
24349			if test $ac_lo -le $ac_mid; then
24350			  ac_lo= ac_hi=
24351			  break
24352			fi
24353			ac_mid=`expr 2 '*' $ac_mid + 1`
24354fi
24355
24356rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24357  done
24358else
24359  echo "$as_me: failed program was:" >&5
24360sed 's/^/| /' conftest.$ac_ext >&5
24361
24362	cat >conftest.$ac_ext <<_ACEOF
24363/* confdefs.h.  */
24364_ACEOF
24365cat confdefs.h >>conftest.$ac_ext
24366cat >>conftest.$ac_ext <<_ACEOF
24367/* end confdefs.h.  */
24368$ac_includes_default
24369   typedef short int ac__type_sizeof_;
24370int
24371main ()
24372{
24373static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
24374test_array [0] = 0
24375
24376  ;
24377  return 0;
24378}
24379_ACEOF
24380rm -f conftest.$ac_objext
24381if { (ac_try="$ac_compile"
24382case "(($ac_try" in
24383  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24384  *) ac_try_echo=$ac_try;;
24385esac
24386eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24387  (eval "$ac_compile") 2>conftest.er1
24388  ac_status=$?
24389  grep -v '^ *+' conftest.er1 >conftest.err
24390  rm -f conftest.er1
24391  cat conftest.err >&5
24392  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24393  (exit $ac_status); } && {
24394	 test -z "$ac_c_werror_flag" ||
24395	 test ! -s conftest.err
24396       } && test -s conftest.$ac_objext; then
24397  ac_hi=-1 ac_mid=-1
24398  while :; do
24399    cat >conftest.$ac_ext <<_ACEOF
24400/* confdefs.h.  */
24401_ACEOF
24402cat confdefs.h >>conftest.$ac_ext
24403cat >>conftest.$ac_ext <<_ACEOF
24404/* end confdefs.h.  */
24405$ac_includes_default
24406   typedef short int ac__type_sizeof_;
24407int
24408main ()
24409{
24410static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
24411test_array [0] = 0
24412
24413  ;
24414  return 0;
24415}
24416_ACEOF
24417rm -f conftest.$ac_objext
24418if { (ac_try="$ac_compile"
24419case "(($ac_try" in
24420  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24421  *) ac_try_echo=$ac_try;;
24422esac
24423eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24424  (eval "$ac_compile") 2>conftest.er1
24425  ac_status=$?
24426  grep -v '^ *+' conftest.er1 >conftest.err
24427  rm -f conftest.er1
24428  cat conftest.err >&5
24429  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24430  (exit $ac_status); } && {
24431	 test -z "$ac_c_werror_flag" ||
24432	 test ! -s conftest.err
24433       } && test -s conftest.$ac_objext; then
24434  ac_lo=$ac_mid; break
24435else
24436  echo "$as_me: failed program was:" >&5
24437sed 's/^/| /' conftest.$ac_ext >&5
24438
24439	ac_hi=`expr '(' $ac_mid ')' - 1`
24440			if test $ac_mid -le $ac_hi; then
24441			  ac_lo= ac_hi=
24442			  break
24443			fi
24444			ac_mid=`expr 2 '*' $ac_mid`
24445fi
24446
24447rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24448  done
24449else
24450  echo "$as_me: failed program was:" >&5
24451sed 's/^/| /' conftest.$ac_ext >&5
24452
24453	ac_lo= ac_hi=
24454fi
24455
24456rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24457fi
24458
24459rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24460# Binary search between lo and hi bounds.
24461while test "x$ac_lo" != "x$ac_hi"; do
24462  ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24463  cat >conftest.$ac_ext <<_ACEOF
24464/* confdefs.h.  */
24465_ACEOF
24466cat confdefs.h >>conftest.$ac_ext
24467cat >>conftest.$ac_ext <<_ACEOF
24468/* end confdefs.h.  */
24469$ac_includes_default
24470   typedef short int ac__type_sizeof_;
24471int
24472main ()
24473{
24474static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
24475test_array [0] = 0
24476
24477  ;
24478  return 0;
24479}
24480_ACEOF
24481rm -f conftest.$ac_objext
24482if { (ac_try="$ac_compile"
24483case "(($ac_try" in
24484  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24485  *) ac_try_echo=$ac_try;;
24486esac
24487eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24488  (eval "$ac_compile") 2>conftest.er1
24489  ac_status=$?
24490  grep -v '^ *+' conftest.er1 >conftest.err
24491  rm -f conftest.er1
24492  cat conftest.err >&5
24493  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24494  (exit $ac_status); } && {
24495	 test -z "$ac_c_werror_flag" ||
24496	 test ! -s conftest.err
24497       } && test -s conftest.$ac_objext; then
24498  ac_hi=$ac_mid
24499else
24500  echo "$as_me: failed program was:" >&5
24501sed 's/^/| /' conftest.$ac_ext >&5
24502
24503	ac_lo=`expr '(' $ac_mid ')' + 1`
24504fi
24505
24506rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24507done
24508case $ac_lo in
24509?*) ac_cv_sizeof_short_int=$ac_lo;;
24510'') if test "$ac_cv_type_short_int" = yes; then
24511     { { echo "$as_me:$LINENO: error: cannot compute sizeof (short int)
24512See \`config.log' for more details." >&5
24513echo "$as_me: error: cannot compute sizeof (short int)
24514See \`config.log' for more details." >&2;}
24515   { (exit 77); exit 77; }; }
24516   else
24517     ac_cv_sizeof_short_int=0
24518   fi ;;
24519esac
24520else
24521  cat >conftest.$ac_ext <<_ACEOF
24522/* confdefs.h.  */
24523_ACEOF
24524cat confdefs.h >>conftest.$ac_ext
24525cat >>conftest.$ac_ext <<_ACEOF
24526/* end confdefs.h.  */
24527$ac_includes_default
24528   typedef short int ac__type_sizeof_;
24529static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
24530static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
24531#include <stdio.h>
24532#include <stdlib.h>
24533int
24534main ()
24535{
24536
24537  FILE *f = fopen ("conftest.val", "w");
24538  if (! f)
24539    return 1;
24540  if (((long int) (sizeof (ac__type_sizeof_))) < 0)
24541    {
24542      long int i = longval ();
24543      if (i != ((long int) (sizeof (ac__type_sizeof_))))
24544	return 1;
24545      fprintf (f, "%ld\n", i);
24546    }
24547  else
24548    {
24549      unsigned long int i = ulongval ();
24550      if (i != ((long int) (sizeof (ac__type_sizeof_))))
24551	return 1;
24552      fprintf (f, "%lu\n", i);
24553    }
24554  return ferror (f) || fclose (f) != 0;
24555
24556  ;
24557  return 0;
24558}
24559_ACEOF
24560rm -f conftest$ac_exeext
24561if { (ac_try="$ac_link"
24562case "(($ac_try" in
24563  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24564  *) ac_try_echo=$ac_try;;
24565esac
24566eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24567  (eval "$ac_link") 2>&5
24568  ac_status=$?
24569  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24570  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24571  { (case "(($ac_try" in
24572  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24573  *) ac_try_echo=$ac_try;;
24574esac
24575eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24576  (eval "$ac_try") 2>&5
24577  ac_status=$?
24578  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24579  (exit $ac_status); }; }; then
24580  ac_cv_sizeof_short_int=`cat conftest.val`
24581else
24582  echo "$as_me: program exited with status $ac_status" >&5
24583echo "$as_me: failed program was:" >&5
24584sed 's/^/| /' conftest.$ac_ext >&5
24585
24586( exit $ac_status )
24587if test "$ac_cv_type_short_int" = yes; then
24588     { { echo "$as_me:$LINENO: error: cannot compute sizeof (short int)
24589See \`config.log' for more details." >&5
24590echo "$as_me: error: cannot compute sizeof (short int)
24591See \`config.log' for more details." >&2;}
24592   { (exit 77); exit 77; }; }
24593   else
24594     ac_cv_sizeof_short_int=0
24595   fi
24596fi
24597rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24598fi
24599rm -f conftest.val
24600fi
24601{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_short_int" >&5
24602echo "${ECHO_T}$ac_cv_sizeof_short_int" >&6; }
24603
24604
24605
24606cat >>confdefs.h <<_ACEOF
24607#define SIZEOF_SHORT_INT $ac_cv_sizeof_short_int
24608_ACEOF
24609
24610
24611{ echo "$as_me:$LINENO: checking for int" >&5
24612echo $ECHO_N "checking for int... $ECHO_C" >&6; }
24613if test "${ac_cv_type_int+set}" = set; then
24614  echo $ECHO_N "(cached) $ECHO_C" >&6
24615else
24616  cat >conftest.$ac_ext <<_ACEOF
24617/* confdefs.h.  */
24618_ACEOF
24619cat confdefs.h >>conftest.$ac_ext
24620cat >>conftest.$ac_ext <<_ACEOF
24621/* end confdefs.h.  */
24622$ac_includes_default
24623typedef int ac__type_new_;
24624int
24625main ()
24626{
24627if ((ac__type_new_ *) 0)
24628  return 0;
24629if (sizeof (ac__type_new_))
24630  return 0;
24631  ;
24632  return 0;
24633}
24634_ACEOF
24635rm -f conftest.$ac_objext
24636if { (ac_try="$ac_compile"
24637case "(($ac_try" in
24638  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24639  *) ac_try_echo=$ac_try;;
24640esac
24641eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24642  (eval "$ac_compile") 2>conftest.er1
24643  ac_status=$?
24644  grep -v '^ *+' conftest.er1 >conftest.err
24645  rm -f conftest.er1
24646  cat conftest.err >&5
24647  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24648  (exit $ac_status); } && {
24649	 test -z "$ac_c_werror_flag" ||
24650	 test ! -s conftest.err
24651       } && test -s conftest.$ac_objext; then
24652  ac_cv_type_int=yes
24653else
24654  echo "$as_me: failed program was:" >&5
24655sed 's/^/| /' conftest.$ac_ext >&5
24656
24657	ac_cv_type_int=no
24658fi
24659
24660rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24661fi
24662{ echo "$as_me:$LINENO: result: $ac_cv_type_int" >&5
24663echo "${ECHO_T}$ac_cv_type_int" >&6; }
24664
24665# The cast to long int works around a bug in the HP C Compiler
24666# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24667# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24668# This bug is HP SR number 8606223364.
24669{ echo "$as_me:$LINENO: checking size of int" >&5
24670echo $ECHO_N "checking size of int... $ECHO_C" >&6; }
24671if test "${ac_cv_sizeof_int+set}" = set; then
24672  echo $ECHO_N "(cached) $ECHO_C" >&6
24673else
24674  if test "$cross_compiling" = yes; then
24675  # Depending upon the size, compute the lo and hi bounds.
24676cat >conftest.$ac_ext <<_ACEOF
24677/* confdefs.h.  */
24678_ACEOF
24679cat confdefs.h >>conftest.$ac_ext
24680cat >>conftest.$ac_ext <<_ACEOF
24681/* end confdefs.h.  */
24682$ac_includes_default
24683   typedef int ac__type_sizeof_;
24684int
24685main ()
24686{
24687static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
24688test_array [0] = 0
24689
24690  ;
24691  return 0;
24692}
24693_ACEOF
24694rm -f conftest.$ac_objext
24695if { (ac_try="$ac_compile"
24696case "(($ac_try" in
24697  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24698  *) ac_try_echo=$ac_try;;
24699esac
24700eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24701  (eval "$ac_compile") 2>conftest.er1
24702  ac_status=$?
24703  grep -v '^ *+' conftest.er1 >conftest.err
24704  rm -f conftest.er1
24705  cat conftest.err >&5
24706  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24707  (exit $ac_status); } && {
24708	 test -z "$ac_c_werror_flag" ||
24709	 test ! -s conftest.err
24710       } && test -s conftest.$ac_objext; then
24711  ac_lo=0 ac_mid=0
24712  while :; do
24713    cat >conftest.$ac_ext <<_ACEOF
24714/* confdefs.h.  */
24715_ACEOF
24716cat confdefs.h >>conftest.$ac_ext
24717cat >>conftest.$ac_ext <<_ACEOF
24718/* end confdefs.h.  */
24719$ac_includes_default
24720   typedef int ac__type_sizeof_;
24721int
24722main ()
24723{
24724static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
24725test_array [0] = 0
24726
24727  ;
24728  return 0;
24729}
24730_ACEOF
24731rm -f conftest.$ac_objext
24732if { (ac_try="$ac_compile"
24733case "(($ac_try" in
24734  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24735  *) ac_try_echo=$ac_try;;
24736esac
24737eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24738  (eval "$ac_compile") 2>conftest.er1
24739  ac_status=$?
24740  grep -v '^ *+' conftest.er1 >conftest.err
24741  rm -f conftest.er1
24742  cat conftest.err >&5
24743  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24744  (exit $ac_status); } && {
24745	 test -z "$ac_c_werror_flag" ||
24746	 test ! -s conftest.err
24747       } && test -s conftest.$ac_objext; then
24748  ac_hi=$ac_mid; break
24749else
24750  echo "$as_me: failed program was:" >&5
24751sed 's/^/| /' conftest.$ac_ext >&5
24752
24753	ac_lo=`expr $ac_mid + 1`
24754			if test $ac_lo -le $ac_mid; then
24755			  ac_lo= ac_hi=
24756			  break
24757			fi
24758			ac_mid=`expr 2 '*' $ac_mid + 1`
24759fi
24760
24761rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24762  done
24763else
24764  echo "$as_me: failed program was:" >&5
24765sed 's/^/| /' conftest.$ac_ext >&5
24766
24767	cat >conftest.$ac_ext <<_ACEOF
24768/* confdefs.h.  */
24769_ACEOF
24770cat confdefs.h >>conftest.$ac_ext
24771cat >>conftest.$ac_ext <<_ACEOF
24772/* end confdefs.h.  */
24773$ac_includes_default
24774   typedef int ac__type_sizeof_;
24775int
24776main ()
24777{
24778static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
24779test_array [0] = 0
24780
24781  ;
24782  return 0;
24783}
24784_ACEOF
24785rm -f conftest.$ac_objext
24786if { (ac_try="$ac_compile"
24787case "(($ac_try" in
24788  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24789  *) ac_try_echo=$ac_try;;
24790esac
24791eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24792  (eval "$ac_compile") 2>conftest.er1
24793  ac_status=$?
24794  grep -v '^ *+' conftest.er1 >conftest.err
24795  rm -f conftest.er1
24796  cat conftest.err >&5
24797  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24798  (exit $ac_status); } && {
24799	 test -z "$ac_c_werror_flag" ||
24800	 test ! -s conftest.err
24801       } && test -s conftest.$ac_objext; then
24802  ac_hi=-1 ac_mid=-1
24803  while :; do
24804    cat >conftest.$ac_ext <<_ACEOF
24805/* confdefs.h.  */
24806_ACEOF
24807cat confdefs.h >>conftest.$ac_ext
24808cat >>conftest.$ac_ext <<_ACEOF
24809/* end confdefs.h.  */
24810$ac_includes_default
24811   typedef int ac__type_sizeof_;
24812int
24813main ()
24814{
24815static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
24816test_array [0] = 0
24817
24818  ;
24819  return 0;
24820}
24821_ACEOF
24822rm -f conftest.$ac_objext
24823if { (ac_try="$ac_compile"
24824case "(($ac_try" in
24825  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24826  *) ac_try_echo=$ac_try;;
24827esac
24828eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24829  (eval "$ac_compile") 2>conftest.er1
24830  ac_status=$?
24831  grep -v '^ *+' conftest.er1 >conftest.err
24832  rm -f conftest.er1
24833  cat conftest.err >&5
24834  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24835  (exit $ac_status); } && {
24836	 test -z "$ac_c_werror_flag" ||
24837	 test ! -s conftest.err
24838       } && test -s conftest.$ac_objext; then
24839  ac_lo=$ac_mid; break
24840else
24841  echo "$as_me: failed program was:" >&5
24842sed 's/^/| /' conftest.$ac_ext >&5
24843
24844	ac_hi=`expr '(' $ac_mid ')' - 1`
24845			if test $ac_mid -le $ac_hi; then
24846			  ac_lo= ac_hi=
24847			  break
24848			fi
24849			ac_mid=`expr 2 '*' $ac_mid`
24850fi
24851
24852rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24853  done
24854else
24855  echo "$as_me: failed program was:" >&5
24856sed 's/^/| /' conftest.$ac_ext >&5
24857
24858	ac_lo= ac_hi=
24859fi
24860
24861rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24862fi
24863
24864rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24865# Binary search between lo and hi bounds.
24866while test "x$ac_lo" != "x$ac_hi"; do
24867  ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24868  cat >conftest.$ac_ext <<_ACEOF
24869/* confdefs.h.  */
24870_ACEOF
24871cat confdefs.h >>conftest.$ac_ext
24872cat >>conftest.$ac_ext <<_ACEOF
24873/* end confdefs.h.  */
24874$ac_includes_default
24875   typedef int ac__type_sizeof_;
24876int
24877main ()
24878{
24879static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
24880test_array [0] = 0
24881
24882  ;
24883  return 0;
24884}
24885_ACEOF
24886rm -f conftest.$ac_objext
24887if { (ac_try="$ac_compile"
24888case "(($ac_try" in
24889  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24890  *) ac_try_echo=$ac_try;;
24891esac
24892eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24893  (eval "$ac_compile") 2>conftest.er1
24894  ac_status=$?
24895  grep -v '^ *+' conftest.er1 >conftest.err
24896  rm -f conftest.er1
24897  cat conftest.err >&5
24898  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24899  (exit $ac_status); } && {
24900	 test -z "$ac_c_werror_flag" ||
24901	 test ! -s conftest.err
24902       } && test -s conftest.$ac_objext; then
24903  ac_hi=$ac_mid
24904else
24905  echo "$as_me: failed program was:" >&5
24906sed 's/^/| /' conftest.$ac_ext >&5
24907
24908	ac_lo=`expr '(' $ac_mid ')' + 1`
24909fi
24910
24911rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24912done
24913case $ac_lo in
24914?*) ac_cv_sizeof_int=$ac_lo;;
24915'') if test "$ac_cv_type_int" = yes; then
24916     { { echo "$as_me:$LINENO: error: cannot compute sizeof (int)
24917See \`config.log' for more details." >&5
24918echo "$as_me: error: cannot compute sizeof (int)
24919See \`config.log' for more details." >&2;}
24920   { (exit 77); exit 77; }; }
24921   else
24922     ac_cv_sizeof_int=0
24923   fi ;;
24924esac
24925else
24926  cat >conftest.$ac_ext <<_ACEOF
24927/* confdefs.h.  */
24928_ACEOF
24929cat confdefs.h >>conftest.$ac_ext
24930cat >>conftest.$ac_ext <<_ACEOF
24931/* end confdefs.h.  */
24932$ac_includes_default
24933   typedef int ac__type_sizeof_;
24934static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
24935static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
24936#include <stdio.h>
24937#include <stdlib.h>
24938int
24939main ()
24940{
24941
24942  FILE *f = fopen ("conftest.val", "w");
24943  if (! f)
24944    return 1;
24945  if (((long int) (sizeof (ac__type_sizeof_))) < 0)
24946    {
24947      long int i = longval ();
24948      if (i != ((long int) (sizeof (ac__type_sizeof_))))
24949	return 1;
24950      fprintf (f, "%ld\n", i);
24951    }
24952  else
24953    {
24954      unsigned long int i = ulongval ();
24955      if (i != ((long int) (sizeof (ac__type_sizeof_))))
24956	return 1;
24957      fprintf (f, "%lu\n", i);
24958    }
24959  return ferror (f) || fclose (f) != 0;
24960
24961  ;
24962  return 0;
24963}
24964_ACEOF
24965rm -f conftest$ac_exeext
24966if { (ac_try="$ac_link"
24967case "(($ac_try" in
24968  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24969  *) ac_try_echo=$ac_try;;
24970esac
24971eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24972  (eval "$ac_link") 2>&5
24973  ac_status=$?
24974  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24975  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24976  { (case "(($ac_try" in
24977  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24978  *) ac_try_echo=$ac_try;;
24979esac
24980eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
24981  (eval "$ac_try") 2>&5
24982  ac_status=$?
24983  echo "$as_me:$LINENO: \$? = $ac_status" >&5
24984  (exit $ac_status); }; }; then
24985  ac_cv_sizeof_int=`cat conftest.val`
24986else
24987  echo "$as_me: program exited with status $ac_status" >&5
24988echo "$as_me: failed program was:" >&5
24989sed 's/^/| /' conftest.$ac_ext >&5
24990
24991( exit $ac_status )
24992if test "$ac_cv_type_int" = yes; then
24993     { { echo "$as_me:$LINENO: error: cannot compute sizeof (int)
24994See \`config.log' for more details." >&5
24995echo "$as_me: error: cannot compute sizeof (int)
24996See \`config.log' for more details." >&2;}
24997   { (exit 77); exit 77; }; }
24998   else
24999     ac_cv_sizeof_int=0
25000   fi
25001fi
25002rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25003fi
25004rm -f conftest.val
25005fi
25006{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_int" >&5
25007echo "${ECHO_T}$ac_cv_sizeof_int" >&6; }
25008
25009
25010
25011cat >>confdefs.h <<_ACEOF
25012#define SIZEOF_INT $ac_cv_sizeof_int
25013_ACEOF
25014
25015
25016{ echo "$as_me:$LINENO: checking for long int" >&5
25017echo $ECHO_N "checking for long int... $ECHO_C" >&6; }
25018if test "${ac_cv_type_long_int+set}" = set; then
25019  echo $ECHO_N "(cached) $ECHO_C" >&6
25020else
25021  cat >conftest.$ac_ext <<_ACEOF
25022/* confdefs.h.  */
25023_ACEOF
25024cat confdefs.h >>conftest.$ac_ext
25025cat >>conftest.$ac_ext <<_ACEOF
25026/* end confdefs.h.  */
25027$ac_includes_default
25028typedef long int ac__type_new_;
25029int
25030main ()
25031{
25032if ((ac__type_new_ *) 0)
25033  return 0;
25034if (sizeof (ac__type_new_))
25035  return 0;
25036  ;
25037  return 0;
25038}
25039_ACEOF
25040rm -f conftest.$ac_objext
25041if { (ac_try="$ac_compile"
25042case "(($ac_try" in
25043  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25044  *) ac_try_echo=$ac_try;;
25045esac
25046eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25047  (eval "$ac_compile") 2>conftest.er1
25048  ac_status=$?
25049  grep -v '^ *+' conftest.er1 >conftest.err
25050  rm -f conftest.er1
25051  cat conftest.err >&5
25052  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25053  (exit $ac_status); } && {
25054	 test -z "$ac_c_werror_flag" ||
25055	 test ! -s conftest.err
25056       } && test -s conftest.$ac_objext; then
25057  ac_cv_type_long_int=yes
25058else
25059  echo "$as_me: failed program was:" >&5
25060sed 's/^/| /' conftest.$ac_ext >&5
25061
25062	ac_cv_type_long_int=no
25063fi
25064
25065rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25066fi
25067{ echo "$as_me:$LINENO: result: $ac_cv_type_long_int" >&5
25068echo "${ECHO_T}$ac_cv_type_long_int" >&6; }
25069
25070# The cast to long int works around a bug in the HP C Compiler
25071# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
25072# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
25073# This bug is HP SR number 8606223364.
25074{ echo "$as_me:$LINENO: checking size of long int" >&5
25075echo $ECHO_N "checking size of long int... $ECHO_C" >&6; }
25076if test "${ac_cv_sizeof_long_int+set}" = set; then
25077  echo $ECHO_N "(cached) $ECHO_C" >&6
25078else
25079  if test "$cross_compiling" = yes; then
25080  # Depending upon the size, compute the lo and hi bounds.
25081cat >conftest.$ac_ext <<_ACEOF
25082/* confdefs.h.  */
25083_ACEOF
25084cat confdefs.h >>conftest.$ac_ext
25085cat >>conftest.$ac_ext <<_ACEOF
25086/* end confdefs.h.  */
25087$ac_includes_default
25088   typedef long int ac__type_sizeof_;
25089int
25090main ()
25091{
25092static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
25093test_array [0] = 0
25094
25095  ;
25096  return 0;
25097}
25098_ACEOF
25099rm -f conftest.$ac_objext
25100if { (ac_try="$ac_compile"
25101case "(($ac_try" in
25102  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25103  *) ac_try_echo=$ac_try;;
25104esac
25105eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25106  (eval "$ac_compile") 2>conftest.er1
25107  ac_status=$?
25108  grep -v '^ *+' conftest.er1 >conftest.err
25109  rm -f conftest.er1
25110  cat conftest.err >&5
25111  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25112  (exit $ac_status); } && {
25113	 test -z "$ac_c_werror_flag" ||
25114	 test ! -s conftest.err
25115       } && test -s conftest.$ac_objext; then
25116  ac_lo=0 ac_mid=0
25117  while :; do
25118    cat >conftest.$ac_ext <<_ACEOF
25119/* confdefs.h.  */
25120_ACEOF
25121cat confdefs.h >>conftest.$ac_ext
25122cat >>conftest.$ac_ext <<_ACEOF
25123/* end confdefs.h.  */
25124$ac_includes_default
25125   typedef long int ac__type_sizeof_;
25126int
25127main ()
25128{
25129static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
25130test_array [0] = 0
25131
25132  ;
25133  return 0;
25134}
25135_ACEOF
25136rm -f conftest.$ac_objext
25137if { (ac_try="$ac_compile"
25138case "(($ac_try" in
25139  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25140  *) ac_try_echo=$ac_try;;
25141esac
25142eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25143  (eval "$ac_compile") 2>conftest.er1
25144  ac_status=$?
25145  grep -v '^ *+' conftest.er1 >conftest.err
25146  rm -f conftest.er1
25147  cat conftest.err >&5
25148  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25149  (exit $ac_status); } && {
25150	 test -z "$ac_c_werror_flag" ||
25151	 test ! -s conftest.err
25152       } && test -s conftest.$ac_objext; then
25153  ac_hi=$ac_mid; break
25154else
25155  echo "$as_me: failed program was:" >&5
25156sed 's/^/| /' conftest.$ac_ext >&5
25157
25158	ac_lo=`expr $ac_mid + 1`
25159			if test $ac_lo -le $ac_mid; then
25160			  ac_lo= ac_hi=
25161			  break
25162			fi
25163			ac_mid=`expr 2 '*' $ac_mid + 1`
25164fi
25165
25166rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25167  done
25168else
25169  echo "$as_me: failed program was:" >&5
25170sed 's/^/| /' conftest.$ac_ext >&5
25171
25172	cat >conftest.$ac_ext <<_ACEOF
25173/* confdefs.h.  */
25174_ACEOF
25175cat confdefs.h >>conftest.$ac_ext
25176cat >>conftest.$ac_ext <<_ACEOF
25177/* end confdefs.h.  */
25178$ac_includes_default
25179   typedef long int ac__type_sizeof_;
25180int
25181main ()
25182{
25183static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
25184test_array [0] = 0
25185
25186  ;
25187  return 0;
25188}
25189_ACEOF
25190rm -f conftest.$ac_objext
25191if { (ac_try="$ac_compile"
25192case "(($ac_try" in
25193  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25194  *) ac_try_echo=$ac_try;;
25195esac
25196eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25197  (eval "$ac_compile") 2>conftest.er1
25198  ac_status=$?
25199  grep -v '^ *+' conftest.er1 >conftest.err
25200  rm -f conftest.er1
25201  cat conftest.err >&5
25202  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25203  (exit $ac_status); } && {
25204	 test -z "$ac_c_werror_flag" ||
25205	 test ! -s conftest.err
25206       } && test -s conftest.$ac_objext; then
25207  ac_hi=-1 ac_mid=-1
25208  while :; do
25209    cat >conftest.$ac_ext <<_ACEOF
25210/* confdefs.h.  */
25211_ACEOF
25212cat confdefs.h >>conftest.$ac_ext
25213cat >>conftest.$ac_ext <<_ACEOF
25214/* end confdefs.h.  */
25215$ac_includes_default
25216   typedef long int ac__type_sizeof_;
25217int
25218main ()
25219{
25220static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
25221test_array [0] = 0
25222
25223  ;
25224  return 0;
25225}
25226_ACEOF
25227rm -f conftest.$ac_objext
25228if { (ac_try="$ac_compile"
25229case "(($ac_try" in
25230  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25231  *) ac_try_echo=$ac_try;;
25232esac
25233eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25234  (eval "$ac_compile") 2>conftest.er1
25235  ac_status=$?
25236  grep -v '^ *+' conftest.er1 >conftest.err
25237  rm -f conftest.er1
25238  cat conftest.err >&5
25239  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25240  (exit $ac_status); } && {
25241	 test -z "$ac_c_werror_flag" ||
25242	 test ! -s conftest.err
25243       } && test -s conftest.$ac_objext; then
25244  ac_lo=$ac_mid; break
25245else
25246  echo "$as_me: failed program was:" >&5
25247sed 's/^/| /' conftest.$ac_ext >&5
25248
25249	ac_hi=`expr '(' $ac_mid ')' - 1`
25250			if test $ac_mid -le $ac_hi; then
25251			  ac_lo= ac_hi=
25252			  break
25253			fi
25254			ac_mid=`expr 2 '*' $ac_mid`
25255fi
25256
25257rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25258  done
25259else
25260  echo "$as_me: failed program was:" >&5
25261sed 's/^/| /' conftest.$ac_ext >&5
25262
25263	ac_lo= ac_hi=
25264fi
25265
25266rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25267fi
25268
25269rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25270# Binary search between lo and hi bounds.
25271while test "x$ac_lo" != "x$ac_hi"; do
25272  ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25273  cat >conftest.$ac_ext <<_ACEOF
25274/* confdefs.h.  */
25275_ACEOF
25276cat confdefs.h >>conftest.$ac_ext
25277cat >>conftest.$ac_ext <<_ACEOF
25278/* end confdefs.h.  */
25279$ac_includes_default
25280   typedef long int ac__type_sizeof_;
25281int
25282main ()
25283{
25284static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
25285test_array [0] = 0
25286
25287  ;
25288  return 0;
25289}
25290_ACEOF
25291rm -f conftest.$ac_objext
25292if { (ac_try="$ac_compile"
25293case "(($ac_try" in
25294  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25295  *) ac_try_echo=$ac_try;;
25296esac
25297eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25298  (eval "$ac_compile") 2>conftest.er1
25299  ac_status=$?
25300  grep -v '^ *+' conftest.er1 >conftest.err
25301  rm -f conftest.er1
25302  cat conftest.err >&5
25303  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25304  (exit $ac_status); } && {
25305	 test -z "$ac_c_werror_flag" ||
25306	 test ! -s conftest.err
25307       } && test -s conftest.$ac_objext; then
25308  ac_hi=$ac_mid
25309else
25310  echo "$as_me: failed program was:" >&5
25311sed 's/^/| /' conftest.$ac_ext >&5
25312
25313	ac_lo=`expr '(' $ac_mid ')' + 1`
25314fi
25315
25316rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25317done
25318case $ac_lo in
25319?*) ac_cv_sizeof_long_int=$ac_lo;;
25320'') if test "$ac_cv_type_long_int" = yes; then
25321     { { echo "$as_me:$LINENO: error: cannot compute sizeof (long int)
25322See \`config.log' for more details." >&5
25323echo "$as_me: error: cannot compute sizeof (long int)
25324See \`config.log' for more details." >&2;}
25325   { (exit 77); exit 77; }; }
25326   else
25327     ac_cv_sizeof_long_int=0
25328   fi ;;
25329esac
25330else
25331  cat >conftest.$ac_ext <<_ACEOF
25332/* confdefs.h.  */
25333_ACEOF
25334cat confdefs.h >>conftest.$ac_ext
25335cat >>conftest.$ac_ext <<_ACEOF
25336/* end confdefs.h.  */
25337$ac_includes_default
25338   typedef long int ac__type_sizeof_;
25339static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
25340static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
25341#include <stdio.h>
25342#include <stdlib.h>
25343int
25344main ()
25345{
25346
25347  FILE *f = fopen ("conftest.val", "w");
25348  if (! f)
25349    return 1;
25350  if (((long int) (sizeof (ac__type_sizeof_))) < 0)
25351    {
25352      long int i = longval ();
25353      if (i != ((long int) (sizeof (ac__type_sizeof_))))
25354	return 1;
25355      fprintf (f, "%ld\n", i);
25356    }
25357  else
25358    {
25359      unsigned long int i = ulongval ();
25360      if (i != ((long int) (sizeof (ac__type_sizeof_))))
25361	return 1;
25362      fprintf (f, "%lu\n", i);
25363    }
25364  return ferror (f) || fclose (f) != 0;
25365
25366  ;
25367  return 0;
25368}
25369_ACEOF
25370rm -f conftest$ac_exeext
25371if { (ac_try="$ac_link"
25372case "(($ac_try" in
25373  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25374  *) ac_try_echo=$ac_try;;
25375esac
25376eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25377  (eval "$ac_link") 2>&5
25378  ac_status=$?
25379  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25380  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25381  { (case "(($ac_try" in
25382  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25383  *) ac_try_echo=$ac_try;;
25384esac
25385eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25386  (eval "$ac_try") 2>&5
25387  ac_status=$?
25388  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25389  (exit $ac_status); }; }; then
25390  ac_cv_sizeof_long_int=`cat conftest.val`
25391else
25392  echo "$as_me: program exited with status $ac_status" >&5
25393echo "$as_me: failed program was:" >&5
25394sed 's/^/| /' conftest.$ac_ext >&5
25395
25396( exit $ac_status )
25397if test "$ac_cv_type_long_int" = yes; then
25398     { { echo "$as_me:$LINENO: error: cannot compute sizeof (long int)
25399See \`config.log' for more details." >&5
25400echo "$as_me: error: cannot compute sizeof (long int)
25401See \`config.log' for more details." >&2;}
25402   { (exit 77); exit 77; }; }
25403   else
25404     ac_cv_sizeof_long_int=0
25405   fi
25406fi
25407rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25408fi
25409rm -f conftest.val
25410fi
25411{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_int" >&5
25412echo "${ECHO_T}$ac_cv_sizeof_long_int" >&6; }
25413
25414
25415
25416cat >>confdefs.h <<_ACEOF
25417#define SIZEOF_LONG_INT $ac_cv_sizeof_long_int
25418_ACEOF
25419
25420
25421{ echo "$as_me:$LINENO: checking for long long int" >&5
25422echo $ECHO_N "checking for long long int... $ECHO_C" >&6; }
25423if test "${ac_cv_type_long_long_int+set}" = set; then
25424  echo $ECHO_N "(cached) $ECHO_C" >&6
25425else
25426  cat >conftest.$ac_ext <<_ACEOF
25427/* confdefs.h.  */
25428_ACEOF
25429cat confdefs.h >>conftest.$ac_ext
25430cat >>conftest.$ac_ext <<_ACEOF
25431/* end confdefs.h.  */
25432$ac_includes_default
25433typedef long long int ac__type_new_;
25434int
25435main ()
25436{
25437if ((ac__type_new_ *) 0)
25438  return 0;
25439if (sizeof (ac__type_new_))
25440  return 0;
25441  ;
25442  return 0;
25443}
25444_ACEOF
25445rm -f conftest.$ac_objext
25446if { (ac_try="$ac_compile"
25447case "(($ac_try" in
25448  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25449  *) ac_try_echo=$ac_try;;
25450esac
25451eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25452  (eval "$ac_compile") 2>conftest.er1
25453  ac_status=$?
25454  grep -v '^ *+' conftest.er1 >conftest.err
25455  rm -f conftest.er1
25456  cat conftest.err >&5
25457  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25458  (exit $ac_status); } && {
25459	 test -z "$ac_c_werror_flag" ||
25460	 test ! -s conftest.err
25461       } && test -s conftest.$ac_objext; then
25462  ac_cv_type_long_long_int=yes
25463else
25464  echo "$as_me: failed program was:" >&5
25465sed 's/^/| /' conftest.$ac_ext >&5
25466
25467	ac_cv_type_long_long_int=no
25468fi
25469
25470rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25471fi
25472{ echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
25473echo "${ECHO_T}$ac_cv_type_long_long_int" >&6; }
25474
25475# The cast to long int works around a bug in the HP C Compiler
25476# version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
25477# declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
25478# This bug is HP SR number 8606223364.
25479{ echo "$as_me:$LINENO: checking size of long long int" >&5
25480echo $ECHO_N "checking size of long long int... $ECHO_C" >&6; }
25481if test "${ac_cv_sizeof_long_long_int+set}" = set; then
25482  echo $ECHO_N "(cached) $ECHO_C" >&6
25483else
25484  if test "$cross_compiling" = yes; then
25485  # Depending upon the size, compute the lo and hi bounds.
25486cat >conftest.$ac_ext <<_ACEOF
25487/* confdefs.h.  */
25488_ACEOF
25489cat confdefs.h >>conftest.$ac_ext
25490cat >>conftest.$ac_ext <<_ACEOF
25491/* end confdefs.h.  */
25492$ac_includes_default
25493   typedef long long int ac__type_sizeof_;
25494int
25495main ()
25496{
25497static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= 0)];
25498test_array [0] = 0
25499
25500  ;
25501  return 0;
25502}
25503_ACEOF
25504rm -f conftest.$ac_objext
25505if { (ac_try="$ac_compile"
25506case "(($ac_try" in
25507  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25508  *) ac_try_echo=$ac_try;;
25509esac
25510eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25511  (eval "$ac_compile") 2>conftest.er1
25512  ac_status=$?
25513  grep -v '^ *+' conftest.er1 >conftest.err
25514  rm -f conftest.er1
25515  cat conftest.err >&5
25516  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25517  (exit $ac_status); } && {
25518	 test -z "$ac_c_werror_flag" ||
25519	 test ! -s conftest.err
25520       } && test -s conftest.$ac_objext; then
25521  ac_lo=0 ac_mid=0
25522  while :; do
25523    cat >conftest.$ac_ext <<_ACEOF
25524/* confdefs.h.  */
25525_ACEOF
25526cat confdefs.h >>conftest.$ac_ext
25527cat >>conftest.$ac_ext <<_ACEOF
25528/* end confdefs.h.  */
25529$ac_includes_default
25530   typedef long long int ac__type_sizeof_;
25531int
25532main ()
25533{
25534static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
25535test_array [0] = 0
25536
25537  ;
25538  return 0;
25539}
25540_ACEOF
25541rm -f conftest.$ac_objext
25542if { (ac_try="$ac_compile"
25543case "(($ac_try" in
25544  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25545  *) ac_try_echo=$ac_try;;
25546esac
25547eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25548  (eval "$ac_compile") 2>conftest.er1
25549  ac_status=$?
25550  grep -v '^ *+' conftest.er1 >conftest.err
25551  rm -f conftest.er1
25552  cat conftest.err >&5
25553  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25554  (exit $ac_status); } && {
25555	 test -z "$ac_c_werror_flag" ||
25556	 test ! -s conftest.err
25557       } && test -s conftest.$ac_objext; then
25558  ac_hi=$ac_mid; break
25559else
25560  echo "$as_me: failed program was:" >&5
25561sed 's/^/| /' conftest.$ac_ext >&5
25562
25563	ac_lo=`expr $ac_mid + 1`
25564			if test $ac_lo -le $ac_mid; then
25565			  ac_lo= ac_hi=
25566			  break
25567			fi
25568			ac_mid=`expr 2 '*' $ac_mid + 1`
25569fi
25570
25571rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25572  done
25573else
25574  echo "$as_me: failed program was:" >&5
25575sed 's/^/| /' conftest.$ac_ext >&5
25576
25577	cat >conftest.$ac_ext <<_ACEOF
25578/* confdefs.h.  */
25579_ACEOF
25580cat confdefs.h >>conftest.$ac_ext
25581cat >>conftest.$ac_ext <<_ACEOF
25582/* end confdefs.h.  */
25583$ac_includes_default
25584   typedef long long int ac__type_sizeof_;
25585int
25586main ()
25587{
25588static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) < 0)];
25589test_array [0] = 0
25590
25591  ;
25592  return 0;
25593}
25594_ACEOF
25595rm -f conftest.$ac_objext
25596if { (ac_try="$ac_compile"
25597case "(($ac_try" in
25598  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25599  *) ac_try_echo=$ac_try;;
25600esac
25601eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25602  (eval "$ac_compile") 2>conftest.er1
25603  ac_status=$?
25604  grep -v '^ *+' conftest.er1 >conftest.err
25605  rm -f conftest.er1
25606  cat conftest.err >&5
25607  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25608  (exit $ac_status); } && {
25609	 test -z "$ac_c_werror_flag" ||
25610	 test ! -s conftest.err
25611       } && test -s conftest.$ac_objext; then
25612  ac_hi=-1 ac_mid=-1
25613  while :; do
25614    cat >conftest.$ac_ext <<_ACEOF
25615/* confdefs.h.  */
25616_ACEOF
25617cat confdefs.h >>conftest.$ac_ext
25618cat >>conftest.$ac_ext <<_ACEOF
25619/* end confdefs.h.  */
25620$ac_includes_default
25621   typedef long long int ac__type_sizeof_;
25622int
25623main ()
25624{
25625static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) >= $ac_mid)];
25626test_array [0] = 0
25627
25628  ;
25629  return 0;
25630}
25631_ACEOF
25632rm -f conftest.$ac_objext
25633if { (ac_try="$ac_compile"
25634case "(($ac_try" in
25635  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25636  *) ac_try_echo=$ac_try;;
25637esac
25638eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25639  (eval "$ac_compile") 2>conftest.er1
25640  ac_status=$?
25641  grep -v '^ *+' conftest.er1 >conftest.err
25642  rm -f conftest.er1
25643  cat conftest.err >&5
25644  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25645  (exit $ac_status); } && {
25646	 test -z "$ac_c_werror_flag" ||
25647	 test ! -s conftest.err
25648       } && test -s conftest.$ac_objext; then
25649  ac_lo=$ac_mid; break
25650else
25651  echo "$as_me: failed program was:" >&5
25652sed 's/^/| /' conftest.$ac_ext >&5
25653
25654	ac_hi=`expr '(' $ac_mid ')' - 1`
25655			if test $ac_mid -le $ac_hi; then
25656			  ac_lo= ac_hi=
25657			  break
25658			fi
25659			ac_mid=`expr 2 '*' $ac_mid`
25660fi
25661
25662rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25663  done
25664else
25665  echo "$as_me: failed program was:" >&5
25666sed 's/^/| /' conftest.$ac_ext >&5
25667
25668	ac_lo= ac_hi=
25669fi
25670
25671rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25672fi
25673
25674rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25675# Binary search between lo and hi bounds.
25676while test "x$ac_lo" != "x$ac_hi"; do
25677  ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25678  cat >conftest.$ac_ext <<_ACEOF
25679/* confdefs.h.  */
25680_ACEOF
25681cat confdefs.h >>conftest.$ac_ext
25682cat >>conftest.$ac_ext <<_ACEOF
25683/* end confdefs.h.  */
25684$ac_includes_default
25685   typedef long long int ac__type_sizeof_;
25686int
25687main ()
25688{
25689static int test_array [1 - 2 * !(((long int) (sizeof (ac__type_sizeof_))) <= $ac_mid)];
25690test_array [0] = 0
25691
25692  ;
25693  return 0;
25694}
25695_ACEOF
25696rm -f conftest.$ac_objext
25697if { (ac_try="$ac_compile"
25698case "(($ac_try" in
25699  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25700  *) ac_try_echo=$ac_try;;
25701esac
25702eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25703  (eval "$ac_compile") 2>conftest.er1
25704  ac_status=$?
25705  grep -v '^ *+' conftest.er1 >conftest.err
25706  rm -f conftest.er1
25707  cat conftest.err >&5
25708  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25709  (exit $ac_status); } && {
25710	 test -z "$ac_c_werror_flag" ||
25711	 test ! -s conftest.err
25712       } && test -s conftest.$ac_objext; then
25713  ac_hi=$ac_mid
25714else
25715  echo "$as_me: failed program was:" >&5
25716sed 's/^/| /' conftest.$ac_ext >&5
25717
25718	ac_lo=`expr '(' $ac_mid ')' + 1`
25719fi
25720
25721rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25722done
25723case $ac_lo in
25724?*) ac_cv_sizeof_long_long_int=$ac_lo;;
25725'') if test "$ac_cv_type_long_long_int" = yes; then
25726     { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long int)
25727See \`config.log' for more details." >&5
25728echo "$as_me: error: cannot compute sizeof (long long int)
25729See \`config.log' for more details." >&2;}
25730   { (exit 77); exit 77; }; }
25731   else
25732     ac_cv_sizeof_long_long_int=0
25733   fi ;;
25734esac
25735else
25736  cat >conftest.$ac_ext <<_ACEOF
25737/* confdefs.h.  */
25738_ACEOF
25739cat confdefs.h >>conftest.$ac_ext
25740cat >>conftest.$ac_ext <<_ACEOF
25741/* end confdefs.h.  */
25742$ac_includes_default
25743   typedef long long int ac__type_sizeof_;
25744static long int longval () { return (long int) (sizeof (ac__type_sizeof_)); }
25745static unsigned long int ulongval () { return (long int) (sizeof (ac__type_sizeof_)); }
25746#include <stdio.h>
25747#include <stdlib.h>
25748int
25749main ()
25750{
25751
25752  FILE *f = fopen ("conftest.val", "w");
25753  if (! f)
25754    return 1;
25755  if (((long int) (sizeof (ac__type_sizeof_))) < 0)
25756    {
25757      long int i = longval ();
25758      if (i != ((long int) (sizeof (ac__type_sizeof_))))
25759	return 1;
25760      fprintf (f, "%ld\n", i);
25761    }
25762  else
25763    {
25764      unsigned long int i = ulongval ();
25765      if (i != ((long int) (sizeof (ac__type_sizeof_))))
25766	return 1;
25767      fprintf (f, "%lu\n", i);
25768    }
25769  return ferror (f) || fclose (f) != 0;
25770
25771  ;
25772  return 0;
25773}
25774_ACEOF
25775rm -f conftest$ac_exeext
25776if { (ac_try="$ac_link"
25777case "(($ac_try" in
25778  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25779  *) ac_try_echo=$ac_try;;
25780esac
25781eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25782  (eval "$ac_link") 2>&5
25783  ac_status=$?
25784  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25785  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25786  { (case "(($ac_try" in
25787  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25788  *) ac_try_echo=$ac_try;;
25789esac
25790eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25791  (eval "$ac_try") 2>&5
25792  ac_status=$?
25793  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25794  (exit $ac_status); }; }; then
25795  ac_cv_sizeof_long_long_int=`cat conftest.val`
25796else
25797  echo "$as_me: program exited with status $ac_status" >&5
25798echo "$as_me: failed program was:" >&5
25799sed 's/^/| /' conftest.$ac_ext >&5
25800
25801( exit $ac_status )
25802if test "$ac_cv_type_long_long_int" = yes; then
25803     { { echo "$as_me:$LINENO: error: cannot compute sizeof (long long int)
25804See \`config.log' for more details." >&5
25805echo "$as_me: error: cannot compute sizeof (long long int)
25806See \`config.log' for more details." >&2;}
25807   { (exit 77); exit 77; }; }
25808   else
25809     ac_cv_sizeof_long_long_int=0
25810   fi
25811fi
25812rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25813fi
25814rm -f conftest.val
25815fi
25816{ echo "$as_me:$LINENO: result: $ac_cv_sizeof_long_long_int" >&5
25817echo "${ECHO_T}$ac_cv_sizeof_long_long_int" >&6; }
25818
25819
25820
25821cat >>confdefs.h <<_ACEOF
25822#define SIZEOF_LONG_LONG_INT $ac_cv_sizeof_long_long_int
25823_ACEOF
25824
25825
25826
25827# Sanity check long long for some platforms (AIX)
25828if test "x$ac_cv_sizeof_long_long_int" = "x4" ; then
25829	ac_cv_sizeof_long_long_int=0
25830fi
25831
25832# compute LLONG_MIN and LLONG_MAX if we don't know them.
25833if test -z "$have_llong_max"; then
25834	{ echo "$as_me:$LINENO: checking for max value of long long" >&5
25835echo $ECHO_N "checking for max value of long long... $ECHO_C" >&6; }
25836	if test "$cross_compiling" = yes; then
25837
25838			{ echo "$as_me:$LINENO: WARNING: cross compiling: not checking" >&5
25839echo "$as_me: WARNING: cross compiling: not checking" >&2;}
25840
25841
25842else
25843  cat >conftest.$ac_ext <<_ACEOF
25844/* confdefs.h.  */
25845_ACEOF
25846cat confdefs.h >>conftest.$ac_ext
25847cat >>conftest.$ac_ext <<_ACEOF
25848/* end confdefs.h.  */
25849
25850#include <stdio.h>
25851/* Why is this so damn hard? */
25852#ifdef __GNUC__
25853# undef __GNUC__
25854#endif
25855#define __USE_ISOC99
25856#include <limits.h>
25857#define DATA "conftest.llminmax"
25858#define my_abs(a) ((a) < 0 ? ((a) * -1) : (a))
25859
25860/*
25861 * printf in libc on some platforms (eg old Tru64) does not understand %lld so
25862 * we do this the hard way.
25863 */
25864static int
25865fprint_ll(FILE *f, long long n)
25866{
25867	unsigned int i;
25868	int l[sizeof(long long) * 8];
25869
25870	if (n < 0)
25871		if (fprintf(f, "-") < 0)
25872			return -1;
25873	for (i = 0; n != 0; i++) {
25874		l[i] = my_abs(n % 10);
25875		n /= 10;
25876	}
25877	do {
25878		if (fprintf(f, "%d", l[--i]) < 0)
25879			return -1;
25880	} while (i != 0);
25881	if (fprintf(f, " ") < 0)
25882		return -1;
25883	return 0;
25884}
25885
25886int
25887main ()
25888{
25889
25890	FILE *f;
25891	long long i, llmin, llmax = 0;
25892
25893	if((f = fopen(DATA,"w")) == NULL)
25894		exit(1);
25895
25896#if defined(LLONG_MIN) && defined(LLONG_MAX)
25897	fprintf(stderr, "Using system header for LLONG_MIN and LLONG_MAX\n");
25898	llmin = LLONG_MIN;
25899	llmax = LLONG_MAX;
25900#else
25901	fprintf(stderr, "Calculating  LLONG_MIN and LLONG_MAX\n");
25902	/* This will work on one's complement and two's complement */
25903	for (i = 1; i > llmax; i <<= 1, i++)
25904		llmax = i;
25905	llmin = llmax + 1LL;	/* wrap */
25906#endif
25907
25908	/* Sanity check */
25909	if (llmin + 1 < llmin || llmin - 1 < llmin || llmax + 1 > llmax
25910	    || llmax - 1 > llmax || llmin == llmax || llmin == 0
25911	    || llmax == 0 || llmax < LONG_MAX || llmin > LONG_MIN) {
25912		fprintf(f, "unknown unknown\n");
25913		exit(2);
25914	}
25915
25916	if (fprint_ll(f, llmin) < 0)
25917		exit(3);
25918	if (fprint_ll(f, llmax) < 0)
25919		exit(4);
25920	if (fclose(f) < 0)
25921		exit(5);
25922	exit(0);
25923
25924  ;
25925  return 0;
25926}
25927_ACEOF
25928rm -f conftest$ac_exeext
25929if { (ac_try="$ac_link"
25930case "(($ac_try" in
25931  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25932  *) ac_try_echo=$ac_try;;
25933esac
25934eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25935  (eval "$ac_link") 2>&5
25936  ac_status=$?
25937  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25938  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25939  { (case "(($ac_try" in
25940  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25941  *) ac_try_echo=$ac_try;;
25942esac
25943eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
25944  (eval "$ac_try") 2>&5
25945  ac_status=$?
25946  echo "$as_me:$LINENO: \$? = $ac_status" >&5
25947  (exit $ac_status); }; }; then
25948
25949			llong_min=`$AWK '{print $1}' conftest.llminmax`
25950			llong_max=`$AWK '{print $2}' conftest.llminmax`
25951
25952			{ echo "$as_me:$LINENO: result: $llong_max" >&5
25953echo "${ECHO_T}$llong_max" >&6; }
25954
25955cat >>confdefs.h <<_ACEOF
25956#define LLONG_MAX ${llong_max}LL
25957_ACEOF
25958
25959			{ echo "$as_me:$LINENO: checking for min value of long long" >&5
25960echo $ECHO_N "checking for min value of long long... $ECHO_C" >&6; }
25961			{ echo "$as_me:$LINENO: result: $llong_min" >&5
25962echo "${ECHO_T}$llong_min" >&6; }
25963
25964cat >>confdefs.h <<_ACEOF
25965#define LLONG_MIN ${llong_min}LL
25966_ACEOF
25967
25968
25969else
25970  echo "$as_me: program exited with status $ac_status" >&5
25971echo "$as_me: failed program was:" >&5
25972sed 's/^/| /' conftest.$ac_ext >&5
25973
25974( exit $ac_status )
25975
25976			{ echo "$as_me:$LINENO: result: not found" >&5
25977echo "${ECHO_T}not found" >&6; }
25978
25979fi
25980rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25981fi
25982
25983
25984fi
25985
25986
25987# More checks for data types
25988{ echo "$as_me:$LINENO: checking for u_int type" >&5
25989echo $ECHO_N "checking for u_int type... $ECHO_C" >&6; }
25990if test "${ac_cv_have_u_int+set}" = set; then
25991  echo $ECHO_N "(cached) $ECHO_C" >&6
25992else
25993
25994	cat >conftest.$ac_ext <<_ACEOF
25995/* confdefs.h.  */
25996_ACEOF
25997cat confdefs.h >>conftest.$ac_ext
25998cat >>conftest.$ac_ext <<_ACEOF
25999/* end confdefs.h.  */
26000 #include <sys/types.h>
26001int
26002main ()
26003{
26004 u_int a; a = 1;
26005  ;
26006  return 0;
26007}
26008_ACEOF
26009rm -f conftest.$ac_objext
26010if { (ac_try="$ac_compile"
26011case "(($ac_try" in
26012  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26013  *) ac_try_echo=$ac_try;;
26014esac
26015eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26016  (eval "$ac_compile") 2>conftest.er1
26017  ac_status=$?
26018  grep -v '^ *+' conftest.er1 >conftest.err
26019  rm -f conftest.er1
26020  cat conftest.err >&5
26021  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26022  (exit $ac_status); } && {
26023	 test -z "$ac_c_werror_flag" ||
26024	 test ! -s conftest.err
26025       } && test -s conftest.$ac_objext; then
26026   ac_cv_have_u_int="yes"
26027else
26028  echo "$as_me: failed program was:" >&5
26029sed 's/^/| /' conftest.$ac_ext >&5
26030
26031	 ac_cv_have_u_int="no"
26032
26033fi
26034
26035rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26036
26037fi
26038{ echo "$as_me:$LINENO: result: $ac_cv_have_u_int" >&5
26039echo "${ECHO_T}$ac_cv_have_u_int" >&6; }
26040if test "x$ac_cv_have_u_int" = "xyes" ; then
26041
26042cat >>confdefs.h <<\_ACEOF
26043#define HAVE_U_INT 1
26044_ACEOF
26045
26046	have_u_int=1
26047fi
26048
26049{ echo "$as_me:$LINENO: checking for intXX_t types" >&5
26050echo $ECHO_N "checking for intXX_t types... $ECHO_C" >&6; }
26051if test "${ac_cv_have_intxx_t+set}" = set; then
26052  echo $ECHO_N "(cached) $ECHO_C" >&6
26053else
26054
26055	cat >conftest.$ac_ext <<_ACEOF
26056/* confdefs.h.  */
26057_ACEOF
26058cat confdefs.h >>conftest.$ac_ext
26059cat >>conftest.$ac_ext <<_ACEOF
26060/* end confdefs.h.  */
26061 #include <sys/types.h>
26062int
26063main ()
26064{
26065 int8_t a; int16_t b; int32_t c; a = b = c = 1;
26066  ;
26067  return 0;
26068}
26069_ACEOF
26070rm -f conftest.$ac_objext
26071if { (ac_try="$ac_compile"
26072case "(($ac_try" in
26073  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26074  *) ac_try_echo=$ac_try;;
26075esac
26076eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26077  (eval "$ac_compile") 2>conftest.er1
26078  ac_status=$?
26079  grep -v '^ *+' conftest.er1 >conftest.err
26080  rm -f conftest.er1
26081  cat conftest.err >&5
26082  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26083  (exit $ac_status); } && {
26084	 test -z "$ac_c_werror_flag" ||
26085	 test ! -s conftest.err
26086       } && test -s conftest.$ac_objext; then
26087   ac_cv_have_intxx_t="yes"
26088else
26089  echo "$as_me: failed program was:" >&5
26090sed 's/^/| /' conftest.$ac_ext >&5
26091
26092	 ac_cv_have_intxx_t="no"
26093
26094fi
26095
26096rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26097
26098fi
26099{ echo "$as_me:$LINENO: result: $ac_cv_have_intxx_t" >&5
26100echo "${ECHO_T}$ac_cv_have_intxx_t" >&6; }
26101if test "x$ac_cv_have_intxx_t" = "xyes" ; then
26102
26103cat >>confdefs.h <<\_ACEOF
26104#define HAVE_INTXX_T 1
26105_ACEOF
26106
26107	have_intxx_t=1
26108fi
26109
26110if (test -z "$have_intxx_t" && \
26111	   test "x$ac_cv_header_stdint_h" = "xyes")
26112then
26113    { echo "$as_me:$LINENO: checking for intXX_t types in stdint.h" >&5
26114echo $ECHO_N "checking for intXX_t types in stdint.h... $ECHO_C" >&6; }
26115	cat >conftest.$ac_ext <<_ACEOF
26116/* confdefs.h.  */
26117_ACEOF
26118cat confdefs.h >>conftest.$ac_ext
26119cat >>conftest.$ac_ext <<_ACEOF
26120/* end confdefs.h.  */
26121 #include <stdint.h>
26122int
26123main ()
26124{
26125 int8_t a; int16_t b; int32_t c; a = b = c = 1;
26126  ;
26127  return 0;
26128}
26129_ACEOF
26130rm -f conftest.$ac_objext
26131if { (ac_try="$ac_compile"
26132case "(($ac_try" in
26133  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26134  *) ac_try_echo=$ac_try;;
26135esac
26136eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26137  (eval "$ac_compile") 2>conftest.er1
26138  ac_status=$?
26139  grep -v '^ *+' conftest.er1 >conftest.err
26140  rm -f conftest.er1
26141  cat conftest.err >&5
26142  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26143  (exit $ac_status); } && {
26144	 test -z "$ac_c_werror_flag" ||
26145	 test ! -s conftest.err
26146       } && test -s conftest.$ac_objext; then
26147
26148			cat >>confdefs.h <<\_ACEOF
26149#define HAVE_INTXX_T 1
26150_ACEOF
26151
26152			{ echo "$as_me:$LINENO: result: yes" >&5
26153echo "${ECHO_T}yes" >&6; }
26154
26155else
26156  echo "$as_me: failed program was:" >&5
26157sed 's/^/| /' conftest.$ac_ext >&5
26158
26159	 { echo "$as_me:$LINENO: result: no" >&5
26160echo "${ECHO_T}no" >&6; }
26161
26162fi
26163
26164rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26165fi
26166
26167{ echo "$as_me:$LINENO: checking for int64_t type" >&5
26168echo $ECHO_N "checking for int64_t type... $ECHO_C" >&6; }
26169if test "${ac_cv_have_int64_t+set}" = set; then
26170  echo $ECHO_N "(cached) $ECHO_C" >&6
26171else
26172
26173	cat >conftest.$ac_ext <<_ACEOF
26174/* confdefs.h.  */
26175_ACEOF
26176cat confdefs.h >>conftest.$ac_ext
26177cat >>conftest.$ac_ext <<_ACEOF
26178/* end confdefs.h.  */
26179
26180#include <sys/types.h>
26181#ifdef HAVE_STDINT_H
26182# include <stdint.h>
26183#endif
26184#include <sys/socket.h>
26185#ifdef HAVE_SYS_BITYPES_H
26186# include <sys/bitypes.h>
26187#endif
26188
26189int
26190main ()
26191{
26192
26193int64_t a; a = 1;
26194
26195  ;
26196  return 0;
26197}
26198_ACEOF
26199rm -f conftest.$ac_objext
26200if { (ac_try="$ac_compile"
26201case "(($ac_try" in
26202  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26203  *) ac_try_echo=$ac_try;;
26204esac
26205eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26206  (eval "$ac_compile") 2>conftest.er1
26207  ac_status=$?
26208  grep -v '^ *+' conftest.er1 >conftest.err
26209  rm -f conftest.er1
26210  cat conftest.err >&5
26211  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26212  (exit $ac_status); } && {
26213	 test -z "$ac_c_werror_flag" ||
26214	 test ! -s conftest.err
26215       } && test -s conftest.$ac_objext; then
26216   ac_cv_have_int64_t="yes"
26217else
26218  echo "$as_me: failed program was:" >&5
26219sed 's/^/| /' conftest.$ac_ext >&5
26220
26221	 ac_cv_have_int64_t="no"
26222
26223fi
26224
26225rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26226
26227fi
26228{ echo "$as_me:$LINENO: result: $ac_cv_have_int64_t" >&5
26229echo "${ECHO_T}$ac_cv_have_int64_t" >&6; }
26230if test "x$ac_cv_have_int64_t" = "xyes" ; then
26231
26232cat >>confdefs.h <<\_ACEOF
26233#define HAVE_INT64_T 1
26234_ACEOF
26235
26236fi
26237
26238{ echo "$as_me:$LINENO: checking for u_intXX_t types" >&5
26239echo $ECHO_N "checking for u_intXX_t types... $ECHO_C" >&6; }
26240if test "${ac_cv_have_u_intxx_t+set}" = set; then
26241  echo $ECHO_N "(cached) $ECHO_C" >&6
26242else
26243
26244	cat >conftest.$ac_ext <<_ACEOF
26245/* confdefs.h.  */
26246_ACEOF
26247cat confdefs.h >>conftest.$ac_ext
26248cat >>conftest.$ac_ext <<_ACEOF
26249/* end confdefs.h.  */
26250 #include <sys/types.h>
26251int
26252main ()
26253{
26254 u_int8_t a; u_int16_t b; u_int32_t c; a = b = c = 1;
26255  ;
26256  return 0;
26257}
26258_ACEOF
26259rm -f conftest.$ac_objext
26260if { (ac_try="$ac_compile"
26261case "(($ac_try" in
26262  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26263  *) ac_try_echo=$ac_try;;
26264esac
26265eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26266  (eval "$ac_compile") 2>conftest.er1
26267  ac_status=$?
26268  grep -v '^ *+' conftest.er1 >conftest.err
26269  rm -f conftest.er1
26270  cat conftest.err >&5
26271  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26272  (exit $ac_status); } && {
26273	 test -z "$ac_c_werror_flag" ||
26274	 test ! -s conftest.err
26275       } && test -s conftest.$ac_objext; then
26276   ac_cv_have_u_intxx_t="yes"
26277else
26278  echo "$as_me: failed program was:" >&5
26279sed 's/^/| /' conftest.$ac_ext >&5
26280
26281	 ac_cv_have_u_intxx_t="no"
26282
26283fi
26284
26285rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26286
26287fi
26288{ echo "$as_me:$LINENO: result: $ac_cv_have_u_intxx_t" >&5
26289echo "${ECHO_T}$ac_cv_have_u_intxx_t" >&6; }
26290if test "x$ac_cv_have_u_intxx_t" = "xyes" ; then
26291
26292cat >>confdefs.h <<\_ACEOF
26293#define HAVE_U_INTXX_T 1
26294_ACEOF
26295
26296	have_u_intxx_t=1
26297fi
26298
26299if test -z "$have_u_intxx_t" ; then
26300    { echo "$as_me:$LINENO: checking for u_intXX_t types in sys/socket.h" >&5
26301echo $ECHO_N "checking for u_intXX_t types in sys/socket.h... $ECHO_C" >&6; }
26302	cat >conftest.$ac_ext <<_ACEOF
26303/* confdefs.h.  */
26304_ACEOF
26305cat confdefs.h >>conftest.$ac_ext
26306cat >>conftest.$ac_ext <<_ACEOF
26307/* end confdefs.h.  */
26308 #include <sys/socket.h>
26309int
26310main ()
26311{
26312 u_int8_t a; u_int16_t b; u_int32_t c; a = b = c = 1;
26313  ;
26314  return 0;
26315}
26316_ACEOF
26317rm -f conftest.$ac_objext
26318if { (ac_try="$ac_compile"
26319case "(($ac_try" in
26320  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26321  *) ac_try_echo=$ac_try;;
26322esac
26323eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26324  (eval "$ac_compile") 2>conftest.er1
26325  ac_status=$?
26326  grep -v '^ *+' conftest.er1 >conftest.err
26327  rm -f conftest.er1
26328  cat conftest.err >&5
26329  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26330  (exit $ac_status); } && {
26331	 test -z "$ac_c_werror_flag" ||
26332	 test ! -s conftest.err
26333       } && test -s conftest.$ac_objext; then
26334
26335			cat >>confdefs.h <<\_ACEOF
26336#define HAVE_U_INTXX_T 1
26337_ACEOF
26338
26339			{ echo "$as_me:$LINENO: result: yes" >&5
26340echo "${ECHO_T}yes" >&6; }
26341
26342else
26343  echo "$as_me: failed program was:" >&5
26344sed 's/^/| /' conftest.$ac_ext >&5
26345
26346	 { echo "$as_me:$LINENO: result: no" >&5
26347echo "${ECHO_T}no" >&6; }
26348
26349fi
26350
26351rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26352fi
26353
26354{ echo "$as_me:$LINENO: checking for u_int64_t types" >&5
26355echo $ECHO_N "checking for u_int64_t types... $ECHO_C" >&6; }
26356if test "${ac_cv_have_u_int64_t+set}" = set; then
26357  echo $ECHO_N "(cached) $ECHO_C" >&6
26358else
26359
26360	cat >conftest.$ac_ext <<_ACEOF
26361/* confdefs.h.  */
26362_ACEOF
26363cat confdefs.h >>conftest.$ac_ext
26364cat >>conftest.$ac_ext <<_ACEOF
26365/* end confdefs.h.  */
26366 #include <sys/types.h>
26367int
26368main ()
26369{
26370 u_int64_t a; a = 1;
26371  ;
26372  return 0;
26373}
26374_ACEOF
26375rm -f conftest.$ac_objext
26376if { (ac_try="$ac_compile"
26377case "(($ac_try" in
26378  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26379  *) ac_try_echo=$ac_try;;
26380esac
26381eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26382  (eval "$ac_compile") 2>conftest.er1
26383  ac_status=$?
26384  grep -v '^ *+' conftest.er1 >conftest.err
26385  rm -f conftest.er1
26386  cat conftest.err >&5
26387  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26388  (exit $ac_status); } && {
26389	 test -z "$ac_c_werror_flag" ||
26390	 test ! -s conftest.err
26391       } && test -s conftest.$ac_objext; then
26392   ac_cv_have_u_int64_t="yes"
26393else
26394  echo "$as_me: failed program was:" >&5
26395sed 's/^/| /' conftest.$ac_ext >&5
26396
26397	 ac_cv_have_u_int64_t="no"
26398
26399fi
26400
26401rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26402
26403fi
26404{ echo "$as_me:$LINENO: result: $ac_cv_have_u_int64_t" >&5
26405echo "${ECHO_T}$ac_cv_have_u_int64_t" >&6; }
26406if test "x$ac_cv_have_u_int64_t" = "xyes" ; then
26407
26408cat >>confdefs.h <<\_ACEOF
26409#define HAVE_U_INT64_T 1
26410_ACEOF
26411
26412	have_u_int64_t=1
26413fi
26414
26415if (test -z "$have_u_int64_t" && \
26416	   test "x$ac_cv_header_sys_bitypes_h" = "xyes")
26417then
26418    { echo "$as_me:$LINENO: checking for u_int64_t type in sys/bitypes.h" >&5
26419echo $ECHO_N "checking for u_int64_t type in sys/bitypes.h... $ECHO_C" >&6; }
26420	cat >conftest.$ac_ext <<_ACEOF
26421/* confdefs.h.  */
26422_ACEOF
26423cat confdefs.h >>conftest.$ac_ext
26424cat >>conftest.$ac_ext <<_ACEOF
26425/* end confdefs.h.  */
26426 #include <sys/bitypes.h>
26427int
26428main ()
26429{
26430 u_int64_t a; a = 1
26431  ;
26432  return 0;
26433}
26434_ACEOF
26435rm -f conftest.$ac_objext
26436if { (ac_try="$ac_compile"
26437case "(($ac_try" in
26438  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26439  *) ac_try_echo=$ac_try;;
26440esac
26441eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26442  (eval "$ac_compile") 2>conftest.er1
26443  ac_status=$?
26444  grep -v '^ *+' conftest.er1 >conftest.err
26445  rm -f conftest.er1
26446  cat conftest.err >&5
26447  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26448  (exit $ac_status); } && {
26449	 test -z "$ac_c_werror_flag" ||
26450	 test ! -s conftest.err
26451       } && test -s conftest.$ac_objext; then
26452
26453			cat >>confdefs.h <<\_ACEOF
26454#define HAVE_U_INT64_T 1
26455_ACEOF
26456
26457			{ echo "$as_me:$LINENO: result: yes" >&5
26458echo "${ECHO_T}yes" >&6; }
26459
26460else
26461  echo "$as_me: failed program was:" >&5
26462sed 's/^/| /' conftest.$ac_ext >&5
26463
26464	 { echo "$as_me:$LINENO: result: no" >&5
26465echo "${ECHO_T}no" >&6; }
26466
26467fi
26468
26469rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26470fi
26471
26472if test -z "$have_u_intxx_t" ; then
26473	{ echo "$as_me:$LINENO: checking for uintXX_t types" >&5
26474echo $ECHO_N "checking for uintXX_t types... $ECHO_C" >&6; }
26475if test "${ac_cv_have_uintxx_t+set}" = set; then
26476  echo $ECHO_N "(cached) $ECHO_C" >&6
26477else
26478
26479		cat >conftest.$ac_ext <<_ACEOF
26480/* confdefs.h.  */
26481_ACEOF
26482cat confdefs.h >>conftest.$ac_ext
26483cat >>conftest.$ac_ext <<_ACEOF
26484/* end confdefs.h.  */
26485
26486#include <sys/types.h>
26487
26488int
26489main ()
26490{
26491
26492	uint8_t a;
26493	uint16_t b;
26494	uint32_t c;
26495	a = b = c = 1;
26496
26497  ;
26498  return 0;
26499}
26500_ACEOF
26501rm -f conftest.$ac_objext
26502if { (ac_try="$ac_compile"
26503case "(($ac_try" in
26504  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26505  *) ac_try_echo=$ac_try;;
26506esac
26507eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26508  (eval "$ac_compile") 2>conftest.er1
26509  ac_status=$?
26510  grep -v '^ *+' conftest.er1 >conftest.err
26511  rm -f conftest.er1
26512  cat conftest.err >&5
26513  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26514  (exit $ac_status); } && {
26515	 test -z "$ac_c_werror_flag" ||
26516	 test ! -s conftest.err
26517       } && test -s conftest.$ac_objext; then
26518   ac_cv_have_uintxx_t="yes"
26519else
26520  echo "$as_me: failed program was:" >&5
26521sed 's/^/| /' conftest.$ac_ext >&5
26522
26523	 ac_cv_have_uintxx_t="no"
26524
26525fi
26526
26527rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26528
26529fi
26530{ echo "$as_me:$LINENO: result: $ac_cv_have_uintxx_t" >&5
26531echo "${ECHO_T}$ac_cv_have_uintxx_t" >&6; }
26532	if test "x$ac_cv_have_uintxx_t" = "xyes" ; then
26533
26534cat >>confdefs.h <<\_ACEOF
26535#define HAVE_UINTXX_T 1
26536_ACEOF
26537
26538	fi
26539fi
26540
26541if (test -z "$have_uintxx_t" && \
26542	   test "x$ac_cv_header_stdint_h" = "xyes")
26543then
26544    { echo "$as_me:$LINENO: checking for uintXX_t types in stdint.h" >&5
26545echo $ECHO_N "checking for uintXX_t types in stdint.h... $ECHO_C" >&6; }
26546	cat >conftest.$ac_ext <<_ACEOF
26547/* confdefs.h.  */
26548_ACEOF
26549cat confdefs.h >>conftest.$ac_ext
26550cat >>conftest.$ac_ext <<_ACEOF
26551/* end confdefs.h.  */
26552 #include <stdint.h>
26553int
26554main ()
26555{
26556 uint8_t a; uint16_t b; uint32_t c; a = b = c = 1;
26557  ;
26558  return 0;
26559}
26560_ACEOF
26561rm -f conftest.$ac_objext
26562if { (ac_try="$ac_compile"
26563case "(($ac_try" in
26564  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26565  *) ac_try_echo=$ac_try;;
26566esac
26567eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26568  (eval "$ac_compile") 2>conftest.er1
26569  ac_status=$?
26570  grep -v '^ *+' conftest.er1 >conftest.err
26571  rm -f conftest.er1
26572  cat conftest.err >&5
26573  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26574  (exit $ac_status); } && {
26575	 test -z "$ac_c_werror_flag" ||
26576	 test ! -s conftest.err
26577       } && test -s conftest.$ac_objext; then
26578
26579			cat >>confdefs.h <<\_ACEOF
26580#define HAVE_UINTXX_T 1
26581_ACEOF
26582
26583			{ echo "$as_me:$LINENO: result: yes" >&5
26584echo "${ECHO_T}yes" >&6; }
26585
26586else
26587  echo "$as_me: failed program was:" >&5
26588sed 's/^/| /' conftest.$ac_ext >&5
26589
26590	 { echo "$as_me:$LINENO: result: no" >&5
26591echo "${ECHO_T}no" >&6; }
26592
26593fi
26594
26595rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26596fi
26597
26598if (test -z "$have_uintxx_t" && \
26599	   test "x$ac_cv_header_inttypes_h" = "xyes")
26600then
26601    { echo "$as_me:$LINENO: checking for uintXX_t types in inttypes.h" >&5
26602echo $ECHO_N "checking for uintXX_t types in inttypes.h... $ECHO_C" >&6; }
26603	cat >conftest.$ac_ext <<_ACEOF
26604/* confdefs.h.  */
26605_ACEOF
26606cat confdefs.h >>conftest.$ac_ext
26607cat >>conftest.$ac_ext <<_ACEOF
26608/* end confdefs.h.  */
26609 #include <inttypes.h>
26610int
26611main ()
26612{
26613 uint8_t a; uint16_t b; uint32_t c; a = b = c = 1;
26614  ;
26615  return 0;
26616}
26617_ACEOF
26618rm -f conftest.$ac_objext
26619if { (ac_try="$ac_compile"
26620case "(($ac_try" in
26621  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26622  *) ac_try_echo=$ac_try;;
26623esac
26624eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26625  (eval "$ac_compile") 2>conftest.er1
26626  ac_status=$?
26627  grep -v '^ *+' conftest.er1 >conftest.err
26628  rm -f conftest.er1
26629  cat conftest.err >&5
26630  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26631  (exit $ac_status); } && {
26632	 test -z "$ac_c_werror_flag" ||
26633	 test ! -s conftest.err
26634       } && test -s conftest.$ac_objext; then
26635
26636			cat >>confdefs.h <<\_ACEOF
26637#define HAVE_UINTXX_T 1
26638_ACEOF
26639
26640			{ echo "$as_me:$LINENO: result: yes" >&5
26641echo "${ECHO_T}yes" >&6; }
26642
26643else
26644  echo "$as_me: failed program was:" >&5
26645sed 's/^/| /' conftest.$ac_ext >&5
26646
26647	 { echo "$as_me:$LINENO: result: no" >&5
26648echo "${ECHO_T}no" >&6; }
26649
26650fi
26651
26652rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26653fi
26654
26655if (test -z "$have_u_intxx_t" || test -z "$have_intxx_t" && \
26656	   test "x$ac_cv_header_sys_bitypes_h" = "xyes")
26657then
26658	{ echo "$as_me:$LINENO: checking for intXX_t and u_intXX_t types in sys/bitypes.h" >&5
26659echo $ECHO_N "checking for intXX_t and u_intXX_t types in sys/bitypes.h... $ECHO_C" >&6; }
26660	cat >conftest.$ac_ext <<_ACEOF
26661/* confdefs.h.  */
26662_ACEOF
26663cat confdefs.h >>conftest.$ac_ext
26664cat >>conftest.$ac_ext <<_ACEOF
26665/* end confdefs.h.  */
26666
26667#include <sys/bitypes.h>
26668
26669int
26670main ()
26671{
26672
26673			int8_t a; int16_t b; int32_t c;
26674			u_int8_t e; u_int16_t f; u_int32_t g;
26675			a = b = c = e = f = g = 1;
26676
26677  ;
26678  return 0;
26679}
26680_ACEOF
26681rm -f conftest.$ac_objext
26682if { (ac_try="$ac_compile"
26683case "(($ac_try" in
26684  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26685  *) ac_try_echo=$ac_try;;
26686esac
26687eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26688  (eval "$ac_compile") 2>conftest.er1
26689  ac_status=$?
26690  grep -v '^ *+' conftest.er1 >conftest.err
26691  rm -f conftest.er1
26692  cat conftest.err >&5
26693  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26694  (exit $ac_status); } && {
26695	 test -z "$ac_c_werror_flag" ||
26696	 test ! -s conftest.err
26697       } && test -s conftest.$ac_objext; then
26698
26699			cat >>confdefs.h <<\_ACEOF
26700#define HAVE_U_INTXX_T 1
26701_ACEOF
26702
26703			cat >>confdefs.h <<\_ACEOF
26704#define HAVE_INTXX_T 1
26705_ACEOF
26706
26707			{ echo "$as_me:$LINENO: result: yes" >&5
26708echo "${ECHO_T}yes" >&6; }
26709
26710else
26711  echo "$as_me: failed program was:" >&5
26712sed 's/^/| /' conftest.$ac_ext >&5
26713
26714	{ echo "$as_me:$LINENO: result: no" >&5
26715echo "${ECHO_T}no" >&6; }
26716
26717fi
26718
26719rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26720fi
26721
26722
26723{ echo "$as_me:$LINENO: checking for u_char" >&5
26724echo $ECHO_N "checking for u_char... $ECHO_C" >&6; }
26725if test "${ac_cv_have_u_char+set}" = set; then
26726  echo $ECHO_N "(cached) $ECHO_C" >&6
26727else
26728
26729	cat >conftest.$ac_ext <<_ACEOF
26730/* confdefs.h.  */
26731_ACEOF
26732cat confdefs.h >>conftest.$ac_ext
26733cat >>conftest.$ac_ext <<_ACEOF
26734/* end confdefs.h.  */
26735 #include <sys/types.h>
26736int
26737main ()
26738{
26739 u_char foo; foo = 125;
26740  ;
26741  return 0;
26742}
26743_ACEOF
26744rm -f conftest.$ac_objext
26745if { (ac_try="$ac_compile"
26746case "(($ac_try" in
26747  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26748  *) ac_try_echo=$ac_try;;
26749esac
26750eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26751  (eval "$ac_compile") 2>conftest.er1
26752  ac_status=$?
26753  grep -v '^ *+' conftest.er1 >conftest.err
26754  rm -f conftest.er1
26755  cat conftest.err >&5
26756  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26757  (exit $ac_status); } && {
26758	 test -z "$ac_c_werror_flag" ||
26759	 test ! -s conftest.err
26760       } && test -s conftest.$ac_objext; then
26761   ac_cv_have_u_char="yes"
26762else
26763  echo "$as_me: failed program was:" >&5
26764sed 's/^/| /' conftest.$ac_ext >&5
26765
26766	 ac_cv_have_u_char="no"
26767
26768fi
26769
26770rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26771
26772fi
26773{ echo "$as_me:$LINENO: result: $ac_cv_have_u_char" >&5
26774echo "${ECHO_T}$ac_cv_have_u_char" >&6; }
26775if test "x$ac_cv_have_u_char" = "xyes" ; then
26776
26777cat >>confdefs.h <<\_ACEOF
26778#define HAVE_U_CHAR 1
26779_ACEOF
26780
26781fi
26782
26783{ echo "$as_me:$LINENO: checking for intmax_t" >&5
26784echo $ECHO_N "checking for intmax_t... $ECHO_C" >&6; }
26785if test "${ac_cv_type_intmax_t+set}" = set; then
26786  echo $ECHO_N "(cached) $ECHO_C" >&6
26787else
26788  cat >conftest.$ac_ext <<_ACEOF
26789/* confdefs.h.  */
26790_ACEOF
26791cat confdefs.h >>conftest.$ac_ext
26792cat >>conftest.$ac_ext <<_ACEOF
26793/* end confdefs.h.  */
26794
26795#include <sys/types.h>
26796#include <stdint.h>
26797
26798
26799typedef intmax_t ac__type_new_;
26800int
26801main ()
26802{
26803if ((ac__type_new_ *) 0)
26804  return 0;
26805if (sizeof (ac__type_new_))
26806  return 0;
26807  ;
26808  return 0;
26809}
26810_ACEOF
26811rm -f conftest.$ac_objext
26812if { (ac_try="$ac_compile"
26813case "(($ac_try" in
26814  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26815  *) ac_try_echo=$ac_try;;
26816esac
26817eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26818  (eval "$ac_compile") 2>conftest.er1
26819  ac_status=$?
26820  grep -v '^ *+' conftest.er1 >conftest.err
26821  rm -f conftest.er1
26822  cat conftest.err >&5
26823  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26824  (exit $ac_status); } && {
26825	 test -z "$ac_c_werror_flag" ||
26826	 test ! -s conftest.err
26827       } && test -s conftest.$ac_objext; then
26828  ac_cv_type_intmax_t=yes
26829else
26830  echo "$as_me: failed program was:" >&5
26831sed 's/^/| /' conftest.$ac_ext >&5
26832
26833	ac_cv_type_intmax_t=no
26834fi
26835
26836rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26837fi
26838{ echo "$as_me:$LINENO: result: $ac_cv_type_intmax_t" >&5
26839echo "${ECHO_T}$ac_cv_type_intmax_t" >&6; }
26840if test $ac_cv_type_intmax_t = yes; then
26841
26842cat >>confdefs.h <<_ACEOF
26843#define HAVE_INTMAX_T 1
26844_ACEOF
26845
26846
26847fi
26848{ echo "$as_me:$LINENO: checking for uintmax_t" >&5
26849echo $ECHO_N "checking for uintmax_t... $ECHO_C" >&6; }
26850if test "${ac_cv_type_uintmax_t+set}" = set; then
26851  echo $ECHO_N "(cached) $ECHO_C" >&6
26852else
26853  cat >conftest.$ac_ext <<_ACEOF
26854/* confdefs.h.  */
26855_ACEOF
26856cat confdefs.h >>conftest.$ac_ext
26857cat >>conftest.$ac_ext <<_ACEOF
26858/* end confdefs.h.  */
26859
26860#include <sys/types.h>
26861#include <stdint.h>
26862
26863
26864typedef uintmax_t ac__type_new_;
26865int
26866main ()
26867{
26868if ((ac__type_new_ *) 0)
26869  return 0;
26870if (sizeof (ac__type_new_))
26871  return 0;
26872  ;
26873  return 0;
26874}
26875_ACEOF
26876rm -f conftest.$ac_objext
26877if { (ac_try="$ac_compile"
26878case "(($ac_try" in
26879  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26880  *) ac_try_echo=$ac_try;;
26881esac
26882eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26883  (eval "$ac_compile") 2>conftest.er1
26884  ac_status=$?
26885  grep -v '^ *+' conftest.er1 >conftest.err
26886  rm -f conftest.er1
26887  cat conftest.err >&5
26888  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26889  (exit $ac_status); } && {
26890	 test -z "$ac_c_werror_flag" ||
26891	 test ! -s conftest.err
26892       } && test -s conftest.$ac_objext; then
26893  ac_cv_type_uintmax_t=yes
26894else
26895  echo "$as_me: failed program was:" >&5
26896sed 's/^/| /' conftest.$ac_ext >&5
26897
26898	ac_cv_type_uintmax_t=no
26899fi
26900
26901rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26902fi
26903{ echo "$as_me:$LINENO: result: $ac_cv_type_uintmax_t" >&5
26904echo "${ECHO_T}$ac_cv_type_uintmax_t" >&6; }
26905if test $ac_cv_type_uintmax_t = yes; then
26906
26907cat >>confdefs.h <<_ACEOF
26908#define HAVE_UINTMAX_T 1
26909_ACEOF
26910
26911
26912fi
26913
26914
26915
26916   { echo "$as_me:$LINENO: checking for socklen_t" >&5
26917echo $ECHO_N "checking for socklen_t... $ECHO_C" >&6; }
26918if test "${ac_cv_type_socklen_t+set}" = set; then
26919  echo $ECHO_N "(cached) $ECHO_C" >&6
26920else
26921  cat >conftest.$ac_ext <<_ACEOF
26922/* confdefs.h.  */
26923_ACEOF
26924cat confdefs.h >>conftest.$ac_ext
26925cat >>conftest.$ac_ext <<_ACEOF
26926/* end confdefs.h.  */
26927#include <sys/types.h>
26928#include <sys/socket.h>
26929
26930typedef socklen_t ac__type_new_;
26931int
26932main ()
26933{
26934if ((ac__type_new_ *) 0)
26935  return 0;
26936if (sizeof (ac__type_new_))
26937  return 0;
26938  ;
26939  return 0;
26940}
26941_ACEOF
26942rm -f conftest.$ac_objext
26943if { (ac_try="$ac_compile"
26944case "(($ac_try" in
26945  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26946  *) ac_try_echo=$ac_try;;
26947esac
26948eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
26949  (eval "$ac_compile") 2>conftest.er1
26950  ac_status=$?
26951  grep -v '^ *+' conftest.er1 >conftest.err
26952  rm -f conftest.er1
26953  cat conftest.err >&5
26954  echo "$as_me:$LINENO: \$? = $ac_status" >&5
26955  (exit $ac_status); } && {
26956	 test -z "$ac_c_werror_flag" ||
26957	 test ! -s conftest.err
26958       } && test -s conftest.$ac_objext; then
26959  ac_cv_type_socklen_t=yes
26960else
26961  echo "$as_me: failed program was:" >&5
26962sed 's/^/| /' conftest.$ac_ext >&5
26963
26964	ac_cv_type_socklen_t=no
26965fi
26966
26967rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26968fi
26969{ echo "$as_me:$LINENO: result: $ac_cv_type_socklen_t" >&5
26970echo "${ECHO_T}$ac_cv_type_socklen_t" >&6; }
26971if test $ac_cv_type_socklen_t = yes; then
26972  :
26973else
26974
26975      { echo "$as_me:$LINENO: checking for socklen_t equivalent" >&5
26976echo $ECHO_N "checking for socklen_t equivalent... $ECHO_C" >&6; }
26977      if test "${curl_cv_socklen_t_equiv+set}" = set; then
26978  echo $ECHO_N "(cached) $ECHO_C" >&6
26979else
26980
26981	 # Systems have either "struct sockaddr *" or
26982	 # "void *" as the second argument to getpeername
26983	 curl_cv_socklen_t_equiv=
26984	 for arg2 in "struct sockaddr" void; do
26985	    for t in int size_t unsigned long "unsigned long"; do
26986	       cat >conftest.$ac_ext <<_ACEOF
26987/* confdefs.h.  */
26988_ACEOF
26989cat confdefs.h >>conftest.$ac_ext
26990cat >>conftest.$ac_ext <<_ACEOF
26991/* end confdefs.h.  */
26992
26993		  #include <sys/types.h>
26994		  #include <sys/socket.h>
26995
26996		  int getpeername (int, $arg2 *, $t *);
26997
26998int
26999main ()
27000{
27001
27002		  $t len;
27003		  getpeername(0,0,&len);
27004
27005  ;
27006  return 0;
27007}
27008_ACEOF
27009rm -f conftest.$ac_objext
27010if { (ac_try="$ac_compile"
27011case "(($ac_try" in
27012  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27013  *) ac_try_echo=$ac_try;;
27014esac
27015eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27016  (eval "$ac_compile") 2>conftest.er1
27017  ac_status=$?
27018  grep -v '^ *+' conftest.er1 >conftest.err
27019  rm -f conftest.er1
27020  cat conftest.err >&5
27021  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27022  (exit $ac_status); } && {
27023	 test -z "$ac_c_werror_flag" ||
27024	 test ! -s conftest.err
27025       } && test -s conftest.$ac_objext; then
27026
27027		  curl_cv_socklen_t_equiv="$t"
27028		  break
27029
27030else
27031  echo "$as_me: failed program was:" >&5
27032sed 's/^/| /' conftest.$ac_ext >&5
27033
27034
27035fi
27036
27037rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27038	    done
27039	 done
27040
27041	 if test "x$curl_cv_socklen_t_equiv" = x; then
27042	    { { echo "$as_me:$LINENO: error: Cannot find a type to use in place of socklen_t" >&5
27043echo "$as_me: error: Cannot find a type to use in place of socklen_t" >&2;}
27044   { (exit 1); exit 1; }; }
27045	 fi
27046
27047fi
27048
27049      { echo "$as_me:$LINENO: result: $curl_cv_socklen_t_equiv" >&5
27050echo "${ECHO_T}$curl_cv_socklen_t_equiv" >&6; }
27051
27052cat >>confdefs.h <<_ACEOF
27053#define socklen_t $curl_cv_socklen_t_equiv
27054_ACEOF
27055
27056fi
27057
27058
27059
27060{ echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
27061echo $ECHO_N "checking for sig_atomic_t... $ECHO_C" >&6; }
27062if test "${ac_cv_type_sig_atomic_t+set}" = set; then
27063  echo $ECHO_N "(cached) $ECHO_C" >&6
27064else
27065  cat >conftest.$ac_ext <<_ACEOF
27066/* confdefs.h.  */
27067_ACEOF
27068cat confdefs.h >>conftest.$ac_ext
27069cat >>conftest.$ac_ext <<_ACEOF
27070/* end confdefs.h.  */
27071#include <signal.h>
27072
27073typedef sig_atomic_t ac__type_new_;
27074int
27075main ()
27076{
27077if ((ac__type_new_ *) 0)
27078  return 0;
27079if (sizeof (ac__type_new_))
27080  return 0;
27081  ;
27082  return 0;
27083}
27084_ACEOF
27085rm -f conftest.$ac_objext
27086if { (ac_try="$ac_compile"
27087case "(($ac_try" in
27088  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27089  *) ac_try_echo=$ac_try;;
27090esac
27091eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27092  (eval "$ac_compile") 2>conftest.er1
27093  ac_status=$?
27094  grep -v '^ *+' conftest.er1 >conftest.err
27095  rm -f conftest.er1
27096  cat conftest.err >&5
27097  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27098  (exit $ac_status); } && {
27099	 test -z "$ac_c_werror_flag" ||
27100	 test ! -s conftest.err
27101       } && test -s conftest.$ac_objext; then
27102  ac_cv_type_sig_atomic_t=yes
27103else
27104  echo "$as_me: failed program was:" >&5
27105sed 's/^/| /' conftest.$ac_ext >&5
27106
27107	ac_cv_type_sig_atomic_t=no
27108fi
27109
27110rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27111fi
27112{ echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
27113echo "${ECHO_T}$ac_cv_type_sig_atomic_t" >&6; }
27114if test $ac_cv_type_sig_atomic_t = yes; then
27115
27116cat >>confdefs.h <<_ACEOF
27117#define HAVE_SIG_ATOMIC_T 1
27118_ACEOF
27119
27120
27121fi
27122
27123{ echo "$as_me:$LINENO: checking for fsblkcnt_t" >&5
27124echo $ECHO_N "checking for fsblkcnt_t... $ECHO_C" >&6; }
27125if test "${ac_cv_type_fsblkcnt_t+set}" = set; then
27126  echo $ECHO_N "(cached) $ECHO_C" >&6
27127else
27128  cat >conftest.$ac_ext <<_ACEOF
27129/* confdefs.h.  */
27130_ACEOF
27131cat confdefs.h >>conftest.$ac_ext
27132cat >>conftest.$ac_ext <<_ACEOF
27133/* end confdefs.h.  */
27134
27135#include <sys/types.h>
27136#ifdef HAVE_SYS_BITYPES_H
27137#include <sys/bitypes.h>
27138#endif
27139#ifdef HAVE_SYS_STATFS_H
27140#include <sys/statfs.h>
27141#endif
27142#ifdef HAVE_SYS_STATVFS_H
27143#include <sys/statvfs.h>
27144#endif
27145
27146
27147typedef fsblkcnt_t ac__type_new_;
27148int
27149main ()
27150{
27151if ((ac__type_new_ *) 0)
27152  return 0;
27153if (sizeof (ac__type_new_))
27154  return 0;
27155  ;
27156  return 0;
27157}
27158_ACEOF
27159rm -f conftest.$ac_objext
27160if { (ac_try="$ac_compile"
27161case "(($ac_try" in
27162  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27163  *) ac_try_echo=$ac_try;;
27164esac
27165eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27166  (eval "$ac_compile") 2>conftest.er1
27167  ac_status=$?
27168  grep -v '^ *+' conftest.er1 >conftest.err
27169  rm -f conftest.er1
27170  cat conftest.err >&5
27171  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27172  (exit $ac_status); } && {
27173	 test -z "$ac_c_werror_flag" ||
27174	 test ! -s conftest.err
27175       } && test -s conftest.$ac_objext; then
27176  ac_cv_type_fsblkcnt_t=yes
27177else
27178  echo "$as_me: failed program was:" >&5
27179sed 's/^/| /' conftest.$ac_ext >&5
27180
27181	ac_cv_type_fsblkcnt_t=no
27182fi
27183
27184rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27185fi
27186{ echo "$as_me:$LINENO: result: $ac_cv_type_fsblkcnt_t" >&5
27187echo "${ECHO_T}$ac_cv_type_fsblkcnt_t" >&6; }
27188if test $ac_cv_type_fsblkcnt_t = yes; then
27189
27190cat >>confdefs.h <<_ACEOF
27191#define HAVE_FSBLKCNT_T 1
27192_ACEOF
27193
27194
27195fi
27196{ echo "$as_me:$LINENO: checking for fsfilcnt_t" >&5
27197echo $ECHO_N "checking for fsfilcnt_t... $ECHO_C" >&6; }
27198if test "${ac_cv_type_fsfilcnt_t+set}" = set; then
27199  echo $ECHO_N "(cached) $ECHO_C" >&6
27200else
27201  cat >conftest.$ac_ext <<_ACEOF
27202/* confdefs.h.  */
27203_ACEOF
27204cat confdefs.h >>conftest.$ac_ext
27205cat >>conftest.$ac_ext <<_ACEOF
27206/* end confdefs.h.  */
27207
27208#include <sys/types.h>
27209#ifdef HAVE_SYS_BITYPES_H
27210#include <sys/bitypes.h>
27211#endif
27212#ifdef HAVE_SYS_STATFS_H
27213#include <sys/statfs.h>
27214#endif
27215#ifdef HAVE_SYS_STATVFS_H
27216#include <sys/statvfs.h>
27217#endif
27218
27219
27220typedef fsfilcnt_t ac__type_new_;
27221int
27222main ()
27223{
27224if ((ac__type_new_ *) 0)
27225  return 0;
27226if (sizeof (ac__type_new_))
27227  return 0;
27228  ;
27229  return 0;
27230}
27231_ACEOF
27232rm -f conftest.$ac_objext
27233if { (ac_try="$ac_compile"
27234case "(($ac_try" in
27235  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27236  *) ac_try_echo=$ac_try;;
27237esac
27238eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27239  (eval "$ac_compile") 2>conftest.er1
27240  ac_status=$?
27241  grep -v '^ *+' conftest.er1 >conftest.err
27242  rm -f conftest.er1
27243  cat conftest.err >&5
27244  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27245  (exit $ac_status); } && {
27246	 test -z "$ac_c_werror_flag" ||
27247	 test ! -s conftest.err
27248       } && test -s conftest.$ac_objext; then
27249  ac_cv_type_fsfilcnt_t=yes
27250else
27251  echo "$as_me: failed program was:" >&5
27252sed 's/^/| /' conftest.$ac_ext >&5
27253
27254	ac_cv_type_fsfilcnt_t=no
27255fi
27256
27257rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27258fi
27259{ echo "$as_me:$LINENO: result: $ac_cv_type_fsfilcnt_t" >&5
27260echo "${ECHO_T}$ac_cv_type_fsfilcnt_t" >&6; }
27261if test $ac_cv_type_fsfilcnt_t = yes; then
27262
27263cat >>confdefs.h <<_ACEOF
27264#define HAVE_FSFILCNT_T 1
27265_ACEOF
27266
27267
27268fi
27269
27270
27271{ echo "$as_me:$LINENO: checking for in_addr_t" >&5
27272echo $ECHO_N "checking for in_addr_t... $ECHO_C" >&6; }
27273if test "${ac_cv_type_in_addr_t+set}" = set; then
27274  echo $ECHO_N "(cached) $ECHO_C" >&6
27275else
27276  cat >conftest.$ac_ext <<_ACEOF
27277/* confdefs.h.  */
27278_ACEOF
27279cat confdefs.h >>conftest.$ac_ext
27280cat >>conftest.$ac_ext <<_ACEOF
27281/* end confdefs.h.  */
27282#include <sys/types.h>
27283#include <netinet/in.h>
27284
27285typedef in_addr_t ac__type_new_;
27286int
27287main ()
27288{
27289if ((ac__type_new_ *) 0)
27290  return 0;
27291if (sizeof (ac__type_new_))
27292  return 0;
27293  ;
27294  return 0;
27295}
27296_ACEOF
27297rm -f conftest.$ac_objext
27298if { (ac_try="$ac_compile"
27299case "(($ac_try" in
27300  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27301  *) ac_try_echo=$ac_try;;
27302esac
27303eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27304  (eval "$ac_compile") 2>conftest.er1
27305  ac_status=$?
27306  grep -v '^ *+' conftest.er1 >conftest.err
27307  rm -f conftest.er1
27308  cat conftest.err >&5
27309  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27310  (exit $ac_status); } && {
27311	 test -z "$ac_c_werror_flag" ||
27312	 test ! -s conftest.err
27313       } && test -s conftest.$ac_objext; then
27314  ac_cv_type_in_addr_t=yes
27315else
27316  echo "$as_me: failed program was:" >&5
27317sed 's/^/| /' conftest.$ac_ext >&5
27318
27319	ac_cv_type_in_addr_t=no
27320fi
27321
27322rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27323fi
27324{ echo "$as_me:$LINENO: result: $ac_cv_type_in_addr_t" >&5
27325echo "${ECHO_T}$ac_cv_type_in_addr_t" >&6; }
27326if test $ac_cv_type_in_addr_t = yes; then
27327
27328cat >>confdefs.h <<_ACEOF
27329#define HAVE_IN_ADDR_T 1
27330_ACEOF
27331
27332
27333fi
27334{ echo "$as_me:$LINENO: checking for in_port_t" >&5
27335echo $ECHO_N "checking for in_port_t... $ECHO_C" >&6; }
27336if test "${ac_cv_type_in_port_t+set}" = set; then
27337  echo $ECHO_N "(cached) $ECHO_C" >&6
27338else
27339  cat >conftest.$ac_ext <<_ACEOF
27340/* confdefs.h.  */
27341_ACEOF
27342cat confdefs.h >>conftest.$ac_ext
27343cat >>conftest.$ac_ext <<_ACEOF
27344/* end confdefs.h.  */
27345#include <sys/types.h>
27346#include <netinet/in.h>
27347
27348typedef in_port_t ac__type_new_;
27349int
27350main ()
27351{
27352if ((ac__type_new_ *) 0)
27353  return 0;
27354if (sizeof (ac__type_new_))
27355  return 0;
27356  ;
27357  return 0;
27358}
27359_ACEOF
27360rm -f conftest.$ac_objext
27361if { (ac_try="$ac_compile"
27362case "(($ac_try" in
27363  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27364  *) ac_try_echo=$ac_try;;
27365esac
27366eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27367  (eval "$ac_compile") 2>conftest.er1
27368  ac_status=$?
27369  grep -v '^ *+' conftest.er1 >conftest.err
27370  rm -f conftest.er1
27371  cat conftest.err >&5
27372  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27373  (exit $ac_status); } && {
27374	 test -z "$ac_c_werror_flag" ||
27375	 test ! -s conftest.err
27376       } && test -s conftest.$ac_objext; then
27377  ac_cv_type_in_port_t=yes
27378else
27379  echo "$as_me: failed program was:" >&5
27380sed 's/^/| /' conftest.$ac_ext >&5
27381
27382	ac_cv_type_in_port_t=no
27383fi
27384
27385rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27386fi
27387{ echo "$as_me:$LINENO: result: $ac_cv_type_in_port_t" >&5
27388echo "${ECHO_T}$ac_cv_type_in_port_t" >&6; }
27389if test $ac_cv_type_in_port_t = yes; then
27390
27391cat >>confdefs.h <<_ACEOF
27392#define HAVE_IN_PORT_T 1
27393_ACEOF
27394
27395
27396fi
27397
27398
27399{ echo "$as_me:$LINENO: checking for size_t" >&5
27400echo $ECHO_N "checking for size_t... $ECHO_C" >&6; }
27401if test "${ac_cv_have_size_t+set}" = set; then
27402  echo $ECHO_N "(cached) $ECHO_C" >&6
27403else
27404
27405	cat >conftest.$ac_ext <<_ACEOF
27406/* confdefs.h.  */
27407_ACEOF
27408cat confdefs.h >>conftest.$ac_ext
27409cat >>conftest.$ac_ext <<_ACEOF
27410/* end confdefs.h.  */
27411 #include <sys/types.h>
27412int
27413main ()
27414{
27415 size_t foo; foo = 1235;
27416  ;
27417  return 0;
27418}
27419_ACEOF
27420rm -f conftest.$ac_objext
27421if { (ac_try="$ac_compile"
27422case "(($ac_try" in
27423  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27424  *) ac_try_echo=$ac_try;;
27425esac
27426eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27427  (eval "$ac_compile") 2>conftest.er1
27428  ac_status=$?
27429  grep -v '^ *+' conftest.er1 >conftest.err
27430  rm -f conftest.er1
27431  cat conftest.err >&5
27432  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27433  (exit $ac_status); } && {
27434	 test -z "$ac_c_werror_flag" ||
27435	 test ! -s conftest.err
27436       } && test -s conftest.$ac_objext; then
27437   ac_cv_have_size_t="yes"
27438else
27439  echo "$as_me: failed program was:" >&5
27440sed 's/^/| /' conftest.$ac_ext >&5
27441
27442	 ac_cv_have_size_t="no"
27443
27444fi
27445
27446rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27447
27448fi
27449{ echo "$as_me:$LINENO: result: $ac_cv_have_size_t" >&5
27450echo "${ECHO_T}$ac_cv_have_size_t" >&6; }
27451if test "x$ac_cv_have_size_t" = "xyes" ; then
27452
27453cat >>confdefs.h <<\_ACEOF
27454#define HAVE_SIZE_T 1
27455_ACEOF
27456
27457fi
27458
27459{ echo "$as_me:$LINENO: checking for ssize_t" >&5
27460echo $ECHO_N "checking for ssize_t... $ECHO_C" >&6; }
27461if test "${ac_cv_have_ssize_t+set}" = set; then
27462  echo $ECHO_N "(cached) $ECHO_C" >&6
27463else
27464
27465	cat >conftest.$ac_ext <<_ACEOF
27466/* confdefs.h.  */
27467_ACEOF
27468cat confdefs.h >>conftest.$ac_ext
27469cat >>conftest.$ac_ext <<_ACEOF
27470/* end confdefs.h.  */
27471 #include <sys/types.h>
27472int
27473main ()
27474{
27475 ssize_t foo; foo = 1235;
27476  ;
27477  return 0;
27478}
27479_ACEOF
27480rm -f conftest.$ac_objext
27481if { (ac_try="$ac_compile"
27482case "(($ac_try" in
27483  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27484  *) ac_try_echo=$ac_try;;
27485esac
27486eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27487  (eval "$ac_compile") 2>conftest.er1
27488  ac_status=$?
27489  grep -v '^ *+' conftest.er1 >conftest.err
27490  rm -f conftest.er1
27491  cat conftest.err >&5
27492  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27493  (exit $ac_status); } && {
27494	 test -z "$ac_c_werror_flag" ||
27495	 test ! -s conftest.err
27496       } && test -s conftest.$ac_objext; then
27497   ac_cv_have_ssize_t="yes"
27498else
27499  echo "$as_me: failed program was:" >&5
27500sed 's/^/| /' conftest.$ac_ext >&5
27501
27502	 ac_cv_have_ssize_t="no"
27503
27504fi
27505
27506rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27507
27508fi
27509{ echo "$as_me:$LINENO: result: $ac_cv_have_ssize_t" >&5
27510echo "${ECHO_T}$ac_cv_have_ssize_t" >&6; }
27511if test "x$ac_cv_have_ssize_t" = "xyes" ; then
27512
27513cat >>confdefs.h <<\_ACEOF
27514#define HAVE_SSIZE_T 1
27515_ACEOF
27516
27517fi
27518
27519{ echo "$as_me:$LINENO: checking for clock_t" >&5
27520echo $ECHO_N "checking for clock_t... $ECHO_C" >&6; }
27521if test "${ac_cv_have_clock_t+set}" = set; then
27522  echo $ECHO_N "(cached) $ECHO_C" >&6
27523else
27524
27525	cat >conftest.$ac_ext <<_ACEOF
27526/* confdefs.h.  */
27527_ACEOF
27528cat confdefs.h >>conftest.$ac_ext
27529cat >>conftest.$ac_ext <<_ACEOF
27530/* end confdefs.h.  */
27531 #include <time.h>
27532int
27533main ()
27534{
27535 clock_t foo; foo = 1235;
27536  ;
27537  return 0;
27538}
27539_ACEOF
27540rm -f conftest.$ac_objext
27541if { (ac_try="$ac_compile"
27542case "(($ac_try" in
27543  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27544  *) ac_try_echo=$ac_try;;
27545esac
27546eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27547  (eval "$ac_compile") 2>conftest.er1
27548  ac_status=$?
27549  grep -v '^ *+' conftest.er1 >conftest.err
27550  rm -f conftest.er1
27551  cat conftest.err >&5
27552  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27553  (exit $ac_status); } && {
27554	 test -z "$ac_c_werror_flag" ||
27555	 test ! -s conftest.err
27556       } && test -s conftest.$ac_objext; then
27557   ac_cv_have_clock_t="yes"
27558else
27559  echo "$as_me: failed program was:" >&5
27560sed 's/^/| /' conftest.$ac_ext >&5
27561
27562	 ac_cv_have_clock_t="no"
27563
27564fi
27565
27566rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27567
27568fi
27569{ echo "$as_me:$LINENO: result: $ac_cv_have_clock_t" >&5
27570echo "${ECHO_T}$ac_cv_have_clock_t" >&6; }
27571if test "x$ac_cv_have_clock_t" = "xyes" ; then
27572
27573cat >>confdefs.h <<\_ACEOF
27574#define HAVE_CLOCK_T 1
27575_ACEOF
27576
27577fi
27578
27579{ echo "$as_me:$LINENO: checking for sa_family_t" >&5
27580echo $ECHO_N "checking for sa_family_t... $ECHO_C" >&6; }
27581if test "${ac_cv_have_sa_family_t+set}" = set; then
27582  echo $ECHO_N "(cached) $ECHO_C" >&6
27583else
27584
27585	cat >conftest.$ac_ext <<_ACEOF
27586/* confdefs.h.  */
27587_ACEOF
27588cat confdefs.h >>conftest.$ac_ext
27589cat >>conftest.$ac_ext <<_ACEOF
27590/* end confdefs.h.  */
27591
27592#include <sys/types.h>
27593#include <sys/socket.h>
27594
27595int
27596main ()
27597{
27598 sa_family_t foo; foo = 1235;
27599  ;
27600  return 0;
27601}
27602_ACEOF
27603rm -f conftest.$ac_objext
27604if { (ac_try="$ac_compile"
27605case "(($ac_try" in
27606  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27607  *) ac_try_echo=$ac_try;;
27608esac
27609eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27610  (eval "$ac_compile") 2>conftest.er1
27611  ac_status=$?
27612  grep -v '^ *+' conftest.er1 >conftest.err
27613  rm -f conftest.er1
27614  cat conftest.err >&5
27615  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27616  (exit $ac_status); } && {
27617	 test -z "$ac_c_werror_flag" ||
27618	 test ! -s conftest.err
27619       } && test -s conftest.$ac_objext; then
27620   ac_cv_have_sa_family_t="yes"
27621else
27622  echo "$as_me: failed program was:" >&5
27623sed 's/^/| /' conftest.$ac_ext >&5
27624
27625	 cat >conftest.$ac_ext <<_ACEOF
27626/* confdefs.h.  */
27627_ACEOF
27628cat confdefs.h >>conftest.$ac_ext
27629cat >>conftest.$ac_ext <<_ACEOF
27630/* end confdefs.h.  */
27631
27632#include <sys/types.h>
27633#include <sys/socket.h>
27634#include <netinet/in.h>
27635
27636int
27637main ()
27638{
27639 sa_family_t foo; foo = 1235;
27640  ;
27641  return 0;
27642}
27643_ACEOF
27644rm -f conftest.$ac_objext
27645if { (ac_try="$ac_compile"
27646case "(($ac_try" in
27647  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27648  *) ac_try_echo=$ac_try;;
27649esac
27650eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27651  (eval "$ac_compile") 2>conftest.er1
27652  ac_status=$?
27653  grep -v '^ *+' conftest.er1 >conftest.err
27654  rm -f conftest.er1
27655  cat conftest.err >&5
27656  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27657  (exit $ac_status); } && {
27658	 test -z "$ac_c_werror_flag" ||
27659	 test ! -s conftest.err
27660       } && test -s conftest.$ac_objext; then
27661   ac_cv_have_sa_family_t="yes"
27662else
27663  echo "$as_me: failed program was:" >&5
27664sed 's/^/| /' conftest.$ac_ext >&5
27665
27666	 ac_cv_have_sa_family_t="no"
27667
27668fi
27669
27670rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27671
27672fi
27673
27674rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27675
27676fi
27677{ echo "$as_me:$LINENO: result: $ac_cv_have_sa_family_t" >&5
27678echo "${ECHO_T}$ac_cv_have_sa_family_t" >&6; }
27679if test "x$ac_cv_have_sa_family_t" = "xyes" ; then
27680
27681cat >>confdefs.h <<\_ACEOF
27682#define HAVE_SA_FAMILY_T 1
27683_ACEOF
27684
27685fi
27686
27687{ echo "$as_me:$LINENO: checking for pid_t" >&5
27688echo $ECHO_N "checking for pid_t... $ECHO_C" >&6; }
27689if test "${ac_cv_have_pid_t+set}" = set; then
27690  echo $ECHO_N "(cached) $ECHO_C" >&6
27691else
27692
27693	cat >conftest.$ac_ext <<_ACEOF
27694/* confdefs.h.  */
27695_ACEOF
27696cat confdefs.h >>conftest.$ac_ext
27697cat >>conftest.$ac_ext <<_ACEOF
27698/* end confdefs.h.  */
27699 #include <sys/types.h>
27700int
27701main ()
27702{
27703 pid_t foo; foo = 1235;
27704  ;
27705  return 0;
27706}
27707_ACEOF
27708rm -f conftest.$ac_objext
27709if { (ac_try="$ac_compile"
27710case "(($ac_try" in
27711  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27712  *) ac_try_echo=$ac_try;;
27713esac
27714eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27715  (eval "$ac_compile") 2>conftest.er1
27716  ac_status=$?
27717  grep -v '^ *+' conftest.er1 >conftest.err
27718  rm -f conftest.er1
27719  cat conftest.err >&5
27720  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27721  (exit $ac_status); } && {
27722	 test -z "$ac_c_werror_flag" ||
27723	 test ! -s conftest.err
27724       } && test -s conftest.$ac_objext; then
27725   ac_cv_have_pid_t="yes"
27726else
27727  echo "$as_me: failed program was:" >&5
27728sed 's/^/| /' conftest.$ac_ext >&5
27729
27730	 ac_cv_have_pid_t="no"
27731
27732fi
27733
27734rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27735
27736fi
27737{ echo "$as_me:$LINENO: result: $ac_cv_have_pid_t" >&5
27738echo "${ECHO_T}$ac_cv_have_pid_t" >&6; }
27739if test "x$ac_cv_have_pid_t" = "xyes" ; then
27740
27741cat >>confdefs.h <<\_ACEOF
27742#define HAVE_PID_T 1
27743_ACEOF
27744
27745fi
27746
27747{ echo "$as_me:$LINENO: checking for mode_t" >&5
27748echo $ECHO_N "checking for mode_t... $ECHO_C" >&6; }
27749if test "${ac_cv_have_mode_t+set}" = set; then
27750  echo $ECHO_N "(cached) $ECHO_C" >&6
27751else
27752
27753	cat >conftest.$ac_ext <<_ACEOF
27754/* confdefs.h.  */
27755_ACEOF
27756cat confdefs.h >>conftest.$ac_ext
27757cat >>conftest.$ac_ext <<_ACEOF
27758/* end confdefs.h.  */
27759 #include <sys/types.h>
27760int
27761main ()
27762{
27763 mode_t foo; foo = 1235;
27764  ;
27765  return 0;
27766}
27767_ACEOF
27768rm -f conftest.$ac_objext
27769if { (ac_try="$ac_compile"
27770case "(($ac_try" in
27771  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27772  *) ac_try_echo=$ac_try;;
27773esac
27774eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27775  (eval "$ac_compile") 2>conftest.er1
27776  ac_status=$?
27777  grep -v '^ *+' conftest.er1 >conftest.err
27778  rm -f conftest.er1
27779  cat conftest.err >&5
27780  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27781  (exit $ac_status); } && {
27782	 test -z "$ac_c_werror_flag" ||
27783	 test ! -s conftest.err
27784       } && test -s conftest.$ac_objext; then
27785   ac_cv_have_mode_t="yes"
27786else
27787  echo "$as_me: failed program was:" >&5
27788sed 's/^/| /' conftest.$ac_ext >&5
27789
27790	 ac_cv_have_mode_t="no"
27791
27792fi
27793
27794rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27795
27796fi
27797{ echo "$as_me:$LINENO: result: $ac_cv_have_mode_t" >&5
27798echo "${ECHO_T}$ac_cv_have_mode_t" >&6; }
27799if test "x$ac_cv_have_mode_t" = "xyes" ; then
27800
27801cat >>confdefs.h <<\_ACEOF
27802#define HAVE_MODE_T 1
27803_ACEOF
27804
27805fi
27806
27807
27808{ echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
27809echo $ECHO_N "checking for struct sockaddr_storage... $ECHO_C" >&6; }
27810if test "${ac_cv_have_struct_sockaddr_storage+set}" = set; then
27811  echo $ECHO_N "(cached) $ECHO_C" >&6
27812else
27813
27814	cat >conftest.$ac_ext <<_ACEOF
27815/* confdefs.h.  */
27816_ACEOF
27817cat confdefs.h >>conftest.$ac_ext
27818cat >>conftest.$ac_ext <<_ACEOF
27819/* end confdefs.h.  */
27820
27821#include <sys/types.h>
27822#include <sys/socket.h>
27823
27824int
27825main ()
27826{
27827 struct sockaddr_storage s;
27828  ;
27829  return 0;
27830}
27831_ACEOF
27832rm -f conftest.$ac_objext
27833if { (ac_try="$ac_compile"
27834case "(($ac_try" in
27835  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27836  *) ac_try_echo=$ac_try;;
27837esac
27838eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27839  (eval "$ac_compile") 2>conftest.er1
27840  ac_status=$?
27841  grep -v '^ *+' conftest.er1 >conftest.err
27842  rm -f conftest.er1
27843  cat conftest.err >&5
27844  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27845  (exit $ac_status); } && {
27846	 test -z "$ac_c_werror_flag" ||
27847	 test ! -s conftest.err
27848       } && test -s conftest.$ac_objext; then
27849   ac_cv_have_struct_sockaddr_storage="yes"
27850else
27851  echo "$as_me: failed program was:" >&5
27852sed 's/^/| /' conftest.$ac_ext >&5
27853
27854	 ac_cv_have_struct_sockaddr_storage="no"
27855
27856fi
27857
27858rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27859
27860fi
27861{ echo "$as_me:$LINENO: result: $ac_cv_have_struct_sockaddr_storage" >&5
27862echo "${ECHO_T}$ac_cv_have_struct_sockaddr_storage" >&6; }
27863if test "x$ac_cv_have_struct_sockaddr_storage" = "xyes" ; then
27864
27865cat >>confdefs.h <<\_ACEOF
27866#define HAVE_STRUCT_SOCKADDR_STORAGE 1
27867_ACEOF
27868
27869fi
27870
27871{ echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
27872echo $ECHO_N "checking for struct sockaddr_in6... $ECHO_C" >&6; }
27873if test "${ac_cv_have_struct_sockaddr_in6+set}" = set; then
27874  echo $ECHO_N "(cached) $ECHO_C" >&6
27875else
27876
27877	cat >conftest.$ac_ext <<_ACEOF
27878/* confdefs.h.  */
27879_ACEOF
27880cat confdefs.h >>conftest.$ac_ext
27881cat >>conftest.$ac_ext <<_ACEOF
27882/* end confdefs.h.  */
27883
27884#include <sys/types.h>
27885#include <netinet/in.h>
27886
27887int
27888main ()
27889{
27890 struct sockaddr_in6 s; s.sin6_family = 0;
27891  ;
27892  return 0;
27893}
27894_ACEOF
27895rm -f conftest.$ac_objext
27896if { (ac_try="$ac_compile"
27897case "(($ac_try" in
27898  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27899  *) ac_try_echo=$ac_try;;
27900esac
27901eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27902  (eval "$ac_compile") 2>conftest.er1
27903  ac_status=$?
27904  grep -v '^ *+' conftest.er1 >conftest.err
27905  rm -f conftest.er1
27906  cat conftest.err >&5
27907  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27908  (exit $ac_status); } && {
27909	 test -z "$ac_c_werror_flag" ||
27910	 test ! -s conftest.err
27911       } && test -s conftest.$ac_objext; then
27912   ac_cv_have_struct_sockaddr_in6="yes"
27913else
27914  echo "$as_me: failed program was:" >&5
27915sed 's/^/| /' conftest.$ac_ext >&5
27916
27917	 ac_cv_have_struct_sockaddr_in6="no"
27918
27919fi
27920
27921rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27922
27923fi
27924{ echo "$as_me:$LINENO: result: $ac_cv_have_struct_sockaddr_in6" >&5
27925echo "${ECHO_T}$ac_cv_have_struct_sockaddr_in6" >&6; }
27926if test "x$ac_cv_have_struct_sockaddr_in6" = "xyes" ; then
27927
27928cat >>confdefs.h <<\_ACEOF
27929#define HAVE_STRUCT_SOCKADDR_IN6 1
27930_ACEOF
27931
27932fi
27933
27934{ echo "$as_me:$LINENO: checking for struct in6_addr" >&5
27935echo $ECHO_N "checking for struct in6_addr... $ECHO_C" >&6; }
27936if test "${ac_cv_have_struct_in6_addr+set}" = set; then
27937  echo $ECHO_N "(cached) $ECHO_C" >&6
27938else
27939
27940	cat >conftest.$ac_ext <<_ACEOF
27941/* confdefs.h.  */
27942_ACEOF
27943cat confdefs.h >>conftest.$ac_ext
27944cat >>conftest.$ac_ext <<_ACEOF
27945/* end confdefs.h.  */
27946
27947#include <sys/types.h>
27948#include <netinet/in.h>
27949
27950int
27951main ()
27952{
27953 struct in6_addr s; s.s6_addr[0] = 0;
27954  ;
27955  return 0;
27956}
27957_ACEOF
27958rm -f conftest.$ac_objext
27959if { (ac_try="$ac_compile"
27960case "(($ac_try" in
27961  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27962  *) ac_try_echo=$ac_try;;
27963esac
27964eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
27965  (eval "$ac_compile") 2>conftest.er1
27966  ac_status=$?
27967  grep -v '^ *+' conftest.er1 >conftest.err
27968  rm -f conftest.er1
27969  cat conftest.err >&5
27970  echo "$as_me:$LINENO: \$? = $ac_status" >&5
27971  (exit $ac_status); } && {
27972	 test -z "$ac_c_werror_flag" ||
27973	 test ! -s conftest.err
27974       } && test -s conftest.$ac_objext; then
27975   ac_cv_have_struct_in6_addr="yes"
27976else
27977  echo "$as_me: failed program was:" >&5
27978sed 's/^/| /' conftest.$ac_ext >&5
27979
27980	 ac_cv_have_struct_in6_addr="no"
27981
27982fi
27983
27984rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27985
27986fi
27987{ echo "$as_me:$LINENO: result: $ac_cv_have_struct_in6_addr" >&5
27988echo "${ECHO_T}$ac_cv_have_struct_in6_addr" >&6; }
27989if test "x$ac_cv_have_struct_in6_addr" = "xyes" ; then
27990
27991cat >>confdefs.h <<\_ACEOF
27992#define HAVE_STRUCT_IN6_ADDR 1
27993_ACEOF
27994
27995
27996	{ echo "$as_me:$LINENO: checking for struct sockaddr_in6.sin6_scope_id" >&5
27997echo $ECHO_N "checking for struct sockaddr_in6.sin6_scope_id... $ECHO_C" >&6; }
27998if test "${ac_cv_member_struct_sockaddr_in6_sin6_scope_id+set}" = set; then
27999  echo $ECHO_N "(cached) $ECHO_C" >&6
28000else
28001  cat >conftest.$ac_ext <<_ACEOF
28002/* confdefs.h.  */
28003_ACEOF
28004cat confdefs.h >>conftest.$ac_ext
28005cat >>conftest.$ac_ext <<_ACEOF
28006/* end confdefs.h.  */
28007
28008#ifdef HAVE_SYS_TYPES_H
28009#include <sys/types.h>
28010#endif
28011#include <netinet/in.h>
28012
28013
28014int
28015main ()
28016{
28017static struct sockaddr_in6 ac_aggr;
28018if (ac_aggr.sin6_scope_id)
28019return 0;
28020  ;
28021  return 0;
28022}
28023_ACEOF
28024rm -f conftest.$ac_objext
28025if { (ac_try="$ac_compile"
28026case "(($ac_try" in
28027  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28028  *) ac_try_echo=$ac_try;;
28029esac
28030eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28031  (eval "$ac_compile") 2>conftest.er1
28032  ac_status=$?
28033  grep -v '^ *+' conftest.er1 >conftest.err
28034  rm -f conftest.er1
28035  cat conftest.err >&5
28036  echo "$as_me:$LINENO: \$? = $ac_status" >&5
28037  (exit $ac_status); } && {
28038	 test -z "$ac_c_werror_flag" ||
28039	 test ! -s conftest.err
28040       } && test -s conftest.$ac_objext; then
28041  ac_cv_member_struct_sockaddr_in6_sin6_scope_id=yes
28042else
28043  echo "$as_me: failed program was:" >&5
28044sed 's/^/| /' conftest.$ac_ext >&5
28045
28046	cat >conftest.$ac_ext <<_ACEOF
28047/* confdefs.h.  */
28048_ACEOF
28049cat confdefs.h >>conftest.$ac_ext
28050cat >>conftest.$ac_ext <<_ACEOF
28051/* end confdefs.h.  */
28052
28053#ifdef HAVE_SYS_TYPES_H
28054#include <sys/types.h>
28055#endif
28056#include <netinet/in.h>
28057
28058
28059int
28060main ()
28061{
28062static struct sockaddr_in6 ac_aggr;
28063if (sizeof ac_aggr.sin6_scope_id)
28064return 0;
28065  ;
28066  return 0;
28067}
28068_ACEOF
28069rm -f conftest.$ac_objext
28070if { (ac_try="$ac_compile"
28071case "(($ac_try" in
28072  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28073  *) ac_try_echo=$ac_try;;
28074esac
28075eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28076  (eval "$ac_compile") 2>conftest.er1
28077  ac_status=$?
28078  grep -v '^ *+' conftest.er1 >conftest.err
28079  rm -f conftest.er1
28080  cat conftest.err >&5
28081  echo "$as_me:$LINENO: \$? = $ac_status" >&5
28082  (exit $ac_status); } && {
28083	 test -z "$ac_c_werror_flag" ||
28084	 test ! -s conftest.err
28085       } && test -s conftest.$ac_objext; then
28086  ac_cv_member_struct_sockaddr_in6_sin6_scope_id=yes
28087else
28088  echo "$as_me: failed program was:" >&5
28089sed 's/^/| /' conftest.$ac_ext >&5
28090
28091	ac_cv_member_struct_sockaddr_in6_sin6_scope_id=no
28092fi
28093
28094rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28095fi
28096
28097rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28098fi
28099{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_in6_sin6_scope_id" >&5
28100echo "${ECHO_T}$ac_cv_member_struct_sockaddr_in6_sin6_scope_id" >&6; }
28101if test $ac_cv_member_struct_sockaddr_in6_sin6_scope_id = yes; then
28102
28103cat >>confdefs.h <<_ACEOF
28104#define HAVE_STRUCT_SOCKADDR_IN6_SIN6_SCOPE_ID 1
28105_ACEOF
28106
28107
28108fi
28109
28110fi
28111
28112{ echo "$as_me:$LINENO: checking for struct addrinfo" >&5
28113echo $ECHO_N "checking for struct addrinfo... $ECHO_C" >&6; }
28114if test "${ac_cv_have_struct_addrinfo+set}" = set; then
28115  echo $ECHO_N "(cached) $ECHO_C" >&6
28116else
28117
28118	cat >conftest.$ac_ext <<_ACEOF
28119/* confdefs.h.  */
28120_ACEOF
28121cat confdefs.h >>conftest.$ac_ext
28122cat >>conftest.$ac_ext <<_ACEOF
28123/* end confdefs.h.  */
28124
28125#include <sys/types.h>
28126#include <sys/socket.h>
28127#include <netdb.h>
28128
28129int
28130main ()
28131{
28132 struct addrinfo s; s.ai_flags = AI_PASSIVE;
28133  ;
28134  return 0;
28135}
28136_ACEOF
28137rm -f conftest.$ac_objext
28138if { (ac_try="$ac_compile"
28139case "(($ac_try" in
28140  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28141  *) ac_try_echo=$ac_try;;
28142esac
28143eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28144  (eval "$ac_compile") 2>conftest.er1
28145  ac_status=$?
28146  grep -v '^ *+' conftest.er1 >conftest.err
28147  rm -f conftest.er1
28148  cat conftest.err >&5
28149  echo "$as_me:$LINENO: \$? = $ac_status" >&5
28150  (exit $ac_status); } && {
28151	 test -z "$ac_c_werror_flag" ||
28152	 test ! -s conftest.err
28153       } && test -s conftest.$ac_objext; then
28154   ac_cv_have_struct_addrinfo="yes"
28155else
28156  echo "$as_me: failed program was:" >&5
28157sed 's/^/| /' conftest.$ac_ext >&5
28158
28159	 ac_cv_have_struct_addrinfo="no"
28160
28161fi
28162
28163rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28164
28165fi
28166{ echo "$as_me:$LINENO: result: $ac_cv_have_struct_addrinfo" >&5
28167echo "${ECHO_T}$ac_cv_have_struct_addrinfo" >&6; }
28168if test "x$ac_cv_have_struct_addrinfo" = "xyes" ; then
28169
28170cat >>confdefs.h <<\_ACEOF
28171#define HAVE_STRUCT_ADDRINFO 1
28172_ACEOF
28173
28174fi
28175
28176{ echo "$as_me:$LINENO: checking for struct timeval" >&5
28177echo $ECHO_N "checking for struct timeval... $ECHO_C" >&6; }
28178if test "${ac_cv_have_struct_timeval+set}" = set; then
28179  echo $ECHO_N "(cached) $ECHO_C" >&6
28180else
28181
28182	cat >conftest.$ac_ext <<_ACEOF
28183/* confdefs.h.  */
28184_ACEOF
28185cat confdefs.h >>conftest.$ac_ext
28186cat >>conftest.$ac_ext <<_ACEOF
28187/* end confdefs.h.  */
28188 #include <sys/time.h>
28189int
28190main ()
28191{
28192 struct timeval tv; tv.tv_sec = 1;
28193  ;
28194  return 0;
28195}
28196_ACEOF
28197rm -f conftest.$ac_objext
28198if { (ac_try="$ac_compile"
28199case "(($ac_try" in
28200  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28201  *) ac_try_echo=$ac_try;;
28202esac
28203eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28204  (eval "$ac_compile") 2>conftest.er1
28205  ac_status=$?
28206  grep -v '^ *+' conftest.er1 >conftest.err
28207  rm -f conftest.er1
28208  cat conftest.err >&5
28209  echo "$as_me:$LINENO: \$? = $ac_status" >&5
28210  (exit $ac_status); } && {
28211	 test -z "$ac_c_werror_flag" ||
28212	 test ! -s conftest.err
28213       } && test -s conftest.$ac_objext; then
28214   ac_cv_have_struct_timeval="yes"
28215else
28216  echo "$as_me: failed program was:" >&5
28217sed 's/^/| /' conftest.$ac_ext >&5
28218
28219	 ac_cv_have_struct_timeval="no"
28220
28221fi
28222
28223rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28224
28225fi
28226{ echo "$as_me:$LINENO: result: $ac_cv_have_struct_timeval" >&5
28227echo "${ECHO_T}$ac_cv_have_struct_timeval" >&6; }
28228if test "x$ac_cv_have_struct_timeval" = "xyes" ; then
28229
28230cat >>confdefs.h <<\_ACEOF
28231#define HAVE_STRUCT_TIMEVAL 1
28232_ACEOF
28233
28234	have_struct_timeval=1
28235fi
28236
28237{ echo "$as_me:$LINENO: checking for struct timespec" >&5
28238echo $ECHO_N "checking for struct timespec... $ECHO_C" >&6; }
28239if test "${ac_cv_type_struct_timespec+set}" = set; then
28240  echo $ECHO_N "(cached) $ECHO_C" >&6
28241else
28242  cat >conftest.$ac_ext <<_ACEOF
28243/* confdefs.h.  */
28244_ACEOF
28245cat confdefs.h >>conftest.$ac_ext
28246cat >>conftest.$ac_ext <<_ACEOF
28247/* end confdefs.h.  */
28248$ac_includes_default
28249typedef struct timespec ac__type_new_;
28250int
28251main ()
28252{
28253if ((ac__type_new_ *) 0)
28254  return 0;
28255if (sizeof (ac__type_new_))
28256  return 0;
28257  ;
28258  return 0;
28259}
28260_ACEOF
28261rm -f conftest.$ac_objext
28262if { (ac_try="$ac_compile"
28263case "(($ac_try" in
28264  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28265  *) ac_try_echo=$ac_try;;
28266esac
28267eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28268  (eval "$ac_compile") 2>conftest.er1
28269  ac_status=$?
28270  grep -v '^ *+' conftest.er1 >conftest.err
28271  rm -f conftest.er1
28272  cat conftest.err >&5
28273  echo "$as_me:$LINENO: \$? = $ac_status" >&5
28274  (exit $ac_status); } && {
28275	 test -z "$ac_c_werror_flag" ||
28276	 test ! -s conftest.err
28277       } && test -s conftest.$ac_objext; then
28278  ac_cv_type_struct_timespec=yes
28279else
28280  echo "$as_me: failed program was:" >&5
28281sed 's/^/| /' conftest.$ac_ext >&5
28282
28283	ac_cv_type_struct_timespec=no
28284fi
28285
28286rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28287fi
28288{ echo "$as_me:$LINENO: result: $ac_cv_type_struct_timespec" >&5
28289echo "${ECHO_T}$ac_cv_type_struct_timespec" >&6; }
28290if test $ac_cv_type_struct_timespec = yes; then
28291
28292cat >>confdefs.h <<_ACEOF
28293#define HAVE_STRUCT_TIMESPEC 1
28294_ACEOF
28295
28296
28297fi
28298
28299
28300# We need int64_t or else certian parts of the compile will fail.
28301if test "x$ac_cv_have_int64_t" = "xno" && \
28302	test "x$ac_cv_sizeof_long_int" != "x8" && \
28303	test "x$ac_cv_sizeof_long_long_int" = "x0" ; then
28304	echo "OpenSSH requires int64_t support.  Contact your vendor or install"
28305	echo "an alternative compiler (I.E., GCC) before continuing."
28306	echo ""
28307	exit 1;
28308else
28309	if test "$cross_compiling" = yes; then
28310  { echo "$as_me:$LINENO: WARNING: cross compiling: Assuming working snprintf()" >&5
28311echo "$as_me: WARNING: cross compiling: Assuming working snprintf()" >&2;}
28312
28313else
28314  cat >conftest.$ac_ext <<_ACEOF
28315/* confdefs.h.  */
28316_ACEOF
28317cat confdefs.h >>conftest.$ac_ext
28318cat >>conftest.$ac_ext <<_ACEOF
28319/* end confdefs.h.  */
28320
28321#include <stdio.h>
28322#include <string.h>
28323#ifdef HAVE_SNPRINTF
28324main()
28325{
28326	char buf[50];
28327	char expected_out[50];
28328	int mazsize = 50 ;
28329#if (SIZEOF_LONG_INT == 8)
28330	long int num = 0x7fffffffffffffff;
28331#else
28332	long long num = 0x7fffffffffffffffll;
28333#endif
28334	strcpy(expected_out, "9223372036854775807");
28335	snprintf(buf, mazsize, "%lld", num);
28336	if(strcmp(buf, expected_out) != 0)
28337		exit(1);
28338	exit(0);
28339}
28340#else
28341main() { exit(0); }
28342#endif
28343
28344_ACEOF
28345rm -f conftest$ac_exeext
28346if { (ac_try="$ac_link"
28347case "(($ac_try" in
28348  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28349  *) ac_try_echo=$ac_try;;
28350esac
28351eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28352  (eval "$ac_link") 2>&5
28353  ac_status=$?
28354  echo "$as_me:$LINENO: \$? = $ac_status" >&5
28355  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28356  { (case "(($ac_try" in
28357  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28358  *) ac_try_echo=$ac_try;;
28359esac
28360eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
28361  (eval "$ac_try") 2>&5
28362  ac_status=$?
28363  echo "$as_me:$LINENO: \$? = $ac_status" >&5
28364  (exit $ac_status); }; }; then
28365   true
28366else
28367  echo "$as_me: program exited with status $ac_status" >&5
28368echo "$as_me: failed program was:" >&5
28369sed 's/^/| /' conftest.$ac_ext >&5
28370
28371( exit $ac_status )
28372 cat >>confdefs.h <<\_ACEOF
28373#define BROKEN_SNPRINTF 1
28374_ACEOF
28375
28376fi
28377rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
28378fi
28379
28380
28381fi
28382
28383
28384# look for field 'ut_host' in header 'utmp.h'
28385		ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
28386		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_host
28387	{ echo "$as_me:$LINENO: checking for ut_host field in utmp.h" >&5
28388echo $ECHO_N "checking for ut_host field in utmp.h... $ECHO_C" >&6; }
28389	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
28390  echo $ECHO_N "(cached) $ECHO_C" >&6
28391else
28392
28393		cat >conftest.$ac_ext <<_ACEOF
28394/* confdefs.h.  */
28395_ACEOF
28396cat confdefs.h >>conftest.$ac_ext
28397cat >>conftest.$ac_ext <<_ACEOF
28398/* end confdefs.h.  */
28399#include <utmp.h>
28400
28401_ACEOF
28402if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28403  $EGREP "ut_host" >/dev/null 2>&1; then
28404   			eval "$ossh_varname=yes"
28405else
28406   			eval "$ossh_varname=no"
28407fi
28408rm -f conftest*
28409
28410fi
28411
28412	ossh_result=`eval 'echo $'"$ossh_varname"`
28413	if test -n "`echo $ossh_varname`"; then
28414		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
28415echo "${ECHO_T}$ossh_result" >&6; }
28416		if test "x$ossh_result" = "xyes"; then
28417
28418cat >>confdefs.h <<\_ACEOF
28419#define HAVE_HOST_IN_UTMP 1
28420_ACEOF
28421
28422		fi
28423	else
28424		{ echo "$as_me:$LINENO: result: no" >&5
28425echo "${ECHO_T}no" >&6; }
28426	fi
28427
28428
28429# look for field 'ut_host' in header 'utmpx.h'
28430		ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
28431		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_host
28432	{ echo "$as_me:$LINENO: checking for ut_host field in utmpx.h" >&5
28433echo $ECHO_N "checking for ut_host field in utmpx.h... $ECHO_C" >&6; }
28434	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
28435  echo $ECHO_N "(cached) $ECHO_C" >&6
28436else
28437
28438		cat >conftest.$ac_ext <<_ACEOF
28439/* confdefs.h.  */
28440_ACEOF
28441cat confdefs.h >>conftest.$ac_ext
28442cat >>conftest.$ac_ext <<_ACEOF
28443/* end confdefs.h.  */
28444#include <utmpx.h>
28445
28446_ACEOF
28447if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28448  $EGREP "ut_host" >/dev/null 2>&1; then
28449   			eval "$ossh_varname=yes"
28450else
28451   			eval "$ossh_varname=no"
28452fi
28453rm -f conftest*
28454
28455fi
28456
28457	ossh_result=`eval 'echo $'"$ossh_varname"`
28458	if test -n "`echo $ossh_varname`"; then
28459		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
28460echo "${ECHO_T}$ossh_result" >&6; }
28461		if test "x$ossh_result" = "xyes"; then
28462
28463cat >>confdefs.h <<\_ACEOF
28464#define HAVE_HOST_IN_UTMPX 1
28465_ACEOF
28466
28467		fi
28468	else
28469		{ echo "$as_me:$LINENO: result: no" >&5
28470echo "${ECHO_T}no" >&6; }
28471	fi
28472
28473
28474# look for field 'syslen' in header 'utmpx.h'
28475		ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
28476		ossh_varname="ossh_cv_$ossh_safe""_has_"syslen
28477	{ echo "$as_me:$LINENO: checking for syslen field in utmpx.h" >&5
28478echo $ECHO_N "checking for syslen field in utmpx.h... $ECHO_C" >&6; }
28479	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
28480  echo $ECHO_N "(cached) $ECHO_C" >&6
28481else
28482
28483		cat >conftest.$ac_ext <<_ACEOF
28484/* confdefs.h.  */
28485_ACEOF
28486cat confdefs.h >>conftest.$ac_ext
28487cat >>conftest.$ac_ext <<_ACEOF
28488/* end confdefs.h.  */
28489#include <utmpx.h>
28490
28491_ACEOF
28492if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28493  $EGREP "syslen" >/dev/null 2>&1; then
28494   			eval "$ossh_varname=yes"
28495else
28496   			eval "$ossh_varname=no"
28497fi
28498rm -f conftest*
28499
28500fi
28501
28502	ossh_result=`eval 'echo $'"$ossh_varname"`
28503	if test -n "`echo $ossh_varname`"; then
28504		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
28505echo "${ECHO_T}$ossh_result" >&6; }
28506		if test "x$ossh_result" = "xyes"; then
28507
28508cat >>confdefs.h <<\_ACEOF
28509#define HAVE_SYSLEN_IN_UTMPX 1
28510_ACEOF
28511
28512		fi
28513	else
28514		{ echo "$as_me:$LINENO: result: no" >&5
28515echo "${ECHO_T}no" >&6; }
28516	fi
28517
28518
28519# look for field 'ut_pid' in header 'utmp.h'
28520		ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
28521		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_pid
28522	{ echo "$as_me:$LINENO: checking for ut_pid field in utmp.h" >&5
28523echo $ECHO_N "checking for ut_pid field in utmp.h... $ECHO_C" >&6; }
28524	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
28525  echo $ECHO_N "(cached) $ECHO_C" >&6
28526else
28527
28528		cat >conftest.$ac_ext <<_ACEOF
28529/* confdefs.h.  */
28530_ACEOF
28531cat confdefs.h >>conftest.$ac_ext
28532cat >>conftest.$ac_ext <<_ACEOF
28533/* end confdefs.h.  */
28534#include <utmp.h>
28535
28536_ACEOF
28537if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28538  $EGREP "ut_pid" >/dev/null 2>&1; then
28539   			eval "$ossh_varname=yes"
28540else
28541   			eval "$ossh_varname=no"
28542fi
28543rm -f conftest*
28544
28545fi
28546
28547	ossh_result=`eval 'echo $'"$ossh_varname"`
28548	if test -n "`echo $ossh_varname`"; then
28549		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
28550echo "${ECHO_T}$ossh_result" >&6; }
28551		if test "x$ossh_result" = "xyes"; then
28552
28553cat >>confdefs.h <<\_ACEOF
28554#define HAVE_PID_IN_UTMP 1
28555_ACEOF
28556
28557		fi
28558	else
28559		{ echo "$as_me:$LINENO: result: no" >&5
28560echo "${ECHO_T}no" >&6; }
28561	fi
28562
28563
28564# look for field 'ut_type' in header 'utmp.h'
28565		ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
28566		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_type
28567	{ echo "$as_me:$LINENO: checking for ut_type field in utmp.h" >&5
28568echo $ECHO_N "checking for ut_type field in utmp.h... $ECHO_C" >&6; }
28569	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
28570  echo $ECHO_N "(cached) $ECHO_C" >&6
28571else
28572
28573		cat >conftest.$ac_ext <<_ACEOF
28574/* confdefs.h.  */
28575_ACEOF
28576cat confdefs.h >>conftest.$ac_ext
28577cat >>conftest.$ac_ext <<_ACEOF
28578/* end confdefs.h.  */
28579#include <utmp.h>
28580
28581_ACEOF
28582if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28583  $EGREP "ut_type" >/dev/null 2>&1; then
28584   			eval "$ossh_varname=yes"
28585else
28586   			eval "$ossh_varname=no"
28587fi
28588rm -f conftest*
28589
28590fi
28591
28592	ossh_result=`eval 'echo $'"$ossh_varname"`
28593	if test -n "`echo $ossh_varname`"; then
28594		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
28595echo "${ECHO_T}$ossh_result" >&6; }
28596		if test "x$ossh_result" = "xyes"; then
28597
28598cat >>confdefs.h <<\_ACEOF
28599#define HAVE_TYPE_IN_UTMP 1
28600_ACEOF
28601
28602		fi
28603	else
28604		{ echo "$as_me:$LINENO: result: no" >&5
28605echo "${ECHO_T}no" >&6; }
28606	fi
28607
28608
28609# look for field 'ut_type' in header 'utmpx.h'
28610		ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
28611		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_type
28612	{ echo "$as_me:$LINENO: checking for ut_type field in utmpx.h" >&5
28613echo $ECHO_N "checking for ut_type field in utmpx.h... $ECHO_C" >&6; }
28614	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
28615  echo $ECHO_N "(cached) $ECHO_C" >&6
28616else
28617
28618		cat >conftest.$ac_ext <<_ACEOF
28619/* confdefs.h.  */
28620_ACEOF
28621cat confdefs.h >>conftest.$ac_ext
28622cat >>conftest.$ac_ext <<_ACEOF
28623/* end confdefs.h.  */
28624#include <utmpx.h>
28625
28626_ACEOF
28627if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28628  $EGREP "ut_type" >/dev/null 2>&1; then
28629   			eval "$ossh_varname=yes"
28630else
28631   			eval "$ossh_varname=no"
28632fi
28633rm -f conftest*
28634
28635fi
28636
28637	ossh_result=`eval 'echo $'"$ossh_varname"`
28638	if test -n "`echo $ossh_varname`"; then
28639		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
28640echo "${ECHO_T}$ossh_result" >&6; }
28641		if test "x$ossh_result" = "xyes"; then
28642
28643cat >>confdefs.h <<\_ACEOF
28644#define HAVE_TYPE_IN_UTMPX 1
28645_ACEOF
28646
28647		fi
28648	else
28649		{ echo "$as_me:$LINENO: result: no" >&5
28650echo "${ECHO_T}no" >&6; }
28651	fi
28652
28653
28654# look for field 'ut_tv' in header 'utmp.h'
28655		ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
28656		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_tv
28657	{ echo "$as_me:$LINENO: checking for ut_tv field in utmp.h" >&5
28658echo $ECHO_N "checking for ut_tv field in utmp.h... $ECHO_C" >&6; }
28659	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
28660  echo $ECHO_N "(cached) $ECHO_C" >&6
28661else
28662
28663		cat >conftest.$ac_ext <<_ACEOF
28664/* confdefs.h.  */
28665_ACEOF
28666cat confdefs.h >>conftest.$ac_ext
28667cat >>conftest.$ac_ext <<_ACEOF
28668/* end confdefs.h.  */
28669#include <utmp.h>
28670
28671_ACEOF
28672if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28673  $EGREP "ut_tv" >/dev/null 2>&1; then
28674   			eval "$ossh_varname=yes"
28675else
28676   			eval "$ossh_varname=no"
28677fi
28678rm -f conftest*
28679
28680fi
28681
28682	ossh_result=`eval 'echo $'"$ossh_varname"`
28683	if test -n "`echo $ossh_varname`"; then
28684		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
28685echo "${ECHO_T}$ossh_result" >&6; }
28686		if test "x$ossh_result" = "xyes"; then
28687
28688cat >>confdefs.h <<\_ACEOF
28689#define HAVE_TV_IN_UTMP 1
28690_ACEOF
28691
28692		fi
28693	else
28694		{ echo "$as_me:$LINENO: result: no" >&5
28695echo "${ECHO_T}no" >&6; }
28696	fi
28697
28698
28699# look for field 'ut_id' in header 'utmp.h'
28700		ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
28701		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_id
28702	{ echo "$as_me:$LINENO: checking for ut_id field in utmp.h" >&5
28703echo $ECHO_N "checking for ut_id field in utmp.h... $ECHO_C" >&6; }
28704	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
28705  echo $ECHO_N "(cached) $ECHO_C" >&6
28706else
28707
28708		cat >conftest.$ac_ext <<_ACEOF
28709/* confdefs.h.  */
28710_ACEOF
28711cat confdefs.h >>conftest.$ac_ext
28712cat >>conftest.$ac_ext <<_ACEOF
28713/* end confdefs.h.  */
28714#include <utmp.h>
28715
28716_ACEOF
28717if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28718  $EGREP "ut_id" >/dev/null 2>&1; then
28719   			eval "$ossh_varname=yes"
28720else
28721   			eval "$ossh_varname=no"
28722fi
28723rm -f conftest*
28724
28725fi
28726
28727	ossh_result=`eval 'echo $'"$ossh_varname"`
28728	if test -n "`echo $ossh_varname`"; then
28729		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
28730echo "${ECHO_T}$ossh_result" >&6; }
28731		if test "x$ossh_result" = "xyes"; then
28732
28733cat >>confdefs.h <<\_ACEOF
28734#define HAVE_ID_IN_UTMP 1
28735_ACEOF
28736
28737		fi
28738	else
28739		{ echo "$as_me:$LINENO: result: no" >&5
28740echo "${ECHO_T}no" >&6; }
28741	fi
28742
28743
28744# look for field 'ut_id' in header 'utmpx.h'
28745		ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
28746		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_id
28747	{ echo "$as_me:$LINENO: checking for ut_id field in utmpx.h" >&5
28748echo $ECHO_N "checking for ut_id field in utmpx.h... $ECHO_C" >&6; }
28749	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
28750  echo $ECHO_N "(cached) $ECHO_C" >&6
28751else
28752
28753		cat >conftest.$ac_ext <<_ACEOF
28754/* confdefs.h.  */
28755_ACEOF
28756cat confdefs.h >>conftest.$ac_ext
28757cat >>conftest.$ac_ext <<_ACEOF
28758/* end confdefs.h.  */
28759#include <utmpx.h>
28760
28761_ACEOF
28762if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28763  $EGREP "ut_id" >/dev/null 2>&1; then
28764   			eval "$ossh_varname=yes"
28765else
28766   			eval "$ossh_varname=no"
28767fi
28768rm -f conftest*
28769
28770fi
28771
28772	ossh_result=`eval 'echo $'"$ossh_varname"`
28773	if test -n "`echo $ossh_varname`"; then
28774		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
28775echo "${ECHO_T}$ossh_result" >&6; }
28776		if test "x$ossh_result" = "xyes"; then
28777
28778cat >>confdefs.h <<\_ACEOF
28779#define HAVE_ID_IN_UTMPX 1
28780_ACEOF
28781
28782		fi
28783	else
28784		{ echo "$as_me:$LINENO: result: no" >&5
28785echo "${ECHO_T}no" >&6; }
28786	fi
28787
28788
28789# look for field 'ut_addr' in header 'utmp.h'
28790		ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
28791		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_addr
28792	{ echo "$as_me:$LINENO: checking for ut_addr field in utmp.h" >&5
28793echo $ECHO_N "checking for ut_addr field in utmp.h... $ECHO_C" >&6; }
28794	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
28795  echo $ECHO_N "(cached) $ECHO_C" >&6
28796else
28797
28798		cat >conftest.$ac_ext <<_ACEOF
28799/* confdefs.h.  */
28800_ACEOF
28801cat confdefs.h >>conftest.$ac_ext
28802cat >>conftest.$ac_ext <<_ACEOF
28803/* end confdefs.h.  */
28804#include <utmp.h>
28805
28806_ACEOF
28807if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28808  $EGREP "ut_addr" >/dev/null 2>&1; then
28809   			eval "$ossh_varname=yes"
28810else
28811   			eval "$ossh_varname=no"
28812fi
28813rm -f conftest*
28814
28815fi
28816
28817	ossh_result=`eval 'echo $'"$ossh_varname"`
28818	if test -n "`echo $ossh_varname`"; then
28819		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
28820echo "${ECHO_T}$ossh_result" >&6; }
28821		if test "x$ossh_result" = "xyes"; then
28822
28823cat >>confdefs.h <<\_ACEOF
28824#define HAVE_ADDR_IN_UTMP 1
28825_ACEOF
28826
28827		fi
28828	else
28829		{ echo "$as_me:$LINENO: result: no" >&5
28830echo "${ECHO_T}no" >&6; }
28831	fi
28832
28833
28834# look for field 'ut_addr' in header 'utmpx.h'
28835		ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
28836		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_addr
28837	{ echo "$as_me:$LINENO: checking for ut_addr field in utmpx.h" >&5
28838echo $ECHO_N "checking for ut_addr field in utmpx.h... $ECHO_C" >&6; }
28839	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
28840  echo $ECHO_N "(cached) $ECHO_C" >&6
28841else
28842
28843		cat >conftest.$ac_ext <<_ACEOF
28844/* confdefs.h.  */
28845_ACEOF
28846cat confdefs.h >>conftest.$ac_ext
28847cat >>conftest.$ac_ext <<_ACEOF
28848/* end confdefs.h.  */
28849#include <utmpx.h>
28850
28851_ACEOF
28852if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28853  $EGREP "ut_addr" >/dev/null 2>&1; then
28854   			eval "$ossh_varname=yes"
28855else
28856   			eval "$ossh_varname=no"
28857fi
28858rm -f conftest*
28859
28860fi
28861
28862	ossh_result=`eval 'echo $'"$ossh_varname"`
28863	if test -n "`echo $ossh_varname`"; then
28864		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
28865echo "${ECHO_T}$ossh_result" >&6; }
28866		if test "x$ossh_result" = "xyes"; then
28867
28868cat >>confdefs.h <<\_ACEOF
28869#define HAVE_ADDR_IN_UTMPX 1
28870_ACEOF
28871
28872		fi
28873	else
28874		{ echo "$as_me:$LINENO: result: no" >&5
28875echo "${ECHO_T}no" >&6; }
28876	fi
28877
28878
28879# look for field 'ut_addr_v6' in header 'utmp.h'
28880		ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
28881		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_addr_v6
28882	{ echo "$as_me:$LINENO: checking for ut_addr_v6 field in utmp.h" >&5
28883echo $ECHO_N "checking for ut_addr_v6 field in utmp.h... $ECHO_C" >&6; }
28884	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
28885  echo $ECHO_N "(cached) $ECHO_C" >&6
28886else
28887
28888		cat >conftest.$ac_ext <<_ACEOF
28889/* confdefs.h.  */
28890_ACEOF
28891cat confdefs.h >>conftest.$ac_ext
28892cat >>conftest.$ac_ext <<_ACEOF
28893/* end confdefs.h.  */
28894#include <utmp.h>
28895
28896_ACEOF
28897if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28898  $EGREP "ut_addr_v6" >/dev/null 2>&1; then
28899   			eval "$ossh_varname=yes"
28900else
28901   			eval "$ossh_varname=no"
28902fi
28903rm -f conftest*
28904
28905fi
28906
28907	ossh_result=`eval 'echo $'"$ossh_varname"`
28908	if test -n "`echo $ossh_varname`"; then
28909		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
28910echo "${ECHO_T}$ossh_result" >&6; }
28911		if test "x$ossh_result" = "xyes"; then
28912
28913cat >>confdefs.h <<\_ACEOF
28914#define HAVE_ADDR_V6_IN_UTMP 1
28915_ACEOF
28916
28917		fi
28918	else
28919		{ echo "$as_me:$LINENO: result: no" >&5
28920echo "${ECHO_T}no" >&6; }
28921	fi
28922
28923
28924# look for field 'ut_addr_v6' in header 'utmpx.h'
28925		ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
28926		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_addr_v6
28927	{ echo "$as_me:$LINENO: checking for ut_addr_v6 field in utmpx.h" >&5
28928echo $ECHO_N "checking for ut_addr_v6 field in utmpx.h... $ECHO_C" >&6; }
28929	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
28930  echo $ECHO_N "(cached) $ECHO_C" >&6
28931else
28932
28933		cat >conftest.$ac_ext <<_ACEOF
28934/* confdefs.h.  */
28935_ACEOF
28936cat confdefs.h >>conftest.$ac_ext
28937cat >>conftest.$ac_ext <<_ACEOF
28938/* end confdefs.h.  */
28939#include <utmpx.h>
28940
28941_ACEOF
28942if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28943  $EGREP "ut_addr_v6" >/dev/null 2>&1; then
28944   			eval "$ossh_varname=yes"
28945else
28946   			eval "$ossh_varname=no"
28947fi
28948rm -f conftest*
28949
28950fi
28951
28952	ossh_result=`eval 'echo $'"$ossh_varname"`
28953	if test -n "`echo $ossh_varname`"; then
28954		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
28955echo "${ECHO_T}$ossh_result" >&6; }
28956		if test "x$ossh_result" = "xyes"; then
28957
28958cat >>confdefs.h <<\_ACEOF
28959#define HAVE_ADDR_V6_IN_UTMPX 1
28960_ACEOF
28961
28962		fi
28963	else
28964		{ echo "$as_me:$LINENO: result: no" >&5
28965echo "${ECHO_T}no" >&6; }
28966	fi
28967
28968
28969# look for field 'ut_exit' in header 'utmp.h'
28970		ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
28971		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_exit
28972	{ echo "$as_me:$LINENO: checking for ut_exit field in utmp.h" >&5
28973echo $ECHO_N "checking for ut_exit field in utmp.h... $ECHO_C" >&6; }
28974	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
28975  echo $ECHO_N "(cached) $ECHO_C" >&6
28976else
28977
28978		cat >conftest.$ac_ext <<_ACEOF
28979/* confdefs.h.  */
28980_ACEOF
28981cat confdefs.h >>conftest.$ac_ext
28982cat >>conftest.$ac_ext <<_ACEOF
28983/* end confdefs.h.  */
28984#include <utmp.h>
28985
28986_ACEOF
28987if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
28988  $EGREP "ut_exit" >/dev/null 2>&1; then
28989   			eval "$ossh_varname=yes"
28990else
28991   			eval "$ossh_varname=no"
28992fi
28993rm -f conftest*
28994
28995fi
28996
28997	ossh_result=`eval 'echo $'"$ossh_varname"`
28998	if test -n "`echo $ossh_varname`"; then
28999		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
29000echo "${ECHO_T}$ossh_result" >&6; }
29001		if test "x$ossh_result" = "xyes"; then
29002
29003cat >>confdefs.h <<\_ACEOF
29004#define HAVE_EXIT_IN_UTMP 1
29005_ACEOF
29006
29007		fi
29008	else
29009		{ echo "$as_me:$LINENO: result: no" >&5
29010echo "${ECHO_T}no" >&6; }
29011	fi
29012
29013
29014# look for field 'ut_time' in header 'utmp.h'
29015		ossh_safe=`echo "utmp.h" | sed 'y%./+-%__p_%'`
29016		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_time
29017	{ echo "$as_me:$LINENO: checking for ut_time field in utmp.h" >&5
29018echo $ECHO_N "checking for ut_time field in utmp.h... $ECHO_C" >&6; }
29019	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
29020  echo $ECHO_N "(cached) $ECHO_C" >&6
29021else
29022
29023		cat >conftest.$ac_ext <<_ACEOF
29024/* confdefs.h.  */
29025_ACEOF
29026cat confdefs.h >>conftest.$ac_ext
29027cat >>conftest.$ac_ext <<_ACEOF
29028/* end confdefs.h.  */
29029#include <utmp.h>
29030
29031_ACEOF
29032if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
29033  $EGREP "ut_time" >/dev/null 2>&1; then
29034   			eval "$ossh_varname=yes"
29035else
29036   			eval "$ossh_varname=no"
29037fi
29038rm -f conftest*
29039
29040fi
29041
29042	ossh_result=`eval 'echo $'"$ossh_varname"`
29043	if test -n "`echo $ossh_varname`"; then
29044		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
29045echo "${ECHO_T}$ossh_result" >&6; }
29046		if test "x$ossh_result" = "xyes"; then
29047
29048cat >>confdefs.h <<\_ACEOF
29049#define HAVE_TIME_IN_UTMP 1
29050_ACEOF
29051
29052		fi
29053	else
29054		{ echo "$as_me:$LINENO: result: no" >&5
29055echo "${ECHO_T}no" >&6; }
29056	fi
29057
29058
29059# look for field 'ut_time' in header 'utmpx.h'
29060		ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
29061		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_time
29062	{ echo "$as_me:$LINENO: checking for ut_time field in utmpx.h" >&5
29063echo $ECHO_N "checking for ut_time field in utmpx.h... $ECHO_C" >&6; }
29064	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
29065  echo $ECHO_N "(cached) $ECHO_C" >&6
29066else
29067
29068		cat >conftest.$ac_ext <<_ACEOF
29069/* confdefs.h.  */
29070_ACEOF
29071cat confdefs.h >>conftest.$ac_ext
29072cat >>conftest.$ac_ext <<_ACEOF
29073/* end confdefs.h.  */
29074#include <utmpx.h>
29075
29076_ACEOF
29077if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
29078  $EGREP "ut_time" >/dev/null 2>&1; then
29079   			eval "$ossh_varname=yes"
29080else
29081   			eval "$ossh_varname=no"
29082fi
29083rm -f conftest*
29084
29085fi
29086
29087	ossh_result=`eval 'echo $'"$ossh_varname"`
29088	if test -n "`echo $ossh_varname`"; then
29089		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
29090echo "${ECHO_T}$ossh_result" >&6; }
29091		if test "x$ossh_result" = "xyes"; then
29092
29093cat >>confdefs.h <<\_ACEOF
29094#define HAVE_TIME_IN_UTMPX 1
29095_ACEOF
29096
29097		fi
29098	else
29099		{ echo "$as_me:$LINENO: result: no" >&5
29100echo "${ECHO_T}no" >&6; }
29101	fi
29102
29103
29104# look for field 'ut_tv' in header 'utmpx.h'
29105		ossh_safe=`echo "utmpx.h" | sed 'y%./+-%__p_%'`
29106		ossh_varname="ossh_cv_$ossh_safe""_has_"ut_tv
29107	{ echo "$as_me:$LINENO: checking for ut_tv field in utmpx.h" >&5
29108echo $ECHO_N "checking for ut_tv field in utmpx.h... $ECHO_C" >&6; }
29109	if { as_var=$ossh_varname; eval "test \"\${$as_var+set}\" = set"; }; then
29110  echo $ECHO_N "(cached) $ECHO_C" >&6
29111else
29112
29113		cat >conftest.$ac_ext <<_ACEOF
29114/* confdefs.h.  */
29115_ACEOF
29116cat confdefs.h >>conftest.$ac_ext
29117cat >>conftest.$ac_ext <<_ACEOF
29118/* end confdefs.h.  */
29119#include <utmpx.h>
29120
29121_ACEOF
29122if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
29123  $EGREP "ut_tv" >/dev/null 2>&1; then
29124   			eval "$ossh_varname=yes"
29125else
29126   			eval "$ossh_varname=no"
29127fi
29128rm -f conftest*
29129
29130fi
29131
29132	ossh_result=`eval 'echo $'"$ossh_varname"`
29133	if test -n "`echo $ossh_varname`"; then
29134		{ echo "$as_me:$LINENO: result: $ossh_result" >&5
29135echo "${ECHO_T}$ossh_result" >&6; }
29136		if test "x$ossh_result" = "xyes"; then
29137
29138cat >>confdefs.h <<\_ACEOF
29139#define HAVE_TV_IN_UTMPX 1
29140_ACEOF
29141
29142		fi
29143	else
29144		{ echo "$as_me:$LINENO: result: no" >&5
29145echo "${ECHO_T}no" >&6; }
29146	fi
29147
29148
29149{ echo "$as_me:$LINENO: checking for struct stat.st_blksize" >&5
29150echo $ECHO_N "checking for struct stat.st_blksize... $ECHO_C" >&6; }
29151if test "${ac_cv_member_struct_stat_st_blksize+set}" = set; then
29152  echo $ECHO_N "(cached) $ECHO_C" >&6
29153else
29154  cat >conftest.$ac_ext <<_ACEOF
29155/* confdefs.h.  */
29156_ACEOF
29157cat confdefs.h >>conftest.$ac_ext
29158cat >>conftest.$ac_ext <<_ACEOF
29159/* end confdefs.h.  */
29160$ac_includes_default
29161int
29162main ()
29163{
29164static struct stat ac_aggr;
29165if (ac_aggr.st_blksize)
29166return 0;
29167  ;
29168  return 0;
29169}
29170_ACEOF
29171rm -f conftest.$ac_objext
29172if { (ac_try="$ac_compile"
29173case "(($ac_try" in
29174  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29175  *) ac_try_echo=$ac_try;;
29176esac
29177eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29178  (eval "$ac_compile") 2>conftest.er1
29179  ac_status=$?
29180  grep -v '^ *+' conftest.er1 >conftest.err
29181  rm -f conftest.er1
29182  cat conftest.err >&5
29183  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29184  (exit $ac_status); } && {
29185	 test -z "$ac_c_werror_flag" ||
29186	 test ! -s conftest.err
29187       } && test -s conftest.$ac_objext; then
29188  ac_cv_member_struct_stat_st_blksize=yes
29189else
29190  echo "$as_me: failed program was:" >&5
29191sed 's/^/| /' conftest.$ac_ext >&5
29192
29193	cat >conftest.$ac_ext <<_ACEOF
29194/* confdefs.h.  */
29195_ACEOF
29196cat confdefs.h >>conftest.$ac_ext
29197cat >>conftest.$ac_ext <<_ACEOF
29198/* end confdefs.h.  */
29199$ac_includes_default
29200int
29201main ()
29202{
29203static struct stat ac_aggr;
29204if (sizeof ac_aggr.st_blksize)
29205return 0;
29206  ;
29207  return 0;
29208}
29209_ACEOF
29210rm -f conftest.$ac_objext
29211if { (ac_try="$ac_compile"
29212case "(($ac_try" in
29213  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29214  *) ac_try_echo=$ac_try;;
29215esac
29216eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29217  (eval "$ac_compile") 2>conftest.er1
29218  ac_status=$?
29219  grep -v '^ *+' conftest.er1 >conftest.err
29220  rm -f conftest.er1
29221  cat conftest.err >&5
29222  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29223  (exit $ac_status); } && {
29224	 test -z "$ac_c_werror_flag" ||
29225	 test ! -s conftest.err
29226       } && test -s conftest.$ac_objext; then
29227  ac_cv_member_struct_stat_st_blksize=yes
29228else
29229  echo "$as_me: failed program was:" >&5
29230sed 's/^/| /' conftest.$ac_ext >&5
29231
29232	ac_cv_member_struct_stat_st_blksize=no
29233fi
29234
29235rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29236fi
29237
29238rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29239fi
29240{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_stat_st_blksize" >&5
29241echo "${ECHO_T}$ac_cv_member_struct_stat_st_blksize" >&6; }
29242if test $ac_cv_member_struct_stat_st_blksize = yes; then
29243
29244cat >>confdefs.h <<_ACEOF
29245#define HAVE_STRUCT_STAT_ST_BLKSIZE 1
29246_ACEOF
29247
29248
29249fi
29250
29251{ echo "$as_me:$LINENO: checking for struct passwd.pw_gecos" >&5
29252echo $ECHO_N "checking for struct passwd.pw_gecos... $ECHO_C" >&6; }
29253if test "${ac_cv_member_struct_passwd_pw_gecos+set}" = set; then
29254  echo $ECHO_N "(cached) $ECHO_C" >&6
29255else
29256  cat >conftest.$ac_ext <<_ACEOF
29257/* confdefs.h.  */
29258_ACEOF
29259cat confdefs.h >>conftest.$ac_ext
29260cat >>conftest.$ac_ext <<_ACEOF
29261/* end confdefs.h.  */
29262
29263#include <sys/types.h>
29264#include <pwd.h>
29265
29266
29267int
29268main ()
29269{
29270static struct passwd ac_aggr;
29271if (ac_aggr.pw_gecos)
29272return 0;
29273  ;
29274  return 0;
29275}
29276_ACEOF
29277rm -f conftest.$ac_objext
29278if { (ac_try="$ac_compile"
29279case "(($ac_try" in
29280  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29281  *) ac_try_echo=$ac_try;;
29282esac
29283eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29284  (eval "$ac_compile") 2>conftest.er1
29285  ac_status=$?
29286  grep -v '^ *+' conftest.er1 >conftest.err
29287  rm -f conftest.er1
29288  cat conftest.err >&5
29289  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29290  (exit $ac_status); } && {
29291	 test -z "$ac_c_werror_flag" ||
29292	 test ! -s conftest.err
29293       } && test -s conftest.$ac_objext; then
29294  ac_cv_member_struct_passwd_pw_gecos=yes
29295else
29296  echo "$as_me: failed program was:" >&5
29297sed 's/^/| /' conftest.$ac_ext >&5
29298
29299	cat >conftest.$ac_ext <<_ACEOF
29300/* confdefs.h.  */
29301_ACEOF
29302cat confdefs.h >>conftest.$ac_ext
29303cat >>conftest.$ac_ext <<_ACEOF
29304/* end confdefs.h.  */
29305
29306#include <sys/types.h>
29307#include <pwd.h>
29308
29309
29310int
29311main ()
29312{
29313static struct passwd ac_aggr;
29314if (sizeof ac_aggr.pw_gecos)
29315return 0;
29316  ;
29317  return 0;
29318}
29319_ACEOF
29320rm -f conftest.$ac_objext
29321if { (ac_try="$ac_compile"
29322case "(($ac_try" in
29323  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29324  *) ac_try_echo=$ac_try;;
29325esac
29326eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29327  (eval "$ac_compile") 2>conftest.er1
29328  ac_status=$?
29329  grep -v '^ *+' conftest.er1 >conftest.err
29330  rm -f conftest.er1
29331  cat conftest.err >&5
29332  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29333  (exit $ac_status); } && {
29334	 test -z "$ac_c_werror_flag" ||
29335	 test ! -s conftest.err
29336       } && test -s conftest.$ac_objext; then
29337  ac_cv_member_struct_passwd_pw_gecos=yes
29338else
29339  echo "$as_me: failed program was:" >&5
29340sed 's/^/| /' conftest.$ac_ext >&5
29341
29342	ac_cv_member_struct_passwd_pw_gecos=no
29343fi
29344
29345rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29346fi
29347
29348rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29349fi
29350{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_passwd_pw_gecos" >&5
29351echo "${ECHO_T}$ac_cv_member_struct_passwd_pw_gecos" >&6; }
29352if test $ac_cv_member_struct_passwd_pw_gecos = yes; then
29353
29354cat >>confdefs.h <<_ACEOF
29355#define HAVE_STRUCT_PASSWD_PW_GECOS 1
29356_ACEOF
29357
29358
29359fi
29360{ echo "$as_me:$LINENO: checking for struct passwd.pw_class" >&5
29361echo $ECHO_N "checking for struct passwd.pw_class... $ECHO_C" >&6; }
29362if test "${ac_cv_member_struct_passwd_pw_class+set}" = set; then
29363  echo $ECHO_N "(cached) $ECHO_C" >&6
29364else
29365  cat >conftest.$ac_ext <<_ACEOF
29366/* confdefs.h.  */
29367_ACEOF
29368cat confdefs.h >>conftest.$ac_ext
29369cat >>conftest.$ac_ext <<_ACEOF
29370/* end confdefs.h.  */
29371
29372#include <sys/types.h>
29373#include <pwd.h>
29374
29375
29376int
29377main ()
29378{
29379static struct passwd ac_aggr;
29380if (ac_aggr.pw_class)
29381return 0;
29382  ;
29383  return 0;
29384}
29385_ACEOF
29386rm -f conftest.$ac_objext
29387if { (ac_try="$ac_compile"
29388case "(($ac_try" in
29389  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29390  *) ac_try_echo=$ac_try;;
29391esac
29392eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29393  (eval "$ac_compile") 2>conftest.er1
29394  ac_status=$?
29395  grep -v '^ *+' conftest.er1 >conftest.err
29396  rm -f conftest.er1
29397  cat conftest.err >&5
29398  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29399  (exit $ac_status); } && {
29400	 test -z "$ac_c_werror_flag" ||
29401	 test ! -s conftest.err
29402       } && test -s conftest.$ac_objext; then
29403  ac_cv_member_struct_passwd_pw_class=yes
29404else
29405  echo "$as_me: failed program was:" >&5
29406sed 's/^/| /' conftest.$ac_ext >&5
29407
29408	cat >conftest.$ac_ext <<_ACEOF
29409/* confdefs.h.  */
29410_ACEOF
29411cat confdefs.h >>conftest.$ac_ext
29412cat >>conftest.$ac_ext <<_ACEOF
29413/* end confdefs.h.  */
29414
29415#include <sys/types.h>
29416#include <pwd.h>
29417
29418
29419int
29420main ()
29421{
29422static struct passwd ac_aggr;
29423if (sizeof ac_aggr.pw_class)
29424return 0;
29425  ;
29426  return 0;
29427}
29428_ACEOF
29429rm -f conftest.$ac_objext
29430if { (ac_try="$ac_compile"
29431case "(($ac_try" in
29432  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29433  *) ac_try_echo=$ac_try;;
29434esac
29435eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29436  (eval "$ac_compile") 2>conftest.er1
29437  ac_status=$?
29438  grep -v '^ *+' conftest.er1 >conftest.err
29439  rm -f conftest.er1
29440  cat conftest.err >&5
29441  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29442  (exit $ac_status); } && {
29443	 test -z "$ac_c_werror_flag" ||
29444	 test ! -s conftest.err
29445       } && test -s conftest.$ac_objext; then
29446  ac_cv_member_struct_passwd_pw_class=yes
29447else
29448  echo "$as_me: failed program was:" >&5
29449sed 's/^/| /' conftest.$ac_ext >&5
29450
29451	ac_cv_member_struct_passwd_pw_class=no
29452fi
29453
29454rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29455fi
29456
29457rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29458fi
29459{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_passwd_pw_class" >&5
29460echo "${ECHO_T}$ac_cv_member_struct_passwd_pw_class" >&6; }
29461if test $ac_cv_member_struct_passwd_pw_class = yes; then
29462
29463cat >>confdefs.h <<_ACEOF
29464#define HAVE_STRUCT_PASSWD_PW_CLASS 1
29465_ACEOF
29466
29467
29468fi
29469{ echo "$as_me:$LINENO: checking for struct passwd.pw_change" >&5
29470echo $ECHO_N "checking for struct passwd.pw_change... $ECHO_C" >&6; }
29471if test "${ac_cv_member_struct_passwd_pw_change+set}" = set; then
29472  echo $ECHO_N "(cached) $ECHO_C" >&6
29473else
29474  cat >conftest.$ac_ext <<_ACEOF
29475/* confdefs.h.  */
29476_ACEOF
29477cat confdefs.h >>conftest.$ac_ext
29478cat >>conftest.$ac_ext <<_ACEOF
29479/* end confdefs.h.  */
29480
29481#include <sys/types.h>
29482#include <pwd.h>
29483
29484
29485int
29486main ()
29487{
29488static struct passwd ac_aggr;
29489if (ac_aggr.pw_change)
29490return 0;
29491  ;
29492  return 0;
29493}
29494_ACEOF
29495rm -f conftest.$ac_objext
29496if { (ac_try="$ac_compile"
29497case "(($ac_try" in
29498  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29499  *) ac_try_echo=$ac_try;;
29500esac
29501eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29502  (eval "$ac_compile") 2>conftest.er1
29503  ac_status=$?
29504  grep -v '^ *+' conftest.er1 >conftest.err
29505  rm -f conftest.er1
29506  cat conftest.err >&5
29507  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29508  (exit $ac_status); } && {
29509	 test -z "$ac_c_werror_flag" ||
29510	 test ! -s conftest.err
29511       } && test -s conftest.$ac_objext; then
29512  ac_cv_member_struct_passwd_pw_change=yes
29513else
29514  echo "$as_me: failed program was:" >&5
29515sed 's/^/| /' conftest.$ac_ext >&5
29516
29517	cat >conftest.$ac_ext <<_ACEOF
29518/* confdefs.h.  */
29519_ACEOF
29520cat confdefs.h >>conftest.$ac_ext
29521cat >>conftest.$ac_ext <<_ACEOF
29522/* end confdefs.h.  */
29523
29524#include <sys/types.h>
29525#include <pwd.h>
29526
29527
29528int
29529main ()
29530{
29531static struct passwd ac_aggr;
29532if (sizeof ac_aggr.pw_change)
29533return 0;
29534  ;
29535  return 0;
29536}
29537_ACEOF
29538rm -f conftest.$ac_objext
29539if { (ac_try="$ac_compile"
29540case "(($ac_try" in
29541  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29542  *) ac_try_echo=$ac_try;;
29543esac
29544eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29545  (eval "$ac_compile") 2>conftest.er1
29546  ac_status=$?
29547  grep -v '^ *+' conftest.er1 >conftest.err
29548  rm -f conftest.er1
29549  cat conftest.err >&5
29550  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29551  (exit $ac_status); } && {
29552	 test -z "$ac_c_werror_flag" ||
29553	 test ! -s conftest.err
29554       } && test -s conftest.$ac_objext; then
29555  ac_cv_member_struct_passwd_pw_change=yes
29556else
29557  echo "$as_me: failed program was:" >&5
29558sed 's/^/| /' conftest.$ac_ext >&5
29559
29560	ac_cv_member_struct_passwd_pw_change=no
29561fi
29562
29563rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29564fi
29565
29566rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29567fi
29568{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_passwd_pw_change" >&5
29569echo "${ECHO_T}$ac_cv_member_struct_passwd_pw_change" >&6; }
29570if test $ac_cv_member_struct_passwd_pw_change = yes; then
29571
29572cat >>confdefs.h <<_ACEOF
29573#define HAVE_STRUCT_PASSWD_PW_CHANGE 1
29574_ACEOF
29575
29576
29577fi
29578{ echo "$as_me:$LINENO: checking for struct passwd.pw_expire" >&5
29579echo $ECHO_N "checking for struct passwd.pw_expire... $ECHO_C" >&6; }
29580if test "${ac_cv_member_struct_passwd_pw_expire+set}" = set; then
29581  echo $ECHO_N "(cached) $ECHO_C" >&6
29582else
29583  cat >conftest.$ac_ext <<_ACEOF
29584/* confdefs.h.  */
29585_ACEOF
29586cat confdefs.h >>conftest.$ac_ext
29587cat >>conftest.$ac_ext <<_ACEOF
29588/* end confdefs.h.  */
29589
29590#include <sys/types.h>
29591#include <pwd.h>
29592
29593
29594int
29595main ()
29596{
29597static struct passwd ac_aggr;
29598if (ac_aggr.pw_expire)
29599return 0;
29600  ;
29601  return 0;
29602}
29603_ACEOF
29604rm -f conftest.$ac_objext
29605if { (ac_try="$ac_compile"
29606case "(($ac_try" in
29607  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29608  *) ac_try_echo=$ac_try;;
29609esac
29610eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29611  (eval "$ac_compile") 2>conftest.er1
29612  ac_status=$?
29613  grep -v '^ *+' conftest.er1 >conftest.err
29614  rm -f conftest.er1
29615  cat conftest.err >&5
29616  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29617  (exit $ac_status); } && {
29618	 test -z "$ac_c_werror_flag" ||
29619	 test ! -s conftest.err
29620       } && test -s conftest.$ac_objext; then
29621  ac_cv_member_struct_passwd_pw_expire=yes
29622else
29623  echo "$as_me: failed program was:" >&5
29624sed 's/^/| /' conftest.$ac_ext >&5
29625
29626	cat >conftest.$ac_ext <<_ACEOF
29627/* confdefs.h.  */
29628_ACEOF
29629cat confdefs.h >>conftest.$ac_ext
29630cat >>conftest.$ac_ext <<_ACEOF
29631/* end confdefs.h.  */
29632
29633#include <sys/types.h>
29634#include <pwd.h>
29635
29636
29637int
29638main ()
29639{
29640static struct passwd ac_aggr;
29641if (sizeof ac_aggr.pw_expire)
29642return 0;
29643  ;
29644  return 0;
29645}
29646_ACEOF
29647rm -f conftest.$ac_objext
29648if { (ac_try="$ac_compile"
29649case "(($ac_try" in
29650  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29651  *) ac_try_echo=$ac_try;;
29652esac
29653eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29654  (eval "$ac_compile") 2>conftest.er1
29655  ac_status=$?
29656  grep -v '^ *+' conftest.er1 >conftest.err
29657  rm -f conftest.er1
29658  cat conftest.err >&5
29659  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29660  (exit $ac_status); } && {
29661	 test -z "$ac_c_werror_flag" ||
29662	 test ! -s conftest.err
29663       } && test -s conftest.$ac_objext; then
29664  ac_cv_member_struct_passwd_pw_expire=yes
29665else
29666  echo "$as_me: failed program was:" >&5
29667sed 's/^/| /' conftest.$ac_ext >&5
29668
29669	ac_cv_member_struct_passwd_pw_expire=no
29670fi
29671
29672rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29673fi
29674
29675rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29676fi
29677{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_passwd_pw_expire" >&5
29678echo "${ECHO_T}$ac_cv_member_struct_passwd_pw_expire" >&6; }
29679if test $ac_cv_member_struct_passwd_pw_expire = yes; then
29680
29681cat >>confdefs.h <<_ACEOF
29682#define HAVE_STRUCT_PASSWD_PW_EXPIRE 1
29683_ACEOF
29684
29685
29686fi
29687
29688
29689{ echo "$as_me:$LINENO: checking for struct __res_state.retrans" >&5
29690echo $ECHO_N "checking for struct __res_state.retrans... $ECHO_C" >&6; }
29691if test "${ac_cv_member_struct___res_state_retrans+set}" = set; then
29692  echo $ECHO_N "(cached) $ECHO_C" >&6
29693else
29694  cat >conftest.$ac_ext <<_ACEOF
29695/* confdefs.h.  */
29696_ACEOF
29697cat confdefs.h >>conftest.$ac_ext
29698cat >>conftest.$ac_ext <<_ACEOF
29699/* end confdefs.h.  */
29700
29701#include <stdio.h>
29702#if HAVE_SYS_TYPES_H
29703# include <sys/types.h>
29704#endif
29705#include <netinet/in.h>
29706#include <arpa/nameser.h>
29707#include <resolv.h>
29708
29709
29710int
29711main ()
29712{
29713static struct __res_state ac_aggr;
29714if (ac_aggr.retrans)
29715return 0;
29716  ;
29717  return 0;
29718}
29719_ACEOF
29720rm -f conftest.$ac_objext
29721if { (ac_try="$ac_compile"
29722case "(($ac_try" in
29723  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29724  *) ac_try_echo=$ac_try;;
29725esac
29726eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29727  (eval "$ac_compile") 2>conftest.er1
29728  ac_status=$?
29729  grep -v '^ *+' conftest.er1 >conftest.err
29730  rm -f conftest.er1
29731  cat conftest.err >&5
29732  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29733  (exit $ac_status); } && {
29734	 test -z "$ac_c_werror_flag" ||
29735	 test ! -s conftest.err
29736       } && test -s conftest.$ac_objext; then
29737  ac_cv_member_struct___res_state_retrans=yes
29738else
29739  echo "$as_me: failed program was:" >&5
29740sed 's/^/| /' conftest.$ac_ext >&5
29741
29742	cat >conftest.$ac_ext <<_ACEOF
29743/* confdefs.h.  */
29744_ACEOF
29745cat confdefs.h >>conftest.$ac_ext
29746cat >>conftest.$ac_ext <<_ACEOF
29747/* end confdefs.h.  */
29748
29749#include <stdio.h>
29750#if HAVE_SYS_TYPES_H
29751# include <sys/types.h>
29752#endif
29753#include <netinet/in.h>
29754#include <arpa/nameser.h>
29755#include <resolv.h>
29756
29757
29758int
29759main ()
29760{
29761static struct __res_state ac_aggr;
29762if (sizeof ac_aggr.retrans)
29763return 0;
29764  ;
29765  return 0;
29766}
29767_ACEOF
29768rm -f conftest.$ac_objext
29769if { (ac_try="$ac_compile"
29770case "(($ac_try" in
29771  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29772  *) ac_try_echo=$ac_try;;
29773esac
29774eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29775  (eval "$ac_compile") 2>conftest.er1
29776  ac_status=$?
29777  grep -v '^ *+' conftest.er1 >conftest.err
29778  rm -f conftest.er1
29779  cat conftest.err >&5
29780  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29781  (exit $ac_status); } && {
29782	 test -z "$ac_c_werror_flag" ||
29783	 test ! -s conftest.err
29784       } && test -s conftest.$ac_objext; then
29785  ac_cv_member_struct___res_state_retrans=yes
29786else
29787  echo "$as_me: failed program was:" >&5
29788sed 's/^/| /' conftest.$ac_ext >&5
29789
29790	ac_cv_member_struct___res_state_retrans=no
29791fi
29792
29793rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29794fi
29795
29796rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29797fi
29798{ echo "$as_me:$LINENO: result: $ac_cv_member_struct___res_state_retrans" >&5
29799echo "${ECHO_T}$ac_cv_member_struct___res_state_retrans" >&6; }
29800if test $ac_cv_member_struct___res_state_retrans = yes; then
29801  :
29802else
29803
29804cat >>confdefs.h <<\_ACEOF
29805#define __res_state state
29806_ACEOF
29807
29808fi
29809
29810
29811{ echo "$as_me:$LINENO: checking for ss_family field in struct sockaddr_storage" >&5
29812echo $ECHO_N "checking for ss_family field in struct sockaddr_storage... $ECHO_C" >&6; }
29813if test "${ac_cv_have_ss_family_in_struct_ss+set}" = set; then
29814  echo $ECHO_N "(cached) $ECHO_C" >&6
29815else
29816
29817	cat >conftest.$ac_ext <<_ACEOF
29818/* confdefs.h.  */
29819_ACEOF
29820cat confdefs.h >>conftest.$ac_ext
29821cat >>conftest.$ac_ext <<_ACEOF
29822/* end confdefs.h.  */
29823
29824#include <sys/types.h>
29825#include <sys/socket.h>
29826
29827int
29828main ()
29829{
29830 struct sockaddr_storage s; s.ss_family = 1;
29831  ;
29832  return 0;
29833}
29834_ACEOF
29835rm -f conftest.$ac_objext
29836if { (ac_try="$ac_compile"
29837case "(($ac_try" in
29838  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29839  *) ac_try_echo=$ac_try;;
29840esac
29841eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29842  (eval "$ac_compile") 2>conftest.er1
29843  ac_status=$?
29844  grep -v '^ *+' conftest.er1 >conftest.err
29845  rm -f conftest.er1
29846  cat conftest.err >&5
29847  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29848  (exit $ac_status); } && {
29849	 test -z "$ac_c_werror_flag" ||
29850	 test ! -s conftest.err
29851       } && test -s conftest.$ac_objext; then
29852   ac_cv_have_ss_family_in_struct_ss="yes"
29853else
29854  echo "$as_me: failed program was:" >&5
29855sed 's/^/| /' conftest.$ac_ext >&5
29856
29857	 ac_cv_have_ss_family_in_struct_ss="no"
29858fi
29859
29860rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29861
29862fi
29863{ echo "$as_me:$LINENO: result: $ac_cv_have_ss_family_in_struct_ss" >&5
29864echo "${ECHO_T}$ac_cv_have_ss_family_in_struct_ss" >&6; }
29865if test "x$ac_cv_have_ss_family_in_struct_ss" = "xyes" ; then
29866
29867cat >>confdefs.h <<\_ACEOF
29868#define HAVE_SS_FAMILY_IN_SS 1
29869_ACEOF
29870
29871fi
29872
29873{ echo "$as_me:$LINENO: checking for __ss_family field in struct sockaddr_storage" >&5
29874echo $ECHO_N "checking for __ss_family field in struct sockaddr_storage... $ECHO_C" >&6; }
29875if test "${ac_cv_have___ss_family_in_struct_ss+set}" = set; then
29876  echo $ECHO_N "(cached) $ECHO_C" >&6
29877else
29878
29879	cat >conftest.$ac_ext <<_ACEOF
29880/* confdefs.h.  */
29881_ACEOF
29882cat confdefs.h >>conftest.$ac_ext
29883cat >>conftest.$ac_ext <<_ACEOF
29884/* end confdefs.h.  */
29885
29886#include <sys/types.h>
29887#include <sys/socket.h>
29888
29889int
29890main ()
29891{
29892 struct sockaddr_storage s; s.__ss_family = 1;
29893  ;
29894  return 0;
29895}
29896_ACEOF
29897rm -f conftest.$ac_objext
29898if { (ac_try="$ac_compile"
29899case "(($ac_try" in
29900  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29901  *) ac_try_echo=$ac_try;;
29902esac
29903eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29904  (eval "$ac_compile") 2>conftest.er1
29905  ac_status=$?
29906  grep -v '^ *+' conftest.er1 >conftest.err
29907  rm -f conftest.er1
29908  cat conftest.err >&5
29909  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29910  (exit $ac_status); } && {
29911	 test -z "$ac_c_werror_flag" ||
29912	 test ! -s conftest.err
29913       } && test -s conftest.$ac_objext; then
29914   ac_cv_have___ss_family_in_struct_ss="yes"
29915else
29916  echo "$as_me: failed program was:" >&5
29917sed 's/^/| /' conftest.$ac_ext >&5
29918
29919	 ac_cv_have___ss_family_in_struct_ss="no"
29920
29921fi
29922
29923rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29924
29925fi
29926{ echo "$as_me:$LINENO: result: $ac_cv_have___ss_family_in_struct_ss" >&5
29927echo "${ECHO_T}$ac_cv_have___ss_family_in_struct_ss" >&6; }
29928if test "x$ac_cv_have___ss_family_in_struct_ss" = "xyes" ; then
29929
29930cat >>confdefs.h <<\_ACEOF
29931#define HAVE___SS_FAMILY_IN_SS 1
29932_ACEOF
29933
29934fi
29935
29936{ echo "$as_me:$LINENO: checking for msg_accrights field in struct msghdr" >&5
29937echo $ECHO_N "checking for msg_accrights field in struct msghdr... $ECHO_C" >&6; }
29938if test "${ac_cv_have_accrights_in_msghdr+set}" = set; then
29939  echo $ECHO_N "(cached) $ECHO_C" >&6
29940else
29941
29942	cat >conftest.$ac_ext <<_ACEOF
29943/* confdefs.h.  */
29944_ACEOF
29945cat confdefs.h >>conftest.$ac_ext
29946cat >>conftest.$ac_ext <<_ACEOF
29947/* end confdefs.h.  */
29948
29949#include <sys/types.h>
29950#include <sys/socket.h>
29951#include <sys/uio.h>
29952
29953int
29954main ()
29955{
29956
29957#ifdef msg_accrights
29958#error "msg_accrights is a macro"
29959exit(1);
29960#endif
29961struct msghdr m;
29962m.msg_accrights = 0;
29963exit(0);
29964
29965  ;
29966  return 0;
29967}
29968_ACEOF
29969rm -f conftest.$ac_objext
29970if { (ac_try="$ac_compile"
29971case "(($ac_try" in
29972  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29973  *) ac_try_echo=$ac_try;;
29974esac
29975eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
29976  (eval "$ac_compile") 2>conftest.er1
29977  ac_status=$?
29978  grep -v '^ *+' conftest.er1 >conftest.err
29979  rm -f conftest.er1
29980  cat conftest.err >&5
29981  echo "$as_me:$LINENO: \$? = $ac_status" >&5
29982  (exit $ac_status); } && {
29983	 test -z "$ac_c_werror_flag" ||
29984	 test ! -s conftest.err
29985       } && test -s conftest.$ac_objext; then
29986   ac_cv_have_accrights_in_msghdr="yes"
29987else
29988  echo "$as_me: failed program was:" >&5
29989sed 's/^/| /' conftest.$ac_ext >&5
29990
29991	 ac_cv_have_accrights_in_msghdr="no"
29992
29993fi
29994
29995rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
29996
29997fi
29998{ echo "$as_me:$LINENO: result: $ac_cv_have_accrights_in_msghdr" >&5
29999echo "${ECHO_T}$ac_cv_have_accrights_in_msghdr" >&6; }
30000if test "x$ac_cv_have_accrights_in_msghdr" = "xyes" ; then
30001
30002cat >>confdefs.h <<\_ACEOF
30003#define HAVE_ACCRIGHTS_IN_MSGHDR 1
30004_ACEOF
30005
30006fi
30007
30008{ echo "$as_me:$LINENO: checking if struct statvfs.f_fsid is integral type" >&5
30009echo $ECHO_N "checking if struct statvfs.f_fsid is integral type... $ECHO_C" >&6; }
30010cat >conftest.$ac_ext <<_ACEOF
30011/* confdefs.h.  */
30012_ACEOF
30013cat confdefs.h >>conftest.$ac_ext
30014cat >>conftest.$ac_ext <<_ACEOF
30015/* end confdefs.h.  */
30016
30017#include <sys/param.h>
30018#include <sys/stat.h>
30019#ifdef HAVE_SYS_TIME_H
30020# include <sys/time.h>
30021#endif
30022#ifdef HAVE_SYS_MOUNT_H
30023#include <sys/mount.h>
30024#endif
30025#ifdef HAVE_SYS_STATVFS_H
30026#include <sys/statvfs.h>
30027#endif
30028
30029int
30030main ()
30031{
30032 struct statvfs s; s.f_fsid = 0;
30033  ;
30034  return 0;
30035}
30036_ACEOF
30037rm -f conftest.$ac_objext
30038if { (ac_try="$ac_compile"
30039case "(($ac_try" in
30040  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30041  *) ac_try_echo=$ac_try;;
30042esac
30043eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30044  (eval "$ac_compile") 2>conftest.er1
30045  ac_status=$?
30046  grep -v '^ *+' conftest.er1 >conftest.err
30047  rm -f conftest.er1
30048  cat conftest.err >&5
30049  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30050  (exit $ac_status); } && {
30051	 test -z "$ac_c_werror_flag" ||
30052	 test ! -s conftest.err
30053       } && test -s conftest.$ac_objext; then
30054   { echo "$as_me:$LINENO: result: yes" >&5
30055echo "${ECHO_T}yes" >&6; }
30056else
30057  echo "$as_me: failed program was:" >&5
30058sed 's/^/| /' conftest.$ac_ext >&5
30059
30060	 { echo "$as_me:$LINENO: result: no" >&5
30061echo "${ECHO_T}no" >&6; }
30062
30063	{ echo "$as_me:$LINENO: checking if fsid_t has member val" >&5
30064echo $ECHO_N "checking if fsid_t has member val... $ECHO_C" >&6; }
30065	cat >conftest.$ac_ext <<_ACEOF
30066/* confdefs.h.  */
30067_ACEOF
30068cat confdefs.h >>conftest.$ac_ext
30069cat >>conftest.$ac_ext <<_ACEOF
30070/* end confdefs.h.  */
30071
30072#include <sys/types.h>
30073#include <sys/statvfs.h>
30074
30075int
30076main ()
30077{
30078 fsid_t t; t.val[0] = 0;
30079  ;
30080  return 0;
30081}
30082_ACEOF
30083rm -f conftest.$ac_objext
30084if { (ac_try="$ac_compile"
30085case "(($ac_try" in
30086  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30087  *) ac_try_echo=$ac_try;;
30088esac
30089eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30090  (eval "$ac_compile") 2>conftest.er1
30091  ac_status=$?
30092  grep -v '^ *+' conftest.er1 >conftest.err
30093  rm -f conftest.er1
30094  cat conftest.err >&5
30095  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30096  (exit $ac_status); } && {
30097	 test -z "$ac_c_werror_flag" ||
30098	 test ! -s conftest.err
30099       } && test -s conftest.$ac_objext; then
30100   { echo "$as_me:$LINENO: result: yes" >&5
30101echo "${ECHO_T}yes" >&6; }
30102
30103cat >>confdefs.h <<\_ACEOF
30104#define FSID_HAS_VAL 1
30105_ACEOF
30106
30107else
30108  echo "$as_me: failed program was:" >&5
30109sed 's/^/| /' conftest.$ac_ext >&5
30110
30111	 { echo "$as_me:$LINENO: result: no" >&5
30112echo "${ECHO_T}no" >&6; }
30113fi
30114
30115rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30116
30117	{ echo "$as_me:$LINENO: checking if f_fsid has member __val" >&5
30118echo $ECHO_N "checking if f_fsid has member __val... $ECHO_C" >&6; }
30119	cat >conftest.$ac_ext <<_ACEOF
30120/* confdefs.h.  */
30121_ACEOF
30122cat confdefs.h >>conftest.$ac_ext
30123cat >>conftest.$ac_ext <<_ACEOF
30124/* end confdefs.h.  */
30125
30126#include <sys/types.h>
30127#include <sys/statvfs.h>
30128
30129int
30130main ()
30131{
30132 fsid_t t; t.__val[0] = 0;
30133  ;
30134  return 0;
30135}
30136_ACEOF
30137rm -f conftest.$ac_objext
30138if { (ac_try="$ac_compile"
30139case "(($ac_try" in
30140  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30141  *) ac_try_echo=$ac_try;;
30142esac
30143eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30144  (eval "$ac_compile") 2>conftest.er1
30145  ac_status=$?
30146  grep -v '^ *+' conftest.er1 >conftest.err
30147  rm -f conftest.er1
30148  cat conftest.err >&5
30149  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30150  (exit $ac_status); } && {
30151	 test -z "$ac_c_werror_flag" ||
30152	 test ! -s conftest.err
30153       } && test -s conftest.$ac_objext; then
30154   { echo "$as_me:$LINENO: result: yes" >&5
30155echo "${ECHO_T}yes" >&6; }
30156
30157cat >>confdefs.h <<\_ACEOF
30158#define FSID_HAS___VAL 1
30159_ACEOF
30160
30161else
30162  echo "$as_me: failed program was:" >&5
30163sed 's/^/| /' conftest.$ac_ext >&5
30164
30165	 { echo "$as_me:$LINENO: result: no" >&5
30166echo "${ECHO_T}no" >&6; }
30167fi
30168
30169rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30170
30171fi
30172
30173rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30174
30175{ echo "$as_me:$LINENO: checking for msg_control field in struct msghdr" >&5
30176echo $ECHO_N "checking for msg_control field in struct msghdr... $ECHO_C" >&6; }
30177if test "${ac_cv_have_control_in_msghdr+set}" = set; then
30178  echo $ECHO_N "(cached) $ECHO_C" >&6
30179else
30180
30181	cat >conftest.$ac_ext <<_ACEOF
30182/* confdefs.h.  */
30183_ACEOF
30184cat confdefs.h >>conftest.$ac_ext
30185cat >>conftest.$ac_ext <<_ACEOF
30186/* end confdefs.h.  */
30187
30188#include <sys/types.h>
30189#include <sys/socket.h>
30190#include <sys/uio.h>
30191
30192int
30193main ()
30194{
30195
30196#ifdef msg_control
30197#error "msg_control is a macro"
30198exit(1);
30199#endif
30200struct msghdr m;
30201m.msg_control = 0;
30202exit(0);
30203
30204  ;
30205  return 0;
30206}
30207_ACEOF
30208rm -f conftest.$ac_objext
30209if { (ac_try="$ac_compile"
30210case "(($ac_try" in
30211  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30212  *) ac_try_echo=$ac_try;;
30213esac
30214eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30215  (eval "$ac_compile") 2>conftest.er1
30216  ac_status=$?
30217  grep -v '^ *+' conftest.er1 >conftest.err
30218  rm -f conftest.er1
30219  cat conftest.err >&5
30220  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30221  (exit $ac_status); } && {
30222	 test -z "$ac_c_werror_flag" ||
30223	 test ! -s conftest.err
30224       } && test -s conftest.$ac_objext; then
30225   ac_cv_have_control_in_msghdr="yes"
30226else
30227  echo "$as_me: failed program was:" >&5
30228sed 's/^/| /' conftest.$ac_ext >&5
30229
30230	 ac_cv_have_control_in_msghdr="no"
30231
30232fi
30233
30234rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
30235
30236fi
30237{ echo "$as_me:$LINENO: result: $ac_cv_have_control_in_msghdr" >&5
30238echo "${ECHO_T}$ac_cv_have_control_in_msghdr" >&6; }
30239if test "x$ac_cv_have_control_in_msghdr" = "xyes" ; then
30240
30241cat >>confdefs.h <<\_ACEOF
30242#define HAVE_CONTROL_IN_MSGHDR 1
30243_ACEOF
30244
30245fi
30246
30247{ echo "$as_me:$LINENO: checking if libc defines __progname" >&5
30248echo $ECHO_N "checking if libc defines __progname... $ECHO_C" >&6; }
30249if test "${ac_cv_libc_defines___progname+set}" = set; then
30250  echo $ECHO_N "(cached) $ECHO_C" >&6
30251else
30252
30253	cat >conftest.$ac_ext <<_ACEOF
30254/* confdefs.h.  */
30255_ACEOF
30256cat confdefs.h >>conftest.$ac_ext
30257cat >>conftest.$ac_ext <<_ACEOF
30258/* end confdefs.h.  */
30259
30260int
30261main ()
30262{
30263 extern char *__progname; printf("%s", __progname);
30264  ;
30265  return 0;
30266}
30267_ACEOF
30268rm -f conftest.$ac_objext conftest$ac_exeext
30269if { (ac_try="$ac_link"
30270case "(($ac_try" in
30271  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30272  *) ac_try_echo=$ac_try;;
30273esac
30274eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30275  (eval "$ac_link") 2>conftest.er1
30276  ac_status=$?
30277  grep -v '^ *+' conftest.er1 >conftest.err
30278  rm -f conftest.er1
30279  cat conftest.err >&5
30280  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30281  (exit $ac_status); } && {
30282	 test -z "$ac_c_werror_flag" ||
30283	 test ! -s conftest.err
30284       } && test -s conftest$ac_exeext &&
30285       $as_test_x conftest$ac_exeext; then
30286   ac_cv_libc_defines___progname="yes"
30287else
30288  echo "$as_me: failed program was:" >&5
30289sed 's/^/| /' conftest.$ac_ext >&5
30290
30291	 ac_cv_libc_defines___progname="no"
30292
30293fi
30294
30295rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
30296      conftest$ac_exeext conftest.$ac_ext
30297
30298fi
30299{ echo "$as_me:$LINENO: result: $ac_cv_libc_defines___progname" >&5
30300echo "${ECHO_T}$ac_cv_libc_defines___progname" >&6; }
30301if test "x$ac_cv_libc_defines___progname" = "xyes" ; then
30302
30303cat >>confdefs.h <<\_ACEOF
30304#define HAVE___PROGNAME 1
30305_ACEOF
30306
30307fi
30308
30309{ echo "$as_me:$LINENO: checking whether $CC implements __FUNCTION__" >&5
30310echo $ECHO_N "checking whether $CC implements __FUNCTION__... $ECHO_C" >&6; }
30311if test "${ac_cv_cc_implements___FUNCTION__+set}" = set; then
30312  echo $ECHO_N "(cached) $ECHO_C" >&6
30313else
30314
30315	cat >conftest.$ac_ext <<_ACEOF
30316/* confdefs.h.  */
30317_ACEOF
30318cat confdefs.h >>conftest.$ac_ext
30319cat >>conftest.$ac_ext <<_ACEOF
30320/* end confdefs.h.  */
30321 #include <stdio.h>
30322int
30323main ()
30324{
30325 printf("%s", __FUNCTION__);
30326  ;
30327  return 0;
30328}
30329_ACEOF
30330rm -f conftest.$ac_objext conftest$ac_exeext
30331if { (ac_try="$ac_link"
30332case "(($ac_try" in
30333  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30334  *) ac_try_echo=$ac_try;;
30335esac
30336eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30337  (eval "$ac_link") 2>conftest.er1
30338  ac_status=$?
30339  grep -v '^ *+' conftest.er1 >conftest.err
30340  rm -f conftest.er1
30341  cat conftest.err >&5
30342  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30343  (exit $ac_status); } && {
30344	 test -z "$ac_c_werror_flag" ||
30345	 test ! -s conftest.err
30346       } && test -s conftest$ac_exeext &&
30347       $as_test_x conftest$ac_exeext; then
30348   ac_cv_cc_implements___FUNCTION__="yes"
30349else
30350  echo "$as_me: failed program was:" >&5
30351sed 's/^/| /' conftest.$ac_ext >&5
30352
30353	 ac_cv_cc_implements___FUNCTION__="no"
30354
30355fi
30356
30357rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
30358      conftest$ac_exeext conftest.$ac_ext
30359
30360fi
30361{ echo "$as_me:$LINENO: result: $ac_cv_cc_implements___FUNCTION__" >&5
30362echo "${ECHO_T}$ac_cv_cc_implements___FUNCTION__" >&6; }
30363if test "x$ac_cv_cc_implements___FUNCTION__" = "xyes" ; then
30364
30365cat >>confdefs.h <<\_ACEOF
30366#define HAVE___FUNCTION__ 1
30367_ACEOF
30368
30369fi
30370
30371{ echo "$as_me:$LINENO: checking whether $CC implements __func__" >&5
30372echo $ECHO_N "checking whether $CC implements __func__... $ECHO_C" >&6; }
30373if test "${ac_cv_cc_implements___func__+set}" = set; then
30374  echo $ECHO_N "(cached) $ECHO_C" >&6
30375else
30376
30377	cat >conftest.$ac_ext <<_ACEOF
30378/* confdefs.h.  */
30379_ACEOF
30380cat confdefs.h >>conftest.$ac_ext
30381cat >>conftest.$ac_ext <<_ACEOF
30382/* end confdefs.h.  */
30383 #include <stdio.h>
30384int
30385main ()
30386{
30387 printf("%s", __func__);
30388  ;
30389  return 0;
30390}
30391_ACEOF
30392rm -f conftest.$ac_objext conftest$ac_exeext
30393if { (ac_try="$ac_link"
30394case "(($ac_try" in
30395  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30396  *) ac_try_echo=$ac_try;;
30397esac
30398eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30399  (eval "$ac_link") 2>conftest.er1
30400  ac_status=$?
30401  grep -v '^ *+' conftest.er1 >conftest.err
30402  rm -f conftest.er1
30403  cat conftest.err >&5
30404  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30405  (exit $ac_status); } && {
30406	 test -z "$ac_c_werror_flag" ||
30407	 test ! -s conftest.err
30408       } && test -s conftest$ac_exeext &&
30409       $as_test_x conftest$ac_exeext; then
30410   ac_cv_cc_implements___func__="yes"
30411else
30412  echo "$as_me: failed program was:" >&5
30413sed 's/^/| /' conftest.$ac_ext >&5
30414
30415	 ac_cv_cc_implements___func__="no"
30416
30417fi
30418
30419rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
30420      conftest$ac_exeext conftest.$ac_ext
30421
30422fi
30423{ echo "$as_me:$LINENO: result: $ac_cv_cc_implements___func__" >&5
30424echo "${ECHO_T}$ac_cv_cc_implements___func__" >&6; }
30425if test "x$ac_cv_cc_implements___func__" = "xyes" ; then
30426
30427cat >>confdefs.h <<\_ACEOF
30428#define HAVE___func__ 1
30429_ACEOF
30430
30431fi
30432
30433{ echo "$as_me:$LINENO: checking whether va_copy exists" >&5
30434echo $ECHO_N "checking whether va_copy exists... $ECHO_C" >&6; }
30435if test "${ac_cv_have_va_copy+set}" = set; then
30436  echo $ECHO_N "(cached) $ECHO_C" >&6
30437else
30438
30439	cat >conftest.$ac_ext <<_ACEOF
30440/* confdefs.h.  */
30441_ACEOF
30442cat confdefs.h >>conftest.$ac_ext
30443cat >>conftest.$ac_ext <<_ACEOF
30444/* end confdefs.h.  */
30445
30446#include <stdarg.h>
30447va_list x,y;
30448
30449int
30450main ()
30451{
30452 va_copy(x,y);
30453  ;
30454  return 0;
30455}
30456_ACEOF
30457rm -f conftest.$ac_objext conftest$ac_exeext
30458if { (ac_try="$ac_link"
30459case "(($ac_try" in
30460  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30461  *) ac_try_echo=$ac_try;;
30462esac
30463eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30464  (eval "$ac_link") 2>conftest.er1
30465  ac_status=$?
30466  grep -v '^ *+' conftest.er1 >conftest.err
30467  rm -f conftest.er1
30468  cat conftest.err >&5
30469  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30470  (exit $ac_status); } && {
30471	 test -z "$ac_c_werror_flag" ||
30472	 test ! -s conftest.err
30473       } && test -s conftest$ac_exeext &&
30474       $as_test_x conftest$ac_exeext; then
30475   ac_cv_have_va_copy="yes"
30476else
30477  echo "$as_me: failed program was:" >&5
30478sed 's/^/| /' conftest.$ac_ext >&5
30479
30480	 ac_cv_have_va_copy="no"
30481
30482fi
30483
30484rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
30485      conftest$ac_exeext conftest.$ac_ext
30486
30487fi
30488{ echo "$as_me:$LINENO: result: $ac_cv_have_va_copy" >&5
30489echo "${ECHO_T}$ac_cv_have_va_copy" >&6; }
30490if test "x$ac_cv_have_va_copy" = "xyes" ; then
30491
30492cat >>confdefs.h <<\_ACEOF
30493#define HAVE_VA_COPY 1
30494_ACEOF
30495
30496fi
30497
30498{ echo "$as_me:$LINENO: checking whether __va_copy exists" >&5
30499echo $ECHO_N "checking whether __va_copy exists... $ECHO_C" >&6; }
30500if test "${ac_cv_have___va_copy+set}" = set; then
30501  echo $ECHO_N "(cached) $ECHO_C" >&6
30502else
30503
30504	cat >conftest.$ac_ext <<_ACEOF
30505/* confdefs.h.  */
30506_ACEOF
30507cat confdefs.h >>conftest.$ac_ext
30508cat >>conftest.$ac_ext <<_ACEOF
30509/* end confdefs.h.  */
30510
30511#include <stdarg.h>
30512va_list x,y;
30513
30514int
30515main ()
30516{
30517 __va_copy(x,y);
30518  ;
30519  return 0;
30520}
30521_ACEOF
30522rm -f conftest.$ac_objext conftest$ac_exeext
30523if { (ac_try="$ac_link"
30524case "(($ac_try" in
30525  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30526  *) ac_try_echo=$ac_try;;
30527esac
30528eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30529  (eval "$ac_link") 2>conftest.er1
30530  ac_status=$?
30531  grep -v '^ *+' conftest.er1 >conftest.err
30532  rm -f conftest.er1
30533  cat conftest.err >&5
30534  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30535  (exit $ac_status); } && {
30536	 test -z "$ac_c_werror_flag" ||
30537	 test ! -s conftest.err
30538       } && test -s conftest$ac_exeext &&
30539       $as_test_x conftest$ac_exeext; then
30540   ac_cv_have___va_copy="yes"
30541else
30542  echo "$as_me: failed program was:" >&5
30543sed 's/^/| /' conftest.$ac_ext >&5
30544
30545	 ac_cv_have___va_copy="no"
30546
30547fi
30548
30549rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
30550      conftest$ac_exeext conftest.$ac_ext
30551
30552fi
30553{ echo "$as_me:$LINENO: result: $ac_cv_have___va_copy" >&5
30554echo "${ECHO_T}$ac_cv_have___va_copy" >&6; }
30555if test "x$ac_cv_have___va_copy" = "xyes" ; then
30556
30557cat >>confdefs.h <<\_ACEOF
30558#define HAVE___VA_COPY 1
30559_ACEOF
30560
30561fi
30562
30563{ echo "$as_me:$LINENO: checking whether getopt has optreset support" >&5
30564echo $ECHO_N "checking whether getopt has optreset support... $ECHO_C" >&6; }
30565if test "${ac_cv_have_getopt_optreset+set}" = set; then
30566  echo $ECHO_N "(cached) $ECHO_C" >&6
30567else
30568
30569	cat >conftest.$ac_ext <<_ACEOF
30570/* confdefs.h.  */
30571_ACEOF
30572cat confdefs.h >>conftest.$ac_ext
30573cat >>conftest.$ac_ext <<_ACEOF
30574/* end confdefs.h.  */
30575 #include <getopt.h>
30576int
30577main ()
30578{
30579 extern int optreset; optreset = 0;
30580  ;
30581  return 0;
30582}
30583_ACEOF
30584rm -f conftest.$ac_objext conftest$ac_exeext
30585if { (ac_try="$ac_link"
30586case "(($ac_try" in
30587  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30588  *) ac_try_echo=$ac_try;;
30589esac
30590eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30591  (eval "$ac_link") 2>conftest.er1
30592  ac_status=$?
30593  grep -v '^ *+' conftest.er1 >conftest.err
30594  rm -f conftest.er1
30595  cat conftest.err >&5
30596  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30597  (exit $ac_status); } && {
30598	 test -z "$ac_c_werror_flag" ||
30599	 test ! -s conftest.err
30600       } && test -s conftest$ac_exeext &&
30601       $as_test_x conftest$ac_exeext; then
30602   ac_cv_have_getopt_optreset="yes"
30603else
30604  echo "$as_me: failed program was:" >&5
30605sed 's/^/| /' conftest.$ac_ext >&5
30606
30607	 ac_cv_have_getopt_optreset="no"
30608
30609fi
30610
30611rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
30612      conftest$ac_exeext conftest.$ac_ext
30613
30614fi
30615{ echo "$as_me:$LINENO: result: $ac_cv_have_getopt_optreset" >&5
30616echo "${ECHO_T}$ac_cv_have_getopt_optreset" >&6; }
30617if test "x$ac_cv_have_getopt_optreset" = "xyes" ; then
30618
30619cat >>confdefs.h <<\_ACEOF
30620#define HAVE_GETOPT_OPTRESET 1
30621_ACEOF
30622
30623fi
30624
30625{ echo "$as_me:$LINENO: checking if libc defines sys_errlist" >&5
30626echo $ECHO_N "checking if libc defines sys_errlist... $ECHO_C" >&6; }
30627if test "${ac_cv_libc_defines_sys_errlist+set}" = set; then
30628  echo $ECHO_N "(cached) $ECHO_C" >&6
30629else
30630
30631	cat >conftest.$ac_ext <<_ACEOF
30632/* confdefs.h.  */
30633_ACEOF
30634cat confdefs.h >>conftest.$ac_ext
30635cat >>conftest.$ac_ext <<_ACEOF
30636/* end confdefs.h.  */
30637
30638int
30639main ()
30640{
30641 extern const char *const sys_errlist[]; printf("%s", sys_errlist[0]);
30642  ;
30643  return 0;
30644}
30645_ACEOF
30646rm -f conftest.$ac_objext conftest$ac_exeext
30647if { (ac_try="$ac_link"
30648case "(($ac_try" in
30649  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30650  *) ac_try_echo=$ac_try;;
30651esac
30652eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30653  (eval "$ac_link") 2>conftest.er1
30654  ac_status=$?
30655  grep -v '^ *+' conftest.er1 >conftest.err
30656  rm -f conftest.er1
30657  cat conftest.err >&5
30658  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30659  (exit $ac_status); } && {
30660	 test -z "$ac_c_werror_flag" ||
30661	 test ! -s conftest.err
30662       } && test -s conftest$ac_exeext &&
30663       $as_test_x conftest$ac_exeext; then
30664   ac_cv_libc_defines_sys_errlist="yes"
30665else
30666  echo "$as_me: failed program was:" >&5
30667sed 's/^/| /' conftest.$ac_ext >&5
30668
30669	 ac_cv_libc_defines_sys_errlist="no"
30670
30671fi
30672
30673rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
30674      conftest$ac_exeext conftest.$ac_ext
30675
30676fi
30677{ echo "$as_me:$LINENO: result: $ac_cv_libc_defines_sys_errlist" >&5
30678echo "${ECHO_T}$ac_cv_libc_defines_sys_errlist" >&6; }
30679if test "x$ac_cv_libc_defines_sys_errlist" = "xyes" ; then
30680
30681cat >>confdefs.h <<\_ACEOF
30682#define HAVE_SYS_ERRLIST 1
30683_ACEOF
30684
30685fi
30686
30687
30688{ echo "$as_me:$LINENO: checking if libc defines sys_nerr" >&5
30689echo $ECHO_N "checking if libc defines sys_nerr... $ECHO_C" >&6; }
30690if test "${ac_cv_libc_defines_sys_nerr+set}" = set; then
30691  echo $ECHO_N "(cached) $ECHO_C" >&6
30692else
30693
30694	cat >conftest.$ac_ext <<_ACEOF
30695/* confdefs.h.  */
30696_ACEOF
30697cat confdefs.h >>conftest.$ac_ext
30698cat >>conftest.$ac_ext <<_ACEOF
30699/* end confdefs.h.  */
30700
30701int
30702main ()
30703{
30704 extern int sys_nerr; printf("%i", sys_nerr);
30705  ;
30706  return 0;
30707}
30708_ACEOF
30709rm -f conftest.$ac_objext conftest$ac_exeext
30710if { (ac_try="$ac_link"
30711case "(($ac_try" in
30712  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30713  *) ac_try_echo=$ac_try;;
30714esac
30715eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30716  (eval "$ac_link") 2>conftest.er1
30717  ac_status=$?
30718  grep -v '^ *+' conftest.er1 >conftest.err
30719  rm -f conftest.er1
30720  cat conftest.err >&5
30721  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30722  (exit $ac_status); } && {
30723	 test -z "$ac_c_werror_flag" ||
30724	 test ! -s conftest.err
30725       } && test -s conftest$ac_exeext &&
30726       $as_test_x conftest$ac_exeext; then
30727   ac_cv_libc_defines_sys_nerr="yes"
30728else
30729  echo "$as_me: failed program was:" >&5
30730sed 's/^/| /' conftest.$ac_ext >&5
30731
30732	 ac_cv_libc_defines_sys_nerr="no"
30733
30734fi
30735
30736rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
30737      conftest$ac_exeext conftest.$ac_ext
30738
30739fi
30740{ echo "$as_me:$LINENO: result: $ac_cv_libc_defines_sys_nerr" >&5
30741echo "${ECHO_T}$ac_cv_libc_defines_sys_nerr" >&6; }
30742if test "x$ac_cv_libc_defines_sys_nerr" = "xyes" ; then
30743
30744cat >>confdefs.h <<\_ACEOF
30745#define HAVE_SYS_NERR 1
30746_ACEOF
30747
30748fi
30749
30750# Check libraries needed by DNS fingerprint support
30751{ echo "$as_me:$LINENO: checking for library containing getrrsetbyname" >&5
30752echo $ECHO_N "checking for library containing getrrsetbyname... $ECHO_C" >&6; }
30753if test "${ac_cv_search_getrrsetbyname+set}" = set; then
30754  echo $ECHO_N "(cached) $ECHO_C" >&6
30755else
30756  ac_func_search_save_LIBS=$LIBS
30757cat >conftest.$ac_ext <<_ACEOF
30758/* confdefs.h.  */
30759_ACEOF
30760cat confdefs.h >>conftest.$ac_ext
30761cat >>conftest.$ac_ext <<_ACEOF
30762/* end confdefs.h.  */
30763
30764/* Override any GCC internal prototype to avoid an error.
30765   Use char because int might match the return type of a GCC
30766   builtin and then its argument prototype would still apply.  */
30767#ifdef __cplusplus
30768extern "C"
30769#endif
30770char getrrsetbyname ();
30771int
30772main ()
30773{
30774return getrrsetbyname ();
30775  ;
30776  return 0;
30777}
30778_ACEOF
30779for ac_lib in '' resolv; do
30780  if test -z "$ac_lib"; then
30781    ac_res="none required"
30782  else
30783    ac_res=-l$ac_lib
30784    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
30785  fi
30786  rm -f conftest.$ac_objext conftest$ac_exeext
30787if { (ac_try="$ac_link"
30788case "(($ac_try" in
30789  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30790  *) ac_try_echo=$ac_try;;
30791esac
30792eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30793  (eval "$ac_link") 2>conftest.er1
30794  ac_status=$?
30795  grep -v '^ *+' conftest.er1 >conftest.err
30796  rm -f conftest.er1
30797  cat conftest.err >&5
30798  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30799  (exit $ac_status); } && {
30800	 test -z "$ac_c_werror_flag" ||
30801	 test ! -s conftest.err
30802       } && test -s conftest$ac_exeext &&
30803       $as_test_x conftest$ac_exeext; then
30804  ac_cv_search_getrrsetbyname=$ac_res
30805else
30806  echo "$as_me: failed program was:" >&5
30807sed 's/^/| /' conftest.$ac_ext >&5
30808
30809
30810fi
30811
30812rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
30813      conftest$ac_exeext
30814  if test "${ac_cv_search_getrrsetbyname+set}" = set; then
30815  break
30816fi
30817done
30818if test "${ac_cv_search_getrrsetbyname+set}" = set; then
30819  :
30820else
30821  ac_cv_search_getrrsetbyname=no
30822fi
30823rm conftest.$ac_ext
30824LIBS=$ac_func_search_save_LIBS
30825fi
30826{ echo "$as_me:$LINENO: result: $ac_cv_search_getrrsetbyname" >&5
30827echo "${ECHO_T}$ac_cv_search_getrrsetbyname" >&6; }
30828ac_res=$ac_cv_search_getrrsetbyname
30829if test "$ac_res" != no; then
30830  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
30831
30832cat >>confdefs.h <<\_ACEOF
30833#define HAVE_GETRRSETBYNAME 1
30834_ACEOF
30835
30836else
30837
30838		# Needed by our getrrsetbyname()
30839		{ echo "$as_me:$LINENO: checking for library containing res_query" >&5
30840echo $ECHO_N "checking for library containing res_query... $ECHO_C" >&6; }
30841if test "${ac_cv_search_res_query+set}" = set; then
30842  echo $ECHO_N "(cached) $ECHO_C" >&6
30843else
30844  ac_func_search_save_LIBS=$LIBS
30845cat >conftest.$ac_ext <<_ACEOF
30846/* confdefs.h.  */
30847_ACEOF
30848cat confdefs.h >>conftest.$ac_ext
30849cat >>conftest.$ac_ext <<_ACEOF
30850/* end confdefs.h.  */
30851
30852/* Override any GCC internal prototype to avoid an error.
30853   Use char because int might match the return type of a GCC
30854   builtin and then its argument prototype would still apply.  */
30855#ifdef __cplusplus
30856extern "C"
30857#endif
30858char res_query ();
30859int
30860main ()
30861{
30862return res_query ();
30863  ;
30864  return 0;
30865}
30866_ACEOF
30867for ac_lib in '' resolv; do
30868  if test -z "$ac_lib"; then
30869    ac_res="none required"
30870  else
30871    ac_res=-l$ac_lib
30872    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
30873  fi
30874  rm -f conftest.$ac_objext conftest$ac_exeext
30875if { (ac_try="$ac_link"
30876case "(($ac_try" in
30877  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30878  *) ac_try_echo=$ac_try;;
30879esac
30880eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30881  (eval "$ac_link") 2>conftest.er1
30882  ac_status=$?
30883  grep -v '^ *+' conftest.er1 >conftest.err
30884  rm -f conftest.er1
30885  cat conftest.err >&5
30886  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30887  (exit $ac_status); } && {
30888	 test -z "$ac_c_werror_flag" ||
30889	 test ! -s conftest.err
30890       } && test -s conftest$ac_exeext &&
30891       $as_test_x conftest$ac_exeext; then
30892  ac_cv_search_res_query=$ac_res
30893else
30894  echo "$as_me: failed program was:" >&5
30895sed 's/^/| /' conftest.$ac_ext >&5
30896
30897
30898fi
30899
30900rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
30901      conftest$ac_exeext
30902  if test "${ac_cv_search_res_query+set}" = set; then
30903  break
30904fi
30905done
30906if test "${ac_cv_search_res_query+set}" = set; then
30907  :
30908else
30909  ac_cv_search_res_query=no
30910fi
30911rm conftest.$ac_ext
30912LIBS=$ac_func_search_save_LIBS
30913fi
30914{ echo "$as_me:$LINENO: result: $ac_cv_search_res_query" >&5
30915echo "${ECHO_T}$ac_cv_search_res_query" >&6; }
30916ac_res=$ac_cv_search_res_query
30917if test "$ac_res" != no; then
30918  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
30919
30920fi
30921
30922		{ echo "$as_me:$LINENO: checking for library containing dn_expand" >&5
30923echo $ECHO_N "checking for library containing dn_expand... $ECHO_C" >&6; }
30924if test "${ac_cv_search_dn_expand+set}" = set; then
30925  echo $ECHO_N "(cached) $ECHO_C" >&6
30926else
30927  ac_func_search_save_LIBS=$LIBS
30928cat >conftest.$ac_ext <<_ACEOF
30929/* confdefs.h.  */
30930_ACEOF
30931cat confdefs.h >>conftest.$ac_ext
30932cat >>conftest.$ac_ext <<_ACEOF
30933/* end confdefs.h.  */
30934
30935/* Override any GCC internal prototype to avoid an error.
30936   Use char because int might match the return type of a GCC
30937   builtin and then its argument prototype would still apply.  */
30938#ifdef __cplusplus
30939extern "C"
30940#endif
30941char dn_expand ();
30942int
30943main ()
30944{
30945return dn_expand ();
30946  ;
30947  return 0;
30948}
30949_ACEOF
30950for ac_lib in '' resolv; do
30951  if test -z "$ac_lib"; then
30952    ac_res="none required"
30953  else
30954    ac_res=-l$ac_lib
30955    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
30956  fi
30957  rm -f conftest.$ac_objext conftest$ac_exeext
30958if { (ac_try="$ac_link"
30959case "(($ac_try" in
30960  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
30961  *) ac_try_echo=$ac_try;;
30962esac
30963eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
30964  (eval "$ac_link") 2>conftest.er1
30965  ac_status=$?
30966  grep -v '^ *+' conftest.er1 >conftest.err
30967  rm -f conftest.er1
30968  cat conftest.err >&5
30969  echo "$as_me:$LINENO: \$? = $ac_status" >&5
30970  (exit $ac_status); } && {
30971	 test -z "$ac_c_werror_flag" ||
30972	 test ! -s conftest.err
30973       } && test -s conftest$ac_exeext &&
30974       $as_test_x conftest$ac_exeext; then
30975  ac_cv_search_dn_expand=$ac_res
30976else
30977  echo "$as_me: failed program was:" >&5
30978sed 's/^/| /' conftest.$ac_ext >&5
30979
30980
30981fi
30982
30983rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
30984      conftest$ac_exeext
30985  if test "${ac_cv_search_dn_expand+set}" = set; then
30986  break
30987fi
30988done
30989if test "${ac_cv_search_dn_expand+set}" = set; then
30990  :
30991else
30992  ac_cv_search_dn_expand=no
30993fi
30994rm conftest.$ac_ext
30995LIBS=$ac_func_search_save_LIBS
30996fi
30997{ echo "$as_me:$LINENO: result: $ac_cv_search_dn_expand" >&5
30998echo "${ECHO_T}$ac_cv_search_dn_expand" >&6; }
30999ac_res=$ac_cv_search_dn_expand
31000if test "$ac_res" != no; then
31001  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
31002
31003fi
31004
31005		{ echo "$as_me:$LINENO: checking if res_query will link" >&5
31006echo $ECHO_N "checking if res_query will link... $ECHO_C" >&6; }
31007		cat >conftest.$ac_ext <<_ACEOF
31008/* confdefs.h.  */
31009_ACEOF
31010cat confdefs.h >>conftest.$ac_ext
31011cat >>conftest.$ac_ext <<_ACEOF
31012/* end confdefs.h.  */
31013
31014#include <sys/types.h>
31015#include <netinet/in.h>
31016#include <arpa/nameser.h>
31017#include <netdb.h>
31018#include <resolv.h>
31019
31020int
31021main ()
31022{
31023
31024	res_query (0, 0, 0, 0, 0);
31025
31026  ;
31027  return 0;
31028}
31029_ACEOF
31030rm -f conftest.$ac_objext conftest$ac_exeext
31031if { (ac_try="$ac_link"
31032case "(($ac_try" in
31033  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31034  *) ac_try_echo=$ac_try;;
31035esac
31036eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31037  (eval "$ac_link") 2>conftest.er1
31038  ac_status=$?
31039  grep -v '^ *+' conftest.er1 >conftest.err
31040  rm -f conftest.er1
31041  cat conftest.err >&5
31042  echo "$as_me:$LINENO: \$? = $ac_status" >&5
31043  (exit $ac_status); } && {
31044	 test -z "$ac_c_werror_flag" ||
31045	 test ! -s conftest.err
31046       } && test -s conftest$ac_exeext &&
31047       $as_test_x conftest$ac_exeext; then
31048  { echo "$as_me:$LINENO: result: yes" >&5
31049echo "${ECHO_T}yes" >&6; }
31050else
31051  echo "$as_me: failed program was:" >&5
31052sed 's/^/| /' conftest.$ac_ext >&5
31053
31054	{ echo "$as_me:$LINENO: result: no" >&5
31055echo "${ECHO_T}no" >&6; }
31056		    saved_LIBS="$LIBS"
31057		    LIBS="$LIBS -lresolv"
31058		    { echo "$as_me:$LINENO: checking for res_query in -lresolv" >&5
31059echo $ECHO_N "checking for res_query in -lresolv... $ECHO_C" >&6; }
31060		    cat >conftest.$ac_ext <<_ACEOF
31061/* confdefs.h.  */
31062_ACEOF
31063cat confdefs.h >>conftest.$ac_ext
31064cat >>conftest.$ac_ext <<_ACEOF
31065/* end confdefs.h.  */
31066
31067#include <sys/types.h>
31068#include <netinet/in.h>
31069#include <arpa/nameser.h>
31070#include <netdb.h>
31071#include <resolv.h>
31072
31073int
31074main ()
31075{
31076
31077	res_query (0, 0, 0, 0, 0);
31078
31079  ;
31080  return 0;
31081}
31082_ACEOF
31083rm -f conftest.$ac_objext conftest$ac_exeext
31084if { (ac_try="$ac_link"
31085case "(($ac_try" in
31086  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31087  *) ac_try_echo=$ac_try;;
31088esac
31089eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31090  (eval "$ac_link") 2>conftest.er1
31091  ac_status=$?
31092  grep -v '^ *+' conftest.er1 >conftest.err
31093  rm -f conftest.er1
31094  cat conftest.err >&5
31095  echo "$as_me:$LINENO: \$? = $ac_status" >&5
31096  (exit $ac_status); } && {
31097	 test -z "$ac_c_werror_flag" ||
31098	 test ! -s conftest.err
31099       } && test -s conftest$ac_exeext &&
31100       $as_test_x conftest$ac_exeext; then
31101  { echo "$as_me:$LINENO: result: yes" >&5
31102echo "${ECHO_T}yes" >&6; }
31103else
31104  echo "$as_me: failed program was:" >&5
31105sed 's/^/| /' conftest.$ac_ext >&5
31106
31107	LIBS="$saved_LIBS"
31108			 { echo "$as_me:$LINENO: result: no" >&5
31109echo "${ECHO_T}no" >&6; }
31110fi
31111
31112rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
31113      conftest$ac_exeext conftest.$ac_ext
31114
31115fi
31116
31117rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
31118      conftest$ac_exeext conftest.$ac_ext
31119
31120
31121for ac_func in _getshort _getlong
31122do
31123as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
31124{ echo "$as_me:$LINENO: checking for $ac_func" >&5
31125echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
31126if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
31127  echo $ECHO_N "(cached) $ECHO_C" >&6
31128else
31129  cat >conftest.$ac_ext <<_ACEOF
31130/* confdefs.h.  */
31131_ACEOF
31132cat confdefs.h >>conftest.$ac_ext
31133cat >>conftest.$ac_ext <<_ACEOF
31134/* end confdefs.h.  */
31135/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
31136   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
31137#define $ac_func innocuous_$ac_func
31138
31139/* System header to define __stub macros and hopefully few prototypes,
31140    which can conflict with char $ac_func (); below.
31141    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31142    <limits.h> exists even on freestanding compilers.  */
31143
31144#ifdef __STDC__
31145# include <limits.h>
31146#else
31147# include <assert.h>
31148#endif
31149
31150#undef $ac_func
31151
31152/* Override any GCC internal prototype to avoid an error.
31153   Use char because int might match the return type of a GCC
31154   builtin and then its argument prototype would still apply.  */
31155#ifdef __cplusplus
31156extern "C"
31157#endif
31158char $ac_func ();
31159/* The GNU C library defines this for functions which it implements
31160    to always fail with ENOSYS.  Some functions are actually named
31161    something starting with __ and the normal name is an alias.  */
31162#if defined __stub_$ac_func || defined __stub___$ac_func
31163choke me
31164#endif
31165
31166int
31167main ()
31168{
31169return $ac_func ();
31170  ;
31171  return 0;
31172}
31173_ACEOF
31174rm -f conftest.$ac_objext conftest$ac_exeext
31175if { (ac_try="$ac_link"
31176case "(($ac_try" in
31177  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31178  *) ac_try_echo=$ac_try;;
31179esac
31180eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31181  (eval "$ac_link") 2>conftest.er1
31182  ac_status=$?
31183  grep -v '^ *+' conftest.er1 >conftest.err
31184  rm -f conftest.er1
31185  cat conftest.err >&5
31186  echo "$as_me:$LINENO: \$? = $ac_status" >&5
31187  (exit $ac_status); } && {
31188	 test -z "$ac_c_werror_flag" ||
31189	 test ! -s conftest.err
31190       } && test -s conftest$ac_exeext &&
31191       $as_test_x conftest$ac_exeext; then
31192  eval "$as_ac_var=yes"
31193else
31194  echo "$as_me: failed program was:" >&5
31195sed 's/^/| /' conftest.$ac_ext >&5
31196
31197	eval "$as_ac_var=no"
31198fi
31199
31200rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
31201      conftest$ac_exeext conftest.$ac_ext
31202fi
31203ac_res=`eval echo '${'$as_ac_var'}'`
31204	       { echo "$as_me:$LINENO: result: $ac_res" >&5
31205echo "${ECHO_T}$ac_res" >&6; }
31206if test `eval echo '${'$as_ac_var'}'` = yes; then
31207  cat >>confdefs.h <<_ACEOF
31208#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
31209_ACEOF
31210
31211fi
31212done
31213
31214		{ echo "$as_me:$LINENO: checking whether _getshort is declared" >&5
31215echo $ECHO_N "checking whether _getshort is declared... $ECHO_C" >&6; }
31216if test "${ac_cv_have_decl__getshort+set}" = set; then
31217  echo $ECHO_N "(cached) $ECHO_C" >&6
31218else
31219  cat >conftest.$ac_ext <<_ACEOF
31220/* confdefs.h.  */
31221_ACEOF
31222cat confdefs.h >>conftest.$ac_ext
31223cat >>conftest.$ac_ext <<_ACEOF
31224/* end confdefs.h.  */
31225#include <sys/types.h>
31226		    #include <arpa/nameser.h>
31227
31228int
31229main ()
31230{
31231#ifndef _getshort
31232  (void) _getshort;
31233#endif
31234
31235  ;
31236  return 0;
31237}
31238_ACEOF
31239rm -f conftest.$ac_objext
31240if { (ac_try="$ac_compile"
31241case "(($ac_try" in
31242  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31243  *) ac_try_echo=$ac_try;;
31244esac
31245eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31246  (eval "$ac_compile") 2>conftest.er1
31247  ac_status=$?
31248  grep -v '^ *+' conftest.er1 >conftest.err
31249  rm -f conftest.er1
31250  cat conftest.err >&5
31251  echo "$as_me:$LINENO: \$? = $ac_status" >&5
31252  (exit $ac_status); } && {
31253	 test -z "$ac_c_werror_flag" ||
31254	 test ! -s conftest.err
31255       } && test -s conftest.$ac_objext; then
31256  ac_cv_have_decl__getshort=yes
31257else
31258  echo "$as_me: failed program was:" >&5
31259sed 's/^/| /' conftest.$ac_ext >&5
31260
31261	ac_cv_have_decl__getshort=no
31262fi
31263
31264rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31265fi
31266{ echo "$as_me:$LINENO: result: $ac_cv_have_decl__getshort" >&5
31267echo "${ECHO_T}$ac_cv_have_decl__getshort" >&6; }
31268if test $ac_cv_have_decl__getshort = yes; then
31269
31270cat >>confdefs.h <<_ACEOF
31271#define HAVE_DECL__GETSHORT 1
31272_ACEOF
31273
31274
31275else
31276  cat >>confdefs.h <<_ACEOF
31277#define HAVE_DECL__GETSHORT 0
31278_ACEOF
31279
31280
31281fi
31282{ echo "$as_me:$LINENO: checking whether _getlong is declared" >&5
31283echo $ECHO_N "checking whether _getlong is declared... $ECHO_C" >&6; }
31284if test "${ac_cv_have_decl__getlong+set}" = set; then
31285  echo $ECHO_N "(cached) $ECHO_C" >&6
31286else
31287  cat >conftest.$ac_ext <<_ACEOF
31288/* confdefs.h.  */
31289_ACEOF
31290cat confdefs.h >>conftest.$ac_ext
31291cat >>conftest.$ac_ext <<_ACEOF
31292/* end confdefs.h.  */
31293#include <sys/types.h>
31294		    #include <arpa/nameser.h>
31295
31296int
31297main ()
31298{
31299#ifndef _getlong
31300  (void) _getlong;
31301#endif
31302
31303  ;
31304  return 0;
31305}
31306_ACEOF
31307rm -f conftest.$ac_objext
31308if { (ac_try="$ac_compile"
31309case "(($ac_try" in
31310  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31311  *) ac_try_echo=$ac_try;;
31312esac
31313eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31314  (eval "$ac_compile") 2>conftest.er1
31315  ac_status=$?
31316  grep -v '^ *+' conftest.er1 >conftest.err
31317  rm -f conftest.er1
31318  cat conftest.err >&5
31319  echo "$as_me:$LINENO: \$? = $ac_status" >&5
31320  (exit $ac_status); } && {
31321	 test -z "$ac_c_werror_flag" ||
31322	 test ! -s conftest.err
31323       } && test -s conftest.$ac_objext; then
31324  ac_cv_have_decl__getlong=yes
31325else
31326  echo "$as_me: failed program was:" >&5
31327sed 's/^/| /' conftest.$ac_ext >&5
31328
31329	ac_cv_have_decl__getlong=no
31330fi
31331
31332rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31333fi
31334{ echo "$as_me:$LINENO: result: $ac_cv_have_decl__getlong" >&5
31335echo "${ECHO_T}$ac_cv_have_decl__getlong" >&6; }
31336if test $ac_cv_have_decl__getlong = yes; then
31337
31338cat >>confdefs.h <<_ACEOF
31339#define HAVE_DECL__GETLONG 1
31340_ACEOF
31341
31342
31343else
31344  cat >>confdefs.h <<_ACEOF
31345#define HAVE_DECL__GETLONG 0
31346_ACEOF
31347
31348
31349fi
31350
31351
31352		{ echo "$as_me:$LINENO: checking for HEADER.ad" >&5
31353echo $ECHO_N "checking for HEADER.ad... $ECHO_C" >&6; }
31354if test "${ac_cv_member_HEADER_ad+set}" = set; then
31355  echo $ECHO_N "(cached) $ECHO_C" >&6
31356else
31357  cat >conftest.$ac_ext <<_ACEOF
31358/* confdefs.h.  */
31359_ACEOF
31360cat confdefs.h >>conftest.$ac_ext
31361cat >>conftest.$ac_ext <<_ACEOF
31362/* end confdefs.h.  */
31363#include <arpa/nameser.h>
31364
31365int
31366main ()
31367{
31368static HEADER ac_aggr;
31369if (ac_aggr.ad)
31370return 0;
31371  ;
31372  return 0;
31373}
31374_ACEOF
31375rm -f conftest.$ac_objext
31376if { (ac_try="$ac_compile"
31377case "(($ac_try" in
31378  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31379  *) ac_try_echo=$ac_try;;
31380esac
31381eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31382  (eval "$ac_compile") 2>conftest.er1
31383  ac_status=$?
31384  grep -v '^ *+' conftest.er1 >conftest.err
31385  rm -f conftest.er1
31386  cat conftest.err >&5
31387  echo "$as_me:$LINENO: \$? = $ac_status" >&5
31388  (exit $ac_status); } && {
31389	 test -z "$ac_c_werror_flag" ||
31390	 test ! -s conftest.err
31391       } && test -s conftest.$ac_objext; then
31392  ac_cv_member_HEADER_ad=yes
31393else
31394  echo "$as_me: failed program was:" >&5
31395sed 's/^/| /' conftest.$ac_ext >&5
31396
31397	cat >conftest.$ac_ext <<_ACEOF
31398/* confdefs.h.  */
31399_ACEOF
31400cat confdefs.h >>conftest.$ac_ext
31401cat >>conftest.$ac_ext <<_ACEOF
31402/* end confdefs.h.  */
31403#include <arpa/nameser.h>
31404
31405int
31406main ()
31407{
31408static HEADER ac_aggr;
31409if (sizeof ac_aggr.ad)
31410return 0;
31411  ;
31412  return 0;
31413}
31414_ACEOF
31415rm -f conftest.$ac_objext
31416if { (ac_try="$ac_compile"
31417case "(($ac_try" in
31418  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31419  *) ac_try_echo=$ac_try;;
31420esac
31421eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31422  (eval "$ac_compile") 2>conftest.er1
31423  ac_status=$?
31424  grep -v '^ *+' conftest.er1 >conftest.err
31425  rm -f conftest.er1
31426  cat conftest.err >&5
31427  echo "$as_me:$LINENO: \$? = $ac_status" >&5
31428  (exit $ac_status); } && {
31429	 test -z "$ac_c_werror_flag" ||
31430	 test ! -s conftest.err
31431       } && test -s conftest.$ac_objext; then
31432  ac_cv_member_HEADER_ad=yes
31433else
31434  echo "$as_me: failed program was:" >&5
31435sed 's/^/| /' conftest.$ac_ext >&5
31436
31437	ac_cv_member_HEADER_ad=no
31438fi
31439
31440rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31441fi
31442
31443rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31444fi
31445{ echo "$as_me:$LINENO: result: $ac_cv_member_HEADER_ad" >&5
31446echo "${ECHO_T}$ac_cv_member_HEADER_ad" >&6; }
31447if test $ac_cv_member_HEADER_ad = yes; then
31448
31449cat >>confdefs.h <<\_ACEOF
31450#define HAVE_HEADER_AD 1
31451_ACEOF
31452
31453fi
31454
31455
31456fi
31457
31458
31459{ echo "$as_me:$LINENO: checking if struct __res_state _res is an extern" >&5
31460echo $ECHO_N "checking if struct __res_state _res is an extern... $ECHO_C" >&6; }
31461cat >conftest.$ac_ext <<_ACEOF
31462/* confdefs.h.  */
31463_ACEOF
31464cat confdefs.h >>conftest.$ac_ext
31465cat >>conftest.$ac_ext <<_ACEOF
31466/* end confdefs.h.  */
31467
31468#include <stdio.h>
31469#if HAVE_SYS_TYPES_H
31470# include <sys/types.h>
31471#endif
31472#include <netinet/in.h>
31473#include <arpa/nameser.h>
31474#include <resolv.h>
31475extern struct __res_state _res;
31476
31477int
31478main ()
31479{
31480
31481  ;
31482  return 0;
31483}
31484_ACEOF
31485rm -f conftest.$ac_objext conftest$ac_exeext
31486if { (ac_try="$ac_link"
31487case "(($ac_try" in
31488  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31489  *) ac_try_echo=$ac_try;;
31490esac
31491eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31492  (eval "$ac_link") 2>conftest.er1
31493  ac_status=$?
31494  grep -v '^ *+' conftest.er1 >conftest.err
31495  rm -f conftest.er1
31496  cat conftest.err >&5
31497  echo "$as_me:$LINENO: \$? = $ac_status" >&5
31498  (exit $ac_status); } && {
31499	 test -z "$ac_c_werror_flag" ||
31500	 test ! -s conftest.err
31501       } && test -s conftest$ac_exeext &&
31502       $as_test_x conftest$ac_exeext; then
31503  { echo "$as_me:$LINENO: result: yes" >&5
31504echo "${ECHO_T}yes" >&6; }
31505
31506cat >>confdefs.h <<\_ACEOF
31507#define HAVE__RES_EXTERN 1
31508_ACEOF
31509
31510
31511else
31512  echo "$as_me: failed program was:" >&5
31513sed 's/^/| /' conftest.$ac_ext >&5
31514
31515	 { echo "$as_me:$LINENO: result: no" >&5
31516echo "${ECHO_T}no" >&6; }
31517
31518fi
31519
31520rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
31521      conftest$ac_exeext conftest.$ac_ext
31522
31523# Check whether user wants SELinux support
31524SELINUX_MSG="no"
31525LIBSELINUX=""
31526
31527# Check whether --with-selinux was given.
31528if test "${with_selinux+set}" = set; then
31529  withval=$with_selinux;  if test "x$withval" != "xno" ; then
31530		save_LIBS="$LIBS"
31531
31532cat >>confdefs.h <<\_ACEOF
31533#define WITH_SELINUX 1
31534_ACEOF
31535
31536		SELINUX_MSG="yes"
31537		if test "${ac_cv_header_selinux_selinux_h+set}" = set; then
31538  { echo "$as_me:$LINENO: checking for selinux/selinux.h" >&5
31539echo $ECHO_N "checking for selinux/selinux.h... $ECHO_C" >&6; }
31540if test "${ac_cv_header_selinux_selinux_h+set}" = set; then
31541  echo $ECHO_N "(cached) $ECHO_C" >&6
31542fi
31543{ echo "$as_me:$LINENO: result: $ac_cv_header_selinux_selinux_h" >&5
31544echo "${ECHO_T}$ac_cv_header_selinux_selinux_h" >&6; }
31545else
31546  # Is the header compilable?
31547{ echo "$as_me:$LINENO: checking selinux/selinux.h usability" >&5
31548echo $ECHO_N "checking selinux/selinux.h usability... $ECHO_C" >&6; }
31549cat >conftest.$ac_ext <<_ACEOF
31550/* confdefs.h.  */
31551_ACEOF
31552cat confdefs.h >>conftest.$ac_ext
31553cat >>conftest.$ac_ext <<_ACEOF
31554/* end confdefs.h.  */
31555$ac_includes_default
31556#include <selinux/selinux.h>
31557_ACEOF
31558rm -f conftest.$ac_objext
31559if { (ac_try="$ac_compile"
31560case "(($ac_try" in
31561  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31562  *) ac_try_echo=$ac_try;;
31563esac
31564eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31565  (eval "$ac_compile") 2>conftest.er1
31566  ac_status=$?
31567  grep -v '^ *+' conftest.er1 >conftest.err
31568  rm -f conftest.er1
31569  cat conftest.err >&5
31570  echo "$as_me:$LINENO: \$? = $ac_status" >&5
31571  (exit $ac_status); } && {
31572	 test -z "$ac_c_werror_flag" ||
31573	 test ! -s conftest.err
31574       } && test -s conftest.$ac_objext; then
31575  ac_header_compiler=yes
31576else
31577  echo "$as_me: failed program was:" >&5
31578sed 's/^/| /' conftest.$ac_ext >&5
31579
31580	ac_header_compiler=no
31581fi
31582
31583rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31584{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
31585echo "${ECHO_T}$ac_header_compiler" >&6; }
31586
31587# Is the header present?
31588{ echo "$as_me:$LINENO: checking selinux/selinux.h presence" >&5
31589echo $ECHO_N "checking selinux/selinux.h presence... $ECHO_C" >&6; }
31590cat >conftest.$ac_ext <<_ACEOF
31591/* confdefs.h.  */
31592_ACEOF
31593cat confdefs.h >>conftest.$ac_ext
31594cat >>conftest.$ac_ext <<_ACEOF
31595/* end confdefs.h.  */
31596#include <selinux/selinux.h>
31597_ACEOF
31598if { (ac_try="$ac_cpp conftest.$ac_ext"
31599case "(($ac_try" in
31600  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31601  *) ac_try_echo=$ac_try;;
31602esac
31603eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31604  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
31605  ac_status=$?
31606  grep -v '^ *+' conftest.er1 >conftest.err
31607  rm -f conftest.er1
31608  cat conftest.err >&5
31609  echo "$as_me:$LINENO: \$? = $ac_status" >&5
31610  (exit $ac_status); } >/dev/null && {
31611	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
31612	 test ! -s conftest.err
31613       }; then
31614  ac_header_preproc=yes
31615else
31616  echo "$as_me: failed program was:" >&5
31617sed 's/^/| /' conftest.$ac_ext >&5
31618
31619  ac_header_preproc=no
31620fi
31621
31622rm -f conftest.err conftest.$ac_ext
31623{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
31624echo "${ECHO_T}$ac_header_preproc" >&6; }
31625
31626# So?  What about this header?
31627case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
31628  yes:no: )
31629    { echo "$as_me:$LINENO: WARNING: selinux/selinux.h: accepted by the compiler, rejected by the preprocessor!" >&5
31630echo "$as_me: WARNING: selinux/selinux.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
31631    { echo "$as_me:$LINENO: WARNING: selinux/selinux.h: proceeding with the compiler's result" >&5
31632echo "$as_me: WARNING: selinux/selinux.h: proceeding with the compiler's result" >&2;}
31633    ac_header_preproc=yes
31634    ;;
31635  no:yes:* )
31636    { echo "$as_me:$LINENO: WARNING: selinux/selinux.h: present but cannot be compiled" >&5
31637echo "$as_me: WARNING: selinux/selinux.h: present but cannot be compiled" >&2;}
31638    { echo "$as_me:$LINENO: WARNING: selinux/selinux.h:     check for missing prerequisite headers?" >&5
31639echo "$as_me: WARNING: selinux/selinux.h:     check for missing prerequisite headers?" >&2;}
31640    { echo "$as_me:$LINENO: WARNING: selinux/selinux.h: see the Autoconf documentation" >&5
31641echo "$as_me: WARNING: selinux/selinux.h: see the Autoconf documentation" >&2;}
31642    { echo "$as_me:$LINENO: WARNING: selinux/selinux.h:     section \"Present But Cannot Be Compiled\"" >&5
31643echo "$as_me: WARNING: selinux/selinux.h:     section \"Present But Cannot Be Compiled\"" >&2;}
31644    { echo "$as_me:$LINENO: WARNING: selinux/selinux.h: proceeding with the preprocessor's result" >&5
31645echo "$as_me: WARNING: selinux/selinux.h: proceeding with the preprocessor's result" >&2;}
31646    { echo "$as_me:$LINENO: WARNING: selinux/selinux.h: in the future, the compiler will take precedence" >&5
31647echo "$as_me: WARNING: selinux/selinux.h: in the future, the compiler will take precedence" >&2;}
31648    ( cat <<\_ASBOX
31649## ------------------------------------------- ##
31650## Report this to openssh-unix-dev@mindrot.org ##
31651## ------------------------------------------- ##
31652_ASBOX
31653     ) | sed "s/^/$as_me: WARNING:     /" >&2
31654    ;;
31655esac
31656{ echo "$as_me:$LINENO: checking for selinux/selinux.h" >&5
31657echo $ECHO_N "checking for selinux/selinux.h... $ECHO_C" >&6; }
31658if test "${ac_cv_header_selinux_selinux_h+set}" = set; then
31659  echo $ECHO_N "(cached) $ECHO_C" >&6
31660else
31661  ac_cv_header_selinux_selinux_h=$ac_header_preproc
31662fi
31663{ echo "$as_me:$LINENO: result: $ac_cv_header_selinux_selinux_h" >&5
31664echo "${ECHO_T}$ac_cv_header_selinux_selinux_h" >&6; }
31665
31666fi
31667if test $ac_cv_header_selinux_selinux_h = yes; then
31668  :
31669else
31670  { { echo "$as_me:$LINENO: error: SELinux support requires selinux.h header" >&5
31671echo "$as_me: error: SELinux support requires selinux.h header" >&2;}
31672   { (exit 1); exit 1; }; }
31673fi
31674
31675
31676		{ echo "$as_me:$LINENO: checking for setexeccon in -lselinux" >&5
31677echo $ECHO_N "checking for setexeccon in -lselinux... $ECHO_C" >&6; }
31678if test "${ac_cv_lib_selinux_setexeccon+set}" = set; then
31679  echo $ECHO_N "(cached) $ECHO_C" >&6
31680else
31681  ac_check_lib_save_LIBS=$LIBS
31682LIBS="-lselinux  $LIBS"
31683cat >conftest.$ac_ext <<_ACEOF
31684/* confdefs.h.  */
31685_ACEOF
31686cat confdefs.h >>conftest.$ac_ext
31687cat >>conftest.$ac_ext <<_ACEOF
31688/* end confdefs.h.  */
31689
31690/* Override any GCC internal prototype to avoid an error.
31691   Use char because int might match the return type of a GCC
31692   builtin and then its argument prototype would still apply.  */
31693#ifdef __cplusplus
31694extern "C"
31695#endif
31696char setexeccon ();
31697int
31698main ()
31699{
31700return setexeccon ();
31701  ;
31702  return 0;
31703}
31704_ACEOF
31705rm -f conftest.$ac_objext conftest$ac_exeext
31706if { (ac_try="$ac_link"
31707case "(($ac_try" in
31708  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31709  *) ac_try_echo=$ac_try;;
31710esac
31711eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31712  (eval "$ac_link") 2>conftest.er1
31713  ac_status=$?
31714  grep -v '^ *+' conftest.er1 >conftest.err
31715  rm -f conftest.er1
31716  cat conftest.err >&5
31717  echo "$as_me:$LINENO: \$? = $ac_status" >&5
31718  (exit $ac_status); } && {
31719	 test -z "$ac_c_werror_flag" ||
31720	 test ! -s conftest.err
31721       } && test -s conftest$ac_exeext &&
31722       $as_test_x conftest$ac_exeext; then
31723  ac_cv_lib_selinux_setexeccon=yes
31724else
31725  echo "$as_me: failed program was:" >&5
31726sed 's/^/| /' conftest.$ac_ext >&5
31727
31728	ac_cv_lib_selinux_setexeccon=no
31729fi
31730
31731rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
31732      conftest$ac_exeext conftest.$ac_ext
31733LIBS=$ac_check_lib_save_LIBS
31734fi
31735{ echo "$as_me:$LINENO: result: $ac_cv_lib_selinux_setexeccon" >&5
31736echo "${ECHO_T}$ac_cv_lib_selinux_setexeccon" >&6; }
31737if test $ac_cv_lib_selinux_setexeccon = yes; then
31738   LIBSELINUX="-lselinux"
31739			  LIBS="$LIBS -lselinux"
31740
31741else
31742  { { echo "$as_me:$LINENO: error: SELinux support requires libselinux library" >&5
31743echo "$as_me: error: SELinux support requires libselinux library" >&2;}
31744   { (exit 1); exit 1; }; }
31745fi
31746
31747		SSHLIBS="$SSHLIBS $LIBSELINUX"
31748		SSHDLIBS="$SSHDLIBS $LIBSELINUX"
31749
31750
31751for ac_func in getseuserbyname get_default_context_with_level
31752do
31753as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
31754{ echo "$as_me:$LINENO: checking for $ac_func" >&5
31755echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
31756if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
31757  echo $ECHO_N "(cached) $ECHO_C" >&6
31758else
31759  cat >conftest.$ac_ext <<_ACEOF
31760/* confdefs.h.  */
31761_ACEOF
31762cat confdefs.h >>conftest.$ac_ext
31763cat >>conftest.$ac_ext <<_ACEOF
31764/* end confdefs.h.  */
31765/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
31766   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
31767#define $ac_func innocuous_$ac_func
31768
31769/* System header to define __stub macros and hopefully few prototypes,
31770    which can conflict with char $ac_func (); below.
31771    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
31772    <limits.h> exists even on freestanding compilers.  */
31773
31774#ifdef __STDC__
31775# include <limits.h>
31776#else
31777# include <assert.h>
31778#endif
31779
31780#undef $ac_func
31781
31782/* Override any GCC internal prototype to avoid an error.
31783   Use char because int might match the return type of a GCC
31784   builtin and then its argument prototype would still apply.  */
31785#ifdef __cplusplus
31786extern "C"
31787#endif
31788char $ac_func ();
31789/* The GNU C library defines this for functions which it implements
31790    to always fail with ENOSYS.  Some functions are actually named
31791    something starting with __ and the normal name is an alias.  */
31792#if defined __stub_$ac_func || defined __stub___$ac_func
31793choke me
31794#endif
31795
31796int
31797main ()
31798{
31799return $ac_func ();
31800  ;
31801  return 0;
31802}
31803_ACEOF
31804rm -f conftest.$ac_objext conftest$ac_exeext
31805if { (ac_try="$ac_link"
31806case "(($ac_try" in
31807  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31808  *) ac_try_echo=$ac_try;;
31809esac
31810eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31811  (eval "$ac_link") 2>conftest.er1
31812  ac_status=$?
31813  grep -v '^ *+' conftest.er1 >conftest.err
31814  rm -f conftest.er1
31815  cat conftest.err >&5
31816  echo "$as_me:$LINENO: \$? = $ac_status" >&5
31817  (exit $ac_status); } && {
31818	 test -z "$ac_c_werror_flag" ||
31819	 test ! -s conftest.err
31820       } && test -s conftest$ac_exeext &&
31821       $as_test_x conftest$ac_exeext; then
31822  eval "$as_ac_var=yes"
31823else
31824  echo "$as_me: failed program was:" >&5
31825sed 's/^/| /' conftest.$ac_ext >&5
31826
31827	eval "$as_ac_var=no"
31828fi
31829
31830rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
31831      conftest$ac_exeext conftest.$ac_ext
31832fi
31833ac_res=`eval echo '${'$as_ac_var'}'`
31834	       { echo "$as_me:$LINENO: result: $ac_res" >&5
31835echo "${ECHO_T}$ac_res" >&6; }
31836if test `eval echo '${'$as_ac_var'}'` = yes; then
31837  cat >>confdefs.h <<_ACEOF
31838#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
31839_ACEOF
31840
31841fi
31842done
31843
31844		LIBS="$save_LIBS"
31845	fi
31846
31847fi
31848
31849
31850
31851
31852# Check whether user wants Kerberos 5 support
31853KRB5_MSG="no"
31854
31855# Check whether --with-kerberos5 was given.
31856if test "${with_kerberos5+set}" = set; then
31857  withval=$with_kerberos5;  if test "x$withval" != "xno" ; then
31858		if test "x$withval" = "xyes" ; then
31859			KRB5ROOT="/usr/local"
31860		else
31861			KRB5ROOT=${withval}
31862		fi
31863
31864
31865cat >>confdefs.h <<\_ACEOF
31866#define KRB5 1
31867_ACEOF
31868
31869		KRB5_MSG="yes"
31870
31871		# Extract the first word of "krb5-config", so it can be a program name with args.
31872set dummy krb5-config; ac_word=$2
31873{ echo "$as_me:$LINENO: checking for $ac_word" >&5
31874echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
31875if test "${ac_cv_path_KRB5CONF+set}" = set; then
31876  echo $ECHO_N "(cached) $ECHO_C" >&6
31877else
31878  case $KRB5CONF in
31879  [\\/]* | ?:[\\/]*)
31880  ac_cv_path_KRB5CONF="$KRB5CONF" # Let the user override the test with a path.
31881  ;;
31882  *)
31883  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
31884as_dummy="$KRB5ROOT/bin:$PATH"
31885for as_dir in $as_dummy
31886do
31887  IFS=$as_save_IFS
31888  test -z "$as_dir" && as_dir=.
31889  for ac_exec_ext in '' $ac_executable_extensions; do
31890  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
31891    ac_cv_path_KRB5CONF="$as_dir/$ac_word$ac_exec_ext"
31892    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
31893    break 2
31894  fi
31895done
31896done
31897IFS=$as_save_IFS
31898
31899  test -z "$ac_cv_path_KRB5CONF" && ac_cv_path_KRB5CONF="$KRB5ROOT/bin/krb5-config"
31900  ;;
31901esac
31902fi
31903KRB5CONF=$ac_cv_path_KRB5CONF
31904if test -n "$KRB5CONF"; then
31905  { echo "$as_me:$LINENO: result: $KRB5CONF" >&5
31906echo "${ECHO_T}$KRB5CONF" >&6; }
31907else
31908  { echo "$as_me:$LINENO: result: no" >&5
31909echo "${ECHO_T}no" >&6; }
31910fi
31911
31912
31913		if test -x $KRB5CONF ; then
31914			K5CFLAGS="`$KRB5CONF --cflags`"
31915			K5LIBS="`$KRB5CONF --libs`"
31916			CPPFLAGS="$CPPFLAGS $K5CFLAGS"
31917
31918			{ echo "$as_me:$LINENO: checking for gssapi support" >&5
31919echo $ECHO_N "checking for gssapi support... $ECHO_C" >&6; }
31920			if $KRB5CONF | grep gssapi >/dev/null ; then
31921				{ echo "$as_me:$LINENO: result: yes" >&5
31922echo "${ECHO_T}yes" >&6; }
31923
31924cat >>confdefs.h <<\_ACEOF
31925#define GSSAPI 1
31926_ACEOF
31927
31928				GSSCFLAGS="`$KRB5CONF --cflags gssapi`"
31929				GSSLIBS="`$KRB5CONF --libs gssapi`"
31930				CPPFLAGS="$CPPFLAGS $GSSCFLAGS"
31931			else
31932				{ echo "$as_me:$LINENO: result: no" >&5
31933echo "${ECHO_T}no" >&6; }
31934			fi
31935			{ echo "$as_me:$LINENO: checking whether we are using Heimdal" >&5
31936echo $ECHO_N "checking whether we are using Heimdal... $ECHO_C" >&6; }
31937			cat >conftest.$ac_ext <<_ACEOF
31938/* confdefs.h.  */
31939_ACEOF
31940cat confdefs.h >>conftest.$ac_ext
31941cat >>conftest.$ac_ext <<_ACEOF
31942/* end confdefs.h.  */
31943 #include <krb5.h>
31944
31945int
31946main ()
31947{
31948 char *tmp = heimdal_version;
31949  ;
31950  return 0;
31951}
31952_ACEOF
31953rm -f conftest.$ac_objext
31954if { (ac_try="$ac_compile"
31955case "(($ac_try" in
31956  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
31957  *) ac_try_echo=$ac_try;;
31958esac
31959eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
31960  (eval "$ac_compile") 2>conftest.er1
31961  ac_status=$?
31962  grep -v '^ *+' conftest.er1 >conftest.err
31963  rm -f conftest.er1
31964  cat conftest.err >&5
31965  echo "$as_me:$LINENO: \$? = $ac_status" >&5
31966  (exit $ac_status); } && {
31967	 test -z "$ac_c_werror_flag" ||
31968	 test ! -s conftest.err
31969       } && test -s conftest.$ac_objext; then
31970   { echo "$as_me:$LINENO: result: yes" >&5
31971echo "${ECHO_T}yes" >&6; }
31972
31973cat >>confdefs.h <<\_ACEOF
31974#define HEIMDAL 1
31975_ACEOF
31976
31977else
31978  echo "$as_me: failed program was:" >&5
31979sed 's/^/| /' conftest.$ac_ext >&5
31980
31981	{ echo "$as_me:$LINENO: result: no" >&5
31982echo "${ECHO_T}no" >&6; }
31983
31984fi
31985
31986rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
31987		else
31988			CPPFLAGS="$CPPFLAGS -I${KRB5ROOT}/include"
31989			LDFLAGS="$LDFLAGS -L${KRB5ROOT}/lib"
31990			{ echo "$as_me:$LINENO: checking whether we are using Heimdal" >&5
31991echo $ECHO_N "checking whether we are using Heimdal... $ECHO_C" >&6; }
31992			cat >conftest.$ac_ext <<_ACEOF
31993/* confdefs.h.  */
31994_ACEOF
31995cat confdefs.h >>conftest.$ac_ext
31996cat >>conftest.$ac_ext <<_ACEOF
31997/* end confdefs.h.  */
31998 #include <krb5.h>
31999
32000int
32001main ()
32002{
32003 char *tmp = heimdal_version;
32004  ;
32005  return 0;
32006}
32007_ACEOF
32008rm -f conftest.$ac_objext
32009if { (ac_try="$ac_compile"
32010case "(($ac_try" in
32011  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32012  *) ac_try_echo=$ac_try;;
32013esac
32014eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32015  (eval "$ac_compile") 2>conftest.er1
32016  ac_status=$?
32017  grep -v '^ *+' conftest.er1 >conftest.err
32018  rm -f conftest.er1
32019  cat conftest.err >&5
32020  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32021  (exit $ac_status); } && {
32022	 test -z "$ac_c_werror_flag" ||
32023	 test ! -s conftest.err
32024       } && test -s conftest.$ac_objext; then
32025   { echo "$as_me:$LINENO: result: yes" >&5
32026echo "${ECHO_T}yes" >&6; }
32027					 cat >>confdefs.h <<\_ACEOF
32028#define HEIMDAL 1
32029_ACEOF
32030
32031					 K5LIBS="-lkrb5"
32032					 K5LIBS="$K5LIBS -lcom_err -lasn1"
32033					 { echo "$as_me:$LINENO: checking for net_write in -lroken" >&5
32034echo $ECHO_N "checking for net_write in -lroken... $ECHO_C" >&6; }
32035if test "${ac_cv_lib_roken_net_write+set}" = set; then
32036  echo $ECHO_N "(cached) $ECHO_C" >&6
32037else
32038  ac_check_lib_save_LIBS=$LIBS
32039LIBS="-lroken  $LIBS"
32040cat >conftest.$ac_ext <<_ACEOF
32041/* confdefs.h.  */
32042_ACEOF
32043cat confdefs.h >>conftest.$ac_ext
32044cat >>conftest.$ac_ext <<_ACEOF
32045/* end confdefs.h.  */
32046
32047/* Override any GCC internal prototype to avoid an error.
32048   Use char because int might match the return type of a GCC
32049   builtin and then its argument prototype would still apply.  */
32050#ifdef __cplusplus
32051extern "C"
32052#endif
32053char net_write ();
32054int
32055main ()
32056{
32057return net_write ();
32058  ;
32059  return 0;
32060}
32061_ACEOF
32062rm -f conftest.$ac_objext conftest$ac_exeext
32063if { (ac_try="$ac_link"
32064case "(($ac_try" in
32065  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32066  *) ac_try_echo=$ac_try;;
32067esac
32068eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32069  (eval "$ac_link") 2>conftest.er1
32070  ac_status=$?
32071  grep -v '^ *+' conftest.er1 >conftest.err
32072  rm -f conftest.er1
32073  cat conftest.err >&5
32074  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32075  (exit $ac_status); } && {
32076	 test -z "$ac_c_werror_flag" ||
32077	 test ! -s conftest.err
32078       } && test -s conftest$ac_exeext &&
32079       $as_test_x conftest$ac_exeext; then
32080  ac_cv_lib_roken_net_write=yes
32081else
32082  echo "$as_me: failed program was:" >&5
32083sed 's/^/| /' conftest.$ac_ext >&5
32084
32085	ac_cv_lib_roken_net_write=no
32086fi
32087
32088rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
32089      conftest$ac_exeext conftest.$ac_ext
32090LIBS=$ac_check_lib_save_LIBS
32091fi
32092{ echo "$as_me:$LINENO: result: $ac_cv_lib_roken_net_write" >&5
32093echo "${ECHO_T}$ac_cv_lib_roken_net_write" >&6; }
32094if test $ac_cv_lib_roken_net_write = yes; then
32095  K5LIBS="$K5LIBS -lroken"
32096fi
32097
32098					 { echo "$as_me:$LINENO: checking for des_cbc_encrypt in -ldes" >&5
32099echo $ECHO_N "checking for des_cbc_encrypt in -ldes... $ECHO_C" >&6; }
32100if test "${ac_cv_lib_des_des_cbc_encrypt+set}" = set; then
32101  echo $ECHO_N "(cached) $ECHO_C" >&6
32102else
32103  ac_check_lib_save_LIBS=$LIBS
32104LIBS="-ldes  $LIBS"
32105cat >conftest.$ac_ext <<_ACEOF
32106/* confdefs.h.  */
32107_ACEOF
32108cat confdefs.h >>conftest.$ac_ext
32109cat >>conftest.$ac_ext <<_ACEOF
32110/* end confdefs.h.  */
32111
32112/* Override any GCC internal prototype to avoid an error.
32113   Use char because int might match the return type of a GCC
32114   builtin and then its argument prototype would still apply.  */
32115#ifdef __cplusplus
32116extern "C"
32117#endif
32118char des_cbc_encrypt ();
32119int
32120main ()
32121{
32122return des_cbc_encrypt ();
32123  ;
32124  return 0;
32125}
32126_ACEOF
32127rm -f conftest.$ac_objext conftest$ac_exeext
32128if { (ac_try="$ac_link"
32129case "(($ac_try" in
32130  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32131  *) ac_try_echo=$ac_try;;
32132esac
32133eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32134  (eval "$ac_link") 2>conftest.er1
32135  ac_status=$?
32136  grep -v '^ *+' conftest.er1 >conftest.err
32137  rm -f conftest.er1
32138  cat conftest.err >&5
32139  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32140  (exit $ac_status); } && {
32141	 test -z "$ac_c_werror_flag" ||
32142	 test ! -s conftest.err
32143       } && test -s conftest$ac_exeext &&
32144       $as_test_x conftest$ac_exeext; then
32145  ac_cv_lib_des_des_cbc_encrypt=yes
32146else
32147  echo "$as_me: failed program was:" >&5
32148sed 's/^/| /' conftest.$ac_ext >&5
32149
32150	ac_cv_lib_des_des_cbc_encrypt=no
32151fi
32152
32153rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
32154      conftest$ac_exeext conftest.$ac_ext
32155LIBS=$ac_check_lib_save_LIBS
32156fi
32157{ echo "$as_me:$LINENO: result: $ac_cv_lib_des_des_cbc_encrypt" >&5
32158echo "${ECHO_T}$ac_cv_lib_des_des_cbc_encrypt" >&6; }
32159if test $ac_cv_lib_des_des_cbc_encrypt = yes; then
32160  K5LIBS="$K5LIBS -ldes"
32161fi
32162
32163
32164else
32165  echo "$as_me: failed program was:" >&5
32166sed 's/^/| /' conftest.$ac_ext >&5
32167
32168	 { echo "$as_me:$LINENO: result: no" >&5
32169echo "${ECHO_T}no" >&6; }
32170					 K5LIBS="-lkrb5 -lk5crypto -lcom_err"
32171
32172
32173fi
32174
32175rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32176			{ echo "$as_me:$LINENO: checking for library containing dn_expand" >&5
32177echo $ECHO_N "checking for library containing dn_expand... $ECHO_C" >&6; }
32178if test "${ac_cv_search_dn_expand+set}" = set; then
32179  echo $ECHO_N "(cached) $ECHO_C" >&6
32180else
32181  ac_func_search_save_LIBS=$LIBS
32182cat >conftest.$ac_ext <<_ACEOF
32183/* confdefs.h.  */
32184_ACEOF
32185cat confdefs.h >>conftest.$ac_ext
32186cat >>conftest.$ac_ext <<_ACEOF
32187/* end confdefs.h.  */
32188
32189/* Override any GCC internal prototype to avoid an error.
32190   Use char because int might match the return type of a GCC
32191   builtin and then its argument prototype would still apply.  */
32192#ifdef __cplusplus
32193extern "C"
32194#endif
32195char dn_expand ();
32196int
32197main ()
32198{
32199return dn_expand ();
32200  ;
32201  return 0;
32202}
32203_ACEOF
32204for ac_lib in '' resolv; do
32205  if test -z "$ac_lib"; then
32206    ac_res="none required"
32207  else
32208    ac_res=-l$ac_lib
32209    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
32210  fi
32211  rm -f conftest.$ac_objext conftest$ac_exeext
32212if { (ac_try="$ac_link"
32213case "(($ac_try" in
32214  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32215  *) ac_try_echo=$ac_try;;
32216esac
32217eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32218  (eval "$ac_link") 2>conftest.er1
32219  ac_status=$?
32220  grep -v '^ *+' conftest.er1 >conftest.err
32221  rm -f conftest.er1
32222  cat conftest.err >&5
32223  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32224  (exit $ac_status); } && {
32225	 test -z "$ac_c_werror_flag" ||
32226	 test ! -s conftest.err
32227       } && test -s conftest$ac_exeext &&
32228       $as_test_x conftest$ac_exeext; then
32229  ac_cv_search_dn_expand=$ac_res
32230else
32231  echo "$as_me: failed program was:" >&5
32232sed 's/^/| /' conftest.$ac_ext >&5
32233
32234
32235fi
32236
32237rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
32238      conftest$ac_exeext
32239  if test "${ac_cv_search_dn_expand+set}" = set; then
32240  break
32241fi
32242done
32243if test "${ac_cv_search_dn_expand+set}" = set; then
32244  :
32245else
32246  ac_cv_search_dn_expand=no
32247fi
32248rm conftest.$ac_ext
32249LIBS=$ac_func_search_save_LIBS
32250fi
32251{ echo "$as_me:$LINENO: result: $ac_cv_search_dn_expand" >&5
32252echo "${ECHO_T}$ac_cv_search_dn_expand" >&6; }
32253ac_res=$ac_cv_search_dn_expand
32254if test "$ac_res" != no; then
32255  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
32256
32257fi
32258
32259
32260			{ echo "$as_me:$LINENO: checking for gss_init_sec_context in -lgssapi_krb5" >&5
32261echo $ECHO_N "checking for gss_init_sec_context in -lgssapi_krb5... $ECHO_C" >&6; }
32262if test "${ac_cv_lib_gssapi_krb5_gss_init_sec_context+set}" = set; then
32263  echo $ECHO_N "(cached) $ECHO_C" >&6
32264else
32265  ac_check_lib_save_LIBS=$LIBS
32266LIBS="-lgssapi_krb5  $LIBS"
32267cat >conftest.$ac_ext <<_ACEOF
32268/* confdefs.h.  */
32269_ACEOF
32270cat confdefs.h >>conftest.$ac_ext
32271cat >>conftest.$ac_ext <<_ACEOF
32272/* end confdefs.h.  */
32273
32274/* Override any GCC internal prototype to avoid an error.
32275   Use char because int might match the return type of a GCC
32276   builtin and then its argument prototype would still apply.  */
32277#ifdef __cplusplus
32278extern "C"
32279#endif
32280char gss_init_sec_context ();
32281int
32282main ()
32283{
32284return gss_init_sec_context ();
32285  ;
32286  return 0;
32287}
32288_ACEOF
32289rm -f conftest.$ac_objext conftest$ac_exeext
32290if { (ac_try="$ac_link"
32291case "(($ac_try" in
32292  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32293  *) ac_try_echo=$ac_try;;
32294esac
32295eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32296  (eval "$ac_link") 2>conftest.er1
32297  ac_status=$?
32298  grep -v '^ *+' conftest.er1 >conftest.err
32299  rm -f conftest.er1
32300  cat conftest.err >&5
32301  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32302  (exit $ac_status); } && {
32303	 test -z "$ac_c_werror_flag" ||
32304	 test ! -s conftest.err
32305       } && test -s conftest$ac_exeext &&
32306       $as_test_x conftest$ac_exeext; then
32307  ac_cv_lib_gssapi_krb5_gss_init_sec_context=yes
32308else
32309  echo "$as_me: failed program was:" >&5
32310sed 's/^/| /' conftest.$ac_ext >&5
32311
32312	ac_cv_lib_gssapi_krb5_gss_init_sec_context=no
32313fi
32314
32315rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
32316      conftest$ac_exeext conftest.$ac_ext
32317LIBS=$ac_check_lib_save_LIBS
32318fi
32319{ echo "$as_me:$LINENO: result: $ac_cv_lib_gssapi_krb5_gss_init_sec_context" >&5
32320echo "${ECHO_T}$ac_cv_lib_gssapi_krb5_gss_init_sec_context" >&6; }
32321if test $ac_cv_lib_gssapi_krb5_gss_init_sec_context = yes; then
32322   cat >>confdefs.h <<\_ACEOF
32323#define GSSAPI 1
32324_ACEOF
32325
32326				  GSSLIBS="-lgssapi_krb5"
32327else
32328   { echo "$as_me:$LINENO: checking for gss_init_sec_context in -lgssapi" >&5
32329echo $ECHO_N "checking for gss_init_sec_context in -lgssapi... $ECHO_C" >&6; }
32330if test "${ac_cv_lib_gssapi_gss_init_sec_context+set}" = set; then
32331  echo $ECHO_N "(cached) $ECHO_C" >&6
32332else
32333  ac_check_lib_save_LIBS=$LIBS
32334LIBS="-lgssapi  $LIBS"
32335cat >conftest.$ac_ext <<_ACEOF
32336/* confdefs.h.  */
32337_ACEOF
32338cat confdefs.h >>conftest.$ac_ext
32339cat >>conftest.$ac_ext <<_ACEOF
32340/* end confdefs.h.  */
32341
32342/* Override any GCC internal prototype to avoid an error.
32343   Use char because int might match the return type of a GCC
32344   builtin and then its argument prototype would still apply.  */
32345#ifdef __cplusplus
32346extern "C"
32347#endif
32348char gss_init_sec_context ();
32349int
32350main ()
32351{
32352return gss_init_sec_context ();
32353  ;
32354  return 0;
32355}
32356_ACEOF
32357rm -f conftest.$ac_objext conftest$ac_exeext
32358if { (ac_try="$ac_link"
32359case "(($ac_try" in
32360  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32361  *) ac_try_echo=$ac_try;;
32362esac
32363eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32364  (eval "$ac_link") 2>conftest.er1
32365  ac_status=$?
32366  grep -v '^ *+' conftest.er1 >conftest.err
32367  rm -f conftest.er1
32368  cat conftest.err >&5
32369  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32370  (exit $ac_status); } && {
32371	 test -z "$ac_c_werror_flag" ||
32372	 test ! -s conftest.err
32373       } && test -s conftest$ac_exeext &&
32374       $as_test_x conftest$ac_exeext; then
32375  ac_cv_lib_gssapi_gss_init_sec_context=yes
32376else
32377  echo "$as_me: failed program was:" >&5
32378sed 's/^/| /' conftest.$ac_ext >&5
32379
32380	ac_cv_lib_gssapi_gss_init_sec_context=no
32381fi
32382
32383rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
32384      conftest$ac_exeext conftest.$ac_ext
32385LIBS=$ac_check_lib_save_LIBS
32386fi
32387{ echo "$as_me:$LINENO: result: $ac_cv_lib_gssapi_gss_init_sec_context" >&5
32388echo "${ECHO_T}$ac_cv_lib_gssapi_gss_init_sec_context" >&6; }
32389if test $ac_cv_lib_gssapi_gss_init_sec_context = yes; then
32390   cat >>confdefs.h <<\_ACEOF
32391#define GSSAPI 1
32392_ACEOF
32393
32394					  GSSLIBS="-lgssapi"
32395else
32396   { echo "$as_me:$LINENO: checking for gss_init_sec_context in -lgss" >&5
32397echo $ECHO_N "checking for gss_init_sec_context in -lgss... $ECHO_C" >&6; }
32398if test "${ac_cv_lib_gss_gss_init_sec_context+set}" = set; then
32399  echo $ECHO_N "(cached) $ECHO_C" >&6
32400else
32401  ac_check_lib_save_LIBS=$LIBS
32402LIBS="-lgss  $LIBS"
32403cat >conftest.$ac_ext <<_ACEOF
32404/* confdefs.h.  */
32405_ACEOF
32406cat confdefs.h >>conftest.$ac_ext
32407cat >>conftest.$ac_ext <<_ACEOF
32408/* end confdefs.h.  */
32409
32410/* Override any GCC internal prototype to avoid an error.
32411   Use char because int might match the return type of a GCC
32412   builtin and then its argument prototype would still apply.  */
32413#ifdef __cplusplus
32414extern "C"
32415#endif
32416char gss_init_sec_context ();
32417int
32418main ()
32419{
32420return gss_init_sec_context ();
32421  ;
32422  return 0;
32423}
32424_ACEOF
32425rm -f conftest.$ac_objext conftest$ac_exeext
32426if { (ac_try="$ac_link"
32427case "(($ac_try" in
32428  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32429  *) ac_try_echo=$ac_try;;
32430esac
32431eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32432  (eval "$ac_link") 2>conftest.er1
32433  ac_status=$?
32434  grep -v '^ *+' conftest.er1 >conftest.err
32435  rm -f conftest.er1
32436  cat conftest.err >&5
32437  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32438  (exit $ac_status); } && {
32439	 test -z "$ac_c_werror_flag" ||
32440	 test ! -s conftest.err
32441       } && test -s conftest$ac_exeext &&
32442       $as_test_x conftest$ac_exeext; then
32443  ac_cv_lib_gss_gss_init_sec_context=yes
32444else
32445  echo "$as_me: failed program was:" >&5
32446sed 's/^/| /' conftest.$ac_ext >&5
32447
32448	ac_cv_lib_gss_gss_init_sec_context=no
32449fi
32450
32451rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
32452      conftest$ac_exeext conftest.$ac_ext
32453LIBS=$ac_check_lib_save_LIBS
32454fi
32455{ echo "$as_me:$LINENO: result: $ac_cv_lib_gss_gss_init_sec_context" >&5
32456echo "${ECHO_T}$ac_cv_lib_gss_gss_init_sec_context" >&6; }
32457if test $ac_cv_lib_gss_gss_init_sec_context = yes; then
32458   cat >>confdefs.h <<\_ACEOF
32459#define GSSAPI 1
32460_ACEOF
32461
32462						  GSSLIBS="-lgss"
32463else
32464  { echo "$as_me:$LINENO: WARNING: Cannot find any suitable gss-api library - build may fail" >&5
32465echo "$as_me: WARNING: Cannot find any suitable gss-api library - build may fail" >&2;}
32466fi
32467
32468
32469fi
32470
32471
32472fi
32473
32474
32475			if test "${ac_cv_header_gssapi_h+set}" = set; then
32476  { echo "$as_me:$LINENO: checking for gssapi.h" >&5
32477echo $ECHO_N "checking for gssapi.h... $ECHO_C" >&6; }
32478if test "${ac_cv_header_gssapi_h+set}" = set; then
32479  echo $ECHO_N "(cached) $ECHO_C" >&6
32480fi
32481{ echo "$as_me:$LINENO: result: $ac_cv_header_gssapi_h" >&5
32482echo "${ECHO_T}$ac_cv_header_gssapi_h" >&6; }
32483else
32484  # Is the header compilable?
32485{ echo "$as_me:$LINENO: checking gssapi.h usability" >&5
32486echo $ECHO_N "checking gssapi.h usability... $ECHO_C" >&6; }
32487cat >conftest.$ac_ext <<_ACEOF
32488/* confdefs.h.  */
32489_ACEOF
32490cat confdefs.h >>conftest.$ac_ext
32491cat >>conftest.$ac_ext <<_ACEOF
32492/* end confdefs.h.  */
32493$ac_includes_default
32494#include <gssapi.h>
32495_ACEOF
32496rm -f conftest.$ac_objext
32497if { (ac_try="$ac_compile"
32498case "(($ac_try" in
32499  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32500  *) ac_try_echo=$ac_try;;
32501esac
32502eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32503  (eval "$ac_compile") 2>conftest.er1
32504  ac_status=$?
32505  grep -v '^ *+' conftest.er1 >conftest.err
32506  rm -f conftest.er1
32507  cat conftest.err >&5
32508  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32509  (exit $ac_status); } && {
32510	 test -z "$ac_c_werror_flag" ||
32511	 test ! -s conftest.err
32512       } && test -s conftest.$ac_objext; then
32513  ac_header_compiler=yes
32514else
32515  echo "$as_me: failed program was:" >&5
32516sed 's/^/| /' conftest.$ac_ext >&5
32517
32518	ac_header_compiler=no
32519fi
32520
32521rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32522{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
32523echo "${ECHO_T}$ac_header_compiler" >&6; }
32524
32525# Is the header present?
32526{ echo "$as_me:$LINENO: checking gssapi.h presence" >&5
32527echo $ECHO_N "checking gssapi.h presence... $ECHO_C" >&6; }
32528cat >conftest.$ac_ext <<_ACEOF
32529/* confdefs.h.  */
32530_ACEOF
32531cat confdefs.h >>conftest.$ac_ext
32532cat >>conftest.$ac_ext <<_ACEOF
32533/* end confdefs.h.  */
32534#include <gssapi.h>
32535_ACEOF
32536if { (ac_try="$ac_cpp conftest.$ac_ext"
32537case "(($ac_try" in
32538  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32539  *) ac_try_echo=$ac_try;;
32540esac
32541eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32542  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
32543  ac_status=$?
32544  grep -v '^ *+' conftest.er1 >conftest.err
32545  rm -f conftest.er1
32546  cat conftest.err >&5
32547  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32548  (exit $ac_status); } >/dev/null && {
32549	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
32550	 test ! -s conftest.err
32551       }; then
32552  ac_header_preproc=yes
32553else
32554  echo "$as_me: failed program was:" >&5
32555sed 's/^/| /' conftest.$ac_ext >&5
32556
32557  ac_header_preproc=no
32558fi
32559
32560rm -f conftest.err conftest.$ac_ext
32561{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
32562echo "${ECHO_T}$ac_header_preproc" >&6; }
32563
32564# So?  What about this header?
32565case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
32566  yes:no: )
32567    { echo "$as_me:$LINENO: WARNING: gssapi.h: accepted by the compiler, rejected by the preprocessor!" >&5
32568echo "$as_me: WARNING: gssapi.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
32569    { echo "$as_me:$LINENO: WARNING: gssapi.h: proceeding with the compiler's result" >&5
32570echo "$as_me: WARNING: gssapi.h: proceeding with the compiler's result" >&2;}
32571    ac_header_preproc=yes
32572    ;;
32573  no:yes:* )
32574    { echo "$as_me:$LINENO: WARNING: gssapi.h: present but cannot be compiled" >&5
32575echo "$as_me: WARNING: gssapi.h: present but cannot be compiled" >&2;}
32576    { echo "$as_me:$LINENO: WARNING: gssapi.h:     check for missing prerequisite headers?" >&5
32577echo "$as_me: WARNING: gssapi.h:     check for missing prerequisite headers?" >&2;}
32578    { echo "$as_me:$LINENO: WARNING: gssapi.h: see the Autoconf documentation" >&5
32579echo "$as_me: WARNING: gssapi.h: see the Autoconf documentation" >&2;}
32580    { echo "$as_me:$LINENO: WARNING: gssapi.h:     section \"Present But Cannot Be Compiled\"" >&5
32581echo "$as_me: WARNING: gssapi.h:     section \"Present But Cannot Be Compiled\"" >&2;}
32582    { echo "$as_me:$LINENO: WARNING: gssapi.h: proceeding with the preprocessor's result" >&5
32583echo "$as_me: WARNING: gssapi.h: proceeding with the preprocessor's result" >&2;}
32584    { echo "$as_me:$LINENO: WARNING: gssapi.h: in the future, the compiler will take precedence" >&5
32585echo "$as_me: WARNING: gssapi.h: in the future, the compiler will take precedence" >&2;}
32586    ( cat <<\_ASBOX
32587## ------------------------------------------- ##
32588## Report this to openssh-unix-dev@mindrot.org ##
32589## ------------------------------------------- ##
32590_ASBOX
32591     ) | sed "s/^/$as_me: WARNING:     /" >&2
32592    ;;
32593esac
32594{ echo "$as_me:$LINENO: checking for gssapi.h" >&5
32595echo $ECHO_N "checking for gssapi.h... $ECHO_C" >&6; }
32596if test "${ac_cv_header_gssapi_h+set}" = set; then
32597  echo $ECHO_N "(cached) $ECHO_C" >&6
32598else
32599  ac_cv_header_gssapi_h=$ac_header_preproc
32600fi
32601{ echo "$as_me:$LINENO: result: $ac_cv_header_gssapi_h" >&5
32602echo "${ECHO_T}$ac_cv_header_gssapi_h" >&6; }
32603
32604fi
32605if test $ac_cv_header_gssapi_h = yes; then
32606  :
32607else
32608   unset ac_cv_header_gssapi_h
32609				  CPPFLAGS="$CPPFLAGS -I${KRB5ROOT}/include/gssapi"
32610
32611for ac_header in gssapi.h
32612do
32613as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
32614if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
32615  { echo "$as_me:$LINENO: checking for $ac_header" >&5
32616echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
32617if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
32618  echo $ECHO_N "(cached) $ECHO_C" >&6
32619fi
32620ac_res=`eval echo '${'$as_ac_Header'}'`
32621	       { echo "$as_me:$LINENO: result: $ac_res" >&5
32622echo "${ECHO_T}$ac_res" >&6; }
32623else
32624  # Is the header compilable?
32625{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
32626echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
32627cat >conftest.$ac_ext <<_ACEOF
32628/* confdefs.h.  */
32629_ACEOF
32630cat confdefs.h >>conftest.$ac_ext
32631cat >>conftest.$ac_ext <<_ACEOF
32632/* end confdefs.h.  */
32633$ac_includes_default
32634#include <$ac_header>
32635_ACEOF
32636rm -f conftest.$ac_objext
32637if { (ac_try="$ac_compile"
32638case "(($ac_try" in
32639  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32640  *) ac_try_echo=$ac_try;;
32641esac
32642eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32643  (eval "$ac_compile") 2>conftest.er1
32644  ac_status=$?
32645  grep -v '^ *+' conftest.er1 >conftest.err
32646  rm -f conftest.er1
32647  cat conftest.err >&5
32648  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32649  (exit $ac_status); } && {
32650	 test -z "$ac_c_werror_flag" ||
32651	 test ! -s conftest.err
32652       } && test -s conftest.$ac_objext; then
32653  ac_header_compiler=yes
32654else
32655  echo "$as_me: failed program was:" >&5
32656sed 's/^/| /' conftest.$ac_ext >&5
32657
32658	ac_header_compiler=no
32659fi
32660
32661rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32662{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
32663echo "${ECHO_T}$ac_header_compiler" >&6; }
32664
32665# Is the header present?
32666{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
32667echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
32668cat >conftest.$ac_ext <<_ACEOF
32669/* confdefs.h.  */
32670_ACEOF
32671cat confdefs.h >>conftest.$ac_ext
32672cat >>conftest.$ac_ext <<_ACEOF
32673/* end confdefs.h.  */
32674#include <$ac_header>
32675_ACEOF
32676if { (ac_try="$ac_cpp conftest.$ac_ext"
32677case "(($ac_try" in
32678  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32679  *) ac_try_echo=$ac_try;;
32680esac
32681eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32682  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
32683  ac_status=$?
32684  grep -v '^ *+' conftest.er1 >conftest.err
32685  rm -f conftest.er1
32686  cat conftest.err >&5
32687  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32688  (exit $ac_status); } >/dev/null && {
32689	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
32690	 test ! -s conftest.err
32691       }; then
32692  ac_header_preproc=yes
32693else
32694  echo "$as_me: failed program was:" >&5
32695sed 's/^/| /' conftest.$ac_ext >&5
32696
32697  ac_header_preproc=no
32698fi
32699
32700rm -f conftest.err conftest.$ac_ext
32701{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
32702echo "${ECHO_T}$ac_header_preproc" >&6; }
32703
32704# So?  What about this header?
32705case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
32706  yes:no: )
32707    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
32708echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
32709    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
32710echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
32711    ac_header_preproc=yes
32712    ;;
32713  no:yes:* )
32714    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
32715echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
32716    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
32717echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
32718    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
32719echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
32720    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
32721echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
32722    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
32723echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
32724    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
32725echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
32726    ( cat <<\_ASBOX
32727## ------------------------------------------- ##
32728## Report this to openssh-unix-dev@mindrot.org ##
32729## ------------------------------------------- ##
32730_ASBOX
32731     ) | sed "s/^/$as_me: WARNING:     /" >&2
32732    ;;
32733esac
32734{ echo "$as_me:$LINENO: checking for $ac_header" >&5
32735echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
32736if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
32737  echo $ECHO_N "(cached) $ECHO_C" >&6
32738else
32739  eval "$as_ac_Header=\$ac_header_preproc"
32740fi
32741ac_res=`eval echo '${'$as_ac_Header'}'`
32742	       { echo "$as_me:$LINENO: result: $ac_res" >&5
32743echo "${ECHO_T}$ac_res" >&6; }
32744
32745fi
32746if test `eval echo '${'$as_ac_Header'}'` = yes; then
32747  cat >>confdefs.h <<_ACEOF
32748#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
32749_ACEOF
32750
32751else
32752  { echo "$as_me:$LINENO: WARNING: Cannot find any suitable gss-api header - build may fail" >&5
32753echo "$as_me: WARNING: Cannot find any suitable gss-api header - build may fail" >&2;}
32754
32755fi
32756
32757done
32758
32759
32760
32761fi
32762
32763
32764
32765			oldCPP="$CPPFLAGS"
32766			CPPFLAGS="$CPPFLAGS -I${KRB5ROOT}/include/gssapi"
32767			if test "${ac_cv_header_gssapi_krb5_h+set}" = set; then
32768  { echo "$as_me:$LINENO: checking for gssapi_krb5.h" >&5
32769echo $ECHO_N "checking for gssapi_krb5.h... $ECHO_C" >&6; }
32770if test "${ac_cv_header_gssapi_krb5_h+set}" = set; then
32771  echo $ECHO_N "(cached) $ECHO_C" >&6
32772fi
32773{ echo "$as_me:$LINENO: result: $ac_cv_header_gssapi_krb5_h" >&5
32774echo "${ECHO_T}$ac_cv_header_gssapi_krb5_h" >&6; }
32775else
32776  # Is the header compilable?
32777{ echo "$as_me:$LINENO: checking gssapi_krb5.h usability" >&5
32778echo $ECHO_N "checking gssapi_krb5.h usability... $ECHO_C" >&6; }
32779cat >conftest.$ac_ext <<_ACEOF
32780/* confdefs.h.  */
32781_ACEOF
32782cat confdefs.h >>conftest.$ac_ext
32783cat >>conftest.$ac_ext <<_ACEOF
32784/* end confdefs.h.  */
32785$ac_includes_default
32786#include <gssapi_krb5.h>
32787_ACEOF
32788rm -f conftest.$ac_objext
32789if { (ac_try="$ac_compile"
32790case "(($ac_try" in
32791  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32792  *) ac_try_echo=$ac_try;;
32793esac
32794eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32795  (eval "$ac_compile") 2>conftest.er1
32796  ac_status=$?
32797  grep -v '^ *+' conftest.er1 >conftest.err
32798  rm -f conftest.er1
32799  cat conftest.err >&5
32800  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32801  (exit $ac_status); } && {
32802	 test -z "$ac_c_werror_flag" ||
32803	 test ! -s conftest.err
32804       } && test -s conftest.$ac_objext; then
32805  ac_header_compiler=yes
32806else
32807  echo "$as_me: failed program was:" >&5
32808sed 's/^/| /' conftest.$ac_ext >&5
32809
32810	ac_header_compiler=no
32811fi
32812
32813rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32814{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
32815echo "${ECHO_T}$ac_header_compiler" >&6; }
32816
32817# Is the header present?
32818{ echo "$as_me:$LINENO: checking gssapi_krb5.h presence" >&5
32819echo $ECHO_N "checking gssapi_krb5.h presence... $ECHO_C" >&6; }
32820cat >conftest.$ac_ext <<_ACEOF
32821/* confdefs.h.  */
32822_ACEOF
32823cat confdefs.h >>conftest.$ac_ext
32824cat >>conftest.$ac_ext <<_ACEOF
32825/* end confdefs.h.  */
32826#include <gssapi_krb5.h>
32827_ACEOF
32828if { (ac_try="$ac_cpp conftest.$ac_ext"
32829case "(($ac_try" in
32830  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32831  *) ac_try_echo=$ac_try;;
32832esac
32833eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32834  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
32835  ac_status=$?
32836  grep -v '^ *+' conftest.er1 >conftest.err
32837  rm -f conftest.er1
32838  cat conftest.err >&5
32839  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32840  (exit $ac_status); } >/dev/null && {
32841	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
32842	 test ! -s conftest.err
32843       }; then
32844  ac_header_preproc=yes
32845else
32846  echo "$as_me: failed program was:" >&5
32847sed 's/^/| /' conftest.$ac_ext >&5
32848
32849  ac_header_preproc=no
32850fi
32851
32852rm -f conftest.err conftest.$ac_ext
32853{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
32854echo "${ECHO_T}$ac_header_preproc" >&6; }
32855
32856# So?  What about this header?
32857case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
32858  yes:no: )
32859    { echo "$as_me:$LINENO: WARNING: gssapi_krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
32860echo "$as_me: WARNING: gssapi_krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
32861    { echo "$as_me:$LINENO: WARNING: gssapi_krb5.h: proceeding with the compiler's result" >&5
32862echo "$as_me: WARNING: gssapi_krb5.h: proceeding with the compiler's result" >&2;}
32863    ac_header_preproc=yes
32864    ;;
32865  no:yes:* )
32866    { echo "$as_me:$LINENO: WARNING: gssapi_krb5.h: present but cannot be compiled" >&5
32867echo "$as_me: WARNING: gssapi_krb5.h: present but cannot be compiled" >&2;}
32868    { echo "$as_me:$LINENO: WARNING: gssapi_krb5.h:     check for missing prerequisite headers?" >&5
32869echo "$as_me: WARNING: gssapi_krb5.h:     check for missing prerequisite headers?" >&2;}
32870    { echo "$as_me:$LINENO: WARNING: gssapi_krb5.h: see the Autoconf documentation" >&5
32871echo "$as_me: WARNING: gssapi_krb5.h: see the Autoconf documentation" >&2;}
32872    { echo "$as_me:$LINENO: WARNING: gssapi_krb5.h:     section \"Present But Cannot Be Compiled\"" >&5
32873echo "$as_me: WARNING: gssapi_krb5.h:     section \"Present But Cannot Be Compiled\"" >&2;}
32874    { echo "$as_me:$LINENO: WARNING: gssapi_krb5.h: proceeding with the preprocessor's result" >&5
32875echo "$as_me: WARNING: gssapi_krb5.h: proceeding with the preprocessor's result" >&2;}
32876    { echo "$as_me:$LINENO: WARNING: gssapi_krb5.h: in the future, the compiler will take precedence" >&5
32877echo "$as_me: WARNING: gssapi_krb5.h: in the future, the compiler will take precedence" >&2;}
32878    ( cat <<\_ASBOX
32879## ------------------------------------------- ##
32880## Report this to openssh-unix-dev@mindrot.org ##
32881## ------------------------------------------- ##
32882_ASBOX
32883     ) | sed "s/^/$as_me: WARNING:     /" >&2
32884    ;;
32885esac
32886{ echo "$as_me:$LINENO: checking for gssapi_krb5.h" >&5
32887echo $ECHO_N "checking for gssapi_krb5.h... $ECHO_C" >&6; }
32888if test "${ac_cv_header_gssapi_krb5_h+set}" = set; then
32889  echo $ECHO_N "(cached) $ECHO_C" >&6
32890else
32891  ac_cv_header_gssapi_krb5_h=$ac_header_preproc
32892fi
32893{ echo "$as_me:$LINENO: result: $ac_cv_header_gssapi_krb5_h" >&5
32894echo "${ECHO_T}$ac_cv_header_gssapi_krb5_h" >&6; }
32895
32896fi
32897if test $ac_cv_header_gssapi_krb5_h = yes; then
32898  :
32899else
32900   CPPFLAGS="$oldCPP"
32901fi
32902
32903
32904
32905		fi
32906		if test ! -z "$need_dash_r" ; then
32907			LDFLAGS="$LDFLAGS -R${KRB5ROOT}/lib"
32908		fi
32909		if test ! -z "$blibpath" ; then
32910			blibpath="$blibpath:${KRB5ROOT}/lib"
32911		fi
32912
32913
32914
32915for ac_header in gssapi.h gssapi/gssapi.h
32916do
32917as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
32918if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
32919  { echo "$as_me:$LINENO: checking for $ac_header" >&5
32920echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
32921if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
32922  echo $ECHO_N "(cached) $ECHO_C" >&6
32923fi
32924ac_res=`eval echo '${'$as_ac_Header'}'`
32925	       { echo "$as_me:$LINENO: result: $ac_res" >&5
32926echo "${ECHO_T}$ac_res" >&6; }
32927else
32928  # Is the header compilable?
32929{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
32930echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
32931cat >conftest.$ac_ext <<_ACEOF
32932/* confdefs.h.  */
32933_ACEOF
32934cat confdefs.h >>conftest.$ac_ext
32935cat >>conftest.$ac_ext <<_ACEOF
32936/* end confdefs.h.  */
32937$ac_includes_default
32938#include <$ac_header>
32939_ACEOF
32940rm -f conftest.$ac_objext
32941if { (ac_try="$ac_compile"
32942case "(($ac_try" in
32943  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32944  *) ac_try_echo=$ac_try;;
32945esac
32946eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32947  (eval "$ac_compile") 2>conftest.er1
32948  ac_status=$?
32949  grep -v '^ *+' conftest.er1 >conftest.err
32950  rm -f conftest.er1
32951  cat conftest.err >&5
32952  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32953  (exit $ac_status); } && {
32954	 test -z "$ac_c_werror_flag" ||
32955	 test ! -s conftest.err
32956       } && test -s conftest.$ac_objext; then
32957  ac_header_compiler=yes
32958else
32959  echo "$as_me: failed program was:" >&5
32960sed 's/^/| /' conftest.$ac_ext >&5
32961
32962	ac_header_compiler=no
32963fi
32964
32965rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
32966{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
32967echo "${ECHO_T}$ac_header_compiler" >&6; }
32968
32969# Is the header present?
32970{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
32971echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
32972cat >conftest.$ac_ext <<_ACEOF
32973/* confdefs.h.  */
32974_ACEOF
32975cat confdefs.h >>conftest.$ac_ext
32976cat >>conftest.$ac_ext <<_ACEOF
32977/* end confdefs.h.  */
32978#include <$ac_header>
32979_ACEOF
32980if { (ac_try="$ac_cpp conftest.$ac_ext"
32981case "(($ac_try" in
32982  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
32983  *) ac_try_echo=$ac_try;;
32984esac
32985eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
32986  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
32987  ac_status=$?
32988  grep -v '^ *+' conftest.er1 >conftest.err
32989  rm -f conftest.er1
32990  cat conftest.err >&5
32991  echo "$as_me:$LINENO: \$? = $ac_status" >&5
32992  (exit $ac_status); } >/dev/null && {
32993	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
32994	 test ! -s conftest.err
32995       }; then
32996  ac_header_preproc=yes
32997else
32998  echo "$as_me: failed program was:" >&5
32999sed 's/^/| /' conftest.$ac_ext >&5
33000
33001  ac_header_preproc=no
33002fi
33003
33004rm -f conftest.err conftest.$ac_ext
33005{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
33006echo "${ECHO_T}$ac_header_preproc" >&6; }
33007
33008# So?  What about this header?
33009case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
33010  yes:no: )
33011    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
33012echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
33013    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
33014echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
33015    ac_header_preproc=yes
33016    ;;
33017  no:yes:* )
33018    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
33019echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
33020    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
33021echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
33022    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
33023echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
33024    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
33025echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
33026    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
33027echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
33028    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
33029echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
33030    ( cat <<\_ASBOX
33031## ------------------------------------------- ##
33032## Report this to openssh-unix-dev@mindrot.org ##
33033## ------------------------------------------- ##
33034_ASBOX
33035     ) | sed "s/^/$as_me: WARNING:     /" >&2
33036    ;;
33037esac
33038{ echo "$as_me:$LINENO: checking for $ac_header" >&5
33039echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
33040if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
33041  echo $ECHO_N "(cached) $ECHO_C" >&6
33042else
33043  eval "$as_ac_Header=\$ac_header_preproc"
33044fi
33045ac_res=`eval echo '${'$as_ac_Header'}'`
33046	       { echo "$as_me:$LINENO: result: $ac_res" >&5
33047echo "${ECHO_T}$ac_res" >&6; }
33048
33049fi
33050if test `eval echo '${'$as_ac_Header'}'` = yes; then
33051  cat >>confdefs.h <<_ACEOF
33052#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
33053_ACEOF
33054
33055fi
33056
33057done
33058
33059
33060
33061for ac_header in gssapi_krb5.h gssapi/gssapi_krb5.h
33062do
33063as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
33064if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
33065  { echo "$as_me:$LINENO: checking for $ac_header" >&5
33066echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
33067if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
33068  echo $ECHO_N "(cached) $ECHO_C" >&6
33069fi
33070ac_res=`eval echo '${'$as_ac_Header'}'`
33071	       { echo "$as_me:$LINENO: result: $ac_res" >&5
33072echo "${ECHO_T}$ac_res" >&6; }
33073else
33074  # Is the header compilable?
33075{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
33076echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
33077cat >conftest.$ac_ext <<_ACEOF
33078/* confdefs.h.  */
33079_ACEOF
33080cat confdefs.h >>conftest.$ac_ext
33081cat >>conftest.$ac_ext <<_ACEOF
33082/* end confdefs.h.  */
33083$ac_includes_default
33084#include <$ac_header>
33085_ACEOF
33086rm -f conftest.$ac_objext
33087if { (ac_try="$ac_compile"
33088case "(($ac_try" in
33089  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33090  *) ac_try_echo=$ac_try;;
33091esac
33092eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33093  (eval "$ac_compile") 2>conftest.er1
33094  ac_status=$?
33095  grep -v '^ *+' conftest.er1 >conftest.err
33096  rm -f conftest.er1
33097  cat conftest.err >&5
33098  echo "$as_me:$LINENO: \$? = $ac_status" >&5
33099  (exit $ac_status); } && {
33100	 test -z "$ac_c_werror_flag" ||
33101	 test ! -s conftest.err
33102       } && test -s conftest.$ac_objext; then
33103  ac_header_compiler=yes
33104else
33105  echo "$as_me: failed program was:" >&5
33106sed 's/^/| /' conftest.$ac_ext >&5
33107
33108	ac_header_compiler=no
33109fi
33110
33111rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33112{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
33113echo "${ECHO_T}$ac_header_compiler" >&6; }
33114
33115# Is the header present?
33116{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
33117echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
33118cat >conftest.$ac_ext <<_ACEOF
33119/* confdefs.h.  */
33120_ACEOF
33121cat confdefs.h >>conftest.$ac_ext
33122cat >>conftest.$ac_ext <<_ACEOF
33123/* end confdefs.h.  */
33124#include <$ac_header>
33125_ACEOF
33126if { (ac_try="$ac_cpp conftest.$ac_ext"
33127case "(($ac_try" in
33128  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33129  *) ac_try_echo=$ac_try;;
33130esac
33131eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33132  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
33133  ac_status=$?
33134  grep -v '^ *+' conftest.er1 >conftest.err
33135  rm -f conftest.er1
33136  cat conftest.err >&5
33137  echo "$as_me:$LINENO: \$? = $ac_status" >&5
33138  (exit $ac_status); } >/dev/null && {
33139	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
33140	 test ! -s conftest.err
33141       }; then
33142  ac_header_preproc=yes
33143else
33144  echo "$as_me: failed program was:" >&5
33145sed 's/^/| /' conftest.$ac_ext >&5
33146
33147  ac_header_preproc=no
33148fi
33149
33150rm -f conftest.err conftest.$ac_ext
33151{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
33152echo "${ECHO_T}$ac_header_preproc" >&6; }
33153
33154# So?  What about this header?
33155case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
33156  yes:no: )
33157    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
33158echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
33159    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
33160echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
33161    ac_header_preproc=yes
33162    ;;
33163  no:yes:* )
33164    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
33165echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
33166    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
33167echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
33168    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
33169echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
33170    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
33171echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
33172    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
33173echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
33174    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
33175echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
33176    ( cat <<\_ASBOX
33177## ------------------------------------------- ##
33178## Report this to openssh-unix-dev@mindrot.org ##
33179## ------------------------------------------- ##
33180_ASBOX
33181     ) | sed "s/^/$as_me: WARNING:     /" >&2
33182    ;;
33183esac
33184{ echo "$as_me:$LINENO: checking for $ac_header" >&5
33185echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
33186if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
33187  echo $ECHO_N "(cached) $ECHO_C" >&6
33188else
33189  eval "$as_ac_Header=\$ac_header_preproc"
33190fi
33191ac_res=`eval echo '${'$as_ac_Header'}'`
33192	       { echo "$as_me:$LINENO: result: $ac_res" >&5
33193echo "${ECHO_T}$ac_res" >&6; }
33194
33195fi
33196if test `eval echo '${'$as_ac_Header'}'` = yes; then
33197  cat >>confdefs.h <<_ACEOF
33198#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
33199_ACEOF
33200
33201fi
33202
33203done
33204
33205
33206
33207for ac_header in gssapi_generic.h gssapi/gssapi_generic.h
33208do
33209as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
33210if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
33211  { echo "$as_me:$LINENO: checking for $ac_header" >&5
33212echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
33213if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
33214  echo $ECHO_N "(cached) $ECHO_C" >&6
33215fi
33216ac_res=`eval echo '${'$as_ac_Header'}'`
33217	       { echo "$as_me:$LINENO: result: $ac_res" >&5
33218echo "${ECHO_T}$ac_res" >&6; }
33219else
33220  # Is the header compilable?
33221{ echo "$as_me:$LINENO: checking $ac_header usability" >&5
33222echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6; }
33223cat >conftest.$ac_ext <<_ACEOF
33224/* confdefs.h.  */
33225_ACEOF
33226cat confdefs.h >>conftest.$ac_ext
33227cat >>conftest.$ac_ext <<_ACEOF
33228/* end confdefs.h.  */
33229$ac_includes_default
33230#include <$ac_header>
33231_ACEOF
33232rm -f conftest.$ac_objext
33233if { (ac_try="$ac_compile"
33234case "(($ac_try" in
33235  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33236  *) ac_try_echo=$ac_try;;
33237esac
33238eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33239  (eval "$ac_compile") 2>conftest.er1
33240  ac_status=$?
33241  grep -v '^ *+' conftest.er1 >conftest.err
33242  rm -f conftest.er1
33243  cat conftest.err >&5
33244  echo "$as_me:$LINENO: \$? = $ac_status" >&5
33245  (exit $ac_status); } && {
33246	 test -z "$ac_c_werror_flag" ||
33247	 test ! -s conftest.err
33248       } && test -s conftest.$ac_objext; then
33249  ac_header_compiler=yes
33250else
33251  echo "$as_me: failed program was:" >&5
33252sed 's/^/| /' conftest.$ac_ext >&5
33253
33254	ac_header_compiler=no
33255fi
33256
33257rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33258{ echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
33259echo "${ECHO_T}$ac_header_compiler" >&6; }
33260
33261# Is the header present?
33262{ echo "$as_me:$LINENO: checking $ac_header presence" >&5
33263echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6; }
33264cat >conftest.$ac_ext <<_ACEOF
33265/* confdefs.h.  */
33266_ACEOF
33267cat confdefs.h >>conftest.$ac_ext
33268cat >>conftest.$ac_ext <<_ACEOF
33269/* end confdefs.h.  */
33270#include <$ac_header>
33271_ACEOF
33272if { (ac_try="$ac_cpp conftest.$ac_ext"
33273case "(($ac_try" in
33274  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33275  *) ac_try_echo=$ac_try;;
33276esac
33277eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33278  (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
33279  ac_status=$?
33280  grep -v '^ *+' conftest.er1 >conftest.err
33281  rm -f conftest.er1
33282  cat conftest.err >&5
33283  echo "$as_me:$LINENO: \$? = $ac_status" >&5
33284  (exit $ac_status); } >/dev/null && {
33285	 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
33286	 test ! -s conftest.err
33287       }; then
33288  ac_header_preproc=yes
33289else
33290  echo "$as_me: failed program was:" >&5
33291sed 's/^/| /' conftest.$ac_ext >&5
33292
33293  ac_header_preproc=no
33294fi
33295
33296rm -f conftest.err conftest.$ac_ext
33297{ echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
33298echo "${ECHO_T}$ac_header_preproc" >&6; }
33299
33300# So?  What about this header?
33301case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
33302  yes:no: )
33303    { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
33304echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
33305    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
33306echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
33307    ac_header_preproc=yes
33308    ;;
33309  no:yes:* )
33310    { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
33311echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
33312    { echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
33313echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
33314    { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
33315echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
33316    { echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
33317echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
33318    { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
33319echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
33320    { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
33321echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
33322    ( cat <<\_ASBOX
33323## ------------------------------------------- ##
33324## Report this to openssh-unix-dev@mindrot.org ##
33325## ------------------------------------------- ##
33326_ASBOX
33327     ) | sed "s/^/$as_me: WARNING:     /" >&2
33328    ;;
33329esac
33330{ echo "$as_me:$LINENO: checking for $ac_header" >&5
33331echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6; }
33332if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
33333  echo $ECHO_N "(cached) $ECHO_C" >&6
33334else
33335  eval "$as_ac_Header=\$ac_header_preproc"
33336fi
33337ac_res=`eval echo '${'$as_ac_Header'}'`
33338	       { echo "$as_me:$LINENO: result: $ac_res" >&5
33339echo "${ECHO_T}$ac_res" >&6; }
33340
33341fi
33342if test `eval echo '${'$as_ac_Header'}'` = yes; then
33343  cat >>confdefs.h <<_ACEOF
33344#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
33345_ACEOF
33346
33347fi
33348
33349done
33350
33351
33352		{ echo "$as_me:$LINENO: checking for library containing k_hasafs" >&5
33353echo $ECHO_N "checking for library containing k_hasafs... $ECHO_C" >&6; }
33354if test "${ac_cv_search_k_hasafs+set}" = set; then
33355  echo $ECHO_N "(cached) $ECHO_C" >&6
33356else
33357  ac_func_search_save_LIBS=$LIBS
33358cat >conftest.$ac_ext <<_ACEOF
33359/* confdefs.h.  */
33360_ACEOF
33361cat confdefs.h >>conftest.$ac_ext
33362cat >>conftest.$ac_ext <<_ACEOF
33363/* end confdefs.h.  */
33364
33365/* Override any GCC internal prototype to avoid an error.
33366   Use char because int might match the return type of a GCC
33367   builtin and then its argument prototype would still apply.  */
33368#ifdef __cplusplus
33369extern "C"
33370#endif
33371char k_hasafs ();
33372int
33373main ()
33374{
33375return k_hasafs ();
33376  ;
33377  return 0;
33378}
33379_ACEOF
33380for ac_lib in '' kafs; do
33381  if test -z "$ac_lib"; then
33382    ac_res="none required"
33383  else
33384    ac_res=-l$ac_lib
33385    LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
33386  fi
33387  rm -f conftest.$ac_objext conftest$ac_exeext
33388if { (ac_try="$ac_link"
33389case "(($ac_try" in
33390  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33391  *) ac_try_echo=$ac_try;;
33392esac
33393eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33394  (eval "$ac_link") 2>conftest.er1
33395  ac_status=$?
33396  grep -v '^ *+' conftest.er1 >conftest.err
33397  rm -f conftest.er1
33398  cat conftest.err >&5
33399  echo "$as_me:$LINENO: \$? = $ac_status" >&5
33400  (exit $ac_status); } && {
33401	 test -z "$ac_c_werror_flag" ||
33402	 test ! -s conftest.err
33403       } && test -s conftest$ac_exeext &&
33404       $as_test_x conftest$ac_exeext; then
33405  ac_cv_search_k_hasafs=$ac_res
33406else
33407  echo "$as_me: failed program was:" >&5
33408sed 's/^/| /' conftest.$ac_ext >&5
33409
33410
33411fi
33412
33413rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
33414      conftest$ac_exeext
33415  if test "${ac_cv_search_k_hasafs+set}" = set; then
33416  break
33417fi
33418done
33419if test "${ac_cv_search_k_hasafs+set}" = set; then
33420  :
33421else
33422  ac_cv_search_k_hasafs=no
33423fi
33424rm conftest.$ac_ext
33425LIBS=$ac_func_search_save_LIBS
33426fi
33427{ echo "$as_me:$LINENO: result: $ac_cv_search_k_hasafs" >&5
33428echo "${ECHO_T}$ac_cv_search_k_hasafs" >&6; }
33429ac_res=$ac_cv_search_k_hasafs
33430if test "$ac_res" != no; then
33431  test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
33432
33433cat >>confdefs.h <<\_ACEOF
33434#define USE_AFS 1
33435_ACEOF
33436
33437fi
33438
33439
33440		{ echo "$as_me:$LINENO: checking whether GSS_C_NT_HOSTBASED_SERVICE is declared" >&5
33441echo $ECHO_N "checking whether GSS_C_NT_HOSTBASED_SERVICE is declared... $ECHO_C" >&6; }
33442if test "${ac_cv_have_decl_GSS_C_NT_HOSTBASED_SERVICE+set}" = set; then
33443  echo $ECHO_N "(cached) $ECHO_C" >&6
33444else
33445  cat >conftest.$ac_ext <<_ACEOF
33446/* confdefs.h.  */
33447_ACEOF
33448cat confdefs.h >>conftest.$ac_ext
33449cat >>conftest.$ac_ext <<_ACEOF
33450/* end confdefs.h.  */
33451
33452#ifdef HAVE_GSSAPI_H
33453# include <gssapi.h>
33454#elif defined(HAVE_GSSAPI_GSSAPI_H)
33455# include <gssapi/gssapi.h>
33456#endif
33457
33458#ifdef HAVE_GSSAPI_GENERIC_H
33459# include <gssapi_generic.h>
33460#elif defined(HAVE_GSSAPI_GSSAPI_GENERIC_H)
33461# include <gssapi/gssapi_generic.h>
33462#endif
33463
33464
33465int
33466main ()
33467{
33468#ifndef GSS_C_NT_HOSTBASED_SERVICE
33469  (void) GSS_C_NT_HOSTBASED_SERVICE;
33470#endif
33471
33472  ;
33473  return 0;
33474}
33475_ACEOF
33476rm -f conftest.$ac_objext
33477if { (ac_try="$ac_compile"
33478case "(($ac_try" in
33479  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33480  *) ac_try_echo=$ac_try;;
33481esac
33482eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33483  (eval "$ac_compile") 2>conftest.er1
33484  ac_status=$?
33485  grep -v '^ *+' conftest.er1 >conftest.err
33486  rm -f conftest.er1
33487  cat conftest.err >&5
33488  echo "$as_me:$LINENO: \$? = $ac_status" >&5
33489  (exit $ac_status); } && {
33490	 test -z "$ac_c_werror_flag" ||
33491	 test ! -s conftest.err
33492       } && test -s conftest.$ac_objext; then
33493  ac_cv_have_decl_GSS_C_NT_HOSTBASED_SERVICE=yes
33494else
33495  echo "$as_me: failed program was:" >&5
33496sed 's/^/| /' conftest.$ac_ext >&5
33497
33498	ac_cv_have_decl_GSS_C_NT_HOSTBASED_SERVICE=no
33499fi
33500
33501rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
33502fi
33503{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_GSS_C_NT_HOSTBASED_SERVICE" >&5
33504echo "${ECHO_T}$ac_cv_have_decl_GSS_C_NT_HOSTBASED_SERVICE" >&6; }
33505if test $ac_cv_have_decl_GSS_C_NT_HOSTBASED_SERVICE = yes; then
33506
33507cat >>confdefs.h <<_ACEOF
33508#define HAVE_DECL_GSS_C_NT_HOSTBASED_SERVICE 1
33509_ACEOF
33510
33511
33512else
33513  cat >>confdefs.h <<_ACEOF
33514#define HAVE_DECL_GSS_C_NT_HOSTBASED_SERVICE 0
33515_ACEOF
33516
33517
33518fi
33519
33520
33521		saved_LIBS="$LIBS"
33522		LIBS="$LIBS $K5LIBS"
33523
33524
33525
33526for ac_func in krb5_cc_new_unique krb5_get_error_message krb5_free_error_message
33527do
33528as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
33529{ echo "$as_me:$LINENO: checking for $ac_func" >&5
33530echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6; }
33531if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
33532  echo $ECHO_N "(cached) $ECHO_C" >&6
33533else
33534  cat >conftest.$ac_ext <<_ACEOF
33535/* confdefs.h.  */
33536_ACEOF
33537cat confdefs.h >>conftest.$ac_ext
33538cat >>conftest.$ac_ext <<_ACEOF
33539/* end confdefs.h.  */
33540/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
33541   For example, HP-UX 11i <limits.h> declares gettimeofday.  */
33542#define $ac_func innocuous_$ac_func
33543
33544/* System header to define __stub macros and hopefully few prototypes,
33545    which can conflict with char $ac_func (); below.
33546    Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
33547    <limits.h> exists even on freestanding compilers.  */
33548
33549#ifdef __STDC__
33550# include <limits.h>
33551#else
33552# include <assert.h>
33553#endif
33554
33555#undef $ac_func
33556
33557/* Override any GCC internal prototype to avoid an error.
33558   Use char because int might match the return type of a GCC
33559   builtin and then its argument prototype would still apply.  */
33560#ifdef __cplusplus
33561extern "C"
33562#endif
33563char $ac_func ();
33564/* The GNU C library defines this for functions which it implements
33565    to always fail with ENOSYS.  Some functions are actually named
33566    something starting with __ and the normal name is an alias.  */
33567#if defined __stub_$ac_func || defined __stub___$ac_func
33568choke me
33569#endif
33570
33571int
33572main ()
33573{
33574return $ac_func ();
33575  ;
33576  return 0;
33577}
33578_ACEOF
33579rm -f conftest.$ac_objext conftest$ac_exeext
33580if { (ac_try="$ac_link"
33581case "(($ac_try" in
33582  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33583  *) ac_try_echo=$ac_try;;
33584esac
33585eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33586  (eval "$ac_link") 2>conftest.er1
33587  ac_status=$?
33588  grep -v '^ *+' conftest.er1 >conftest.err
33589  rm -f conftest.er1
33590  cat conftest.err >&5
33591  echo "$as_me:$LINENO: \$? = $ac_status" >&5
33592  (exit $ac_status); } && {
33593	 test -z "$ac_c_werror_flag" ||
33594	 test ! -s conftest.err
33595       } && test -s conftest$ac_exeext &&
33596       $as_test_x conftest$ac_exeext; then
33597  eval "$as_ac_var=yes"
33598else
33599  echo "$as_me: failed program was:" >&5
33600sed 's/^/| /' conftest.$ac_ext >&5
33601
33602	eval "$as_ac_var=no"
33603fi
33604
33605rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
33606      conftest$ac_exeext conftest.$ac_ext
33607fi
33608ac_res=`eval echo '${'$as_ac_var'}'`
33609	       { echo "$as_me:$LINENO: result: $ac_res" >&5
33610echo "${ECHO_T}$ac_res" >&6; }
33611if test `eval echo '${'$as_ac_var'}'` = yes; then
33612  cat >>confdefs.h <<_ACEOF
33613#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
33614_ACEOF
33615
33616fi
33617done
33618
33619		LIBS="$saved_LIBS"
33620
33621	fi
33622
33623
33624fi
33625
33626
33627
33628
33629# Looking for programs, paths and files
33630
33631PRIVSEP_PATH=/var/empty
33632
33633# Check whether --with-privsep-path was given.
33634if test "${with_privsep_path+set}" = set; then
33635  withval=$with_privsep_path;
33636		if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
33637		    test "x${withval}" != "xyes"; then
33638			PRIVSEP_PATH=$withval
33639		fi
33640
33641
33642fi
33643
33644
33645
33646
33647# Check whether --with-xauth was given.
33648if test "${with_xauth+set}" = set; then
33649  withval=$with_xauth;
33650		if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
33651		    test "x${withval}" != "xyes"; then
33652			xauth_path=$withval
33653		fi
33654
33655else
33656
33657		TestPath="$PATH"
33658		TestPath="${TestPath}${PATH_SEPARATOR}/usr/X/bin"
33659		TestPath="${TestPath}${PATH_SEPARATOR}/usr/bin/X11"
33660		TestPath="${TestPath}${PATH_SEPARATOR}/usr/X11R6/bin"
33661		TestPath="${TestPath}${PATH_SEPARATOR}/usr/openwin/bin"
33662		# Extract the first word of "xauth", so it can be a program name with args.
33663set dummy xauth; ac_word=$2
33664{ echo "$as_me:$LINENO: checking for $ac_word" >&5
33665echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
33666if test "${ac_cv_path_xauth_path+set}" = set; then
33667  echo $ECHO_N "(cached) $ECHO_C" >&6
33668else
33669  case $xauth_path in
33670  [\\/]* | ?:[\\/]*)
33671  ac_cv_path_xauth_path="$xauth_path" # Let the user override the test with a path.
33672  ;;
33673  *)
33674  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33675for as_dir in $TestPath
33676do
33677  IFS=$as_save_IFS
33678  test -z "$as_dir" && as_dir=.
33679  for ac_exec_ext in '' $ac_executable_extensions; do
33680  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
33681    ac_cv_path_xauth_path="$as_dir/$ac_word$ac_exec_ext"
33682    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
33683    break 2
33684  fi
33685done
33686done
33687IFS=$as_save_IFS
33688
33689  ;;
33690esac
33691fi
33692xauth_path=$ac_cv_path_xauth_path
33693if test -n "$xauth_path"; then
33694  { echo "$as_me:$LINENO: result: $xauth_path" >&5
33695echo "${ECHO_T}$xauth_path" >&6; }
33696else
33697  { echo "$as_me:$LINENO: result: no" >&5
33698echo "${ECHO_T}no" >&6; }
33699fi
33700
33701
33702		if (test ! -z "$xauth_path" && test -x "/usr/openwin/bin/xauth") ; then
33703			xauth_path="/usr/openwin/bin/xauth"
33704		fi
33705
33706
33707fi
33708
33709
33710STRIP_OPT=-s
33711# Check whether --enable-strip was given.
33712if test "${enable_strip+set}" = set; then
33713  enableval=$enable_strip;
33714		if test "x$enableval" = "xno" ; then
33715			STRIP_OPT=
33716		fi
33717
33718
33719fi
33720
33721
33722
33723if test -z "$xauth_path" ; then
33724	XAUTH_PATH="undefined"
33725
33726else
33727
33728cat >>confdefs.h <<_ACEOF
33729#define XAUTH_PATH "$xauth_path"
33730_ACEOF
33731
33732	XAUTH_PATH=$xauth_path
33733
33734fi
33735
33736# Check for mail directory
33737
33738# Check whether --with-maildir was given.
33739if test "${with_maildir+set}" = set; then
33740  withval=$with_maildir;
33741	if test "X$withval" != X  &&  test "x$withval" != xno  &&  \
33742	    test "x${withval}" != xyes; then
33743
33744cat >>confdefs.h <<_ACEOF
33745#define MAIL_DIRECTORY "$withval"
33746_ACEOF
33747
33748	    fi
33749
33750else
33751
33752	if test "X$maildir" != "X"; then
33753	    cat >>confdefs.h <<_ACEOF
33754#define MAIL_DIRECTORY "$maildir"
33755_ACEOF
33756
33757	else
33758	    { echo "$as_me:$LINENO: checking Discovering system mail directory" >&5
33759echo $ECHO_N "checking Discovering system mail directory... $ECHO_C" >&6; }
33760	    if test "$cross_compiling" = yes; then
33761
33762			{ echo "$as_me:$LINENO: WARNING: cross compiling: use --with-maildir=/path/to/mail" >&5
33763echo "$as_me: WARNING: cross compiling: use --with-maildir=/path/to/mail" >&2;}
33764
33765
33766else
33767  cat >conftest.$ac_ext <<_ACEOF
33768/* confdefs.h.  */
33769_ACEOF
33770cat confdefs.h >>conftest.$ac_ext
33771cat >>conftest.$ac_ext <<_ACEOF
33772/* end confdefs.h.  */
33773
33774#include <stdio.h>
33775#include <string.h>
33776#ifdef HAVE_PATHS_H
33777#include <paths.h>
33778#endif
33779#ifdef HAVE_MAILLOCK_H
33780#include <maillock.h>
33781#endif
33782#define DATA "conftest.maildir"
33783
33784int
33785main ()
33786{
33787
33788	FILE *fd;
33789	int rc;
33790
33791	fd = fopen(DATA,"w");
33792	if(fd == NULL)
33793		exit(1);
33794
33795#if defined (_PATH_MAILDIR)
33796	if ((rc = fprintf(fd ,"_PATH_MAILDIR:%s\n", _PATH_MAILDIR)) <0)
33797		exit(1);
33798#elif defined (MAILDIR)
33799	if ((rc = fprintf(fd ,"MAILDIR:%s\n", MAILDIR)) <0)
33800		exit(1);
33801#elif defined (_PATH_MAIL)
33802	if ((rc = fprintf(fd ,"_PATH_MAIL:%s\n", _PATH_MAIL)) <0)
33803		exit(1);
33804#else
33805	exit (2);
33806#endif
33807
33808	exit(0);
33809
33810  ;
33811  return 0;
33812}
33813_ACEOF
33814rm -f conftest$ac_exeext
33815if { (ac_try="$ac_link"
33816case "(($ac_try" in
33817  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33818  *) ac_try_echo=$ac_try;;
33819esac
33820eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33821  (eval "$ac_link") 2>&5
33822  ac_status=$?
33823  echo "$as_me:$LINENO: \$? = $ac_status" >&5
33824  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
33825  { (case "(($ac_try" in
33826  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
33827  *) ac_try_echo=$ac_try;;
33828esac
33829eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
33830  (eval "$ac_try") 2>&5
33831  ac_status=$?
33832  echo "$as_me:$LINENO: \$? = $ac_status" >&5
33833  (exit $ac_status); }; }; then
33834
33835	 	    maildir_what=`awk -F: '{print $1}' conftest.maildir`
33836		    maildir=`awk -F: '{print $2}' conftest.maildir \
33837			| sed 's|/$||'`
33838		    { echo "$as_me:$LINENO: result: Using: $maildir from $maildir_what" >&5
33839echo "${ECHO_T}Using: $maildir from $maildir_what" >&6; }
33840		    if test "x$maildir_what" != "x_PATH_MAILDIR"; then
33841			cat >>confdefs.h <<_ACEOF
33842#define MAIL_DIRECTORY "$maildir"
33843_ACEOF
33844
33845		    fi
33846
33847else
33848  echo "$as_me: program exited with status $ac_status" >&5
33849echo "$as_me: failed program was:" >&5
33850sed 's/^/| /' conftest.$ac_ext >&5
33851
33852( exit $ac_status )
33853
33854		    if test "X$ac_status" = "X2";then
33855# our test program didn't find it. Default to /var/spool/mail
33856			{ echo "$as_me:$LINENO: result: Using: default value of /var/spool/mail" >&5
33857echo "${ECHO_T}Using: default value of /var/spool/mail" >&6; }
33858			cat >>confdefs.h <<_ACEOF
33859#define MAIL_DIRECTORY "/var/spool/mail"
33860_ACEOF
33861
33862		     else
33863			{ echo "$as_me:$LINENO: result: *** not found ***" >&5
33864echo "${ECHO_T}*** not found ***" >&6; }
33865		     fi
33866
33867fi
33868rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
33869fi
33870
33871
33872	fi
33873
33874
33875fi
33876 # maildir
33877
33878if test ! -z "$cross_compiling" && test "x$cross_compiling" = "xyes"; then
33879	{ echo "$as_me:$LINENO: WARNING: cross compiling: Disabling /dev/ptmx test" >&5
33880echo "$as_me: WARNING: cross compiling: Disabling /dev/ptmx test" >&2;}
33881	disable_ptmx_check=yes
33882fi
33883if test -z "$no_dev_ptmx" ; then
33884	if test "x$disable_ptmx_check" != "xyes" ; then
33885		{ echo "$as_me:$LINENO: checking for \"/dev/ptmx\"" >&5
33886echo $ECHO_N "checking for \"/dev/ptmx\"... $ECHO_C" >&6; }
33887if test "${ac_cv_file___dev_ptmx_+set}" = set; then
33888  echo $ECHO_N "(cached) $ECHO_C" >&6
33889else
33890  test "$cross_compiling" = yes &&
33891  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
33892echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
33893   { (exit 1); exit 1; }; }
33894if test -r ""/dev/ptmx""; then
33895  ac_cv_file___dev_ptmx_=yes
33896else
33897  ac_cv_file___dev_ptmx_=no
33898fi
33899fi
33900{ echo "$as_me:$LINENO: result: $ac_cv_file___dev_ptmx_" >&5
33901echo "${ECHO_T}$ac_cv_file___dev_ptmx_" >&6; }
33902if test $ac_cv_file___dev_ptmx_ = yes; then
33903
33904
33905cat >>confdefs.h <<_ACEOF
33906#define HAVE_DEV_PTMX 1
33907_ACEOF
33908
33909				have_dev_ptmx=1
33910
33911
33912fi
33913
33914	fi
33915fi
33916
33917if test ! -z "$cross_compiling" && test "x$cross_compiling" != "xyes"; then
33918	{ echo "$as_me:$LINENO: checking for \"/dev/ptc\"" >&5
33919echo $ECHO_N "checking for \"/dev/ptc\"... $ECHO_C" >&6; }
33920if test "${ac_cv_file___dev_ptc_+set}" = set; then
33921  echo $ECHO_N "(cached) $ECHO_C" >&6
33922else
33923  test "$cross_compiling" = yes &&
33924  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
33925echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
33926   { (exit 1); exit 1; }; }
33927if test -r ""/dev/ptc""; then
33928  ac_cv_file___dev_ptc_=yes
33929else
33930  ac_cv_file___dev_ptc_=no
33931fi
33932fi
33933{ echo "$as_me:$LINENO: result: $ac_cv_file___dev_ptc_" >&5
33934echo "${ECHO_T}$ac_cv_file___dev_ptc_" >&6; }
33935if test $ac_cv_file___dev_ptc_ = yes; then
33936
33937
33938cat >>confdefs.h <<_ACEOF
33939#define HAVE_DEV_PTS_AND_PTC 1
33940_ACEOF
33941
33942			have_dev_ptc=1
33943
33944
33945fi
33946
33947else
33948	{ echo "$as_me:$LINENO: WARNING: cross compiling: Disabling /dev/ptc test" >&5
33949echo "$as_me: WARNING: cross compiling: Disabling /dev/ptc test" >&2;}
33950fi
33951
33952# Options from here on. Some of these are preset by platform above
33953
33954# Check whether --with-mantype was given.
33955if test "${with_mantype+set}" = set; then
33956  withval=$with_mantype;
33957		case "$withval" in
33958		man|cat|doc)
33959			MANTYPE=$withval
33960			;;
33961		*)
33962			{ { echo "$as_me:$LINENO: error: invalid man type: $withval" >&5
33963echo "$as_me: error: invalid man type: $withval" >&2;}
33964   { (exit 1); exit 1; }; }
33965			;;
33966		esac
33967
33968
33969fi
33970
33971if test -z "$MANTYPE"; then
33972	TestPath="/usr/bin${PATH_SEPARATOR}/usr/ucb"
33973	for ac_prog in nroff awf
33974do
33975  # Extract the first word of "$ac_prog", so it can be a program name with args.
33976set dummy $ac_prog; ac_word=$2
33977{ echo "$as_me:$LINENO: checking for $ac_word" >&5
33978echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; }
33979if test "${ac_cv_path_NROFF+set}" = set; then
33980  echo $ECHO_N "(cached) $ECHO_C" >&6
33981else
33982  case $NROFF in
33983  [\\/]* | ?:[\\/]*)
33984  ac_cv_path_NROFF="$NROFF" # Let the user override the test with a path.
33985  ;;
33986  *)
33987  as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
33988for as_dir in $TestPath
33989do
33990  IFS=$as_save_IFS
33991  test -z "$as_dir" && as_dir=.
33992  for ac_exec_ext in '' $ac_executable_extensions; do
33993  if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
33994    ac_cv_path_NROFF="$as_dir/$ac_word$ac_exec_ext"
33995    echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
33996    break 2
33997  fi
33998done
33999done
34000IFS=$as_save_IFS
34001
34002  ;;
34003esac
34004fi
34005NROFF=$ac_cv_path_NROFF
34006if test -n "$NROFF"; then
34007  { echo "$as_me:$LINENO: result: $NROFF" >&5
34008echo "${ECHO_T}$NROFF" >&6; }
34009else
34010  { echo "$as_me:$LINENO: result: no" >&5
34011echo "${ECHO_T}no" >&6; }
34012fi
34013
34014
34015  test -n "$NROFF" && break
34016done
34017test -n "$NROFF" || NROFF="/bin/false"
34018
34019	if ${NROFF} -mdoc ${srcdir}/ssh.1 >/dev/null 2>&1; then
34020		MANTYPE=doc
34021	elif ${NROFF} -man ${srcdir}/ssh.1 >/dev/null 2>&1; then
34022		MANTYPE=man
34023	else
34024		MANTYPE=cat
34025	fi
34026fi
34027
34028if test "$MANTYPE" = "doc"; then
34029	mansubdir=man;
34030else
34031	mansubdir=$MANTYPE;
34032fi
34033
34034
34035# Check whether to enable MD5 passwords
34036MD5_MSG="no"
34037
34038# Check whether --with-md5-passwords was given.
34039if test "${with_md5_passwords+set}" = set; then
34040  withval=$with_md5_passwords;
34041		if test "x$withval" != "xno" ; then
34042
34043cat >>confdefs.h <<\_ACEOF
34044#define HAVE_MD5_PASSWORDS 1
34045_ACEOF
34046
34047			MD5_MSG="yes"
34048		fi
34049
34050
34051fi
34052
34053
34054# Whether to disable shadow password support
34055
34056# Check whether --with-shadow was given.
34057if test "${with_shadow+set}" = set; then
34058  withval=$with_shadow;
34059		if test "x$withval" = "xno" ; then
34060			cat >>confdefs.h <<\_ACEOF
34061#define DISABLE_SHADOW 1
34062_ACEOF
34063
34064			disable_shadow=yes
34065		fi
34066
34067
34068fi
34069
34070
34071if test -z "$disable_shadow" ; then
34072	{ echo "$as_me:$LINENO: checking if the systems has expire shadow information" >&5
34073echo $ECHO_N "checking if the systems has expire shadow information... $ECHO_C" >&6; }
34074	cat >conftest.$ac_ext <<_ACEOF
34075/* confdefs.h.  */
34076_ACEOF
34077cat confdefs.h >>conftest.$ac_ext
34078cat >>conftest.$ac_ext <<_ACEOF
34079/* end confdefs.h.  */
34080
34081#include <sys/types.h>
34082#include <shadow.h>
34083struct spwd sp;
34084
34085int
34086main ()
34087{
34088 sp.sp_expire = sp.sp_lstchg = sp.sp_inact = 0;
34089  ;
34090  return 0;
34091}
34092_ACEOF
34093rm -f conftest.$ac_objext
34094if { (ac_try="$ac_compile"
34095case "(($ac_try" in
34096  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
34097  *) ac_try_echo=$ac_try;;
34098esac
34099eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
34100  (eval "$ac_compile") 2>conftest.er1
34101  ac_status=$?
34102  grep -v '^ *+' conftest.er1 >conftest.err
34103  rm -f conftest.er1
34104  cat conftest.err >&5
34105  echo "$as_me:$LINENO: \$? = $ac_status" >&5
34106  (exit $ac_status); } && {
34107	 test -z "$ac_c_werror_flag" ||
34108	 test ! -s conftest.err
34109       } && test -s conftest.$ac_objext; then
34110   sp_expire_available=yes
34111else
34112  echo "$as_me: failed program was:" >&5
34113sed 's/^/| /' conftest.$ac_ext >&5
34114
34115
34116
34117fi
34118
34119rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34120
34121	if test "x$sp_expire_available" = "xyes" ; then
34122		{ echo "$as_me:$LINENO: result: yes" >&5
34123echo "${ECHO_T}yes" >&6; }
34124
34125cat >>confdefs.h <<\_ACEOF
34126#define HAS_SHADOW_EXPIRE 1
34127_ACEOF
34128
34129	else
34130		{ echo "$as_me:$LINENO: result: no" >&5
34131echo "${ECHO_T}no" >&6; }
34132	fi
34133fi
34134
34135# Use ip address instead of hostname in $DISPLAY
34136if test ! -z "$IPADDR_IN_DISPLAY" ; then
34137	DISPLAY_HACK_MSG="yes"
34138
34139cat >>confdefs.h <<\_ACEOF
34140#define IPADDR_IN_DISPLAY 1
34141_ACEOF
34142
34143else
34144	DISPLAY_HACK_MSG="no"
34145
34146# Check whether --with-ipaddr-display was given.
34147if test "${with_ipaddr_display+set}" = set; then
34148  withval=$with_ipaddr_display;
34149			if test "x$withval" != "xno" ; then
34150				cat >>confdefs.h <<\_ACEOF
34151#define IPADDR_IN_DISPLAY 1
34152_ACEOF
34153
34154				DISPLAY_HACK_MSG="yes"
34155			fi
34156
34157
34158fi
34159
34160fi
34161
34162# check for /etc/default/login and use it if present.
34163# Check whether --enable-etc-default-login was given.
34164if test "${enable_etc_default_login+set}" = set; then
34165  enableval=$enable_etc_default_login;  if test "x$enableval" = "xno"; then
34166		{ echo "$as_me:$LINENO: /etc/default/login handling disabled" >&5
34167echo "$as_me: /etc/default/login handling disabled" >&6;}
34168		etc_default_login=no
34169	  else
34170		etc_default_login=yes
34171	  fi
34172else
34173   if test ! -z "$cross_compiling" && test "x$cross_compiling" = "xyes";
34174	  then
34175		{ echo "$as_me:$LINENO: WARNING: cross compiling: not checking /etc/default/login" >&5
34176echo "$as_me: WARNING: cross compiling: not checking /etc/default/login" >&2;}
34177		etc_default_login=no
34178	  else
34179		etc_default_login=yes
34180	  fi
34181
34182fi
34183
34184
34185if test "x$etc_default_login" != "xno"; then
34186	{ echo "$as_me:$LINENO: checking for \"/etc/default/login\"" >&5
34187echo $ECHO_N "checking for \"/etc/default/login\"... $ECHO_C" >&6; }
34188if test "${ac_cv_file___etc_default_login_+set}" = set; then
34189  echo $ECHO_N "(cached) $ECHO_C" >&6
34190else
34191  test "$cross_compiling" = yes &&
34192  { { echo "$as_me:$LINENO: error: cannot check for file existence when cross compiling" >&5
34193echo "$as_me: error: cannot check for file existence when cross compiling" >&2;}
34194   { (exit 1); exit 1; }; }
34195if test -r ""/etc/default/login""; then
34196  ac_cv_file___etc_default_login_=yes
34197else
34198  ac_cv_file___etc_default_login_=no
34199fi
34200fi
34201{ echo "$as_me:$LINENO: result: $ac_cv_file___etc_default_login_" >&5
34202echo "${ECHO_T}$ac_cv_file___etc_default_login_" >&6; }
34203if test $ac_cv_file___etc_default_login_ = yes; then
34204   external_path_file=/etc/default/login
34205fi
34206
34207	if test "x$external_path_file" = "x/etc/default/login"; then
34208
34209cat >>confdefs.h <<\_ACEOF
34210#define HAVE_ETC_DEFAULT_LOGIN 1
34211_ACEOF
34212
34213	fi
34214fi
34215
34216if test $ac_cv_func_login_getcapbool = "yes" && \
34217	test $ac_cv_header_login_cap_h = "yes" ; then
34218	external_path_file=/etc/login.conf
34219fi
34220
34221# Whether to mess with the default path
34222SERVER_PATH_MSG="(default)"
34223
34224# Check whether --with-default-path was given.
34225if test "${with_default_path+set}" = set; then
34226  withval=$with_default_path;
34227		if test "x$external_path_file" = "x/etc/login.conf" ; then
34228			{ echo "$as_me:$LINENO: WARNING:
34229--with-default-path=PATH has no effect on this system.
34230Edit /etc/login.conf instead." >&5
34231echo "$as_me: WARNING:
34232--with-default-path=PATH has no effect on this system.
34233Edit /etc/login.conf instead." >&2;}
34234		elif test "x$withval" != "xno" ; then
34235			if test ! -z "$external_path_file" ; then
34236				{ echo "$as_me:$LINENO: WARNING:
34237--with-default-path=PATH will only be used if PATH is not defined in
34238$external_path_file ." >&5
34239echo "$as_me: WARNING:
34240--with-default-path=PATH will only be used if PATH is not defined in
34241$external_path_file ." >&2;}
34242			fi
34243			user_path="$withval"
34244			SERVER_PATH_MSG="$withval"
34245		fi
34246
34247else
34248   if test "x$external_path_file" = "x/etc/login.conf" ; then
34249		{ echo "$as_me:$LINENO: WARNING: Make sure the path to scp is in /etc/login.conf" >&5
34250echo "$as_me: WARNING: Make sure the path to scp is in /etc/login.conf" >&2;}
34251	else
34252		if test ! -z "$external_path_file" ; then
34253			{ echo "$as_me:$LINENO: WARNING:
34254If PATH is defined in $external_path_file, ensure the path to scp is included,
34255otherwise scp will not work." >&5
34256echo "$as_me: WARNING:
34257If PATH is defined in $external_path_file, ensure the path to scp is included,
34258otherwise scp will not work." >&2;}
34259		fi
34260		if test "$cross_compiling" = yes; then
34261   user_path="/usr/bin:/bin:/usr/sbin:/sbin"
34262
34263else
34264  cat >conftest.$ac_ext <<_ACEOF
34265/* confdefs.h.  */
34266_ACEOF
34267cat confdefs.h >>conftest.$ac_ext
34268cat >>conftest.$ac_ext <<_ACEOF
34269/* end confdefs.h.  */
34270
34271/* find out what STDPATH is */
34272#include <stdio.h>
34273#ifdef HAVE_PATHS_H
34274# include <paths.h>
34275#endif
34276#ifndef _PATH_STDPATH
34277# ifdef _PATH_USERPATH	/* Irix */
34278#  define _PATH_STDPATH _PATH_USERPATH
34279# else
34280#  define _PATH_STDPATH "/usr/bin:/bin:/usr/sbin:/sbin"
34281# endif
34282#endif
34283#include <sys/types.h>
34284#include <sys/stat.h>
34285#include <fcntl.h>
34286#define DATA "conftest.stdpath"
34287
34288int
34289main ()
34290{
34291
34292	FILE *fd;
34293	int rc;
34294
34295	fd = fopen(DATA,"w");
34296	if(fd == NULL)
34297		exit(1);
34298
34299	if ((rc = fprintf(fd,"%s", _PATH_STDPATH)) < 0)
34300		exit(1);
34301
34302	exit(0);
34303
34304  ;
34305  return 0;
34306}
34307_ACEOF
34308rm -f conftest$ac_exeext
34309if { (ac_try="$ac_link"
34310case "(($ac_try" in
34311  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
34312  *) ac_try_echo=$ac_try;;
34313esac
34314eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
34315  (eval "$ac_link") 2>&5
34316  ac_status=$?
34317  echo "$as_me:$LINENO: \$? = $ac_status" >&5
34318  (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
34319  { (case "(($ac_try" in
34320  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
34321  *) ac_try_echo=$ac_try;;
34322esac
34323eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
34324  (eval "$ac_try") 2>&5
34325  ac_status=$?
34326  echo "$as_me:$LINENO: \$? = $ac_status" >&5
34327  (exit $ac_status); }; }; then
34328   user_path=`cat conftest.stdpath`
34329else
34330  echo "$as_me: program exited with status $ac_status" >&5
34331echo "$as_me: failed program was:" >&5
34332sed 's/^/| /' conftest.$ac_ext >&5
34333
34334( exit $ac_status )
34335 user_path="/usr/bin:/bin:/usr/sbin:/sbin"
34336fi
34337rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
34338fi
34339
34340
34341# make sure $bindir is in USER_PATH so scp will work
34342		t_bindir="${bindir}"
34343		while echo "${t_bindir}" | egrep '\$\{|NONE/' >/dev/null 2>&1; do
34344			t_bindir=`eval echo ${t_bindir}`
34345			case $t_bindir in
34346				NONE/*) t_bindir=`echo $t_bindir | sed "s~NONE~$prefix~"` ;;
34347			esac
34348			case $t_bindir in
34349				NONE/*) t_bindir=`echo $t_bindir | sed "s~NONE~$ac_default_prefix~"` ;;
34350			esac
34351		done
34352		echo $user_path | grep ":$t_bindir"  > /dev/null 2>&1
34353		if test $? -ne 0  ; then
34354			echo $user_path | grep "^$t_bindir"  > /dev/null 2>&1
34355			if test $? -ne 0  ; then
34356				user_path=$user_path:$t_bindir
34357				{ echo "$as_me:$LINENO: result: Adding $t_bindir to USER_PATH so scp will work" >&5
34358echo "${ECHO_T}Adding $t_bindir to USER_PATH so scp will work" >&6; }
34359			fi
34360		fi
34361	fi
34362
34363fi
34364
34365if test "x$external_path_file" != "x/etc/login.conf" ; then
34366
34367cat >>confdefs.h <<_ACEOF
34368#define USER_PATH "$user_path"
34369_ACEOF
34370
34371
34372fi
34373
34374# Set superuser path separately to user path
34375
34376# Check whether --with-superuser-path was given.
34377if test "${with_superuser_path+set}" = set; then
34378  withval=$with_superuser_path;
34379		if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
34380		    test "x${withval}" != "xyes"; then
34381
34382cat >>confdefs.h <<_ACEOF
34383#define SUPERUSER_PATH "$withval"
34384_ACEOF
34385
34386			superuser_path=$withval
34387		fi
34388
34389
34390fi
34391
34392
34393
34394{ echo "$as_me:$LINENO: checking if we need to convert IPv4 in IPv6-mapped addresses" >&5
34395echo $ECHO_N "checking if we need to convert IPv4 in IPv6-mapped addresses... $ECHO_C" >&6; }
34396IPV4_IN6_HACK_MSG="no"
34397
34398# Check whether --with-4in6 was given.
34399if test "${with_4in6+set}" = set; then
34400  withval=$with_4in6;
34401		if test "x$withval" != "xno" ; then
34402			{ echo "$as_me:$LINENO: result: yes" >&5
34403echo "${ECHO_T}yes" >&6; }
34404
34405cat >>confdefs.h <<\_ACEOF
34406#define IPV4_IN_IPV6 1
34407_ACEOF
34408
34409			IPV4_IN6_HACK_MSG="yes"
34410		else
34411			{ echo "$as_me:$LINENO: result: no" >&5
34412echo "${ECHO_T}no" >&6; }
34413		fi
34414
34415else
34416
34417		if test "x$inet6_default_4in6" = "xyes"; then
34418			{ echo "$as_me:$LINENO: result: yes (default)" >&5
34419echo "${ECHO_T}yes (default)" >&6; }
34420			cat >>confdefs.h <<\_ACEOF
34421#define IPV4_IN_IPV6 1
34422_ACEOF
34423
34424			IPV4_IN6_HACK_MSG="yes"
34425		else
34426			{ echo "$as_me:$LINENO: result: no (default)" >&5
34427echo "${ECHO_T}no (default)" >&6; }
34428		fi
34429
34430
34431fi
34432
34433
34434# Whether to enable BSD auth support
34435BSD_AUTH_MSG=no
34436
34437# Check whether --with-bsd-auth was given.
34438if test "${with_bsd_auth+set}" = set; then
34439  withval=$with_bsd_auth;
34440		if test "x$withval" != "xno" ; then
34441
34442cat >>confdefs.h <<\_ACEOF
34443#define BSD_AUTH 1
34444_ACEOF
34445
34446			BSD_AUTH_MSG=yes
34447		fi
34448
34449
34450fi
34451
34452
34453# Where to place sshd.pid
34454piddir=/var/run
34455# make sure the directory exists
34456if test ! -d $piddir ; then
34457	piddir=`eval echo ${sysconfdir}`
34458	case $piddir in
34459		NONE/*) piddir=`echo $piddir | sed "s~NONE~$ac_default_prefix~"` ;;
34460	esac
34461fi
34462
34463
34464# Check whether --with-pid-dir was given.
34465if test "${with_pid_dir+set}" = set; then
34466  withval=$with_pid_dir;
34467		if test -n "$withval"  &&  test "x$withval" != "xno"  &&  \
34468		    test "x${withval}" != "xyes"; then
34469			piddir=$withval
34470			if test ! -d $piddir ; then
34471			{ echo "$as_me:$LINENO: WARNING: ** no $piddir directory on this system **" >&5
34472echo "$as_me: WARNING: ** no $piddir directory on this system **" >&2;}
34473			fi
34474		fi
34475
34476
34477fi
34478
34479
34480
34481cat >>confdefs.h <<_ACEOF
34482#define _PATH_SSH_PIDDIR "$piddir"
34483_ACEOF
34484
34485
34486
34487# Check whether --enable-lastlog was given.
34488if test "${enable_lastlog+set}" = set; then
34489  enableval=$enable_lastlog;
34490		if test "x$enableval" = "xno" ; then
34491			cat >>confdefs.h <<\_ACEOF
34492#define DISABLE_LASTLOG 1
34493_ACEOF
34494
34495		fi
34496
34497
34498fi
34499
34500# Check whether --enable-utmp was given.
34501if test "${enable_utmp+set}" = set; then
34502  enableval=$enable_utmp;
34503		if test "x$enableval" = "xno" ; then
34504			cat >>confdefs.h <<\_ACEOF
34505#define DISABLE_UTMP 1
34506_ACEOF
34507
34508		fi
34509
34510
34511fi
34512
34513# Check whether --enable-utmpx was given.
34514if test "${enable_utmpx+set}" = set; then
34515  enableval=$enable_utmpx;
34516		if test "x$enableval" = "xno" ; then
34517
34518cat >>confdefs.h <<\_ACEOF
34519#define DISABLE_UTMPX 1
34520_ACEOF
34521
34522		fi
34523
34524
34525fi
34526
34527# Check whether --enable-wtmp was given.
34528if test "${enable_wtmp+set}" = set; then
34529  enableval=$enable_wtmp;
34530		if test "x$enableval" = "xno" ; then
34531			cat >>confdefs.h <<\_ACEOF
34532#define DISABLE_WTMP 1
34533_ACEOF
34534
34535		fi
34536
34537
34538fi
34539
34540# Check whether --enable-wtmpx was given.
34541if test "${enable_wtmpx+set}" = set; then
34542  enableval=$enable_wtmpx;
34543		if test "x$enableval" = "xno" ; then
34544
34545cat >>confdefs.h <<\_ACEOF
34546#define DISABLE_WTMPX 1
34547_ACEOF
34548
34549		fi
34550
34551
34552fi
34553
34554# Check whether --enable-libutil was given.
34555if test "${enable_libutil+set}" = set; then
34556  enableval=$enable_libutil;
34557		if test "x$enableval" = "xno" ; then
34558			cat >>confdefs.h <<\_ACEOF
34559#define DISABLE_LOGIN 1
34560_ACEOF
34561
34562		fi
34563
34564
34565fi
34566
34567# Check whether --enable-pututline was given.
34568if test "${enable_pututline+set}" = set; then
34569  enableval=$enable_pututline;
34570		if test "x$enableval" = "xno" ; then
34571
34572cat >>confdefs.h <<\_ACEOF
34573#define DISABLE_PUTUTLINE 1
34574_ACEOF
34575
34576		fi
34577
34578
34579fi
34580
34581# Check whether --enable-pututxline was given.
34582if test "${enable_pututxline+set}" = set; then
34583  enableval=$enable_pututxline;
34584		if test "x$enableval" = "xno" ; then
34585
34586cat >>confdefs.h <<\_ACEOF
34587#define DISABLE_PUTUTXLINE 1
34588_ACEOF
34589
34590		fi
34591
34592
34593fi
34594
34595
34596# Check whether --with-lastlog was given.
34597if test "${with_lastlog+set}" = set; then
34598  withval=$with_lastlog;
34599		if test "x$withval" = "xno" ; then
34600			cat >>confdefs.h <<\_ACEOF
34601#define DISABLE_LASTLOG 1
34602_ACEOF
34603
34604		elif test -n "$withval"  &&  test "x${withval}" != "xyes"; then
34605			conf_lastlog_location=$withval
34606		fi
34607
34608
34609fi
34610
34611
34612
34613{ echo "$as_me:$LINENO: checking if your system defines LASTLOG_FILE" >&5
34614echo $ECHO_N "checking if your system defines LASTLOG_FILE... $ECHO_C" >&6; }
34615cat >conftest.$ac_ext <<_ACEOF
34616/* confdefs.h.  */
34617_ACEOF
34618cat confdefs.h >>conftest.$ac_ext
34619cat >>conftest.$ac_ext <<_ACEOF
34620/* end confdefs.h.  */
34621
34622#include <sys/types.h>
34623#include <utmp.h>
34624#ifdef HAVE_LASTLOG_H
34625#  include <lastlog.h>
34626#endif
34627#ifdef HAVE_PATHS_H
34628#  include <paths.h>
34629#endif
34630#ifdef HAVE_LOGIN_H
34631# include <login.h>
34632#endif
34633
34634int
34635main ()
34636{
34637 char *lastlog = LASTLOG_FILE;
34638  ;
34639  return 0;
34640}
34641_ACEOF
34642rm -f conftest.$ac_objext
34643if { (ac_try="$ac_compile"
34644case "(($ac_try" in
34645  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
34646  *) ac_try_echo=$ac_try;;
34647esac
34648eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
34649  (eval "$ac_compile") 2>conftest.er1
34650  ac_status=$?
34651  grep -v '^ *+' conftest.er1 >conftest.err
34652  rm -f conftest.er1
34653  cat conftest.err >&5
34654  echo "$as_me:$LINENO: \$? = $ac_status" >&5
34655  (exit $ac_status); } && {
34656	 test -z "$ac_c_werror_flag" ||
34657	 test ! -s conftest.err
34658       } && test -s conftest.$ac_objext; then
34659   { echo "$as_me:$LINENO: result: yes" >&5
34660echo "${ECHO_T}yes" >&6; }
34661else
34662  echo "$as_me: failed program was:" >&5
34663sed 's/^/| /' conftest.$ac_ext >&5
34664
34665
34666		{ echo "$as_me:$LINENO: result: no" >&5
34667echo "${ECHO_T}no" >&6; }
34668		{ echo "$as_me:$LINENO: checking if your system defines _PATH_LASTLOG" >&5
34669echo $ECHO_N "checking if your system defines _PATH_LASTLOG... $ECHO_C" >&6; }
34670		cat >conftest.$ac_ext <<_ACEOF
34671/* confdefs.h.  */
34672_ACEOF
34673cat confdefs.h >>conftest.$ac_ext
34674cat >>conftest.$ac_ext <<_ACEOF
34675/* end confdefs.h.  */
34676
34677#include <sys/types.h>
34678#include <utmp.h>
34679#ifdef HAVE_LASTLOG_H
34680#  include <lastlog.h>
34681#endif
34682#ifdef HAVE_PATHS_H
34683#  include <paths.h>
34684#endif
34685
34686int
34687main ()
34688{
34689 char *lastlog = _PATH_LASTLOG;
34690  ;
34691  return 0;
34692}
34693_ACEOF
34694rm -f conftest.$ac_objext
34695if { (ac_try="$ac_compile"
34696case "(($ac_try" in
34697  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
34698  *) ac_try_echo=$ac_try;;
34699esac
34700eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
34701  (eval "$ac_compile") 2>conftest.er1
34702  ac_status=$?
34703  grep -v '^ *+' conftest.er1 >conftest.err
34704  rm -f conftest.er1
34705  cat conftest.err >&5
34706  echo "$as_me:$LINENO: \$? = $ac_status" >&5
34707  (exit $ac_status); } && {
34708	 test -z "$ac_c_werror_flag" ||
34709	 test ! -s conftest.err
34710       } && test -s conftest.$ac_objext; then
34711   { echo "$as_me:$LINENO: result: yes" >&5
34712echo "${ECHO_T}yes" >&6; }
34713else
34714  echo "$as_me: failed program was:" >&5
34715sed 's/^/| /' conftest.$ac_ext >&5
34716
34717
34718			{ echo "$as_me:$LINENO: result: no" >&5
34719echo "${ECHO_T}no" >&6; }
34720			system_lastlog_path=no
34721
34722fi
34723
34724rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34725
34726fi
34727
34728rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34729
34730if test -z "$conf_lastlog_location"; then
34731	if test x"$system_lastlog_path" = x"no" ; then
34732		for f in /var/log/lastlog /usr/adm/lastlog /var/adm/lastlog /etc/security/lastlog ; do
34733				if (test -d "$f" || test -f "$f") ; then
34734					conf_lastlog_location=$f
34735				fi
34736		done
34737		if test -z "$conf_lastlog_location"; then
34738			{ echo "$as_me:$LINENO: WARNING: ** Cannot find lastlog **" >&5
34739echo "$as_me: WARNING: ** Cannot find lastlog **" >&2;}
34740					fi
34741	fi
34742fi
34743
34744if test -n "$conf_lastlog_location"; then
34745
34746cat >>confdefs.h <<_ACEOF
34747#define CONF_LASTLOG_FILE "$conf_lastlog_location"
34748_ACEOF
34749
34750fi
34751
34752{ echo "$as_me:$LINENO: checking if your system defines UTMP_FILE" >&5
34753echo $ECHO_N "checking if your system defines UTMP_FILE... $ECHO_C" >&6; }
34754cat >conftest.$ac_ext <<_ACEOF
34755/* confdefs.h.  */
34756_ACEOF
34757cat confdefs.h >>conftest.$ac_ext
34758cat >>conftest.$ac_ext <<_ACEOF
34759/* end confdefs.h.  */
34760
34761#include <sys/types.h>
34762#include <utmp.h>
34763#ifdef HAVE_PATHS_H
34764#  include <paths.h>
34765#endif
34766
34767int
34768main ()
34769{
34770 char *utmp = UTMP_FILE;
34771  ;
34772  return 0;
34773}
34774_ACEOF
34775rm -f conftest.$ac_objext
34776if { (ac_try="$ac_compile"
34777case "(($ac_try" in
34778  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
34779  *) ac_try_echo=$ac_try;;
34780esac
34781eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
34782  (eval "$ac_compile") 2>conftest.er1
34783  ac_status=$?
34784  grep -v '^ *+' conftest.er1 >conftest.err
34785  rm -f conftest.er1
34786  cat conftest.err >&5
34787  echo "$as_me:$LINENO: \$? = $ac_status" >&5
34788  (exit $ac_status); } && {
34789	 test -z "$ac_c_werror_flag" ||
34790	 test ! -s conftest.err
34791       } && test -s conftest.$ac_objext; then
34792   { echo "$as_me:$LINENO: result: yes" >&5
34793echo "${ECHO_T}yes" >&6; }
34794else
34795  echo "$as_me: failed program was:" >&5
34796sed 's/^/| /' conftest.$ac_ext >&5
34797
34798	 { echo "$as_me:$LINENO: result: no" >&5
34799echo "${ECHO_T}no" >&6; }
34800	  system_utmp_path=no
34801
34802fi
34803
34804rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34805if test -z "$conf_utmp_location"; then
34806	if test x"$system_utmp_path" = x"no" ; then
34807		for f in /etc/utmp /usr/adm/utmp /var/run/utmp; do
34808			if test -f $f ; then
34809				conf_utmp_location=$f
34810			fi
34811		done
34812		if test -z "$conf_utmp_location"; then
34813			cat >>confdefs.h <<\_ACEOF
34814#define DISABLE_UTMP 1
34815_ACEOF
34816
34817		fi
34818	fi
34819fi
34820if test -n "$conf_utmp_location"; then
34821
34822cat >>confdefs.h <<_ACEOF
34823#define CONF_UTMP_FILE "$conf_utmp_location"
34824_ACEOF
34825
34826fi
34827
34828{ echo "$as_me:$LINENO: checking if your system defines WTMP_FILE" >&5
34829echo $ECHO_N "checking if your system defines WTMP_FILE... $ECHO_C" >&6; }
34830cat >conftest.$ac_ext <<_ACEOF
34831/* confdefs.h.  */
34832_ACEOF
34833cat confdefs.h >>conftest.$ac_ext
34834cat >>conftest.$ac_ext <<_ACEOF
34835/* end confdefs.h.  */
34836
34837#include <sys/types.h>
34838#include <utmp.h>
34839#ifdef HAVE_PATHS_H
34840#  include <paths.h>
34841#endif
34842
34843int
34844main ()
34845{
34846 char *wtmp = WTMP_FILE;
34847  ;
34848  return 0;
34849}
34850_ACEOF
34851rm -f conftest.$ac_objext
34852if { (ac_try="$ac_compile"
34853case "(($ac_try" in
34854  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
34855  *) ac_try_echo=$ac_try;;
34856esac
34857eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
34858  (eval "$ac_compile") 2>conftest.er1
34859  ac_status=$?
34860  grep -v '^ *+' conftest.er1 >conftest.err
34861  rm -f conftest.er1
34862  cat conftest.err >&5
34863  echo "$as_me:$LINENO: \$? = $ac_status" >&5
34864  (exit $ac_status); } && {
34865	 test -z "$ac_c_werror_flag" ||
34866	 test ! -s conftest.err
34867       } && test -s conftest.$ac_objext; then
34868   { echo "$as_me:$LINENO: result: yes" >&5
34869echo "${ECHO_T}yes" >&6; }
34870else
34871  echo "$as_me: failed program was:" >&5
34872sed 's/^/| /' conftest.$ac_ext >&5
34873
34874	 { echo "$as_me:$LINENO: result: no" >&5
34875echo "${ECHO_T}no" >&6; }
34876	  system_wtmp_path=no
34877
34878fi
34879
34880rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34881if test -z "$conf_wtmp_location"; then
34882	if test x"$system_wtmp_path" = x"no" ; then
34883		for f in /usr/adm/wtmp /var/log/wtmp; do
34884			if test -f $f ; then
34885				conf_wtmp_location=$f
34886			fi
34887		done
34888		if test -z "$conf_wtmp_location"; then
34889			cat >>confdefs.h <<\_ACEOF
34890#define DISABLE_WTMP 1
34891_ACEOF
34892
34893		fi
34894	fi
34895fi
34896if test -n "$conf_wtmp_location"; then
34897
34898cat >>confdefs.h <<_ACEOF
34899#define CONF_WTMP_FILE "$conf_wtmp_location"
34900_ACEOF
34901
34902fi
34903
34904{ echo "$as_me:$LINENO: checking if your system defines WTMPX_FILE" >&5
34905echo $ECHO_N "checking if your system defines WTMPX_FILE... $ECHO_C" >&6; }
34906cat >conftest.$ac_ext <<_ACEOF
34907/* confdefs.h.  */
34908_ACEOF
34909cat confdefs.h >>conftest.$ac_ext
34910cat >>conftest.$ac_ext <<_ACEOF
34911/* end confdefs.h.  */
34912
34913#include <sys/types.h>
34914#include <utmp.h>
34915#ifdef HAVE_UTMPX_H
34916#include <utmpx.h>
34917#endif
34918#ifdef HAVE_PATHS_H
34919#  include <paths.h>
34920#endif
34921
34922int
34923main ()
34924{
34925 char *wtmpx = WTMPX_FILE;
34926  ;
34927  return 0;
34928}
34929_ACEOF
34930rm -f conftest.$ac_objext
34931if { (ac_try="$ac_compile"
34932case "(($ac_try" in
34933  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
34934  *) ac_try_echo=$ac_try;;
34935esac
34936eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
34937  (eval "$ac_compile") 2>conftest.er1
34938  ac_status=$?
34939  grep -v '^ *+' conftest.er1 >conftest.err
34940  rm -f conftest.er1
34941  cat conftest.err >&5
34942  echo "$as_me:$LINENO: \$? = $ac_status" >&5
34943  (exit $ac_status); } && {
34944	 test -z "$ac_c_werror_flag" ||
34945	 test ! -s conftest.err
34946       } && test -s conftest.$ac_objext; then
34947   { echo "$as_me:$LINENO: result: yes" >&5
34948echo "${ECHO_T}yes" >&6; }
34949else
34950  echo "$as_me: failed program was:" >&5
34951sed 's/^/| /' conftest.$ac_ext >&5
34952
34953	 { echo "$as_me:$LINENO: result: no" >&5
34954echo "${ECHO_T}no" >&6; }
34955	  system_wtmpx_path=no
34956
34957fi
34958
34959rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
34960if test -z "$conf_wtmpx_location"; then
34961	if test x"$system_wtmpx_path" = x"no" ; then
34962		cat >>confdefs.h <<\_ACEOF
34963#define DISABLE_WTMPX 1
34964_ACEOF
34965
34966	fi
34967else
34968
34969cat >>confdefs.h <<_ACEOF
34970#define CONF_WTMPX_FILE "$conf_wtmpx_location"
34971_ACEOF
34972
34973fi
34974
34975
34976if test ! -z "$blibpath" ; then
34977	LDFLAGS="$LDFLAGS $blibflags$blibpath"
34978	{ echo "$as_me:$LINENO: WARNING: Please check and edit blibpath in LDFLAGS in Makefile" >&5
34979echo "$as_me: WARNING: Please check and edit blibpath in LDFLAGS in Makefile" >&2;}
34980fi
34981
34982{ echo "$as_me:$LINENO: checking for struct lastlog.ll_line" >&5
34983echo $ECHO_N "checking for struct lastlog.ll_line... $ECHO_C" >&6; }
34984if test "${ac_cv_member_struct_lastlog_ll_line+set}" = set; then
34985  echo $ECHO_N "(cached) $ECHO_C" >&6
34986else
34987  cat >conftest.$ac_ext <<_ACEOF
34988/* confdefs.h.  */
34989_ACEOF
34990cat confdefs.h >>conftest.$ac_ext
34991cat >>conftest.$ac_ext <<_ACEOF
34992/* end confdefs.h.  */
34993
34994#ifdef HAVE_SYS_TYPES_H
34995#include <sys/types.h>
34996#endif
34997#ifdef HAVE_UTMP_H
34998#include <utmp.h>
34999#endif
35000#ifdef HAVE_UTMPX_H
35001#include <utmpx.h>
35002#endif
35003#ifdef HAVE_LASTLOG_H
35004#include <lastlog.h>
35005#endif
35006
35007
35008int
35009main ()
35010{
35011static struct lastlog ac_aggr;
35012if (ac_aggr.ll_line)
35013return 0;
35014  ;
35015  return 0;
35016}
35017_ACEOF
35018rm -f conftest.$ac_objext
35019if { (ac_try="$ac_compile"
35020case "(($ac_try" in
35021  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
35022  *) ac_try_echo=$ac_try;;
35023esac
35024eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
35025  (eval "$ac_compile") 2>conftest.er1
35026  ac_status=$?
35027  grep -v '^ *+' conftest.er1 >conftest.err
35028  rm -f conftest.er1
35029  cat conftest.err >&5
35030  echo "$as_me:$LINENO: \$? = $ac_status" >&5
35031  (exit $ac_status); } && {
35032	 test -z "$ac_c_werror_flag" ||
35033	 test ! -s conftest.err
35034       } && test -s conftest.$ac_objext; then
35035  ac_cv_member_struct_lastlog_ll_line=yes
35036else
35037  echo "$as_me: failed program was:" >&5
35038sed 's/^/| /' conftest.$ac_ext >&5
35039
35040	cat >conftest.$ac_ext <<_ACEOF
35041/* confdefs.h.  */
35042_ACEOF
35043cat confdefs.h >>conftest.$ac_ext
35044cat >>conftest.$ac_ext <<_ACEOF
35045/* end confdefs.h.  */
35046
35047#ifdef HAVE_SYS_TYPES_H
35048#include <sys/types.h>
35049#endif
35050#ifdef HAVE_UTMP_H
35051#include <utmp.h>
35052#endif
35053#ifdef HAVE_UTMPX_H
35054#include <utmpx.h>
35055#endif
35056#ifdef HAVE_LASTLOG_H
35057#include <lastlog.h>
35058#endif
35059
35060
35061int
35062main ()
35063{
35064static struct lastlog ac_aggr;
35065if (sizeof ac_aggr.ll_line)
35066return 0;
35067  ;
35068  return 0;
35069}
35070_ACEOF
35071rm -f conftest.$ac_objext
35072if { (ac_try="$ac_compile"
35073case "(($ac_try" in
35074  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
35075  *) ac_try_echo=$ac_try;;
35076esac
35077eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
35078  (eval "$ac_compile") 2>conftest.er1
35079  ac_status=$?
35080  grep -v '^ *+' conftest.er1 >conftest.err
35081  rm -f conftest.er1
35082  cat conftest.err >&5
35083  echo "$as_me:$LINENO: \$? = $ac_status" >&5
35084  (exit $ac_status); } && {
35085	 test -z "$ac_c_werror_flag" ||
35086	 test ! -s conftest.err
35087       } && test -s conftest.$ac_objext; then
35088  ac_cv_member_struct_lastlog_ll_line=yes
35089else
35090  echo "$as_me: failed program was:" >&5
35091sed 's/^/| /' conftest.$ac_ext >&5
35092
35093	ac_cv_member_struct_lastlog_ll_line=no
35094fi
35095
35096rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35097fi
35098
35099rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35100fi
35101{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_lastlog_ll_line" >&5
35102echo "${ECHO_T}$ac_cv_member_struct_lastlog_ll_line" >&6; }
35103if test $ac_cv_member_struct_lastlog_ll_line = yes; then
35104  :
35105else
35106
35107    if test x$SKIP_DISABLE_LASTLOG_DEFINE != "xyes" ; then
35108	cat >>confdefs.h <<\_ACEOF
35109#define DISABLE_LASTLOG 1
35110_ACEOF
35111
35112    fi
35113
35114fi
35115
35116
35117{ echo "$as_me:$LINENO: checking for struct utmp.ut_line" >&5
35118echo $ECHO_N "checking for struct utmp.ut_line... $ECHO_C" >&6; }
35119if test "${ac_cv_member_struct_utmp_ut_line+set}" = set; then
35120  echo $ECHO_N "(cached) $ECHO_C" >&6
35121else
35122  cat >conftest.$ac_ext <<_ACEOF
35123/* confdefs.h.  */
35124_ACEOF
35125cat confdefs.h >>conftest.$ac_ext
35126cat >>conftest.$ac_ext <<_ACEOF
35127/* end confdefs.h.  */
35128
35129#ifdef HAVE_SYS_TYPES_H
35130#include <sys/types.h>
35131#endif
35132#ifdef HAVE_UTMP_H
35133#include <utmp.h>
35134#endif
35135#ifdef HAVE_UTMPX_H
35136#include <utmpx.h>
35137#endif
35138#ifdef HAVE_LASTLOG_H
35139#include <lastlog.h>
35140#endif
35141
35142
35143int
35144main ()
35145{
35146static struct utmp ac_aggr;
35147if (ac_aggr.ut_line)
35148return 0;
35149  ;
35150  return 0;
35151}
35152_ACEOF
35153rm -f conftest.$ac_objext
35154if { (ac_try="$ac_compile"
35155case "(($ac_try" in
35156  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
35157  *) ac_try_echo=$ac_try;;
35158esac
35159eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
35160  (eval "$ac_compile") 2>conftest.er1
35161  ac_status=$?
35162  grep -v '^ *+' conftest.er1 >conftest.err
35163  rm -f conftest.er1
35164  cat conftest.err >&5
35165  echo "$as_me:$LINENO: \$? = $ac_status" >&5
35166  (exit $ac_status); } && {
35167	 test -z "$ac_c_werror_flag" ||
35168	 test ! -s conftest.err
35169       } && test -s conftest.$ac_objext; then
35170  ac_cv_member_struct_utmp_ut_line=yes
35171else
35172  echo "$as_me: failed program was:" >&5
35173sed 's/^/| /' conftest.$ac_ext >&5
35174
35175	cat >conftest.$ac_ext <<_ACEOF
35176/* confdefs.h.  */
35177_ACEOF
35178cat confdefs.h >>conftest.$ac_ext
35179cat >>conftest.$ac_ext <<_ACEOF
35180/* end confdefs.h.  */
35181
35182#ifdef HAVE_SYS_TYPES_H
35183#include <sys/types.h>
35184#endif
35185#ifdef HAVE_UTMP_H
35186#include <utmp.h>
35187#endif
35188#ifdef HAVE_UTMPX_H
35189#include <utmpx.h>
35190#endif
35191#ifdef HAVE_LASTLOG_H
35192#include <lastlog.h>
35193#endif
35194
35195
35196int
35197main ()
35198{
35199static struct utmp ac_aggr;
35200if (sizeof ac_aggr.ut_line)
35201return 0;
35202  ;
35203  return 0;
35204}
35205_ACEOF
35206rm -f conftest.$ac_objext
35207if { (ac_try="$ac_compile"
35208case "(($ac_try" in
35209  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
35210  *) ac_try_echo=$ac_try;;
35211esac
35212eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
35213  (eval "$ac_compile") 2>conftest.er1
35214  ac_status=$?
35215  grep -v '^ *+' conftest.er1 >conftest.err
35216  rm -f conftest.er1
35217  cat conftest.err >&5
35218  echo "$as_me:$LINENO: \$? = $ac_status" >&5
35219  (exit $ac_status); } && {
35220	 test -z "$ac_c_werror_flag" ||
35221	 test ! -s conftest.err
35222       } && test -s conftest.$ac_objext; then
35223  ac_cv_member_struct_utmp_ut_line=yes
35224else
35225  echo "$as_me: failed program was:" >&5
35226sed 's/^/| /' conftest.$ac_ext >&5
35227
35228	ac_cv_member_struct_utmp_ut_line=no
35229fi
35230
35231rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35232fi
35233
35234rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35235fi
35236{ echo "$as_me:$LINENO: result: $ac_cv_member_struct_utmp_ut_line" >&5
35237echo "${ECHO_T}$ac_cv_member_struct_utmp_ut_line" >&6; }
35238if test $ac_cv_member_struct_utmp_ut_line = yes; then
35239  :
35240else
35241
35242	cat >>confdefs.h <<\_ACEOF
35243#define DISABLE_UTMP 1
35244_ACEOF
35245
35246	cat >>confdefs.h <<\_ACEOF
35247#define DISABLE_WTMP 1
35248_ACEOF
35249
35250
35251fi
35252
35253
35254CFLAGS="$CFLAGS $werror_flags"
35255
35256if test "x$ac_cv_func_getaddrinfo" != "xyes" ; then
35257	TEST_SSH_IPV6=no
35258else
35259	TEST_SSH_IPV6=yes
35260fi
35261{ echo "$as_me:$LINENO: checking whether BROKEN_GETADDRINFO is declared" >&5
35262echo $ECHO_N "checking whether BROKEN_GETADDRINFO is declared... $ECHO_C" >&6; }
35263if test "${ac_cv_have_decl_BROKEN_GETADDRINFO+set}" = set; then
35264  echo $ECHO_N "(cached) $ECHO_C" >&6
35265else
35266  cat >conftest.$ac_ext <<_ACEOF
35267/* confdefs.h.  */
35268_ACEOF
35269cat confdefs.h >>conftest.$ac_ext
35270cat >>conftest.$ac_ext <<_ACEOF
35271/* end confdefs.h.  */
35272$ac_includes_default
35273int
35274main ()
35275{
35276#ifndef BROKEN_GETADDRINFO
35277  (void) BROKEN_GETADDRINFO;
35278#endif
35279
35280  ;
35281  return 0;
35282}
35283_ACEOF
35284rm -f conftest.$ac_objext
35285if { (ac_try="$ac_compile"
35286case "(($ac_try" in
35287  *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
35288  *) ac_try_echo=$ac_try;;
35289esac
35290eval "echo \"\$as_me:$LINENO: $ac_try_echo\"") >&5
35291  (eval "$ac_compile") 2>conftest.er1
35292  ac_status=$?
35293  grep -v '^ *+' conftest.er1 >conftest.err
35294  rm -f conftest.er1
35295  cat conftest.err >&5
35296  echo "$as_me:$LINENO: \$? = $ac_status" >&5
35297  (exit $ac_status); } && {
35298	 test -z "$ac_c_werror_flag" ||
35299	 test ! -s conftest.err
35300       } && test -s conftest.$ac_objext; then
35301  ac_cv_have_decl_BROKEN_GETADDRINFO=yes
35302else
35303  echo "$as_me: failed program was:" >&5
35304sed 's/^/| /' conftest.$ac_ext >&5
35305
35306	ac_cv_have_decl_BROKEN_GETADDRINFO=no
35307fi
35308
35309rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
35310fi
35311{ echo "$as_me:$LINENO: result: $ac_cv_have_decl_BROKEN_GETADDRINFO" >&5
35312echo "${ECHO_T}$ac_cv_have_decl_BROKEN_GETADDRINFO" >&6; }
35313if test $ac_cv_have_decl_BROKEN_GETADDRINFO = yes; then
35314  TEST_SSH_IPV6=no
35315fi
35316
35317TEST_SSH_IPV6=$TEST_SSH_IPV6
35318
35319TEST_MALLOC_OPTIONS=$TEST_MALLOC_OPTIONS
35320
35321UNSUPPORTED_ALGORITHMS=$unsupported_algorithms
35322
35323
35324
35325ac_config_files="$ac_config_files Makefile buildpkg.sh opensshd.init openssh.xml openbsd-compat/Makefile openbsd-compat/regress/Makefile survey.sh"
35326
35327cat >confcache <<\_ACEOF
35328# This file is a shell script that caches the results of configure
35329# tests run on this system so they can be shared between configure
35330# scripts and configure runs, see configure's option --config-cache.
35331# It is not useful on other systems.  If it contains results you don't
35332# want to keep, you may remove or edit it.
35333#
35334# config.status only pays attention to the cache file if you give it
35335# the --recheck option to rerun configure.
35336#
35337# `ac_cv_env_foo' variables (set or unset) will be overridden when
35338# loading this file, other *unset* `ac_cv_foo' will be assigned the
35339# following values.
35340
35341_ACEOF
35342
35343# The following way of writing the cache mishandles newlines in values,
35344# but we know of no workaround that is simple, portable, and efficient.
35345# So, we kill variables containing newlines.
35346# Ultrix sh set writes to stderr and can't be redirected directly,
35347# and sets the high bit in the cache file unless we assign to the vars.
35348(
35349  for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
35350    eval ac_val=\$$ac_var
35351    case $ac_val in #(
35352    *${as_nl}*)
35353      case $ac_var in #(
35354      *_cv_*) { echo "$as_me:$LINENO: WARNING: Cache variable $ac_var contains a newline." >&5
35355echo "$as_me: WARNING: Cache variable $ac_var contains a newline." >&2;} ;;
35356      esac
35357      case $ac_var in #(
35358      _ | IFS | as_nl) ;; #(
35359      *) $as_unset $ac_var ;;
35360      esac ;;
35361    esac
35362  done
35363
35364  (set) 2>&1 |
35365    case $as_nl`(ac_space=' '; set) 2>&1` in #(
35366    *${as_nl}ac_space=\ *)
35367      # `set' does not quote correctly, so add quotes (double-quote
35368      # substitution turns \\\\ into \\, and sed turns \\ into \).
35369      sed -n \
35370	"s/'/'\\\\''/g;
35371	  s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
35372      ;; #(
35373    *)
35374      # `set' quotes correctly as required by POSIX, so do not add quotes.
35375      sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
35376      ;;
35377    esac |
35378    sort
35379) |
35380  sed '
35381     /^ac_cv_env_/b end
35382     t clear
35383     :clear
35384     s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
35385     t end
35386     s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
35387     :end' >>confcache
35388if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
35389  if test -w "$cache_file"; then
35390    test "x$cache_file" != "x/dev/null" &&
35391      { echo "$as_me:$LINENO: updating cache $cache_file" >&5
35392echo "$as_me: updating cache $cache_file" >&6;}
35393    cat confcache >$cache_file
35394  else
35395    { echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
35396echo "$as_me: not updating unwritable cache $cache_file" >&6;}
35397  fi
35398fi
35399rm -f confcache
35400
35401test "x$prefix" = xNONE && prefix=$ac_default_prefix
35402# Let make expand exec_prefix.
35403test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
35404
35405DEFS=-DHAVE_CONFIG_H
35406
35407ac_libobjs=
35408ac_ltlibobjs=
35409for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
35410  # 1. Remove the extension, and $U if already installed.
35411  ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
35412  ac_i=`echo "$ac_i" | sed "$ac_script"`
35413  # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
35414  #    will be set to the directory where LIBOBJS objects are built.
35415  ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
35416  ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
35417done
35418LIBOBJS=$ac_libobjs
35419
35420LTLIBOBJS=$ac_ltlibobjs
35421
35422
35423
35424: ${CONFIG_STATUS=./config.status}
35425ac_clean_files_save=$ac_clean_files
35426ac_clean_files="$ac_clean_files $CONFIG_STATUS"
35427{ echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
35428echo "$as_me: creating $CONFIG_STATUS" >&6;}
35429cat >$CONFIG_STATUS <<_ACEOF
35430#! $SHELL
35431# Generated by $as_me.
35432# Run this file to recreate the current configuration.
35433# Compiler output produced by configure, useful for debugging
35434# configure, is in config.log if it exists.
35435
35436debug=false
35437ac_cs_recheck=false
35438ac_cs_silent=false
35439SHELL=\${CONFIG_SHELL-$SHELL}
35440_ACEOF
35441
35442cat >>$CONFIG_STATUS <<\_ACEOF
35443## --------------------- ##
35444## M4sh Initialization.  ##
35445## --------------------- ##
35446
35447# Be more Bourne compatible
35448DUALCASE=1; export DUALCASE # for MKS sh
35449if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
35450  emulate sh
35451  NULLCMD=:
35452  # Zsh 3.x and 4.x performs word splitting on ${1+"$@"}, which
35453  # is contrary to our usage.  Disable this feature.
35454  alias -g '${1+"$@"}'='"$@"'
35455  setopt NO_GLOB_SUBST
35456else
35457  case `(set -o) 2>/dev/null` in
35458  *posix*) set -o posix ;;
35459esac
35460
35461fi
35462
35463
35464
35465
35466# PATH needs CR
35467# Avoid depending upon Character Ranges.
35468as_cr_letters='abcdefghijklmnopqrstuvwxyz'
35469as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
35470as_cr_Letters=$as_cr_letters$as_cr_LETTERS
35471as_cr_digits='0123456789'
35472as_cr_alnum=$as_cr_Letters$as_cr_digits
35473
35474# The user is always right.
35475if test "${PATH_SEPARATOR+set}" != set; then
35476  echo "#! /bin/sh" >conf$$.sh
35477  echo  "exit 0"   >>conf$$.sh
35478  chmod +x conf$$.sh
35479  if (PATH="/nonexistent;."; conf$$.sh) >/dev/null 2>&1; then
35480    PATH_SEPARATOR=';'
35481  else
35482    PATH_SEPARATOR=:
35483  fi
35484  rm -f conf$$.sh
35485fi
35486
35487# Support unset when possible.
35488if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
35489  as_unset=unset
35490else
35491  as_unset=false
35492fi
35493
35494
35495# IFS
35496# We need space, tab and new line, in precisely that order.  Quoting is
35497# there to prevent editors from complaining about space-tab.
35498# (If _AS_PATH_WALK were called with IFS unset, it would disable word
35499# splitting by setting IFS to empty value.)
35500as_nl='
35501'
35502IFS=" ""	$as_nl"
35503
35504# Find who we are.  Look in the path if we contain no directory separator.
35505case $0 in
35506  *[\\/]* ) as_myself=$0 ;;
35507  *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
35508for as_dir in $PATH
35509do
35510  IFS=$as_save_IFS
35511  test -z "$as_dir" && as_dir=.
35512  test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
35513done
35514IFS=$as_save_IFS
35515
35516     ;;
35517esac
35518# We did not find ourselves, most probably we were run as `sh COMMAND'
35519# in which case we are not to be found in the path.
35520if test "x$as_myself" = x; then
35521  as_myself=$0
35522fi
35523if test ! -f "$as_myself"; then
35524  echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
35525  { (exit 1); exit 1; }
35526fi
35527
35528# Work around bugs in pre-3.0 UWIN ksh.
35529for as_var in ENV MAIL MAILPATH
35530do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
35531done
35532PS1='$ '
35533PS2='> '
35534PS4='+ '
35535
35536# NLS nuisances.
35537for as_var in \
35538  LANG LANGUAGE LC_ADDRESS LC_ALL LC_COLLATE LC_CTYPE LC_IDENTIFICATION \
35539  LC_MEASUREMENT LC_MESSAGES LC_MONETARY LC_NAME LC_NUMERIC LC_PAPER \
35540  LC_TELEPHONE LC_TIME
35541do
35542  if (set +x; test -z "`(eval $as_var=C; export $as_var) 2>&1`"); then
35543    eval $as_var=C; export $as_var
35544  else
35545    ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
35546  fi
35547done
35548
35549# Required to use basename.
35550if expr a : '\(a\)' >/dev/null 2>&1 &&
35551   test "X`expr 00001 : '.*\(...\)'`" = X001; then
35552  as_expr=expr
35553else
35554  as_expr=false
35555fi
35556
35557if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
35558  as_basename=basename
35559else
35560  as_basename=false
35561fi
35562
35563
35564# Name of the executable.
35565as_me=`$as_basename -- "$0" ||
35566$as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
35567	 X"$0" : 'X\(//\)$' \| \
35568	 X"$0" : 'X\(/\)' \| . 2>/dev/null ||
35569echo X/"$0" |
35570    sed '/^.*\/\([^/][^/]*\)\/*$/{
35571	    s//\1/
35572	    q
35573	  }
35574	  /^X\/\(\/\/\)$/{
35575	    s//\1/
35576	    q
35577	  }
35578	  /^X\/\(\/\).*/{
35579	    s//\1/
35580	    q
35581	  }
35582	  s/.*/./; q'`
35583
35584# CDPATH.
35585$as_unset CDPATH
35586
35587
35588
35589  as_lineno_1=$LINENO
35590  as_lineno_2=$LINENO
35591  test "x$as_lineno_1" != "x$as_lineno_2" &&
35592  test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
35593
35594  # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
35595  # uniformly replaced by the line number.  The first 'sed' inserts a
35596  # line-number line after each line using $LINENO; the second 'sed'
35597  # does the real work.  The second script uses 'N' to pair each
35598  # line-number line with the line containing $LINENO, and appends
35599  # trailing '-' during substitution so that $LINENO is not a special
35600  # case at line end.
35601  # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
35602  # scripts with optimization help from Paolo Bonzini.  Blame Lee
35603  # E. McMahon (1931-1989) for sed's syntax.  :-)
35604  sed -n '
35605    p
35606    /[$]LINENO/=
35607  ' <$as_myself |
35608    sed '
35609      s/[$]LINENO.*/&-/
35610      t lineno
35611      b
35612      :lineno
35613      N
35614      :loop
35615      s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
35616      t loop
35617      s/-\n.*//
35618    ' >$as_me.lineno &&
35619  chmod +x "$as_me.lineno" ||
35620    { echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
35621   { (exit 1); exit 1; }; }
35622
35623  # Don't try to exec as it changes $[0], causing all sort of problems
35624  # (the dirname of $[0] is not the place where we might find the
35625  # original and so on.  Autoconf is especially sensitive to this).
35626  . "./$as_me.lineno"
35627  # Exit status is that of the last command.
35628  exit
35629}
35630
35631
35632if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
35633  as_dirname=dirname
35634else
35635  as_dirname=false
35636fi
35637
35638ECHO_C= ECHO_N= ECHO_T=
35639case `echo -n x` in
35640-n*)
35641  case `echo 'x\c'` in
35642  *c*) ECHO_T='	';;	# ECHO_T is single tab character.
35643  *)   ECHO_C='\c';;
35644  esac;;
35645*)
35646  ECHO_N='-n';;
35647esac
35648
35649if expr a : '\(a\)' >/dev/null 2>&1 &&
35650   test "X`expr 00001 : '.*\(...\)'`" = X001; then
35651  as_expr=expr
35652else
35653  as_expr=false
35654fi
35655
35656rm -f conf$$ conf$$.exe conf$$.file
35657if test -d conf$$.dir; then
35658  rm -f conf$$.dir/conf$$.file
35659else
35660  rm -f conf$$.dir
35661  mkdir conf$$.dir
35662fi
35663echo >conf$$.file
35664if ln -s conf$$.file conf$$ 2>/dev/null; then
35665  as_ln_s='ln -s'
35666  # ... but there are two gotchas:
35667  # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
35668  # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
35669  # In both cases, we have to default to `cp -p'.
35670  ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
35671    as_ln_s='cp -p'
35672elif ln conf$$.file conf$$ 2>/dev/null; then
35673  as_ln_s=ln
35674else
35675  as_ln_s='cp -p'
35676fi
35677rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
35678rmdir conf$$.dir 2>/dev/null
35679
35680if mkdir -p . 2>/dev/null; then
35681  as_mkdir_p=:
35682else
35683  test -d ./-p && rmdir ./-p
35684  as_mkdir_p=false
35685fi
35686
35687if test -x / >/dev/null 2>&1; then
35688  as_test_x='test -x'
35689else
35690  if ls -dL / >/dev/null 2>&1; then
35691    as_ls_L_option=L
35692  else
35693    as_ls_L_option=
35694  fi
35695  as_test_x='
35696    eval sh -c '\''
35697      if test -d "$1"; then
35698        test -d "$1/.";
35699      else
35700	case $1 in
35701        -*)set "./$1";;
35702	esac;
35703	case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
35704	???[sx]*):;;*)false;;esac;fi
35705    '\'' sh
35706  '
35707fi
35708as_executable_p=$as_test_x
35709
35710# Sed expression to map a string onto a valid CPP name.
35711as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
35712
35713# Sed expression to map a string onto a valid variable name.
35714as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
35715
35716
35717exec 6>&1
35718
35719# Save the log message, to keep $[0] and so on meaningful, and to
35720# report actual input values of CONFIG_FILES etc. instead of their
35721# values after options handling.
35722ac_log="
35723This file was extended by OpenSSH $as_me Portable, which was
35724generated by GNU Autoconf 2.61.  Invocation command line was
35725
35726  CONFIG_FILES    = $CONFIG_FILES
35727  CONFIG_HEADERS  = $CONFIG_HEADERS
35728  CONFIG_LINKS    = $CONFIG_LINKS
35729  CONFIG_COMMANDS = $CONFIG_COMMANDS
35730  $ $0 $@
35731
35732on `(hostname || uname -n) 2>/dev/null | sed 1q`
35733"
35734
35735_ACEOF
35736
35737cat >>$CONFIG_STATUS <<_ACEOF
35738# Files that config.status was made for.
35739config_files="$ac_config_files"
35740config_headers="$ac_config_headers"
35741
35742_ACEOF
35743
35744cat >>$CONFIG_STATUS <<\_ACEOF
35745ac_cs_usage="\
35746\`$as_me' instantiates files from templates according to the
35747current configuration.
35748
35749Usage: $0 [OPTIONS] [FILE]...
35750
35751  -h, --help       print this help, then exit
35752  -V, --version    print version number and configuration settings, then exit
35753  -q, --quiet      do not print progress messages
35754  -d, --debug      don't remove temporary files
35755      --recheck    update $as_me by reconfiguring in the same conditions
35756  --file=FILE[:TEMPLATE]
35757		   instantiate the configuration file FILE
35758  --header=FILE[:TEMPLATE]
35759		   instantiate the configuration header FILE
35760
35761Configuration files:
35762$config_files
35763
35764Configuration headers:
35765$config_headers
35766
35767Report bugs to <bug-autoconf@gnu.org>."
35768
35769_ACEOF
35770cat >>$CONFIG_STATUS <<_ACEOF
35771ac_cs_version="\\
35772OpenSSH config.status Portable
35773configured by $0, generated by GNU Autoconf 2.61,
35774  with options \\"`echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
35775
35776Copyright (C) 2006 Free Software Foundation, Inc.
35777This config.status script is free software; the Free Software Foundation
35778gives unlimited permission to copy, distribute and modify it."
35779
35780ac_pwd='$ac_pwd'
35781srcdir='$srcdir'
35782INSTALL='$INSTALL'
35783_ACEOF
35784
35785cat >>$CONFIG_STATUS <<\_ACEOF
35786# If no file are specified by the user, then we need to provide default
35787# value.  By we need to know if files were specified by the user.
35788ac_need_defaults=:
35789while test $# != 0
35790do
35791  case $1 in
35792  --*=*)
35793    ac_option=`expr "X$1" : 'X\([^=]*\)='`
35794    ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
35795    ac_shift=:
35796    ;;
35797  *)
35798    ac_option=$1
35799    ac_optarg=$2
35800    ac_shift=shift
35801    ;;
35802  esac
35803
35804  case $ac_option in
35805  # Handling of the options.
35806  -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
35807    ac_cs_recheck=: ;;
35808  --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
35809    echo "$ac_cs_version"; exit ;;
35810  --debug | --debu | --deb | --de | --d | -d )
35811    debug=: ;;
35812  --file | --fil | --fi | --f )
35813    $ac_shift
35814    CONFIG_FILES="$CONFIG_FILES $ac_optarg"
35815    ac_need_defaults=false;;
35816  --header | --heade | --head | --hea )
35817    $ac_shift
35818    CONFIG_HEADERS="$CONFIG_HEADERS $ac_optarg"
35819    ac_need_defaults=false;;
35820  --he | --h)
35821    # Conflict between --help and --header
35822    { echo "$as_me: error: ambiguous option: $1
35823Try \`$0 --help' for more information." >&2
35824   { (exit 1); exit 1; }; };;
35825  --help | --hel | -h )
35826    echo "$ac_cs_usage"; exit ;;
35827  -q | -quiet | --quiet | --quie | --qui | --qu | --q \
35828  | -silent | --silent | --silen | --sile | --sil | --si | --s)
35829    ac_cs_silent=: ;;
35830
35831  # This is an error.
35832  -*) { echo "$as_me: error: unrecognized option: $1
35833Try \`$0 --help' for more information." >&2
35834   { (exit 1); exit 1; }; } ;;
35835
35836  *) ac_config_targets="$ac_config_targets $1"
35837     ac_need_defaults=false ;;
35838
35839  esac
35840  shift
35841done
35842
35843ac_configure_extra_args=
35844
35845if $ac_cs_silent; then
35846  exec 6>/dev/null
35847  ac_configure_extra_args="$ac_configure_extra_args --silent"
35848fi
35849
35850_ACEOF
35851cat >>$CONFIG_STATUS <<_ACEOF
35852if \$ac_cs_recheck; then
35853  echo "running CONFIG_SHELL=$SHELL $SHELL $0 "$ac_configure_args \$ac_configure_extra_args " --no-create --no-recursion" >&6
35854  CONFIG_SHELL=$SHELL
35855  export CONFIG_SHELL
35856  exec $SHELL "$0"$ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
35857fi
35858
35859_ACEOF
35860cat >>$CONFIG_STATUS <<\_ACEOF
35861exec 5>>config.log
35862{
35863  echo
35864  sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
35865## Running $as_me. ##
35866_ASBOX
35867  echo "$ac_log"
35868} >&5
35869
35870_ACEOF
35871cat >>$CONFIG_STATUS <<_ACEOF
35872_ACEOF
35873
35874cat >>$CONFIG_STATUS <<\_ACEOF
35875
35876# Handling of arguments.
35877for ac_config_target in $ac_config_targets
35878do
35879  case $ac_config_target in
35880    "config.h") CONFIG_HEADERS="$CONFIG_HEADERS config.h" ;;
35881    "Makefile") CONFIG_FILES="$CONFIG_FILES Makefile" ;;
35882    "buildpkg.sh") CONFIG_FILES="$CONFIG_FILES buildpkg.sh" ;;
35883    "opensshd.init") CONFIG_FILES="$CONFIG_FILES opensshd.init" ;;
35884    "openssh.xml") CONFIG_FILES="$CONFIG_FILES openssh.xml" ;;
35885    "openbsd-compat/Makefile") CONFIG_FILES="$CONFIG_FILES openbsd-compat/Makefile" ;;
35886    "openbsd-compat/regress/Makefile") CONFIG_FILES="$CONFIG_FILES openbsd-compat/regress/Makefile" ;;
35887    "survey.sh") CONFIG_FILES="$CONFIG_FILES survey.sh" ;;
35888
35889  *) { { echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
35890echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
35891   { (exit 1); exit 1; }; };;
35892  esac
35893done
35894
35895
35896# If the user did not use the arguments to specify the items to instantiate,
35897# then the envvar interface is used.  Set only those that are not.
35898# We use the long form for the default assignment because of an extremely
35899# bizarre bug on SunOS 4.1.3.
35900if $ac_need_defaults; then
35901  test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
35902  test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
35903fi
35904
35905# Have a temporary directory for convenience.  Make it in the build tree
35906# simply because there is no reason against having it here, and in addition,
35907# creating and moving files from /tmp can sometimes cause problems.
35908# Hook for its removal unless debugging.
35909# Note that there is a small window in which the directory will not be cleaned:
35910# after its creation but before its name has been assigned to `$tmp'.
35911$debug ||
35912{
35913  tmp=
35914  trap 'exit_status=$?
35915  { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
35916' 0
35917  trap '{ (exit 1); exit 1; }' 1 2 13 15
35918}
35919# Create a (secure) tmp directory for tmp files.
35920
35921{
35922  tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
35923  test -n "$tmp" && test -d "$tmp"
35924}  ||
35925{
35926  tmp=./conf$$-$RANDOM
35927  (umask 077 && mkdir "$tmp")
35928} ||
35929{
35930   echo "$me: cannot create a temporary directory in ." >&2
35931   { (exit 1); exit 1; }
35932}
35933
35934#
35935# Set up the sed scripts for CONFIG_FILES section.
35936#
35937
35938# No need to generate the scripts if there are no CONFIG_FILES.
35939# This happens for instance when ./config.status config.h
35940if test -n "$CONFIG_FILES"; then
35941
35942_ACEOF
35943
35944
35945
35946ac_delim='%!_!# '
35947for ac_last_try in false false false false false :; do
35948  cat >conf$$subs.sed <<_ACEOF
35949SHELL!$SHELL$ac_delim
35950PATH_SEPARATOR!$PATH_SEPARATOR$ac_delim
35951PACKAGE_NAME!$PACKAGE_NAME$ac_delim
35952PACKAGE_TARNAME!$PACKAGE_TARNAME$ac_delim
35953PACKAGE_VERSION!$PACKAGE_VERSION$ac_delim
35954PACKAGE_STRING!$PACKAGE_STRING$ac_delim
35955PACKAGE_BUGREPORT!$PACKAGE_BUGREPORT$ac_delim
35956exec_prefix!$exec_prefix$ac_delim
35957prefix!$prefix$ac_delim
35958program_transform_name!$program_transform_name$ac_delim
35959bindir!$bindir$ac_delim
35960sbindir!$sbindir$ac_delim
35961libexecdir!$libexecdir$ac_delim
35962datarootdir!$datarootdir$ac_delim
35963datadir!$datadir$ac_delim
35964sysconfdir!$sysconfdir$ac_delim
35965sharedstatedir!$sharedstatedir$ac_delim
35966localstatedir!$localstatedir$ac_delim
35967includedir!$includedir$ac_delim
35968oldincludedir!$oldincludedir$ac_delim
35969docdir!$docdir$ac_delim
35970infodir!$infodir$ac_delim
35971htmldir!$htmldir$ac_delim
35972dvidir!$dvidir$ac_delim
35973pdfdir!$pdfdir$ac_delim
35974psdir!$psdir$ac_delim
35975libdir!$libdir$ac_delim
35976localedir!$localedir$ac_delim
35977mandir!$mandir$ac_delim
35978DEFS!$DEFS$ac_delim
35979ECHO_C!$ECHO_C$ac_delim
35980ECHO_N!$ECHO_N$ac_delim
35981ECHO_T!$ECHO_T$ac_delim
35982LIBS!$LIBS$ac_delim
35983build_alias!$build_alias$ac_delim
35984host_alias!$host_alias$ac_delim
35985target_alias!$target_alias$ac_delim
35986CC!$CC$ac_delim
35987CFLAGS!$CFLAGS$ac_delim
35988LDFLAGS!$LDFLAGS$ac_delim
35989CPPFLAGS!$CPPFLAGS$ac_delim
35990ac_ct_CC!$ac_ct_CC$ac_delim
35991EXEEXT!$EXEEXT$ac_delim
35992OBJEXT!$OBJEXT$ac_delim
35993build!$build$ac_delim
35994build_cpu!$build_cpu$ac_delim
35995build_vendor!$build_vendor$ac_delim
35996build_os!$build_os$ac_delim
35997host!$host$ac_delim
35998host_cpu!$host_cpu$ac_delim
35999host_vendor!$host_vendor$ac_delim
36000host_os!$host_os$ac_delim
36001CPP!$CPP$ac_delim
36002GREP!$GREP$ac_delim
36003EGREP!$EGREP$ac_delim
36004AWK!$AWK$ac_delim
36005RANLIB!$RANLIB$ac_delim
36006INSTALL_PROGRAM!$INSTALL_PROGRAM$ac_delim
36007INSTALL_SCRIPT!$INSTALL_SCRIPT$ac_delim
36008INSTALL_DATA!$INSTALL_DATA$ac_delim
36009AR!$AR$ac_delim
36010CAT!$CAT$ac_delim
36011KILL!$KILL$ac_delim
36012PERL!$PERL$ac_delim
36013SED!$SED$ac_delim
36014ENT!$ENT$ac_delim
36015TEST_MINUS_S_SH!$TEST_MINUS_S_SH$ac_delim
36016SH!$SH$ac_delim
36017GROFF!$GROFF$ac_delim
36018NROFF!$NROFF$ac_delim
36019MANDOC!$MANDOC$ac_delim
36020TEST_SHELL!$TEST_SHELL$ac_delim
36021MANFMT!$MANFMT$ac_delim
36022PATH_GROUPADD_PROG!$PATH_GROUPADD_PROG$ac_delim
36023PATH_USERADD_PROG!$PATH_USERADD_PROG$ac_delim
36024MAKE_PACKAGE_SUPPORTED!$MAKE_PACKAGE_SUPPORTED$ac_delim
36025STARTUP_SCRIPT_SHELL!$STARTUP_SCRIPT_SHELL$ac_delim
36026LOGIN_PROGRAM_FALLBACK!$LOGIN_PROGRAM_FALLBACK$ac_delim
36027PATH_PASSWD_PROG!$PATH_PASSWD_PROG$ac_delim
36028LD!$LD$ac_delim
36029PKGCONFIG!$PKGCONFIG$ac_delim
36030LIBEDIT!$LIBEDIT$ac_delim
36031TEST_SSH_ECC!$TEST_SSH_ECC$ac_delim
36032COMMENT_OUT_ECC!$COMMENT_OUT_ECC$ac_delim
36033SSH_PRIVSEP_USER!$SSH_PRIVSEP_USER$ac_delim
36034SSHLIBS!$SSHLIBS$ac_delim
36035SSHDLIBS!$SSHDLIBS$ac_delim
36036KRB5CONF!$KRB5CONF$ac_delim
36037GSSLIBS!$GSSLIBS$ac_delim
36038K5LIBS!$K5LIBS$ac_delim
36039PRIVSEP_PATH!$PRIVSEP_PATH$ac_delim
36040xauth_path!$xauth_path$ac_delim
36041STRIP_OPT!$STRIP_OPT$ac_delim
36042XAUTH_PATH!$XAUTH_PATH$ac_delim
36043MANTYPE!$MANTYPE$ac_delim
36044mansubdir!$mansubdir$ac_delim
36045user_path!$user_path$ac_delim
36046_ACEOF
36047
36048  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 97; then
36049    break
36050  elif $ac_last_try; then
36051    { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
36052echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
36053   { (exit 1); exit 1; }; }
36054  else
36055    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
36056  fi
36057done
36058
36059ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
36060if test -n "$ac_eof"; then
36061  ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
36062  ac_eof=`expr $ac_eof + 1`
36063fi
36064
36065cat >>$CONFIG_STATUS <<_ACEOF
36066cat >"\$tmp/subs-1.sed" <<\CEOF$ac_eof
36067/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
36068_ACEOF
36069sed '
36070s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
36071s/^/s,@/; s/!/@,|#_!!_#|/
36072:n
36073t n
36074s/'"$ac_delim"'$/,g/; t
36075s/$/\\/; p
36076N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
36077' >>$CONFIG_STATUS <conf$$subs.sed
36078rm -f conf$$subs.sed
36079cat >>$CONFIG_STATUS <<_ACEOF
36080CEOF$ac_eof
36081_ACEOF
36082
36083
36084ac_delim='%!_!# '
36085for ac_last_try in false false false false false :; do
36086  cat >conf$$subs.sed <<_ACEOF
36087piddir!$piddir$ac_delim
36088TEST_SSH_IPV6!$TEST_SSH_IPV6$ac_delim
36089TEST_MALLOC_OPTIONS!$TEST_MALLOC_OPTIONS$ac_delim
36090UNSUPPORTED_ALGORITHMS!$UNSUPPORTED_ALGORITHMS$ac_delim
36091LIBOBJS!$LIBOBJS$ac_delim
36092LTLIBOBJS!$LTLIBOBJS$ac_delim
36093_ACEOF
36094
36095  if test `sed -n "s/.*$ac_delim\$/X/p" conf$$subs.sed | grep -c X` = 6; then
36096    break
36097  elif $ac_last_try; then
36098    { { echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
36099echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
36100   { (exit 1); exit 1; }; }
36101  else
36102    ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
36103  fi
36104done
36105
36106ac_eof=`sed -n '/^CEOF[0-9]*$/s/CEOF/0/p' conf$$subs.sed`
36107if test -n "$ac_eof"; then
36108  ac_eof=`echo "$ac_eof" | sort -nru | sed 1q`
36109  ac_eof=`expr $ac_eof + 1`
36110fi
36111
36112cat >>$CONFIG_STATUS <<_ACEOF
36113cat >"\$tmp/subs-2.sed" <<\CEOF$ac_eof
36114/@[a-zA-Z_][a-zA-Z_0-9]*@/!b end
36115_ACEOF
36116sed '
36117s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g
36118s/^/s,@/; s/!/@,|#_!!_#|/
36119:n
36120t n
36121s/'"$ac_delim"'$/,g/; t
36122s/$/\\/; p
36123N; s/^.*\n//; s/[,\\&]/\\&/g; s/@/@|#_!!_#|/g; b n
36124' >>$CONFIG_STATUS <conf$$subs.sed
36125rm -f conf$$subs.sed
36126cat >>$CONFIG_STATUS <<_ACEOF
36127:end
36128s/|#_!!_#|//g
36129CEOF$ac_eof
36130_ACEOF
36131
36132
36133# VPATH may cause trouble with some makes, so we remove $(srcdir),
36134# ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
36135# trailing colons and then remove the whole line if VPATH becomes empty
36136# (actually we leave an empty line to preserve line numbers).
36137if test "x$srcdir" = x.; then
36138  ac_vpsub='/^[	 ]*VPATH[	 ]*=/{
36139s/:*\$(srcdir):*/:/
36140s/:*\${srcdir}:*/:/
36141s/:*@srcdir@:*/:/
36142s/^\([^=]*=[	 ]*\):*/\1/
36143s/:*$//
36144s/^[^=]*=[	 ]*$//
36145}'
36146fi
36147
36148cat >>$CONFIG_STATUS <<\_ACEOF
36149fi # test -n "$CONFIG_FILES"
36150
36151
36152for ac_tag in  :F $CONFIG_FILES  :H $CONFIG_HEADERS
36153do
36154  case $ac_tag in
36155  :[FHLC]) ac_mode=$ac_tag; continue;;
36156  esac
36157  case $ac_mode$ac_tag in
36158  :[FHL]*:*);;
36159  :L* | :C*:*) { { echo "$as_me:$LINENO: error: Invalid tag $ac_tag." >&5
36160echo "$as_me: error: Invalid tag $ac_tag." >&2;}
36161   { (exit 1); exit 1; }; };;
36162  :[FH]-) ac_tag=-:-;;
36163  :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
36164  esac
36165  ac_save_IFS=$IFS
36166  IFS=:
36167  set x $ac_tag
36168  IFS=$ac_save_IFS
36169  shift
36170  ac_file=$1
36171  shift
36172
36173  case $ac_mode in
36174  :L) ac_source=$1;;
36175  :[FH])
36176    ac_file_inputs=
36177    for ac_f
36178    do
36179      case $ac_f in
36180      -) ac_f="$tmp/stdin";;
36181      *) # Look for the file first in the build tree, then in the source tree
36182	 # (if the path is not absolute).  The absolute path cannot be DOS-style,
36183	 # because $ac_f cannot contain `:'.
36184	 test -f "$ac_f" ||
36185	   case $ac_f in
36186	   [\\/$]*) false;;
36187	   *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
36188	   esac ||
36189	   { { echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
36190echo "$as_me: error: cannot find input file: $ac_f" >&2;}
36191   { (exit 1); exit 1; }; };;
36192      esac
36193      ac_file_inputs="$ac_file_inputs $ac_f"
36194    done
36195
36196    # Let's still pretend it is `configure' which instantiates (i.e., don't
36197    # use $as_me), people would be surprised to read:
36198    #    /* config.h.  Generated by config.status.  */
36199    configure_input="Generated from "`IFS=:
36200	  echo $* | sed 's|^[^:]*/||;s|:[^:]*/|, |g'`" by configure."
36201    if test x"$ac_file" != x-; then
36202      configure_input="$ac_file.  $configure_input"
36203      { echo "$as_me:$LINENO: creating $ac_file" >&5
36204echo "$as_me: creating $ac_file" >&6;}
36205    fi
36206
36207    case $ac_tag in
36208    *:-:* | *:-) cat >"$tmp/stdin";;
36209    esac
36210    ;;
36211  esac
36212
36213  ac_dir=`$as_dirname -- "$ac_file" ||
36214$as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
36215	 X"$ac_file" : 'X\(//\)[^/]' \| \
36216	 X"$ac_file" : 'X\(//\)$' \| \
36217	 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
36218echo X"$ac_file" |
36219    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
36220	    s//\1/
36221	    q
36222	  }
36223	  /^X\(\/\/\)[^/].*/{
36224	    s//\1/
36225	    q
36226	  }
36227	  /^X\(\/\/\)$/{
36228	    s//\1/
36229	    q
36230	  }
36231	  /^X\(\/\).*/{
36232	    s//\1/
36233	    q
36234	  }
36235	  s/.*/./; q'`
36236  { as_dir="$ac_dir"
36237  case $as_dir in #(
36238  -*) as_dir=./$as_dir;;
36239  esac
36240  test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
36241    as_dirs=
36242    while :; do
36243      case $as_dir in #(
36244      *\'*) as_qdir=`echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #(
36245      *) as_qdir=$as_dir;;
36246      esac
36247      as_dirs="'$as_qdir' $as_dirs"
36248      as_dir=`$as_dirname -- "$as_dir" ||
36249$as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
36250	 X"$as_dir" : 'X\(//\)[^/]' \| \
36251	 X"$as_dir" : 'X\(//\)$' \| \
36252	 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
36253echo X"$as_dir" |
36254    sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
36255	    s//\1/
36256	    q
36257	  }
36258	  /^X\(\/\/\)[^/].*/{
36259	    s//\1/
36260	    q
36261	  }
36262	  /^X\(\/\/\)$/{
36263	    s//\1/
36264	    q
36265	  }
36266	  /^X\(\/\).*/{
36267	    s//\1/
36268	    q
36269	  }
36270	  s/.*/./; q'`
36271      test -d "$as_dir" && break
36272    done
36273    test -z "$as_dirs" || eval "mkdir $as_dirs"
36274  } || test -d "$as_dir" || { { echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
36275echo "$as_me: error: cannot create directory $as_dir" >&2;}
36276   { (exit 1); exit 1; }; }; }
36277  ac_builddir=.
36278
36279case "$ac_dir" in
36280.) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
36281*)
36282  ac_dir_suffix=/`echo "$ac_dir" | sed 's,^\.[\\/],,'`
36283  # A ".." for each directory in $ac_dir_suffix.
36284  ac_top_builddir_sub=`echo "$ac_dir_suffix" | sed 's,/[^\\/]*,/..,g;s,/,,'`
36285  case $ac_top_builddir_sub in
36286  "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
36287  *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
36288  esac ;;
36289esac
36290ac_abs_top_builddir=$ac_pwd
36291ac_abs_builddir=$ac_pwd$ac_dir_suffix
36292# for backward compatibility:
36293ac_top_builddir=$ac_top_build_prefix
36294
36295case $srcdir in
36296  .)  # We are building in place.
36297    ac_srcdir=.
36298    ac_top_srcdir=$ac_top_builddir_sub
36299    ac_abs_top_srcdir=$ac_pwd ;;
36300  [\\/]* | ?:[\\/]* )  # Absolute name.
36301    ac_srcdir=$srcdir$ac_dir_suffix;
36302    ac_top_srcdir=$srcdir
36303    ac_abs_top_srcdir=$srcdir ;;
36304  *) # Relative name.
36305    ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
36306    ac_top_srcdir=$ac_top_build_prefix$srcdir
36307    ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
36308esac
36309ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
36310
36311
36312  case $ac_mode in
36313  :F)
36314  #
36315  # CONFIG_FILE
36316  #
36317
36318  case $INSTALL in
36319  [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;;
36320  *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;;
36321  esac
36322_ACEOF
36323
36324cat >>$CONFIG_STATUS <<\_ACEOF
36325# If the template does not know about datarootdir, expand it.
36326# FIXME: This hack should be removed a few years after 2.60.
36327ac_datarootdir_hack=; ac_datarootdir_seen=
36328
36329case `sed -n '/datarootdir/ {
36330  p
36331  q
36332}
36333/@datadir@/p
36334/@docdir@/p
36335/@infodir@/p
36336/@localedir@/p
36337/@mandir@/p
36338' $ac_file_inputs` in
36339*datarootdir*) ac_datarootdir_seen=yes;;
36340*@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
36341  { echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
36342echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
36343_ACEOF
36344cat >>$CONFIG_STATUS <<_ACEOF
36345  ac_datarootdir_hack='
36346  s&@datadir@&$datadir&g
36347  s&@docdir@&$docdir&g
36348  s&@infodir@&$infodir&g
36349  s&@localedir@&$localedir&g
36350  s&@mandir@&$mandir&g
36351    s&\\\${datarootdir}&$datarootdir&g' ;;
36352esac
36353_ACEOF
36354
36355# Neutralize VPATH when `$srcdir' = `.'.
36356# Shell code in configure.ac might set extrasub.
36357# FIXME: do we really want to maintain this feature?
36358cat >>$CONFIG_STATUS <<_ACEOF
36359  sed "$ac_vpsub
36360$extrasub
36361_ACEOF
36362cat >>$CONFIG_STATUS <<\_ACEOF
36363:t
36364/@[a-zA-Z_][a-zA-Z_0-9]*@/!b
36365s&@configure_input@&$configure_input&;t t
36366s&@top_builddir@&$ac_top_builddir_sub&;t t
36367s&@srcdir@&$ac_srcdir&;t t
36368s&@abs_srcdir@&$ac_abs_srcdir&;t t
36369s&@top_srcdir@&$ac_top_srcdir&;t t
36370s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
36371s&@builddir@&$ac_builddir&;t t
36372s&@abs_builddir@&$ac_abs_builddir&;t t
36373s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
36374s&@INSTALL@&$ac_INSTALL&;t t
36375$ac_datarootdir_hack
36376" $ac_file_inputs | sed -f "$tmp/subs-1.sed" | sed -f "$tmp/subs-2.sed" >$tmp/out
36377
36378test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
36379  { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
36380  { ac_out=`sed -n '/^[	 ]*datarootdir[	 ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
36381  { echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
36382which seems to be undefined.  Please make sure it is defined." >&5
36383echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
36384which seems to be undefined.  Please make sure it is defined." >&2;}
36385
36386  rm -f "$tmp/stdin"
36387  case $ac_file in
36388  -) cat "$tmp/out"; rm -f "$tmp/out";;
36389  *) rm -f "$ac_file"; mv "$tmp/out" $ac_file;;
36390  esac
36391 ;;
36392  :H)
36393  #
36394  # CONFIG_HEADER
36395  #
36396_ACEOF
36397
36398# Transform confdefs.h into a sed script `conftest.defines', that
36399# substitutes the proper values into config.h.in to produce config.h.
36400rm -f conftest.defines conftest.tail
36401# First, append a space to every undef/define line, to ease matching.
36402echo 's/$/ /' >conftest.defines
36403# Then, protect against being on the right side of a sed subst, or in
36404# an unquoted here document, in config.status.  If some macros were
36405# called several times there might be several #defines for the same
36406# symbol, which is useless.  But do not sort them, since the last
36407# AC_DEFINE must be honored.
36408ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
36409# These sed commands are passed to sed as "A NAME B PARAMS C VALUE D", where
36410# NAME is the cpp macro being defined, VALUE is the value it is being given.
36411# PARAMS is the parameter list in the macro definition--in most cases, it's
36412# just an empty string.
36413ac_dA='s,^\\([	 #]*\\)[^	 ]*\\([	 ]*'
36414ac_dB='\\)[	 (].*,\\1define\\2'
36415ac_dC=' '
36416ac_dD=' ,'
36417
36418uniq confdefs.h |
36419  sed -n '
36420	t rset
36421	:rset
36422	s/^[	 ]*#[	 ]*define[	 ][	 ]*//
36423	t ok
36424	d
36425	:ok
36426	s/[\\&,]/\\&/g
36427	s/^\('"$ac_word_re"'\)\(([^()]*)\)[	 ]*\(.*\)/ '"$ac_dA"'\1'"$ac_dB"'\2'"${ac_dC}"'\3'"$ac_dD"'/p
36428	s/^\('"$ac_word_re"'\)[	 ]*\(.*\)/'"$ac_dA"'\1'"$ac_dB$ac_dC"'\2'"$ac_dD"'/p
36429  ' >>conftest.defines
36430
36431# Remove the space that was appended to ease matching.
36432# Then replace #undef with comments.  This is necessary, for
36433# example, in the case of _POSIX_SOURCE, which is predefined and required
36434# on some systems where configure will not decide to define it.
36435# (The regexp can be short, since the line contains either #define or #undef.)
36436echo 's/ $//
36437s,^[	 #]*u.*,/* & */,' >>conftest.defines
36438
36439# Break up conftest.defines:
36440ac_max_sed_lines=50
36441
36442# First sed command is:	 sed -f defines.sed $ac_file_inputs >"$tmp/out1"
36443# Second one is:	 sed -f defines.sed "$tmp/out1" >"$tmp/out2"
36444# Third one will be:	 sed -f defines.sed "$tmp/out2" >"$tmp/out1"
36445# et cetera.
36446ac_in='$ac_file_inputs'
36447ac_out='"$tmp/out1"'
36448ac_nxt='"$tmp/out2"'
36449
36450while :
36451do
36452  # Write a here document:
36453    cat >>$CONFIG_STATUS <<_ACEOF
36454    # First, check the format of the line:
36455    cat >"\$tmp/defines.sed" <<\\CEOF
36456/^[	 ]*#[	 ]*undef[	 ][	 ]*$ac_word_re[	 ]*\$/b def
36457/^[	 ]*#[	 ]*define[	 ][	 ]*$ac_word_re[(	 ]/b def
36458b
36459:def
36460_ACEOF
36461  sed ${ac_max_sed_lines}q conftest.defines >>$CONFIG_STATUS
36462  echo 'CEOF
36463    sed -f "$tmp/defines.sed"' "$ac_in >$ac_out" >>$CONFIG_STATUS
36464  ac_in=$ac_out; ac_out=$ac_nxt; ac_nxt=$ac_in
36465  sed 1,${ac_max_sed_lines}d conftest.defines >conftest.tail
36466  grep . conftest.tail >/dev/null || break
36467  rm -f conftest.defines
36468  mv conftest.tail conftest.defines
36469done
36470rm -f conftest.defines conftest.tail
36471
36472echo "ac_result=$ac_in" >>$CONFIG_STATUS
36473cat >>$CONFIG_STATUS <<\_ACEOF
36474  if test x"$ac_file" != x-; then
36475    echo "/* $configure_input  */" >"$tmp/config.h"
36476    cat "$ac_result" >>"$tmp/config.h"
36477    if diff $ac_file "$tmp/config.h" >/dev/null 2>&1; then
36478      { echo "$as_me:$LINENO: $ac_file is unchanged" >&5
36479echo "$as_me: $ac_file is unchanged" >&6;}
36480    else
36481      rm -f $ac_file
36482      mv "$tmp/config.h" $ac_file
36483    fi
36484  else
36485    echo "/* $configure_input  */"
36486    cat "$ac_result"
36487  fi
36488  rm -f "$tmp/out12"
36489 ;;
36490
36491
36492  esac
36493
36494done # for ac_tag
36495
36496
36497{ (exit 0); exit 0; }
36498_ACEOF
36499chmod +x $CONFIG_STATUS
36500ac_clean_files=$ac_clean_files_save
36501
36502
36503# configure is writing to config.log, and then calls config.status.
36504# config.status does its own redirection, appending to config.log.
36505# Unfortunately, on DOS this fails, as config.log is still kept open
36506# by configure, so config.status won't be able to write to it; its
36507# output is simply discarded.  So we exec the FD to /dev/null,
36508# effectively closing config.log, so it can be properly (re)opened and
36509# appended to by config.status.  When coming back to configure, we
36510# need to make the FD available again.
36511if test "$no_create" != yes; then
36512  ac_cs_success=:
36513  ac_config_status_args=
36514  test "$silent" = yes &&
36515    ac_config_status_args="$ac_config_status_args --quiet"
36516  exec 5>/dev/null
36517  $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
36518  exec 5>>config.log
36519  # Use ||, not &&, to avoid exiting from the if with $? = 1, which
36520  # would make configure fail if this is the last instruction.
36521  $ac_cs_success || { (exit 1); exit 1; }
36522fi
36523
36524
36525# Print summary of options
36526
36527# Someone please show me a better way :)
36528A=`eval echo ${prefix}` ; A=`eval echo ${A}`
36529B=`eval echo ${bindir}` ; B=`eval echo ${B}`
36530C=`eval echo ${sbindir}` ; C=`eval echo ${C}`
36531D=`eval echo ${sysconfdir}` ; D=`eval echo ${D}`
36532E=`eval echo ${libexecdir}/ssh-askpass` ; E=`eval echo ${E}`
36533F=`eval echo ${mandir}/${mansubdir}X` ; F=`eval echo ${F}`
36534G=`eval echo ${piddir}` ; G=`eval echo ${G}`
36535H=`eval echo ${PRIVSEP_PATH}` ; H=`eval echo ${H}`
36536I=`eval echo ${user_path}` ; I=`eval echo ${I}`
36537J=`eval echo ${superuser_path}` ; J=`eval echo ${J}`
36538
36539echo ""
36540echo "OpenSSH has been configured with the following options:"
36541echo "                     User binaries: $B"
36542echo "                   System binaries: $C"
36543echo "               Configuration files: $D"
36544echo "                   Askpass program: $E"
36545echo "                      Manual pages: $F"
36546echo "                          PID file: $G"
36547echo "  Privilege separation chroot path: $H"
36548if test "x$external_path_file" = "x/etc/login.conf" ; then
36549echo "   At runtime, sshd will use the path defined in $external_path_file"
36550echo "   Make sure the path to scp is present, otherwise scp will not work"
36551else
36552echo "            sshd default user PATH: $I"
36553	if test ! -z "$external_path_file"; then
36554echo "   (If PATH is set in $external_path_file it will be used instead. If"
36555echo "   used, ensure the path to scp is present, otherwise scp will not work.)"
36556	fi
36557fi
36558if test ! -z "$superuser_path" ; then
36559echo "          sshd superuser user PATH: $J"
36560fi
36561echo "                    Manpage format: $MANTYPE"
36562echo "                       PAM support: $PAM_MSG"
36563echo "                   OSF SIA support: $SIA_MSG"
36564echo "                 KerberosV support: $KRB5_MSG"
36565echo "                   SELinux support: $SELINUX_MSG"
36566echo "                 Smartcard support: $SCARD_MSG"
36567echo "                     S/KEY support: $SKEY_MSG"
36568echo "              MD5 password support: $MD5_MSG"
36569echo "                   libedit support: $LIBEDIT_MSG"
36570echo "  Solaris process contract support: $SPC_MSG"
36571echo "           Solaris project support: $SP_MSG"
36572echo "       IP address in \$DISPLAY hack: $DISPLAY_HACK_MSG"
36573echo "           Translate v4 in v6 hack: $IPV4_IN6_HACK_MSG"
36574echo "                  BSD Auth support: $BSD_AUTH_MSG"
36575echo "              Random number source: $RAND_MSG"
36576echo "             Privsep sandbox style: $SANDBOX_STYLE"
36577
36578echo ""
36579
36580echo "              Host: ${host}"
36581echo "          Compiler: ${CC}"
36582echo "    Compiler flags: ${CFLAGS}"
36583echo "Preprocessor flags: ${CPPFLAGS}"
36584echo "      Linker flags: ${LDFLAGS}"
36585echo "         Libraries: ${LIBS}"
36586if test ! -z "${SSHDLIBS}"; then
36587echo "         +for sshd: ${SSHDLIBS}"
36588fi
36589if test ! -z "${SSHLIBS}"; then
36590echo "          +for ssh: ${SSHLIBS}"
36591fi
36592
36593echo ""
36594
36595if test "x$MAKE_PACKAGE_SUPPORTED" = "xyes" ; then
36596	echo "SVR4 style packages are supported with \"make package\""
36597	echo ""
36598fi
36599
36600if test "x$PAM_MSG" = "xyes" ; then
36601	echo "PAM is enabled. You may need to install a PAM control file "
36602	echo "for sshd, otherwise password authentication may fail. "
36603	echo "Example PAM control files can be found in the contrib/ "
36604	echo "subdirectory"
36605	echo ""
36606fi
36607
36608if test ! -z "$NO_PEERCHECK" ; then
36609	echo "WARNING: the operating system that you are using does not"
36610	echo "appear to support getpeereid(), getpeerucred() or the"
36611	echo "SO_PEERCRED getsockopt() option. These facilities are used to"
36612	echo "enforce security checks to prevent unauthorised connections to"
36613	echo "ssh-agent. Their absence increases the risk that a malicious"
36614	echo "user can connect to your agent."
36615	echo ""
36616fi
36617
36618if test "$AUDIT_MODULE" = "bsm" ; then
36619	echo "WARNING: BSM audit support is currently considered EXPERIMENTAL."
36620	echo "See the Solaris section in README.platform for details."
36621fi
36622