OSDN Git Service

autoreconf
[pg-rex/syncrep.git] / configure
1 #! /bin/sh
2 # Guess values for system-dependent variables and create Makefiles.
3 # Generated by GNU Autoconf 2.63 for PostgreSQL 9.1devel.
4 #
5 # Report bugs to <pgsql-bugs@postgresql.org>.
6 #
7 # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
8 # 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
9 # This configure script is free software; the Free Software Foundation
10 # gives unlimited permission to copy, distribute and modify it.
11 #
12 # Copyright (c) 1996-2011, PostgreSQL Global Development Group
13 ## --------------------- ##
14 ## M4sh Initialization.  ##
15 ## --------------------- ##
16
17 # Be more Bourne compatible
18 DUALCASE=1; export DUALCASE # for MKS sh
19 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
20   emulate sh
21   NULLCMD=:
22   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
23   # is contrary to our usage.  Disable this feature.
24   alias -g '${1+"$@"}'='"$@"'
25   setopt NO_GLOB_SUBST
26 else
27   case `(set -o) 2>/dev/null` in
28   *posix*) set -o posix ;;
29 esac
30
31 fi
32
33
34
35
36 # PATH needs CR
37 # Avoid depending upon Character Ranges.
38 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
39 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
40 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
41 as_cr_digits='0123456789'
42 as_cr_alnum=$as_cr_Letters$as_cr_digits
43
44 as_nl='
45 '
46 export as_nl
47 # Printing a long string crashes Solaris 7 /usr/bin/printf.
48 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
49 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
50 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
51 if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
52   as_echo='printf %s\n'
53   as_echo_n='printf %s'
54 else
55   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
56     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
57     as_echo_n='/usr/ucb/echo -n'
58   else
59     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
60     as_echo_n_body='eval
61       arg=$1;
62       case $arg in
63       *"$as_nl"*)
64         expr "X$arg" : "X\\(.*\\)$as_nl";
65         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
66       esac;
67       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
68     '
69     export as_echo_n_body
70     as_echo_n='sh -c $as_echo_n_body as_echo'
71   fi
72   export as_echo_body
73   as_echo='sh -c $as_echo_body as_echo'
74 fi
75
76 # The user is always right.
77 if test "${PATH_SEPARATOR+set}" != set; then
78   PATH_SEPARATOR=:
79   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
80     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
81       PATH_SEPARATOR=';'
82   }
83 fi
84
85 # Support unset when possible.
86 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
87   as_unset=unset
88 else
89   as_unset=false
90 fi
91
92
93 # IFS
94 # We need space, tab and new line, in precisely that order.  Quoting is
95 # there to prevent editors from complaining about space-tab.
96 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
97 # splitting by setting IFS to empty value.)
98 IFS=" ""        $as_nl"
99
100 # Find who we are.  Look in the path if we contain no directory separator.
101 case $0 in
102   *[\\/]* ) as_myself=$0 ;;
103   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
104 for as_dir in $PATH
105 do
106   IFS=$as_save_IFS
107   test -z "$as_dir" && as_dir=.
108   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
109 done
110 IFS=$as_save_IFS
111
112      ;;
113 esac
114 # We did not find ourselves, most probably we were run as `sh COMMAND'
115 # in which case we are not to be found in the path.
116 if test "x$as_myself" = x; then
117   as_myself=$0
118 fi
119 if test ! -f "$as_myself"; then
120   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
121   { (exit 1); exit 1; }
122 fi
123
124 # Work around bugs in pre-3.0 UWIN ksh.
125 for as_var in ENV MAIL MAILPATH
126 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
127 done
128 PS1='$ '
129 PS2='> '
130 PS4='+ '
131
132 # NLS nuisances.
133 LC_ALL=C
134 export LC_ALL
135 LANGUAGE=C
136 export LANGUAGE
137
138 # Required to use basename.
139 if expr a : '\(a\)' >/dev/null 2>&1 &&
140    test "X`expr 00001 : '.*\(...\)'`" = X001; then
141   as_expr=expr
142 else
143   as_expr=false
144 fi
145
146 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
147   as_basename=basename
148 else
149   as_basename=false
150 fi
151
152
153 # Name of the executable.
154 as_me=`$as_basename -- "$0" ||
155 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
156          X"$0" : 'X\(//\)$' \| \
157          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
158 $as_echo X/"$0" |
159     sed '/^.*\/\([^/][^/]*\)\/*$/{
160             s//\1/
161             q
162           }
163           /^X\/\(\/\/\)$/{
164             s//\1/
165             q
166           }
167           /^X\/\(\/\).*/{
168             s//\1/
169             q
170           }
171           s/.*/./; q'`
172
173 # CDPATH.
174 $as_unset CDPATH
175
176
177 if test "x$CONFIG_SHELL" = x; then
178   if (eval ":") 2>/dev/null; then
179   as_have_required=yes
180 else
181   as_have_required=no
182 fi
183
184   if test $as_have_required = yes &&     (eval ":
185 (as_func_return () {
186   (exit \$1)
187 }
188 as_func_success () {
189   as_func_return 0
190 }
191 as_func_failure () {
192   as_func_return 1
193 }
194 as_func_ret_success () {
195   return 0
196 }
197 as_func_ret_failure () {
198   return 1
199 }
200
201 exitcode=0
202 if as_func_success; then
203   :
204 else
205   exitcode=1
206   echo as_func_success failed.
207 fi
208
209 if as_func_failure; then
210   exitcode=1
211   echo as_func_failure succeeded.
212 fi
213
214 if as_func_ret_success; then
215   :
216 else
217   exitcode=1
218   echo as_func_ret_success failed.
219 fi
220
221 if as_func_ret_failure; then
222   exitcode=1
223   echo as_func_ret_failure succeeded.
224 fi
225
226 if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
227   :
228 else
229   exitcode=1
230   echo positional parameters were not saved.
231 fi
232
233 test \$exitcode = 0) || { (exit 1); exit 1; }
234
235 (
236   as_lineno_1=\$LINENO
237   as_lineno_2=\$LINENO
238   test \"x\$as_lineno_1\" != \"x\$as_lineno_2\" &&
239   test \"x\`expr \$as_lineno_1 + 1\`\" = \"x\$as_lineno_2\") || { (exit 1); exit 1; }
240 ") 2> /dev/null; then
241   :
242 else
243   as_candidate_shells=
244     as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
245 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH
246 do
247   IFS=$as_save_IFS
248   test -z "$as_dir" && as_dir=.
249   case $as_dir in
250          /*)
251            for as_base in sh bash ksh sh5; do
252              as_candidate_shells="$as_candidate_shells $as_dir/$as_base"
253            done;;
254        esac
255 done
256 IFS=$as_save_IFS
257
258
259       for as_shell in $as_candidate_shells $SHELL; do
260          # Try only shells that exist, to save several forks.
261          if { test -f "$as_shell" || test -f "$as_shell.exe"; } &&
262                 { ("$as_shell") 2> /dev/null <<\_ASEOF
263 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
264   emulate sh
265   NULLCMD=:
266   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
267   # is contrary to our usage.  Disable this feature.
268   alias -g '${1+"$@"}'='"$@"'
269   setopt NO_GLOB_SUBST
270 else
271   case `(set -o) 2>/dev/null` in
272   *posix*) set -o posix ;;
273 esac
274
275 fi
276
277
278 :
279 _ASEOF
280 }; then
281   CONFIG_SHELL=$as_shell
282                as_have_required=yes
283                if { "$as_shell" 2> /dev/null <<\_ASEOF
284 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
285   emulate sh
286   NULLCMD=:
287   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
288   # is contrary to our usage.  Disable this feature.
289   alias -g '${1+"$@"}'='"$@"'
290   setopt NO_GLOB_SUBST
291 else
292   case `(set -o) 2>/dev/null` in
293   *posix*) set -o posix ;;
294 esac
295
296 fi
297
298
299 :
300 (as_func_return () {
301   (exit $1)
302 }
303 as_func_success () {
304   as_func_return 0
305 }
306 as_func_failure () {
307   as_func_return 1
308 }
309 as_func_ret_success () {
310   return 0
311 }
312 as_func_ret_failure () {
313   return 1
314 }
315
316 exitcode=0
317 if as_func_success; then
318   :
319 else
320   exitcode=1
321   echo as_func_success failed.
322 fi
323
324 if as_func_failure; then
325   exitcode=1
326   echo as_func_failure succeeded.
327 fi
328
329 if as_func_ret_success; then
330   :
331 else
332   exitcode=1
333   echo as_func_ret_success failed.
334 fi
335
336 if as_func_ret_failure; then
337   exitcode=1
338   echo as_func_ret_failure succeeded.
339 fi
340
341 if ( set x; as_func_ret_success y && test x = "$1" ); then
342   :
343 else
344   exitcode=1
345   echo positional parameters were not saved.
346 fi
347
348 test $exitcode = 0) || { (exit 1); exit 1; }
349
350 (
351   as_lineno_1=$LINENO
352   as_lineno_2=$LINENO
353   test "x$as_lineno_1" != "x$as_lineno_2" &&
354   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2") || { (exit 1); exit 1; }
355
356 _ASEOF
357 }; then
358   break
359 fi
360
361 fi
362
363       done
364
365       if test "x$CONFIG_SHELL" != x; then
366   for as_var in BASH_ENV ENV
367         do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
368         done
369         export CONFIG_SHELL
370         exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"}
371 fi
372
373
374     if test $as_have_required = no; then
375   echo This script requires a shell more modern than all the
376       echo shells that I found on your system.  Please install a
377       echo modern shell, or manually run the script under such a
378       echo shell if you do have one.
379       { (exit 1); exit 1; }
380 fi
381
382
383 fi
384
385 fi
386
387
388
389 (eval "as_func_return () {
390   (exit \$1)
391 }
392 as_func_success () {
393   as_func_return 0
394 }
395 as_func_failure () {
396   as_func_return 1
397 }
398 as_func_ret_success () {
399   return 0
400 }
401 as_func_ret_failure () {
402   return 1
403 }
404
405 exitcode=0
406 if as_func_success; then
407   :
408 else
409   exitcode=1
410   echo as_func_success failed.
411 fi
412
413 if as_func_failure; then
414   exitcode=1
415   echo as_func_failure succeeded.
416 fi
417
418 if as_func_ret_success; then
419   :
420 else
421   exitcode=1
422   echo as_func_ret_success failed.
423 fi
424
425 if as_func_ret_failure; then
426   exitcode=1
427   echo as_func_ret_failure succeeded.
428 fi
429
430 if ( set x; as_func_ret_success y && test x = \"\$1\" ); then
431   :
432 else
433   exitcode=1
434   echo positional parameters were not saved.
435 fi
436
437 test \$exitcode = 0") || {
438   echo No shell found that supports shell functions.
439   echo Please tell bug-autoconf@gnu.org about your system,
440   echo including any error possibly output before this message.
441   echo This can help us improve future autoconf versions.
442   echo Configuration will now proceed without shell functions.
443 }
444
445
446
447   as_lineno_1=$LINENO
448   as_lineno_2=$LINENO
449   test "x$as_lineno_1" != "x$as_lineno_2" &&
450   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
451
452   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
453   # uniformly replaced by the line number.  The first 'sed' inserts a
454   # line-number line after each line using $LINENO; the second 'sed'
455   # does the real work.  The second script uses 'N' to pair each
456   # line-number line with the line containing $LINENO, and appends
457   # trailing '-' during substitution so that $LINENO is not a special
458   # case at line end.
459   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
460   # scripts with optimization help from Paolo Bonzini.  Blame Lee
461   # E. McMahon (1931-1989) for sed's syntax.  :-)
462   sed -n '
463     p
464     /[$]LINENO/=
465   ' <$as_myself |
466     sed '
467       s/[$]LINENO.*/&-/
468       t lineno
469       b
470       :lineno
471       N
472       :loop
473       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
474       t loop
475       s/-\n.*//
476     ' >$as_me.lineno &&
477   chmod +x "$as_me.lineno" ||
478     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
479    { (exit 1); exit 1; }; }
480
481   # Don't try to exec as it changes $[0], causing all sort of problems
482   # (the dirname of $[0] is not the place where we might find the
483   # original and so on.  Autoconf is especially sensitive to this).
484   . "./$as_me.lineno"
485   # Exit status is that of the last command.
486   exit
487 }
488
489
490 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
491   as_dirname=dirname
492 else
493   as_dirname=false
494 fi
495
496 ECHO_C= ECHO_N= ECHO_T=
497 case `echo -n x` in
498 -n*)
499   case `echo 'x\c'` in
500   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
501   *)   ECHO_C='\c';;
502   esac;;
503 *)
504   ECHO_N='-n';;
505 esac
506 if expr a : '\(a\)' >/dev/null 2>&1 &&
507    test "X`expr 00001 : '.*\(...\)'`" = X001; then
508   as_expr=expr
509 else
510   as_expr=false
511 fi
512
513 rm -f conf$$ conf$$.exe conf$$.file
514 if test -d conf$$.dir; then
515   rm -f conf$$.dir/conf$$.file
516 else
517   rm -f conf$$.dir
518   mkdir conf$$.dir 2>/dev/null
519 fi
520 if (echo >conf$$.file) 2>/dev/null; then
521   if ln -s conf$$.file conf$$ 2>/dev/null; then
522     as_ln_s='ln -s'
523     # ... but there are two gotchas:
524     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
525     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
526     # In both cases, we have to default to `cp -p'.
527     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
528       as_ln_s='cp -p'
529   elif ln conf$$.file conf$$ 2>/dev/null; then
530     as_ln_s=ln
531   else
532     as_ln_s='cp -p'
533   fi
534 else
535   as_ln_s='cp -p'
536 fi
537 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
538 rmdir conf$$.dir 2>/dev/null
539
540 if mkdir -p . 2>/dev/null; then
541   as_mkdir_p=:
542 else
543   test -d ./-p && rmdir ./-p
544   as_mkdir_p=false
545 fi
546
547 if test -x / >/dev/null 2>&1; then
548   as_test_x='test -x'
549 else
550   if ls -dL / >/dev/null 2>&1; then
551     as_ls_L_option=L
552   else
553     as_ls_L_option=
554   fi
555   as_test_x='
556     eval sh -c '\''
557       if test -d "$1"; then
558         test -d "$1/.";
559       else
560         case $1 in
561         -*)set "./$1";;
562         esac;
563         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
564         ???[sx]*):;;*)false;;esac;fi
565     '\'' sh
566   '
567 fi
568 as_executable_p=$as_test_x
569
570 # Sed expression to map a string onto a valid CPP name.
571 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
572
573 # Sed expression to map a string onto a valid variable name.
574 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
575
576
577
578 exec 7<&0 </dev/null 6>&1
579
580 # Name of the host.
581 # hostname on some systems (SVR3.2, Linux) returns a bogus exit status,
582 # so uname gets run too.
583 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q`
584
585 #
586 # Initializations.
587 #
588 ac_default_prefix=/usr/local
589 ac_clean_files=
590 ac_config_libobj_dir=.
591 LIBOBJS=
592 cross_compiling=no
593 subdirs=
594 MFLAGS=
595 MAKEFLAGS=
596 SHELL=${CONFIG_SHELL-/bin/sh}
597
598 # Identity of this package.
599 PACKAGE_NAME='PostgreSQL'
600 PACKAGE_TARNAME='postgresql'
601 PACKAGE_VERSION='9.1devel'
602 PACKAGE_STRING='PostgreSQL 9.1devel'
603 PACKAGE_BUGREPORT='pgsql-bugs@postgresql.org'
604
605 ac_unique_file="src/backend/access/common/heaptuple.c"
606 ac_default_prefix=/usr/local/pgsql
607 # Factoring default headers for most tests.
608 ac_includes_default="\
609 #include <stdio.h>
610 #ifdef HAVE_SYS_TYPES_H
611 # include <sys/types.h>
612 #endif
613 #ifdef HAVE_SYS_STAT_H
614 # include <sys/stat.h>
615 #endif
616 #ifdef STDC_HEADERS
617 # include <stdlib.h>
618 # include <stddef.h>
619 #else
620 # ifdef HAVE_STDLIB_H
621 #  include <stdlib.h>
622 # endif
623 #endif
624 #ifdef HAVE_STRING_H
625 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H
626 #  include <memory.h>
627 # endif
628 # include <string.h>
629 #endif
630 #ifdef HAVE_STRINGS_H
631 # include <strings.h>
632 #endif
633 #ifdef HAVE_INTTYPES_H
634 # include <inttypes.h>
635 #endif
636 #ifdef HAVE_STDINT_H
637 # include <stdint.h>
638 #endif
639 #ifdef HAVE_UNISTD_H
640 # include <unistd.h>
641 #endif"
642
643 ac_subst_vars='LTLIBOBJS
644 vpath_build
645 OSX
646 XSLTPROC
647 COLLATEINDEX
648 DOCBOOKSTYLE
649 have_docbook
650 JADE
651 NSGMLS
652 TCL_SHLIB_LD_LIBS
653 TCL_SHARED_BUILD
654 TCL_LIB_SPEC
655 TCL_LIBS
656 TCL_LIB_FILE
657 TCL_INCLUDE_SPEC
658 TCL_CONFIG_SH
659 TCLSH
660 XGETTEXT
661 MSGMERGE
662 MSGFMT
663 HAVE_POSIX_SIGNALS
664 LDAP_LIBS_BE
665 LDAP_LIBS_FE
666 PTHREAD_CFLAGS
667 PTHREAD_LIBS
668 PTHREAD_CC
669 acx_pthread_config
670 have_win32_dbghelp
671 HAVE_IPV6
672 LIBOBJS
673 OSSP_UUID_LIBS
674 ZIC
675 python_additional_libs
676 python_libspec
677 python_libdir
678 python_includespec
679 python_configdir
680 python_version
681 python_majorversion
682 PYTHON
683 perl_embed_ldflags
684 perl_useshrplib
685 perl_privlibexp
686 perl_archlibexp
687 PERL
688 FLEXFLAGS
689 FLEX
690 BISONFLAGS
691 BISON
692 MKDIR_P
693 AWK
694 LN_S
695 TAR
696 WINDRES
697 DLLWRAP
698 DLLTOOL
699 AR
700 STRIP_SHARED_LIB
701 STRIP_STATIC_LIB
702 STRIP
703 RANLIB
704 ld_R_works
705 with_gnu_ld
706 LD
707 LDFLAGS_SL
708 LDFLAGS_EX
709 ELF_SYS
710 EGREP
711 GREP
712 with_zlib
713 with_system_tzdata
714 with_libxslt
715 with_libxml
716 XML2_CONFIG
717 with_ossp_uuid
718 with_selinux
719 with_openssl
720 with_bonjour
721 with_ldap
722 with_pam
723 krb_srvtab
724 with_krb5
725 with_gssapi
726 with_python
727 with_perl
728 with_tcl
729 enable_thread_safety
730 INCLUDES
731 autodepend
732 TAS
733 GCC
734 CPP
735 SUN_STUDIO_CC
736 OBJEXT
737 EXEEXT
738 ac_ct_CC
739 CPPFLAGS
740 LDFLAGS
741 CFLAGS
742 CC
743 enable_dtrace
744 DTRACEFLAGS
745 DTRACE
746 enable_coverage
747 GENHTML
748 LCOV
749 GCOV
750 enable_profiling
751 enable_debug
752 enable_rpath
753 enable_shared
754 default_port
755 WANTED_LANGUAGES
756 enable_nls
757 PORTNAME
758 host_os
759 host_vendor
760 host_cpu
761 host
762 build_os
763 build_vendor
764 build_cpu
765 build
766 PG_MAJORVERSION
767 configure_args
768 target_alias
769 host_alias
770 build_alias
771 LIBS
772 ECHO_T
773 ECHO_N
774 ECHO_C
775 DEFS
776 mandir
777 localedir
778 libdir
779 psdir
780 pdfdir
781 dvidir
782 htmldir
783 infodir
784 docdir
785 oldincludedir
786 includedir
787 localstatedir
788 sharedstatedir
789 sysconfdir
790 datadir
791 datarootdir
792 libexecdir
793 sbindir
794 bindir
795 program_transform_name
796 prefix
797 exec_prefix
798 PACKAGE_BUGREPORT
799 PACKAGE_STRING
800 PACKAGE_VERSION
801 PACKAGE_TARNAME
802 PACKAGE_NAME
803 PATH_SEPARATOR
804 SHELL'
805 ac_subst_files=''
806 ac_user_opts='
807 enable_option_checking
808 with_template
809 with_includes
810 with_libraries
811 with_libs
812 enable_integer_datetimes
813 enable_nls
814 with_pgport
815 enable_shared
816 enable_rpath
817 enable_spinlocks
818 enable_debug
819 enable_profiling
820 enable_coverage
821 enable_dtrace
822 with_blocksize
823 with_segsize
824 with_wal_blocksize
825 with_wal_segsize
826 with_CC
827 enable_depend
828 enable_cassert
829 enable_thread_safety
830 with_tcl
831 with_tclconfig
832 with_perl
833 with_python
834 with_gssapi
835 with_krb5
836 with_krb_srvnam
837 with_pam
838 with_ldap
839 with_bonjour
840 with_openssl
841 with_selinux
842 with_readline
843 with_libedit_preferred
844 with_ossp_uuid
845 with_libxml
846 with_libxslt
847 with_system_tzdata
848 with_zlib
849 with_gnu_ld
850 enable_largefile
851 enable_float4_byval
852 enable_float8_byval
853 '
854       ac_precious_vars='build_alias
855 host_alias
856 target_alias
857 CC
858 CFLAGS
859 LDFLAGS
860 LIBS
861 CPPFLAGS
862 CPP
863 LDFLAGS_EX
864 LDFLAGS_SL
865 DOCBOOKSTYLE'
866
867
868 # Initialize some variables set by options.
869 ac_init_help=
870 ac_init_version=false
871 ac_unrecognized_opts=
872 ac_unrecognized_sep=
873 # The variables have the same names as the options, with
874 # dashes changed to underlines.
875 cache_file=/dev/null
876 exec_prefix=NONE
877 no_create=
878 no_recursion=
879 prefix=NONE
880 program_prefix=NONE
881 program_suffix=NONE
882 program_transform_name=s,x,x,
883 silent=
884 site=
885 srcdir=
886 verbose=
887 x_includes=NONE
888 x_libraries=NONE
889
890 # Installation directory options.
891 # These are left unexpanded so users can "make install exec_prefix=/foo"
892 # and all the variables that are supposed to be based on exec_prefix
893 # by default will actually change.
894 # Use braces instead of parens because sh, perl, etc. also accept them.
895 # (The list follows the same order as the GNU Coding Standards.)
896 bindir='${exec_prefix}/bin'
897 sbindir='${exec_prefix}/sbin'
898 libexecdir='${exec_prefix}/libexec'
899 datarootdir='${prefix}/share'
900 datadir='${datarootdir}'
901 sysconfdir='${prefix}/etc'
902 sharedstatedir='${prefix}/com'
903 localstatedir='${prefix}/var'
904 includedir='${prefix}/include'
905 oldincludedir='/usr/include'
906 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
907 infodir='${datarootdir}/info'
908 htmldir='${docdir}'
909 dvidir='${docdir}'
910 pdfdir='${docdir}'
911 psdir='${docdir}'
912 libdir='${exec_prefix}/lib'
913 localedir='${datarootdir}/locale'
914 mandir='${datarootdir}/man'
915
916 ac_prev=
917 ac_dashdash=
918 for ac_option
919 do
920   # If the previous option needs an argument, assign it.
921   if test -n "$ac_prev"; then
922     eval $ac_prev=\$ac_option
923     ac_prev=
924     continue
925   fi
926
927   case $ac_option in
928   *=*)  ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
929   *)    ac_optarg=yes ;;
930   esac
931
932   # Accept the important Cygnus configure options, so we can diagnose typos.
933
934   case $ac_dashdash$ac_option in
935   --)
936     ac_dashdash=yes ;;
937
938   -bindir | --bindir | --bindi | --bind | --bin | --bi)
939     ac_prev=bindir ;;
940   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
941     bindir=$ac_optarg ;;
942
943   -build | --build | --buil | --bui | --bu)
944     ac_prev=build_alias ;;
945   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
946     build_alias=$ac_optarg ;;
947
948   -cache-file | --cache-file | --cache-fil | --cache-fi \
949   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
950     ac_prev=cache_file ;;
951   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
952   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
953     cache_file=$ac_optarg ;;
954
955   --config-cache | -C)
956     cache_file=config.cache ;;
957
958   -datadir | --datadir | --datadi | --datad)
959     ac_prev=datadir ;;
960   -datadir=* | --datadir=* | --datadi=* | --datad=*)
961     datadir=$ac_optarg ;;
962
963   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
964   | --dataroo | --dataro | --datar)
965     ac_prev=datarootdir ;;
966   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
967   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
968     datarootdir=$ac_optarg ;;
969
970   -disable-* | --disable-*)
971     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
972     # Reject names that are not valid shell variable names.
973     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
974       { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
975    { (exit 1); exit 1; }; }
976     ac_useropt_orig=$ac_useropt
977     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
978     case $ac_user_opts in
979       *"
980 "enable_$ac_useropt"
981 "*) ;;
982       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
983          ac_unrecognized_sep=', ';;
984     esac
985     eval enable_$ac_useropt=no ;;
986
987   -docdir | --docdir | --docdi | --doc | --do)
988     ac_prev=docdir ;;
989   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
990     docdir=$ac_optarg ;;
991
992   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
993     ac_prev=dvidir ;;
994   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
995     dvidir=$ac_optarg ;;
996
997   -enable-* | --enable-*)
998     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
999     # Reject names that are not valid shell variable names.
1000     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1001       { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
1002    { (exit 1); exit 1; }; }
1003     ac_useropt_orig=$ac_useropt
1004     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1005     case $ac_user_opts in
1006       *"
1007 "enable_$ac_useropt"
1008 "*) ;;
1009       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1010          ac_unrecognized_sep=', ';;
1011     esac
1012     eval enable_$ac_useropt=\$ac_optarg ;;
1013
1014   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1015   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1016   | --exec | --exe | --ex)
1017     ac_prev=exec_prefix ;;
1018   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1019   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1020   | --exec=* | --exe=* | --ex=*)
1021     exec_prefix=$ac_optarg ;;
1022
1023   -gas | --gas | --ga | --g)
1024     # Obsolete; use --with-gas.
1025     with_gas=yes ;;
1026
1027   -help | --help | --hel | --he | -h)
1028     ac_init_help=long ;;
1029   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1030     ac_init_help=recursive ;;
1031   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1032     ac_init_help=short ;;
1033
1034   -host | --host | --hos | --ho)
1035     ac_prev=host_alias ;;
1036   -host=* | --host=* | --hos=* | --ho=*)
1037     host_alias=$ac_optarg ;;
1038
1039   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1040     ac_prev=htmldir ;;
1041   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1042   | --ht=*)
1043     htmldir=$ac_optarg ;;
1044
1045   -includedir | --includedir | --includedi | --included | --include \
1046   | --includ | --inclu | --incl | --inc)
1047     ac_prev=includedir ;;
1048   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1049   | --includ=* | --inclu=* | --incl=* | --inc=*)
1050     includedir=$ac_optarg ;;
1051
1052   -infodir | --infodir | --infodi | --infod | --info | --inf)
1053     ac_prev=infodir ;;
1054   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1055     infodir=$ac_optarg ;;
1056
1057   -libdir | --libdir | --libdi | --libd)
1058     ac_prev=libdir ;;
1059   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1060     libdir=$ac_optarg ;;
1061
1062   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1063   | --libexe | --libex | --libe)
1064     ac_prev=libexecdir ;;
1065   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1066   | --libexe=* | --libex=* | --libe=*)
1067     libexecdir=$ac_optarg ;;
1068
1069   -localedir | --localedir | --localedi | --localed | --locale)
1070     ac_prev=localedir ;;
1071   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1072     localedir=$ac_optarg ;;
1073
1074   -localstatedir | --localstatedir | --localstatedi | --localstated \
1075   | --localstate | --localstat | --localsta | --localst | --locals)
1076     ac_prev=localstatedir ;;
1077   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1078   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1079     localstatedir=$ac_optarg ;;
1080
1081   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1082     ac_prev=mandir ;;
1083   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1084     mandir=$ac_optarg ;;
1085
1086   -nfp | --nfp | --nf)
1087     # Obsolete; use --without-fp.
1088     with_fp=no ;;
1089
1090   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1091   | --no-cr | --no-c | -n)
1092     no_create=yes ;;
1093
1094   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1095   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1096     no_recursion=yes ;;
1097
1098   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1099   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1100   | --oldin | --oldi | --old | --ol | --o)
1101     ac_prev=oldincludedir ;;
1102   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1103   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1104   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1105     oldincludedir=$ac_optarg ;;
1106
1107   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1108     ac_prev=prefix ;;
1109   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1110     prefix=$ac_optarg ;;
1111
1112   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1113   | --program-pre | --program-pr | --program-p)
1114     ac_prev=program_prefix ;;
1115   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1116   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1117     program_prefix=$ac_optarg ;;
1118
1119   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1120   | --program-suf | --program-su | --program-s)
1121     ac_prev=program_suffix ;;
1122   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1123   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1124     program_suffix=$ac_optarg ;;
1125
1126   -program-transform-name | --program-transform-name \
1127   | --program-transform-nam | --program-transform-na \
1128   | --program-transform-n | --program-transform- \
1129   | --program-transform | --program-transfor \
1130   | --program-transfo | --program-transf \
1131   | --program-trans | --program-tran \
1132   | --progr-tra | --program-tr | --program-t)
1133     ac_prev=program_transform_name ;;
1134   -program-transform-name=* | --program-transform-name=* \
1135   | --program-transform-nam=* | --program-transform-na=* \
1136   | --program-transform-n=* | --program-transform-=* \
1137   | --program-transform=* | --program-transfor=* \
1138   | --program-transfo=* | --program-transf=* \
1139   | --program-trans=* | --program-tran=* \
1140   | --progr-tra=* | --program-tr=* | --program-t=*)
1141     program_transform_name=$ac_optarg ;;
1142
1143   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1144     ac_prev=pdfdir ;;
1145   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1146     pdfdir=$ac_optarg ;;
1147
1148   -psdir | --psdir | --psdi | --psd | --ps)
1149     ac_prev=psdir ;;
1150   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1151     psdir=$ac_optarg ;;
1152
1153   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1154   | -silent | --silent | --silen | --sile | --sil)
1155     silent=yes ;;
1156
1157   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1158     ac_prev=sbindir ;;
1159   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1160   | --sbi=* | --sb=*)
1161     sbindir=$ac_optarg ;;
1162
1163   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1164   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1165   | --sharedst | --shareds | --shared | --share | --shar \
1166   | --sha | --sh)
1167     ac_prev=sharedstatedir ;;
1168   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1169   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1170   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1171   | --sha=* | --sh=*)
1172     sharedstatedir=$ac_optarg ;;
1173
1174   -site | --site | --sit)
1175     ac_prev=site ;;
1176   -site=* | --site=* | --sit=*)
1177     site=$ac_optarg ;;
1178
1179   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1180     ac_prev=srcdir ;;
1181   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1182     srcdir=$ac_optarg ;;
1183
1184   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1185   | --syscon | --sysco | --sysc | --sys | --sy)
1186     ac_prev=sysconfdir ;;
1187   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1188   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1189     sysconfdir=$ac_optarg ;;
1190
1191   -target | --target | --targe | --targ | --tar | --ta | --t)
1192     ac_prev=target_alias ;;
1193   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1194     target_alias=$ac_optarg ;;
1195
1196   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1197     verbose=yes ;;
1198
1199   -version | --version | --versio | --versi | --vers | -V)
1200     ac_init_version=: ;;
1201
1202   -with-* | --with-*)
1203     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1204     # Reject names that are not valid shell variable names.
1205     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1206       { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1207    { (exit 1); exit 1; }; }
1208     ac_useropt_orig=$ac_useropt
1209     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1210     case $ac_user_opts in
1211       *"
1212 "with_$ac_useropt"
1213 "*) ;;
1214       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1215          ac_unrecognized_sep=', ';;
1216     esac
1217     eval with_$ac_useropt=\$ac_optarg ;;
1218
1219   -without-* | --without-*)
1220     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1221     # Reject names that are not valid shell variable names.
1222     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1223       { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1224    { (exit 1); exit 1; }; }
1225     ac_useropt_orig=$ac_useropt
1226     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1227     case $ac_user_opts in
1228       *"
1229 "with_$ac_useropt"
1230 "*) ;;
1231       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1232          ac_unrecognized_sep=', ';;
1233     esac
1234     eval with_$ac_useropt=no ;;
1235
1236   --x)
1237     # Obsolete; use --with-x.
1238     with_x=yes ;;
1239
1240   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1241   | --x-incl | --x-inc | --x-in | --x-i)
1242     ac_prev=x_includes ;;
1243   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1244   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1245     x_includes=$ac_optarg ;;
1246
1247   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1248   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1249     ac_prev=x_libraries ;;
1250   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1251   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1252     x_libraries=$ac_optarg ;;
1253
1254   -*) { $as_echo "$as_me: error: unrecognized option: $ac_option
1255 Try \`$0 --help' for more information." >&2
1256    { (exit 1); exit 1; }; }
1257     ;;
1258
1259   *=*)
1260     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1261     # Reject names that are not valid shell variable names.
1262     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
1263       { $as_echo "$as_me: error: invalid variable name: $ac_envvar" >&2
1264    { (exit 1); exit 1; }; }
1265     eval $ac_envvar=\$ac_optarg
1266     export $ac_envvar ;;
1267
1268   *)
1269     # FIXME: should be removed in autoconf 3.0.
1270     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1271     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1272       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1273     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1274     ;;
1275
1276   esac
1277 done
1278
1279 if test -n "$ac_prev"; then
1280   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1281   { $as_echo "$as_me: error: missing argument to $ac_option" >&2
1282    { (exit 1); exit 1; }; }
1283 fi
1284
1285 if test -n "$ac_unrecognized_opts"; then
1286   case $enable_option_checking in
1287     no) ;;
1288     fatal) { $as_echo "$as_me: error: unrecognized options: $ac_unrecognized_opts" >&2
1289    { (exit 1); exit 1; }; } ;;
1290     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1291   esac
1292 fi
1293
1294 # Check all directory arguments for consistency.
1295 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1296                 datadir sysconfdir sharedstatedir localstatedir includedir \
1297                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1298                 libdir localedir mandir
1299 do
1300   eval ac_val=\$$ac_var
1301   # Remove trailing slashes.
1302   case $ac_val in
1303     */ )
1304       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1305       eval $ac_var=\$ac_val;;
1306   esac
1307   # Be sure to have absolute directory names.
1308   case $ac_val in
1309     [\\/$]* | ?:[\\/]* )  continue;;
1310     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1311   esac
1312   { $as_echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
1313    { (exit 1); exit 1; }; }
1314 done
1315
1316 # There might be people who depend on the old broken behavior: `$host'
1317 # used to hold the argument of --host etc.
1318 # FIXME: To remove some day.
1319 build=$build_alias
1320 host=$host_alias
1321 target=$target_alias
1322
1323 # FIXME: To remove some day.
1324 if test "x$host_alias" != x; then
1325   if test "x$build_alias" = x; then
1326     cross_compiling=maybe
1327     $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1328     If a cross compiler is detected then cross compile mode will be used." >&2
1329   elif test "x$build_alias" != "x$host_alias"; then
1330     cross_compiling=yes
1331   fi
1332 fi
1333
1334 ac_tool_prefix=
1335 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1336
1337 test "$silent" = yes && exec 6>/dev/null
1338
1339
1340 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1341 ac_ls_di=`ls -di .` &&
1342 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1343   { $as_echo "$as_me: error: working directory cannot be determined" >&2
1344    { (exit 1); exit 1; }; }
1345 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1346   { $as_echo "$as_me: error: pwd does not report name of working directory" >&2
1347    { (exit 1); exit 1; }; }
1348
1349
1350 # Find the source files, if location was not specified.
1351 if test -z "$srcdir"; then
1352   ac_srcdir_defaulted=yes
1353   # Try the directory containing this script, then the parent directory.
1354   ac_confdir=`$as_dirname -- "$as_myself" ||
1355 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1356          X"$as_myself" : 'X\(//\)[^/]' \| \
1357          X"$as_myself" : 'X\(//\)$' \| \
1358          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1359 $as_echo X"$as_myself" |
1360     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1361             s//\1/
1362             q
1363           }
1364           /^X\(\/\/\)[^/].*/{
1365             s//\1/
1366             q
1367           }
1368           /^X\(\/\/\)$/{
1369             s//\1/
1370             q
1371           }
1372           /^X\(\/\).*/{
1373             s//\1/
1374             q
1375           }
1376           s/.*/./; q'`
1377   srcdir=$ac_confdir
1378   if test ! -r "$srcdir/$ac_unique_file"; then
1379     srcdir=..
1380   fi
1381 else
1382   ac_srcdir_defaulted=no
1383 fi
1384 if test ! -r "$srcdir/$ac_unique_file"; then
1385   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1386   { $as_echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
1387    { (exit 1); exit 1; }; }
1388 fi
1389 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1390 ac_abs_confdir=`(
1391         cd "$srcdir" && test -r "./$ac_unique_file" || { $as_echo "$as_me: error: $ac_msg" >&2
1392    { (exit 1); exit 1; }; }
1393         pwd)`
1394 # When building in place, set srcdir=.
1395 if test "$ac_abs_confdir" = "$ac_pwd"; then
1396   srcdir=.
1397 fi
1398 # Remove unnecessary trailing slashes from srcdir.
1399 # Double slashes in file names in object file debugging info
1400 # mess up M-x gdb in Emacs.
1401 case $srcdir in
1402 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1403 esac
1404 for ac_var in $ac_precious_vars; do
1405   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1406   eval ac_env_${ac_var}_value=\$${ac_var}
1407   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1408   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1409 done
1410
1411 #
1412 # Report the --help message.
1413 #
1414 if test "$ac_init_help" = "long"; then
1415   # Omit some internal or obsolete options to make the list less imposing.
1416   # This message is too long to be a string in the A/UX 3.1 sh.
1417   cat <<_ACEOF
1418 \`configure' configures PostgreSQL 9.1devel to adapt to many kinds of systems.
1419
1420 Usage: $0 [OPTION]... [VAR=VALUE]...
1421
1422 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1423 VAR=VALUE.  See below for descriptions of some of the useful variables.
1424
1425 Defaults for the options are specified in brackets.
1426
1427 Configuration:
1428   -h, --help              display this help and exit
1429       --help=short        display options specific to this package
1430       --help=recursive    display the short help of all the included packages
1431   -V, --version           display version information and exit
1432   -q, --quiet, --silent   do not print \`checking...' messages
1433       --cache-file=FILE   cache test results in FILE [disabled]
1434   -C, --config-cache      alias for \`--cache-file=config.cache'
1435   -n, --no-create         do not create output files
1436       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1437
1438 Installation directories:
1439   --prefix=PREFIX         install architecture-independent files in PREFIX
1440                           [$ac_default_prefix]
1441   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1442                           [PREFIX]
1443
1444 By default, \`make install' will install all the files in
1445 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1446 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1447 for instance \`--prefix=\$HOME'.
1448
1449 For better control, use the options below.
1450
1451 Fine tuning of the installation directories:
1452   --bindir=DIR            user executables [EPREFIX/bin]
1453   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1454   --libexecdir=DIR        program executables [EPREFIX/libexec]
1455   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1456   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1457   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1458   --libdir=DIR            object code libraries [EPREFIX/lib]
1459   --includedir=DIR        C header files [PREFIX/include]
1460   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1461   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1462   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1463   --infodir=DIR           info documentation [DATAROOTDIR/info]
1464   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1465   --mandir=DIR            man documentation [DATAROOTDIR/man]
1466   --docdir=DIR            documentation root [DATAROOTDIR/doc/postgresql]
1467   --htmldir=DIR           html documentation [DOCDIR]
1468   --dvidir=DIR            dvi documentation [DOCDIR]
1469   --pdfdir=DIR            pdf documentation [DOCDIR]
1470   --psdir=DIR             ps documentation [DOCDIR]
1471 _ACEOF
1472
1473   cat <<\_ACEOF
1474
1475 System types:
1476   --build=BUILD     configure for building on BUILD [guessed]
1477   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1478 _ACEOF
1479 fi
1480
1481 if test -n "$ac_init_help"; then
1482   case $ac_init_help in
1483      short | recursive ) echo "Configuration of PostgreSQL 9.1devel:";;
1484    esac
1485   cat <<\_ACEOF
1486
1487 Optional Features:
1488   --disable-option-checking  ignore unrecognized --enable/--with options
1489   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1490   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1491   --disable-integer-datetimes
1492                           disable 64-bit integer date/time support
1493   --enable-nls[=LANGUAGES]
1494                           enable Native Language Support
1495   --disable-shared        do not build shared libraries
1496   --disable-rpath         do not embed shared library search path in
1497                           executables
1498   --disable-spinlocks     do not use spinlocks
1499   --enable-debug          build with debugging symbols (-g)
1500   --enable-profiling      build with profiling enabled
1501   --enable-coverage       build with coverage testing instrumentation
1502   --enable-dtrace         build with DTrace support
1503   --enable-depend         turn on automatic dependency tracking
1504   --enable-cassert        enable assertion checks (for debugging)
1505   --disable-thread-safety disable thread-safety in client libraries
1506   --disable-largefile     omit support for large files
1507   --disable-float4-byval  disable float4 passed by value
1508   --disable-float8-byval  disable float8 passed by value
1509
1510 Optional Packages:
1511   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1512   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1513   --with-template=NAME    override operating system template
1514   --with-includes=DIRS    look for additional header files in DIRS
1515   --with-libraries=DIRS   look for additional libraries in DIRS
1516   --with-libs=DIRS        alternative spelling of --with-libraries
1517   --with-pgport=PORTNUM   set default port number [5432]
1518   --with-blocksize=BLOCKSIZE
1519                           set table block size in kB [8]
1520   --with-segsize=SEGSIZE  set table segment size in GB [1]
1521   --with-wal-blocksize=BLOCKSIZE
1522                           set WAL block size in kB [8]
1523   --with-wal-segsize=SEGSIZE
1524                           set WAL segment size in MB [16]
1525   --with-CC=CMD           set compiler (deprecated)
1526   --with-tcl              build Tcl modules (PL/Tcl)
1527   --with-tclconfig=DIR    tclConfig.sh is in DIR
1528   --with-perl             build Perl modules (PL/Perl)
1529   --with-python           build Python modules (PL/Python)
1530   --with-gssapi           build with GSSAPI support
1531   --with-krb5             build with Kerberos 5 support
1532   --with-krb-srvnam=NAME  default service principal name in Kerberos
1533                           [postgres]
1534   --with-pam              build with PAM support
1535   --with-ldap             build with LDAP support
1536   --with-bonjour          build with Bonjour support
1537   --with-openssl          build with OpenSSL support
1538   --with-selinux          build with SELinux support
1539   --without-readline      do not use GNU Readline nor BSD Libedit for editing
1540   --with-libedit-preferred
1541                           prefer BSD Libedit over GNU Readline
1542   --with-ossp-uuid        use OSSP UUID library when building
1543                           contrib/uuid-ossp
1544   --with-libxml           build with XML support
1545   --with-libxslt          use XSLT support when building contrib/xml2
1546   --with-system-tzdata=DIR
1547                           use system time zone data in DIR
1548   --without-zlib          do not use Zlib
1549   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1550
1551 Some influential environment variables:
1552   CC          C compiler command
1553   CFLAGS      C compiler flags
1554   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1555               nonstandard directory <lib dir>
1556   LIBS        libraries to pass to the linker, e.g. -l<library>
1557   CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1558               you have headers in a nonstandard directory <include dir>
1559   CPP         C preprocessor
1560   LDFLAGS_EX  extra linker flags for linking executables only
1561   LDFLAGS_SL  extra linker flags for linking shared libraries only
1562   DOCBOOKSTYLE
1563               location of DocBook stylesheets
1564
1565 Use these variables to override the choices made by `configure' or to help
1566 it to find libraries and programs with nonstandard names/locations.
1567
1568 Report bugs to <pgsql-bugs@postgresql.org>.
1569 _ACEOF
1570 ac_status=$?
1571 fi
1572
1573 if test "$ac_init_help" = "recursive"; then
1574   # If there are subdirs, report their specific --help.
1575   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1576     test -d "$ac_dir" ||
1577       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1578       continue
1579     ac_builddir=.
1580
1581 case "$ac_dir" in
1582 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1583 *)
1584   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1585   # A ".." for each directory in $ac_dir_suffix.
1586   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1587   case $ac_top_builddir_sub in
1588   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1589   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1590   esac ;;
1591 esac
1592 ac_abs_top_builddir=$ac_pwd
1593 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1594 # for backward compatibility:
1595 ac_top_builddir=$ac_top_build_prefix
1596
1597 case $srcdir in
1598   .)  # We are building in place.
1599     ac_srcdir=.
1600     ac_top_srcdir=$ac_top_builddir_sub
1601     ac_abs_top_srcdir=$ac_pwd ;;
1602   [\\/]* | ?:[\\/]* )  # Absolute name.
1603     ac_srcdir=$srcdir$ac_dir_suffix;
1604     ac_top_srcdir=$srcdir
1605     ac_abs_top_srcdir=$srcdir ;;
1606   *) # Relative name.
1607     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1608     ac_top_srcdir=$ac_top_build_prefix$srcdir
1609     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1610 esac
1611 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1612
1613     cd "$ac_dir" || { ac_status=$?; continue; }
1614     # Check for guested configure.
1615     if test -f "$ac_srcdir/configure.gnu"; then
1616       echo &&
1617       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1618     elif test -f "$ac_srcdir/configure"; then
1619       echo &&
1620       $SHELL "$ac_srcdir/configure" --help=recursive
1621     else
1622       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1623     fi || ac_status=$?
1624     cd "$ac_pwd" || { ac_status=$?; break; }
1625   done
1626 fi
1627
1628 test -n "$ac_init_help" && exit $ac_status
1629 if $ac_init_version; then
1630   cat <<\_ACEOF
1631 PostgreSQL configure 9.1devel
1632 generated by GNU Autoconf 2.63
1633
1634 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
1635 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
1636 This configure script is free software; the Free Software Foundation
1637 gives unlimited permission to copy, distribute and modify it.
1638
1639 Copyright (c) 1996-2011, PostgreSQL Global Development Group
1640 _ACEOF
1641   exit
1642 fi
1643 cat >config.log <<_ACEOF
1644 This file contains any messages produced by compilers while
1645 running configure, to aid debugging if configure makes a mistake.
1646
1647 It was created by PostgreSQL $as_me 9.1devel, which was
1648 generated by GNU Autoconf 2.63.  Invocation command line was
1649
1650   $ $0 $@
1651
1652 _ACEOF
1653 exec 5>>config.log
1654 {
1655 cat <<_ASUNAME
1656 ## --------- ##
1657 ## Platform. ##
1658 ## --------- ##
1659
1660 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1661 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1662 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1663 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1664 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1665
1666 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1667 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1668
1669 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1670 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1671 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1672 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1673 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1674 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1675 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1676
1677 _ASUNAME
1678
1679 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1680 for as_dir in $PATH
1681 do
1682   IFS=$as_save_IFS
1683   test -z "$as_dir" && as_dir=.
1684   $as_echo "PATH: $as_dir"
1685 done
1686 IFS=$as_save_IFS
1687
1688 } >&5
1689
1690 cat >&5 <<_ACEOF
1691
1692
1693 ## ----------- ##
1694 ## Core tests. ##
1695 ## ----------- ##
1696
1697 _ACEOF
1698
1699
1700 # Keep a trace of the command line.
1701 # Strip out --no-create and --no-recursion so they do not pile up.
1702 # Strip out --silent because we don't want to record it for future runs.
1703 # Also quote any args containing shell meta-characters.
1704 # Make two passes to allow for proper duplicate-argument suppression.
1705 ac_configure_args=
1706 ac_configure_args0=
1707 ac_configure_args1=
1708 ac_must_keep_next=false
1709 for ac_pass in 1 2
1710 do
1711   for ac_arg
1712   do
1713     case $ac_arg in
1714     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1715     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1716     | -silent | --silent | --silen | --sile | --sil)
1717       continue ;;
1718     *\'*)
1719       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1720     esac
1721     case $ac_pass in
1722     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1723     2)
1724       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1725       if test $ac_must_keep_next = true; then
1726         ac_must_keep_next=false # Got value, back to normal.
1727       else
1728         case $ac_arg in
1729           *=* | --config-cache | -C | -disable-* | --disable-* \
1730           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1731           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1732           | -with-* | --with-* | -without-* | --without-* | --x)
1733             case "$ac_configure_args0 " in
1734               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1735             esac
1736             ;;
1737           -* ) ac_must_keep_next=true ;;
1738         esac
1739       fi
1740       ac_configure_args="$ac_configure_args '$ac_arg'"
1741       ;;
1742     esac
1743   done
1744 done
1745 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1746 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1747
1748 # When interrupted or exit'd, cleanup temporary files, and complete
1749 # config.log.  We remove comments because anyway the quotes in there
1750 # would cause problems or look ugly.
1751 # WARNING: Use '\'' to represent an apostrophe within the trap.
1752 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1753 trap 'exit_status=$?
1754   # Save into config.log some information that might help in debugging.
1755   {
1756     echo
1757
1758     cat <<\_ASBOX
1759 ## ---------------- ##
1760 ## Cache variables. ##
1761 ## ---------------- ##
1762 _ASBOX
1763     echo
1764     # The following way of writing the cache mishandles newlines in values,
1765 (
1766   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1767     eval ac_val=\$$ac_var
1768     case $ac_val in #(
1769     *${as_nl}*)
1770       case $ac_var in #(
1771       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
1772 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
1773       esac
1774       case $ac_var in #(
1775       _ | IFS | as_nl) ;; #(
1776       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
1777       *) $as_unset $ac_var ;;
1778       esac ;;
1779     esac
1780   done
1781   (set) 2>&1 |
1782     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1783     *${as_nl}ac_space=\ *)
1784       sed -n \
1785         "s/'\''/'\''\\\\'\'''\''/g;
1786           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1787       ;; #(
1788     *)
1789       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1790       ;;
1791     esac |
1792     sort
1793 )
1794     echo
1795
1796     cat <<\_ASBOX
1797 ## ----------------- ##
1798 ## Output variables. ##
1799 ## ----------------- ##
1800 _ASBOX
1801     echo
1802     for ac_var in $ac_subst_vars
1803     do
1804       eval ac_val=\$$ac_var
1805       case $ac_val in
1806       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1807       esac
1808       $as_echo "$ac_var='\''$ac_val'\''"
1809     done | sort
1810     echo
1811
1812     if test -n "$ac_subst_files"; then
1813       cat <<\_ASBOX
1814 ## ------------------- ##
1815 ## File substitutions. ##
1816 ## ------------------- ##
1817 _ASBOX
1818       echo
1819       for ac_var in $ac_subst_files
1820       do
1821         eval ac_val=\$$ac_var
1822         case $ac_val in
1823         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1824         esac
1825         $as_echo "$ac_var='\''$ac_val'\''"
1826       done | sort
1827       echo
1828     fi
1829
1830     if test -s confdefs.h; then
1831       cat <<\_ASBOX
1832 ## ----------- ##
1833 ## confdefs.h. ##
1834 ## ----------- ##
1835 _ASBOX
1836       echo
1837       cat confdefs.h
1838       echo
1839     fi
1840     test "$ac_signal" != 0 &&
1841       $as_echo "$as_me: caught signal $ac_signal"
1842     $as_echo "$as_me: exit $exit_status"
1843   } >&5
1844   rm -f core *.core core.conftest.* &&
1845     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1846     exit $exit_status
1847 ' 0
1848 for ac_signal in 1 2 13 15; do
1849   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1850 done
1851 ac_signal=0
1852
1853 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1854 rm -f -r conftest* confdefs.h
1855
1856 # Predefined preprocessor variables.
1857
1858 cat >>confdefs.h <<_ACEOF
1859 #define PACKAGE_NAME "$PACKAGE_NAME"
1860 _ACEOF
1861
1862
1863 cat >>confdefs.h <<_ACEOF
1864 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1865 _ACEOF
1866
1867
1868 cat >>confdefs.h <<_ACEOF
1869 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1870 _ACEOF
1871
1872
1873 cat >>confdefs.h <<_ACEOF
1874 #define PACKAGE_STRING "$PACKAGE_STRING"
1875 _ACEOF
1876
1877
1878 cat >>confdefs.h <<_ACEOF
1879 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1880 _ACEOF
1881
1882
1883 # Let the site file select an alternate cache file if it wants to.
1884 # Prefer an explicitly selected file to automatically selected ones.
1885 ac_site_file1=NONE
1886 ac_site_file2=NONE
1887 if test -n "$CONFIG_SITE"; then
1888   ac_site_file1=$CONFIG_SITE
1889 elif test "x$prefix" != xNONE; then
1890   ac_site_file1=$prefix/share/config.site
1891   ac_site_file2=$prefix/etc/config.site
1892 else
1893   ac_site_file1=$ac_default_prefix/share/config.site
1894   ac_site_file2=$ac_default_prefix/etc/config.site
1895 fi
1896 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
1897 do
1898   test "x$ac_site_file" = xNONE && continue
1899   if test -r "$ac_site_file"; then
1900     { $as_echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1901 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
1902     sed 's/^/| /' "$ac_site_file" >&5
1903     . "$ac_site_file"
1904   fi
1905 done
1906
1907 if test -r "$cache_file"; then
1908   # Some versions of bash will fail to source /dev/null (special
1909   # files actually), so we avoid doing that.
1910   if test -f "$cache_file"; then
1911     { $as_echo "$as_me:$LINENO: loading cache $cache_file" >&5
1912 $as_echo "$as_me: loading cache $cache_file" >&6;}
1913     case $cache_file in
1914       [\\/]* | ?:[\\/]* ) . "$cache_file";;
1915       *)                      . "./$cache_file";;
1916     esac
1917   fi
1918 else
1919   { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5
1920 $as_echo "$as_me: creating cache $cache_file" >&6;}
1921   >$cache_file
1922 fi
1923
1924 # Check that the precious variables saved in the cache have kept the same
1925 # value.
1926 ac_cache_corrupted=false
1927 for ac_var in $ac_precious_vars; do
1928   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1929   eval ac_new_set=\$ac_env_${ac_var}_set
1930   eval ac_old_val=\$ac_cv_env_${ac_var}_value
1931   eval ac_new_val=\$ac_env_${ac_var}_value
1932   case $ac_old_set,$ac_new_set in
1933     set,)
1934       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1935 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1936       ac_cache_corrupted=: ;;
1937     ,set)
1938       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1939 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1940       ac_cache_corrupted=: ;;
1941     ,);;
1942     *)
1943       if test "x$ac_old_val" != "x$ac_new_val"; then
1944         # differences in whitespace do not lead to failure.
1945         ac_old_val_w=`echo x $ac_old_val`
1946         ac_new_val_w=`echo x $ac_new_val`
1947         if test "$ac_old_val_w" != "$ac_new_val_w"; then
1948           { $as_echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1949 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1950           ac_cache_corrupted=:
1951         else
1952           { $as_echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
1953 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
1954           eval $ac_var=\$ac_old_val
1955         fi
1956         { $as_echo "$as_me:$LINENO:   former value:  \`$ac_old_val'" >&5
1957 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
1958         { $as_echo "$as_me:$LINENO:   current value: \`$ac_new_val'" >&5
1959 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
1960       fi;;
1961   esac
1962   # Pass precious variables to config.status.
1963   if test "$ac_new_set" = set; then
1964     case $ac_new_val in
1965     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1966     *) ac_arg=$ac_var=$ac_new_val ;;
1967     esac
1968     case " $ac_configure_args " in
1969       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1970       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1971     esac
1972   fi
1973 done
1974 if $ac_cache_corrupted; then
1975   { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1976 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
1977   { $as_echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1978 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1979   { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1980 $as_echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1981    { (exit 1); exit 1; }; }
1982 fi
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008 ac_ext=c
2009 ac_cpp='$CPP $CPPFLAGS'
2010 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2011 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2012 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2013
2014
2015
2016
2017
2018
2019 ac_aux_dir=
2020 for ac_dir in config "$srcdir"/config; do
2021   if test -f "$ac_dir/install-sh"; then
2022     ac_aux_dir=$ac_dir
2023     ac_install_sh="$ac_aux_dir/install-sh -c"
2024     break
2025   elif test -f "$ac_dir/install.sh"; then
2026     ac_aux_dir=$ac_dir
2027     ac_install_sh="$ac_aux_dir/install.sh -c"
2028     break
2029   elif test -f "$ac_dir/shtool"; then
2030     ac_aux_dir=$ac_dir
2031     ac_install_sh="$ac_aux_dir/shtool install -c"
2032     break
2033   fi
2034 done
2035 if test -z "$ac_aux_dir"; then
2036   { { $as_echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&5
2037 $as_echo "$as_me: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&2;}
2038    { (exit 1); exit 1; }; }
2039 fi
2040
2041 # These three variables are undocumented and unsupported,
2042 # and are intended to be withdrawn in a future Autoconf release.
2043 # They can cause serious problems if a builder's source tree is in a directory
2044 # whose full name contains unusual characters.
2045 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2046 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2047 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2048
2049
2050
2051 configure_args=$ac_configure_args
2052
2053
2054
2055 cat >>confdefs.h <<_ACEOF
2056 #define PG_VERSION "$PACKAGE_VERSION"
2057 _ACEOF
2058
2059 PG_MAJORVERSION=`expr "$PACKAGE_VERSION" : '\([0-9][0-9]*\.[0-9][0-9]*\)'`
2060
2061
2062 cat >>confdefs.h <<_ACEOF
2063 #define PG_MAJORVERSION "$PG_MAJORVERSION"
2064 _ACEOF
2065
2066
2067 # Make sure we can run config.sub.
2068 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2069   { { $as_echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
2070 $as_echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
2071    { (exit 1); exit 1; }; }
2072
2073 { $as_echo "$as_me:$LINENO: checking build system type" >&5
2074 $as_echo_n "checking build system type... " >&6; }
2075 if test "${ac_cv_build+set}" = set; then
2076   $as_echo_n "(cached) " >&6
2077 else
2078   ac_build_alias=$build_alias
2079 test "x$ac_build_alias" = x &&
2080   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2081 test "x$ac_build_alias" = x &&
2082   { { $as_echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
2083 $as_echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
2084    { (exit 1); exit 1; }; }
2085 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2086   { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
2087 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
2088    { (exit 1); exit 1; }; }
2089
2090 fi
2091 { $as_echo "$as_me:$LINENO: result: $ac_cv_build" >&5
2092 $as_echo "$ac_cv_build" >&6; }
2093 case $ac_cv_build in
2094 *-*-*) ;;
2095 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
2096 $as_echo "$as_me: error: invalid value of canonical build" >&2;}
2097    { (exit 1); exit 1; }; };;
2098 esac
2099 build=$ac_cv_build
2100 ac_save_IFS=$IFS; IFS='-'
2101 set x $ac_cv_build
2102 shift
2103 build_cpu=$1
2104 build_vendor=$2
2105 shift; shift
2106 # Remember, the first character of IFS is used to create $*,
2107 # except with old shells:
2108 build_os=$*
2109 IFS=$ac_save_IFS
2110 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2111
2112
2113 { $as_echo "$as_me:$LINENO: checking host system type" >&5
2114 $as_echo_n "checking host system type... " >&6; }
2115 if test "${ac_cv_host+set}" = set; then
2116   $as_echo_n "(cached) " >&6
2117 else
2118   if test "x$host_alias" = x; then
2119   ac_cv_host=$ac_cv_build
2120 else
2121   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2122     { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
2123 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
2124    { (exit 1); exit 1; }; }
2125 fi
2126
2127 fi
2128 { $as_echo "$as_me:$LINENO: result: $ac_cv_host" >&5
2129 $as_echo "$ac_cv_host" >&6; }
2130 case $ac_cv_host in
2131 *-*-*) ;;
2132 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
2133 $as_echo "$as_me: error: invalid value of canonical host" >&2;}
2134    { (exit 1); exit 1; }; };;
2135 esac
2136 host=$ac_cv_host
2137 ac_save_IFS=$IFS; IFS='-'
2138 set x $ac_cv_host
2139 shift
2140 host_cpu=$1
2141 host_vendor=$2
2142 shift; shift
2143 # Remember, the first character of IFS is used to create $*,
2144 # except with old shells:
2145 host_os=$*
2146 IFS=$ac_save_IFS
2147 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2148
2149
2150
2151 template=
2152 { $as_echo "$as_me:$LINENO: checking which template to use" >&5
2153 $as_echo_n "checking which template to use... " >&6; }
2154
2155
2156
2157
2158 # Check whether --with-template was given.
2159 if test "${with_template+set}" = set; then
2160   withval=$with_template;
2161   case $withval in
2162     yes)
2163       { { $as_echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
2164 $as_echo "$as_me: error: argument required for --with-template option" >&2;}
2165    { (exit 1); exit 1; }; }
2166       ;;
2167     no)
2168       { { $as_echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
2169 $as_echo "$as_me: error: argument required for --with-template option" >&2;}
2170    { (exit 1); exit 1; }; }
2171       ;;
2172     *)
2173
2174   case $withval in
2175     list)   echo; ls "$srcdir/src/template"; exit;;
2176     *)      if test -f "$srcdir/src/template/$with_template" ; then
2177               template=$withval
2178             else
2179               { { $as_echo "$as_me:$LINENO: error: '$withval' is not a valid template name. Use 'list' for a list." >&5
2180 $as_echo "$as_me: error: '$withval' is not a valid template name. Use 'list' for a list." >&2;}
2181    { (exit 1); exit 1; }; }
2182             fi;;
2183   esac
2184
2185       ;;
2186   esac
2187
2188 else
2189
2190 # --with-template not given
2191
2192 case $host_os in
2193      aix*) template=aix ;;
2194     bsdi*) template=bsdi ;;
2195   cygwin*) template=cygwin ;;
2196   darwin*) template=darwin ;;
2197     dgux*) template=dgux ;;
2198  freebsd*) template=freebsd ;;
2199     hpux*) template=hpux ;;
2200     irix*) template=irix ;;
2201  linux*|gnu*|k*bsd*-gnu)
2202            template=linux ;;
2203    mingw*) template=win32 ;;
2204   netbsd*) template=netbsd ;;
2205 nextstep*) template=nextstep ;;
2206  openbsd*) template=openbsd ;;
2207      osf*) template=osf ;;
2208      sco*) template=sco ;;
2209  solaris*) template=solaris ;;
2210    sunos*) template=sunos4 ;;
2211  sysv4.2*)
2212         case $host_vendor in
2213           univel) template=univel ;;
2214         esac ;;
2215    sysv4*) template=svr4 ;;
2216    sysv5*) template=unixware ;;
2217   ultrix*) template=ultrix4 ;;
2218 esac
2219
2220   if test x"$template" = x"" ; then
2221     { { $as_echo "$as_me:$LINENO: error:
2222 *******************************************************************
2223 PostgreSQL has apparently not been ported to your platform yet.
2224 To try a manual configuration, look into the src/template directory
2225 for a similar platform and use the '--with-template=' option.
2226
2227 Please also contact <pgsql-bugs@postgresql.org> to see about
2228 rectifying this.  Include the above 'checking host system type...'
2229 line.
2230 *******************************************************************
2231 " >&5
2232 $as_echo "$as_me: error:
2233 *******************************************************************
2234 PostgreSQL has apparently not been ported to your platform yet.
2235 To try a manual configuration, look into the src/template directory
2236 for a similar platform and use the '--with-template=' option.
2237
2238 Please also contact <pgsql-bugs@postgresql.org> to see about
2239 rectifying this.  Include the above 'checking host system type...'
2240 line.
2241 *******************************************************************
2242 " >&2;}
2243    { (exit 1); exit 1; }; }
2244   fi
2245
2246
2247 fi
2248
2249
2250
2251 { $as_echo "$as_me:$LINENO: result: $template" >&5
2252 $as_echo "$template" >&6; }
2253
2254 PORTNAME=$template
2255
2256
2257 # Initialize default assumption that we do not need separate assembly code
2258 # for TAS (test-and-set).  This can be overridden by the template file
2259 # when it's executed.
2260 need_tas=no
2261 tas_file=dummy.s
2262
2263
2264
2265 ##
2266 ## Command line options
2267 ##
2268
2269 #
2270 # Add non-standard directories to the include path
2271 #
2272
2273
2274
2275 # Check whether --with-includes was given.
2276 if test "${with_includes+set}" = set; then
2277   withval=$with_includes;
2278   case $withval in
2279     yes)
2280       { { $as_echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2281 $as_echo "$as_me: error: argument required for --with-includes option" >&2;}
2282    { (exit 1); exit 1; }; }
2283       ;;
2284     no)
2285       { { $as_echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2286 $as_echo "$as_me: error: argument required for --with-includes option" >&2;}
2287    { (exit 1); exit 1; }; }
2288       ;;
2289     *)
2290
2291       ;;
2292   esac
2293
2294 fi
2295
2296
2297
2298
2299 #
2300 # Add non-standard directories to the library search path
2301 #
2302
2303
2304
2305 # Check whether --with-libraries was given.
2306 if test "${with_libraries+set}" = set; then
2307   withval=$with_libraries;
2308   case $withval in
2309     yes)
2310       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2311 $as_echo "$as_me: error: argument required for --with-libraries option" >&2;}
2312    { (exit 1); exit 1; }; }
2313       ;;
2314     no)
2315       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2316 $as_echo "$as_me: error: argument required for --with-libraries option" >&2;}
2317    { (exit 1); exit 1; }; }
2318       ;;
2319     *)
2320       LIBRARY_DIRS=$withval
2321       ;;
2322   esac
2323
2324 fi
2325
2326
2327
2328
2329
2330
2331 # Check whether --with-libs was given.
2332 if test "${with_libs+set}" = set; then
2333   withval=$with_libs;
2334   case $withval in
2335     yes)
2336       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2337 $as_echo "$as_me: error: argument required for --with-libs option" >&2;}
2338    { (exit 1); exit 1; }; }
2339       ;;
2340     no)
2341       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2342 $as_echo "$as_me: error: argument required for --with-libs option" >&2;}
2343    { (exit 1); exit 1; }; }
2344       ;;
2345     *)
2346       LIBRARY_DIRS=$withval
2347       ;;
2348   esac
2349
2350 fi
2351
2352
2353
2354
2355 #
2356 # 64-bit integer date/time storage: enabled by default.
2357 #
2358 { $as_echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
2359 $as_echo_n "checking whether to build with 64-bit integer date/time support... " >&6; }
2360
2361
2362 # Check whether --enable-integer-datetimes was given.
2363 if test "${enable_integer_datetimes+set}" = set; then
2364   enableval=$enable_integer_datetimes;
2365   case $enableval in
2366     yes)
2367
2368 cat >>confdefs.h <<\_ACEOF
2369 #define USE_INTEGER_DATETIMES 1
2370 _ACEOF
2371
2372       ;;
2373     no)
2374       :
2375       ;;
2376     *)
2377       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-integer-datetimes option" >&5
2378 $as_echo "$as_me: error: no argument expected for --enable-integer-datetimes option" >&2;}
2379    { (exit 1); exit 1; }; }
2380       ;;
2381   esac
2382
2383 else
2384   enable_integer_datetimes=yes
2385
2386 cat >>confdefs.h <<\_ACEOF
2387 #define USE_INTEGER_DATETIMES 1
2388 _ACEOF
2389
2390 fi
2391
2392
2393 { $as_echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
2394 $as_echo "$enable_integer_datetimes" >&6; }
2395
2396
2397 #
2398 # NLS
2399 #
2400 { $as_echo "$as_me:$LINENO: checking whether NLS is wanted" >&5
2401 $as_echo_n "checking whether NLS is wanted... " >&6; }
2402
2403
2404 # Check whether --enable-nls was given.
2405 if test "${enable_nls+set}" = set; then
2406   enableval=$enable_nls;
2407   case $enableval in
2408     yes)
2409       :
2410       ;;
2411     no)
2412       :
2413       ;;
2414     *)
2415       enable_nls=yes
2416 WANTED_LANGUAGES=$enableval
2417       ;;
2418   esac
2419
2420 else
2421   enable_nls=no
2422 fi
2423
2424
2425
2426 if test "$enable_nls" = yes; then
2427
2428 cat >>confdefs.h <<\_ACEOF
2429 #define ENABLE_NLS 1
2430 _ACEOF
2431
2432 fi
2433
2434 { $as_echo "$as_me:$LINENO: result: $enable_nls" >&5
2435 $as_echo "$enable_nls" >&6; }
2436
2437
2438
2439 #
2440 # Default port number (--with-pgport), default 5432
2441 #
2442 { $as_echo "$as_me:$LINENO: checking for default port number" >&5
2443 $as_echo_n "checking for default port number... " >&6; }
2444
2445
2446
2447 # Check whether --with-pgport was given.
2448 if test "${with_pgport+set}" = set; then
2449   withval=$with_pgport;
2450   case $withval in
2451     yes)
2452       { { $as_echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2453 $as_echo "$as_me: error: argument required for --with-pgport option" >&2;}
2454    { (exit 1); exit 1; }; }
2455       ;;
2456     no)
2457       { { $as_echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2458 $as_echo "$as_me: error: argument required for --with-pgport option" >&2;}
2459    { (exit 1); exit 1; }; }
2460       ;;
2461     *)
2462       default_port=$withval
2463       ;;
2464   esac
2465
2466 else
2467   default_port=5432
2468 fi
2469
2470
2471 { $as_echo "$as_me:$LINENO: result: $default_port" >&5
2472 $as_echo "$default_port" >&6; }
2473 # Need both of these because some places want an integer and some a string
2474
2475 cat >>confdefs.h <<_ACEOF
2476 #define DEF_PGPORT ${default_port}
2477 _ACEOF
2478
2479
2480 cat >>confdefs.h <<_ACEOF
2481 #define DEF_PGPORT_STR "${default_port}"
2482 _ACEOF
2483
2484
2485
2486 #
2487 # Option to disable shared libraries
2488 #
2489
2490
2491 # Check whether --enable-shared was given.
2492 if test "${enable_shared+set}" = set; then
2493   enableval=$enable_shared;
2494   case $enableval in
2495     yes)
2496       :
2497       ;;
2498     no)
2499       :
2500       ;;
2501     *)
2502       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-shared option" >&5
2503 $as_echo "$as_me: error: no argument expected for --enable-shared option" >&2;}
2504    { (exit 1); exit 1; }; }
2505       ;;
2506   esac
2507
2508 else
2509   enable_shared=yes
2510
2511 fi
2512
2513
2514
2515
2516 #
2517 # '-rpath'-like feature can be disabled
2518 #
2519
2520
2521 # Check whether --enable-rpath was given.
2522 if test "${enable_rpath+set}" = set; then
2523   enableval=$enable_rpath;
2524   case $enableval in
2525     yes)
2526       :
2527       ;;
2528     no)
2529       :
2530       ;;
2531     *)
2532       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-rpath option" >&5
2533 $as_echo "$as_me: error: no argument expected for --enable-rpath option" >&2;}
2534    { (exit 1); exit 1; }; }
2535       ;;
2536   esac
2537
2538 else
2539   enable_rpath=yes
2540
2541 fi
2542
2543
2544
2545
2546 #
2547 # Spinlocks
2548 #
2549
2550
2551 # Check whether --enable-spinlocks was given.
2552 if test "${enable_spinlocks+set}" = set; then
2553   enableval=$enable_spinlocks;
2554   case $enableval in
2555     yes)
2556       :
2557       ;;
2558     no)
2559       :
2560       ;;
2561     *)
2562       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-spinlocks option" >&5
2563 $as_echo "$as_me: error: no argument expected for --enable-spinlocks option" >&2;}
2564    { (exit 1); exit 1; }; }
2565       ;;
2566   esac
2567
2568 else
2569   enable_spinlocks=yes
2570
2571 fi
2572
2573
2574
2575 #
2576 # --enable-debug adds -g to compiler flags
2577 #
2578
2579
2580 # Check whether --enable-debug was given.
2581 if test "${enable_debug+set}" = set; then
2582   enableval=$enable_debug;
2583   case $enableval in
2584     yes)
2585       :
2586       ;;
2587     no)
2588       :
2589       ;;
2590     *)
2591       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-debug option" >&5
2592 $as_echo "$as_me: error: no argument expected for --enable-debug option" >&2;}
2593    { (exit 1); exit 1; }; }
2594       ;;
2595   esac
2596
2597 else
2598   enable_debug=no
2599
2600 fi
2601
2602
2603
2604
2605 #
2606 # --enable-profiling enables gcc profiling
2607 #
2608
2609
2610 # Check whether --enable-profiling was given.
2611 if test "${enable_profiling+set}" = set; then
2612   enableval=$enable_profiling;
2613   case $enableval in
2614     yes)
2615       :
2616       ;;
2617     no)
2618       :
2619       ;;
2620     *)
2621       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-profiling option" >&5
2622 $as_echo "$as_me: error: no argument expected for --enable-profiling option" >&2;}
2623    { (exit 1); exit 1; }; }
2624       ;;
2625   esac
2626
2627 else
2628   enable_profiling=no
2629
2630 fi
2631
2632
2633
2634
2635 #
2636 # --enable-coverage enables generation of code coverage metrics with gcov
2637 #
2638
2639
2640 # Check whether --enable-coverage was given.
2641 if test "${enable_coverage+set}" = set; then
2642   enableval=$enable_coverage;
2643   case $enableval in
2644     yes)
2645       for ac_prog in gcov
2646 do
2647   # Extract the first word of "$ac_prog", so it can be a program name with args.
2648 set dummy $ac_prog; ac_word=$2
2649 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2650 $as_echo_n "checking for $ac_word... " >&6; }
2651 if test "${ac_cv_prog_GCOV+set}" = set; then
2652   $as_echo_n "(cached) " >&6
2653 else
2654   if test -n "$GCOV"; then
2655   ac_cv_prog_GCOV="$GCOV" # Let the user override the test.
2656 else
2657 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2658 for as_dir in $PATH
2659 do
2660   IFS=$as_save_IFS
2661   test -z "$as_dir" && as_dir=.
2662   for ac_exec_ext in '' $ac_executable_extensions; do
2663   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2664     ac_cv_prog_GCOV="$ac_prog"
2665     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2666     break 2
2667   fi
2668 done
2669 done
2670 IFS=$as_save_IFS
2671
2672 fi
2673 fi
2674 GCOV=$ac_cv_prog_GCOV
2675 if test -n "$GCOV"; then
2676   { $as_echo "$as_me:$LINENO: result: $GCOV" >&5
2677 $as_echo "$GCOV" >&6; }
2678 else
2679   { $as_echo "$as_me:$LINENO: result: no" >&5
2680 $as_echo "no" >&6; }
2681 fi
2682
2683
2684   test -n "$GCOV" && break
2685 done
2686
2687 if test -z "$GCOV"; then
2688   { { $as_echo "$as_me:$LINENO: error: gcov not found" >&5
2689 $as_echo "$as_me: error: gcov not found" >&2;}
2690    { (exit 1); exit 1; }; }
2691 fi
2692 for ac_prog in lcov
2693 do
2694   # Extract the first word of "$ac_prog", so it can be a program name with args.
2695 set dummy $ac_prog; ac_word=$2
2696 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2697 $as_echo_n "checking for $ac_word... " >&6; }
2698 if test "${ac_cv_prog_LCOV+set}" = set; then
2699   $as_echo_n "(cached) " >&6
2700 else
2701   if test -n "$LCOV"; then
2702   ac_cv_prog_LCOV="$LCOV" # Let the user override the test.
2703 else
2704 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2705 for as_dir in $PATH
2706 do
2707   IFS=$as_save_IFS
2708   test -z "$as_dir" && as_dir=.
2709   for ac_exec_ext in '' $ac_executable_extensions; do
2710   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2711     ac_cv_prog_LCOV="$ac_prog"
2712     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2713     break 2
2714   fi
2715 done
2716 done
2717 IFS=$as_save_IFS
2718
2719 fi
2720 fi
2721 LCOV=$ac_cv_prog_LCOV
2722 if test -n "$LCOV"; then
2723   { $as_echo "$as_me:$LINENO: result: $LCOV" >&5
2724 $as_echo "$LCOV" >&6; }
2725 else
2726   { $as_echo "$as_me:$LINENO: result: no" >&5
2727 $as_echo "no" >&6; }
2728 fi
2729
2730
2731   test -n "$LCOV" && break
2732 done
2733
2734 if test -z "$LCOV"; then
2735   { { $as_echo "$as_me:$LINENO: error: lcov not found" >&5
2736 $as_echo "$as_me: error: lcov not found" >&2;}
2737    { (exit 1); exit 1; }; }
2738 fi
2739 for ac_prog in genhtml
2740 do
2741   # Extract the first word of "$ac_prog", so it can be a program name with args.
2742 set dummy $ac_prog; ac_word=$2
2743 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2744 $as_echo_n "checking for $ac_word... " >&6; }
2745 if test "${ac_cv_prog_GENHTML+set}" = set; then
2746   $as_echo_n "(cached) " >&6
2747 else
2748   if test -n "$GENHTML"; then
2749   ac_cv_prog_GENHTML="$GENHTML" # Let the user override the test.
2750 else
2751 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2752 for as_dir in $PATH
2753 do
2754   IFS=$as_save_IFS
2755   test -z "$as_dir" && as_dir=.
2756   for ac_exec_ext in '' $ac_executable_extensions; do
2757   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2758     ac_cv_prog_GENHTML="$ac_prog"
2759     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2760     break 2
2761   fi
2762 done
2763 done
2764 IFS=$as_save_IFS
2765
2766 fi
2767 fi
2768 GENHTML=$ac_cv_prog_GENHTML
2769 if test -n "$GENHTML"; then
2770   { $as_echo "$as_me:$LINENO: result: $GENHTML" >&5
2771 $as_echo "$GENHTML" >&6; }
2772 else
2773   { $as_echo "$as_me:$LINENO: result: no" >&5
2774 $as_echo "no" >&6; }
2775 fi
2776
2777
2778   test -n "$GENHTML" && break
2779 done
2780
2781 if test -z "$GENHTML"; then
2782   { { $as_echo "$as_me:$LINENO: error: genhtml not found" >&5
2783 $as_echo "$as_me: error: genhtml not found" >&2;}
2784    { (exit 1); exit 1; }; }
2785 fi
2786       ;;
2787     no)
2788       :
2789       ;;
2790     *)
2791       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-coverage option" >&5
2792 $as_echo "$as_me: error: no argument expected for --enable-coverage option" >&2;}
2793    { (exit 1); exit 1; }; }
2794       ;;
2795   esac
2796
2797 else
2798   enable_coverage=no
2799
2800 fi
2801
2802
2803
2804
2805 #
2806 # DTrace
2807 #
2808
2809
2810 # Check whether --enable-dtrace was given.
2811 if test "${enable_dtrace+set}" = set; then
2812   enableval=$enable_dtrace;
2813   case $enableval in
2814     yes)
2815
2816 cat >>confdefs.h <<\_ACEOF
2817 #define ENABLE_DTRACE 1
2818 _ACEOF
2819
2820 for ac_prog in dtrace
2821 do
2822   # Extract the first word of "$ac_prog", so it can be a program name with args.
2823 set dummy $ac_prog; ac_word=$2
2824 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2825 $as_echo_n "checking for $ac_word... " >&6; }
2826 if test "${ac_cv_prog_DTRACE+set}" = set; then
2827   $as_echo_n "(cached) " >&6
2828 else
2829   if test -n "$DTRACE"; then
2830   ac_cv_prog_DTRACE="$DTRACE" # Let the user override the test.
2831 else
2832 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2833 for as_dir in $PATH
2834 do
2835   IFS=$as_save_IFS
2836   test -z "$as_dir" && as_dir=.
2837   for ac_exec_ext in '' $ac_executable_extensions; do
2838   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2839     ac_cv_prog_DTRACE="$ac_prog"
2840     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2841     break 2
2842   fi
2843 done
2844 done
2845 IFS=$as_save_IFS
2846
2847 fi
2848 fi
2849 DTRACE=$ac_cv_prog_DTRACE
2850 if test -n "$DTRACE"; then
2851   { $as_echo "$as_me:$LINENO: result: $DTRACE" >&5
2852 $as_echo "$DTRACE" >&6; }
2853 else
2854   { $as_echo "$as_me:$LINENO: result: no" >&5
2855 $as_echo "no" >&6; }
2856 fi
2857
2858
2859   test -n "$DTRACE" && break
2860 done
2861
2862 if test -z "$DTRACE"; then
2863   { { $as_echo "$as_me:$LINENO: error: dtrace not found" >&5
2864 $as_echo "$as_me: error: dtrace not found" >&2;}
2865    { (exit 1); exit 1; }; }
2866 fi
2867
2868       ;;
2869     no)
2870       :
2871       ;;
2872     *)
2873       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-dtrace option" >&5
2874 $as_echo "$as_me: error: no argument expected for --enable-dtrace option" >&2;}
2875    { (exit 1); exit 1; }; }
2876       ;;
2877   esac
2878
2879 else
2880   enable_dtrace=no
2881
2882 fi
2883
2884
2885
2886
2887 #
2888 # Block size
2889 #
2890 { $as_echo "$as_me:$LINENO: checking for block size" >&5
2891 $as_echo_n "checking for block size... " >&6; }
2892
2893
2894
2895 # Check whether --with-blocksize was given.
2896 if test "${with_blocksize+set}" = set; then
2897   withval=$with_blocksize;
2898   case $withval in
2899     yes)
2900       { { $as_echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2901 $as_echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2902    { (exit 1); exit 1; }; }
2903       ;;
2904     no)
2905       { { $as_echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2906 $as_echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2907    { (exit 1); exit 1; }; }
2908       ;;
2909     *)
2910       blocksize=$withval
2911       ;;
2912   esac
2913
2914 else
2915   blocksize=8
2916 fi
2917
2918
2919 case ${blocksize} in
2920   1) BLCKSZ=1024;;
2921   2) BLCKSZ=2048;;
2922   4) BLCKSZ=4096;;
2923   8) BLCKSZ=8192;;
2924  16) BLCKSZ=16384;;
2925  32) BLCKSZ=32768;;
2926   *) { { $as_echo "$as_me:$LINENO: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&5
2927 $as_echo "$as_me: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&2;}
2928    { (exit 1); exit 1; }; }
2929 esac
2930 { $as_echo "$as_me:$LINENO: result: ${blocksize}kB" >&5
2931 $as_echo "${blocksize}kB" >&6; }
2932
2933
2934 cat >>confdefs.h <<_ACEOF
2935 #define BLCKSZ ${BLCKSZ}
2936 _ACEOF
2937
2938
2939 #
2940 # Relation segment size
2941 #
2942 { $as_echo "$as_me:$LINENO: checking for segment size" >&5
2943 $as_echo_n "checking for segment size... " >&6; }
2944
2945
2946
2947 # Check whether --with-segsize was given.
2948 if test "${with_segsize+set}" = set; then
2949   withval=$with_segsize;
2950   case $withval in
2951     yes)
2952       { { $as_echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2953 $as_echo "$as_me: error: argument required for --with-segsize option" >&2;}
2954    { (exit 1); exit 1; }; }
2955       ;;
2956     no)
2957       { { $as_echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2958 $as_echo "$as_me: error: argument required for --with-segsize option" >&2;}
2959    { (exit 1); exit 1; }; }
2960       ;;
2961     *)
2962       segsize=$withval
2963       ;;
2964   esac
2965
2966 else
2967   segsize=1
2968 fi
2969
2970
2971 # this expression is set up to avoid unnecessary integer overflow
2972 # blocksize is already guaranteed to be a factor of 1024
2973 RELSEG_SIZE=`expr '(' 1024 / ${blocksize} ')' '*' ${segsize} '*' 1024`
2974 test $? -eq 0 || exit 1
2975 { $as_echo "$as_me:$LINENO: result: ${segsize}GB" >&5
2976 $as_echo "${segsize}GB" >&6; }
2977
2978
2979 cat >>confdefs.h <<_ACEOF
2980 #define RELSEG_SIZE ${RELSEG_SIZE}
2981 _ACEOF
2982
2983
2984 #
2985 # WAL block size
2986 #
2987 { $as_echo "$as_me:$LINENO: checking for WAL block size" >&5
2988 $as_echo_n "checking for WAL block size... " >&6; }
2989
2990
2991
2992 # Check whether --with-wal-blocksize was given.
2993 if test "${with_wal_blocksize+set}" = set; then
2994   withval=$with_wal_blocksize;
2995   case $withval in
2996     yes)
2997       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
2998 $as_echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
2999    { (exit 1); exit 1; }; }
3000       ;;
3001     no)
3002       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
3003 $as_echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
3004    { (exit 1); exit 1; }; }
3005       ;;
3006     *)
3007       wal_blocksize=$withval
3008       ;;
3009   esac
3010
3011 else
3012   wal_blocksize=8
3013 fi
3014
3015
3016 case ${wal_blocksize} in
3017   1) XLOG_BLCKSZ=1024;;
3018   2) XLOG_BLCKSZ=2048;;
3019   4) XLOG_BLCKSZ=4096;;
3020   8) XLOG_BLCKSZ=8192;;
3021  16) XLOG_BLCKSZ=16384;;
3022  32) XLOG_BLCKSZ=32768;;
3023  64) XLOG_BLCKSZ=65536;;
3024   *) { { $as_echo "$as_me:$LINENO: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&5
3025 $as_echo "$as_me: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&2;}
3026    { (exit 1); exit 1; }; }
3027 esac
3028 { $as_echo "$as_me:$LINENO: result: ${wal_blocksize}kB" >&5
3029 $as_echo "${wal_blocksize}kB" >&6; }
3030
3031
3032 cat >>confdefs.h <<_ACEOF
3033 #define XLOG_BLCKSZ ${XLOG_BLCKSZ}
3034 _ACEOF
3035
3036
3037 #
3038 # WAL segment size
3039 #
3040 { $as_echo "$as_me:$LINENO: checking for WAL segment size" >&5
3041 $as_echo_n "checking for WAL segment size... " >&6; }
3042
3043
3044
3045 # Check whether --with-wal-segsize was given.
3046 if test "${with_wal_segsize+set}" = set; then
3047   withval=$with_wal_segsize;
3048   case $withval in
3049     yes)
3050       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
3051 $as_echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
3052    { (exit 1); exit 1; }; }
3053       ;;
3054     no)
3055       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
3056 $as_echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
3057    { (exit 1); exit 1; }; }
3058       ;;
3059     *)
3060       wal_segsize=$withval
3061       ;;
3062   esac
3063
3064 else
3065   wal_segsize=16
3066 fi
3067
3068
3069 case ${wal_segsize} in
3070   1) ;;
3071   2) ;;
3072   4) ;;
3073   8) ;;
3074  16) ;;
3075  32) ;;
3076  64) ;;
3077   *) { { $as_echo "$as_me:$LINENO: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&5
3078 $as_echo "$as_me: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&2;}
3079    { (exit 1); exit 1; }; }
3080 esac
3081 { $as_echo "$as_me:$LINENO: result: ${wal_segsize}MB" >&5
3082 $as_echo "${wal_segsize}MB" >&6; }
3083
3084
3085 cat >>confdefs.h <<_ACEOF
3086 #define XLOG_SEG_SIZE (${wal_segsize} * 1024 * 1024)
3087 _ACEOF
3088
3089
3090 #
3091 # C compiler
3092 #
3093
3094 # For historical reasons you can also use --with-CC to specify the C compiler
3095 # to use, although the standard way to do this is to set the CC environment
3096 # variable.
3097
3098
3099
3100 # Check whether --with-CC was given.
3101 if test "${with_CC+set}" = set; then
3102   withval=$with_CC;
3103   case $withval in
3104     yes)
3105       { { $as_echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
3106 $as_echo "$as_me: error: argument required for --with-CC option" >&2;}
3107    { (exit 1); exit 1; }; }
3108       ;;
3109     no)
3110       { { $as_echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
3111 $as_echo "$as_me: error: argument required for --with-CC option" >&2;}
3112    { (exit 1); exit 1; }; }
3113       ;;
3114     *)
3115       CC=$with_CC
3116       ;;
3117   esac
3118
3119 fi
3120
3121
3122
3123 case $template in
3124   aix) pgac_cc_list="gcc xlc";;
3125  irix) pgac_cc_list="cc";; # no gcc
3126     *) pgac_cc_list="gcc cc";;
3127 esac
3128
3129 ac_ext=c
3130 ac_cpp='$CPP $CPPFLAGS'
3131 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3132 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3133 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3134 if test -n "$ac_tool_prefix"; then
3135   for ac_prog in $pgac_cc_list
3136   do
3137     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3138 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3139 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3140 $as_echo_n "checking for $ac_word... " >&6; }
3141 if test "${ac_cv_prog_CC+set}" = set; then
3142   $as_echo_n "(cached) " >&6
3143 else
3144   if test -n "$CC"; then
3145   ac_cv_prog_CC="$CC" # Let the user override the test.
3146 else
3147 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3148 for as_dir in $PATH
3149 do
3150   IFS=$as_save_IFS
3151   test -z "$as_dir" && as_dir=.
3152   for ac_exec_ext in '' $ac_executable_extensions; do
3153   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3154     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3155     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3156     break 2
3157   fi
3158 done
3159 done
3160 IFS=$as_save_IFS
3161
3162 fi
3163 fi
3164 CC=$ac_cv_prog_CC
3165 if test -n "$CC"; then
3166   { $as_echo "$as_me:$LINENO: result: $CC" >&5
3167 $as_echo "$CC" >&6; }
3168 else
3169   { $as_echo "$as_me:$LINENO: result: no" >&5
3170 $as_echo "no" >&6; }
3171 fi
3172
3173
3174     test -n "$CC" && break
3175   done
3176 fi
3177 if test -z "$CC"; then
3178   ac_ct_CC=$CC
3179   for ac_prog in $pgac_cc_list
3180 do
3181   # Extract the first word of "$ac_prog", so it can be a program name with args.
3182 set dummy $ac_prog; ac_word=$2
3183 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3184 $as_echo_n "checking for $ac_word... " >&6; }
3185 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3186   $as_echo_n "(cached) " >&6
3187 else
3188   if test -n "$ac_ct_CC"; then
3189   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3190 else
3191 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3192 for as_dir in $PATH
3193 do
3194   IFS=$as_save_IFS
3195   test -z "$as_dir" && as_dir=.
3196   for ac_exec_ext in '' $ac_executable_extensions; do
3197   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3198     ac_cv_prog_ac_ct_CC="$ac_prog"
3199     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3200     break 2
3201   fi
3202 done
3203 done
3204 IFS=$as_save_IFS
3205
3206 fi
3207 fi
3208 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3209 if test -n "$ac_ct_CC"; then
3210   { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
3211 $as_echo "$ac_ct_CC" >&6; }
3212 else
3213   { $as_echo "$as_me:$LINENO: result: no" >&5
3214 $as_echo "no" >&6; }
3215 fi
3216
3217
3218   test -n "$ac_ct_CC" && break
3219 done
3220
3221   if test "x$ac_ct_CC" = x; then
3222     CC=""
3223   else
3224     case $cross_compiling:$ac_tool_warned in
3225 yes:)
3226 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
3227 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3228 ac_tool_warned=yes ;;
3229 esac
3230     CC=$ac_ct_CC
3231   fi
3232 fi
3233
3234
3235 test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3236 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3237 { { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
3238 See \`config.log' for more details." >&5
3239 $as_echo "$as_me: error: no acceptable C compiler found in \$PATH
3240 See \`config.log' for more details." >&2;}
3241    { (exit 1); exit 1; }; }; }
3242
3243 # Provide some information about the compiler.
3244 $as_echo "$as_me:$LINENO: checking for C compiler version" >&5
3245 set X $ac_compile
3246 ac_compiler=$2
3247 { (ac_try="$ac_compiler --version >&5"
3248 case "(($ac_try" in
3249   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3250   *) ac_try_echo=$ac_try;;
3251 esac
3252 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3253 $as_echo "$ac_try_echo") >&5
3254   (eval "$ac_compiler --version >&5") 2>&5
3255   ac_status=$?
3256   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3257   (exit $ac_status); }
3258 { (ac_try="$ac_compiler -v >&5"
3259 case "(($ac_try" in
3260   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3261   *) ac_try_echo=$ac_try;;
3262 esac
3263 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3264 $as_echo "$ac_try_echo") >&5
3265   (eval "$ac_compiler -v >&5") 2>&5
3266   ac_status=$?
3267   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3268   (exit $ac_status); }
3269 { (ac_try="$ac_compiler -V >&5"
3270 case "(($ac_try" in
3271   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3272   *) ac_try_echo=$ac_try;;
3273 esac
3274 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3275 $as_echo "$ac_try_echo") >&5
3276   (eval "$ac_compiler -V >&5") 2>&5
3277   ac_status=$?
3278   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3279   (exit $ac_status); }
3280
3281 cat >conftest.$ac_ext <<_ACEOF
3282 /* confdefs.h.  */
3283 _ACEOF
3284 cat confdefs.h >>conftest.$ac_ext
3285 cat >>conftest.$ac_ext <<_ACEOF
3286 /* end confdefs.h.  */
3287
3288 int
3289 main ()
3290 {
3291
3292   ;
3293   return 0;
3294 }
3295 _ACEOF
3296 ac_clean_files_save=$ac_clean_files
3297 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3298 # Try to create an executable without -o first, disregard a.out.
3299 # It will help us diagnose broken compilers, and finding out an intuition
3300 # of exeext.
3301 { $as_echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
3302 $as_echo_n "checking for C compiler default output file name... " >&6; }
3303 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3304
3305 # The possible output files:
3306 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3307
3308 ac_rmfiles=
3309 for ac_file in $ac_files
3310 do
3311   case $ac_file in
3312     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3313     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3314   esac
3315 done
3316 rm -f $ac_rmfiles
3317
3318 if { (ac_try="$ac_link_default"
3319 case "(($ac_try" in
3320   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3321   *) ac_try_echo=$ac_try;;
3322 esac
3323 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3324 $as_echo "$ac_try_echo") >&5
3325   (eval "$ac_link_default") 2>&5
3326   ac_status=$?
3327   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3328   (exit $ac_status); }; then
3329   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3330 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3331 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
3332 # so that the user can short-circuit this test for compilers unknown to
3333 # Autoconf.
3334 for ac_file in $ac_files ''
3335 do
3336   test -f "$ac_file" || continue
3337   case $ac_file in
3338     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3339         ;;
3340     [ab].out )
3341         # We found the default executable, but exeext='' is most
3342         # certainly right.
3343         break;;
3344     *.* )
3345         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3346         then :; else
3347            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3348         fi
3349         # We set ac_cv_exeext here because the later test for it is not
3350         # safe: cross compilers may not add the suffix if given an `-o'
3351         # argument, so we may need to know it at that point already.
3352         # Even if this section looks crufty: it has the advantage of
3353         # actually working.
3354         break;;
3355     * )
3356         break;;
3357   esac
3358 done
3359 test "$ac_cv_exeext" = no && ac_cv_exeext=
3360
3361 else
3362   ac_file=''
3363 fi
3364
3365 { $as_echo "$as_me:$LINENO: result: $ac_file" >&5
3366 $as_echo "$ac_file" >&6; }
3367 if test -z "$ac_file"; then
3368   $as_echo "$as_me: failed program was:" >&5
3369 sed 's/^/| /' conftest.$ac_ext >&5
3370
3371 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3372 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3373 { { $as_echo "$as_me:$LINENO: error: C compiler cannot create executables
3374 See \`config.log' for more details." >&5
3375 $as_echo "$as_me: error: C compiler cannot create executables
3376 See \`config.log' for more details." >&2;}
3377    { (exit 77); exit 77; }; }; }
3378 fi
3379
3380 ac_exeext=$ac_cv_exeext
3381
3382 # Check that the compiler produces executables we can run.  If not, either
3383 # the compiler is broken, or we cross compile.
3384 { $as_echo "$as_me:$LINENO: checking whether the C compiler works" >&5
3385 $as_echo_n "checking whether the C compiler works... " >&6; }
3386 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3387 # If not cross compiling, check that we can run a simple program.
3388 if test "$cross_compiling" != yes; then
3389   if { ac_try='./$ac_file'
3390   { (case "(($ac_try" in
3391   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3392   *) ac_try_echo=$ac_try;;
3393 esac
3394 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3395 $as_echo "$ac_try_echo") >&5
3396   (eval "$ac_try") 2>&5
3397   ac_status=$?
3398   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3399   (exit $ac_status); }; }; then
3400     cross_compiling=no
3401   else
3402     if test "$cross_compiling" = maybe; then
3403         cross_compiling=yes
3404     else
3405         { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3406 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3407 { { $as_echo "$as_me:$LINENO: error: cannot run C compiled programs.
3408 If you meant to cross compile, use \`--host'.
3409 See \`config.log' for more details." >&5
3410 $as_echo "$as_me: error: cannot run C compiled programs.
3411 If you meant to cross compile, use \`--host'.
3412 See \`config.log' for more details." >&2;}
3413    { (exit 1); exit 1; }; }; }
3414     fi
3415   fi
3416 fi
3417 { $as_echo "$as_me:$LINENO: result: yes" >&5
3418 $as_echo "yes" >&6; }
3419
3420 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3421 ac_clean_files=$ac_clean_files_save
3422 # Check that the compiler produces executables we can run.  If not, either
3423 # the compiler is broken, or we cross compile.
3424 { $as_echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
3425 $as_echo_n "checking whether we are cross compiling... " >&6; }
3426 { $as_echo "$as_me:$LINENO: result: $cross_compiling" >&5
3427 $as_echo "$cross_compiling" >&6; }
3428
3429 { $as_echo "$as_me:$LINENO: checking for suffix of executables" >&5
3430 $as_echo_n "checking for suffix of executables... " >&6; }
3431 if { (ac_try="$ac_link"
3432 case "(($ac_try" in
3433   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3434   *) ac_try_echo=$ac_try;;
3435 esac
3436 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3437 $as_echo "$ac_try_echo") >&5
3438   (eval "$ac_link") 2>&5
3439   ac_status=$?
3440   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3441   (exit $ac_status); }; then
3442   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3443 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3444 # work properly (i.e., refer to `conftest.exe'), while it won't with
3445 # `rm'.
3446 for ac_file in conftest.exe conftest conftest.*; do
3447   test -f "$ac_file" || continue
3448   case $ac_file in
3449     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3450     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3451           break;;
3452     * ) break;;
3453   esac
3454 done
3455 else
3456   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3457 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3458 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3459 See \`config.log' for more details." >&5
3460 $as_echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3461 See \`config.log' for more details." >&2;}
3462    { (exit 1); exit 1; }; }; }
3463 fi
3464
3465 rm -f conftest$ac_cv_exeext
3466 { $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
3467 $as_echo "$ac_cv_exeext" >&6; }
3468
3469 rm -f conftest.$ac_ext
3470 EXEEXT=$ac_cv_exeext
3471 ac_exeext=$EXEEXT
3472 { $as_echo "$as_me:$LINENO: checking for suffix of object files" >&5
3473 $as_echo_n "checking for suffix of object files... " >&6; }
3474 if test "${ac_cv_objext+set}" = set; then
3475   $as_echo_n "(cached) " >&6
3476 else
3477   cat >conftest.$ac_ext <<_ACEOF
3478 /* confdefs.h.  */
3479 _ACEOF
3480 cat confdefs.h >>conftest.$ac_ext
3481 cat >>conftest.$ac_ext <<_ACEOF
3482 /* end confdefs.h.  */
3483
3484 int
3485 main ()
3486 {
3487
3488   ;
3489   return 0;
3490 }
3491 _ACEOF
3492 rm -f conftest.o conftest.obj
3493 if { (ac_try="$ac_compile"
3494 case "(($ac_try" in
3495   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3496   *) ac_try_echo=$ac_try;;
3497 esac
3498 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3499 $as_echo "$ac_try_echo") >&5
3500   (eval "$ac_compile") 2>&5
3501   ac_status=$?
3502   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3503   (exit $ac_status); }; then
3504   for ac_file in conftest.o conftest.obj conftest.*; do
3505   test -f "$ac_file" || continue;
3506   case $ac_file in
3507     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3508     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3509        break;;
3510   esac
3511 done
3512 else
3513   $as_echo "$as_me: failed program was:" >&5
3514 sed 's/^/| /' conftest.$ac_ext >&5
3515
3516 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3517 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3518 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3519 See \`config.log' for more details." >&5
3520 $as_echo "$as_me: error: cannot compute suffix of object files: cannot compile
3521 See \`config.log' for more details." >&2;}
3522    { (exit 1); exit 1; }; }; }
3523 fi
3524
3525 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3526 fi
3527 { $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
3528 $as_echo "$ac_cv_objext" >&6; }
3529 OBJEXT=$ac_cv_objext
3530 ac_objext=$OBJEXT
3531 { $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
3532 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3533 if test "${ac_cv_c_compiler_gnu+set}" = set; then
3534   $as_echo_n "(cached) " >&6
3535 else
3536   cat >conftest.$ac_ext <<_ACEOF
3537 /* confdefs.h.  */
3538 _ACEOF
3539 cat confdefs.h >>conftest.$ac_ext
3540 cat >>conftest.$ac_ext <<_ACEOF
3541 /* end confdefs.h.  */
3542
3543 int
3544 main ()
3545 {
3546 #ifndef __GNUC__
3547        choke me
3548 #endif
3549
3550   ;
3551   return 0;
3552 }
3553 _ACEOF
3554 rm -f conftest.$ac_objext
3555 if { (ac_try="$ac_compile"
3556 case "(($ac_try" in
3557   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3558   *) ac_try_echo=$ac_try;;
3559 esac
3560 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3561 $as_echo "$ac_try_echo") >&5
3562   (eval "$ac_compile") 2>conftest.er1
3563   ac_status=$?
3564   grep -v '^ *+' conftest.er1 >conftest.err
3565   rm -f conftest.er1
3566   cat conftest.err >&5
3567   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3568   (exit $ac_status); } && {
3569          test -z "$ac_c_werror_flag" ||
3570          test ! -s conftest.err
3571        } && test -s conftest.$ac_objext; then
3572   ac_compiler_gnu=yes
3573 else
3574   $as_echo "$as_me: failed program was:" >&5
3575 sed 's/^/| /' conftest.$ac_ext >&5
3576
3577         ac_compiler_gnu=no
3578 fi
3579
3580 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3581 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3582
3583 fi
3584 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
3585 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3586 if test $ac_compiler_gnu = yes; then
3587   GCC=yes
3588 else
3589   GCC=
3590 fi
3591 ac_test_CFLAGS=${CFLAGS+set}
3592 ac_save_CFLAGS=$CFLAGS
3593 { $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
3594 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3595 if test "${ac_cv_prog_cc_g+set}" = set; then
3596   $as_echo_n "(cached) " >&6
3597 else
3598   ac_save_c_werror_flag=$ac_c_werror_flag
3599    ac_c_werror_flag=yes
3600    ac_cv_prog_cc_g=no
3601    CFLAGS="-g"
3602    cat >conftest.$ac_ext <<_ACEOF
3603 /* confdefs.h.  */
3604 _ACEOF
3605 cat confdefs.h >>conftest.$ac_ext
3606 cat >>conftest.$ac_ext <<_ACEOF
3607 /* end confdefs.h.  */
3608
3609 int
3610 main ()
3611 {
3612
3613   ;
3614   return 0;
3615 }
3616 _ACEOF
3617 rm -f conftest.$ac_objext
3618 if { (ac_try="$ac_compile"
3619 case "(($ac_try" in
3620   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3621   *) ac_try_echo=$ac_try;;
3622 esac
3623 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3624 $as_echo "$ac_try_echo") >&5
3625   (eval "$ac_compile") 2>conftest.er1
3626   ac_status=$?
3627   grep -v '^ *+' conftest.er1 >conftest.err
3628   rm -f conftest.er1
3629   cat conftest.err >&5
3630   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3631   (exit $ac_status); } && {
3632          test -z "$ac_c_werror_flag" ||
3633          test ! -s conftest.err
3634        } && test -s conftest.$ac_objext; then
3635   ac_cv_prog_cc_g=yes
3636 else
3637   $as_echo "$as_me: failed program was:" >&5
3638 sed 's/^/| /' conftest.$ac_ext >&5
3639
3640         CFLAGS=""
3641       cat >conftest.$ac_ext <<_ACEOF
3642 /* confdefs.h.  */
3643 _ACEOF
3644 cat confdefs.h >>conftest.$ac_ext
3645 cat >>conftest.$ac_ext <<_ACEOF
3646 /* end confdefs.h.  */
3647
3648 int
3649 main ()
3650 {
3651
3652   ;
3653   return 0;
3654 }
3655 _ACEOF
3656 rm -f conftest.$ac_objext
3657 if { (ac_try="$ac_compile"
3658 case "(($ac_try" in
3659   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3660   *) ac_try_echo=$ac_try;;
3661 esac
3662 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3663 $as_echo "$ac_try_echo") >&5
3664   (eval "$ac_compile") 2>conftest.er1
3665   ac_status=$?
3666   grep -v '^ *+' conftest.er1 >conftest.err
3667   rm -f conftest.er1
3668   cat conftest.err >&5
3669   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3670   (exit $ac_status); } && {
3671          test -z "$ac_c_werror_flag" ||
3672          test ! -s conftest.err
3673        } && test -s conftest.$ac_objext; then
3674   :
3675 else
3676   $as_echo "$as_me: failed program was:" >&5
3677 sed 's/^/| /' conftest.$ac_ext >&5
3678
3679         ac_c_werror_flag=$ac_save_c_werror_flag
3680          CFLAGS="-g"
3681          cat >conftest.$ac_ext <<_ACEOF
3682 /* confdefs.h.  */
3683 _ACEOF
3684 cat confdefs.h >>conftest.$ac_ext
3685 cat >>conftest.$ac_ext <<_ACEOF
3686 /* end confdefs.h.  */
3687
3688 int
3689 main ()
3690 {
3691
3692   ;
3693   return 0;
3694 }
3695 _ACEOF
3696 rm -f conftest.$ac_objext
3697 if { (ac_try="$ac_compile"
3698 case "(($ac_try" in
3699   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3700   *) ac_try_echo=$ac_try;;
3701 esac
3702 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3703 $as_echo "$ac_try_echo") >&5
3704   (eval "$ac_compile") 2>conftest.er1
3705   ac_status=$?
3706   grep -v '^ *+' conftest.er1 >conftest.err
3707   rm -f conftest.er1
3708   cat conftest.err >&5
3709   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3710   (exit $ac_status); } && {
3711          test -z "$ac_c_werror_flag" ||
3712          test ! -s conftest.err
3713        } && test -s conftest.$ac_objext; then
3714   ac_cv_prog_cc_g=yes
3715 else
3716   $as_echo "$as_me: failed program was:" >&5
3717 sed 's/^/| /' conftest.$ac_ext >&5
3718
3719
3720 fi
3721
3722 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3723 fi
3724
3725 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3726 fi
3727
3728 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3729    ac_c_werror_flag=$ac_save_c_werror_flag
3730 fi
3731 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
3732 $as_echo "$ac_cv_prog_cc_g" >&6; }
3733 if test "$ac_test_CFLAGS" = set; then
3734   CFLAGS=$ac_save_CFLAGS
3735 elif test $ac_cv_prog_cc_g = yes; then
3736   if test "$GCC" = yes; then
3737     CFLAGS="-g -O2"
3738   else
3739     CFLAGS="-g"
3740   fi
3741 else
3742   if test "$GCC" = yes; then
3743     CFLAGS="-O2"
3744   else
3745     CFLAGS=
3746   fi
3747 fi
3748 { $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
3749 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3750 if test "${ac_cv_prog_cc_c89+set}" = set; then
3751   $as_echo_n "(cached) " >&6
3752 else
3753   ac_cv_prog_cc_c89=no
3754 ac_save_CC=$CC
3755 cat >conftest.$ac_ext <<_ACEOF
3756 /* confdefs.h.  */
3757 _ACEOF
3758 cat confdefs.h >>conftest.$ac_ext
3759 cat >>conftest.$ac_ext <<_ACEOF
3760 /* end confdefs.h.  */
3761 #include <stdarg.h>
3762 #include <stdio.h>
3763 #include <sys/types.h>
3764 #include <sys/stat.h>
3765 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3766 struct buf { int x; };
3767 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3768 static char *e (p, i)
3769      char **p;
3770      int i;
3771 {
3772   return p[i];
3773 }
3774 static char *f (char * (*g) (char **, int), char **p, ...)
3775 {
3776   char *s;
3777   va_list v;
3778   va_start (v,p);
3779   s = g (p, va_arg (v,int));
3780   va_end (v);
3781   return s;
3782 }
3783
3784 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3785    function prototypes and stuff, but not '\xHH' hex character constants.
3786    These don't provoke an error unfortunately, instead are silently treated
3787    as 'x'.  The following induces an error, until -std is added to get
3788    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3789    array size at least.  It's necessary to write '\x00'==0 to get something
3790    that's true only with -std.  */
3791 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3792
3793 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3794    inside strings and character constants.  */
3795 #define FOO(x) 'x'
3796 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3797
3798 int test (int i, double x);
3799 struct s1 {int (*f) (int a);};
3800 struct s2 {int (*f) (double a);};
3801 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3802 int argc;
3803 char **argv;
3804 int
3805 main ()
3806 {
3807 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3808   ;
3809   return 0;
3810 }
3811 _ACEOF
3812 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3813         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3814 do
3815   CC="$ac_save_CC $ac_arg"
3816   rm -f conftest.$ac_objext
3817 if { (ac_try="$ac_compile"
3818 case "(($ac_try" in
3819   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3820   *) ac_try_echo=$ac_try;;
3821 esac
3822 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3823 $as_echo "$ac_try_echo") >&5
3824   (eval "$ac_compile") 2>conftest.er1
3825   ac_status=$?
3826   grep -v '^ *+' conftest.er1 >conftest.err
3827   rm -f conftest.er1
3828   cat conftest.err >&5
3829   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3830   (exit $ac_status); } && {
3831          test -z "$ac_c_werror_flag" ||
3832          test ! -s conftest.err
3833        } && test -s conftest.$ac_objext; then
3834   ac_cv_prog_cc_c89=$ac_arg
3835 else
3836   $as_echo "$as_me: failed program was:" >&5
3837 sed 's/^/| /' conftest.$ac_ext >&5
3838
3839
3840 fi
3841
3842 rm -f core conftest.err conftest.$ac_objext
3843   test "x$ac_cv_prog_cc_c89" != "xno" && break
3844 done
3845 rm -f conftest.$ac_ext
3846 CC=$ac_save_CC
3847
3848 fi
3849 # AC_CACHE_VAL
3850 case "x$ac_cv_prog_cc_c89" in
3851   x)
3852     { $as_echo "$as_me:$LINENO: result: none needed" >&5
3853 $as_echo "none needed" >&6; } ;;
3854   xno)
3855     { $as_echo "$as_me:$LINENO: result: unsupported" >&5
3856 $as_echo "unsupported" >&6; } ;;
3857   *)
3858     CC="$CC $ac_cv_prog_cc_c89"
3859     { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
3860 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3861 esac
3862
3863
3864 ac_ext=c
3865 ac_cpp='$CPP $CPPFLAGS'
3866 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3867 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3868 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3869
3870
3871 # Check if it's Intel's compiler, which (usually) pretends to be gcc,
3872 # but has idiosyncrasies of its own.  We assume icc will define
3873 # __INTEL_COMPILER regardless of CFLAGS.
3874
3875 cat >conftest.$ac_ext <<_ACEOF
3876 /* confdefs.h.  */
3877 _ACEOF
3878 cat confdefs.h >>conftest.$ac_ext
3879 cat >>conftest.$ac_ext <<_ACEOF
3880 /* end confdefs.h.  */
3881
3882 int
3883 main ()
3884 {
3885 #ifndef __INTEL_COMPILER
3886 choke me
3887 #endif
3888   ;
3889   return 0;
3890 }
3891 _ACEOF
3892 rm -f conftest.$ac_objext
3893 if { (ac_try="$ac_compile"
3894 case "(($ac_try" in
3895   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3896   *) ac_try_echo=$ac_try;;
3897 esac
3898 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3899 $as_echo "$ac_try_echo") >&5
3900   (eval "$ac_compile") 2>conftest.er1
3901   ac_status=$?
3902   grep -v '^ *+' conftest.er1 >conftest.err
3903   rm -f conftest.er1
3904   cat conftest.err >&5
3905   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3906   (exit $ac_status); } && {
3907          test -z "$ac_c_werror_flag" ||
3908          test ! -s conftest.err
3909        } && test -s conftest.$ac_objext; then
3910   ICC=yes
3911 else
3912   $as_echo "$as_me: failed program was:" >&5
3913 sed 's/^/| /' conftest.$ac_ext >&5
3914
3915         ICC=no
3916 fi
3917
3918 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3919
3920 # Check if it's Sun Studio compiler. We assume that
3921 # __SUNPRO_C will be defined for Sun Studio compilers
3922 cat >conftest.$ac_ext <<_ACEOF
3923 /* confdefs.h.  */
3924 _ACEOF
3925 cat confdefs.h >>conftest.$ac_ext
3926 cat >>conftest.$ac_ext <<_ACEOF
3927 /* end confdefs.h.  */
3928
3929 int
3930 main ()
3931 {
3932 #ifndef __SUNPRO_C
3933 choke me
3934 #endif
3935   ;
3936   return 0;
3937 }
3938 _ACEOF
3939 rm -f conftest.$ac_objext
3940 if { (ac_try="$ac_compile"
3941 case "(($ac_try" in
3942   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3943   *) ac_try_echo=$ac_try;;
3944 esac
3945 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3946 $as_echo "$ac_try_echo") >&5
3947   (eval "$ac_compile") 2>conftest.er1
3948   ac_status=$?
3949   grep -v '^ *+' conftest.er1 >conftest.err
3950   rm -f conftest.er1
3951   cat conftest.err >&5
3952   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3953   (exit $ac_status); } && {
3954          test -z "$ac_c_werror_flag" ||
3955          test ! -s conftest.err
3956        } && test -s conftest.$ac_objext; then
3957   SUN_STUDIO_CC=yes
3958 else
3959   $as_echo "$as_me: failed program was:" >&5
3960 sed 's/^/| /' conftest.$ac_ext >&5
3961
3962         SUN_STUDIO_CC=no
3963 fi
3964
3965 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3966
3967
3968
3969 unset CFLAGS
3970
3971 #
3972 # Read the template
3973 #
3974 . "$srcdir/src/template/$template" || exit
3975
3976 # CFLAGS are selected so:
3977 # If the user specifies something in the environment, that is used.
3978 # else:  If the template file set something, that is used.
3979 # else:  If coverage was enabled, don't set anything.
3980 # else:  If the compiler is GCC, then we use -O2.
3981 # else:  If the compiler is something else, then we use -O, unless debugging.
3982
3983 if test "$ac_env_CFLAGS_set" = set; then
3984   CFLAGS=$ac_env_CFLAGS_value
3985 elif test "${CFLAGS+set}" = set; then
3986   : # (keep what template set)
3987 elif test "$enable_coverage" = yes; then
3988   : # no optimization by default
3989 elif test "$GCC" = yes; then
3990   CFLAGS="-O2"
3991 else
3992   # if the user selected debug mode, don't use -O
3993   if test "$enable_debug" != yes; then
3994     CFLAGS="-O"
3995   fi
3996 fi
3997
3998 # Some versions of GCC support some additional useful warning flags.
3999 # Check whether they are supported, and add them to CFLAGS if so.
4000 # ICC pretends to be GCC but it's lying; it doesn't support these flags,
4001 # but has its own.  Also check other compiler-specific flags here.
4002
4003 if test "$GCC" = yes -a "$ICC" = no; then
4004   CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith"
4005   # These work in some but not all gcc versions
4006   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wdeclaration-after-statement" >&5
4007 $as_echo_n "checking whether $CC supports -Wdeclaration-after-statement... " >&6; }
4008 if test "${pgac_cv_prog_cc_cflags__Wdeclaration_after_statement+set}" = set; then
4009   $as_echo_n "(cached) " >&6
4010 else
4011   pgac_save_CFLAGS=$CFLAGS
4012 CFLAGS="$pgac_save_CFLAGS -Wdeclaration-after-statement"
4013 cat >conftest.$ac_ext <<_ACEOF
4014 /* confdefs.h.  */
4015 _ACEOF
4016 cat confdefs.h >>conftest.$ac_ext
4017 cat >>conftest.$ac_ext <<_ACEOF
4018 /* end confdefs.h.  */
4019
4020 int
4021 main ()
4022 {
4023
4024   ;
4025   return 0;
4026 }
4027 _ACEOF
4028 rm -f conftest.$ac_objext
4029 if { (ac_try="$ac_compile"
4030 case "(($ac_try" in
4031   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4032   *) ac_try_echo=$ac_try;;
4033 esac
4034 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4035 $as_echo "$ac_try_echo") >&5
4036   (eval "$ac_compile") 2>conftest.er1
4037   ac_status=$?
4038   grep -v '^ *+' conftest.er1 >conftest.err
4039   rm -f conftest.er1
4040   cat conftest.err >&5
4041   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4042   (exit $ac_status); } && {
4043          test -z "$ac_c_werror_flag" ||
4044          test ! -s conftest.err
4045        } && test -s conftest.$ac_objext; then
4046   pgac_cv_prog_cc_cflags__Wdeclaration_after_statement=yes
4047 else
4048   $as_echo "$as_me: failed program was:" >&5
4049 sed 's/^/| /' conftest.$ac_ext >&5
4050
4051         pgac_cv_prog_cc_cflags__Wdeclaration_after_statement=no
4052 fi
4053
4054 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4055 CFLAGS="$pgac_save_CFLAGS"
4056 fi
4057 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" >&5
4058 $as_echo "$pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" >&6; }
4059 if test x"$pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" = x"yes"; then
4060   CFLAGS="$CFLAGS -Wdeclaration-after-statement"
4061 fi
4062
4063   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wendif-labels" >&5
4064 $as_echo_n "checking whether $CC supports -Wendif-labels... " >&6; }
4065 if test "${pgac_cv_prog_cc_cflags__Wendif_labels+set}" = set; then
4066   $as_echo_n "(cached) " >&6
4067 else
4068   pgac_save_CFLAGS=$CFLAGS
4069 CFLAGS="$pgac_save_CFLAGS -Wendif-labels"
4070 cat >conftest.$ac_ext <<_ACEOF
4071 /* confdefs.h.  */
4072 _ACEOF
4073 cat confdefs.h >>conftest.$ac_ext
4074 cat >>conftest.$ac_ext <<_ACEOF
4075 /* end confdefs.h.  */
4076
4077 int
4078 main ()
4079 {
4080
4081   ;
4082   return 0;
4083 }
4084 _ACEOF
4085 rm -f conftest.$ac_objext
4086 if { (ac_try="$ac_compile"
4087 case "(($ac_try" in
4088   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4089   *) ac_try_echo=$ac_try;;
4090 esac
4091 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4092 $as_echo "$ac_try_echo") >&5
4093   (eval "$ac_compile") 2>conftest.er1
4094   ac_status=$?
4095   grep -v '^ *+' conftest.er1 >conftest.err
4096   rm -f conftest.er1
4097   cat conftest.err >&5
4098   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4099   (exit $ac_status); } && {
4100          test -z "$ac_c_werror_flag" ||
4101          test ! -s conftest.err
4102        } && test -s conftest.$ac_objext; then
4103   pgac_cv_prog_cc_cflags__Wendif_labels=yes
4104 else
4105   $as_echo "$as_me: failed program was:" >&5
4106 sed 's/^/| /' conftest.$ac_ext >&5
4107
4108         pgac_cv_prog_cc_cflags__Wendif_labels=no
4109 fi
4110
4111 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4112 CFLAGS="$pgac_save_CFLAGS"
4113 fi
4114 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wendif_labels" >&5
4115 $as_echo "$pgac_cv_prog_cc_cflags__Wendif_labels" >&6; }
4116 if test x"$pgac_cv_prog_cc_cflags__Wendif_labels" = x"yes"; then
4117   CFLAGS="$CFLAGS -Wendif-labels"
4118 fi
4119
4120   # Disable strict-aliasing rules; needed for gcc 3.3+
4121   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fno-strict-aliasing" >&5
4122 $as_echo_n "checking whether $CC supports -fno-strict-aliasing... " >&6; }
4123 if test "${pgac_cv_prog_cc_cflags__fno_strict_aliasing+set}" = set; then
4124   $as_echo_n "(cached) " >&6
4125 else
4126   pgac_save_CFLAGS=$CFLAGS
4127 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
4128 cat >conftest.$ac_ext <<_ACEOF
4129 /* confdefs.h.  */
4130 _ACEOF
4131 cat confdefs.h >>conftest.$ac_ext
4132 cat >>conftest.$ac_ext <<_ACEOF
4133 /* end confdefs.h.  */
4134
4135 int
4136 main ()
4137 {
4138
4139   ;
4140   return 0;
4141 }
4142 _ACEOF
4143 rm -f conftest.$ac_objext
4144 if { (ac_try="$ac_compile"
4145 case "(($ac_try" in
4146   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4147   *) ac_try_echo=$ac_try;;
4148 esac
4149 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4150 $as_echo "$ac_try_echo") >&5
4151   (eval "$ac_compile") 2>conftest.er1
4152   ac_status=$?
4153   grep -v '^ *+' conftest.er1 >conftest.err
4154   rm -f conftest.er1
4155   cat conftest.err >&5
4156   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4157   (exit $ac_status); } && {
4158          test -z "$ac_c_werror_flag" ||
4159          test ! -s conftest.err
4160        } && test -s conftest.$ac_objext; then
4161   pgac_cv_prog_cc_cflags__fno_strict_aliasing=yes
4162 else
4163   $as_echo "$as_me: failed program was:" >&5
4164 sed 's/^/| /' conftest.$ac_ext >&5
4165
4166         pgac_cv_prog_cc_cflags__fno_strict_aliasing=no
4167 fi
4168
4169 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4170 CFLAGS="$pgac_save_CFLAGS"
4171 fi
4172 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&5
4173 $as_echo "$pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&6; }
4174 if test x"$pgac_cv_prog_cc_cflags__fno_strict_aliasing" = x"yes"; then
4175   CFLAGS="$CFLAGS -fno-strict-aliasing"
4176 fi
4177
4178   # Disable optimizations that assume no overflow; needed for gcc 4.3+
4179   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fwrapv" >&5
4180 $as_echo_n "checking whether $CC supports -fwrapv... " >&6; }
4181 if test "${pgac_cv_prog_cc_cflags__fwrapv+set}" = set; then
4182   $as_echo_n "(cached) " >&6
4183 else
4184   pgac_save_CFLAGS=$CFLAGS
4185 CFLAGS="$pgac_save_CFLAGS -fwrapv"
4186 cat >conftest.$ac_ext <<_ACEOF
4187 /* confdefs.h.  */
4188 _ACEOF
4189 cat confdefs.h >>conftest.$ac_ext
4190 cat >>conftest.$ac_ext <<_ACEOF
4191 /* end confdefs.h.  */
4192
4193 int
4194 main ()
4195 {
4196
4197   ;
4198   return 0;
4199 }
4200 _ACEOF
4201 rm -f conftest.$ac_objext
4202 if { (ac_try="$ac_compile"
4203 case "(($ac_try" in
4204   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4205   *) ac_try_echo=$ac_try;;
4206 esac
4207 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4208 $as_echo "$ac_try_echo") >&5
4209   (eval "$ac_compile") 2>conftest.er1
4210   ac_status=$?
4211   grep -v '^ *+' conftest.er1 >conftest.err
4212   rm -f conftest.er1
4213   cat conftest.err >&5
4214   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4215   (exit $ac_status); } && {
4216          test -z "$ac_c_werror_flag" ||
4217          test ! -s conftest.err
4218        } && test -s conftest.$ac_objext; then
4219   pgac_cv_prog_cc_cflags__fwrapv=yes
4220 else
4221   $as_echo "$as_me: failed program was:" >&5
4222 sed 's/^/| /' conftest.$ac_ext >&5
4223
4224         pgac_cv_prog_cc_cflags__fwrapv=no
4225 fi
4226
4227 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4228 CFLAGS="$pgac_save_CFLAGS"
4229 fi
4230 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fwrapv" >&5
4231 $as_echo "$pgac_cv_prog_cc_cflags__fwrapv" >&6; }
4232 if test x"$pgac_cv_prog_cc_cflags__fwrapv" = x"yes"; then
4233   CFLAGS="$CFLAGS -fwrapv"
4234 fi
4235
4236 elif test "$ICC" = yes; then
4237   # Intel's compiler has a bug/misoptimization in checking for
4238   # division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS.
4239   { $as_echo "$as_me:$LINENO: checking whether $CC supports -mp1" >&5
4240 $as_echo_n "checking whether $CC supports -mp1... " >&6; }
4241 if test "${pgac_cv_prog_cc_cflags__mp1+set}" = set; then
4242   $as_echo_n "(cached) " >&6
4243 else
4244   pgac_save_CFLAGS=$CFLAGS
4245 CFLAGS="$pgac_save_CFLAGS -mp1"
4246 cat >conftest.$ac_ext <<_ACEOF
4247 /* confdefs.h.  */
4248 _ACEOF
4249 cat confdefs.h >>conftest.$ac_ext
4250 cat >>conftest.$ac_ext <<_ACEOF
4251 /* end confdefs.h.  */
4252
4253 int
4254 main ()
4255 {
4256
4257   ;
4258   return 0;
4259 }
4260 _ACEOF
4261 rm -f conftest.$ac_objext
4262 if { (ac_try="$ac_compile"
4263 case "(($ac_try" in
4264   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4265   *) ac_try_echo=$ac_try;;
4266 esac
4267 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4268 $as_echo "$ac_try_echo") >&5
4269   (eval "$ac_compile") 2>conftest.er1
4270   ac_status=$?
4271   grep -v '^ *+' conftest.er1 >conftest.err
4272   rm -f conftest.er1
4273   cat conftest.err >&5
4274   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4275   (exit $ac_status); } && {
4276          test -z "$ac_c_werror_flag" ||
4277          test ! -s conftest.err
4278        } && test -s conftest.$ac_objext; then
4279   pgac_cv_prog_cc_cflags__mp1=yes
4280 else
4281   $as_echo "$as_me: failed program was:" >&5
4282 sed 's/^/| /' conftest.$ac_ext >&5
4283
4284         pgac_cv_prog_cc_cflags__mp1=no
4285 fi
4286
4287 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4288 CFLAGS="$pgac_save_CFLAGS"
4289 fi
4290 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__mp1" >&5
4291 $as_echo "$pgac_cv_prog_cc_cflags__mp1" >&6; }
4292 if test x"$pgac_cv_prog_cc_cflags__mp1" = x"yes"; then
4293   CFLAGS="$CFLAGS -mp1"
4294 fi
4295
4296   # Make sure strict aliasing is off (though this is said to be the default)
4297   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fno-strict-aliasing" >&5
4298 $as_echo_n "checking whether $CC supports -fno-strict-aliasing... " >&6; }
4299 if test "${pgac_cv_prog_cc_cflags__fno_strict_aliasing+set}" = set; then
4300   $as_echo_n "(cached) " >&6
4301 else
4302   pgac_save_CFLAGS=$CFLAGS
4303 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
4304 cat >conftest.$ac_ext <<_ACEOF
4305 /* confdefs.h.  */
4306 _ACEOF
4307 cat confdefs.h >>conftest.$ac_ext
4308 cat >>conftest.$ac_ext <<_ACEOF
4309 /* end confdefs.h.  */
4310
4311 int
4312 main ()
4313 {
4314
4315   ;
4316   return 0;
4317 }
4318 _ACEOF
4319 rm -f conftest.$ac_objext
4320 if { (ac_try="$ac_compile"
4321 case "(($ac_try" in
4322   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4323   *) ac_try_echo=$ac_try;;
4324 esac
4325 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4326 $as_echo "$ac_try_echo") >&5
4327   (eval "$ac_compile") 2>conftest.er1
4328   ac_status=$?
4329   grep -v '^ *+' conftest.er1 >conftest.err
4330   rm -f conftest.er1
4331   cat conftest.err >&5
4332   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4333   (exit $ac_status); } && {
4334          test -z "$ac_c_werror_flag" ||
4335          test ! -s conftest.err
4336        } && test -s conftest.$ac_objext; then
4337   pgac_cv_prog_cc_cflags__fno_strict_aliasing=yes
4338 else
4339   $as_echo "$as_me: failed program was:" >&5
4340 sed 's/^/| /' conftest.$ac_ext >&5
4341
4342         pgac_cv_prog_cc_cflags__fno_strict_aliasing=no
4343 fi
4344
4345 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4346 CFLAGS="$pgac_save_CFLAGS"
4347 fi
4348 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&5
4349 $as_echo "$pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&6; }
4350 if test x"$pgac_cv_prog_cc_cflags__fno_strict_aliasing" = x"yes"; then
4351   CFLAGS="$CFLAGS -fno-strict-aliasing"
4352 fi
4353
4354 elif test "$PORTNAME" = "aix"; then
4355   # AIX's xlc has to have strict aliasing turned off too
4356   { $as_echo "$as_me:$LINENO: checking whether $CC supports -qnoansialias" >&5
4357 $as_echo_n "checking whether $CC supports -qnoansialias... " >&6; }
4358 if test "${pgac_cv_prog_cc_cflags__qnoansialias+set}" = set; then
4359   $as_echo_n "(cached) " >&6
4360 else
4361   pgac_save_CFLAGS=$CFLAGS
4362 CFLAGS="$pgac_save_CFLAGS -qnoansialias"
4363 cat >conftest.$ac_ext <<_ACEOF
4364 /* confdefs.h.  */
4365 _ACEOF
4366 cat confdefs.h >>conftest.$ac_ext
4367 cat >>conftest.$ac_ext <<_ACEOF
4368 /* end confdefs.h.  */
4369
4370 int
4371 main ()
4372 {
4373
4374   ;
4375   return 0;
4376 }
4377 _ACEOF
4378 rm -f conftest.$ac_objext
4379 if { (ac_try="$ac_compile"
4380 case "(($ac_try" in
4381   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4382   *) ac_try_echo=$ac_try;;
4383 esac
4384 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4385 $as_echo "$ac_try_echo") >&5
4386   (eval "$ac_compile") 2>conftest.er1
4387   ac_status=$?
4388   grep -v '^ *+' conftest.er1 >conftest.err
4389   rm -f conftest.er1
4390   cat conftest.err >&5
4391   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4392   (exit $ac_status); } && {
4393          test -z "$ac_c_werror_flag" ||
4394          test ! -s conftest.err
4395        } && test -s conftest.$ac_objext; then
4396   pgac_cv_prog_cc_cflags__qnoansialias=yes
4397 else
4398   $as_echo "$as_me: failed program was:" >&5
4399 sed 's/^/| /' conftest.$ac_ext >&5
4400
4401         pgac_cv_prog_cc_cflags__qnoansialias=no
4402 fi
4403
4404 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4405 CFLAGS="$pgac_save_CFLAGS"
4406 fi
4407 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__qnoansialias" >&5
4408 $as_echo "$pgac_cv_prog_cc_cflags__qnoansialias" >&6; }
4409 if test x"$pgac_cv_prog_cc_cflags__qnoansialias" = x"yes"; then
4410   CFLAGS="$CFLAGS -qnoansialias"
4411 fi
4412
4413 fi
4414
4415 # supply -g if --enable-debug
4416 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
4417   CFLAGS="$CFLAGS -g"
4418 fi
4419
4420 # enable code coverage if --enable-coverage
4421 if test "$enable_coverage" = yes; then
4422   if test "$GCC" = yes; then
4423     CFLAGS="$CFLAGS -fprofile-arcs -ftest-coverage"
4424   else
4425     { { $as_echo "$as_me:$LINENO: error: --enable-coverage is supported only when using GCC" >&5
4426 $as_echo "$as_me: error: --enable-coverage is supported only when using GCC" >&2;}
4427    { (exit 1); exit 1; }; }
4428   fi
4429 fi
4430
4431 # enable profiling if --enable-profiling
4432 if test "$enable_profiling" = yes && test "$ac_cv_prog_cc_g" = yes; then
4433   if test "$GCC" = yes; then
4434
4435 cat >>confdefs.h <<\_ACEOF
4436 #define PROFILE_PID_DIR 1
4437 _ACEOF
4438
4439     CFLAGS="$CFLAGS -pg $PLATFORM_PROFILE_FLAGS"
4440   else
4441     { { $as_echo "$as_me:$LINENO: error: --enable-profiling is supported only when using GCC" >&5
4442 $as_echo "$as_me: error: --enable-profiling is supported only when using GCC" >&2;}
4443    { (exit 1); exit 1; }; }
4444   fi
4445 fi
4446
4447 # We already have this in Makefile.win32, but configure needs it too
4448 if test "$PORTNAME" = "win32"; then
4449   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
4450 fi
4451
4452 # Check if the compiler still works with the template settings
4453 { $as_echo "$as_me:$LINENO: checking whether the C compiler still works" >&5
4454 $as_echo_n "checking whether the C compiler still works... " >&6; }
4455 cat >conftest.$ac_ext <<_ACEOF
4456 /* confdefs.h.  */
4457 _ACEOF
4458 cat confdefs.h >>conftest.$ac_ext
4459 cat >>conftest.$ac_ext <<_ACEOF
4460 /* end confdefs.h.  */
4461
4462 int
4463 main ()
4464 {
4465 return 0;
4466   ;
4467   return 0;
4468 }
4469 _ACEOF
4470 rm -f conftest.$ac_objext conftest$ac_exeext
4471 if { (ac_try="$ac_link"
4472 case "(($ac_try" in
4473   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4474   *) ac_try_echo=$ac_try;;
4475 esac
4476 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4477 $as_echo "$ac_try_echo") >&5
4478   (eval "$ac_link") 2>conftest.er1
4479   ac_status=$?
4480   grep -v '^ *+' conftest.er1 >conftest.err
4481   rm -f conftest.er1
4482   cat conftest.err >&5
4483   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4484   (exit $ac_status); } && {
4485          test -z "$ac_c_werror_flag" ||
4486          test ! -s conftest.err
4487        } && test -s conftest$ac_exeext && {
4488          test "$cross_compiling" = yes ||
4489          $as_test_x conftest$ac_exeext
4490        }; then
4491   { $as_echo "$as_me:$LINENO: result: yes" >&5
4492 $as_echo "yes" >&6; }
4493 else
4494   $as_echo "$as_me: failed program was:" >&5
4495 sed 's/^/| /' conftest.$ac_ext >&5
4496
4497         { $as_echo "$as_me:$LINENO: result: no" >&5
4498 $as_echo "no" >&6; }
4499    { { $as_echo "$as_me:$LINENO: error: cannot proceed" >&5
4500 $as_echo "$as_me: error: cannot proceed" >&2;}
4501    { (exit 1); exit 1; }; }
4502 fi
4503
4504 rm -rf conftest.dSYM
4505 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
4506       conftest$ac_exeext conftest.$ac_ext
4507
4508 # Defend against gcc -ffast-math
4509 if test "$GCC" = yes; then
4510 cat >conftest.$ac_ext <<_ACEOF
4511 /* confdefs.h.  */
4512 _ACEOF
4513 cat confdefs.h >>conftest.$ac_ext
4514 cat >>conftest.$ac_ext <<_ACEOF
4515 /* end confdefs.h.  */
4516
4517 int
4518 main ()
4519 {
4520 #ifdef __FAST_MATH__
4521 choke me
4522 #endif
4523   ;
4524   return 0;
4525 }
4526 _ACEOF
4527 rm -f conftest.$ac_objext
4528 if { (ac_try="$ac_compile"
4529 case "(($ac_try" in
4530   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4531   *) ac_try_echo=$ac_try;;
4532 esac
4533 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4534 $as_echo "$ac_try_echo") >&5
4535   (eval "$ac_compile") 2>conftest.er1
4536   ac_status=$?
4537   grep -v '^ *+' conftest.er1 >conftest.err
4538   rm -f conftest.er1
4539   cat conftest.err >&5
4540   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4541   (exit $ac_status); } && {
4542          test -z "$ac_c_werror_flag" ||
4543          test ! -s conftest.err
4544        } && test -s conftest.$ac_objext; then
4545   :
4546 else
4547   $as_echo "$as_me: failed program was:" >&5
4548 sed 's/^/| /' conftest.$ac_ext >&5
4549
4550         { { $as_echo "$as_me:$LINENO: error: do not put -ffast-math in CFLAGS" >&5
4551 $as_echo "$as_me: error: do not put -ffast-math in CFLAGS" >&2;}
4552    { (exit 1); exit 1; }; }
4553 fi
4554
4555 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4556 fi
4557
4558 ac_ext=c
4559 ac_cpp='$CPP $CPPFLAGS'
4560 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4561 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4562 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4563 { $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
4564 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4565 # On Suns, sometimes $CPP names a directory.
4566 if test -n "$CPP" && test -d "$CPP"; then
4567   CPP=
4568 fi
4569 if test -z "$CPP"; then
4570   if test "${ac_cv_prog_CPP+set}" = set; then
4571   $as_echo_n "(cached) " >&6
4572 else
4573       # Double quotes because CPP needs to be expanded
4574     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4575     do
4576       ac_preproc_ok=false
4577 for ac_c_preproc_warn_flag in '' yes
4578 do
4579   # Use a header file that comes with gcc, so configuring glibc
4580   # with a fresh cross-compiler works.
4581   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4582   # <limits.h> exists even on freestanding compilers.
4583   # On the NeXT, cc -E runs the code through the compiler's parser,
4584   # not just through cpp. "Syntax error" is here to catch this case.
4585   cat >conftest.$ac_ext <<_ACEOF
4586 /* confdefs.h.  */
4587 _ACEOF
4588 cat confdefs.h >>conftest.$ac_ext
4589 cat >>conftest.$ac_ext <<_ACEOF
4590 /* end confdefs.h.  */
4591 #ifdef __STDC__
4592 # include <limits.h>
4593 #else
4594 # include <assert.h>
4595 #endif
4596                      Syntax error
4597 _ACEOF
4598 if { (ac_try="$ac_cpp conftest.$ac_ext"
4599 case "(($ac_try" in
4600   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4601   *) ac_try_echo=$ac_try;;
4602 esac
4603 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4604 $as_echo "$ac_try_echo") >&5
4605   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4606   ac_status=$?
4607   grep -v '^ *+' conftest.er1 >conftest.err
4608   rm -f conftest.er1
4609   cat conftest.err >&5
4610   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4611   (exit $ac_status); } >/dev/null && {
4612          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4613          test ! -s conftest.err
4614        }; then
4615   :
4616 else
4617   $as_echo "$as_me: failed program was:" >&5
4618 sed 's/^/| /' conftest.$ac_ext >&5
4619
4620   # Broken: fails on valid input.
4621 continue
4622 fi
4623
4624 rm -f conftest.err conftest.$ac_ext
4625
4626   # OK, works on sane cases.  Now check whether nonexistent headers
4627   # can be detected and how.
4628   cat >conftest.$ac_ext <<_ACEOF
4629 /* confdefs.h.  */
4630 _ACEOF
4631 cat confdefs.h >>conftest.$ac_ext
4632 cat >>conftest.$ac_ext <<_ACEOF
4633 /* end confdefs.h.  */
4634 #include <ac_nonexistent.h>
4635 _ACEOF
4636 if { (ac_try="$ac_cpp conftest.$ac_ext"
4637 case "(($ac_try" in
4638   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4639   *) ac_try_echo=$ac_try;;
4640 esac
4641 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4642 $as_echo "$ac_try_echo") >&5
4643   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4644   ac_status=$?
4645   grep -v '^ *+' conftest.er1 >conftest.err
4646   rm -f conftest.er1
4647   cat conftest.err >&5
4648   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4649   (exit $ac_status); } >/dev/null && {
4650          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4651          test ! -s conftest.err
4652        }; then
4653   # Broken: success on invalid input.
4654 continue
4655 else
4656   $as_echo "$as_me: failed program was:" >&5
4657 sed 's/^/| /' conftest.$ac_ext >&5
4658
4659   # Passes both tests.
4660 ac_preproc_ok=:
4661 break
4662 fi
4663
4664 rm -f conftest.err conftest.$ac_ext
4665
4666 done
4667 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4668 rm -f conftest.err conftest.$ac_ext
4669 if $ac_preproc_ok; then
4670   break
4671 fi
4672
4673     done
4674     ac_cv_prog_CPP=$CPP
4675
4676 fi
4677   CPP=$ac_cv_prog_CPP
4678 else
4679   ac_cv_prog_CPP=$CPP
4680 fi
4681 { $as_echo "$as_me:$LINENO: result: $CPP" >&5
4682 $as_echo "$CPP" >&6; }
4683 ac_preproc_ok=false
4684 for ac_c_preproc_warn_flag in '' yes
4685 do
4686   # Use a header file that comes with gcc, so configuring glibc
4687   # with a fresh cross-compiler works.
4688   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4689   # <limits.h> exists even on freestanding compilers.
4690   # On the NeXT, cc -E runs the code through the compiler's parser,
4691   # not just through cpp. "Syntax error" is here to catch this case.
4692   cat >conftest.$ac_ext <<_ACEOF
4693 /* confdefs.h.  */
4694 _ACEOF
4695 cat confdefs.h >>conftest.$ac_ext
4696 cat >>conftest.$ac_ext <<_ACEOF
4697 /* end confdefs.h.  */
4698 #ifdef __STDC__
4699 # include <limits.h>
4700 #else
4701 # include <assert.h>
4702 #endif
4703                      Syntax error
4704 _ACEOF
4705 if { (ac_try="$ac_cpp conftest.$ac_ext"
4706 case "(($ac_try" in
4707   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4708   *) ac_try_echo=$ac_try;;
4709 esac
4710 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4711 $as_echo "$ac_try_echo") >&5
4712   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4713   ac_status=$?
4714   grep -v '^ *+' conftest.er1 >conftest.err
4715   rm -f conftest.er1
4716   cat conftest.err >&5
4717   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4718   (exit $ac_status); } >/dev/null && {
4719          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4720          test ! -s conftest.err
4721        }; then
4722   :
4723 else
4724   $as_echo "$as_me: failed program was:" >&5
4725 sed 's/^/| /' conftest.$ac_ext >&5
4726
4727   # Broken: fails on valid input.
4728 continue
4729 fi
4730
4731 rm -f conftest.err conftest.$ac_ext
4732
4733   # OK, works on sane cases.  Now check whether nonexistent headers
4734   # can be detected and how.
4735   cat >conftest.$ac_ext <<_ACEOF
4736 /* confdefs.h.  */
4737 _ACEOF
4738 cat confdefs.h >>conftest.$ac_ext
4739 cat >>conftest.$ac_ext <<_ACEOF
4740 /* end confdefs.h.  */
4741 #include <ac_nonexistent.h>
4742 _ACEOF
4743 if { (ac_try="$ac_cpp conftest.$ac_ext"
4744 case "(($ac_try" in
4745   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4746   *) ac_try_echo=$ac_try;;
4747 esac
4748 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4749 $as_echo "$ac_try_echo") >&5
4750   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4751   ac_status=$?
4752   grep -v '^ *+' conftest.er1 >conftest.err
4753   rm -f conftest.er1
4754   cat conftest.err >&5
4755   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4756   (exit $ac_status); } >/dev/null && {
4757          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4758          test ! -s conftest.err
4759        }; then
4760   # Broken: success on invalid input.
4761 continue
4762 else
4763   $as_echo "$as_me: failed program was:" >&5
4764 sed 's/^/| /' conftest.$ac_ext >&5
4765
4766   # Passes both tests.
4767 ac_preproc_ok=:
4768 break
4769 fi
4770
4771 rm -f conftest.err conftest.$ac_ext
4772
4773 done
4774 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4775 rm -f conftest.err conftest.$ac_ext
4776 if $ac_preproc_ok; then
4777   :
4778 else
4779   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
4780 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4781 { { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
4782 See \`config.log' for more details." >&5
4783 $as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
4784 See \`config.log' for more details." >&2;}
4785    { (exit 1); exit 1; }; }; }
4786 fi
4787
4788 ac_ext=c
4789 ac_cpp='$CPP $CPPFLAGS'
4790 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4791 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4792 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4793
4794
4795
4796
4797 #
4798 # Set up TAS assembly code if needed; the template file has now had its
4799 # chance to request this.
4800 #
4801 ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
4802
4803
4804 if test "$need_tas" = yes ; then
4805   TAS=tas.o
4806 else
4807   TAS=""
4808 fi
4809
4810
4811
4812 #
4813 # Automatic dependency tracking
4814 #
4815
4816
4817 # Check whether --enable-depend was given.
4818 if test "${enable_depend+set}" = set; then
4819   enableval=$enable_depend;
4820   case $enableval in
4821     yes)
4822       autodepend=yes
4823       ;;
4824     no)
4825       :
4826       ;;
4827     *)
4828       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-depend option" >&5
4829 $as_echo "$as_me: error: no argument expected for --enable-depend option" >&2;}
4830    { (exit 1); exit 1; }; }
4831       ;;
4832   esac
4833
4834 else
4835   enable_depend=no
4836
4837 fi
4838
4839
4840
4841
4842
4843 #
4844 # Enable assert checks
4845 #
4846
4847
4848 # Check whether --enable-cassert was given.
4849 if test "${enable_cassert+set}" = set; then
4850   enableval=$enable_cassert;
4851   case $enableval in
4852     yes)
4853
4854 cat >>confdefs.h <<\_ACEOF
4855 #define USE_ASSERT_CHECKING 1
4856 _ACEOF
4857
4858       ;;
4859     no)
4860       :
4861       ;;
4862     *)
4863       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-cassert option" >&5
4864 $as_echo "$as_me: error: no argument expected for --enable-cassert option" >&2;}
4865    { (exit 1); exit 1; }; }
4866       ;;
4867   esac
4868
4869 else
4870   enable_cassert=no
4871
4872 fi
4873
4874
4875
4876
4877 #
4878 # Include directories
4879 #
4880 ac_save_IFS=$IFS
4881 IFS="${IFS}${PATH_SEPARATOR}"
4882 # SRCH_INC comes from the template file
4883 for dir in $with_includes $SRCH_INC; do
4884   if test -d "$dir"; then
4885     INCLUDES="$INCLUDES -I$dir"
4886   else
4887     { $as_echo "$as_me:$LINENO: WARNING: *** Include directory $dir does not exist." >&5
4888 $as_echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
4889   fi
4890 done
4891 IFS=$ac_save_IFS
4892
4893
4894
4895 #
4896 # Library directories
4897 #
4898 ac_save_IFS=$IFS
4899 IFS="${IFS}${PATH_SEPARATOR}"
4900 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
4901 for dir in $LIBRARY_DIRS $SRCH_LIB; do
4902   if test -d "$dir"; then
4903     LIBDIRS="$LIBDIRS -L$dir"
4904   else
4905     { $as_echo "$as_me:$LINENO: WARNING: *** Library directory $dir does not exist." >&5
4906 $as_echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
4907   fi
4908 done
4909 IFS=$ac_save_IFS
4910
4911 #
4912 # Enable thread-safe client libraries
4913 #
4914 { $as_echo "$as_me:$LINENO: checking allow thread-safe client libraries" >&5
4915 $as_echo_n "checking allow thread-safe client libraries... " >&6; }
4916
4917
4918 # Check whether --enable-thread-safety was given.
4919 if test "${enable_thread_safety+set}" = set; then
4920   enableval=$enable_thread_safety;
4921   case $enableval in
4922     yes)
4923       :
4924       ;;
4925     no)
4926       :
4927       ;;
4928     *)
4929       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
4930 $as_echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
4931    { (exit 1); exit 1; }; }
4932       ;;
4933   esac
4934
4935 else
4936   enable_thread_safety=yes
4937
4938 fi
4939
4940
4941 if test "$enable_thread_safety" = yes; then
4942
4943 cat >>confdefs.h <<\_ACEOF
4944 #define ENABLE_THREAD_SAFETY 1
4945 _ACEOF
4946
4947 fi
4948 { $as_echo "$as_me:$LINENO: result: $enable_thread_safety" >&5
4949 $as_echo "$enable_thread_safety" >&6; }
4950
4951
4952 #
4953 # Optionally build Tcl modules (PL/Tcl)
4954 #
4955 { $as_echo "$as_me:$LINENO: checking whether to build with Tcl" >&5
4956 $as_echo_n "checking whether to build with Tcl... " >&6; }
4957
4958
4959
4960 # Check whether --with-tcl was given.
4961 if test "${with_tcl+set}" = set; then
4962   withval=$with_tcl;
4963   case $withval in
4964     yes)
4965       :
4966       ;;
4967     no)
4968       :
4969       ;;
4970     *)
4971       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-tcl option" >&5
4972 $as_echo "$as_me: error: no argument expected for --with-tcl option" >&2;}
4973    { (exit 1); exit 1; }; }
4974       ;;
4975   esac
4976
4977 else
4978   with_tcl=no
4979
4980 fi
4981
4982
4983 { $as_echo "$as_me:$LINENO: result: $with_tcl" >&5
4984 $as_echo "$with_tcl" >&6; }
4985
4986
4987 # We see if the path to the Tcl/Tk configuration scripts is specified.
4988 # This will override the use of tclsh to find the paths to search.
4989
4990
4991
4992
4993 # Check whether --with-tclconfig was given.
4994 if test "${with_tclconfig+set}" = set; then
4995   withval=$with_tclconfig;
4996   case $withval in
4997     yes)
4998       { { $as_echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
4999 $as_echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
5000    { (exit 1); exit 1; }; }
5001       ;;
5002     no)
5003       { { $as_echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
5004 $as_echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
5005    { (exit 1); exit 1; }; }
5006       ;;
5007     *)
5008
5009       ;;
5010   esac
5011
5012 fi
5013
5014
5015
5016 #
5017 # Optionally build Perl modules (PL/Perl)
5018 #
5019 { $as_echo "$as_me:$LINENO: checking whether to build Perl modules" >&5
5020 $as_echo_n "checking whether to build Perl modules... " >&6; }
5021
5022
5023
5024 # Check whether --with-perl was given.
5025 if test "${with_perl+set}" = set; then
5026   withval=$with_perl;
5027   case $withval in
5028     yes)
5029       :
5030       ;;
5031     no)
5032       :
5033       ;;
5034     *)
5035       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-perl option" >&5
5036 $as_echo "$as_me: error: no argument expected for --with-perl option" >&2;}
5037    { (exit 1); exit 1; }; }
5038       ;;
5039   esac
5040
5041 else
5042   with_perl=no
5043
5044 fi
5045
5046
5047 { $as_echo "$as_me:$LINENO: result: $with_perl" >&5
5048 $as_echo "$with_perl" >&6; }
5049
5050
5051 #
5052 # Optionally build Python modules (PL/Python)
5053 #
5054 { $as_echo "$as_me:$LINENO: checking whether to build Python modules" >&5
5055 $as_echo_n "checking whether to build Python modules... " >&6; }
5056
5057
5058
5059 # Check whether --with-python was given.
5060 if test "${with_python+set}" = set; then
5061   withval=$with_python;
5062   case $withval in
5063     yes)
5064       :
5065       ;;
5066     no)
5067       :
5068       ;;
5069     *)
5070       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-python option" >&5
5071 $as_echo "$as_me: error: no argument expected for --with-python option" >&2;}
5072    { (exit 1); exit 1; }; }
5073       ;;
5074   esac
5075
5076 else
5077   with_python=no
5078
5079 fi
5080
5081
5082 { $as_echo "$as_me:$LINENO: result: $with_python" >&5
5083 $as_echo "$with_python" >&6; }
5084
5085
5086 #
5087 # GSSAPI
5088 #
5089 { $as_echo "$as_me:$LINENO: checking whether to build with GSSAPI support" >&5
5090 $as_echo_n "checking whether to build with GSSAPI support... " >&6; }
5091
5092
5093
5094 # Check whether --with-gssapi was given.
5095 if test "${with_gssapi+set}" = set; then
5096   withval=$with_gssapi;
5097   case $withval in
5098     yes)
5099
5100
5101 cat >>confdefs.h <<\_ACEOF
5102 #define ENABLE_GSS 1
5103 _ACEOF
5104
5105   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
5106
5107       ;;
5108     no)
5109       :
5110       ;;
5111     *)
5112       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-gssapi option" >&5
5113 $as_echo "$as_me: error: no argument expected for --with-gssapi option" >&2;}
5114    { (exit 1); exit 1; }; }
5115       ;;
5116   esac
5117
5118 else
5119   with_gssapi=no
5120
5121 fi
5122
5123
5124 { $as_echo "$as_me:$LINENO: result: $with_gssapi" >&5
5125 $as_echo "$with_gssapi" >&6; }
5126
5127
5128 #
5129 # Kerberos 5
5130 #
5131 { $as_echo "$as_me:$LINENO: checking whether to build with Kerberos 5 support" >&5
5132 $as_echo_n "checking whether to build with Kerberos 5 support... " >&6; }
5133
5134
5135
5136 # Check whether --with-krb5 was given.
5137 if test "${with_krb5+set}" = set; then
5138   withval=$with_krb5;
5139   case $withval in
5140     yes)
5141
5142
5143 cat >>confdefs.h <<\_ACEOF
5144 #define KRB5 1
5145 _ACEOF
5146
5147   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
5148
5149       ;;
5150     no)
5151       :
5152       ;;
5153     *)
5154       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-krb5 option" >&5
5155 $as_echo "$as_me: error: no argument expected for --with-krb5 option" >&2;}
5156    { (exit 1); exit 1; }; }
5157       ;;
5158   esac
5159
5160 else
5161   with_krb5=no
5162
5163 fi
5164
5165
5166 { $as_echo "$as_me:$LINENO: result: $with_krb5" >&5
5167 $as_echo "$with_krb5" >&6; }
5168
5169
5170
5171
5172
5173
5174 #
5175 # Kerberos configuration parameters
5176 #
5177
5178
5179
5180 # Check whether --with-krb-srvnam was given.
5181 if test "${with_krb_srvnam+set}" = set; then
5182   withval=$with_krb_srvnam;
5183   case $withval in
5184     yes)
5185       { { $as_echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
5186 $as_echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
5187    { (exit 1); exit 1; }; }
5188       ;;
5189     no)
5190       { { $as_echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
5191 $as_echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
5192    { (exit 1); exit 1; }; }
5193       ;;
5194     *)
5195
5196       ;;
5197   esac
5198
5199 else
5200   with_krb_srvnam="postgres"
5201 fi
5202
5203
5204
5205 cat >>confdefs.h <<_ACEOF
5206 #define PG_KRB_SRVNAM "$with_krb_srvnam"
5207 _ACEOF
5208
5209
5210
5211 #
5212 # PAM
5213 #
5214 { $as_echo "$as_me:$LINENO: checking whether to build with PAM support" >&5
5215 $as_echo_n "checking whether to build with PAM support... " >&6; }
5216
5217
5218
5219 # Check whether --with-pam was given.
5220 if test "${with_pam+set}" = set; then
5221   withval=$with_pam;
5222   case $withval in
5223     yes)
5224
5225 cat >>confdefs.h <<\_ACEOF
5226 #define USE_PAM 1
5227 _ACEOF
5228
5229       ;;
5230     no)
5231       :
5232       ;;
5233     *)
5234       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-pam option" >&5
5235 $as_echo "$as_me: error: no argument expected for --with-pam option" >&2;}
5236    { (exit 1); exit 1; }; }
5237       ;;
5238   esac
5239
5240 else
5241   with_pam=no
5242
5243 fi
5244
5245
5246 { $as_echo "$as_me:$LINENO: result: $with_pam" >&5
5247 $as_echo "$with_pam" >&6; }
5248
5249
5250
5251 #
5252 # LDAP
5253 #
5254 { $as_echo "$as_me:$LINENO: checking whether to build with LDAP support" >&5
5255 $as_echo_n "checking whether to build with LDAP support... " >&6; }
5256
5257
5258
5259 # Check whether --with-ldap was given.
5260 if test "${with_ldap+set}" = set; then
5261   withval=$with_ldap;
5262   case $withval in
5263     yes)
5264
5265 cat >>confdefs.h <<\_ACEOF
5266 #define USE_LDAP 1
5267 _ACEOF
5268
5269       ;;
5270     no)
5271       :
5272       ;;
5273     *)
5274       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-ldap option" >&5
5275 $as_echo "$as_me: error: no argument expected for --with-ldap option" >&2;}
5276    { (exit 1); exit 1; }; }
5277       ;;
5278   esac
5279
5280 else
5281   with_ldap=no
5282
5283 fi
5284
5285
5286 { $as_echo "$as_me:$LINENO: result: $with_ldap" >&5
5287 $as_echo "$with_ldap" >&6; }
5288
5289
5290
5291 #
5292 # Bonjour
5293 #
5294 { $as_echo "$as_me:$LINENO: checking whether to build with Bonjour support" >&5
5295 $as_echo_n "checking whether to build with Bonjour support... " >&6; }
5296
5297
5298
5299 # Check whether --with-bonjour was given.
5300 if test "${with_bonjour+set}" = set; then
5301   withval=$with_bonjour;
5302   case $withval in
5303     yes)
5304
5305 cat >>confdefs.h <<\_ACEOF
5306 #define USE_BONJOUR 1
5307 _ACEOF
5308
5309       ;;
5310     no)
5311       :
5312       ;;
5313     *)
5314       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-bonjour option" >&5
5315 $as_echo "$as_me: error: no argument expected for --with-bonjour option" >&2;}
5316    { (exit 1); exit 1; }; }
5317       ;;
5318   esac
5319
5320 else
5321   with_bonjour=no
5322
5323 fi
5324
5325
5326 { $as_echo "$as_me:$LINENO: result: $with_bonjour" >&5
5327 $as_echo "$with_bonjour" >&6; }
5328
5329
5330
5331 #
5332 # OpenSSL
5333 #
5334 { $as_echo "$as_me:$LINENO: checking whether to build with OpenSSL support" >&5
5335 $as_echo_n "checking whether to build with OpenSSL support... " >&6; }
5336
5337
5338
5339 # Check whether --with-openssl was given.
5340 if test "${with_openssl+set}" = set; then
5341   withval=$with_openssl;
5342   case $withval in
5343     yes)
5344
5345 cat >>confdefs.h <<\_ACEOF
5346 #define USE_SSL 1
5347 _ACEOF
5348
5349       ;;
5350     no)
5351       :
5352       ;;
5353     *)
5354       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-openssl option" >&5
5355 $as_echo "$as_me: error: no argument expected for --with-openssl option" >&2;}
5356    { (exit 1); exit 1; }; }
5357       ;;
5358   esac
5359
5360 else
5361   with_openssl=no
5362
5363 fi
5364
5365
5366 { $as_echo "$as_me:$LINENO: result: $with_openssl" >&5
5367 $as_echo "$with_openssl" >&6; }
5368
5369
5370 #
5371 # SELinux
5372 #
5373 { $as_echo "$as_me:$LINENO: checking whether to build with SELinux support" >&5
5374 $as_echo_n "checking whether to build with SELinux support... " >&6; }
5375
5376
5377
5378 # Check whether --with-selinux was given.
5379 if test "${with_selinux+set}" = set; then
5380   withval=$with_selinux;
5381   case $withval in
5382     yes)
5383       :
5384       ;;
5385     no)
5386       :
5387       ;;
5388     *)
5389       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-selinux option" >&5
5390 $as_echo "$as_me: error: no argument expected for --with-selinux option" >&2;}
5391    { (exit 1); exit 1; }; }
5392       ;;
5393   esac
5394
5395 else
5396   with_selinux=no
5397
5398 fi
5399
5400
5401
5402 { $as_echo "$as_me:$LINENO: result: $with_selinux" >&5
5403 $as_echo "$with_selinux" >&6; }
5404
5405 #
5406 # Readline
5407 #
5408
5409
5410
5411 # Check whether --with-readline was given.
5412 if test "${with_readline+set}" = set; then
5413   withval=$with_readline;
5414   case $withval in
5415     yes)
5416       :
5417       ;;
5418     no)
5419       :
5420       ;;
5421     *)
5422       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-readline option" >&5
5423 $as_echo "$as_me: error: no argument expected for --with-readline option" >&2;}
5424    { (exit 1); exit 1; }; }
5425       ;;
5426   esac
5427
5428 else
5429   with_readline=yes
5430
5431 fi
5432
5433
5434 # readline on MinGW has problems with backslashes in psql and other bugs.
5435 # This is particularly a problem with non-US code pages.
5436 # Therefore disable its use until we understand the cause. 2004-07-20
5437 if test "$PORTNAME" = "win32"; then
5438   if test "$with_readline" = yes; then
5439     { $as_echo "$as_me:$LINENO: WARNING: *** Readline does not work on MinGW --- disabling" >&5
5440 $as_echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
5441     with_readline=no
5442   fi
5443 fi
5444
5445
5446 #
5447 # Prefer libedit
5448 #
5449
5450
5451
5452 # Check whether --with-libedit-preferred was given.
5453 if test "${with_libedit_preferred+set}" = set; then
5454   withval=$with_libedit_preferred;
5455   case $withval in
5456     yes)
5457       :
5458       ;;
5459     no)
5460       :
5461       ;;
5462     *)
5463       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libedit-preferred option" >&5
5464 $as_echo "$as_me: error: no argument expected for --with-libedit-preferred option" >&2;}
5465    { (exit 1); exit 1; }; }
5466       ;;
5467   esac
5468
5469 else
5470   with_libedit_preferred=no
5471
5472 fi
5473
5474
5475
5476
5477 #
5478 # OSSP UUID library
5479 #
5480
5481
5482
5483 # Check whether --with-ossp-uuid was given.
5484 if test "${with_ossp_uuid+set}" = set; then
5485   withval=$with_ossp_uuid;
5486   case $withval in
5487     yes)
5488       :
5489       ;;
5490     no)
5491       :
5492       ;;
5493     *)
5494       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-ossp-uuid option" >&5
5495 $as_echo "$as_me: error: no argument expected for --with-ossp-uuid option" >&2;}
5496    { (exit 1); exit 1; }; }
5497       ;;
5498   esac
5499
5500 else
5501   with_ossp_uuid=no
5502
5503 fi
5504
5505
5506
5507
5508
5509 #
5510 # XML
5511 #
5512
5513
5514
5515 # Check whether --with-libxml was given.
5516 if test "${with_libxml+set}" = set; then
5517   withval=$with_libxml;
5518   case $withval in
5519     yes)
5520
5521 cat >>confdefs.h <<\_ACEOF
5522 #define USE_LIBXML 1
5523 _ACEOF
5524
5525       ;;
5526     no)
5527       :
5528       ;;
5529     *)
5530       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libxml option" >&5
5531 $as_echo "$as_me: error: no argument expected for --with-libxml option" >&2;}
5532    { (exit 1); exit 1; }; }
5533       ;;
5534   esac
5535
5536 else
5537   with_libxml=no
5538
5539 fi
5540
5541
5542
5543 if test "$with_libxml" = yes ; then
5544   for ac_prog in xml2-config
5545 do
5546   # Extract the first word of "$ac_prog", so it can be a program name with args.
5547 set dummy $ac_prog; ac_word=$2
5548 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5549 $as_echo_n "checking for $ac_word... " >&6; }
5550 if test "${ac_cv_prog_XML2_CONFIG+set}" = set; then
5551   $as_echo_n "(cached) " >&6
5552 else
5553   if test -n "$XML2_CONFIG"; then
5554   ac_cv_prog_XML2_CONFIG="$XML2_CONFIG" # Let the user override the test.
5555 else
5556 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5557 for as_dir in $PATH
5558 do
5559   IFS=$as_save_IFS
5560   test -z "$as_dir" && as_dir=.
5561   for ac_exec_ext in '' $ac_executable_extensions; do
5562   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5563     ac_cv_prog_XML2_CONFIG="$ac_prog"
5564     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5565     break 2
5566   fi
5567 done
5568 done
5569 IFS=$as_save_IFS
5570
5571 fi
5572 fi
5573 XML2_CONFIG=$ac_cv_prog_XML2_CONFIG
5574 if test -n "$XML2_CONFIG"; then
5575   { $as_echo "$as_me:$LINENO: result: $XML2_CONFIG" >&5
5576 $as_echo "$XML2_CONFIG" >&6; }
5577 else
5578   { $as_echo "$as_me:$LINENO: result: no" >&5
5579 $as_echo "no" >&6; }
5580 fi
5581
5582
5583   test -n "$XML2_CONFIG" && break
5584 done
5585
5586   if test -n "$XML2_CONFIG"; then
5587     for pgac_option in `$XML2_CONFIG --cflags`; do
5588       case $pgac_option in
5589         -I*|-D*) CPPFLAGS="$CPPFLAGS $pgac_option";;
5590       esac
5591     done
5592     for pgac_option in `$XML2_CONFIG --libs`; do
5593       case $pgac_option in
5594         -L*) LDFLAGS="$LDFLAGS $pgac_option";;
5595       esac
5596     done
5597   fi
5598 fi
5599
5600
5601
5602 #
5603 # XSLT
5604 #
5605
5606
5607
5608 # Check whether --with-libxslt was given.
5609 if test "${with_libxslt+set}" = set; then
5610   withval=$with_libxslt;
5611   case $withval in
5612     yes)
5613
5614 cat >>confdefs.h <<\_ACEOF
5615 #define USE_LIBXSLT 1
5616 _ACEOF
5617
5618       ;;
5619     no)
5620       :
5621       ;;
5622     *)
5623       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libxslt option" >&5
5624 $as_echo "$as_me: error: no argument expected for --with-libxslt option" >&2;}
5625    { (exit 1); exit 1; }; }
5626       ;;
5627   esac
5628
5629 else
5630   with_libxslt=no
5631
5632 fi
5633
5634
5635
5636
5637
5638
5639 #
5640 # tzdata
5641 #
5642
5643
5644
5645 # Check whether --with-system-tzdata was given.
5646 if test "${with_system_tzdata+set}" = set; then
5647   withval=$with_system_tzdata;
5648   case $withval in
5649     yes)
5650       { { $as_echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5651 $as_echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5652    { (exit 1); exit 1; }; }
5653       ;;
5654     no)
5655       { { $as_echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5656 $as_echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5657    { (exit 1); exit 1; }; }
5658       ;;
5659     *)
5660
5661       ;;
5662   esac
5663
5664 fi
5665
5666
5667
5668
5669 #
5670 # Zlib
5671 #
5672
5673
5674
5675 # Check whether --with-zlib was given.
5676 if test "${with_zlib+set}" = set; then
5677   withval=$with_zlib;
5678   case $withval in
5679     yes)
5680       :
5681       ;;
5682     no)
5683       :
5684       ;;
5685     *)
5686       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-zlib option" >&5
5687 $as_echo "$as_me: error: no argument expected for --with-zlib option" >&2;}
5688    { (exit 1); exit 1; }; }
5689       ;;
5690   esac
5691
5692 else
5693   with_zlib=yes
5694
5695 fi
5696
5697
5698
5699
5700 #
5701 # Elf
5702 #
5703
5704 # Assume system is ELF if it predefines __ELF__ as 1,
5705 # otherwise believe host_os based default.
5706 case $host_os in
5707     freebsd1*|freebsd2*) elf=no;;
5708     freebsd3*|freebsd4*) elf=yes;;
5709 esac
5710
5711
5712 { $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
5713 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5714 if test "${ac_cv_path_GREP+set}" = set; then
5715   $as_echo_n "(cached) " >&6
5716 else
5717   if test -z "$GREP"; then
5718   ac_path_GREP_found=false
5719   # Loop through the user's path and test for each of PROGNAME-LIST
5720   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5721 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5722 do
5723   IFS=$as_save_IFS
5724   test -z "$as_dir" && as_dir=.
5725   for ac_prog in grep ggrep; do
5726     for ac_exec_ext in '' $ac_executable_extensions; do
5727       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5728       { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5729 # Check for GNU ac_path_GREP and select it if it is found.
5730   # Check for GNU $ac_path_GREP
5731 case `"$ac_path_GREP" --version 2>&1` in
5732 *GNU*)
5733   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5734 *)
5735   ac_count=0
5736   $as_echo_n 0123456789 >"conftest.in"
5737   while :
5738   do
5739     cat "conftest.in" "conftest.in" >"conftest.tmp"
5740     mv "conftest.tmp" "conftest.in"
5741     cp "conftest.in" "conftest.nl"
5742     $as_echo 'GREP' >> "conftest.nl"
5743     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5744     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5745     ac_count=`expr $ac_count + 1`
5746     if test $ac_count -gt ${ac_path_GREP_max-0}; then
5747       # Best one so far, save it but keep looking for a better one
5748       ac_cv_path_GREP="$ac_path_GREP"
5749       ac_path_GREP_max=$ac_count
5750     fi
5751     # 10*(2^10) chars as input seems more than enough
5752     test $ac_count -gt 10 && break
5753   done
5754   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5755 esac
5756
5757       $ac_path_GREP_found && break 3
5758     done
5759   done
5760 done
5761 IFS=$as_save_IFS
5762   if test -z "$ac_cv_path_GREP"; then
5763     { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5764 $as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5765    { (exit 1); exit 1; }; }
5766   fi
5767 else
5768   ac_cv_path_GREP=$GREP
5769 fi
5770
5771 fi
5772 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
5773 $as_echo "$ac_cv_path_GREP" >&6; }
5774  GREP="$ac_cv_path_GREP"
5775
5776
5777 { $as_echo "$as_me:$LINENO: checking for egrep" >&5
5778 $as_echo_n "checking for egrep... " >&6; }
5779 if test "${ac_cv_path_EGREP+set}" = set; then
5780   $as_echo_n "(cached) " >&6
5781 else
5782   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5783    then ac_cv_path_EGREP="$GREP -E"
5784    else
5785      if test -z "$EGREP"; then
5786   ac_path_EGREP_found=false
5787   # Loop through the user's path and test for each of PROGNAME-LIST
5788   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5789 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5790 do
5791   IFS=$as_save_IFS
5792   test -z "$as_dir" && as_dir=.
5793   for ac_prog in egrep; do
5794     for ac_exec_ext in '' $ac_executable_extensions; do
5795       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5796       { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5797 # Check for GNU ac_path_EGREP and select it if it is found.
5798   # Check for GNU $ac_path_EGREP
5799 case `"$ac_path_EGREP" --version 2>&1` in
5800 *GNU*)
5801   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5802 *)
5803   ac_count=0
5804   $as_echo_n 0123456789 >"conftest.in"
5805   while :
5806   do
5807     cat "conftest.in" "conftest.in" >"conftest.tmp"
5808     mv "conftest.tmp" "conftest.in"
5809     cp "conftest.in" "conftest.nl"
5810     $as_echo 'EGREP' >> "conftest.nl"
5811     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5812     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5813     ac_count=`expr $ac_count + 1`
5814     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5815       # Best one so far, save it but keep looking for a better one
5816       ac_cv_path_EGREP="$ac_path_EGREP"
5817       ac_path_EGREP_max=$ac_count
5818     fi
5819     # 10*(2^10) chars as input seems more than enough
5820     test $ac_count -gt 10 && break
5821   done
5822   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5823 esac
5824
5825       $ac_path_EGREP_found && break 3
5826     done
5827   done
5828 done
5829 IFS=$as_save_IFS
5830   if test -z "$ac_cv_path_EGREP"; then
5831     { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5832 $as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5833    { (exit 1); exit 1; }; }
5834   fi
5835 else
5836   ac_cv_path_EGREP=$EGREP
5837 fi
5838
5839    fi
5840 fi
5841 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
5842 $as_echo "$ac_cv_path_EGREP" >&6; }
5843  EGREP="$ac_cv_path_EGREP"
5844
5845
5846 cat >conftest.$ac_ext <<_ACEOF
5847 /* confdefs.h.  */
5848 _ACEOF
5849 cat confdefs.h >>conftest.$ac_ext
5850 cat >>conftest.$ac_ext <<_ACEOF
5851 /* end confdefs.h.  */
5852 #if __ELF__
5853   yes
5854 #endif
5855
5856 _ACEOF
5857 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5858   $EGREP "yes" >/dev/null 2>&1; then
5859   ELF_SYS=true
5860 else
5861   if test "X$elf" = "Xyes" ; then
5862   ELF_SYS=true
5863 else
5864   ELF_SYS=
5865 fi
5866 fi
5867 rm -f conftest*
5868
5869
5870
5871 #
5872 # Assignments
5873 #
5874
5875 CPPFLAGS="$CPPFLAGS $INCLUDES"
5876 LDFLAGS="$LDFLAGS $LIBDIRS"
5877
5878
5879
5880
5881
5882 # Check whether --with-gnu-ld was given.
5883 if test "${with_gnu_ld+set}" = set; then
5884   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
5885 else
5886   with_gnu_ld=no
5887 fi
5888
5889 ac_prog=ld
5890 if test "$GCC" = yes; then
5891   # Check if gcc -print-prog-name=ld gives a path.
5892   { $as_echo "$as_me:$LINENO: checking for ld used by GCC" >&5
5893 $as_echo_n "checking for ld used by GCC... " >&6; }
5894   case $host in
5895   *-*-mingw*)
5896     # gcc leaves a trailing carriage return which upsets mingw
5897     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
5898   *)
5899     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
5900   esac
5901   case "$ac_prog" in
5902     # Accept absolute paths.
5903     [\\/]* | [A-Za-z]:[\\/]*)
5904       re_direlt='/[^/][^/]*/\.\./'
5905       # Canonicalize the path of ld
5906       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
5907       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
5908         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
5909       done
5910       test -z "$LD" && LD="$ac_prog"
5911       ;;
5912   "")
5913     # If it fails, then pretend we aren't using GCC.
5914     ac_prog=ld
5915     ;;
5916   *)
5917     # If it is relative, then search for the first ld in PATH.
5918     with_gnu_ld=unknown
5919     ;;
5920   esac
5921 elif test "$with_gnu_ld" = yes; then
5922   { $as_echo "$as_me:$LINENO: checking for GNU ld" >&5
5923 $as_echo_n "checking for GNU ld... " >&6; }
5924 else
5925   { $as_echo "$as_me:$LINENO: checking for non-GNU ld" >&5
5926 $as_echo_n "checking for non-GNU ld... " >&6; }
5927 fi
5928 if test "${ac_cv_path_LD+set}" = set; then
5929   $as_echo_n "(cached) " >&6
5930 else
5931   if test -z "$LD"; then
5932   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
5933   for ac_dir in $PATH; do
5934     test -z "$ac_dir" && ac_dir=.
5935     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
5936       ac_cv_path_LD="$ac_dir/$ac_prog"
5937       # Check to see if the program is GNU ld.  I'd rather use --version,
5938       # but apparently some GNU ld's only accept -v.
5939       # Break only if it was the GNU/non-GNU ld that we prefer.
5940       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
5941         test "$with_gnu_ld" != no && break
5942       else
5943         test "$with_gnu_ld" != yes && break
5944       fi
5945     fi
5946   done
5947   IFS="$ac_save_ifs"
5948 else
5949   ac_cv_path_LD="$LD" # Let the user override the test with a path.
5950 fi
5951 fi
5952
5953 LD="$ac_cv_path_LD"
5954 if test -n "$LD"; then
5955   { $as_echo "$as_me:$LINENO: result: $LD" >&5
5956 $as_echo "$LD" >&6; }
5957 else
5958   { $as_echo "$as_me:$LINENO: result: no" >&5
5959 $as_echo "no" >&6; }
5960 fi
5961 test -z "$LD" && { { $as_echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
5962 $as_echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
5963    { (exit 1); exit 1; }; }
5964 { $as_echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
5965 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
5966 if test "${ac_cv_prog_gnu_ld+set}" = set; then
5967   $as_echo_n "(cached) " >&6
5968 else
5969   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
5970 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
5971   ac_cv_prog_gnu_ld=yes
5972 else
5973   ac_cv_prog_gnu_ld=no
5974 fi
5975 fi
5976 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
5977 $as_echo "$ac_cv_prog_gnu_ld" >&6; }
5978 with_gnu_ld=$ac_cv_prog_gnu_ld
5979
5980
5981
5982
5983 case $host_os in sysv5*)
5984   { $as_echo "$as_me:$LINENO: checking whether ld -R works" >&5
5985 $as_echo_n "checking whether ld -R works... " >&6; }
5986 if test "${pgac_cv_prog_ld_R+set}" = set; then
5987   $as_echo_n "(cached) " >&6
5988 else
5989
5990     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
5991     cat >conftest.$ac_ext <<_ACEOF
5992 /* confdefs.h.  */
5993 _ACEOF
5994 cat confdefs.h >>conftest.$ac_ext
5995 cat >>conftest.$ac_ext <<_ACEOF
5996 /* end confdefs.h.  */
5997
5998 int
5999 main ()
6000 {
6001
6002   ;
6003   return 0;
6004 }
6005 _ACEOF
6006 rm -f conftest.$ac_objext conftest$ac_exeext
6007 if { (ac_try="$ac_link"
6008 case "(($ac_try" in
6009   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
6010   *) ac_try_echo=$ac_try;;
6011 esac
6012 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
6013 $as_echo "$ac_try_echo") >&5
6014   (eval "$ac_link") 2>conftest.er1
6015   ac_status=$?
6016   grep -v '^ *+' conftest.er1 >conftest.err
6017   rm -f conftest.er1
6018   cat conftest.err >&5
6019   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
6020   (exit $ac_status); } && {
6021          test -z "$ac_c_werror_flag" ||
6022          test ! -s conftest.err
6023        } && test -s conftest$ac_exeext && {
6024          test "$cross_compiling" = yes ||
6025          $as_test_x conftest$ac_exeext
6026        }; then
6027   pgac_cv_prog_ld_R=yes
6028 else
6029   $as_echo "$as_me: failed program was:" >&5
6030 sed 's/^/| /' conftest.$ac_ext >&5
6031
6032         pgac_cv_prog_ld_R=no
6033 fi
6034
6035 rm -rf conftest.dSYM
6036 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6037       conftest$ac_exeext conftest.$ac_ext
6038     LDFLAGS=$pgac_save_LDFLAGS
6039
6040 fi
6041 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
6042 $as_echo "$pgac_cv_prog_ld_R" >&6; }
6043   ld_R_works=$pgac_cv_prog_ld_R
6044
6045 esac
6046 if test -n "$ac_tool_prefix"; then
6047   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6048 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6049 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6050 $as_echo_n "checking for $ac_word... " >&6; }
6051 if test "${ac_cv_prog_RANLIB+set}" = set; then
6052   $as_echo_n "(cached) " >&6
6053 else
6054   if test -n "$RANLIB"; then
6055   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6056 else
6057 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6058 for as_dir in $PATH
6059 do
6060   IFS=$as_save_IFS
6061   test -z "$as_dir" && as_dir=.
6062   for ac_exec_ext in '' $ac_executable_extensions; do
6063   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6064     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6065     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6066     break 2
6067   fi
6068 done
6069 done
6070 IFS=$as_save_IFS
6071
6072 fi
6073 fi
6074 RANLIB=$ac_cv_prog_RANLIB
6075 if test -n "$RANLIB"; then
6076   { $as_echo "$as_me:$LINENO: result: $RANLIB" >&5
6077 $as_echo "$RANLIB" >&6; }
6078 else
6079   { $as_echo "$as_me:$LINENO: result: no" >&5
6080 $as_echo "no" >&6; }
6081 fi
6082
6083
6084 fi
6085 if test -z "$ac_cv_prog_RANLIB"; then
6086   ac_ct_RANLIB=$RANLIB
6087   # Extract the first word of "ranlib", so it can be a program name with args.
6088 set dummy ranlib; ac_word=$2
6089 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6090 $as_echo_n "checking for $ac_word... " >&6; }
6091 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
6092   $as_echo_n "(cached) " >&6
6093 else
6094   if test -n "$ac_ct_RANLIB"; then
6095   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6096 else
6097 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6098 for as_dir in $PATH
6099 do
6100   IFS=$as_save_IFS
6101   test -z "$as_dir" && as_dir=.
6102   for ac_exec_ext in '' $ac_executable_extensions; do
6103   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6104     ac_cv_prog_ac_ct_RANLIB="ranlib"
6105     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6106     break 2
6107   fi
6108 done
6109 done
6110 IFS=$as_save_IFS
6111
6112 fi
6113 fi
6114 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6115 if test -n "$ac_ct_RANLIB"; then
6116   { $as_echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
6117 $as_echo "$ac_ct_RANLIB" >&6; }
6118 else
6119   { $as_echo "$as_me:$LINENO: result: no" >&5
6120 $as_echo "no" >&6; }
6121 fi
6122
6123   if test "x$ac_ct_RANLIB" = x; then
6124     RANLIB=":"
6125   else
6126     case $cross_compiling:$ac_tool_warned in
6127 yes:)
6128 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6129 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6130 ac_tool_warned=yes ;;
6131 esac
6132     RANLIB=$ac_ct_RANLIB
6133   fi
6134 else
6135   RANLIB="$ac_cv_prog_RANLIB"
6136 fi
6137
6138
6139   if test -n "$ac_tool_prefix"; then
6140   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6141 set dummy ${ac_tool_prefix}strip; ac_word=$2
6142 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6143 $as_echo_n "checking for $ac_word... " >&6; }
6144 if test "${ac_cv_prog_STRIP+set}" = set; then
6145   $as_echo_n "(cached) " >&6
6146 else
6147   if test -n "$STRIP"; then
6148   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6149 else
6150 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6151 for as_dir in $PATH
6152 do
6153   IFS=$as_save_IFS
6154   test -z "$as_dir" && as_dir=.
6155   for ac_exec_ext in '' $ac_executable_extensions; do
6156   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6157     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6158     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6159     break 2
6160   fi
6161 done
6162 done
6163 IFS=$as_save_IFS
6164
6165 fi
6166 fi
6167 STRIP=$ac_cv_prog_STRIP
6168 if test -n "$STRIP"; then
6169   { $as_echo "$as_me:$LINENO: result: $STRIP" >&5
6170 $as_echo "$STRIP" >&6; }
6171 else
6172   { $as_echo "$as_me:$LINENO: result: no" >&5
6173 $as_echo "no" >&6; }
6174 fi
6175
6176
6177 fi
6178 if test -z "$ac_cv_prog_STRIP"; then
6179   ac_ct_STRIP=$STRIP
6180   # Extract the first word of "strip", so it can be a program name with args.
6181 set dummy strip; ac_word=$2
6182 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6183 $as_echo_n "checking for $ac_word... " >&6; }
6184 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
6185   $as_echo_n "(cached) " >&6
6186 else
6187   if test -n "$ac_ct_STRIP"; then
6188   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6189 else
6190 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6191 for as_dir in $PATH
6192 do
6193   IFS=$as_save_IFS
6194   test -z "$as_dir" && as_dir=.
6195   for ac_exec_ext in '' $ac_executable_extensions; do
6196   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6197     ac_cv_prog_ac_ct_STRIP="strip"
6198     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6199     break 2
6200   fi
6201 done
6202 done
6203 IFS=$as_save_IFS
6204
6205 fi
6206 fi
6207 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6208 if test -n "$ac_ct_STRIP"; then
6209   { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
6210 $as_echo "$ac_ct_STRIP" >&6; }
6211 else
6212   { $as_echo "$as_me:$LINENO: result: no" >&5
6213 $as_echo "no" >&6; }
6214 fi
6215
6216   if test "x$ac_ct_STRIP" = x; then
6217     STRIP=":"
6218   else
6219     case $cross_compiling:$ac_tool_warned in
6220 yes:)
6221 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6222 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6223 ac_tool_warned=yes ;;
6224 esac
6225     STRIP=$ac_ct_STRIP
6226   fi
6227 else
6228   STRIP="$ac_cv_prog_STRIP"
6229 fi
6230
6231
6232   { $as_echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
6233 $as_echo_n "checking whether it is possible to strip libraries... " >&6; }
6234   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
6235     STRIP_STATIC_LIB="$STRIP -x"
6236     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
6237     { $as_echo "$as_me:$LINENO: result: yes" >&5
6238 $as_echo "yes" >&6; }
6239   else
6240     STRIP_STATIC_LIB=:
6241     STRIP_SHARED_LIB=:
6242     { $as_echo "$as_me:$LINENO: result: no" >&5
6243 $as_echo "no" >&6; }
6244   fi
6245
6246
6247
6248 if test -n "$ac_tool_prefix"; then
6249   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6250 set dummy ${ac_tool_prefix}ar; ac_word=$2
6251 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6252 $as_echo_n "checking for $ac_word... " >&6; }
6253 if test "${ac_cv_prog_AR+set}" = set; then
6254   $as_echo_n "(cached) " >&6
6255 else
6256   if test -n "$AR"; then
6257   ac_cv_prog_AR="$AR" # Let the user override the test.
6258 else
6259 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6260 for as_dir in $PATH
6261 do
6262   IFS=$as_save_IFS
6263   test -z "$as_dir" && as_dir=.
6264   for ac_exec_ext in '' $ac_executable_extensions; do
6265   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6266     ac_cv_prog_AR="${ac_tool_prefix}ar"
6267     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6268     break 2
6269   fi
6270 done
6271 done
6272 IFS=$as_save_IFS
6273
6274 fi
6275 fi
6276 AR=$ac_cv_prog_AR
6277 if test -n "$AR"; then
6278   { $as_echo "$as_me:$LINENO: result: $AR" >&5
6279 $as_echo "$AR" >&6; }
6280 else
6281   { $as_echo "$as_me:$LINENO: result: no" >&5
6282 $as_echo "no" >&6; }
6283 fi
6284
6285
6286 fi
6287 if test -z "$ac_cv_prog_AR"; then
6288   ac_ct_AR=$AR
6289   # Extract the first word of "ar", so it can be a program name with args.
6290 set dummy ar; ac_word=$2
6291 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6292 $as_echo_n "checking for $ac_word... " >&6; }
6293 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
6294   $as_echo_n "(cached) " >&6
6295 else
6296   if test -n "$ac_ct_AR"; then
6297   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6298 else
6299 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6300 for as_dir in $PATH
6301 do
6302   IFS=$as_save_IFS
6303   test -z "$as_dir" && as_dir=.
6304   for ac_exec_ext in '' $ac_executable_extensions; do
6305   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6306     ac_cv_prog_ac_ct_AR="ar"
6307     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6308     break 2
6309   fi
6310 done
6311 done
6312 IFS=$as_save_IFS
6313
6314 fi
6315 fi
6316 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6317 if test -n "$ac_ct_AR"; then
6318   { $as_echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
6319 $as_echo "$ac_ct_AR" >&6; }
6320 else
6321   { $as_echo "$as_me:$LINENO: result: no" >&5
6322 $as_echo "no" >&6; }
6323 fi
6324
6325   if test "x$ac_ct_AR" = x; then
6326     AR="ar"
6327   else
6328     case $cross_compiling:$ac_tool_warned in
6329 yes:)
6330 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6331 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6332 ac_tool_warned=yes ;;
6333 esac
6334     AR=$ac_ct_AR
6335   fi
6336 else
6337   AR="$ac_cv_prog_AR"
6338 fi
6339
6340 if test "$PORTNAME" = "win32"; then
6341   if test -n "$ac_tool_prefix"; then
6342   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
6343 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
6344 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6345 $as_echo_n "checking for $ac_word... " >&6; }
6346 if test "${ac_cv_prog_DLLTOOL+set}" = set; then
6347   $as_echo_n "(cached) " >&6
6348 else
6349   if test -n "$DLLTOOL"; then
6350   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
6351 else
6352 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6353 for as_dir in $PATH
6354 do
6355   IFS=$as_save_IFS
6356   test -z "$as_dir" && as_dir=.
6357   for ac_exec_ext in '' $ac_executable_extensions; do
6358   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6359     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
6360     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6361     break 2
6362   fi
6363 done
6364 done
6365 IFS=$as_save_IFS
6366
6367 fi
6368 fi
6369 DLLTOOL=$ac_cv_prog_DLLTOOL
6370 if test -n "$DLLTOOL"; then
6371   { $as_echo "$as_me:$LINENO: result: $DLLTOOL" >&5
6372 $as_echo "$DLLTOOL" >&6; }
6373 else
6374   { $as_echo "$as_me:$LINENO: result: no" >&5
6375 $as_echo "no" >&6; }
6376 fi
6377
6378
6379 fi
6380 if test -z "$ac_cv_prog_DLLTOOL"; then
6381   ac_ct_DLLTOOL=$DLLTOOL
6382   # Extract the first word of "dlltool", so it can be a program name with args.
6383 set dummy dlltool; ac_word=$2
6384 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6385 $as_echo_n "checking for $ac_word... " >&6; }
6386 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
6387   $as_echo_n "(cached) " >&6
6388 else
6389   if test -n "$ac_ct_DLLTOOL"; then
6390   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
6391 else
6392 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6393 for as_dir in $PATH
6394 do
6395   IFS=$as_save_IFS
6396   test -z "$as_dir" && as_dir=.
6397   for ac_exec_ext in '' $ac_executable_extensions; do
6398   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6399     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
6400     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6401     break 2
6402   fi
6403 done
6404 done
6405 IFS=$as_save_IFS
6406
6407 fi
6408 fi
6409 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
6410 if test -n "$ac_ct_DLLTOOL"; then
6411   { $as_echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
6412 $as_echo "$ac_ct_DLLTOOL" >&6; }
6413 else
6414   { $as_echo "$as_me:$LINENO: result: no" >&5
6415 $as_echo "no" >&6; }
6416 fi
6417
6418   if test "x$ac_ct_DLLTOOL" = x; then
6419     DLLTOOL="dlltool"
6420   else
6421     case $cross_compiling:$ac_tool_warned in
6422 yes:)
6423 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6424 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6425 ac_tool_warned=yes ;;
6426 esac
6427     DLLTOOL=$ac_ct_DLLTOOL
6428   fi
6429 else
6430   DLLTOOL="$ac_cv_prog_DLLTOOL"
6431 fi
6432
6433   if test -n "$ac_tool_prefix"; then
6434   # Extract the first word of "${ac_tool_prefix}dllwrap", so it can be a program name with args.
6435 set dummy ${ac_tool_prefix}dllwrap; ac_word=$2
6436 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6437 $as_echo_n "checking for $ac_word... " >&6; }
6438 if test "${ac_cv_prog_DLLWRAP+set}" = set; then
6439   $as_echo_n "(cached) " >&6
6440 else
6441   if test -n "$DLLWRAP"; then
6442   ac_cv_prog_DLLWRAP="$DLLWRAP" # Let the user override the test.
6443 else
6444 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6445 for as_dir in $PATH
6446 do
6447   IFS=$as_save_IFS
6448   test -z "$as_dir" && as_dir=.
6449   for ac_exec_ext in '' $ac_executable_extensions; do
6450   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6451     ac_cv_prog_DLLWRAP="${ac_tool_prefix}dllwrap"
6452     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6453     break 2
6454   fi
6455 done
6456 done
6457 IFS=$as_save_IFS
6458
6459 fi
6460 fi
6461 DLLWRAP=$ac_cv_prog_DLLWRAP
6462 if test -n "$DLLWRAP"; then
6463   { $as_echo "$as_me:$LINENO: result: $DLLWRAP" >&5
6464 $as_echo "$DLLWRAP" >&6; }
6465 else
6466   { $as_echo "$as_me:$LINENO: result: no" >&5
6467 $as_echo "no" >&6; }
6468 fi
6469
6470
6471 fi
6472 if test -z "$ac_cv_prog_DLLWRAP"; then
6473   ac_ct_DLLWRAP=$DLLWRAP
6474   # Extract the first word of "dllwrap", so it can be a program name with args.
6475 set dummy dllwrap; ac_word=$2
6476 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6477 $as_echo_n "checking for $ac_word... " >&6; }
6478 if test "${ac_cv_prog_ac_ct_DLLWRAP+set}" = set; then
6479   $as_echo_n "(cached) " >&6
6480 else
6481   if test -n "$ac_ct_DLLWRAP"; then
6482   ac_cv_prog_ac_ct_DLLWRAP="$ac_ct_DLLWRAP" # Let the user override the test.
6483 else
6484 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6485 for as_dir in $PATH
6486 do
6487   IFS=$as_save_IFS
6488   test -z "$as_dir" && as_dir=.
6489   for ac_exec_ext in '' $ac_executable_extensions; do
6490   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6491     ac_cv_prog_ac_ct_DLLWRAP="dllwrap"
6492     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6493     break 2
6494   fi
6495 done
6496 done
6497 IFS=$as_save_IFS
6498
6499 fi
6500 fi
6501 ac_ct_DLLWRAP=$ac_cv_prog_ac_ct_DLLWRAP
6502 if test -n "$ac_ct_DLLWRAP"; then
6503   { $as_echo "$as_me:$LINENO: result: $ac_ct_DLLWRAP" >&5
6504 $as_echo "$ac_ct_DLLWRAP" >&6; }
6505 else
6506   { $as_echo "$as_me:$LINENO: result: no" >&5
6507 $as_echo "no" >&6; }
6508 fi
6509
6510   if test "x$ac_ct_DLLWRAP" = x; then
6511     DLLWRAP="dllwrap"
6512   else
6513     case $cross_compiling:$ac_tool_warned in
6514 yes:)
6515 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6516 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6517 ac_tool_warned=yes ;;
6518 esac
6519     DLLWRAP=$ac_ct_DLLWRAP
6520   fi
6521 else
6522   DLLWRAP="$ac_cv_prog_DLLWRAP"
6523 fi
6524
6525   if test -n "$ac_tool_prefix"; then
6526   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
6527 set dummy ${ac_tool_prefix}windres; ac_word=$2
6528 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6529 $as_echo_n "checking for $ac_word... " >&6; }
6530 if test "${ac_cv_prog_WINDRES+set}" = set; then
6531   $as_echo_n "(cached) " >&6
6532 else
6533   if test -n "$WINDRES"; then
6534   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
6535 else
6536 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6537 for as_dir in $PATH
6538 do
6539   IFS=$as_save_IFS
6540   test -z "$as_dir" && as_dir=.
6541   for ac_exec_ext in '' $ac_executable_extensions; do
6542   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6543     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
6544     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6545     break 2
6546   fi
6547 done
6548 done
6549 IFS=$as_save_IFS
6550
6551 fi
6552 fi
6553 WINDRES=$ac_cv_prog_WINDRES
6554 if test -n "$WINDRES"; then
6555   { $as_echo "$as_me:$LINENO: result: $WINDRES" >&5
6556 $as_echo "$WINDRES" >&6; }
6557 else
6558   { $as_echo "$as_me:$LINENO: result: no" >&5
6559 $as_echo "no" >&6; }
6560 fi
6561
6562
6563 fi
6564 if test -z "$ac_cv_prog_WINDRES"; then
6565   ac_ct_WINDRES=$WINDRES
6566   # Extract the first word of "windres", so it can be a program name with args.
6567 set dummy windres; ac_word=$2
6568 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6569 $as_echo_n "checking for $ac_word... " >&6; }
6570 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then
6571   $as_echo_n "(cached) " >&6
6572 else
6573   if test -n "$ac_ct_WINDRES"; then
6574   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
6575 else
6576 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6577 for as_dir in $PATH
6578 do
6579   IFS=$as_save_IFS
6580   test -z "$as_dir" && as_dir=.
6581   for ac_exec_ext in '' $ac_executable_extensions; do
6582   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6583     ac_cv_prog_ac_ct_WINDRES="windres"
6584     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6585     break 2
6586   fi
6587 done
6588 done
6589 IFS=$as_save_IFS
6590
6591 fi
6592 fi
6593 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
6594 if test -n "$ac_ct_WINDRES"; then
6595   { $as_echo "$as_me:$LINENO: result: $ac_ct_WINDRES" >&5
6596 $as_echo "$ac_ct_WINDRES" >&6; }
6597 else
6598   { $as_echo "$as_me:$LINENO: result: no" >&5
6599 $as_echo "no" >&6; }
6600 fi
6601
6602   if test "x$ac_ct_WINDRES" = x; then
6603     WINDRES="windres"
6604   else
6605     case $cross_compiling:$ac_tool_warned in
6606 yes:)
6607 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6608 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6609 ac_tool_warned=yes ;;
6610 esac
6611     WINDRES=$ac_ct_WINDRES
6612   fi
6613 else
6614   WINDRES="$ac_cv_prog_WINDRES"
6615 fi
6616
6617 fi
6618
6619 # Extract the first word of "tar", so it can be a program name with args.
6620 set dummy tar; ac_word=$2
6621 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6622 $as_echo_n "checking for $ac_word... " >&6; }
6623 if test "${ac_cv_path_TAR+set}" = set; then
6624   $as_echo_n "(cached) " >&6
6625 else
6626   case $TAR in
6627   [\\/]* | ?:[\\/]*)
6628   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
6629   ;;
6630   *)
6631   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6632 for as_dir in $PATH
6633 do
6634   IFS=$as_save_IFS
6635   test -z "$as_dir" && as_dir=.
6636   for ac_exec_ext in '' $ac_executable_extensions; do
6637   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6638     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
6639     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6640     break 2
6641   fi
6642 done
6643 done
6644 IFS=$as_save_IFS
6645
6646   ;;
6647 esac
6648 fi
6649 TAR=$ac_cv_path_TAR
6650 if test -n "$TAR"; then
6651   { $as_echo "$as_me:$LINENO: result: $TAR" >&5
6652 $as_echo "$TAR" >&6; }
6653 else
6654   { $as_echo "$as_me:$LINENO: result: no" >&5
6655 $as_echo "no" >&6; }
6656 fi
6657
6658
6659 { $as_echo "$as_me:$LINENO: checking whether ln -s works" >&5
6660 $as_echo_n "checking whether ln -s works... " >&6; }
6661 LN_S=$as_ln_s
6662 if test "$LN_S" = "ln -s"; then
6663   { $as_echo "$as_me:$LINENO: result: yes" >&5
6664 $as_echo "yes" >&6; }
6665 else
6666   { $as_echo "$as_me:$LINENO: result: no, using $LN_S" >&5
6667 $as_echo "no, using $LN_S" >&6; }
6668 fi
6669
6670 for ac_prog in gawk mawk nawk awk
6671 do
6672   # Extract the first word of "$ac_prog", so it can be a program name with args.
6673 set dummy $ac_prog; ac_word=$2
6674 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6675 $as_echo_n "checking for $ac_word... " >&6; }
6676 if test "${ac_cv_prog_AWK+set}" = set; then
6677   $as_echo_n "(cached) " >&6
6678 else
6679   if test -n "$AWK"; then
6680   ac_cv_prog_AWK="$AWK" # Let the user override the test.
6681 else
6682 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6683 for as_dir in $PATH
6684 do
6685   IFS=$as_save_IFS
6686   test -z "$as_dir" && as_dir=.
6687   for ac_exec_ext in '' $ac_executable_extensions; do
6688   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6689     ac_cv_prog_AWK="$ac_prog"
6690     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6691     break 2
6692   fi
6693 done
6694 done
6695 IFS=$as_save_IFS
6696
6697 fi
6698 fi
6699 AWK=$ac_cv_prog_AWK
6700 if test -n "$AWK"; then
6701   { $as_echo "$as_me:$LINENO: result: $AWK" >&5
6702 $as_echo "$AWK" >&6; }
6703 else
6704   { $as_echo "$as_me:$LINENO: result: no" >&5
6705 $as_echo "no" >&6; }
6706 fi
6707
6708
6709   test -n "$AWK" && break
6710 done
6711
6712 { $as_echo "$as_me:$LINENO: checking for a thread-safe mkdir -p" >&5
6713 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
6714 if test -z "$MKDIR_P"; then
6715   if test "${ac_cv_path_mkdir+set}" = set; then
6716   $as_echo_n "(cached) " >&6
6717 else
6718   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6719 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
6720 do
6721   IFS=$as_save_IFS
6722   test -z "$as_dir" && as_dir=.
6723   for ac_prog in mkdir gmkdir; do
6724          for ac_exec_ext in '' $ac_executable_extensions; do
6725            { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
6726            case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
6727              'mkdir (GNU coreutils) '* | \
6728              'mkdir (coreutils) '* | \
6729              'mkdir (fileutils) '4.1*)
6730                ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
6731                break 3;;
6732            esac
6733          done
6734        done
6735 done
6736 IFS=$as_save_IFS
6737
6738 fi
6739
6740   if test "${ac_cv_path_mkdir+set}" = set; then
6741     MKDIR_P="$ac_cv_path_mkdir -p"
6742   else
6743     # As a last resort, use the slow shell script.  Don't cache a
6744     # value for MKDIR_P within a source directory, because that will
6745     # break other packages using the cache if that directory is
6746     # removed, or if the value is a relative name.
6747     test -d ./--version && rmdir ./--version
6748     MKDIR_P="$ac_install_sh -d"
6749   fi
6750 fi
6751 { $as_echo "$as_me:$LINENO: result: $MKDIR_P" >&5
6752 $as_echo "$MKDIR_P" >&6; }
6753
6754 # When Autoconf chooses install-sh as mkdir -p program it tries to generate
6755 # a relative path to it in each makefile where it subsitutes it. This clashes
6756 # with our Makefile.global concept. This workaround helps.
6757 case $MKDIR_P in
6758   *install-sh*) MKDIR_P='\${SHELL} \${top_srcdir}/config/install-sh -c -d';;
6759 esac
6760
6761 # Let the user override the search
6762 if test -z "$BISON"; then
6763   for ac_prog in bison
6764 do
6765   # Extract the first word of "$ac_prog", so it can be a program name with args.
6766 set dummy $ac_prog; ac_word=$2
6767 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6768 $as_echo_n "checking for $ac_word... " >&6; }
6769 if test "${ac_cv_path_BISON+set}" = set; then
6770   $as_echo_n "(cached) " >&6
6771 else
6772   case $BISON in
6773   [\\/]* | ?:[\\/]*)
6774   ac_cv_path_BISON="$BISON" # Let the user override the test with a path.
6775   ;;
6776   *)
6777   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6778 for as_dir in $PATH
6779 do
6780   IFS=$as_save_IFS
6781   test -z "$as_dir" && as_dir=.
6782   for ac_exec_ext in '' $ac_executable_extensions; do
6783   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6784     ac_cv_path_BISON="$as_dir/$ac_word$ac_exec_ext"
6785     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6786     break 2
6787   fi
6788 done
6789 done
6790 IFS=$as_save_IFS
6791
6792   ;;
6793 esac
6794 fi
6795 BISON=$ac_cv_path_BISON
6796 if test -n "$BISON"; then
6797   { $as_echo "$as_me:$LINENO: result: $BISON" >&5
6798 $as_echo "$BISON" >&6; }
6799 else
6800   { $as_echo "$as_me:$LINENO: result: no" >&5
6801 $as_echo "no" >&6; }
6802 fi
6803
6804
6805   test -n "$BISON" && break
6806 done
6807
6808 fi
6809
6810 if test "$BISON"; then
6811   pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
6812   { $as_echo "$as_me:$LINENO: using $pgac_bison_version" >&5
6813 $as_echo "$as_me: using $pgac_bison_version" >&6;}
6814   if echo "$pgac_bison_version" | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'
6815   then
6816     { $as_echo "$as_me:$LINENO: WARNING:
6817 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
6818 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&5
6819 $as_echo "$as_me: WARNING:
6820 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
6821 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&2;}
6822     BISON=""
6823   fi
6824 fi
6825
6826 if test -z "$BISON"; then
6827   { $as_echo "$as_me:$LINENO: WARNING:
6828 *** Without Bison you will not be able to build PostgreSQL from Git nor
6829 *** change any of the parser definition files.  You can obtain Bison from
6830 *** a GNU mirror site.  (If you are using the official distribution of
6831 *** PostgreSQL then you do not need to worry about this, because the Bison
6832 *** output is pre-generated.)" >&5
6833 $as_echo "$as_me: WARNING:
6834 *** Without Bison you will not be able to build PostgreSQL from Git nor
6835 *** change any of the parser definition files.  You can obtain Bison from
6836 *** a GNU mirror site.  (If you are using the official distribution of
6837 *** PostgreSQL then you do not need to worry about this, because the Bison
6838 *** output is pre-generated.)" >&2;}
6839 fi
6840 # We don't need AC_SUBST(BISON) because AC_PATH_PROG did it
6841
6842
6843 { $as_echo "$as_me:$LINENO: checking for flex" >&5
6844 $as_echo_n "checking for flex... " >&6; }
6845 if test "${pgac_cv_path_flex+set}" = set; then
6846   $as_echo_n "(cached) " >&6
6847 else
6848   # Let the user override the test
6849 if test -n "$FLEX"; then
6850   pgac_cv_path_flex=$FLEX
6851 else
6852   pgac_save_IFS=$IFS
6853   IFS=$PATH_SEPARATOR
6854   for pgac_dir in $PATH; do
6855     IFS=$pgac_save_IFS
6856     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
6857       pgac_dir=`pwd`
6858     fi
6859     for pgac_prog in flex lex; do
6860       pgac_candidate="$pgac_dir/$pgac_prog"
6861       if test -f "$pgac_candidate" \
6862         && $pgac_candidate --version </dev/null >/dev/null 2>&1
6863       then
6864         echo '%%'  > conftest.l
6865         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
6866           pgac_flex_version=`$pgac_candidate --version 2>/dev/null`
6867           if echo "$pgac_flex_version" | sed 's/[.a-z]/ /g' | $AWK '{ if ($1 = 2 && $2 = 5 && $3 >= 31) exit 0; else exit 1;}'
6868           then
6869             pgac_cv_path_flex=$pgac_candidate
6870             break 2
6871           else
6872             { $as_echo "$as_me:$LINENO: WARNING:
6873 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
6874 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&5
6875 $as_echo "$as_me: WARNING:
6876 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
6877 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&2;}
6878           fi
6879         fi
6880       fi
6881     done
6882   done
6883   rm -f conftest.l lex.yy.c
6884   : ${pgac_cv_path_flex=no}
6885 fi
6886
6887 fi
6888 { $as_echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
6889 $as_echo "$pgac_cv_path_flex" >&6; }
6890 if test x"$pgac_cv_path_flex" = x"no"; then
6891   { $as_echo "$as_me:$LINENO: WARNING:
6892 *** Without Flex you will not be able to build PostgreSQL from Git nor
6893 *** change any of the scanner definition files.  You can obtain Flex from
6894 *** a GNU mirror site.  (If you are using the official distribution of
6895 *** PostgreSQL then you do not need to worry about this because the Flex
6896 *** output is pre-generated.)" >&5
6897 $as_echo "$as_me: WARNING:
6898 *** Without Flex you will not be able to build PostgreSQL from Git nor
6899 *** change any of the scanner definition files.  You can obtain Flex from
6900 *** a GNU mirror site.  (If you are using the official distribution of
6901 *** PostgreSQL then you do not need to worry about this because the Flex
6902 *** output is pre-generated.)" >&2;}
6903
6904   FLEX=
6905 else
6906   FLEX=$pgac_cv_path_flex
6907   pgac_flex_version=`$FLEX --version 2>/dev/null`
6908   { $as_echo "$as_me:$LINENO: using $pgac_flex_version" >&5
6909 $as_echo "$as_me: using $pgac_flex_version" >&6;}
6910 fi
6911
6912
6913
6914
6915
6916 # Let the user override the search
6917 if test -z "$PERL"; then
6918   # Extract the first word of "perl", so it can be a program name with args.
6919 set dummy perl; ac_word=$2
6920 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6921 $as_echo_n "checking for $ac_word... " >&6; }
6922 if test "${ac_cv_path_PERL+set}" = set; then
6923   $as_echo_n "(cached) " >&6
6924 else
6925   case $PERL in
6926   [\\/]* | ?:[\\/]*)
6927   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
6928   ;;
6929   *)
6930   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6931 for as_dir in $PATH
6932 do
6933   IFS=$as_save_IFS
6934   test -z "$as_dir" && as_dir=.
6935   for ac_exec_ext in '' $ac_executable_extensions; do
6936   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6937     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
6938     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6939     break 2
6940   fi
6941 done
6942 done
6943 IFS=$as_save_IFS
6944
6945   ;;
6946 esac
6947 fi
6948 PERL=$ac_cv_path_PERL
6949 if test -n "$PERL"; then
6950   { $as_echo "$as_me:$LINENO: result: $PERL" >&5
6951 $as_echo "$PERL" >&6; }
6952 else
6953   { $as_echo "$as_me:$LINENO: result: no" >&5
6954 $as_echo "no" >&6; }
6955 fi
6956
6957
6958 fi
6959
6960 if test "$PERL"; then
6961   pgac_perl_version=`$PERL -v 2>/dev/null | sed -n 's/This is perl.*v[a-z ]*\([0-9]\.[0-9][0-9.]*\).*$/\1/p'`
6962   { $as_echo "$as_me:$LINENO: using perl $pgac_perl_version" >&5
6963 $as_echo "$as_me: using perl $pgac_perl_version" >&6;}
6964   if echo "$pgac_perl_version" | sed 's/[.a-z_]/ /g' | \
6965     $AWK '{ if ($1 = 5 && $2 >= 8) exit 1; else exit 0;}'
6966   then
6967     { $as_echo "$as_me:$LINENO: WARNING:
6968 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
6969 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&5
6970 $as_echo "$as_me: WARNING:
6971 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
6972 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&2;}
6973     PERL=""
6974   fi
6975 fi
6976
6977 if test -z "$PERL"; then
6978   { $as_echo "$as_me:$LINENO: WARNING:
6979 *** Without Perl you will not be able to build PostgreSQL from Git.
6980 *** You can obtain Perl from any CPAN mirror site.
6981 *** (If you are using the official distribution of PostgreSQL then you do not
6982 *** need to worry about this, because the Perl output is pre-generated.)" >&5
6983 $as_echo "$as_me: WARNING:
6984 *** Without Perl you will not be able to build PostgreSQL from Git.
6985 *** You can obtain Perl from any CPAN mirror site.
6986 *** (If you are using the official distribution of PostgreSQL then you do not
6987 *** need to worry about this, because the Perl output is pre-generated.)" >&2;}
6988 fi
6989
6990 if test "$with_perl" = yes; then
6991   if test -z "$PERL"; then
6992     { { $as_echo "$as_me:$LINENO: error: Perl not found" >&5
6993 $as_echo "$as_me: error: Perl not found" >&2;}
6994    { (exit 1); exit 1; }; }
6995   fi
6996
6997 { $as_echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
6998 $as_echo_n "checking for Perl archlibexp... " >&6; }
6999 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
7000 { $as_echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
7001 $as_echo "$perl_archlibexp" >&6; }
7002 { $as_echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
7003 $as_echo_n "checking for Perl privlibexp... " >&6; }
7004 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
7005 { $as_echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
7006 $as_echo "$perl_privlibexp" >&6; }
7007 { $as_echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
7008 $as_echo_n "checking for Perl useshrplib... " >&6; }
7009 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
7010 { $as_echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
7011 $as_echo "$perl_useshrplib" >&6; }
7012
7013 { $as_echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
7014 $as_echo_n "checking for flags to link embedded Perl... " >&6; }
7015 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
7016 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
7017 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed -e "s/^X//" -e "s%$pgac_tmp2%%" -e "s/ -arch [-a-zA-Z0-9_]*//g"`
7018 if test -z "$perl_embed_ldflags" ; then
7019         { $as_echo "$as_me:$LINENO: result: no" >&5
7020 $as_echo "no" >&6; }
7021         { { $as_echo "$as_me:$LINENO: error: could not determine flags for linking embedded Perl.
7022 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
7023 installed." >&5
7024 $as_echo "$as_me: error: could not determine flags for linking embedded Perl.
7025 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
7026 installed." >&2;}
7027    { (exit 1); exit 1; }; }
7028 else
7029         { $as_echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
7030 $as_echo "$perl_embed_ldflags" >&6; }
7031 fi
7032
7033 fi
7034
7035 if test "$with_python" = yes; then
7036   # Extract the first word of "python", so it can be a program name with args.
7037 set dummy python; ac_word=$2
7038 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7039 $as_echo_n "checking for $ac_word... " >&6; }
7040 if test "${ac_cv_path_PYTHON+set}" = set; then
7041   $as_echo_n "(cached) " >&6
7042 else
7043   case $PYTHON in
7044   [\\/]* | ?:[\\/]*)
7045   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
7046   ;;
7047   *)
7048   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7049 for as_dir in $PATH
7050 do
7051   IFS=$as_save_IFS
7052   test -z "$as_dir" && as_dir=.
7053   for ac_exec_ext in '' $ac_executable_extensions; do
7054   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7055     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
7056     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7057     break 2
7058   fi
7059 done
7060 done
7061 IFS=$as_save_IFS
7062
7063   ;;
7064 esac
7065 fi
7066 PYTHON=$ac_cv_path_PYTHON
7067 if test -n "$PYTHON"; then
7068   { $as_echo "$as_me:$LINENO: result: $PYTHON" >&5
7069 $as_echo "$PYTHON" >&6; }
7070 else
7071   { $as_echo "$as_me:$LINENO: result: no" >&5
7072 $as_echo "no" >&6; }
7073 fi
7074
7075
7076 if test x"$PYTHON" = x""; then
7077   { { $as_echo "$as_me:$LINENO: error: Python not found" >&5
7078 $as_echo "$as_me: error: Python not found" >&2;}
7079    { (exit 1); exit 1; }; }
7080 fi
7081
7082
7083 { $as_echo "$as_me:$LINENO: checking for Python distutils module" >&5
7084 $as_echo_n "checking for Python distutils module... " >&6; }
7085 if "${PYTHON}" -c 'import distutils' 2>&5
7086 then
7087     { $as_echo "$as_me:$LINENO: result: yes" >&5
7088 $as_echo "yes" >&6; }
7089 else
7090     { $as_echo "$as_me:$LINENO: result: no" >&5
7091 $as_echo "no" >&6; }
7092     { { $as_echo "$as_me:$LINENO: error: distutils module not found" >&5
7093 $as_echo "$as_me: error: distutils module not found" >&2;}
7094    { (exit 1); exit 1; }; }
7095 fi
7096 { $as_echo "$as_me:$LINENO: checking Python configuration directory" >&5
7097 $as_echo_n "checking Python configuration directory... " >&6; }
7098 python_majorversion=`${PYTHON} -c "import sys; print(sys.version[0])"`
7099 python_version=`${PYTHON} -c "import sys; print(sys.version[:3])"`
7100 python_configdir=`${PYTHON} -c "from distutils.sysconfig import get_python_lib as f; import os; print(os.path.join(f(plat_specific=1,standard_lib=1),'config'))"`
7101 python_includespec=`${PYTHON} -c "import distutils.sysconfig; print('-I'+distutils.sysconfig.get_python_inc())"`
7102
7103 # This should be enough of a message.
7104 { $as_echo "$as_me:$LINENO: result: $python_configdir" >&5
7105 $as_echo "$python_configdir" >&6; }
7106
7107
7108 { $as_echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
7109 $as_echo_n "checking how to link an embedded Python application... " >&6; }
7110
7111 python_libdir=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR'))))"`
7112 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY'))))"`
7113 python_so=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('SO'))))"`
7114 ldlibrary=`echo "${python_ldlibrary}" | sed "s/${python_so}$//"`
7115
7116 if test x"${python_libdir}" != x"" -a x"${python_ldlibrary}" != x"" -a x"${python_ldlibrary}" != x"${ldlibrary}"
7117 then
7118         # New way: use the official shared library
7119         ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
7120         python_libspec="-L${python_libdir} -l${ldlibrary}"
7121 else
7122         # Old way: use libpython from python_configdir
7123         python_libdir="${python_configdir}"
7124         python_libspec="-L${python_libdir} -lpython${python_version}"
7125 fi
7126
7127 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','BASEMODLIBS'))))"`
7128
7129 { $as_echo "$as_me:$LINENO: result: ${python_libspec} ${python_additional_libs}" >&5
7130 $as_echo "${python_libspec} ${python_additional_libs}" >&6; }
7131
7132
7133 # threaded python is not supported on bsd's
7134 { $as_echo "$as_me:$LINENO: checking whether Python is compiled with thread support" >&5
7135 $as_echo_n "checking whether Python is compiled with thread support... " >&6; }
7136 pythreads=`${PYTHON} -c "import sys; print(int('thread' in sys.builtin_module_names))"`
7137 if test "$pythreads" = "1"; then
7138   { $as_echo "$as_me:$LINENO: result: yes" >&5
7139 $as_echo "yes" >&6; }
7140   case $host_os in
7141   openbsd*|freebsd*)
7142     { { $as_echo "$as_me:$LINENO: error: threaded Python not supported on this platform" >&5
7143 $as_echo "$as_me: error: threaded Python not supported on this platform" >&2;}
7144    { (exit 1); exit 1; }; }
7145     ;;
7146   esac
7147 else
7148   { $as_echo "$as_me:$LINENO: result: no" >&5
7149 $as_echo "no" >&6; }
7150 fi
7151
7152
7153 fi
7154
7155 if test "$cross_compiling" = yes && test -z "$with_system_tzdata"; then
7156   # Extract the first word of "zic", so it can be a program name with args.
7157 set dummy zic; ac_word=$2
7158 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7159 $as_echo_n "checking for $ac_word... " >&6; }
7160 if test "${ac_cv_path_ZIC+set}" = set; then
7161   $as_echo_n "(cached) " >&6
7162 else
7163   case $ZIC in
7164   [\\/]* | ?:[\\/]*)
7165   ac_cv_path_ZIC="$ZIC" # Let the user override the test with a path.
7166   ;;
7167   *)
7168   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7169 for as_dir in $PATH
7170 do
7171   IFS=$as_save_IFS
7172   test -z "$as_dir" && as_dir=.
7173   for ac_exec_ext in '' $ac_executable_extensions; do
7174   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7175     ac_cv_path_ZIC="$as_dir/$ac_word$ac_exec_ext"
7176     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7177     break 2
7178   fi
7179 done
7180 done
7181 IFS=$as_save_IFS
7182
7183   ;;
7184 esac
7185 fi
7186 ZIC=$ac_cv_path_ZIC
7187 if test -n "$ZIC"; then
7188   { $as_echo "$as_me:$LINENO: result: $ZIC" >&5
7189 $as_echo "$ZIC" >&6; }
7190 else
7191   { $as_echo "$as_me:$LINENO: result: no" >&5
7192 $as_echo "no" >&6; }
7193 fi
7194
7195
7196   if test -z "$ZIC"; then
7197     { { $as_echo "$as_me:$LINENO: error:
7198 When cross-compiling, either use the option --with-system-tzdata to use
7199 existing time-zone data, or set the environment variable ZIC to a zic
7200 program to use during the build." >&5
7201 $as_echo "$as_me: error:
7202 When cross-compiling, either use the option --with-system-tzdata to use
7203 existing time-zone data, or set the environment variable ZIC to a zic
7204 program to use during the build." >&2;}
7205    { (exit 1); exit 1; }; }
7206   fi
7207 fi
7208
7209
7210 ##
7211 ## Libraries
7212 ##
7213 ## Most libraries are included only if they demonstrably provide a function
7214 ## we need, but libm is an exception: always include it, because there are
7215 ## too many compilers that play cute optimization games that will break
7216 ## probes for standard functions such as pow().
7217 ##
7218
7219
7220 { $as_echo "$as_me:$LINENO: checking for main in -lm" >&5
7221 $as_echo_n "checking for main in -lm... " >&6; }
7222 if test "${ac_cv_lib_m_main+set}" = set; then
7223   $as_echo_n "(cached) " >&6
7224 else
7225   ac_check_lib_save_LIBS=$LIBS
7226 LIBS="-lm  $LIBS"
7227 cat >conftest.$ac_ext <<_ACEOF
7228 /* confdefs.h.  */
7229 _ACEOF
7230 cat confdefs.h >>conftest.$ac_ext
7231 cat >>conftest.$ac_ext <<_ACEOF
7232 /* end confdefs.h.  */
7233
7234
7235 int
7236 main ()
7237 {
7238 return main ();
7239   ;
7240   return 0;
7241 }
7242 _ACEOF
7243 rm -f conftest.$ac_objext conftest$ac_exeext
7244 if { (ac_try="$ac_link"
7245 case "(($ac_try" in
7246   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7247   *) ac_try_echo=$ac_try;;
7248 esac
7249 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7250 $as_echo "$ac_try_echo") >&5
7251   (eval "$ac_link") 2>conftest.er1
7252   ac_status=$?
7253   grep -v '^ *+' conftest.er1 >conftest.err
7254   rm -f conftest.er1
7255   cat conftest.err >&5
7256   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7257   (exit $ac_status); } && {
7258          test -z "$ac_c_werror_flag" ||
7259          test ! -s conftest.err
7260        } && test -s conftest$ac_exeext && {
7261          test "$cross_compiling" = yes ||
7262          $as_test_x conftest$ac_exeext
7263        }; then
7264   ac_cv_lib_m_main=yes
7265 else
7266   $as_echo "$as_me: failed program was:" >&5
7267 sed 's/^/| /' conftest.$ac_ext >&5
7268
7269         ac_cv_lib_m_main=no
7270 fi
7271
7272 rm -rf conftest.dSYM
7273 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7274       conftest$ac_exeext conftest.$ac_ext
7275 LIBS=$ac_check_lib_save_LIBS
7276 fi
7277 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_m_main" >&5
7278 $as_echo "$ac_cv_lib_m_main" >&6; }
7279 if test "x$ac_cv_lib_m_main" = x""yes; then
7280   cat >>confdefs.h <<_ACEOF
7281 #define HAVE_LIBM 1
7282 _ACEOF
7283
7284   LIBS="-lm $LIBS"
7285
7286 fi
7287
7288 { $as_echo "$as_me:$LINENO: checking for library containing setproctitle" >&5
7289 $as_echo_n "checking for library containing setproctitle... " >&6; }
7290 if test "${ac_cv_search_setproctitle+set}" = set; then
7291   $as_echo_n "(cached) " >&6
7292 else
7293   ac_func_search_save_LIBS=$LIBS
7294 cat >conftest.$ac_ext <<_ACEOF
7295 /* confdefs.h.  */
7296 _ACEOF
7297 cat confdefs.h >>conftest.$ac_ext
7298 cat >>conftest.$ac_ext <<_ACEOF
7299 /* end confdefs.h.  */
7300
7301 /* Override any GCC internal prototype to avoid an error.
7302    Use char because int might match the return type of a GCC
7303    builtin and then its argument prototype would still apply.  */
7304 #ifdef __cplusplus
7305 extern "C"
7306 #endif
7307 char setproctitle ();
7308 int
7309 main ()
7310 {
7311 return setproctitle ();
7312   ;
7313   return 0;
7314 }
7315 _ACEOF
7316 for ac_lib in '' util; do
7317   if test -z "$ac_lib"; then
7318     ac_res="none required"
7319   else
7320     ac_res=-l$ac_lib
7321     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7322   fi
7323   rm -f conftest.$ac_objext conftest$ac_exeext
7324 if { (ac_try="$ac_link"
7325 case "(($ac_try" in
7326   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7327   *) ac_try_echo=$ac_try;;
7328 esac
7329 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7330 $as_echo "$ac_try_echo") >&5
7331   (eval "$ac_link") 2>conftest.er1
7332   ac_status=$?
7333   grep -v '^ *+' conftest.er1 >conftest.err
7334   rm -f conftest.er1
7335   cat conftest.err >&5
7336   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7337   (exit $ac_status); } && {
7338          test -z "$ac_c_werror_flag" ||
7339          test ! -s conftest.err
7340        } && test -s conftest$ac_exeext && {
7341          test "$cross_compiling" = yes ||
7342          $as_test_x conftest$ac_exeext
7343        }; then
7344   ac_cv_search_setproctitle=$ac_res
7345 else
7346   $as_echo "$as_me: failed program was:" >&5
7347 sed 's/^/| /' conftest.$ac_ext >&5
7348
7349
7350 fi
7351
7352 rm -rf conftest.dSYM
7353 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7354       conftest$ac_exeext
7355   if test "${ac_cv_search_setproctitle+set}" = set; then
7356   break
7357 fi
7358 done
7359 if test "${ac_cv_search_setproctitle+set}" = set; then
7360   :
7361 else
7362   ac_cv_search_setproctitle=no
7363 fi
7364 rm conftest.$ac_ext
7365 LIBS=$ac_func_search_save_LIBS
7366 fi
7367 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_setproctitle" >&5
7368 $as_echo "$ac_cv_search_setproctitle" >&6; }
7369 ac_res=$ac_cv_search_setproctitle
7370 if test "$ac_res" != no; then
7371   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7372
7373 fi
7374
7375 { $as_echo "$as_me:$LINENO: checking for library containing dlopen" >&5
7376 $as_echo_n "checking for library containing dlopen... " >&6; }
7377 if test "${ac_cv_search_dlopen+set}" = set; then
7378   $as_echo_n "(cached) " >&6
7379 else
7380   ac_func_search_save_LIBS=$LIBS
7381 cat >conftest.$ac_ext <<_ACEOF
7382 /* confdefs.h.  */
7383 _ACEOF
7384 cat confdefs.h >>conftest.$ac_ext
7385 cat >>conftest.$ac_ext <<_ACEOF
7386 /* end confdefs.h.  */
7387
7388 /* Override any GCC internal prototype to avoid an error.
7389    Use char because int might match the return type of a GCC
7390    builtin and then its argument prototype would still apply.  */
7391 #ifdef __cplusplus
7392 extern "C"
7393 #endif
7394 char dlopen ();
7395 int
7396 main ()
7397 {
7398 return dlopen ();
7399   ;
7400   return 0;
7401 }
7402 _ACEOF
7403 for ac_lib in '' dl; do
7404   if test -z "$ac_lib"; then
7405     ac_res="none required"
7406   else
7407     ac_res=-l$ac_lib
7408     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7409   fi
7410   rm -f conftest.$ac_objext conftest$ac_exeext
7411 if { (ac_try="$ac_link"
7412 case "(($ac_try" in
7413   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7414   *) ac_try_echo=$ac_try;;
7415 esac
7416 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7417 $as_echo "$ac_try_echo") >&5
7418   (eval "$ac_link") 2>conftest.er1
7419   ac_status=$?
7420   grep -v '^ *+' conftest.er1 >conftest.err
7421   rm -f conftest.er1
7422   cat conftest.err >&5
7423   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7424   (exit $ac_status); } && {
7425          test -z "$ac_c_werror_flag" ||
7426          test ! -s conftest.err
7427        } && test -s conftest$ac_exeext && {
7428          test "$cross_compiling" = yes ||
7429          $as_test_x conftest$ac_exeext
7430        }; then
7431   ac_cv_search_dlopen=$ac_res
7432 else
7433   $as_echo "$as_me: failed program was:" >&5
7434 sed 's/^/| /' conftest.$ac_ext >&5
7435
7436
7437 fi
7438
7439 rm -rf conftest.dSYM
7440 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7441       conftest$ac_exeext
7442   if test "${ac_cv_search_dlopen+set}" = set; then
7443   break
7444 fi
7445 done
7446 if test "${ac_cv_search_dlopen+set}" = set; then
7447   :
7448 else
7449   ac_cv_search_dlopen=no
7450 fi
7451 rm conftest.$ac_ext
7452 LIBS=$ac_func_search_save_LIBS
7453 fi
7454 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5
7455 $as_echo "$ac_cv_search_dlopen" >&6; }
7456 ac_res=$ac_cv_search_dlopen
7457 if test "$ac_res" != no; then
7458   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7459
7460 fi
7461
7462 { $as_echo "$as_me:$LINENO: checking for library containing socket" >&5
7463 $as_echo_n "checking for library containing socket... " >&6; }
7464 if test "${ac_cv_search_socket+set}" = set; then
7465   $as_echo_n "(cached) " >&6
7466 else
7467   ac_func_search_save_LIBS=$LIBS
7468 cat >conftest.$ac_ext <<_ACEOF
7469 /* confdefs.h.  */
7470 _ACEOF
7471 cat confdefs.h >>conftest.$ac_ext
7472 cat >>conftest.$ac_ext <<_ACEOF
7473 /* end confdefs.h.  */
7474
7475 /* Override any GCC internal prototype to avoid an error.
7476    Use char because int might match the return type of a GCC
7477    builtin and then its argument prototype would still apply.  */
7478 #ifdef __cplusplus
7479 extern "C"
7480 #endif
7481 char socket ();
7482 int
7483 main ()
7484 {
7485 return socket ();
7486   ;
7487   return 0;
7488 }
7489 _ACEOF
7490 for ac_lib in '' socket wsock32; do
7491   if test -z "$ac_lib"; then
7492     ac_res="none required"
7493   else
7494     ac_res=-l$ac_lib
7495     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7496   fi
7497   rm -f conftest.$ac_objext conftest$ac_exeext
7498 if { (ac_try="$ac_link"
7499 case "(($ac_try" in
7500   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7501   *) ac_try_echo=$ac_try;;
7502 esac
7503 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7504 $as_echo "$ac_try_echo") >&5
7505   (eval "$ac_link") 2>conftest.er1
7506   ac_status=$?
7507   grep -v '^ *+' conftest.er1 >conftest.err
7508   rm -f conftest.er1
7509   cat conftest.err >&5
7510   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7511   (exit $ac_status); } && {
7512          test -z "$ac_c_werror_flag" ||
7513          test ! -s conftest.err
7514        } && test -s conftest$ac_exeext && {
7515          test "$cross_compiling" = yes ||
7516          $as_test_x conftest$ac_exeext
7517        }; then
7518   ac_cv_search_socket=$ac_res
7519 else
7520   $as_echo "$as_me: failed program was:" >&5
7521 sed 's/^/| /' conftest.$ac_ext >&5
7522
7523
7524 fi
7525
7526 rm -rf conftest.dSYM
7527 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7528       conftest$ac_exeext
7529   if test "${ac_cv_search_socket+set}" = set; then
7530   break
7531 fi
7532 done
7533 if test "${ac_cv_search_socket+set}" = set; then
7534   :
7535 else
7536   ac_cv_search_socket=no
7537 fi
7538 rm conftest.$ac_ext
7539 LIBS=$ac_func_search_save_LIBS
7540 fi
7541 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_socket" >&5
7542 $as_echo "$ac_cv_search_socket" >&6; }
7543 ac_res=$ac_cv_search_socket
7544 if test "$ac_res" != no; then
7545   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7546
7547 fi
7548
7549 { $as_echo "$as_me:$LINENO: checking for library containing shl_load" >&5
7550 $as_echo_n "checking for library containing shl_load... " >&6; }
7551 if test "${ac_cv_search_shl_load+set}" = set; then
7552   $as_echo_n "(cached) " >&6
7553 else
7554   ac_func_search_save_LIBS=$LIBS
7555 cat >conftest.$ac_ext <<_ACEOF
7556 /* confdefs.h.  */
7557 _ACEOF
7558 cat confdefs.h >>conftest.$ac_ext
7559 cat >>conftest.$ac_ext <<_ACEOF
7560 /* end confdefs.h.  */
7561
7562 /* Override any GCC internal prototype to avoid an error.
7563    Use char because int might match the return type of a GCC
7564    builtin and then its argument prototype would still apply.  */
7565 #ifdef __cplusplus
7566 extern "C"
7567 #endif
7568 char shl_load ();
7569 int
7570 main ()
7571 {
7572 return shl_load ();
7573   ;
7574   return 0;
7575 }
7576 _ACEOF
7577 for ac_lib in '' dld; do
7578   if test -z "$ac_lib"; then
7579     ac_res="none required"
7580   else
7581     ac_res=-l$ac_lib
7582     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7583   fi
7584   rm -f conftest.$ac_objext conftest$ac_exeext
7585 if { (ac_try="$ac_link"
7586 case "(($ac_try" in
7587   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7588   *) ac_try_echo=$ac_try;;
7589 esac
7590 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7591 $as_echo "$ac_try_echo") >&5
7592   (eval "$ac_link") 2>conftest.er1
7593   ac_status=$?
7594   grep -v '^ *+' conftest.er1 >conftest.err
7595   rm -f conftest.er1
7596   cat conftest.err >&5
7597   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7598   (exit $ac_status); } && {
7599          test -z "$ac_c_werror_flag" ||
7600          test ! -s conftest.err
7601        } && test -s conftest$ac_exeext && {
7602          test "$cross_compiling" = yes ||
7603          $as_test_x conftest$ac_exeext
7604        }; then
7605   ac_cv_search_shl_load=$ac_res
7606 else
7607   $as_echo "$as_me: failed program was:" >&5
7608 sed 's/^/| /' conftest.$ac_ext >&5
7609
7610
7611 fi
7612
7613 rm -rf conftest.dSYM
7614 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7615       conftest$ac_exeext
7616   if test "${ac_cv_search_shl_load+set}" = set; then
7617   break
7618 fi
7619 done
7620 if test "${ac_cv_search_shl_load+set}" = set; then
7621   :
7622 else
7623   ac_cv_search_shl_load=no
7624 fi
7625 rm conftest.$ac_ext
7626 LIBS=$ac_func_search_save_LIBS
7627 fi
7628 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shl_load" >&5
7629 $as_echo "$ac_cv_search_shl_load" >&6; }
7630 ac_res=$ac_cv_search_shl_load
7631 if test "$ac_res" != no; then
7632   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7633
7634 fi
7635
7636 # We only use libld in port/dynloader/aix.c
7637 case $host_os in
7638      aix*)
7639         { $as_echo "$as_me:$LINENO: checking for library containing ldopen" >&5
7640 $as_echo_n "checking for library containing ldopen... " >&6; }
7641 if test "${ac_cv_search_ldopen+set}" = set; then
7642   $as_echo_n "(cached) " >&6
7643 else
7644   ac_func_search_save_LIBS=$LIBS
7645 cat >conftest.$ac_ext <<_ACEOF
7646 /* confdefs.h.  */
7647 _ACEOF
7648 cat confdefs.h >>conftest.$ac_ext
7649 cat >>conftest.$ac_ext <<_ACEOF
7650 /* end confdefs.h.  */
7651
7652 /* Override any GCC internal prototype to avoid an error.
7653    Use char because int might match the return type of a GCC
7654    builtin and then its argument prototype would still apply.  */
7655 #ifdef __cplusplus
7656 extern "C"
7657 #endif
7658 char ldopen ();
7659 int
7660 main ()
7661 {
7662 return ldopen ();
7663   ;
7664   return 0;
7665 }
7666 _ACEOF
7667 for ac_lib in '' ld; do
7668   if test -z "$ac_lib"; then
7669     ac_res="none required"
7670   else
7671     ac_res=-l$ac_lib
7672     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7673   fi
7674   rm -f conftest.$ac_objext conftest$ac_exeext
7675 if { (ac_try="$ac_link"
7676 case "(($ac_try" in
7677   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7678   *) ac_try_echo=$ac_try;;
7679 esac
7680 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7681 $as_echo "$ac_try_echo") >&5
7682   (eval "$ac_link") 2>conftest.er1
7683   ac_status=$?
7684   grep -v '^ *+' conftest.er1 >conftest.err
7685   rm -f conftest.er1
7686   cat conftest.err >&5
7687   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7688   (exit $ac_status); } && {
7689          test -z "$ac_c_werror_flag" ||
7690          test ! -s conftest.err
7691        } && test -s conftest$ac_exeext && {
7692          test "$cross_compiling" = yes ||
7693          $as_test_x conftest$ac_exeext
7694        }; then
7695   ac_cv_search_ldopen=$ac_res
7696 else
7697   $as_echo "$as_me: failed program was:" >&5
7698 sed 's/^/| /' conftest.$ac_ext >&5
7699
7700
7701 fi
7702
7703 rm -rf conftest.dSYM
7704 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7705       conftest$ac_exeext
7706   if test "${ac_cv_search_ldopen+set}" = set; then
7707   break
7708 fi
7709 done
7710 if test "${ac_cv_search_ldopen+set}" = set; then
7711   :
7712 else
7713   ac_cv_search_ldopen=no
7714 fi
7715 rm conftest.$ac_ext
7716 LIBS=$ac_func_search_save_LIBS
7717 fi
7718 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_ldopen" >&5
7719 $as_echo "$ac_cv_search_ldopen" >&6; }
7720 ac_res=$ac_cv_search_ldopen
7721 if test "$ac_res" != no; then
7722   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7723
7724 fi
7725
7726         ;;
7727 esac
7728 { $as_echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
7729 $as_echo_n "checking for library containing getopt_long... " >&6; }
7730 if test "${ac_cv_search_getopt_long+set}" = set; then
7731   $as_echo_n "(cached) " >&6
7732 else
7733   ac_func_search_save_LIBS=$LIBS
7734 cat >conftest.$ac_ext <<_ACEOF
7735 /* confdefs.h.  */
7736 _ACEOF
7737 cat confdefs.h >>conftest.$ac_ext
7738 cat >>conftest.$ac_ext <<_ACEOF
7739 /* end confdefs.h.  */
7740
7741 /* Override any GCC internal prototype to avoid an error.
7742    Use char because int might match the return type of a GCC
7743    builtin and then its argument prototype would still apply.  */
7744 #ifdef __cplusplus
7745 extern "C"
7746 #endif
7747 char getopt_long ();
7748 int
7749 main ()
7750 {
7751 return getopt_long ();
7752   ;
7753   return 0;
7754 }
7755 _ACEOF
7756 for ac_lib in '' getopt gnugetopt; do
7757   if test -z "$ac_lib"; then
7758     ac_res="none required"
7759   else
7760     ac_res=-l$ac_lib
7761     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7762   fi
7763   rm -f conftest.$ac_objext conftest$ac_exeext
7764 if { (ac_try="$ac_link"
7765 case "(($ac_try" in
7766   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7767   *) ac_try_echo=$ac_try;;
7768 esac
7769 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7770 $as_echo "$ac_try_echo") >&5
7771   (eval "$ac_link") 2>conftest.er1
7772   ac_status=$?
7773   grep -v '^ *+' conftest.er1 >conftest.err
7774   rm -f conftest.er1
7775   cat conftest.err >&5
7776   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7777   (exit $ac_status); } && {
7778          test -z "$ac_c_werror_flag" ||
7779          test ! -s conftest.err
7780        } && test -s conftest$ac_exeext && {
7781          test "$cross_compiling" = yes ||
7782          $as_test_x conftest$ac_exeext
7783        }; then
7784   ac_cv_search_getopt_long=$ac_res
7785 else
7786   $as_echo "$as_me: failed program was:" >&5
7787 sed 's/^/| /' conftest.$ac_ext >&5
7788
7789
7790 fi
7791
7792 rm -rf conftest.dSYM
7793 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7794       conftest$ac_exeext
7795   if test "${ac_cv_search_getopt_long+set}" = set; then
7796   break
7797 fi
7798 done
7799 if test "${ac_cv_search_getopt_long+set}" = set; then
7800   :
7801 else
7802   ac_cv_search_getopt_long=no
7803 fi
7804 rm conftest.$ac_ext
7805 LIBS=$ac_func_search_save_LIBS
7806 fi
7807 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
7808 $as_echo "$ac_cv_search_getopt_long" >&6; }
7809 ac_res=$ac_cv_search_getopt_long
7810 if test "$ac_res" != no; then
7811   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7812
7813 fi
7814
7815 { $as_echo "$as_me:$LINENO: checking for library containing crypt" >&5
7816 $as_echo_n "checking for library containing crypt... " >&6; }
7817 if test "${ac_cv_search_crypt+set}" = set; then
7818   $as_echo_n "(cached) " >&6
7819 else
7820   ac_func_search_save_LIBS=$LIBS
7821 cat >conftest.$ac_ext <<_ACEOF
7822 /* confdefs.h.  */
7823 _ACEOF
7824 cat confdefs.h >>conftest.$ac_ext
7825 cat >>conftest.$ac_ext <<_ACEOF
7826 /* end confdefs.h.  */
7827
7828 /* Override any GCC internal prototype to avoid an error.
7829    Use char because int might match the return type of a GCC
7830    builtin and then its argument prototype would still apply.  */
7831 #ifdef __cplusplus
7832 extern "C"
7833 #endif
7834 char crypt ();
7835 int
7836 main ()
7837 {
7838 return crypt ();
7839   ;
7840   return 0;
7841 }
7842 _ACEOF
7843 for ac_lib in '' crypt; do
7844   if test -z "$ac_lib"; then
7845     ac_res="none required"
7846   else
7847     ac_res=-l$ac_lib
7848     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7849   fi
7850   rm -f conftest.$ac_objext conftest$ac_exeext
7851 if { (ac_try="$ac_link"
7852 case "(($ac_try" in
7853   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7854   *) ac_try_echo=$ac_try;;
7855 esac
7856 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7857 $as_echo "$ac_try_echo") >&5
7858   (eval "$ac_link") 2>conftest.er1
7859   ac_status=$?
7860   grep -v '^ *+' conftest.er1 >conftest.err
7861   rm -f conftest.er1
7862   cat conftest.err >&5
7863   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7864   (exit $ac_status); } && {
7865          test -z "$ac_c_werror_flag" ||
7866          test ! -s conftest.err
7867        } && test -s conftest$ac_exeext && {
7868          test "$cross_compiling" = yes ||
7869          $as_test_x conftest$ac_exeext
7870        }; then
7871   ac_cv_search_crypt=$ac_res
7872 else
7873   $as_echo "$as_me: failed program was:" >&5
7874 sed 's/^/| /' conftest.$ac_ext >&5
7875
7876
7877 fi
7878
7879 rm -rf conftest.dSYM
7880 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7881       conftest$ac_exeext
7882   if test "${ac_cv_search_crypt+set}" = set; then
7883   break
7884 fi
7885 done
7886 if test "${ac_cv_search_crypt+set}" = set; then
7887   :
7888 else
7889   ac_cv_search_crypt=no
7890 fi
7891 rm conftest.$ac_ext
7892 LIBS=$ac_func_search_save_LIBS
7893 fi
7894 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
7895 $as_echo "$ac_cv_search_crypt" >&6; }
7896 ac_res=$ac_cv_search_crypt
7897 if test "$ac_res" != no; then
7898   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7899
7900 fi
7901
7902 # Solaris:
7903 { $as_echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
7904 $as_echo_n "checking for library containing fdatasync... " >&6; }
7905 if test "${ac_cv_search_fdatasync+set}" = set; then
7906   $as_echo_n "(cached) " >&6
7907 else
7908   ac_func_search_save_LIBS=$LIBS
7909 cat >conftest.$ac_ext <<_ACEOF
7910 /* confdefs.h.  */
7911 _ACEOF
7912 cat confdefs.h >>conftest.$ac_ext
7913 cat >>conftest.$ac_ext <<_ACEOF
7914 /* end confdefs.h.  */
7915
7916 /* Override any GCC internal prototype to avoid an error.
7917    Use char because int might match the return type of a GCC
7918    builtin and then its argument prototype would still apply.  */
7919 #ifdef __cplusplus
7920 extern "C"
7921 #endif
7922 char fdatasync ();
7923 int
7924 main ()
7925 {
7926 return fdatasync ();
7927   ;
7928   return 0;
7929 }
7930 _ACEOF
7931 for ac_lib in '' rt posix4; do
7932   if test -z "$ac_lib"; then
7933     ac_res="none required"
7934   else
7935     ac_res=-l$ac_lib
7936     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7937   fi
7938   rm -f conftest.$ac_objext conftest$ac_exeext
7939 if { (ac_try="$ac_link"
7940 case "(($ac_try" in
7941   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7942   *) ac_try_echo=$ac_try;;
7943 esac
7944 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7945 $as_echo "$ac_try_echo") >&5
7946   (eval "$ac_link") 2>conftest.er1
7947   ac_status=$?
7948   grep -v '^ *+' conftest.er1 >conftest.err
7949   rm -f conftest.er1
7950   cat conftest.err >&5
7951   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7952   (exit $ac_status); } && {
7953          test -z "$ac_c_werror_flag" ||
7954          test ! -s conftest.err
7955        } && test -s conftest$ac_exeext && {
7956          test "$cross_compiling" = yes ||
7957          $as_test_x conftest$ac_exeext
7958        }; then
7959   ac_cv_search_fdatasync=$ac_res
7960 else
7961   $as_echo "$as_me: failed program was:" >&5
7962 sed 's/^/| /' conftest.$ac_ext >&5
7963
7964
7965 fi
7966
7967 rm -rf conftest.dSYM
7968 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7969       conftest$ac_exeext
7970   if test "${ac_cv_search_fdatasync+set}" = set; then
7971   break
7972 fi
7973 done
7974 if test "${ac_cv_search_fdatasync+set}" = set; then
7975   :
7976 else
7977   ac_cv_search_fdatasync=no
7978 fi
7979 rm conftest.$ac_ext
7980 LIBS=$ac_func_search_save_LIBS
7981 fi
7982 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
7983 $as_echo "$ac_cv_search_fdatasync" >&6; }
7984 ac_res=$ac_cv_search_fdatasync
7985 if test "$ac_res" != no; then
7986   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7987
7988 fi
7989
7990 # Required for thread_test.c on Solaris 2.5:
7991 # Other ports use it too (HP-UX) so test unconditionally
7992 { $as_echo "$as_me:$LINENO: checking for library containing gethostbyname_r" >&5
7993 $as_echo_n "checking for library containing gethostbyname_r... " >&6; }
7994 if test "${ac_cv_search_gethostbyname_r+set}" = set; then
7995   $as_echo_n "(cached) " >&6
7996 else
7997   ac_func_search_save_LIBS=$LIBS
7998 cat >conftest.$ac_ext <<_ACEOF
7999 /* confdefs.h.  */
8000 _ACEOF
8001 cat confdefs.h >>conftest.$ac_ext
8002 cat >>conftest.$ac_ext <<_ACEOF
8003 /* end confdefs.h.  */
8004
8005 /* Override any GCC internal prototype to avoid an error.
8006    Use char because int might match the return type of a GCC
8007    builtin and then its argument prototype would still apply.  */
8008 #ifdef __cplusplus
8009 extern "C"
8010 #endif
8011 char gethostbyname_r ();
8012 int
8013 main ()
8014 {
8015 return gethostbyname_r ();
8016   ;
8017   return 0;
8018 }
8019 _ACEOF
8020 for ac_lib in '' nsl; do
8021   if test -z "$ac_lib"; then
8022     ac_res="none required"
8023   else
8024     ac_res=-l$ac_lib
8025     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8026   fi
8027   rm -f conftest.$ac_objext conftest$ac_exeext
8028 if { (ac_try="$ac_link"
8029 case "(($ac_try" in
8030   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8031   *) ac_try_echo=$ac_try;;
8032 esac
8033 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8034 $as_echo "$ac_try_echo") >&5
8035   (eval "$ac_link") 2>conftest.er1
8036   ac_status=$?
8037   grep -v '^ *+' conftest.er1 >conftest.err
8038   rm -f conftest.er1
8039   cat conftest.err >&5
8040   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8041   (exit $ac_status); } && {
8042          test -z "$ac_c_werror_flag" ||
8043          test ! -s conftest.err
8044        } && test -s conftest$ac_exeext && {
8045          test "$cross_compiling" = yes ||
8046          $as_test_x conftest$ac_exeext
8047        }; then
8048   ac_cv_search_gethostbyname_r=$ac_res
8049 else
8050   $as_echo "$as_me: failed program was:" >&5
8051 sed 's/^/| /' conftest.$ac_ext >&5
8052
8053
8054 fi
8055
8056 rm -rf conftest.dSYM
8057 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8058       conftest$ac_exeext
8059   if test "${ac_cv_search_gethostbyname_r+set}" = set; then
8060   break
8061 fi
8062 done
8063 if test "${ac_cv_search_gethostbyname_r+set}" = set; then
8064   :
8065 else
8066   ac_cv_search_gethostbyname_r=no
8067 fi
8068 rm conftest.$ac_ext
8069 LIBS=$ac_func_search_save_LIBS
8070 fi
8071 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_gethostbyname_r" >&5
8072 $as_echo "$ac_cv_search_gethostbyname_r" >&6; }
8073 ac_res=$ac_cv_search_gethostbyname_r
8074 if test "$ac_res" != no; then
8075   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8076
8077 fi
8078
8079 # Cygwin:
8080 { $as_echo "$as_me:$LINENO: checking for library containing shmget" >&5
8081 $as_echo_n "checking for library containing shmget... " >&6; }
8082 if test "${ac_cv_search_shmget+set}" = set; then
8083   $as_echo_n "(cached) " >&6
8084 else
8085   ac_func_search_save_LIBS=$LIBS
8086 cat >conftest.$ac_ext <<_ACEOF
8087 /* confdefs.h.  */
8088 _ACEOF
8089 cat confdefs.h >>conftest.$ac_ext
8090 cat >>conftest.$ac_ext <<_ACEOF
8091 /* end confdefs.h.  */
8092
8093 /* Override any GCC internal prototype to avoid an error.
8094    Use char because int might match the return type of a GCC
8095    builtin and then its argument prototype would still apply.  */
8096 #ifdef __cplusplus
8097 extern "C"
8098 #endif
8099 char shmget ();
8100 int
8101 main ()
8102 {
8103 return shmget ();
8104   ;
8105   return 0;
8106 }
8107 _ACEOF
8108 for ac_lib in '' cygipc; do
8109   if test -z "$ac_lib"; then
8110     ac_res="none required"
8111   else
8112     ac_res=-l$ac_lib
8113     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8114   fi
8115   rm -f conftest.$ac_objext conftest$ac_exeext
8116 if { (ac_try="$ac_link"
8117 case "(($ac_try" in
8118   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8119   *) ac_try_echo=$ac_try;;
8120 esac
8121 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8122 $as_echo "$ac_try_echo") >&5
8123   (eval "$ac_link") 2>conftest.er1
8124   ac_status=$?
8125   grep -v '^ *+' conftest.er1 >conftest.err
8126   rm -f conftest.er1
8127   cat conftest.err >&5
8128   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8129   (exit $ac_status); } && {
8130          test -z "$ac_c_werror_flag" ||
8131          test ! -s conftest.err
8132        } && test -s conftest$ac_exeext && {
8133          test "$cross_compiling" = yes ||
8134          $as_test_x conftest$ac_exeext
8135        }; then
8136   ac_cv_search_shmget=$ac_res
8137 else
8138   $as_echo "$as_me: failed program was:" >&5
8139 sed 's/^/| /' conftest.$ac_ext >&5
8140
8141
8142 fi
8143
8144 rm -rf conftest.dSYM
8145 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8146       conftest$ac_exeext
8147   if test "${ac_cv_search_shmget+set}" = set; then
8148   break
8149 fi
8150 done
8151 if test "${ac_cv_search_shmget+set}" = set; then
8152   :
8153 else
8154   ac_cv_search_shmget=no
8155 fi
8156 rm conftest.$ac_ext
8157 LIBS=$ac_func_search_save_LIBS
8158 fi
8159 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shmget" >&5
8160 $as_echo "$ac_cv_search_shmget" >&6; }
8161 ac_res=$ac_cv_search_shmget
8162 if test "$ac_res" != no; then
8163   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8164
8165 fi
8166
8167
8168 if test "$with_readline" = yes; then
8169
8170
8171 { $as_echo "$as_me:$LINENO: checking for library containing readline" >&5
8172 $as_echo_n "checking for library containing readline... " >&6; }
8173 if test "${pgac_cv_check_readline+set}" = set; then
8174   $as_echo_n "(cached) " >&6
8175 else
8176   pgac_cv_check_readline=no
8177 pgac_save_LIBS=$LIBS
8178 if test x"$with_libedit_preferred" != x"yes"
8179 then    READLINE_ORDER="-lreadline -ledit"
8180 else    READLINE_ORDER="-ledit -lreadline"
8181 fi
8182 for pgac_rllib in $READLINE_ORDER ; do
8183   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
8184     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
8185     cat >conftest.$ac_ext <<_ACEOF
8186 /* confdefs.h.  */
8187 _ACEOF
8188 cat confdefs.h >>conftest.$ac_ext
8189 cat >>conftest.$ac_ext <<_ACEOF
8190 /* end confdefs.h.  */
8191
8192 /* Override any GCC internal prototype to avoid an error.
8193    Use char because int might match the return type of a GCC
8194    builtin and then its argument prototype would still apply.  */
8195 #ifdef __cplusplus
8196 extern "C"
8197 #endif
8198 char readline ();
8199 int
8200 main ()
8201 {
8202 return readline ();
8203   ;
8204   return 0;
8205 }
8206 _ACEOF
8207 rm -f conftest.$ac_objext conftest$ac_exeext
8208 if { (ac_try="$ac_link"
8209 case "(($ac_try" in
8210   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8211   *) ac_try_echo=$ac_try;;
8212 esac
8213 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8214 $as_echo "$ac_try_echo") >&5
8215   (eval "$ac_link") 2>conftest.er1
8216   ac_status=$?
8217   grep -v '^ *+' conftest.er1 >conftest.err
8218   rm -f conftest.er1
8219   cat conftest.err >&5
8220   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8221   (exit $ac_status); } && {
8222          test -z "$ac_c_werror_flag" ||
8223          test ! -s conftest.err
8224        } && test -s conftest$ac_exeext && {
8225          test "$cross_compiling" = yes ||
8226          $as_test_x conftest$ac_exeext
8227        }; then
8228
8229       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
8230       # recognize dependent libraries; assume curses is needed if we didn't
8231       # find any dependency.
8232       case $host_os in
8233         netbsd* | openbsd* | irix*)
8234           if test x"$pgac_lib" = x"" ; then
8235             pgac_lib=" -lcurses"
8236           fi ;;
8237       esac
8238
8239       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
8240       break
8241
8242 else
8243   $as_echo "$as_me: failed program was:" >&5
8244 sed 's/^/| /' conftest.$ac_ext >&5
8245
8246
8247 fi
8248
8249 rm -rf conftest.dSYM
8250 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8251       conftest$ac_exeext conftest.$ac_ext
8252   done
8253   if test "$pgac_cv_check_readline" != no ; then
8254     break
8255   fi
8256 done
8257 LIBS=$pgac_save_LIBS
8258
8259 fi
8260 { $as_echo "$as_me:$LINENO: result: $pgac_cv_check_readline" >&5
8261 $as_echo "$pgac_cv_check_readline" >&6; }
8262 if test "$pgac_cv_check_readline" != no ; then
8263   LIBS="$pgac_cv_check_readline $LIBS"
8264
8265 cat >>confdefs.h <<\_ACEOF
8266 #define HAVE_LIBREADLINE 1
8267 _ACEOF
8268
8269 fi
8270
8271
8272   if test x"$pgac_cv_check_readline" = x"no"; then
8273     { { $as_echo "$as_me:$LINENO: error: readline library not found
8274 If you have readline already installed, see config.log for details on the
8275 failure.  It is possible the compiler isn't looking in the proper directory.
8276 Use --without-readline to disable readline support." >&5
8277 $as_echo "$as_me: error: readline library not found
8278 If you have readline already installed, see config.log for details on the
8279 failure.  It is possible the compiler isn't looking in the proper directory.
8280 Use --without-readline to disable readline support." >&2;}
8281    { (exit 1); exit 1; }; }
8282   fi
8283 fi
8284
8285 if test "$with_zlib" = yes; then
8286
8287 { $as_echo "$as_me:$LINENO: checking for inflate in -lz" >&5
8288 $as_echo_n "checking for inflate in -lz... " >&6; }
8289 if test "${ac_cv_lib_z_inflate+set}" = set; then
8290   $as_echo_n "(cached) " >&6
8291 else
8292   ac_check_lib_save_LIBS=$LIBS
8293 LIBS="-lz  $LIBS"
8294 cat >conftest.$ac_ext <<_ACEOF
8295 /* confdefs.h.  */
8296 _ACEOF
8297 cat confdefs.h >>conftest.$ac_ext
8298 cat >>conftest.$ac_ext <<_ACEOF
8299 /* end confdefs.h.  */
8300
8301 /* Override any GCC internal prototype to avoid an error.
8302    Use char because int might match the return type of a GCC
8303    builtin and then its argument prototype would still apply.  */
8304 #ifdef __cplusplus
8305 extern "C"
8306 #endif
8307 char inflate ();
8308 int
8309 main ()
8310 {
8311 return inflate ();
8312   ;
8313   return 0;
8314 }
8315 _ACEOF
8316 rm -f conftest.$ac_objext conftest$ac_exeext
8317 if { (ac_try="$ac_link"
8318 case "(($ac_try" in
8319   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8320   *) ac_try_echo=$ac_try;;
8321 esac
8322 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8323 $as_echo "$ac_try_echo") >&5
8324   (eval "$ac_link") 2>conftest.er1
8325   ac_status=$?
8326   grep -v '^ *+' conftest.er1 >conftest.err
8327   rm -f conftest.er1
8328   cat conftest.err >&5
8329   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8330   (exit $ac_status); } && {
8331          test -z "$ac_c_werror_flag" ||
8332          test ! -s conftest.err
8333        } && test -s conftest$ac_exeext && {
8334          test "$cross_compiling" = yes ||
8335          $as_test_x conftest$ac_exeext
8336        }; then
8337   ac_cv_lib_z_inflate=yes
8338 else
8339   $as_echo "$as_me: failed program was:" >&5
8340 sed 's/^/| /' conftest.$ac_ext >&5
8341
8342         ac_cv_lib_z_inflate=no
8343 fi
8344
8345 rm -rf conftest.dSYM
8346 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8347       conftest$ac_exeext conftest.$ac_ext
8348 LIBS=$ac_check_lib_save_LIBS
8349 fi
8350 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
8351 $as_echo "$ac_cv_lib_z_inflate" >&6; }
8352 if test "x$ac_cv_lib_z_inflate" = x""yes; then
8353   cat >>confdefs.h <<_ACEOF
8354 #define HAVE_LIBZ 1
8355 _ACEOF
8356
8357   LIBS="-lz $LIBS"
8358
8359 else
8360   { { $as_echo "$as_me:$LINENO: error: zlib library not found
8361 If you have zlib already installed, see config.log for details on the
8362 failure.  It is possible the compiler isn't looking in the proper directory.
8363 Use --without-zlib to disable zlib support." >&5
8364 $as_echo "$as_me: error: zlib library not found
8365 If you have zlib already installed, see config.log for details on the
8366 failure.  It is possible the compiler isn't looking in the proper directory.
8367 Use --without-zlib to disable zlib support." >&2;}
8368    { (exit 1); exit 1; }; }
8369 fi
8370
8371 fi
8372
8373 if test "$enable_spinlocks" = yes; then
8374
8375 cat >>confdefs.h <<\_ACEOF
8376 #define HAVE_SPINLOCKS 1
8377 _ACEOF
8378
8379 else
8380   { $as_echo "$as_me:$LINENO: WARNING:
8381 *** Not using spinlocks will cause poor performance." >&5
8382 $as_echo "$as_me: WARNING:
8383 *** Not using spinlocks will cause poor performance." >&2;}
8384 fi
8385
8386 if test "$with_gssapi" = yes ; then
8387   if test "$PORTNAME" != "win32"; then
8388     { $as_echo "$as_me:$LINENO: checking for library containing gss_init_sec_context" >&5
8389 $as_echo_n "checking for library containing gss_init_sec_context... " >&6; }
8390 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8391   $as_echo_n "(cached) " >&6
8392 else
8393   ac_func_search_save_LIBS=$LIBS
8394 cat >conftest.$ac_ext <<_ACEOF
8395 /* confdefs.h.  */
8396 _ACEOF
8397 cat confdefs.h >>conftest.$ac_ext
8398 cat >>conftest.$ac_ext <<_ACEOF
8399 /* end confdefs.h.  */
8400
8401 /* Override any GCC internal prototype to avoid an error.
8402    Use char because int might match the return type of a GCC
8403    builtin and then its argument prototype would still apply.  */
8404 #ifdef __cplusplus
8405 extern "C"
8406 #endif
8407 char gss_init_sec_context ();
8408 int
8409 main ()
8410 {
8411 return gss_init_sec_context ();
8412   ;
8413   return 0;
8414 }
8415 _ACEOF
8416 for ac_lib in '' gssapi_krb5 gss 'gssapi -lkrb5 -lcrypto'; do
8417   if test -z "$ac_lib"; then
8418     ac_res="none required"
8419   else
8420     ac_res=-l$ac_lib
8421     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8422   fi
8423   rm -f conftest.$ac_objext conftest$ac_exeext
8424 if { (ac_try="$ac_link"
8425 case "(($ac_try" in
8426   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8427   *) ac_try_echo=$ac_try;;
8428 esac
8429 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8430 $as_echo "$ac_try_echo") >&5
8431   (eval "$ac_link") 2>conftest.er1
8432   ac_status=$?
8433   grep -v '^ *+' conftest.er1 >conftest.err
8434   rm -f conftest.er1
8435   cat conftest.err >&5
8436   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8437   (exit $ac_status); } && {
8438          test -z "$ac_c_werror_flag" ||
8439          test ! -s conftest.err
8440        } && test -s conftest$ac_exeext && {
8441          test "$cross_compiling" = yes ||
8442          $as_test_x conftest$ac_exeext
8443        }; then
8444   ac_cv_search_gss_init_sec_context=$ac_res
8445 else
8446   $as_echo "$as_me: failed program was:" >&5
8447 sed 's/^/| /' conftest.$ac_ext >&5
8448
8449
8450 fi
8451
8452 rm -rf conftest.dSYM
8453 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8454       conftest$ac_exeext
8455   if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8456   break
8457 fi
8458 done
8459 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8460   :
8461 else
8462   ac_cv_search_gss_init_sec_context=no
8463 fi
8464 rm conftest.$ac_ext
8465 LIBS=$ac_func_search_save_LIBS
8466 fi
8467 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_gss_init_sec_context" >&5
8468 $as_echo "$ac_cv_search_gss_init_sec_context" >&6; }
8469 ac_res=$ac_cv_search_gss_init_sec_context
8470 if test "$ac_res" != no; then
8471   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8472
8473 else
8474   { { $as_echo "$as_me:$LINENO: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&5
8475 $as_echo "$as_me: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&2;}
8476    { (exit 1); exit 1; }; }
8477 fi
8478
8479   else
8480     LIBS="$LIBS -lgssapi32"
8481   fi
8482 fi
8483
8484 if test "$with_krb5" = yes ; then
8485   if test "$PORTNAME" != "win32"; then
8486      { $as_echo "$as_me:$LINENO: checking for library containing com_err" >&5
8487 $as_echo_n "checking for library containing com_err... " >&6; }
8488 if test "${ac_cv_search_com_err+set}" = set; then
8489   $as_echo_n "(cached) " >&6
8490 else
8491   ac_func_search_save_LIBS=$LIBS
8492 cat >conftest.$ac_ext <<_ACEOF
8493 /* confdefs.h.  */
8494 _ACEOF
8495 cat confdefs.h >>conftest.$ac_ext
8496 cat >>conftest.$ac_ext <<_ACEOF
8497 /* end confdefs.h.  */
8498
8499 /* Override any GCC internal prototype to avoid an error.
8500    Use char because int might match the return type of a GCC
8501    builtin and then its argument prototype would still apply.  */
8502 #ifdef __cplusplus
8503 extern "C"
8504 #endif
8505 char com_err ();
8506 int
8507 main ()
8508 {
8509 return com_err ();
8510   ;
8511   return 0;
8512 }
8513 _ACEOF
8514 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken' com_err 'com_err -lssl -lcrypto'; do
8515   if test -z "$ac_lib"; then
8516     ac_res="none required"
8517   else
8518     ac_res=-l$ac_lib
8519     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8520   fi
8521   rm -f conftest.$ac_objext conftest$ac_exeext
8522 if { (ac_try="$ac_link"
8523 case "(($ac_try" in
8524   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8525   *) ac_try_echo=$ac_try;;
8526 esac
8527 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8528 $as_echo "$ac_try_echo") >&5
8529   (eval "$ac_link") 2>conftest.er1
8530   ac_status=$?
8531   grep -v '^ *+' conftest.er1 >conftest.err
8532   rm -f conftest.er1
8533   cat conftest.err >&5
8534   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8535   (exit $ac_status); } && {
8536          test -z "$ac_c_werror_flag" ||
8537          test ! -s conftest.err
8538        } && test -s conftest$ac_exeext && {
8539          test "$cross_compiling" = yes ||
8540          $as_test_x conftest$ac_exeext
8541        }; then
8542   ac_cv_search_com_err=$ac_res
8543 else
8544   $as_echo "$as_me: failed program was:" >&5
8545 sed 's/^/| /' conftest.$ac_ext >&5
8546
8547
8548 fi
8549
8550 rm -rf conftest.dSYM
8551 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8552       conftest$ac_exeext
8553   if test "${ac_cv_search_com_err+set}" = set; then
8554   break
8555 fi
8556 done
8557 if test "${ac_cv_search_com_err+set}" = set; then
8558   :
8559 else
8560   ac_cv_search_com_err=no
8561 fi
8562 rm conftest.$ac_ext
8563 LIBS=$ac_func_search_save_LIBS
8564 fi
8565 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
8566 $as_echo "$ac_cv_search_com_err" >&6; }
8567 ac_res=$ac_cv_search_com_err
8568 if test "$ac_res" != no; then
8569   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8570
8571 else
8572   { { $as_echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
8573 $as_echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
8574    { (exit 1); exit 1; }; }
8575 fi
8576
8577      { $as_echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
8578 $as_echo_n "checking for library containing krb5_sendauth... " >&6; }
8579 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8580   $as_echo_n "(cached) " >&6
8581 else
8582   ac_func_search_save_LIBS=$LIBS
8583 cat >conftest.$ac_ext <<_ACEOF
8584 /* confdefs.h.  */
8585 _ACEOF
8586 cat confdefs.h >>conftest.$ac_ext
8587 cat >>conftest.$ac_ext <<_ACEOF
8588 /* end confdefs.h.  */
8589
8590 /* Override any GCC internal prototype to avoid an error.
8591    Use char because int might match the return type of a GCC
8592    builtin and then its argument prototype would still apply.  */
8593 #ifdef __cplusplus
8594 extern "C"
8595 #endif
8596 char krb5_sendauth ();
8597 int
8598 main ()
8599 {
8600 return krb5_sendauth ();
8601   ;
8602   return 0;
8603 }
8604 _ACEOF
8605 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken'; do
8606   if test -z "$ac_lib"; then
8607     ac_res="none required"
8608   else
8609     ac_res=-l$ac_lib
8610     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8611   fi
8612   rm -f conftest.$ac_objext conftest$ac_exeext
8613 if { (ac_try="$ac_link"
8614 case "(($ac_try" in
8615   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8616   *) ac_try_echo=$ac_try;;
8617 esac
8618 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8619 $as_echo "$ac_try_echo") >&5
8620   (eval "$ac_link") 2>conftest.er1
8621   ac_status=$?
8622   grep -v '^ *+' conftest.er1 >conftest.err
8623   rm -f conftest.er1
8624   cat conftest.err >&5
8625   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8626   (exit $ac_status); } && {
8627          test -z "$ac_c_werror_flag" ||
8628          test ! -s conftest.err
8629        } && test -s conftest$ac_exeext && {
8630          test "$cross_compiling" = yes ||
8631          $as_test_x conftest$ac_exeext
8632        }; then
8633   ac_cv_search_krb5_sendauth=$ac_res
8634 else
8635   $as_echo "$as_me: failed program was:" >&5
8636 sed 's/^/| /' conftest.$ac_ext >&5
8637
8638
8639 fi
8640
8641 rm -rf conftest.dSYM
8642 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8643       conftest$ac_exeext
8644   if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8645   break
8646 fi
8647 done
8648 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8649   :
8650 else
8651   ac_cv_search_krb5_sendauth=no
8652 fi
8653 rm conftest.$ac_ext
8654 LIBS=$ac_func_search_save_LIBS
8655 fi
8656 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
8657 $as_echo "$ac_cv_search_krb5_sendauth" >&6; }
8658 ac_res=$ac_cv_search_krb5_sendauth
8659 if test "$ac_res" != no; then
8660   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8661
8662 else
8663   { { $as_echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
8664 $as_echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
8665    { (exit 1); exit 1; }; }
8666 fi
8667
8668   else
8669      { $as_echo "$as_me:$LINENO: checking for library containing com_err" >&5
8670 $as_echo_n "checking for library containing com_err... " >&6; }
8671 if test "${ac_cv_search_com_err+set}" = set; then
8672   $as_echo_n "(cached) " >&6
8673 else
8674   ac_func_search_save_LIBS=$LIBS
8675 cat >conftest.$ac_ext <<_ACEOF
8676 /* confdefs.h.  */
8677 _ACEOF
8678 cat confdefs.h >>conftest.$ac_ext
8679 cat >>conftest.$ac_ext <<_ACEOF
8680 /* end confdefs.h.  */
8681
8682 /* Override any GCC internal prototype to avoid an error.
8683    Use char because int might match the return type of a GCC
8684    builtin and then its argument prototype would still apply.  */
8685 #ifdef __cplusplus
8686 extern "C"
8687 #endif
8688 char com_err ();
8689 int
8690 main ()
8691 {
8692 return com_err ();
8693   ;
8694   return 0;
8695 }
8696 _ACEOF
8697 for ac_lib in '' 'comerr32 -lkrb5_32'; do
8698   if test -z "$ac_lib"; then
8699     ac_res="none required"
8700   else
8701     ac_res=-l$ac_lib
8702     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8703   fi
8704   rm -f conftest.$ac_objext conftest$ac_exeext
8705 if { (ac_try="$ac_link"
8706 case "(($ac_try" in
8707   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8708   *) ac_try_echo=$ac_try;;
8709 esac
8710 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8711 $as_echo "$ac_try_echo") >&5
8712   (eval "$ac_link") 2>conftest.er1
8713   ac_status=$?
8714   grep -v '^ *+' conftest.er1 >conftest.err
8715   rm -f conftest.er1
8716   cat conftest.err >&5
8717   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8718   (exit $ac_status); } && {
8719          test -z "$ac_c_werror_flag" ||
8720          test ! -s conftest.err
8721        } && test -s conftest$ac_exeext && {
8722          test "$cross_compiling" = yes ||
8723          $as_test_x conftest$ac_exeext
8724        }; then
8725   ac_cv_search_com_err=$ac_res
8726 else
8727   $as_echo "$as_me: failed program was:" >&5
8728 sed 's/^/| /' conftest.$ac_ext >&5
8729
8730
8731 fi
8732
8733 rm -rf conftest.dSYM
8734 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8735       conftest$ac_exeext
8736   if test "${ac_cv_search_com_err+set}" = set; then
8737   break
8738 fi
8739 done
8740 if test "${ac_cv_search_com_err+set}" = set; then
8741   :
8742 else
8743   ac_cv_search_com_err=no
8744 fi
8745 rm conftest.$ac_ext
8746 LIBS=$ac_func_search_save_LIBS
8747 fi
8748 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
8749 $as_echo "$ac_cv_search_com_err" >&6; }
8750 ac_res=$ac_cv_search_com_err
8751 if test "$ac_res" != no; then
8752   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8753
8754 else
8755   { { $as_echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
8756 $as_echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
8757    { (exit 1); exit 1; }; }
8758 fi
8759
8760   fi
8761 fi
8762
8763 if test "$with_openssl" = yes ; then
8764     if test "$PORTNAME" != "win32"; then
8765
8766 { $as_echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
8767 $as_echo_n "checking for CRYPTO_new_ex_data in -lcrypto... " >&6; }
8768 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
8769   $as_echo_n "(cached) " >&6
8770 else
8771   ac_check_lib_save_LIBS=$LIBS
8772 LIBS="-lcrypto  $LIBS"
8773 cat >conftest.$ac_ext <<_ACEOF
8774 /* confdefs.h.  */
8775 _ACEOF
8776 cat confdefs.h >>conftest.$ac_ext
8777 cat >>conftest.$ac_ext <<_ACEOF
8778 /* end confdefs.h.  */
8779
8780 /* Override any GCC internal prototype to avoid an error.
8781    Use char because int might match the return type of a GCC
8782    builtin and then its argument prototype would still apply.  */
8783 #ifdef __cplusplus
8784 extern "C"
8785 #endif
8786 char CRYPTO_new_ex_data ();
8787 int
8788 main ()
8789 {
8790 return CRYPTO_new_ex_data ();
8791   ;
8792   return 0;
8793 }
8794 _ACEOF
8795 rm -f conftest.$ac_objext conftest$ac_exeext
8796 if { (ac_try="$ac_link"
8797 case "(($ac_try" in
8798   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8799   *) ac_try_echo=$ac_try;;
8800 esac
8801 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8802 $as_echo "$ac_try_echo") >&5
8803   (eval "$ac_link") 2>conftest.er1
8804   ac_status=$?
8805   grep -v '^ *+' conftest.er1 >conftest.err
8806   rm -f conftest.er1
8807   cat conftest.err >&5
8808   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8809   (exit $ac_status); } && {
8810          test -z "$ac_c_werror_flag" ||
8811          test ! -s conftest.err
8812        } && test -s conftest$ac_exeext && {
8813          test "$cross_compiling" = yes ||
8814          $as_test_x conftest$ac_exeext
8815        }; then
8816   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
8817 else
8818   $as_echo "$as_me: failed program was:" >&5
8819 sed 's/^/| /' conftest.$ac_ext >&5
8820
8821         ac_cv_lib_crypto_CRYPTO_new_ex_data=no
8822 fi
8823
8824 rm -rf conftest.dSYM
8825 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8826       conftest$ac_exeext conftest.$ac_ext
8827 LIBS=$ac_check_lib_save_LIBS
8828 fi
8829 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
8830 $as_echo "$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6; }
8831 if test "x$ac_cv_lib_crypto_CRYPTO_new_ex_data" = x""yes; then
8832   cat >>confdefs.h <<_ACEOF
8833 #define HAVE_LIBCRYPTO 1
8834 _ACEOF
8835
8836   LIBS="-lcrypto $LIBS"
8837
8838 else
8839   { { $as_echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
8840 $as_echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
8841    { (exit 1); exit 1; }; }
8842 fi
8843
8844
8845 { $as_echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
8846 $as_echo_n "checking for SSL_library_init in -lssl... " >&6; }
8847 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
8848   $as_echo_n "(cached) " >&6
8849 else
8850   ac_check_lib_save_LIBS=$LIBS
8851 LIBS="-lssl  $LIBS"
8852 cat >conftest.$ac_ext <<_ACEOF
8853 /* confdefs.h.  */
8854 _ACEOF
8855 cat confdefs.h >>conftest.$ac_ext
8856 cat >>conftest.$ac_ext <<_ACEOF
8857 /* end confdefs.h.  */
8858
8859 /* Override any GCC internal prototype to avoid an error.
8860    Use char because int might match the return type of a GCC
8861    builtin and then its argument prototype would still apply.  */
8862 #ifdef __cplusplus
8863 extern "C"
8864 #endif
8865 char SSL_library_init ();
8866 int
8867 main ()
8868 {
8869 return SSL_library_init ();
8870   ;
8871   return 0;
8872 }
8873 _ACEOF
8874 rm -f conftest.$ac_objext conftest$ac_exeext
8875 if { (ac_try="$ac_link"
8876 case "(($ac_try" in
8877   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8878   *) ac_try_echo=$ac_try;;
8879 esac
8880 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8881 $as_echo "$ac_try_echo") >&5
8882   (eval "$ac_link") 2>conftest.er1
8883   ac_status=$?
8884   grep -v '^ *+' conftest.er1 >conftest.err
8885   rm -f conftest.er1
8886   cat conftest.err >&5
8887   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8888   (exit $ac_status); } && {
8889          test -z "$ac_c_werror_flag" ||
8890          test ! -s conftest.err
8891        } && test -s conftest$ac_exeext && {
8892          test "$cross_compiling" = yes ||
8893          $as_test_x conftest$ac_exeext
8894        }; then
8895   ac_cv_lib_ssl_SSL_library_init=yes
8896 else
8897   $as_echo "$as_me: failed program was:" >&5
8898 sed 's/^/| /' conftest.$ac_ext >&5
8899
8900         ac_cv_lib_ssl_SSL_library_init=no
8901 fi
8902
8903 rm -rf conftest.dSYM
8904 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8905       conftest$ac_exeext conftest.$ac_ext
8906 LIBS=$ac_check_lib_save_LIBS
8907 fi
8908 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
8909 $as_echo "$ac_cv_lib_ssl_SSL_library_init" >&6; }
8910 if test "x$ac_cv_lib_ssl_SSL_library_init" = x""yes; then
8911   cat >>confdefs.h <<_ACEOF
8912 #define HAVE_LIBSSL 1
8913 _ACEOF
8914
8915   LIBS="-lssl $LIBS"
8916
8917 else
8918   { { $as_echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
8919 $as_echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
8920    { (exit 1); exit 1; }; }
8921 fi
8922
8923   else
8924
8925 { $as_echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -leay32" >&5
8926 $as_echo_n "checking for CRYPTO_new_ex_data in -leay32... " >&6; }
8927 if test "${ac_cv_lib_eay32_CRYPTO_new_ex_data+set}" = set; then
8928   $as_echo_n "(cached) " >&6
8929 else
8930   ac_check_lib_save_LIBS=$LIBS
8931 LIBS="-leay32  $LIBS"
8932 cat >conftest.$ac_ext <<_ACEOF
8933 /* confdefs.h.  */
8934 _ACEOF
8935 cat confdefs.h >>conftest.$ac_ext
8936 cat >>conftest.$ac_ext <<_ACEOF
8937 /* end confdefs.h.  */
8938
8939 /* Override any GCC internal prototype to avoid an error.
8940    Use char because int might match the return type of a GCC
8941    builtin and then its argument prototype would still apply.  */
8942 #ifdef __cplusplus
8943 extern "C"
8944 #endif
8945 char CRYPTO_new_ex_data ();
8946 int
8947 main ()
8948 {
8949 return CRYPTO_new_ex_data ();
8950   ;
8951   return 0;
8952 }
8953 _ACEOF
8954 rm -f conftest.$ac_objext conftest$ac_exeext
8955 if { (ac_try="$ac_link"
8956 case "(($ac_try" in
8957   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8958   *) ac_try_echo=$ac_try;;
8959 esac
8960 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8961 $as_echo "$ac_try_echo") >&5
8962   (eval "$ac_link") 2>conftest.er1
8963   ac_status=$?
8964   grep -v '^ *+' conftest.er1 >conftest.err
8965   rm -f conftest.er1
8966   cat conftest.err >&5
8967   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8968   (exit $ac_status); } && {
8969          test -z "$ac_c_werror_flag" ||
8970          test ! -s conftest.err
8971        } && test -s conftest$ac_exeext && {
8972          test "$cross_compiling" = yes ||
8973          $as_test_x conftest$ac_exeext
8974        }; then
8975   ac_cv_lib_eay32_CRYPTO_new_ex_data=yes
8976 else
8977   $as_echo "$as_me: failed program was:" >&5
8978 sed 's/^/| /' conftest.$ac_ext >&5
8979
8980         ac_cv_lib_eay32_CRYPTO_new_ex_data=no
8981 fi
8982
8983 rm -rf conftest.dSYM
8984 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8985       conftest$ac_exeext conftest.$ac_ext
8986 LIBS=$ac_check_lib_save_LIBS
8987 fi
8988 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_eay32_CRYPTO_new_ex_data" >&5
8989 $as_echo "$ac_cv_lib_eay32_CRYPTO_new_ex_data" >&6; }
8990 if test "x$ac_cv_lib_eay32_CRYPTO_new_ex_data" = x""yes; then
8991   cat >>confdefs.h <<_ACEOF
8992 #define HAVE_LIBEAY32 1
8993 _ACEOF
8994
8995   LIBS="-leay32 $LIBS"
8996
8997 else
8998   { { $as_echo "$as_me:$LINENO: error: library 'eay32' is required for OpenSSL" >&5
8999 $as_echo "$as_me: error: library 'eay32' is required for OpenSSL" >&2;}
9000    { (exit 1); exit 1; }; }
9001 fi
9002
9003
9004 { $as_echo "$as_me:$LINENO: checking for SSL_library_init in -lssleay32" >&5
9005 $as_echo_n "checking for SSL_library_init in -lssleay32... " >&6; }
9006 if test "${ac_cv_lib_ssleay32_SSL_library_init+set}" = set; then
9007   $as_echo_n "(cached) " >&6
9008 else
9009   ac_check_lib_save_LIBS=$LIBS
9010 LIBS="-lssleay32  $LIBS"
9011 cat >conftest.$ac_ext <<_ACEOF
9012 /* confdefs.h.  */
9013 _ACEOF
9014 cat confdefs.h >>conftest.$ac_ext
9015 cat >>conftest.$ac_ext <<_ACEOF
9016 /* end confdefs.h.  */
9017
9018 /* Override any GCC internal prototype to avoid an error.
9019    Use char because int might match the return type of a GCC
9020    builtin and then its argument prototype would still apply.  */
9021 #ifdef __cplusplus
9022 extern "C"
9023 #endif
9024 char SSL_library_init ();
9025 int
9026 main ()
9027 {
9028 return SSL_library_init ();
9029   ;
9030   return 0;
9031 }
9032 _ACEOF
9033 rm -f conftest.$ac_objext conftest$ac_exeext
9034 if { (ac_try="$ac_link"
9035 case "(($ac_try" in
9036   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9037   *) ac_try_echo=$ac_try;;
9038 esac
9039 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9040 $as_echo "$ac_try_echo") >&5
9041   (eval "$ac_link") 2>conftest.er1
9042   ac_status=$?
9043   grep -v '^ *+' conftest.er1 >conftest.err
9044   rm -f conftest.er1
9045   cat conftest.err >&5
9046   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9047   (exit $ac_status); } && {
9048          test -z "$ac_c_werror_flag" ||
9049          test ! -s conftest.err
9050        } && test -s conftest$ac_exeext && {
9051          test "$cross_compiling" = yes ||
9052          $as_test_x conftest$ac_exeext
9053        }; then
9054   ac_cv_lib_ssleay32_SSL_library_init=yes
9055 else
9056   $as_echo "$as_me: failed program was:" >&5
9057 sed 's/^/| /' conftest.$ac_ext >&5
9058
9059         ac_cv_lib_ssleay32_SSL_library_init=no
9060 fi
9061
9062 rm -rf conftest.dSYM
9063 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9064       conftest$ac_exeext conftest.$ac_ext
9065 LIBS=$ac_check_lib_save_LIBS
9066 fi
9067 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ssleay32_SSL_library_init" >&5
9068 $as_echo "$ac_cv_lib_ssleay32_SSL_library_init" >&6; }
9069 if test "x$ac_cv_lib_ssleay32_SSL_library_init" = x""yes; then
9070   cat >>confdefs.h <<_ACEOF
9071 #define HAVE_LIBSSLEAY32 1
9072 _ACEOF
9073
9074   LIBS="-lssleay32 $LIBS"
9075
9076 else
9077   { { $as_echo "$as_me:$LINENO: error: library 'ssleay32' is required for OpenSSL" >&5
9078 $as_echo "$as_me: error: library 'ssleay32' is required for OpenSSL" >&2;}
9079    { (exit 1); exit 1; }; }
9080 fi
9081
9082   fi
9083 fi
9084
9085 if test "$with_pam" = yes ; then
9086
9087 { $as_echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
9088 $as_echo_n "checking for pam_start in -lpam... " >&6; }
9089 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
9090   $as_echo_n "(cached) " >&6
9091 else
9092   ac_check_lib_save_LIBS=$LIBS
9093 LIBS="-lpam  $LIBS"
9094 cat >conftest.$ac_ext <<_ACEOF
9095 /* confdefs.h.  */
9096 _ACEOF
9097 cat confdefs.h >>conftest.$ac_ext
9098 cat >>conftest.$ac_ext <<_ACEOF
9099 /* end confdefs.h.  */
9100
9101 /* Override any GCC internal prototype to avoid an error.
9102    Use char because int might match the return type of a GCC
9103    builtin and then its argument prototype would still apply.  */
9104 #ifdef __cplusplus
9105 extern "C"
9106 #endif
9107 char pam_start ();
9108 int
9109 main ()
9110 {
9111 return pam_start ();
9112   ;
9113   return 0;
9114 }
9115 _ACEOF
9116 rm -f conftest.$ac_objext conftest$ac_exeext
9117 if { (ac_try="$ac_link"
9118 case "(($ac_try" in
9119   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9120   *) ac_try_echo=$ac_try;;
9121 esac
9122 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9123 $as_echo "$ac_try_echo") >&5
9124   (eval "$ac_link") 2>conftest.er1
9125   ac_status=$?
9126   grep -v '^ *+' conftest.er1 >conftest.err
9127   rm -f conftest.er1
9128   cat conftest.err >&5
9129   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9130   (exit $ac_status); } && {
9131          test -z "$ac_c_werror_flag" ||
9132          test ! -s conftest.err
9133        } && test -s conftest$ac_exeext && {
9134          test "$cross_compiling" = yes ||
9135          $as_test_x conftest$ac_exeext
9136        }; then
9137   ac_cv_lib_pam_pam_start=yes
9138 else
9139   $as_echo "$as_me: failed program was:" >&5
9140 sed 's/^/| /' conftest.$ac_ext >&5
9141
9142         ac_cv_lib_pam_pam_start=no
9143 fi
9144
9145 rm -rf conftest.dSYM
9146 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9147       conftest$ac_exeext conftest.$ac_ext
9148 LIBS=$ac_check_lib_save_LIBS
9149 fi
9150 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
9151 $as_echo "$ac_cv_lib_pam_pam_start" >&6; }
9152 if test "x$ac_cv_lib_pam_pam_start" = x""yes; then
9153   cat >>confdefs.h <<_ACEOF
9154 #define HAVE_LIBPAM 1
9155 _ACEOF
9156
9157   LIBS="-lpam $LIBS"
9158
9159 else
9160   { { $as_echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
9161 $as_echo "$as_me: error: library 'pam' is required for PAM" >&2;}
9162    { (exit 1); exit 1; }; }
9163 fi
9164
9165 fi
9166
9167 if test "$with_libxml" = yes ; then
9168
9169 { $as_echo "$as_me:$LINENO: checking for xmlSaveToBuffer in -lxml2" >&5
9170 $as_echo_n "checking for xmlSaveToBuffer in -lxml2... " >&6; }
9171 if test "${ac_cv_lib_xml2_xmlSaveToBuffer+set}" = set; then
9172   $as_echo_n "(cached) " >&6
9173 else
9174   ac_check_lib_save_LIBS=$LIBS
9175 LIBS="-lxml2  $LIBS"
9176 cat >conftest.$ac_ext <<_ACEOF
9177 /* confdefs.h.  */
9178 _ACEOF
9179 cat confdefs.h >>conftest.$ac_ext
9180 cat >>conftest.$ac_ext <<_ACEOF
9181 /* end confdefs.h.  */
9182
9183 /* Override any GCC internal prototype to avoid an error.
9184    Use char because int might match the return type of a GCC
9185    builtin and then its argument prototype would still apply.  */
9186 #ifdef __cplusplus
9187 extern "C"
9188 #endif
9189 char xmlSaveToBuffer ();
9190 int
9191 main ()
9192 {
9193 return xmlSaveToBuffer ();
9194   ;
9195   return 0;
9196 }
9197 _ACEOF
9198 rm -f conftest.$ac_objext conftest$ac_exeext
9199 if { (ac_try="$ac_link"
9200 case "(($ac_try" in
9201   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9202   *) ac_try_echo=$ac_try;;
9203 esac
9204 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9205 $as_echo "$ac_try_echo") >&5
9206   (eval "$ac_link") 2>conftest.er1
9207   ac_status=$?
9208   grep -v '^ *+' conftest.er1 >conftest.err
9209   rm -f conftest.er1
9210   cat conftest.err >&5
9211   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9212   (exit $ac_status); } && {
9213          test -z "$ac_c_werror_flag" ||
9214          test ! -s conftest.err
9215        } && test -s conftest$ac_exeext && {
9216          test "$cross_compiling" = yes ||
9217          $as_test_x conftest$ac_exeext
9218        }; then
9219   ac_cv_lib_xml2_xmlSaveToBuffer=yes
9220 else
9221   $as_echo "$as_me: failed program was:" >&5
9222 sed 's/^/| /' conftest.$ac_ext >&5
9223
9224         ac_cv_lib_xml2_xmlSaveToBuffer=no
9225 fi
9226
9227 rm -rf conftest.dSYM
9228 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9229       conftest$ac_exeext conftest.$ac_ext
9230 LIBS=$ac_check_lib_save_LIBS
9231 fi
9232 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlSaveToBuffer" >&5
9233 $as_echo "$ac_cv_lib_xml2_xmlSaveToBuffer" >&6; }
9234 if test "x$ac_cv_lib_xml2_xmlSaveToBuffer" = x""yes; then
9235   cat >>confdefs.h <<_ACEOF
9236 #define HAVE_LIBXML2 1
9237 _ACEOF
9238
9239   LIBS="-lxml2 $LIBS"
9240
9241 else
9242   { { $as_echo "$as_me:$LINENO: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&5
9243 $as_echo "$as_me: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&2;}
9244    { (exit 1); exit 1; }; }
9245 fi
9246
9247 fi
9248
9249 if test "$with_libxslt" = yes ; then
9250
9251 { $as_echo "$as_me:$LINENO: checking for xsltCleanupGlobals in -lxslt" >&5
9252 $as_echo_n "checking for xsltCleanupGlobals in -lxslt... " >&6; }
9253 if test "${ac_cv_lib_xslt_xsltCleanupGlobals+set}" = set; then
9254   $as_echo_n "(cached) " >&6
9255 else
9256   ac_check_lib_save_LIBS=$LIBS
9257 LIBS="-lxslt  $LIBS"
9258 cat >conftest.$ac_ext <<_ACEOF
9259 /* confdefs.h.  */
9260 _ACEOF
9261 cat confdefs.h >>conftest.$ac_ext
9262 cat >>conftest.$ac_ext <<_ACEOF
9263 /* end confdefs.h.  */
9264
9265 /* Override any GCC internal prototype to avoid an error.
9266    Use char because int might match the return type of a GCC
9267    builtin and then its argument prototype would still apply.  */
9268 #ifdef __cplusplus
9269 extern "C"
9270 #endif
9271 char xsltCleanupGlobals ();
9272 int
9273 main ()
9274 {
9275 return xsltCleanupGlobals ();
9276   ;
9277   return 0;
9278 }
9279 _ACEOF
9280 rm -f conftest.$ac_objext conftest$ac_exeext
9281 if { (ac_try="$ac_link"
9282 case "(($ac_try" in
9283   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9284   *) ac_try_echo=$ac_try;;
9285 esac
9286 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9287 $as_echo "$ac_try_echo") >&5
9288   (eval "$ac_link") 2>conftest.er1
9289   ac_status=$?
9290   grep -v '^ *+' conftest.er1 >conftest.err
9291   rm -f conftest.er1
9292   cat conftest.err >&5
9293   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9294   (exit $ac_status); } && {
9295          test -z "$ac_c_werror_flag" ||
9296          test ! -s conftest.err
9297        } && test -s conftest$ac_exeext && {
9298          test "$cross_compiling" = yes ||
9299          $as_test_x conftest$ac_exeext
9300        }; then
9301   ac_cv_lib_xslt_xsltCleanupGlobals=yes
9302 else
9303   $as_echo "$as_me: failed program was:" >&5
9304 sed 's/^/| /' conftest.$ac_ext >&5
9305
9306         ac_cv_lib_xslt_xsltCleanupGlobals=no
9307 fi
9308
9309 rm -rf conftest.dSYM
9310 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9311       conftest$ac_exeext conftest.$ac_ext
9312 LIBS=$ac_check_lib_save_LIBS
9313 fi
9314 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xslt_xsltCleanupGlobals" >&5
9315 $as_echo "$ac_cv_lib_xslt_xsltCleanupGlobals" >&6; }
9316 if test "x$ac_cv_lib_xslt_xsltCleanupGlobals" = x""yes; then
9317   cat >>confdefs.h <<_ACEOF
9318 #define HAVE_LIBXSLT 1
9319 _ACEOF
9320
9321   LIBS="-lxslt $LIBS"
9322
9323 else
9324   { { $as_echo "$as_me:$LINENO: error: library 'xslt' is required for XSLT support" >&5
9325 $as_echo "$as_me: error: library 'xslt' is required for XSLT support" >&2;}
9326    { (exit 1); exit 1; }; }
9327 fi
9328
9329 fi
9330
9331 # for contrib/sepgsql
9332 if test "$with_selinux" = yes; then
9333
9334 { $as_echo "$as_me:$LINENO: checking for getpeercon_raw in -lselinux" >&5
9335 $as_echo_n "checking for getpeercon_raw in -lselinux... " >&6; }
9336 if test "${ac_cv_lib_selinux_getpeercon_raw+set}" = set; then
9337   $as_echo_n "(cached) " >&6
9338 else
9339   ac_check_lib_save_LIBS=$LIBS
9340 LIBS="-lselinux  $LIBS"
9341 cat >conftest.$ac_ext <<_ACEOF
9342 /* confdefs.h.  */
9343 _ACEOF
9344 cat confdefs.h >>conftest.$ac_ext
9345 cat >>conftest.$ac_ext <<_ACEOF
9346 /* end confdefs.h.  */
9347
9348 /* Override any GCC internal prototype to avoid an error.
9349    Use char because int might match the return type of a GCC
9350    builtin and then its argument prototype would still apply.  */
9351 #ifdef __cplusplus
9352 extern "C"
9353 #endif
9354 char getpeercon_raw ();
9355 int
9356 main ()
9357 {
9358 return getpeercon_raw ();
9359   ;
9360   return 0;
9361 }
9362 _ACEOF
9363 rm -f conftest.$ac_objext conftest$ac_exeext
9364 if { (ac_try="$ac_link"
9365 case "(($ac_try" in
9366   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9367   *) ac_try_echo=$ac_try;;
9368 esac
9369 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9370 $as_echo "$ac_try_echo") >&5
9371   (eval "$ac_link") 2>conftest.er1
9372   ac_status=$?
9373   grep -v '^ *+' conftest.er1 >conftest.err
9374   rm -f conftest.er1
9375   cat conftest.err >&5
9376   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9377   (exit $ac_status); } && {
9378          test -z "$ac_c_werror_flag" ||
9379          test ! -s conftest.err
9380        } && test -s conftest$ac_exeext && {
9381          test "$cross_compiling" = yes ||
9382          $as_test_x conftest$ac_exeext
9383        }; then
9384   ac_cv_lib_selinux_getpeercon_raw=yes
9385 else
9386   $as_echo "$as_me: failed program was:" >&5
9387 sed 's/^/| /' conftest.$ac_ext >&5
9388
9389         ac_cv_lib_selinux_getpeercon_raw=no
9390 fi
9391
9392 rm -rf conftest.dSYM
9393 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9394       conftest$ac_exeext conftest.$ac_ext
9395 LIBS=$ac_check_lib_save_LIBS
9396 fi
9397 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_selinux_getpeercon_raw" >&5
9398 $as_echo "$ac_cv_lib_selinux_getpeercon_raw" >&6; }
9399 if test "x$ac_cv_lib_selinux_getpeercon_raw" = x""yes; then
9400   cat >>confdefs.h <<_ACEOF
9401 #define HAVE_LIBSELINUX 1
9402 _ACEOF
9403
9404   LIBS="-lselinux $LIBS"
9405
9406 else
9407   { { $as_echo "$as_me:$LINENO: error: library 'libselinux' is required for SELinux support" >&5
9408 $as_echo "$as_me: error: library 'libselinux' is required for SELinux support" >&2;}
9409    { (exit 1); exit 1; }; }
9410 fi
9411
9412 fi
9413
9414 # for contrib/uuid-ossp
9415 if test "$with_ossp_uuid" = yes ; then
9416   { $as_echo "$as_me:$LINENO: checking for uuid_export in -lossp-uuid" >&5
9417 $as_echo_n "checking for uuid_export in -lossp-uuid... " >&6; }
9418 if test "${ac_cv_lib_ossp_uuid_uuid_export+set}" = set; then
9419   $as_echo_n "(cached) " >&6
9420 else
9421   ac_check_lib_save_LIBS=$LIBS
9422 LIBS="-lossp-uuid  $LIBS"
9423 cat >conftest.$ac_ext <<_ACEOF
9424 /* confdefs.h.  */
9425 _ACEOF
9426 cat confdefs.h >>conftest.$ac_ext
9427 cat >>conftest.$ac_ext <<_ACEOF
9428 /* end confdefs.h.  */
9429
9430 /* Override any GCC internal prototype to avoid an error.
9431    Use char because int might match the return type of a GCC
9432    builtin and then its argument prototype would still apply.  */
9433 #ifdef __cplusplus
9434 extern "C"
9435 #endif
9436 char uuid_export ();
9437 int
9438 main ()
9439 {
9440 return uuid_export ();
9441   ;
9442   return 0;
9443 }
9444 _ACEOF
9445 rm -f conftest.$ac_objext conftest$ac_exeext
9446 if { (ac_try="$ac_link"
9447 case "(($ac_try" in
9448   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9449   *) ac_try_echo=$ac_try;;
9450 esac
9451 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9452 $as_echo "$ac_try_echo") >&5
9453   (eval "$ac_link") 2>conftest.er1
9454   ac_status=$?
9455   grep -v '^ *+' conftest.er1 >conftest.err
9456   rm -f conftest.er1
9457   cat conftest.err >&5
9458   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9459   (exit $ac_status); } && {
9460          test -z "$ac_c_werror_flag" ||
9461          test ! -s conftest.err
9462        } && test -s conftest$ac_exeext && {
9463          test "$cross_compiling" = yes ||
9464          $as_test_x conftest$ac_exeext
9465        }; then
9466   ac_cv_lib_ossp_uuid_uuid_export=yes
9467 else
9468   $as_echo "$as_me: failed program was:" >&5
9469 sed 's/^/| /' conftest.$ac_ext >&5
9470
9471         ac_cv_lib_ossp_uuid_uuid_export=no
9472 fi
9473
9474 rm -rf conftest.dSYM
9475 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9476       conftest$ac_exeext conftest.$ac_ext
9477 LIBS=$ac_check_lib_save_LIBS
9478 fi
9479 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ossp_uuid_uuid_export" >&5
9480 $as_echo "$ac_cv_lib_ossp_uuid_uuid_export" >&6; }
9481 if test "x$ac_cv_lib_ossp_uuid_uuid_export" = x""yes; then
9482   OSSP_UUID_LIBS="-lossp-uuid"
9483 else
9484   { $as_echo "$as_me:$LINENO: checking for uuid_export in -luuid" >&5
9485 $as_echo_n "checking for uuid_export in -luuid... " >&6; }
9486 if test "${ac_cv_lib_uuid_uuid_export+set}" = set; then
9487   $as_echo_n "(cached) " >&6
9488 else
9489   ac_check_lib_save_LIBS=$LIBS
9490 LIBS="-luuid  $LIBS"
9491 cat >conftest.$ac_ext <<_ACEOF
9492 /* confdefs.h.  */
9493 _ACEOF
9494 cat confdefs.h >>conftest.$ac_ext
9495 cat >>conftest.$ac_ext <<_ACEOF
9496 /* end confdefs.h.  */
9497
9498 /* Override any GCC internal prototype to avoid an error.
9499    Use char because int might match the return type of a GCC
9500    builtin and then its argument prototype would still apply.  */
9501 #ifdef __cplusplus
9502 extern "C"
9503 #endif
9504 char uuid_export ();
9505 int
9506 main ()
9507 {
9508 return uuid_export ();
9509   ;
9510   return 0;
9511 }
9512 _ACEOF
9513 rm -f conftest.$ac_objext conftest$ac_exeext
9514 if { (ac_try="$ac_link"
9515 case "(($ac_try" in
9516   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9517   *) ac_try_echo=$ac_try;;
9518 esac
9519 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9520 $as_echo "$ac_try_echo") >&5
9521   (eval "$ac_link") 2>conftest.er1
9522   ac_status=$?
9523   grep -v '^ *+' conftest.er1 >conftest.err
9524   rm -f conftest.er1
9525   cat conftest.err >&5
9526   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9527   (exit $ac_status); } && {
9528          test -z "$ac_c_werror_flag" ||
9529          test ! -s conftest.err
9530        } && test -s conftest$ac_exeext && {
9531          test "$cross_compiling" = yes ||
9532          $as_test_x conftest$ac_exeext
9533        }; then
9534   ac_cv_lib_uuid_uuid_export=yes
9535 else
9536   $as_echo "$as_me: failed program was:" >&5
9537 sed 's/^/| /' conftest.$ac_ext >&5
9538
9539         ac_cv_lib_uuid_uuid_export=no
9540 fi
9541
9542 rm -rf conftest.dSYM
9543 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9544       conftest$ac_exeext conftest.$ac_ext
9545 LIBS=$ac_check_lib_save_LIBS
9546 fi
9547 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_uuid_uuid_export" >&5
9548 $as_echo "$ac_cv_lib_uuid_uuid_export" >&6; }
9549 if test "x$ac_cv_lib_uuid_uuid_export" = x""yes; then
9550   OSSP_UUID_LIBS="-luuid"
9551 else
9552   { { $as_echo "$as_me:$LINENO: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&5
9553 $as_echo "$as_me: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&2;}
9554    { (exit 1); exit 1; }; }
9555 fi
9556
9557 fi
9558
9559 fi
9560
9561
9562
9563 ##
9564 ## Header files
9565 ##
9566
9567 { $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5
9568 $as_echo_n "checking for ANSI C header files... " >&6; }
9569 if test "${ac_cv_header_stdc+set}" = set; then
9570   $as_echo_n "(cached) " >&6
9571 else
9572   cat >conftest.$ac_ext <<_ACEOF
9573 /* confdefs.h.  */
9574 _ACEOF
9575 cat confdefs.h >>conftest.$ac_ext
9576 cat >>conftest.$ac_ext <<_ACEOF
9577 /* end confdefs.h.  */
9578 #include <stdlib.h>
9579 #include <stdarg.h>
9580 #include <string.h>
9581 #include <float.h>
9582
9583 int
9584 main ()
9585 {
9586
9587   ;
9588   return 0;
9589 }
9590 _ACEOF
9591 rm -f conftest.$ac_objext
9592 if { (ac_try="$ac_compile"
9593 case "(($ac_try" in
9594   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9595   *) ac_try_echo=$ac_try;;
9596 esac
9597 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9598 $as_echo "$ac_try_echo") >&5
9599   (eval "$ac_compile") 2>conftest.er1
9600   ac_status=$?
9601   grep -v '^ *+' conftest.er1 >conftest.err
9602   rm -f conftest.er1
9603   cat conftest.err >&5
9604   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9605   (exit $ac_status); } && {
9606          test -z "$ac_c_werror_flag" ||
9607          test ! -s conftest.err
9608        } && test -s conftest.$ac_objext; then
9609   ac_cv_header_stdc=yes
9610 else
9611   $as_echo "$as_me: failed program was:" >&5
9612 sed 's/^/| /' conftest.$ac_ext >&5
9613
9614         ac_cv_header_stdc=no
9615 fi
9616
9617 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9618
9619 if test $ac_cv_header_stdc = yes; then
9620   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
9621   cat >conftest.$ac_ext <<_ACEOF
9622 /* confdefs.h.  */
9623 _ACEOF
9624 cat confdefs.h >>conftest.$ac_ext
9625 cat >>conftest.$ac_ext <<_ACEOF
9626 /* end confdefs.h.  */
9627 #include <string.h>
9628
9629 _ACEOF
9630 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9631   $EGREP "memchr" >/dev/null 2>&1; then
9632   :
9633 else
9634   ac_cv_header_stdc=no
9635 fi
9636 rm -f conftest*
9637
9638 fi
9639
9640 if test $ac_cv_header_stdc = yes; then
9641   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
9642   cat >conftest.$ac_ext <<_ACEOF
9643 /* confdefs.h.  */
9644 _ACEOF
9645 cat confdefs.h >>conftest.$ac_ext
9646 cat >>conftest.$ac_ext <<_ACEOF
9647 /* end confdefs.h.  */
9648 #include <stdlib.h>
9649
9650 _ACEOF
9651 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9652   $EGREP "free" >/dev/null 2>&1; then
9653   :
9654 else
9655   ac_cv_header_stdc=no
9656 fi
9657 rm -f conftest*
9658
9659 fi
9660
9661 if test $ac_cv_header_stdc = yes; then
9662   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
9663   if test "$cross_compiling" = yes; then
9664   :
9665 else
9666   cat >conftest.$ac_ext <<_ACEOF
9667 /* confdefs.h.  */
9668 _ACEOF
9669 cat confdefs.h >>conftest.$ac_ext
9670 cat >>conftest.$ac_ext <<_ACEOF
9671 /* end confdefs.h.  */
9672 #include <ctype.h>
9673 #include <stdlib.h>
9674 #if ((' ' & 0x0FF) == 0x020)
9675 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
9676 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
9677 #else
9678 # define ISLOWER(c) \
9679                    (('a' <= (c) && (c) <= 'i') \
9680                      || ('j' <= (c) && (c) <= 'r') \
9681                      || ('s' <= (c) && (c) <= 'z'))
9682 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
9683 #endif
9684
9685 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
9686 int
9687 main ()
9688 {
9689   int i;
9690   for (i = 0; i < 256; i++)
9691     if (XOR (islower (i), ISLOWER (i))
9692         || toupper (i) != TOUPPER (i))
9693       return 2;
9694   return 0;
9695 }
9696 _ACEOF
9697 rm -f conftest$ac_exeext
9698 if { (ac_try="$ac_link"
9699 case "(($ac_try" in
9700   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9701   *) ac_try_echo=$ac_try;;
9702 esac
9703 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9704 $as_echo "$ac_try_echo") >&5
9705   (eval "$ac_link") 2>&5
9706   ac_status=$?
9707   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9708   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9709   { (case "(($ac_try" in
9710   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9711   *) ac_try_echo=$ac_try;;
9712 esac
9713 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9714 $as_echo "$ac_try_echo") >&5
9715   (eval "$ac_try") 2>&5
9716   ac_status=$?
9717   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9718   (exit $ac_status); }; }; then
9719   :
9720 else
9721   $as_echo "$as_me: program exited with status $ac_status" >&5
9722 $as_echo "$as_me: failed program was:" >&5
9723 sed 's/^/| /' conftest.$ac_ext >&5
9724
9725 ( exit $ac_status )
9726 ac_cv_header_stdc=no
9727 fi
9728 rm -rf conftest.dSYM
9729 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9730 fi
9731
9732
9733 fi
9734 fi
9735 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
9736 $as_echo "$ac_cv_header_stdc" >&6; }
9737 if test $ac_cv_header_stdc = yes; then
9738
9739 cat >>confdefs.h <<\_ACEOF
9740 #define STDC_HEADERS 1
9741 _ACEOF
9742
9743 fi
9744
9745 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
9746
9747
9748
9749
9750
9751
9752
9753
9754
9755 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
9756                   inttypes.h stdint.h unistd.h
9757 do
9758 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9759 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9760 $as_echo_n "checking for $ac_header... " >&6; }
9761 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9762   $as_echo_n "(cached) " >&6
9763 else
9764   cat >conftest.$ac_ext <<_ACEOF
9765 /* confdefs.h.  */
9766 _ACEOF
9767 cat confdefs.h >>conftest.$ac_ext
9768 cat >>conftest.$ac_ext <<_ACEOF
9769 /* end confdefs.h.  */
9770 $ac_includes_default
9771
9772 #include <$ac_header>
9773 _ACEOF
9774 rm -f conftest.$ac_objext
9775 if { (ac_try="$ac_compile"
9776 case "(($ac_try" in
9777   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9778   *) ac_try_echo=$ac_try;;
9779 esac
9780 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9781 $as_echo "$ac_try_echo") >&5
9782   (eval "$ac_compile") 2>conftest.er1
9783   ac_status=$?
9784   grep -v '^ *+' conftest.er1 >conftest.err
9785   rm -f conftest.er1
9786   cat conftest.err >&5
9787   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9788   (exit $ac_status); } && {
9789          test -z "$ac_c_werror_flag" ||
9790          test ! -s conftest.err
9791        } && test -s conftest.$ac_objext; then
9792   eval "$as_ac_Header=yes"
9793 else
9794   $as_echo "$as_me: failed program was:" >&5
9795 sed 's/^/| /' conftest.$ac_ext >&5
9796
9797         eval "$as_ac_Header=no"
9798 fi
9799
9800 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9801 fi
9802 ac_res=`eval 'as_val=${'$as_ac_Header'}
9803                  $as_echo "$as_val"'`
9804                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9805 $as_echo "$ac_res" >&6; }
9806 as_val=`eval 'as_val=${'$as_ac_Header'}
9807                  $as_echo "$as_val"'`
9808    if test "x$as_val" = x""yes; then
9809   cat >>confdefs.h <<_ACEOF
9810 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9811 _ACEOF
9812
9813 fi
9814
9815 done
9816
9817
9818
9819
9820
9821
9822
9823
9824
9825
9826
9827
9828
9829
9830
9831
9832
9833
9834
9835
9836
9837
9838
9839
9840
9841
9842
9843
9844
9845
9846
9847
9848 for ac_header in crypt.h dld.h fp_class.h getopt.h ieeefp.h ifaddrs.h langinfo.h poll.h pwd.h sys/ioctl.h sys/ipc.h sys/poll.h sys/pstat.h sys/resource.h sys/select.h sys/sem.h sys/shm.h sys/socket.h sys/sockio.h sys/tas.h sys/time.h sys/un.h termios.h ucred.h utime.h wchar.h wctype.h kernel/OS.h kernel/image.h SupportDefs.h
9849 do
9850 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9851 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9852   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9853 $as_echo_n "checking for $ac_header... " >&6; }
9854 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9855   $as_echo_n "(cached) " >&6
9856 fi
9857 ac_res=`eval 'as_val=${'$as_ac_Header'}
9858                  $as_echo "$as_val"'`
9859                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9860 $as_echo "$ac_res" >&6; }
9861 else
9862   # Is the header compilable?
9863 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
9864 $as_echo_n "checking $ac_header usability... " >&6; }
9865 cat >conftest.$ac_ext <<_ACEOF
9866 /* confdefs.h.  */
9867 _ACEOF
9868 cat confdefs.h >>conftest.$ac_ext
9869 cat >>conftest.$ac_ext <<_ACEOF
9870 /* end confdefs.h.  */
9871 $ac_includes_default
9872 #include <$ac_header>
9873 _ACEOF
9874 rm -f conftest.$ac_objext
9875 if { (ac_try="$ac_compile"
9876 case "(($ac_try" in
9877   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9878   *) ac_try_echo=$ac_try;;
9879 esac
9880 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9881 $as_echo "$ac_try_echo") >&5
9882   (eval "$ac_compile") 2>conftest.er1
9883   ac_status=$?
9884   grep -v '^ *+' conftest.er1 >conftest.err
9885   rm -f conftest.er1
9886   cat conftest.err >&5
9887   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9888   (exit $ac_status); } && {
9889          test -z "$ac_c_werror_flag" ||
9890          test ! -s conftest.err
9891        } && test -s conftest.$ac_objext; then
9892   ac_header_compiler=yes
9893 else
9894   $as_echo "$as_me: failed program was:" >&5
9895 sed 's/^/| /' conftest.$ac_ext >&5
9896
9897         ac_header_compiler=no
9898 fi
9899
9900 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9901 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9902 $as_echo "$ac_header_compiler" >&6; }
9903
9904 # Is the header present?
9905 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
9906 $as_echo_n "checking $ac_header presence... " >&6; }
9907 cat >conftest.$ac_ext <<_ACEOF
9908 /* confdefs.h.  */
9909 _ACEOF
9910 cat confdefs.h >>conftest.$ac_ext
9911 cat >>conftest.$ac_ext <<_ACEOF
9912 /* end confdefs.h.  */
9913 #include <$ac_header>
9914 _ACEOF
9915 if { (ac_try="$ac_cpp conftest.$ac_ext"
9916 case "(($ac_try" in
9917   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9918   *) ac_try_echo=$ac_try;;
9919 esac
9920 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9921 $as_echo "$ac_try_echo") >&5
9922   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9923   ac_status=$?
9924   grep -v '^ *+' conftest.er1 >conftest.err
9925   rm -f conftest.er1
9926   cat conftest.err >&5
9927   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9928   (exit $ac_status); } >/dev/null && {
9929          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9930          test ! -s conftest.err
9931        }; then
9932   ac_header_preproc=yes
9933 else
9934   $as_echo "$as_me: failed program was:" >&5
9935 sed 's/^/| /' conftest.$ac_ext >&5
9936
9937   ac_header_preproc=no
9938 fi
9939
9940 rm -f conftest.err conftest.$ac_ext
9941 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9942 $as_echo "$ac_header_preproc" >&6; }
9943
9944 # So?  What about this header?
9945 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9946   yes:no: )
9947     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9948 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9949     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9950 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9951     ac_header_preproc=yes
9952     ;;
9953   no:yes:* )
9954     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9955 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9956     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9957 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9958     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9959 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9960     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9961 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9962     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9963 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9964     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9965 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9966     ( cat <<\_ASBOX
9967 ## ---------------------------------------- ##
9968 ## Report this to pgsql-bugs@postgresql.org ##
9969 ## ---------------------------------------- ##
9970 _ASBOX
9971      ) | sed "s/^/$as_me: WARNING:     /" >&2
9972     ;;
9973 esac
9974 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9975 $as_echo_n "checking for $ac_header... " >&6; }
9976 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9977   $as_echo_n "(cached) " >&6
9978 else
9979   eval "$as_ac_Header=\$ac_header_preproc"
9980 fi
9981 ac_res=`eval 'as_val=${'$as_ac_Header'}
9982                  $as_echo "$as_val"'`
9983                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9984 $as_echo "$ac_res" >&6; }
9985
9986 fi
9987 as_val=`eval 'as_val=${'$as_ac_Header'}
9988                  $as_echo "$as_val"'`
9989    if test "x$as_val" = x""yes; then
9990   cat >>confdefs.h <<_ACEOF
9991 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9992 _ACEOF
9993
9994 fi
9995
9996 done
9997
9998
9999 # On BSD, cpp test for net/if.h will fail unless sys/socket.h
10000 # is included first.
10001
10002 for ac_header in net/if.h
10003 do
10004 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10005 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10006 $as_echo_n "checking for $ac_header... " >&6; }
10007 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10008   $as_echo_n "(cached) " >&6
10009 else
10010   cat >conftest.$ac_ext <<_ACEOF
10011 /* confdefs.h.  */
10012 _ACEOF
10013 cat confdefs.h >>conftest.$ac_ext
10014 cat >>conftest.$ac_ext <<_ACEOF
10015 /* end confdefs.h.  */
10016 $ac_includes_default
10017 #ifdef HAVE_SYS_SOCKET_H
10018 #include <sys/socket.h>
10019 #endif
10020
10021
10022 #include <$ac_header>
10023 _ACEOF
10024 rm -f conftest.$ac_objext
10025 if { (ac_try="$ac_compile"
10026 case "(($ac_try" in
10027   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10028   *) ac_try_echo=$ac_try;;
10029 esac
10030 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10031 $as_echo "$ac_try_echo") >&5
10032   (eval "$ac_compile") 2>conftest.er1
10033   ac_status=$?
10034   grep -v '^ *+' conftest.er1 >conftest.err
10035   rm -f conftest.er1
10036   cat conftest.err >&5
10037   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10038   (exit $ac_status); } && {
10039          test -z "$ac_c_werror_flag" ||
10040          test ! -s conftest.err
10041        } && test -s conftest.$ac_objext; then
10042   eval "$as_ac_Header=yes"
10043 else
10044   $as_echo "$as_me: failed program was:" >&5
10045 sed 's/^/| /' conftest.$ac_ext >&5
10046
10047         eval "$as_ac_Header=no"
10048 fi
10049
10050 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10051 fi
10052 ac_res=`eval 'as_val=${'$as_ac_Header'}
10053                  $as_echo "$as_val"'`
10054                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10055 $as_echo "$ac_res" >&6; }
10056 as_val=`eval 'as_val=${'$as_ac_Header'}
10057                  $as_echo "$as_val"'`
10058    if test "x$as_val" = x""yes; then
10059   cat >>confdefs.h <<_ACEOF
10060 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10061 _ACEOF
10062
10063 fi
10064
10065 done
10066
10067
10068 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
10069 # netinet/in.h is included first.
10070
10071 for ac_header in netinet/in.h
10072 do
10073 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10074 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10075   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10076 $as_echo_n "checking for $ac_header... " >&6; }
10077 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10078   $as_echo_n "(cached) " >&6
10079 fi
10080 ac_res=`eval 'as_val=${'$as_ac_Header'}
10081                  $as_echo "$as_val"'`
10082                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10083 $as_echo "$ac_res" >&6; }
10084 else
10085   # Is the header compilable?
10086 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10087 $as_echo_n "checking $ac_header usability... " >&6; }
10088 cat >conftest.$ac_ext <<_ACEOF
10089 /* confdefs.h.  */
10090 _ACEOF
10091 cat confdefs.h >>conftest.$ac_ext
10092 cat >>conftest.$ac_ext <<_ACEOF
10093 /* end confdefs.h.  */
10094 $ac_includes_default
10095 #include <$ac_header>
10096 _ACEOF
10097 rm -f conftest.$ac_objext
10098 if { (ac_try="$ac_compile"
10099 case "(($ac_try" in
10100   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10101   *) ac_try_echo=$ac_try;;
10102 esac
10103 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10104 $as_echo "$ac_try_echo") >&5
10105   (eval "$ac_compile") 2>conftest.er1
10106   ac_status=$?
10107   grep -v '^ *+' conftest.er1 >conftest.err
10108   rm -f conftest.er1
10109   cat conftest.err >&5
10110   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10111   (exit $ac_status); } && {
10112          test -z "$ac_c_werror_flag" ||
10113          test ! -s conftest.err
10114        } && test -s conftest.$ac_objext; then
10115   ac_header_compiler=yes
10116 else
10117   $as_echo "$as_me: failed program was:" >&5
10118 sed 's/^/| /' conftest.$ac_ext >&5
10119
10120         ac_header_compiler=no
10121 fi
10122
10123 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10124 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10125 $as_echo "$ac_header_compiler" >&6; }
10126
10127 # Is the header present?
10128 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10129 $as_echo_n "checking $ac_header presence... " >&6; }
10130 cat >conftest.$ac_ext <<_ACEOF
10131 /* confdefs.h.  */
10132 _ACEOF
10133 cat confdefs.h >>conftest.$ac_ext
10134 cat >>conftest.$ac_ext <<_ACEOF
10135 /* end confdefs.h.  */
10136 #include <$ac_header>
10137 _ACEOF
10138 if { (ac_try="$ac_cpp conftest.$ac_ext"
10139 case "(($ac_try" in
10140   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10141   *) ac_try_echo=$ac_try;;
10142 esac
10143 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10144 $as_echo "$ac_try_echo") >&5
10145   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10146   ac_status=$?
10147   grep -v '^ *+' conftest.er1 >conftest.err
10148   rm -f conftest.er1
10149   cat conftest.err >&5
10150   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10151   (exit $ac_status); } >/dev/null && {
10152          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10153          test ! -s conftest.err
10154        }; then
10155   ac_header_preproc=yes
10156 else
10157   $as_echo "$as_me: failed program was:" >&5
10158 sed 's/^/| /' conftest.$ac_ext >&5
10159
10160   ac_header_preproc=no
10161 fi
10162
10163 rm -f conftest.err conftest.$ac_ext
10164 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10165 $as_echo "$ac_header_preproc" >&6; }
10166
10167 # So?  What about this header?
10168 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10169   yes:no: )
10170     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10171 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10172     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10173 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10174     ac_header_preproc=yes
10175     ;;
10176   no:yes:* )
10177     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10178 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10179     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10180 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10181     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10182 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10183     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10184 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10185     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10186 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10187     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10188 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10189     ( cat <<\_ASBOX
10190 ## ---------------------------------------- ##
10191 ## Report this to pgsql-bugs@postgresql.org ##
10192 ## ---------------------------------------- ##
10193 _ASBOX
10194      ) | sed "s/^/$as_me: WARNING:     /" >&2
10195     ;;
10196 esac
10197 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10198 $as_echo_n "checking for $ac_header... " >&6; }
10199 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10200   $as_echo_n "(cached) " >&6
10201 else
10202   eval "$as_ac_Header=\$ac_header_preproc"
10203 fi
10204 ac_res=`eval 'as_val=${'$as_ac_Header'}
10205                  $as_echo "$as_val"'`
10206                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10207 $as_echo "$ac_res" >&6; }
10208
10209 fi
10210 as_val=`eval 'as_val=${'$as_ac_Header'}
10211                  $as_echo "$as_val"'`
10212    if test "x$as_val" = x""yes; then
10213   cat >>confdefs.h <<_ACEOF
10214 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10215 _ACEOF
10216
10217 fi
10218
10219 done
10220
10221
10222 for ac_header in netinet/tcp.h
10223 do
10224 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10225 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10226 $as_echo_n "checking for $ac_header... " >&6; }
10227 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10228   $as_echo_n "(cached) " >&6
10229 else
10230   cat >conftest.$ac_ext <<_ACEOF
10231 /* confdefs.h.  */
10232 _ACEOF
10233 cat confdefs.h >>conftest.$ac_ext
10234 cat >>conftest.$ac_ext <<_ACEOF
10235 /* end confdefs.h.  */
10236 $ac_includes_default
10237 #ifdef HAVE_NETINET_IN_H
10238 #include <netinet/in.h>
10239 #endif
10240
10241
10242 #include <$ac_header>
10243 _ACEOF
10244 rm -f conftest.$ac_objext
10245 if { (ac_try="$ac_compile"
10246 case "(($ac_try" in
10247   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10248   *) ac_try_echo=$ac_try;;
10249 esac
10250 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10251 $as_echo "$ac_try_echo") >&5
10252   (eval "$ac_compile") 2>conftest.er1
10253   ac_status=$?
10254   grep -v '^ *+' conftest.er1 >conftest.err
10255   rm -f conftest.er1
10256   cat conftest.err >&5
10257   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10258   (exit $ac_status); } && {
10259          test -z "$ac_c_werror_flag" ||
10260          test ! -s conftest.err
10261        } && test -s conftest.$ac_objext; then
10262   eval "$as_ac_Header=yes"
10263 else
10264   $as_echo "$as_me: failed program was:" >&5
10265 sed 's/^/| /' conftest.$ac_ext >&5
10266
10267         eval "$as_ac_Header=no"
10268 fi
10269
10270 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10271 fi
10272 ac_res=`eval 'as_val=${'$as_ac_Header'}
10273                  $as_echo "$as_val"'`
10274                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10275 $as_echo "$ac_res" >&6; }
10276 as_val=`eval 'as_val=${'$as_ac_Header'}
10277                  $as_echo "$as_val"'`
10278    if test "x$as_val" = x""yes; then
10279   cat >>confdefs.h <<_ACEOF
10280 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10281 _ACEOF
10282
10283 fi
10284
10285 done
10286
10287
10288 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
10289
10290 for ac_header in readline/readline.h
10291 do
10292 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10293 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10294   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10295 $as_echo_n "checking for $ac_header... " >&6; }
10296 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10297   $as_echo_n "(cached) " >&6
10298 fi
10299 ac_res=`eval 'as_val=${'$as_ac_Header'}
10300                  $as_echo "$as_val"'`
10301                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10302 $as_echo "$ac_res" >&6; }
10303 else
10304   # Is the header compilable?
10305 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10306 $as_echo_n "checking $ac_header usability... " >&6; }
10307 cat >conftest.$ac_ext <<_ACEOF
10308 /* confdefs.h.  */
10309 _ACEOF
10310 cat confdefs.h >>conftest.$ac_ext
10311 cat >>conftest.$ac_ext <<_ACEOF
10312 /* end confdefs.h.  */
10313 $ac_includes_default
10314 #include <$ac_header>
10315 _ACEOF
10316 rm -f conftest.$ac_objext
10317 if { (ac_try="$ac_compile"
10318 case "(($ac_try" in
10319   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10320   *) ac_try_echo=$ac_try;;
10321 esac
10322 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10323 $as_echo "$ac_try_echo") >&5
10324   (eval "$ac_compile") 2>conftest.er1
10325   ac_status=$?
10326   grep -v '^ *+' conftest.er1 >conftest.err
10327   rm -f conftest.er1
10328   cat conftest.err >&5
10329   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10330   (exit $ac_status); } && {
10331          test -z "$ac_c_werror_flag" ||
10332          test ! -s conftest.err
10333        } && test -s conftest.$ac_objext; then
10334   ac_header_compiler=yes
10335 else
10336   $as_echo "$as_me: failed program was:" >&5
10337 sed 's/^/| /' conftest.$ac_ext >&5
10338
10339         ac_header_compiler=no
10340 fi
10341
10342 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10343 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10344 $as_echo "$ac_header_compiler" >&6; }
10345
10346 # Is the header present?
10347 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10348 $as_echo_n "checking $ac_header presence... " >&6; }
10349 cat >conftest.$ac_ext <<_ACEOF
10350 /* confdefs.h.  */
10351 _ACEOF
10352 cat confdefs.h >>conftest.$ac_ext
10353 cat >>conftest.$ac_ext <<_ACEOF
10354 /* end confdefs.h.  */
10355 #include <$ac_header>
10356 _ACEOF
10357 if { (ac_try="$ac_cpp conftest.$ac_ext"
10358 case "(($ac_try" in
10359   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10360   *) ac_try_echo=$ac_try;;
10361 esac
10362 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10363 $as_echo "$ac_try_echo") >&5
10364   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10365   ac_status=$?
10366   grep -v '^ *+' conftest.er1 >conftest.err
10367   rm -f conftest.er1
10368   cat conftest.err >&5
10369   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10370   (exit $ac_status); } >/dev/null && {
10371          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10372          test ! -s conftest.err
10373        }; then
10374   ac_header_preproc=yes
10375 else
10376   $as_echo "$as_me: failed program was:" >&5
10377 sed 's/^/| /' conftest.$ac_ext >&5
10378
10379   ac_header_preproc=no
10380 fi
10381
10382 rm -f conftest.err conftest.$ac_ext
10383 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10384 $as_echo "$ac_header_preproc" >&6; }
10385
10386 # So?  What about this header?
10387 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10388   yes:no: )
10389     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10390 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10391     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10392 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10393     ac_header_preproc=yes
10394     ;;
10395   no:yes:* )
10396     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10397 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10398     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10399 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10400     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10401 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10402     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10403 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10404     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10405 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10406     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10407 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10408     ( cat <<\_ASBOX
10409 ## ---------------------------------------- ##
10410 ## Report this to pgsql-bugs@postgresql.org ##
10411 ## ---------------------------------------- ##
10412 _ASBOX
10413      ) | sed "s/^/$as_me: WARNING:     /" >&2
10414     ;;
10415 esac
10416 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10417 $as_echo_n "checking for $ac_header... " >&6; }
10418 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10419   $as_echo_n "(cached) " >&6
10420 else
10421   eval "$as_ac_Header=\$ac_header_preproc"
10422 fi
10423 ac_res=`eval 'as_val=${'$as_ac_Header'}
10424                  $as_echo "$as_val"'`
10425                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10426 $as_echo "$ac_res" >&6; }
10427
10428 fi
10429 as_val=`eval 'as_val=${'$as_ac_Header'}
10430                  $as_echo "$as_val"'`
10431    if test "x$as_val" = x""yes; then
10432   cat >>confdefs.h <<_ACEOF
10433 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10434 _ACEOF
10435
10436 else
10437
10438 for ac_header in readline.h
10439 do
10440 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10441 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10442   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10443 $as_echo_n "checking for $ac_header... " >&6; }
10444 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10445   $as_echo_n "(cached) " >&6
10446 fi
10447 ac_res=`eval 'as_val=${'$as_ac_Header'}
10448                  $as_echo "$as_val"'`
10449                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10450 $as_echo "$ac_res" >&6; }
10451 else
10452   # Is the header compilable?
10453 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10454 $as_echo_n "checking $ac_header usability... " >&6; }
10455 cat >conftest.$ac_ext <<_ACEOF
10456 /* confdefs.h.  */
10457 _ACEOF
10458 cat confdefs.h >>conftest.$ac_ext
10459 cat >>conftest.$ac_ext <<_ACEOF
10460 /* end confdefs.h.  */
10461 $ac_includes_default
10462 #include <$ac_header>
10463 _ACEOF
10464 rm -f conftest.$ac_objext
10465 if { (ac_try="$ac_compile"
10466 case "(($ac_try" in
10467   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10468   *) ac_try_echo=$ac_try;;
10469 esac
10470 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10471 $as_echo "$ac_try_echo") >&5
10472   (eval "$ac_compile") 2>conftest.er1
10473   ac_status=$?
10474   grep -v '^ *+' conftest.er1 >conftest.err
10475   rm -f conftest.er1
10476   cat conftest.err >&5
10477   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10478   (exit $ac_status); } && {
10479          test -z "$ac_c_werror_flag" ||
10480          test ! -s conftest.err
10481        } && test -s conftest.$ac_objext; then
10482   ac_header_compiler=yes
10483 else
10484   $as_echo "$as_me: failed program was:" >&5
10485 sed 's/^/| /' conftest.$ac_ext >&5
10486
10487         ac_header_compiler=no
10488 fi
10489
10490 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10491 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10492 $as_echo "$ac_header_compiler" >&6; }
10493
10494 # Is the header present?
10495 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10496 $as_echo_n "checking $ac_header presence... " >&6; }
10497 cat >conftest.$ac_ext <<_ACEOF
10498 /* confdefs.h.  */
10499 _ACEOF
10500 cat confdefs.h >>conftest.$ac_ext
10501 cat >>conftest.$ac_ext <<_ACEOF
10502 /* end confdefs.h.  */
10503 #include <$ac_header>
10504 _ACEOF
10505 if { (ac_try="$ac_cpp conftest.$ac_ext"
10506 case "(($ac_try" in
10507   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10508   *) ac_try_echo=$ac_try;;
10509 esac
10510 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10511 $as_echo "$ac_try_echo") >&5
10512   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10513   ac_status=$?
10514   grep -v '^ *+' conftest.er1 >conftest.err
10515   rm -f conftest.er1
10516   cat conftest.err >&5
10517   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10518   (exit $ac_status); } >/dev/null && {
10519          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10520          test ! -s conftest.err
10521        }; then
10522   ac_header_preproc=yes
10523 else
10524   $as_echo "$as_me: failed program was:" >&5
10525 sed 's/^/| /' conftest.$ac_ext >&5
10526
10527   ac_header_preproc=no
10528 fi
10529
10530 rm -f conftest.err conftest.$ac_ext
10531 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10532 $as_echo "$ac_header_preproc" >&6; }
10533
10534 # So?  What about this header?
10535 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10536   yes:no: )
10537     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10538 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10539     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10540 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10541     ac_header_preproc=yes
10542     ;;
10543   no:yes:* )
10544     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10545 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10546     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10547 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10548     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10549 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10550     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10551 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10552     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10553 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10554     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10555 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10556     ( cat <<\_ASBOX
10557 ## ---------------------------------------- ##
10558 ## Report this to pgsql-bugs@postgresql.org ##
10559 ## ---------------------------------------- ##
10560 _ASBOX
10561      ) | sed "s/^/$as_me: WARNING:     /" >&2
10562     ;;
10563 esac
10564 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10565 $as_echo_n "checking for $ac_header... " >&6; }
10566 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10567   $as_echo_n "(cached) " >&6
10568 else
10569   eval "$as_ac_Header=\$ac_header_preproc"
10570 fi
10571 ac_res=`eval 'as_val=${'$as_ac_Header'}
10572                  $as_echo "$as_val"'`
10573                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10574 $as_echo "$ac_res" >&6; }
10575
10576 fi
10577 as_val=`eval 'as_val=${'$as_ac_Header'}
10578                  $as_echo "$as_val"'`
10579    if test "x$as_val" = x""yes; then
10580   cat >>confdefs.h <<_ACEOF
10581 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10582 _ACEOF
10583
10584 else
10585   { { $as_echo "$as_me:$LINENO: error: readline header not found
10586 If you have readline already installed, see config.log for details on the
10587 failure.  It is possible the compiler isn't looking in the proper directory.
10588 Use --without-readline to disable readline support." >&5
10589 $as_echo "$as_me: error: readline header not found
10590 If you have readline already installed, see config.log for details on the
10591 failure.  It is possible the compiler isn't looking in the proper directory.
10592 Use --without-readline to disable readline support." >&2;}
10593    { (exit 1); exit 1; }; }
10594 fi
10595
10596 done
10597
10598 fi
10599
10600 done
10601
10602
10603 for ac_header in readline/history.h
10604 do
10605 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10606 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10607   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10608 $as_echo_n "checking for $ac_header... " >&6; }
10609 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10610   $as_echo_n "(cached) " >&6
10611 fi
10612 ac_res=`eval 'as_val=${'$as_ac_Header'}
10613                  $as_echo "$as_val"'`
10614                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10615 $as_echo "$ac_res" >&6; }
10616 else
10617   # Is the header compilable?
10618 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10619 $as_echo_n "checking $ac_header usability... " >&6; }
10620 cat >conftest.$ac_ext <<_ACEOF
10621 /* confdefs.h.  */
10622 _ACEOF
10623 cat confdefs.h >>conftest.$ac_ext
10624 cat >>conftest.$ac_ext <<_ACEOF
10625 /* end confdefs.h.  */
10626 $ac_includes_default
10627 #include <$ac_header>
10628 _ACEOF
10629 rm -f conftest.$ac_objext
10630 if { (ac_try="$ac_compile"
10631 case "(($ac_try" in
10632   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10633   *) ac_try_echo=$ac_try;;
10634 esac
10635 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10636 $as_echo "$ac_try_echo") >&5
10637   (eval "$ac_compile") 2>conftest.er1
10638   ac_status=$?
10639   grep -v '^ *+' conftest.er1 >conftest.err
10640   rm -f conftest.er1
10641   cat conftest.err >&5
10642   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10643   (exit $ac_status); } && {
10644          test -z "$ac_c_werror_flag" ||
10645          test ! -s conftest.err
10646        } && test -s conftest.$ac_objext; then
10647   ac_header_compiler=yes
10648 else
10649   $as_echo "$as_me: failed program was:" >&5
10650 sed 's/^/| /' conftest.$ac_ext >&5
10651
10652         ac_header_compiler=no
10653 fi
10654
10655 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10656 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10657 $as_echo "$ac_header_compiler" >&6; }
10658
10659 # Is the header present?
10660 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10661 $as_echo_n "checking $ac_header presence... " >&6; }
10662 cat >conftest.$ac_ext <<_ACEOF
10663 /* confdefs.h.  */
10664 _ACEOF
10665 cat confdefs.h >>conftest.$ac_ext
10666 cat >>conftest.$ac_ext <<_ACEOF
10667 /* end confdefs.h.  */
10668 #include <$ac_header>
10669 _ACEOF
10670 if { (ac_try="$ac_cpp conftest.$ac_ext"
10671 case "(($ac_try" in
10672   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10673   *) ac_try_echo=$ac_try;;
10674 esac
10675 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10676 $as_echo "$ac_try_echo") >&5
10677   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10678   ac_status=$?
10679   grep -v '^ *+' conftest.er1 >conftest.err
10680   rm -f conftest.er1
10681   cat conftest.err >&5
10682   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10683   (exit $ac_status); } >/dev/null && {
10684          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10685          test ! -s conftest.err
10686        }; then
10687   ac_header_preproc=yes
10688 else
10689   $as_echo "$as_me: failed program was:" >&5
10690 sed 's/^/| /' conftest.$ac_ext >&5
10691
10692   ac_header_preproc=no
10693 fi
10694
10695 rm -f conftest.err conftest.$ac_ext
10696 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10697 $as_echo "$ac_header_preproc" >&6; }
10698
10699 # So?  What about this header?
10700 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10701   yes:no: )
10702     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10703 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10704     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10705 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10706     ac_header_preproc=yes
10707     ;;
10708   no:yes:* )
10709     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10710 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10711     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10712 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10713     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10714 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10715     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10716 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10717     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10718 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10719     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10720 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10721     ( cat <<\_ASBOX
10722 ## ---------------------------------------- ##
10723 ## Report this to pgsql-bugs@postgresql.org ##
10724 ## ---------------------------------------- ##
10725 _ASBOX
10726      ) | sed "s/^/$as_me: WARNING:     /" >&2
10727     ;;
10728 esac
10729 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10730 $as_echo_n "checking for $ac_header... " >&6; }
10731 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10732   $as_echo_n "(cached) " >&6
10733 else
10734   eval "$as_ac_Header=\$ac_header_preproc"
10735 fi
10736 ac_res=`eval 'as_val=${'$as_ac_Header'}
10737                  $as_echo "$as_val"'`
10738                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10739 $as_echo "$ac_res" >&6; }
10740
10741 fi
10742 as_val=`eval 'as_val=${'$as_ac_Header'}
10743                  $as_echo "$as_val"'`
10744    if test "x$as_val" = x""yes; then
10745   cat >>confdefs.h <<_ACEOF
10746 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10747 _ACEOF
10748
10749 else
10750
10751 for ac_header in history.h
10752 do
10753 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10754 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10755   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10756 $as_echo_n "checking for $ac_header... " >&6; }
10757 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10758   $as_echo_n "(cached) " >&6
10759 fi
10760 ac_res=`eval 'as_val=${'$as_ac_Header'}
10761                  $as_echo "$as_val"'`
10762                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10763 $as_echo "$ac_res" >&6; }
10764 else
10765   # Is the header compilable?
10766 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10767 $as_echo_n "checking $ac_header usability... " >&6; }
10768 cat >conftest.$ac_ext <<_ACEOF
10769 /* confdefs.h.  */
10770 _ACEOF
10771 cat confdefs.h >>conftest.$ac_ext
10772 cat >>conftest.$ac_ext <<_ACEOF
10773 /* end confdefs.h.  */
10774 $ac_includes_default
10775 #include <$ac_header>
10776 _ACEOF
10777 rm -f conftest.$ac_objext
10778 if { (ac_try="$ac_compile"
10779 case "(($ac_try" in
10780   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10781   *) ac_try_echo=$ac_try;;
10782 esac
10783 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10784 $as_echo "$ac_try_echo") >&5
10785   (eval "$ac_compile") 2>conftest.er1
10786   ac_status=$?
10787   grep -v '^ *+' conftest.er1 >conftest.err
10788   rm -f conftest.er1
10789   cat conftest.err >&5
10790   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10791   (exit $ac_status); } && {
10792          test -z "$ac_c_werror_flag" ||
10793          test ! -s conftest.err
10794        } && test -s conftest.$ac_objext; then
10795   ac_header_compiler=yes
10796 else
10797   $as_echo "$as_me: failed program was:" >&5
10798 sed 's/^/| /' conftest.$ac_ext >&5
10799
10800         ac_header_compiler=no
10801 fi
10802
10803 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10804 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10805 $as_echo "$ac_header_compiler" >&6; }
10806
10807 # Is the header present?
10808 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10809 $as_echo_n "checking $ac_header presence... " >&6; }
10810 cat >conftest.$ac_ext <<_ACEOF
10811 /* confdefs.h.  */
10812 _ACEOF
10813 cat confdefs.h >>conftest.$ac_ext
10814 cat >>conftest.$ac_ext <<_ACEOF
10815 /* end confdefs.h.  */
10816 #include <$ac_header>
10817 _ACEOF
10818 if { (ac_try="$ac_cpp conftest.$ac_ext"
10819 case "(($ac_try" in
10820   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10821   *) ac_try_echo=$ac_try;;
10822 esac
10823 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10824 $as_echo "$ac_try_echo") >&5
10825   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10826   ac_status=$?
10827   grep -v '^ *+' conftest.er1 >conftest.err
10828   rm -f conftest.er1
10829   cat conftest.err >&5
10830   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10831   (exit $ac_status); } >/dev/null && {
10832          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10833          test ! -s conftest.err
10834        }; then
10835   ac_header_preproc=yes
10836 else
10837   $as_echo "$as_me: failed program was:" >&5
10838 sed 's/^/| /' conftest.$ac_ext >&5
10839
10840   ac_header_preproc=no
10841 fi
10842
10843 rm -f conftest.err conftest.$ac_ext
10844 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10845 $as_echo "$ac_header_preproc" >&6; }
10846
10847 # So?  What about this header?
10848 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10849   yes:no: )
10850     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10851 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10852     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10853 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10854     ac_header_preproc=yes
10855     ;;
10856   no:yes:* )
10857     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10858 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10859     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10860 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10861     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10862 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10863     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10864 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10865     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10866 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10867     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10868 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10869     ( cat <<\_ASBOX
10870 ## ---------------------------------------- ##
10871 ## Report this to pgsql-bugs@postgresql.org ##
10872 ## ---------------------------------------- ##
10873 _ASBOX
10874      ) | sed "s/^/$as_me: WARNING:     /" >&2
10875     ;;
10876 esac
10877 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10878 $as_echo_n "checking for $ac_header... " >&6; }
10879 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10880   $as_echo_n "(cached) " >&6
10881 else
10882   eval "$as_ac_Header=\$ac_header_preproc"
10883 fi
10884 ac_res=`eval 'as_val=${'$as_ac_Header'}
10885                  $as_echo "$as_val"'`
10886                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10887 $as_echo "$ac_res" >&6; }
10888
10889 fi
10890 as_val=`eval 'as_val=${'$as_ac_Header'}
10891                  $as_echo "$as_val"'`
10892    if test "x$as_val" = x""yes; then
10893   cat >>confdefs.h <<_ACEOF
10894 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10895 _ACEOF
10896
10897 else
10898   { { $as_echo "$as_me:$LINENO: error: history header not found
10899 If you have readline already installed, see config.log for details on the
10900 failure.  It is possible the compiler isn't looking in the proper directory.
10901 Use --without-readline to disable readline support." >&5
10902 $as_echo "$as_me: error: history header not found
10903 If you have readline already installed, see config.log for details on the
10904 failure.  It is possible the compiler isn't looking in the proper directory.
10905 Use --without-readline to disable readline support." >&2;}
10906    { (exit 1); exit 1; }; }
10907 fi
10908
10909 done
10910
10911 fi
10912
10913 done
10914
10915 fi
10916
10917 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
10918 # Some installations of libedit usurp /usr/include/readline/, which seems
10919 # bad practice, since in combined installations readline will have its headers
10920 # there.  We might have to resort to AC_EGREP checks to make sure we found
10921 # the proper header...
10922
10923 for ac_header in editline/readline.h
10924 do
10925 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10926 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10927   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10928 $as_echo_n "checking for $ac_header... " >&6; }
10929 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10930   $as_echo_n "(cached) " >&6
10931 fi
10932 ac_res=`eval 'as_val=${'$as_ac_Header'}
10933                  $as_echo "$as_val"'`
10934                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10935 $as_echo "$ac_res" >&6; }
10936 else
10937   # Is the header compilable?
10938 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10939 $as_echo_n "checking $ac_header usability... " >&6; }
10940 cat >conftest.$ac_ext <<_ACEOF
10941 /* confdefs.h.  */
10942 _ACEOF
10943 cat confdefs.h >>conftest.$ac_ext
10944 cat >>conftest.$ac_ext <<_ACEOF
10945 /* end confdefs.h.  */
10946 $ac_includes_default
10947 #include <$ac_header>
10948 _ACEOF
10949 rm -f conftest.$ac_objext
10950 if { (ac_try="$ac_compile"
10951 case "(($ac_try" in
10952   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10953   *) ac_try_echo=$ac_try;;
10954 esac
10955 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10956 $as_echo "$ac_try_echo") >&5
10957   (eval "$ac_compile") 2>conftest.er1
10958   ac_status=$?
10959   grep -v '^ *+' conftest.er1 >conftest.err
10960   rm -f conftest.er1
10961   cat conftest.err >&5
10962   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10963   (exit $ac_status); } && {
10964          test -z "$ac_c_werror_flag" ||
10965          test ! -s conftest.err
10966        } && test -s conftest.$ac_objext; then
10967   ac_header_compiler=yes
10968 else
10969   $as_echo "$as_me: failed program was:" >&5
10970 sed 's/^/| /' conftest.$ac_ext >&5
10971
10972         ac_header_compiler=no
10973 fi
10974
10975 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10976 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10977 $as_echo "$ac_header_compiler" >&6; }
10978
10979 # Is the header present?
10980 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10981 $as_echo_n "checking $ac_header presence... " >&6; }
10982 cat >conftest.$ac_ext <<_ACEOF
10983 /* confdefs.h.  */
10984 _ACEOF
10985 cat confdefs.h >>conftest.$ac_ext
10986 cat >>conftest.$ac_ext <<_ACEOF
10987 /* end confdefs.h.  */
10988 #include <$ac_header>
10989 _ACEOF
10990 if { (ac_try="$ac_cpp conftest.$ac_ext"
10991 case "(($ac_try" in
10992   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10993   *) ac_try_echo=$ac_try;;
10994 esac
10995 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10996 $as_echo "$ac_try_echo") >&5
10997   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10998   ac_status=$?
10999   grep -v '^ *+' conftest.er1 >conftest.err
11000   rm -f conftest.er1
11001   cat conftest.err >&5
11002   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11003   (exit $ac_status); } >/dev/null && {
11004          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11005          test ! -s conftest.err
11006        }; then
11007   ac_header_preproc=yes
11008 else
11009   $as_echo "$as_me: failed program was:" >&5
11010 sed 's/^/| /' conftest.$ac_ext >&5
11011
11012   ac_header_preproc=no
11013 fi
11014
11015 rm -f conftest.err conftest.$ac_ext
11016 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11017 $as_echo "$ac_header_preproc" >&6; }
11018
11019 # So?  What about this header?
11020 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11021   yes:no: )
11022     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11023 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11024     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11025 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11026     ac_header_preproc=yes
11027     ;;
11028   no:yes:* )
11029     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11030 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11031     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11032 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11033     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11034 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11035     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11036 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11037     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11038 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11039     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11040 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11041     ( cat <<\_ASBOX
11042 ## ---------------------------------------- ##
11043 ## Report this to pgsql-bugs@postgresql.org ##
11044 ## ---------------------------------------- ##
11045 _ASBOX
11046      ) | sed "s/^/$as_me: WARNING:     /" >&2
11047     ;;
11048 esac
11049 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11050 $as_echo_n "checking for $ac_header... " >&6; }
11051 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11052   $as_echo_n "(cached) " >&6
11053 else
11054   eval "$as_ac_Header=\$ac_header_preproc"
11055 fi
11056 ac_res=`eval 'as_val=${'$as_ac_Header'}
11057                  $as_echo "$as_val"'`
11058                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11059 $as_echo "$ac_res" >&6; }
11060
11061 fi
11062 as_val=`eval 'as_val=${'$as_ac_Header'}
11063                  $as_echo "$as_val"'`
11064    if test "x$as_val" = x""yes; then
11065   cat >>confdefs.h <<_ACEOF
11066 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11067 _ACEOF
11068
11069 else
11070
11071 for ac_header in readline.h
11072 do
11073 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11074 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11075   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11076 $as_echo_n "checking for $ac_header... " >&6; }
11077 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11078   $as_echo_n "(cached) " >&6
11079 fi
11080 ac_res=`eval 'as_val=${'$as_ac_Header'}
11081                  $as_echo "$as_val"'`
11082                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11083 $as_echo "$ac_res" >&6; }
11084 else
11085   # Is the header compilable?
11086 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11087 $as_echo_n "checking $ac_header usability... " >&6; }
11088 cat >conftest.$ac_ext <<_ACEOF
11089 /* confdefs.h.  */
11090 _ACEOF
11091 cat confdefs.h >>conftest.$ac_ext
11092 cat >>conftest.$ac_ext <<_ACEOF
11093 /* end confdefs.h.  */
11094 $ac_includes_default
11095 #include <$ac_header>
11096 _ACEOF
11097 rm -f conftest.$ac_objext
11098 if { (ac_try="$ac_compile"
11099 case "(($ac_try" in
11100   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11101   *) ac_try_echo=$ac_try;;
11102 esac
11103 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11104 $as_echo "$ac_try_echo") >&5
11105   (eval "$ac_compile") 2>conftest.er1
11106   ac_status=$?
11107   grep -v '^ *+' conftest.er1 >conftest.err
11108   rm -f conftest.er1
11109   cat conftest.err >&5
11110   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11111   (exit $ac_status); } && {
11112          test -z "$ac_c_werror_flag" ||
11113          test ! -s conftest.err
11114        } && test -s conftest.$ac_objext; then
11115   ac_header_compiler=yes
11116 else
11117   $as_echo "$as_me: failed program was:" >&5
11118 sed 's/^/| /' conftest.$ac_ext >&5
11119
11120         ac_header_compiler=no
11121 fi
11122
11123 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11124 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11125 $as_echo "$ac_header_compiler" >&6; }
11126
11127 # Is the header present?
11128 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11129 $as_echo_n "checking $ac_header presence... " >&6; }
11130 cat >conftest.$ac_ext <<_ACEOF
11131 /* confdefs.h.  */
11132 _ACEOF
11133 cat confdefs.h >>conftest.$ac_ext
11134 cat >>conftest.$ac_ext <<_ACEOF
11135 /* end confdefs.h.  */
11136 #include <$ac_header>
11137 _ACEOF
11138 if { (ac_try="$ac_cpp conftest.$ac_ext"
11139 case "(($ac_try" in
11140   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11141   *) ac_try_echo=$ac_try;;
11142 esac
11143 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11144 $as_echo "$ac_try_echo") >&5
11145   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11146   ac_status=$?
11147   grep -v '^ *+' conftest.er1 >conftest.err
11148   rm -f conftest.er1
11149   cat conftest.err >&5
11150   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11151   (exit $ac_status); } >/dev/null && {
11152          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11153          test ! -s conftest.err
11154        }; then
11155   ac_header_preproc=yes
11156 else
11157   $as_echo "$as_me: failed program was:" >&5
11158 sed 's/^/| /' conftest.$ac_ext >&5
11159
11160   ac_header_preproc=no
11161 fi
11162
11163 rm -f conftest.err conftest.$ac_ext
11164 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11165 $as_echo "$ac_header_preproc" >&6; }
11166
11167 # So?  What about this header?
11168 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11169   yes:no: )
11170     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11171 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11172     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11173 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11174     ac_header_preproc=yes
11175     ;;
11176   no:yes:* )
11177     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11178 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11179     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11180 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11181     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11182 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11183     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11184 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11185     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11186 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11187     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11188 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11189     ( cat <<\_ASBOX
11190 ## ---------------------------------------- ##
11191 ## Report this to pgsql-bugs@postgresql.org ##
11192 ## ---------------------------------------- ##
11193 _ASBOX
11194      ) | sed "s/^/$as_me: WARNING:     /" >&2
11195     ;;
11196 esac
11197 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11198 $as_echo_n "checking for $ac_header... " >&6; }
11199 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11200   $as_echo_n "(cached) " >&6
11201 else
11202   eval "$as_ac_Header=\$ac_header_preproc"
11203 fi
11204 ac_res=`eval 'as_val=${'$as_ac_Header'}
11205                  $as_echo "$as_val"'`
11206                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11207 $as_echo "$ac_res" >&6; }
11208
11209 fi
11210 as_val=`eval 'as_val=${'$as_ac_Header'}
11211                  $as_echo "$as_val"'`
11212    if test "x$as_val" = x""yes; then
11213   cat >>confdefs.h <<_ACEOF
11214 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11215 _ACEOF
11216
11217 else
11218
11219 for ac_header in readline/readline.h
11220 do
11221 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11222 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11223   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11224 $as_echo_n "checking for $ac_header... " >&6; }
11225 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11226   $as_echo_n "(cached) " >&6
11227 fi
11228 ac_res=`eval 'as_val=${'$as_ac_Header'}
11229                  $as_echo "$as_val"'`
11230                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11231 $as_echo "$ac_res" >&6; }
11232 else
11233   # Is the header compilable?
11234 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11235 $as_echo_n "checking $ac_header usability... " >&6; }
11236 cat >conftest.$ac_ext <<_ACEOF
11237 /* confdefs.h.  */
11238 _ACEOF
11239 cat confdefs.h >>conftest.$ac_ext
11240 cat >>conftest.$ac_ext <<_ACEOF
11241 /* end confdefs.h.  */
11242 $ac_includes_default
11243 #include <$ac_header>
11244 _ACEOF
11245 rm -f conftest.$ac_objext
11246 if { (ac_try="$ac_compile"
11247 case "(($ac_try" in
11248   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11249   *) ac_try_echo=$ac_try;;
11250 esac
11251 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11252 $as_echo "$ac_try_echo") >&5
11253   (eval "$ac_compile") 2>conftest.er1
11254   ac_status=$?
11255   grep -v '^ *+' conftest.er1 >conftest.err
11256   rm -f conftest.er1
11257   cat conftest.err >&5
11258   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11259   (exit $ac_status); } && {
11260          test -z "$ac_c_werror_flag" ||
11261          test ! -s conftest.err
11262        } && test -s conftest.$ac_objext; then
11263   ac_header_compiler=yes
11264 else
11265   $as_echo "$as_me: failed program was:" >&5
11266 sed 's/^/| /' conftest.$ac_ext >&5
11267
11268         ac_header_compiler=no
11269 fi
11270
11271 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11272 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11273 $as_echo "$ac_header_compiler" >&6; }
11274
11275 # Is the header present?
11276 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11277 $as_echo_n "checking $ac_header presence... " >&6; }
11278 cat >conftest.$ac_ext <<_ACEOF
11279 /* confdefs.h.  */
11280 _ACEOF
11281 cat confdefs.h >>conftest.$ac_ext
11282 cat >>conftest.$ac_ext <<_ACEOF
11283 /* end confdefs.h.  */
11284 #include <$ac_header>
11285 _ACEOF
11286 if { (ac_try="$ac_cpp conftest.$ac_ext"
11287 case "(($ac_try" in
11288   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11289   *) ac_try_echo=$ac_try;;
11290 esac
11291 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11292 $as_echo "$ac_try_echo") >&5
11293   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11294   ac_status=$?
11295   grep -v '^ *+' conftest.er1 >conftest.err
11296   rm -f conftest.er1
11297   cat conftest.err >&5
11298   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11299   (exit $ac_status); } >/dev/null && {
11300          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11301          test ! -s conftest.err
11302        }; then
11303   ac_header_preproc=yes
11304 else
11305   $as_echo "$as_me: failed program was:" >&5
11306 sed 's/^/| /' conftest.$ac_ext >&5
11307
11308   ac_header_preproc=no
11309 fi
11310
11311 rm -f conftest.err conftest.$ac_ext
11312 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11313 $as_echo "$ac_header_preproc" >&6; }
11314
11315 # So?  What about this header?
11316 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11317   yes:no: )
11318     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11319 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11320     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11321 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11322     ac_header_preproc=yes
11323     ;;
11324   no:yes:* )
11325     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11326 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11327     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11328 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11329     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11330 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11331     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11332 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11333     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11334 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11335     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11336 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11337     ( cat <<\_ASBOX
11338 ## ---------------------------------------- ##
11339 ## Report this to pgsql-bugs@postgresql.org ##
11340 ## ---------------------------------------- ##
11341 _ASBOX
11342      ) | sed "s/^/$as_me: WARNING:     /" >&2
11343     ;;
11344 esac
11345 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11346 $as_echo_n "checking for $ac_header... " >&6; }
11347 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11348   $as_echo_n "(cached) " >&6
11349 else
11350   eval "$as_ac_Header=\$ac_header_preproc"
11351 fi
11352 ac_res=`eval 'as_val=${'$as_ac_Header'}
11353                  $as_echo "$as_val"'`
11354                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11355 $as_echo "$ac_res" >&6; }
11356
11357 fi
11358 as_val=`eval 'as_val=${'$as_ac_Header'}
11359                  $as_echo "$as_val"'`
11360    if test "x$as_val" = x""yes; then
11361   cat >>confdefs.h <<_ACEOF
11362 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11363 _ACEOF
11364
11365 else
11366   { { $as_echo "$as_me:$LINENO: error: readline header not found
11367 If you have libedit already installed, see config.log for details on the
11368 failure.  It is possible the compiler isn't looking in the proper directory.
11369 Use --without-readline to disable libedit support." >&5
11370 $as_echo "$as_me: error: readline header not found
11371 If you have libedit already installed, see config.log for details on the
11372 failure.  It is possible the compiler isn't looking in the proper directory.
11373 Use --without-readline to disable libedit support." >&2;}
11374    { (exit 1); exit 1; }; }
11375 fi
11376
11377 done
11378
11379 fi
11380
11381 done
11382
11383 fi
11384
11385 done
11386
11387 # Note: in a libedit installation, history.h is sometimes a dummy, and may
11388 # not be there at all.  Hence, don't complain if not found.  We must check
11389 # though, since in yet other versions it is an independent header.
11390
11391 for ac_header in editline/history.h
11392 do
11393 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11394 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11395   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11396 $as_echo_n "checking for $ac_header... " >&6; }
11397 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11398   $as_echo_n "(cached) " >&6
11399 fi
11400 ac_res=`eval 'as_val=${'$as_ac_Header'}
11401                  $as_echo "$as_val"'`
11402                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11403 $as_echo "$ac_res" >&6; }
11404 else
11405   # Is the header compilable?
11406 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11407 $as_echo_n "checking $ac_header usability... " >&6; }
11408 cat >conftest.$ac_ext <<_ACEOF
11409 /* confdefs.h.  */
11410 _ACEOF
11411 cat confdefs.h >>conftest.$ac_ext
11412 cat >>conftest.$ac_ext <<_ACEOF
11413 /* end confdefs.h.  */
11414 $ac_includes_default
11415 #include <$ac_header>
11416 _ACEOF
11417 rm -f conftest.$ac_objext
11418 if { (ac_try="$ac_compile"
11419 case "(($ac_try" in
11420   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11421   *) ac_try_echo=$ac_try;;
11422 esac
11423 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11424 $as_echo "$ac_try_echo") >&5
11425   (eval "$ac_compile") 2>conftest.er1
11426   ac_status=$?
11427   grep -v '^ *+' conftest.er1 >conftest.err
11428   rm -f conftest.er1
11429   cat conftest.err >&5
11430   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11431   (exit $ac_status); } && {
11432          test -z "$ac_c_werror_flag" ||
11433          test ! -s conftest.err
11434        } && test -s conftest.$ac_objext; then
11435   ac_header_compiler=yes
11436 else
11437   $as_echo "$as_me: failed program was:" >&5
11438 sed 's/^/| /' conftest.$ac_ext >&5
11439
11440         ac_header_compiler=no
11441 fi
11442
11443 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11444 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11445 $as_echo "$ac_header_compiler" >&6; }
11446
11447 # Is the header present?
11448 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11449 $as_echo_n "checking $ac_header presence... " >&6; }
11450 cat >conftest.$ac_ext <<_ACEOF
11451 /* confdefs.h.  */
11452 _ACEOF
11453 cat confdefs.h >>conftest.$ac_ext
11454 cat >>conftest.$ac_ext <<_ACEOF
11455 /* end confdefs.h.  */
11456 #include <$ac_header>
11457 _ACEOF
11458 if { (ac_try="$ac_cpp conftest.$ac_ext"
11459 case "(($ac_try" in
11460   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11461   *) ac_try_echo=$ac_try;;
11462 esac
11463 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11464 $as_echo "$ac_try_echo") >&5
11465   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11466   ac_status=$?
11467   grep -v '^ *+' conftest.er1 >conftest.err
11468   rm -f conftest.er1
11469   cat conftest.err >&5
11470   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11471   (exit $ac_status); } >/dev/null && {
11472          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11473          test ! -s conftest.err
11474        }; then
11475   ac_header_preproc=yes
11476 else
11477   $as_echo "$as_me: failed program was:" >&5
11478 sed 's/^/| /' conftest.$ac_ext >&5
11479
11480   ac_header_preproc=no
11481 fi
11482
11483 rm -f conftest.err conftest.$ac_ext
11484 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11485 $as_echo "$ac_header_preproc" >&6; }
11486
11487 # So?  What about this header?
11488 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11489   yes:no: )
11490     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11491 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11492     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11493 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11494     ac_header_preproc=yes
11495     ;;
11496   no:yes:* )
11497     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11498 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11499     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11500 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11501     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11502 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11503     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11504 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11505     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11506 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11507     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11508 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11509     ( cat <<\_ASBOX
11510 ## ---------------------------------------- ##
11511 ## Report this to pgsql-bugs@postgresql.org ##
11512 ## ---------------------------------------- ##
11513 _ASBOX
11514      ) | sed "s/^/$as_me: WARNING:     /" >&2
11515     ;;
11516 esac
11517 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11518 $as_echo_n "checking for $ac_header... " >&6; }
11519 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11520   $as_echo_n "(cached) " >&6
11521 else
11522   eval "$as_ac_Header=\$ac_header_preproc"
11523 fi
11524 ac_res=`eval 'as_val=${'$as_ac_Header'}
11525                  $as_echo "$as_val"'`
11526                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11527 $as_echo "$ac_res" >&6; }
11528
11529 fi
11530 as_val=`eval 'as_val=${'$as_ac_Header'}
11531                  $as_echo "$as_val"'`
11532    if test "x$as_val" = x""yes; then
11533   cat >>confdefs.h <<_ACEOF
11534 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11535 _ACEOF
11536
11537 else
11538
11539 for ac_header in history.h
11540 do
11541 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11542 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11543   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11544 $as_echo_n "checking for $ac_header... " >&6; }
11545 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11546   $as_echo_n "(cached) " >&6
11547 fi
11548 ac_res=`eval 'as_val=${'$as_ac_Header'}
11549                  $as_echo "$as_val"'`
11550                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11551 $as_echo "$ac_res" >&6; }
11552 else
11553   # Is the header compilable?
11554 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11555 $as_echo_n "checking $ac_header usability... " >&6; }
11556 cat >conftest.$ac_ext <<_ACEOF
11557 /* confdefs.h.  */
11558 _ACEOF
11559 cat confdefs.h >>conftest.$ac_ext
11560 cat >>conftest.$ac_ext <<_ACEOF
11561 /* end confdefs.h.  */
11562 $ac_includes_default
11563 #include <$ac_header>
11564 _ACEOF
11565 rm -f conftest.$ac_objext
11566 if { (ac_try="$ac_compile"
11567 case "(($ac_try" in
11568   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11569   *) ac_try_echo=$ac_try;;
11570 esac
11571 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11572 $as_echo "$ac_try_echo") >&5
11573   (eval "$ac_compile") 2>conftest.er1
11574   ac_status=$?
11575   grep -v '^ *+' conftest.er1 >conftest.err
11576   rm -f conftest.er1
11577   cat conftest.err >&5
11578   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11579   (exit $ac_status); } && {
11580          test -z "$ac_c_werror_flag" ||
11581          test ! -s conftest.err
11582        } && test -s conftest.$ac_objext; then
11583   ac_header_compiler=yes
11584 else
11585   $as_echo "$as_me: failed program was:" >&5
11586 sed 's/^/| /' conftest.$ac_ext >&5
11587
11588         ac_header_compiler=no
11589 fi
11590
11591 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11592 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11593 $as_echo "$ac_header_compiler" >&6; }
11594
11595 # Is the header present?
11596 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11597 $as_echo_n "checking $ac_header presence... " >&6; }
11598 cat >conftest.$ac_ext <<_ACEOF
11599 /* confdefs.h.  */
11600 _ACEOF
11601 cat confdefs.h >>conftest.$ac_ext
11602 cat >>conftest.$ac_ext <<_ACEOF
11603 /* end confdefs.h.  */
11604 #include <$ac_header>
11605 _ACEOF
11606 if { (ac_try="$ac_cpp conftest.$ac_ext"
11607 case "(($ac_try" in
11608   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11609   *) ac_try_echo=$ac_try;;
11610 esac
11611 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11612 $as_echo "$ac_try_echo") >&5
11613   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11614   ac_status=$?
11615   grep -v '^ *+' conftest.er1 >conftest.err
11616   rm -f conftest.er1
11617   cat conftest.err >&5
11618   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11619   (exit $ac_status); } >/dev/null && {
11620          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11621          test ! -s conftest.err
11622        }; then
11623   ac_header_preproc=yes
11624 else
11625   $as_echo "$as_me: failed program was:" >&5
11626 sed 's/^/| /' conftest.$ac_ext >&5
11627
11628   ac_header_preproc=no
11629 fi
11630
11631 rm -f conftest.err conftest.$ac_ext
11632 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11633 $as_echo "$ac_header_preproc" >&6; }
11634
11635 # So?  What about this header?
11636 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11637   yes:no: )
11638     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11639 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11640     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11641 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11642     ac_header_preproc=yes
11643     ;;
11644   no:yes:* )
11645     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11646 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11647     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11648 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11649     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11650 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11651     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11652 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11653     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11654 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11655     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11656 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11657     ( cat <<\_ASBOX
11658 ## ---------------------------------------- ##
11659 ## Report this to pgsql-bugs@postgresql.org ##
11660 ## ---------------------------------------- ##
11661 _ASBOX
11662      ) | sed "s/^/$as_me: WARNING:     /" >&2
11663     ;;
11664 esac
11665 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11666 $as_echo_n "checking for $ac_header... " >&6; }
11667 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11668   $as_echo_n "(cached) " >&6
11669 else
11670   eval "$as_ac_Header=\$ac_header_preproc"
11671 fi
11672 ac_res=`eval 'as_val=${'$as_ac_Header'}
11673                  $as_echo "$as_val"'`
11674                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11675 $as_echo "$ac_res" >&6; }
11676
11677 fi
11678 as_val=`eval 'as_val=${'$as_ac_Header'}
11679                  $as_echo "$as_val"'`
11680    if test "x$as_val" = x""yes; then
11681   cat >>confdefs.h <<_ACEOF
11682 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11683 _ACEOF
11684
11685 else
11686
11687 for ac_header in readline/history.h
11688 do
11689 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11690 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11691   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11692 $as_echo_n "checking for $ac_header... " >&6; }
11693 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11694   $as_echo_n "(cached) " >&6
11695 fi
11696 ac_res=`eval 'as_val=${'$as_ac_Header'}
11697                  $as_echo "$as_val"'`
11698                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11699 $as_echo "$ac_res" >&6; }
11700 else
11701   # Is the header compilable?
11702 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11703 $as_echo_n "checking $ac_header usability... " >&6; }
11704 cat >conftest.$ac_ext <<_ACEOF
11705 /* confdefs.h.  */
11706 _ACEOF
11707 cat confdefs.h >>conftest.$ac_ext
11708 cat >>conftest.$ac_ext <<_ACEOF
11709 /* end confdefs.h.  */
11710 $ac_includes_default
11711 #include <$ac_header>
11712 _ACEOF
11713 rm -f conftest.$ac_objext
11714 if { (ac_try="$ac_compile"
11715 case "(($ac_try" in
11716   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11717   *) ac_try_echo=$ac_try;;
11718 esac
11719 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11720 $as_echo "$ac_try_echo") >&5
11721   (eval "$ac_compile") 2>conftest.er1
11722   ac_status=$?
11723   grep -v '^ *+' conftest.er1 >conftest.err
11724   rm -f conftest.er1
11725   cat conftest.err >&5
11726   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11727   (exit $ac_status); } && {
11728          test -z "$ac_c_werror_flag" ||
11729          test ! -s conftest.err
11730        } && test -s conftest.$ac_objext; then
11731   ac_header_compiler=yes
11732 else
11733   $as_echo "$as_me: failed program was:" >&5
11734 sed 's/^/| /' conftest.$ac_ext >&5
11735
11736         ac_header_compiler=no
11737 fi
11738
11739 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11740 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11741 $as_echo "$ac_header_compiler" >&6; }
11742
11743 # Is the header present?
11744 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11745 $as_echo_n "checking $ac_header presence... " >&6; }
11746 cat >conftest.$ac_ext <<_ACEOF
11747 /* confdefs.h.  */
11748 _ACEOF
11749 cat confdefs.h >>conftest.$ac_ext
11750 cat >>conftest.$ac_ext <<_ACEOF
11751 /* end confdefs.h.  */
11752 #include <$ac_header>
11753 _ACEOF
11754 if { (ac_try="$ac_cpp conftest.$ac_ext"
11755 case "(($ac_try" in
11756   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11757   *) ac_try_echo=$ac_try;;
11758 esac
11759 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11760 $as_echo "$ac_try_echo") >&5
11761   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11762   ac_status=$?
11763   grep -v '^ *+' conftest.er1 >conftest.err
11764   rm -f conftest.er1
11765   cat conftest.err >&5
11766   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11767   (exit $ac_status); } >/dev/null && {
11768          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11769          test ! -s conftest.err
11770        }; then
11771   ac_header_preproc=yes
11772 else
11773   $as_echo "$as_me: failed program was:" >&5
11774 sed 's/^/| /' conftest.$ac_ext >&5
11775
11776   ac_header_preproc=no
11777 fi
11778
11779 rm -f conftest.err conftest.$ac_ext
11780 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11781 $as_echo "$ac_header_preproc" >&6; }
11782
11783 # So?  What about this header?
11784 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11785   yes:no: )
11786     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11787 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11788     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11789 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11790     ac_header_preproc=yes
11791     ;;
11792   no:yes:* )
11793     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11794 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11795     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11796 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11797     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11798 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11799     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11800 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11801     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11802 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11803     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11804 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11805     ( cat <<\_ASBOX
11806 ## ---------------------------------------- ##
11807 ## Report this to pgsql-bugs@postgresql.org ##
11808 ## ---------------------------------------- ##
11809 _ASBOX
11810      ) | sed "s/^/$as_me: WARNING:     /" >&2
11811     ;;
11812 esac
11813 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11814 $as_echo_n "checking for $ac_header... " >&6; }
11815 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11816   $as_echo_n "(cached) " >&6
11817 else
11818   eval "$as_ac_Header=\$ac_header_preproc"
11819 fi
11820 ac_res=`eval 'as_val=${'$as_ac_Header'}
11821                  $as_echo "$as_val"'`
11822                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11823 $as_echo "$ac_res" >&6; }
11824
11825 fi
11826 as_val=`eval 'as_val=${'$as_ac_Header'}
11827                  $as_echo "$as_val"'`
11828    if test "x$as_val" = x""yes; then
11829   cat >>confdefs.h <<_ACEOF
11830 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11831 _ACEOF
11832
11833 fi
11834
11835 done
11836
11837 fi
11838
11839 done
11840
11841 fi
11842
11843 done
11844
11845 fi
11846
11847 if test "$with_zlib" = yes; then
11848   if test "${ac_cv_header_zlib_h+set}" = set; then
11849   { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
11850 $as_echo_n "checking for zlib.h... " >&6; }
11851 if test "${ac_cv_header_zlib_h+set}" = set; then
11852   $as_echo_n "(cached) " >&6
11853 fi
11854 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
11855 $as_echo "$ac_cv_header_zlib_h" >&6; }
11856 else
11857   # Is the header compilable?
11858 { $as_echo "$as_me:$LINENO: checking zlib.h usability" >&5
11859 $as_echo_n "checking zlib.h usability... " >&6; }
11860 cat >conftest.$ac_ext <<_ACEOF
11861 /* confdefs.h.  */
11862 _ACEOF
11863 cat confdefs.h >>conftest.$ac_ext
11864 cat >>conftest.$ac_ext <<_ACEOF
11865 /* end confdefs.h.  */
11866 $ac_includes_default
11867 #include <zlib.h>
11868 _ACEOF
11869 rm -f conftest.$ac_objext
11870 if { (ac_try="$ac_compile"
11871 case "(($ac_try" in
11872   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11873   *) ac_try_echo=$ac_try;;
11874 esac
11875 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11876 $as_echo "$ac_try_echo") >&5
11877   (eval "$ac_compile") 2>conftest.er1
11878   ac_status=$?
11879   grep -v '^ *+' conftest.er1 >conftest.err
11880   rm -f conftest.er1
11881   cat conftest.err >&5
11882   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11883   (exit $ac_status); } && {
11884          test -z "$ac_c_werror_flag" ||
11885          test ! -s conftest.err
11886        } && test -s conftest.$ac_objext; then
11887   ac_header_compiler=yes
11888 else
11889   $as_echo "$as_me: failed program was:" >&5
11890 sed 's/^/| /' conftest.$ac_ext >&5
11891
11892         ac_header_compiler=no
11893 fi
11894
11895 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11896 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11897 $as_echo "$ac_header_compiler" >&6; }
11898
11899 # Is the header present?
11900 { $as_echo "$as_me:$LINENO: checking zlib.h presence" >&5
11901 $as_echo_n "checking zlib.h presence... " >&6; }
11902 cat >conftest.$ac_ext <<_ACEOF
11903 /* confdefs.h.  */
11904 _ACEOF
11905 cat confdefs.h >>conftest.$ac_ext
11906 cat >>conftest.$ac_ext <<_ACEOF
11907 /* end confdefs.h.  */
11908 #include <zlib.h>
11909 _ACEOF
11910 if { (ac_try="$ac_cpp conftest.$ac_ext"
11911 case "(($ac_try" in
11912   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11913   *) ac_try_echo=$ac_try;;
11914 esac
11915 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11916 $as_echo "$ac_try_echo") >&5
11917   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11918   ac_status=$?
11919   grep -v '^ *+' conftest.er1 >conftest.err
11920   rm -f conftest.er1
11921   cat conftest.err >&5
11922   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11923   (exit $ac_status); } >/dev/null && {
11924          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11925          test ! -s conftest.err
11926        }; then
11927   ac_header_preproc=yes
11928 else
11929   $as_echo "$as_me: failed program was:" >&5
11930 sed 's/^/| /' conftest.$ac_ext >&5
11931
11932   ac_header_preproc=no
11933 fi
11934
11935 rm -f conftest.err conftest.$ac_ext
11936 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11937 $as_echo "$ac_header_preproc" >&6; }
11938
11939 # So?  What about this header?
11940 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11941   yes:no: )
11942     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
11943 $as_echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11944     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
11945 $as_echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
11946     ac_header_preproc=yes
11947     ;;
11948   no:yes:* )
11949     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
11950 $as_echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
11951     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
11952 $as_echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
11953     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
11954 $as_echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
11955     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
11956 $as_echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
11957     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
11958 $as_echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
11959     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
11960 $as_echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
11961     ( cat <<\_ASBOX
11962 ## ---------------------------------------- ##
11963 ## Report this to pgsql-bugs@postgresql.org ##
11964 ## ---------------------------------------- ##
11965 _ASBOX
11966      ) | sed "s/^/$as_me: WARNING:     /" >&2
11967     ;;
11968 esac
11969 { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
11970 $as_echo_n "checking for zlib.h... " >&6; }
11971 if test "${ac_cv_header_zlib_h+set}" = set; then
11972   $as_echo_n "(cached) " >&6
11973 else
11974   ac_cv_header_zlib_h=$ac_header_preproc
11975 fi
11976 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
11977 $as_echo "$ac_cv_header_zlib_h" >&6; }
11978
11979 fi
11980 if test "x$ac_cv_header_zlib_h" = x""yes; then
11981   :
11982 else
11983   { { $as_echo "$as_me:$LINENO: error: zlib header not found
11984 If you have zlib already installed, see config.log for details on the
11985 failure.  It is possible the compiler isn't looking in the proper directory.
11986 Use --without-zlib to disable zlib support." >&5
11987 $as_echo "$as_me: error: zlib header not found
11988 If you have zlib already installed, see config.log for details on the
11989 failure.  It is possible the compiler isn't looking in the proper directory.
11990 Use --without-zlib to disable zlib support." >&2;}
11991    { (exit 1); exit 1; }; }
11992 fi
11993
11994
11995 fi
11996
11997 if test "$with_gssapi" = yes ; then
11998
11999 for ac_header in gssapi/gssapi.h
12000 do
12001 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12002 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12003   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12004 $as_echo_n "checking for $ac_header... " >&6; }
12005 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12006   $as_echo_n "(cached) " >&6
12007 fi
12008 ac_res=`eval 'as_val=${'$as_ac_Header'}
12009                  $as_echo "$as_val"'`
12010                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12011 $as_echo "$ac_res" >&6; }
12012 else
12013   # Is the header compilable?
12014 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12015 $as_echo_n "checking $ac_header usability... " >&6; }
12016 cat >conftest.$ac_ext <<_ACEOF
12017 /* confdefs.h.  */
12018 _ACEOF
12019 cat confdefs.h >>conftest.$ac_ext
12020 cat >>conftest.$ac_ext <<_ACEOF
12021 /* end confdefs.h.  */
12022 $ac_includes_default
12023 #include <$ac_header>
12024 _ACEOF
12025 rm -f conftest.$ac_objext
12026 if { (ac_try="$ac_compile"
12027 case "(($ac_try" in
12028   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12029   *) ac_try_echo=$ac_try;;
12030 esac
12031 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12032 $as_echo "$ac_try_echo") >&5
12033   (eval "$ac_compile") 2>conftest.er1
12034   ac_status=$?
12035   grep -v '^ *+' conftest.er1 >conftest.err
12036   rm -f conftest.er1
12037   cat conftest.err >&5
12038   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12039   (exit $ac_status); } && {
12040          test -z "$ac_c_werror_flag" ||
12041          test ! -s conftest.err
12042        } && test -s conftest.$ac_objext; then
12043   ac_header_compiler=yes
12044 else
12045   $as_echo "$as_me: failed program was:" >&5
12046 sed 's/^/| /' conftest.$ac_ext >&5
12047
12048         ac_header_compiler=no
12049 fi
12050
12051 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12052 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12053 $as_echo "$ac_header_compiler" >&6; }
12054
12055 # Is the header present?
12056 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12057 $as_echo_n "checking $ac_header presence... " >&6; }
12058 cat >conftest.$ac_ext <<_ACEOF
12059 /* confdefs.h.  */
12060 _ACEOF
12061 cat confdefs.h >>conftest.$ac_ext
12062 cat >>conftest.$ac_ext <<_ACEOF
12063 /* end confdefs.h.  */
12064 #include <$ac_header>
12065 _ACEOF
12066 if { (ac_try="$ac_cpp conftest.$ac_ext"
12067 case "(($ac_try" in
12068   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12069   *) ac_try_echo=$ac_try;;
12070 esac
12071 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12072 $as_echo "$ac_try_echo") >&5
12073   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12074   ac_status=$?
12075   grep -v '^ *+' conftest.er1 >conftest.err
12076   rm -f conftest.er1
12077   cat conftest.err >&5
12078   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12079   (exit $ac_status); } >/dev/null && {
12080          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12081          test ! -s conftest.err
12082        }; then
12083   ac_header_preproc=yes
12084 else
12085   $as_echo "$as_me: failed program was:" >&5
12086 sed 's/^/| /' conftest.$ac_ext >&5
12087
12088   ac_header_preproc=no
12089 fi
12090
12091 rm -f conftest.err conftest.$ac_ext
12092 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12093 $as_echo "$ac_header_preproc" >&6; }
12094
12095 # So?  What about this header?
12096 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12097   yes:no: )
12098     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12099 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12100     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12101 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12102     ac_header_preproc=yes
12103     ;;
12104   no:yes:* )
12105     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12106 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12107     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12108 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12109     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12110 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12111     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12112 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12113     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12114 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12115     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12116 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12117     ( cat <<\_ASBOX
12118 ## ---------------------------------------- ##
12119 ## Report this to pgsql-bugs@postgresql.org ##
12120 ## ---------------------------------------- ##
12121 _ASBOX
12122      ) | sed "s/^/$as_me: WARNING:     /" >&2
12123     ;;
12124 esac
12125 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12126 $as_echo_n "checking for $ac_header... " >&6; }
12127 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12128   $as_echo_n "(cached) " >&6
12129 else
12130   eval "$as_ac_Header=\$ac_header_preproc"
12131 fi
12132 ac_res=`eval 'as_val=${'$as_ac_Header'}
12133                  $as_echo "$as_val"'`
12134                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12135 $as_echo "$ac_res" >&6; }
12136
12137 fi
12138 as_val=`eval 'as_val=${'$as_ac_Header'}
12139                  $as_echo "$as_val"'`
12140    if test "x$as_val" = x""yes; then
12141   cat >>confdefs.h <<_ACEOF
12142 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12143 _ACEOF
12144
12145 else
12146
12147 for ac_header in gssapi.h
12148 do
12149 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12150 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12151   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12152 $as_echo_n "checking for $ac_header... " >&6; }
12153 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12154   $as_echo_n "(cached) " >&6
12155 fi
12156 ac_res=`eval 'as_val=${'$as_ac_Header'}
12157                  $as_echo "$as_val"'`
12158                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12159 $as_echo "$ac_res" >&6; }
12160 else
12161   # Is the header compilable?
12162 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12163 $as_echo_n "checking $ac_header usability... " >&6; }
12164 cat >conftest.$ac_ext <<_ACEOF
12165 /* confdefs.h.  */
12166 _ACEOF
12167 cat confdefs.h >>conftest.$ac_ext
12168 cat >>conftest.$ac_ext <<_ACEOF
12169 /* end confdefs.h.  */
12170 $ac_includes_default
12171 #include <$ac_header>
12172 _ACEOF
12173 rm -f conftest.$ac_objext
12174 if { (ac_try="$ac_compile"
12175 case "(($ac_try" in
12176   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12177   *) ac_try_echo=$ac_try;;
12178 esac
12179 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12180 $as_echo "$ac_try_echo") >&5
12181   (eval "$ac_compile") 2>conftest.er1
12182   ac_status=$?
12183   grep -v '^ *+' conftest.er1 >conftest.err
12184   rm -f conftest.er1
12185   cat conftest.err >&5
12186   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12187   (exit $ac_status); } && {
12188          test -z "$ac_c_werror_flag" ||
12189          test ! -s conftest.err
12190        } && test -s conftest.$ac_objext; then
12191   ac_header_compiler=yes
12192 else
12193   $as_echo "$as_me: failed program was:" >&5
12194 sed 's/^/| /' conftest.$ac_ext >&5
12195
12196         ac_header_compiler=no
12197 fi
12198
12199 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12200 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12201 $as_echo "$ac_header_compiler" >&6; }
12202
12203 # Is the header present?
12204 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12205 $as_echo_n "checking $ac_header presence... " >&6; }
12206 cat >conftest.$ac_ext <<_ACEOF
12207 /* confdefs.h.  */
12208 _ACEOF
12209 cat confdefs.h >>conftest.$ac_ext
12210 cat >>conftest.$ac_ext <<_ACEOF
12211 /* end confdefs.h.  */
12212 #include <$ac_header>
12213 _ACEOF
12214 if { (ac_try="$ac_cpp conftest.$ac_ext"
12215 case "(($ac_try" in
12216   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12217   *) ac_try_echo=$ac_try;;
12218 esac
12219 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12220 $as_echo "$ac_try_echo") >&5
12221   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12222   ac_status=$?
12223   grep -v '^ *+' conftest.er1 >conftest.err
12224   rm -f conftest.er1
12225   cat conftest.err >&5
12226   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12227   (exit $ac_status); } >/dev/null && {
12228          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12229          test ! -s conftest.err
12230        }; then
12231   ac_header_preproc=yes
12232 else
12233   $as_echo "$as_me: failed program was:" >&5
12234 sed 's/^/| /' conftest.$ac_ext >&5
12235
12236   ac_header_preproc=no
12237 fi
12238
12239 rm -f conftest.err conftest.$ac_ext
12240 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12241 $as_echo "$ac_header_preproc" >&6; }
12242
12243 # So?  What about this header?
12244 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12245   yes:no: )
12246     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12247 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12248     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12249 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12250     ac_header_preproc=yes
12251     ;;
12252   no:yes:* )
12253     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12254 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12255     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12256 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12257     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12258 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12259     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12260 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12261     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12262 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12263     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12264 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12265     ( cat <<\_ASBOX
12266 ## ---------------------------------------- ##
12267 ## Report this to pgsql-bugs@postgresql.org ##
12268 ## ---------------------------------------- ##
12269 _ASBOX
12270      ) | sed "s/^/$as_me: WARNING:     /" >&2
12271     ;;
12272 esac
12273 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12274 $as_echo_n "checking for $ac_header... " >&6; }
12275 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12276   $as_echo_n "(cached) " >&6
12277 else
12278   eval "$as_ac_Header=\$ac_header_preproc"
12279 fi
12280 ac_res=`eval 'as_val=${'$as_ac_Header'}
12281                  $as_echo "$as_val"'`
12282                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12283 $as_echo "$ac_res" >&6; }
12284
12285 fi
12286 as_val=`eval 'as_val=${'$as_ac_Header'}
12287                  $as_echo "$as_val"'`
12288    if test "x$as_val" = x""yes; then
12289   cat >>confdefs.h <<_ACEOF
12290 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12291 _ACEOF
12292
12293 else
12294   { { $as_echo "$as_me:$LINENO: error: gssapi.h header file is required for GSSAPI" >&5
12295 $as_echo "$as_me: error: gssapi.h header file is required for GSSAPI" >&2;}
12296    { (exit 1); exit 1; }; }
12297 fi
12298
12299 done
12300
12301 fi
12302
12303 done
12304
12305 fi
12306
12307 if test "$with_krb5" = yes ; then
12308   if test "${ac_cv_header_krb5_h+set}" = set; then
12309   { $as_echo "$as_me:$LINENO: checking for krb5.h" >&5
12310 $as_echo_n "checking for krb5.h... " >&6; }
12311 if test "${ac_cv_header_krb5_h+set}" = set; then
12312   $as_echo_n "(cached) " >&6
12313 fi
12314 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
12315 $as_echo "$ac_cv_header_krb5_h" >&6; }
12316 else
12317   # Is the header compilable?
12318 { $as_echo "$as_me:$LINENO: checking krb5.h usability" >&5
12319 $as_echo_n "checking krb5.h usability... " >&6; }
12320 cat >conftest.$ac_ext <<_ACEOF
12321 /* confdefs.h.  */
12322 _ACEOF
12323 cat confdefs.h >>conftest.$ac_ext
12324 cat >>conftest.$ac_ext <<_ACEOF
12325 /* end confdefs.h.  */
12326 $ac_includes_default
12327 #include <krb5.h>
12328 _ACEOF
12329 rm -f conftest.$ac_objext
12330 if { (ac_try="$ac_compile"
12331 case "(($ac_try" in
12332   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12333   *) ac_try_echo=$ac_try;;
12334 esac
12335 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12336 $as_echo "$ac_try_echo") >&5
12337   (eval "$ac_compile") 2>conftest.er1
12338   ac_status=$?
12339   grep -v '^ *+' conftest.er1 >conftest.err
12340   rm -f conftest.er1
12341   cat conftest.err >&5
12342   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12343   (exit $ac_status); } && {
12344          test -z "$ac_c_werror_flag" ||
12345          test ! -s conftest.err
12346        } && test -s conftest.$ac_objext; then
12347   ac_header_compiler=yes
12348 else
12349   $as_echo "$as_me: failed program was:" >&5
12350 sed 's/^/| /' conftest.$ac_ext >&5
12351
12352         ac_header_compiler=no
12353 fi
12354
12355 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12356 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12357 $as_echo "$ac_header_compiler" >&6; }
12358
12359 # Is the header present?
12360 { $as_echo "$as_me:$LINENO: checking krb5.h presence" >&5
12361 $as_echo_n "checking krb5.h presence... " >&6; }
12362 cat >conftest.$ac_ext <<_ACEOF
12363 /* confdefs.h.  */
12364 _ACEOF
12365 cat confdefs.h >>conftest.$ac_ext
12366 cat >>conftest.$ac_ext <<_ACEOF
12367 /* end confdefs.h.  */
12368 #include <krb5.h>
12369 _ACEOF
12370 if { (ac_try="$ac_cpp conftest.$ac_ext"
12371 case "(($ac_try" in
12372   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12373   *) ac_try_echo=$ac_try;;
12374 esac
12375 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12376 $as_echo "$ac_try_echo") >&5
12377   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12378   ac_status=$?
12379   grep -v '^ *+' conftest.er1 >conftest.err
12380   rm -f conftest.er1
12381   cat conftest.err >&5
12382   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12383   (exit $ac_status); } >/dev/null && {
12384          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12385          test ! -s conftest.err
12386        }; then
12387   ac_header_preproc=yes
12388 else
12389   $as_echo "$as_me: failed program was:" >&5
12390 sed 's/^/| /' conftest.$ac_ext >&5
12391
12392   ac_header_preproc=no
12393 fi
12394
12395 rm -f conftest.err conftest.$ac_ext
12396 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12397 $as_echo "$ac_header_preproc" >&6; }
12398
12399 # So?  What about this header?
12400 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12401   yes:no: )
12402     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
12403 $as_echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12404     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the compiler's result" >&5
12405 $as_echo "$as_me: WARNING: krb5.h: proceeding with the compiler's result" >&2;}
12406     ac_header_preproc=yes
12407     ;;
12408   no:yes:* )
12409     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
12410 $as_echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
12411     { $as_echo "$as_me:$LINENO: WARNING: krb5.h:     check for missing prerequisite headers?" >&5
12412 $as_echo "$as_me: WARNING: krb5.h:     check for missing prerequisite headers?" >&2;}
12413     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: see the Autoconf documentation" >&5
12414 $as_echo "$as_me: WARNING: krb5.h: see the Autoconf documentation" >&2;}
12415     { $as_echo "$as_me:$LINENO: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&5
12416 $as_echo "$as_me: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12417     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
12418 $as_echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;}
12419     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: in the future, the compiler will take precedence" >&5
12420 $as_echo "$as_me: WARNING: krb5.h: in the future, the compiler will take precedence" >&2;}
12421     ( cat <<\_ASBOX
12422 ## ---------------------------------------- ##
12423 ## Report this to pgsql-bugs@postgresql.org ##
12424 ## ---------------------------------------- ##
12425 _ASBOX
12426      ) | sed "s/^/$as_me: WARNING:     /" >&2
12427     ;;
12428 esac
12429 { $as_echo "$as_me:$LINENO: checking for krb5.h" >&5
12430 $as_echo_n "checking for krb5.h... " >&6; }
12431 if test "${ac_cv_header_krb5_h+set}" = set; then
12432   $as_echo_n "(cached) " >&6
12433 else
12434   ac_cv_header_krb5_h=$ac_header_preproc
12435 fi
12436 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
12437 $as_echo "$ac_cv_header_krb5_h" >&6; }
12438
12439 fi
12440 if test "x$ac_cv_header_krb5_h" = x""yes; then
12441   :
12442 else
12443   { { $as_echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
12444 $as_echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
12445    { (exit 1); exit 1; }; }
12446 fi
12447
12448
12449 fi
12450
12451 if test "$with_openssl" = yes ; then
12452   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12453   { $as_echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
12454 $as_echo_n "checking for openssl/ssl.h... " >&6; }
12455 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12456   $as_echo_n "(cached) " >&6
12457 fi
12458 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
12459 $as_echo "$ac_cv_header_openssl_ssl_h" >&6; }
12460 else
12461   # Is the header compilable?
12462 { $as_echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
12463 $as_echo_n "checking openssl/ssl.h usability... " >&6; }
12464 cat >conftest.$ac_ext <<_ACEOF
12465 /* confdefs.h.  */
12466 _ACEOF
12467 cat confdefs.h >>conftest.$ac_ext
12468 cat >>conftest.$ac_ext <<_ACEOF
12469 /* end confdefs.h.  */
12470 $ac_includes_default
12471 #include <openssl/ssl.h>
12472 _ACEOF
12473 rm -f conftest.$ac_objext
12474 if { (ac_try="$ac_compile"
12475 case "(($ac_try" in
12476   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12477   *) ac_try_echo=$ac_try;;
12478 esac
12479 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12480 $as_echo "$ac_try_echo") >&5
12481   (eval "$ac_compile") 2>conftest.er1
12482   ac_status=$?
12483   grep -v '^ *+' conftest.er1 >conftest.err
12484   rm -f conftest.er1
12485   cat conftest.err >&5
12486   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12487   (exit $ac_status); } && {
12488          test -z "$ac_c_werror_flag" ||
12489          test ! -s conftest.err
12490        } && test -s conftest.$ac_objext; then
12491   ac_header_compiler=yes
12492 else
12493   $as_echo "$as_me: failed program was:" >&5
12494 sed 's/^/| /' conftest.$ac_ext >&5
12495
12496         ac_header_compiler=no
12497 fi
12498
12499 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12500 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12501 $as_echo "$ac_header_compiler" >&6; }
12502
12503 # Is the header present?
12504 { $as_echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
12505 $as_echo_n "checking openssl/ssl.h presence... " >&6; }
12506 cat >conftest.$ac_ext <<_ACEOF
12507 /* confdefs.h.  */
12508 _ACEOF
12509 cat confdefs.h >>conftest.$ac_ext
12510 cat >>conftest.$ac_ext <<_ACEOF
12511 /* end confdefs.h.  */
12512 #include <openssl/ssl.h>
12513 _ACEOF
12514 if { (ac_try="$ac_cpp conftest.$ac_ext"
12515 case "(($ac_try" in
12516   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12517   *) ac_try_echo=$ac_try;;
12518 esac
12519 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12520 $as_echo "$ac_try_echo") >&5
12521   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12522   ac_status=$?
12523   grep -v '^ *+' conftest.er1 >conftest.err
12524   rm -f conftest.er1
12525   cat conftest.err >&5
12526   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12527   (exit $ac_status); } >/dev/null && {
12528          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12529          test ! -s conftest.err
12530        }; then
12531   ac_header_preproc=yes
12532 else
12533   $as_echo "$as_me: failed program was:" >&5
12534 sed 's/^/| /' conftest.$ac_ext >&5
12535
12536   ac_header_preproc=no
12537 fi
12538
12539 rm -f conftest.err conftest.$ac_ext
12540 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12541 $as_echo "$ac_header_preproc" >&6; }
12542
12543 # So?  What about this header?
12544 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12545   yes:no: )
12546     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
12547 $as_echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12548     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&5
12549 $as_echo "$as_me: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&2;}
12550     ac_header_preproc=yes
12551     ;;
12552   no:yes:* )
12553     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
12554 $as_echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
12555     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&5
12556 $as_echo "$as_me: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&2;}
12557     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: see the Autoconf documentation" >&5
12558 $as_echo "$as_me: WARNING: openssl/ssl.h: see the Autoconf documentation" >&2;}
12559     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&5
12560 $as_echo "$as_me: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12561     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
12562 $as_echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;}
12563     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&5
12564 $as_echo "$as_me: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&2;}
12565     ( cat <<\_ASBOX
12566 ## ---------------------------------------- ##
12567 ## Report this to pgsql-bugs@postgresql.org ##
12568 ## ---------------------------------------- ##
12569 _ASBOX
12570      ) | sed "s/^/$as_me: WARNING:     /" >&2
12571     ;;
12572 esac
12573 { $as_echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
12574 $as_echo_n "checking for openssl/ssl.h... " >&6; }
12575 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12576   $as_echo_n "(cached) " >&6
12577 else
12578   ac_cv_header_openssl_ssl_h=$ac_header_preproc
12579 fi
12580 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
12581 $as_echo "$ac_cv_header_openssl_ssl_h" >&6; }
12582
12583 fi
12584 if test "x$ac_cv_header_openssl_ssl_h" = x""yes; then
12585   :
12586 else
12587   { { $as_echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
12588 $as_echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
12589    { (exit 1); exit 1; }; }
12590 fi
12591
12592
12593   if test "${ac_cv_header_openssl_err_h+set}" = set; then
12594   { $as_echo "$as_me:$LINENO: checking for openssl/err.h" >&5
12595 $as_echo_n "checking for openssl/err.h... " >&6; }
12596 if test "${ac_cv_header_openssl_err_h+set}" = set; then
12597   $as_echo_n "(cached) " >&6
12598 fi
12599 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
12600 $as_echo "$ac_cv_header_openssl_err_h" >&6; }
12601 else
12602   # Is the header compilable?
12603 { $as_echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
12604 $as_echo_n "checking openssl/err.h usability... " >&6; }
12605 cat >conftest.$ac_ext <<_ACEOF
12606 /* confdefs.h.  */
12607 _ACEOF
12608 cat confdefs.h >>conftest.$ac_ext
12609 cat >>conftest.$ac_ext <<_ACEOF
12610 /* end confdefs.h.  */
12611 $ac_includes_default
12612 #include <openssl/err.h>
12613 _ACEOF
12614 rm -f conftest.$ac_objext
12615 if { (ac_try="$ac_compile"
12616 case "(($ac_try" in
12617   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12618   *) ac_try_echo=$ac_try;;
12619 esac
12620 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12621 $as_echo "$ac_try_echo") >&5
12622   (eval "$ac_compile") 2>conftest.er1
12623   ac_status=$?
12624   grep -v '^ *+' conftest.er1 >conftest.err
12625   rm -f conftest.er1
12626   cat conftest.err >&5
12627   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12628   (exit $ac_status); } && {
12629          test -z "$ac_c_werror_flag" ||
12630          test ! -s conftest.err
12631        } && test -s conftest.$ac_objext; then
12632   ac_header_compiler=yes
12633 else
12634   $as_echo "$as_me: failed program was:" >&5
12635 sed 's/^/| /' conftest.$ac_ext >&5
12636
12637         ac_header_compiler=no
12638 fi
12639
12640 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12641 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12642 $as_echo "$ac_header_compiler" >&6; }
12643
12644 # Is the header present?
12645 { $as_echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
12646 $as_echo_n "checking openssl/err.h presence... " >&6; }
12647 cat >conftest.$ac_ext <<_ACEOF
12648 /* confdefs.h.  */
12649 _ACEOF
12650 cat confdefs.h >>conftest.$ac_ext
12651 cat >>conftest.$ac_ext <<_ACEOF
12652 /* end confdefs.h.  */
12653 #include <openssl/err.h>
12654 _ACEOF
12655 if { (ac_try="$ac_cpp conftest.$ac_ext"
12656 case "(($ac_try" in
12657   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12658   *) ac_try_echo=$ac_try;;
12659 esac
12660 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12661 $as_echo "$ac_try_echo") >&5
12662   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12663   ac_status=$?
12664   grep -v '^ *+' conftest.er1 >conftest.err
12665   rm -f conftest.er1
12666   cat conftest.err >&5
12667   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12668   (exit $ac_status); } >/dev/null && {
12669          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12670          test ! -s conftest.err
12671        }; then
12672   ac_header_preproc=yes
12673 else
12674   $as_echo "$as_me: failed program was:" >&5
12675 sed 's/^/| /' conftest.$ac_ext >&5
12676
12677   ac_header_preproc=no
12678 fi
12679
12680 rm -f conftest.err conftest.$ac_ext
12681 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12682 $as_echo "$ac_header_preproc" >&6; }
12683
12684 # So?  What about this header?
12685 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12686   yes:no: )
12687     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
12688 $as_echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12689     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the compiler's result" >&5
12690 $as_echo "$as_me: WARNING: openssl/err.h: proceeding with the compiler's result" >&2;}
12691     ac_header_preproc=yes
12692     ;;
12693   no:yes:* )
12694     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
12695 $as_echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
12696     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&5
12697 $as_echo "$as_me: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&2;}
12698     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: see the Autoconf documentation" >&5
12699 $as_echo "$as_me: WARNING: openssl/err.h: see the Autoconf documentation" >&2;}
12700     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&5
12701 $as_echo "$as_me: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12702     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
12703 $as_echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;}
12704     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&5
12705 $as_echo "$as_me: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&2;}
12706     ( cat <<\_ASBOX
12707 ## ---------------------------------------- ##
12708 ## Report this to pgsql-bugs@postgresql.org ##
12709 ## ---------------------------------------- ##
12710 _ASBOX
12711      ) | sed "s/^/$as_me: WARNING:     /" >&2
12712     ;;
12713 esac
12714 { $as_echo "$as_me:$LINENO: checking for openssl/err.h" >&5
12715 $as_echo_n "checking for openssl/err.h... " >&6; }
12716 if test "${ac_cv_header_openssl_err_h+set}" = set; then
12717   $as_echo_n "(cached) " >&6
12718 else
12719   ac_cv_header_openssl_err_h=$ac_header_preproc
12720 fi
12721 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
12722 $as_echo "$ac_cv_header_openssl_err_h" >&6; }
12723
12724 fi
12725 if test "x$ac_cv_header_openssl_err_h" = x""yes; then
12726   :
12727 else
12728   { { $as_echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
12729 $as_echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
12730    { (exit 1); exit 1; }; }
12731 fi
12732
12733
12734
12735 for ac_func in ERR_set_mark
12736 do
12737 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12738 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
12739 $as_echo_n "checking for $ac_func... " >&6; }
12740 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
12741   $as_echo_n "(cached) " >&6
12742 else
12743   cat >conftest.$ac_ext <<_ACEOF
12744 /* confdefs.h.  */
12745 _ACEOF
12746 cat confdefs.h >>conftest.$ac_ext
12747 cat >>conftest.$ac_ext <<_ACEOF
12748 /* end confdefs.h.  */
12749 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
12750    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
12751 #define $ac_func innocuous_$ac_func
12752
12753 /* System header to define __stub macros and hopefully few prototypes,
12754     which can conflict with char $ac_func (); below.
12755     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12756     <limits.h> exists even on freestanding compilers.  */
12757
12758 #ifdef __STDC__
12759 # include <limits.h>
12760 #else
12761 # include <assert.h>
12762 #endif
12763
12764 #undef $ac_func
12765
12766 /* Override any GCC internal prototype to avoid an error.
12767    Use char because int might match the return type of a GCC
12768    builtin and then its argument prototype would still apply.  */
12769 #ifdef __cplusplus
12770 extern "C"
12771 #endif
12772 char $ac_func ();
12773 /* The GNU C library defines this for functions which it implements
12774     to always fail with ENOSYS.  Some functions are actually named
12775     something starting with __ and the normal name is an alias.  */
12776 #if defined __stub_$ac_func || defined __stub___$ac_func
12777 choke me
12778 #endif
12779
12780 int
12781 main ()
12782 {
12783 return $ac_func ();
12784   ;
12785   return 0;
12786 }
12787 _ACEOF
12788 rm -f conftest.$ac_objext conftest$ac_exeext
12789 if { (ac_try="$ac_link"
12790 case "(($ac_try" in
12791   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12792   *) ac_try_echo=$ac_try;;
12793 esac
12794 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12795 $as_echo "$ac_try_echo") >&5
12796   (eval "$ac_link") 2>conftest.er1
12797   ac_status=$?
12798   grep -v '^ *+' conftest.er1 >conftest.err
12799   rm -f conftest.er1
12800   cat conftest.err >&5
12801   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12802   (exit $ac_status); } && {
12803          test -z "$ac_c_werror_flag" ||
12804          test ! -s conftest.err
12805        } && test -s conftest$ac_exeext && {
12806          test "$cross_compiling" = yes ||
12807          $as_test_x conftest$ac_exeext
12808        }; then
12809   eval "$as_ac_var=yes"
12810 else
12811   $as_echo "$as_me: failed program was:" >&5
12812 sed 's/^/| /' conftest.$ac_ext >&5
12813
12814         eval "$as_ac_var=no"
12815 fi
12816
12817 rm -rf conftest.dSYM
12818 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12819       conftest$ac_exeext conftest.$ac_ext
12820 fi
12821 ac_res=`eval 'as_val=${'$as_ac_var'}
12822                  $as_echo "$as_val"'`
12823                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12824 $as_echo "$ac_res" >&6; }
12825 as_val=`eval 'as_val=${'$as_ac_var'}
12826                  $as_echo "$as_val"'`
12827    if test "x$as_val" = x""yes; then
12828   cat >>confdefs.h <<_ACEOF
12829 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
12830 _ACEOF
12831
12832 fi
12833 done
12834
12835 fi
12836
12837 if test "$with_pam" = yes ; then
12838
12839 for ac_header in security/pam_appl.h
12840 do
12841 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12842 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12843   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12844 $as_echo_n "checking for $ac_header... " >&6; }
12845 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12846   $as_echo_n "(cached) " >&6
12847 fi
12848 ac_res=`eval 'as_val=${'$as_ac_Header'}
12849                  $as_echo "$as_val"'`
12850                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12851 $as_echo "$ac_res" >&6; }
12852 else
12853   # Is the header compilable?
12854 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12855 $as_echo_n "checking $ac_header usability... " >&6; }
12856 cat >conftest.$ac_ext <<_ACEOF
12857 /* confdefs.h.  */
12858 _ACEOF
12859 cat confdefs.h >>conftest.$ac_ext
12860 cat >>conftest.$ac_ext <<_ACEOF
12861 /* end confdefs.h.  */
12862 $ac_includes_default
12863 #include <$ac_header>
12864 _ACEOF
12865 rm -f conftest.$ac_objext
12866 if { (ac_try="$ac_compile"
12867 case "(($ac_try" in
12868   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12869   *) ac_try_echo=$ac_try;;
12870 esac
12871 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12872 $as_echo "$ac_try_echo") >&5
12873   (eval "$ac_compile") 2>conftest.er1
12874   ac_status=$?
12875   grep -v '^ *+' conftest.er1 >conftest.err
12876   rm -f conftest.er1
12877   cat conftest.err >&5
12878   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12879   (exit $ac_status); } && {
12880          test -z "$ac_c_werror_flag" ||
12881          test ! -s conftest.err
12882        } && test -s conftest.$ac_objext; then
12883   ac_header_compiler=yes
12884 else
12885   $as_echo "$as_me: failed program was:" >&5
12886 sed 's/^/| /' conftest.$ac_ext >&5
12887
12888         ac_header_compiler=no
12889 fi
12890
12891 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12892 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12893 $as_echo "$ac_header_compiler" >&6; }
12894
12895 # Is the header present?
12896 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12897 $as_echo_n "checking $ac_header presence... " >&6; }
12898 cat >conftest.$ac_ext <<_ACEOF
12899 /* confdefs.h.  */
12900 _ACEOF
12901 cat confdefs.h >>conftest.$ac_ext
12902 cat >>conftest.$ac_ext <<_ACEOF
12903 /* end confdefs.h.  */
12904 #include <$ac_header>
12905 _ACEOF
12906 if { (ac_try="$ac_cpp conftest.$ac_ext"
12907 case "(($ac_try" in
12908   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12909   *) ac_try_echo=$ac_try;;
12910 esac
12911 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12912 $as_echo "$ac_try_echo") >&5
12913   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12914   ac_status=$?
12915   grep -v '^ *+' conftest.er1 >conftest.err
12916   rm -f conftest.er1
12917   cat conftest.err >&5
12918   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12919   (exit $ac_status); } >/dev/null && {
12920          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12921          test ! -s conftest.err
12922        }; then
12923   ac_header_preproc=yes
12924 else
12925   $as_echo "$as_me: failed program was:" >&5
12926 sed 's/^/| /' conftest.$ac_ext >&5
12927
12928   ac_header_preproc=no
12929 fi
12930
12931 rm -f conftest.err conftest.$ac_ext
12932 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12933 $as_echo "$ac_header_preproc" >&6; }
12934
12935 # So?  What about this header?
12936 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12937   yes:no: )
12938     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12939 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12940     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12941 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12942     ac_header_preproc=yes
12943     ;;
12944   no:yes:* )
12945     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12946 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12947     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12948 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12949     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12950 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12951     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12952 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12953     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12954 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12955     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12956 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12957     ( cat <<\_ASBOX
12958 ## ---------------------------------------- ##
12959 ## Report this to pgsql-bugs@postgresql.org ##
12960 ## ---------------------------------------- ##
12961 _ASBOX
12962      ) | sed "s/^/$as_me: WARNING:     /" >&2
12963     ;;
12964 esac
12965 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12966 $as_echo_n "checking for $ac_header... " >&6; }
12967 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12968   $as_echo_n "(cached) " >&6
12969 else
12970   eval "$as_ac_Header=\$ac_header_preproc"
12971 fi
12972 ac_res=`eval 'as_val=${'$as_ac_Header'}
12973                  $as_echo "$as_val"'`
12974                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12975 $as_echo "$ac_res" >&6; }
12976
12977 fi
12978 as_val=`eval 'as_val=${'$as_ac_Header'}
12979                  $as_echo "$as_val"'`
12980    if test "x$as_val" = x""yes; then
12981   cat >>confdefs.h <<_ACEOF
12982 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12983 _ACEOF
12984
12985 else
12986
12987 for ac_header in pam/pam_appl.h
12988 do
12989 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12990 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12991   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12992 $as_echo_n "checking for $ac_header... " >&6; }
12993 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12994   $as_echo_n "(cached) " >&6
12995 fi
12996 ac_res=`eval 'as_val=${'$as_ac_Header'}
12997                  $as_echo "$as_val"'`
12998                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12999 $as_echo "$ac_res" >&6; }
13000 else
13001   # Is the header compilable?
13002 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13003 $as_echo_n "checking $ac_header usability... " >&6; }
13004 cat >conftest.$ac_ext <<_ACEOF
13005 /* confdefs.h.  */
13006 _ACEOF
13007 cat confdefs.h >>conftest.$ac_ext
13008 cat >>conftest.$ac_ext <<_ACEOF
13009 /* end confdefs.h.  */
13010 $ac_includes_default
13011 #include <$ac_header>
13012 _ACEOF
13013 rm -f conftest.$ac_objext
13014 if { (ac_try="$ac_compile"
13015 case "(($ac_try" in
13016   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13017   *) ac_try_echo=$ac_try;;
13018 esac
13019 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13020 $as_echo "$ac_try_echo") >&5
13021   (eval "$ac_compile") 2>conftest.er1
13022   ac_status=$?
13023   grep -v '^ *+' conftest.er1 >conftest.err
13024   rm -f conftest.er1
13025   cat conftest.err >&5
13026   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13027   (exit $ac_status); } && {
13028          test -z "$ac_c_werror_flag" ||
13029          test ! -s conftest.err
13030        } && test -s conftest.$ac_objext; then
13031   ac_header_compiler=yes
13032 else
13033   $as_echo "$as_me: failed program was:" >&5
13034 sed 's/^/| /' conftest.$ac_ext >&5
13035
13036         ac_header_compiler=no
13037 fi
13038
13039 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13040 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13041 $as_echo "$ac_header_compiler" >&6; }
13042
13043 # Is the header present?
13044 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13045 $as_echo_n "checking $ac_header presence... " >&6; }
13046 cat >conftest.$ac_ext <<_ACEOF
13047 /* confdefs.h.  */
13048 _ACEOF
13049 cat confdefs.h >>conftest.$ac_ext
13050 cat >>conftest.$ac_ext <<_ACEOF
13051 /* end confdefs.h.  */
13052 #include <$ac_header>
13053 _ACEOF
13054 if { (ac_try="$ac_cpp conftest.$ac_ext"
13055 case "(($ac_try" in
13056   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13057   *) ac_try_echo=$ac_try;;
13058 esac
13059 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13060 $as_echo "$ac_try_echo") >&5
13061   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13062   ac_status=$?
13063   grep -v '^ *+' conftest.er1 >conftest.err
13064   rm -f conftest.er1
13065   cat conftest.err >&5
13066   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13067   (exit $ac_status); } >/dev/null && {
13068          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13069          test ! -s conftest.err
13070        }; then
13071   ac_header_preproc=yes
13072 else
13073   $as_echo "$as_me: failed program was:" >&5
13074 sed 's/^/| /' conftest.$ac_ext >&5
13075
13076   ac_header_preproc=no
13077 fi
13078
13079 rm -f conftest.err conftest.$ac_ext
13080 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13081 $as_echo "$ac_header_preproc" >&6; }
13082
13083 # So?  What about this header?
13084 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13085   yes:no: )
13086     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13087 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13088     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13089 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13090     ac_header_preproc=yes
13091     ;;
13092   no:yes:* )
13093     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13094 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13095     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13096 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13097     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13098 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13099     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13100 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13101     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13102 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13103     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13104 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13105     ( cat <<\_ASBOX
13106 ## ---------------------------------------- ##
13107 ## Report this to pgsql-bugs@postgresql.org ##
13108 ## ---------------------------------------- ##
13109 _ASBOX
13110      ) | sed "s/^/$as_me: WARNING:     /" >&2
13111     ;;
13112 esac
13113 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13114 $as_echo_n "checking for $ac_header... " >&6; }
13115 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13116   $as_echo_n "(cached) " >&6
13117 else
13118   eval "$as_ac_Header=\$ac_header_preproc"
13119 fi
13120 ac_res=`eval 'as_val=${'$as_ac_Header'}
13121                  $as_echo "$as_val"'`
13122                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13123 $as_echo "$ac_res" >&6; }
13124
13125 fi
13126 as_val=`eval 'as_val=${'$as_ac_Header'}
13127                  $as_echo "$as_val"'`
13128    if test "x$as_val" = x""yes; then
13129   cat >>confdefs.h <<_ACEOF
13130 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13131 _ACEOF
13132
13133 else
13134   { { $as_echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
13135 $as_echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
13136    { (exit 1); exit 1; }; }
13137 fi
13138
13139 done
13140
13141 fi
13142
13143 done
13144
13145 fi
13146
13147 if test "$with_libxml" = yes ; then
13148   if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13149   { $as_echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
13150 $as_echo_n "checking for libxml/parser.h... " >&6; }
13151 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13152   $as_echo_n "(cached) " >&6
13153 fi
13154 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
13155 $as_echo "$ac_cv_header_libxml_parser_h" >&6; }
13156 else
13157   # Is the header compilable?
13158 { $as_echo "$as_me:$LINENO: checking libxml/parser.h usability" >&5
13159 $as_echo_n "checking libxml/parser.h usability... " >&6; }
13160 cat >conftest.$ac_ext <<_ACEOF
13161 /* confdefs.h.  */
13162 _ACEOF
13163 cat confdefs.h >>conftest.$ac_ext
13164 cat >>conftest.$ac_ext <<_ACEOF
13165 /* end confdefs.h.  */
13166 $ac_includes_default
13167 #include <libxml/parser.h>
13168 _ACEOF
13169 rm -f conftest.$ac_objext
13170 if { (ac_try="$ac_compile"
13171 case "(($ac_try" in
13172   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13173   *) ac_try_echo=$ac_try;;
13174 esac
13175 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13176 $as_echo "$ac_try_echo") >&5
13177   (eval "$ac_compile") 2>conftest.er1
13178   ac_status=$?
13179   grep -v '^ *+' conftest.er1 >conftest.err
13180   rm -f conftest.er1
13181   cat conftest.err >&5
13182   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13183   (exit $ac_status); } && {
13184          test -z "$ac_c_werror_flag" ||
13185          test ! -s conftest.err
13186        } && test -s conftest.$ac_objext; then
13187   ac_header_compiler=yes
13188 else
13189   $as_echo "$as_me: failed program was:" >&5
13190 sed 's/^/| /' conftest.$ac_ext >&5
13191
13192         ac_header_compiler=no
13193 fi
13194
13195 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13196 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13197 $as_echo "$ac_header_compiler" >&6; }
13198
13199 # Is the header present?
13200 { $as_echo "$as_me:$LINENO: checking libxml/parser.h presence" >&5
13201 $as_echo_n "checking libxml/parser.h presence... " >&6; }
13202 cat >conftest.$ac_ext <<_ACEOF
13203 /* confdefs.h.  */
13204 _ACEOF
13205 cat confdefs.h >>conftest.$ac_ext
13206 cat >>conftest.$ac_ext <<_ACEOF
13207 /* end confdefs.h.  */
13208 #include <libxml/parser.h>
13209 _ACEOF
13210 if { (ac_try="$ac_cpp conftest.$ac_ext"
13211 case "(($ac_try" in
13212   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13213   *) ac_try_echo=$ac_try;;
13214 esac
13215 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13216 $as_echo "$ac_try_echo") >&5
13217   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13218   ac_status=$?
13219   grep -v '^ *+' conftest.er1 >conftest.err
13220   rm -f conftest.er1
13221   cat conftest.err >&5
13222   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13223   (exit $ac_status); } >/dev/null && {
13224          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13225          test ! -s conftest.err
13226        }; then
13227   ac_header_preproc=yes
13228 else
13229   $as_echo "$as_me: failed program was:" >&5
13230 sed 's/^/| /' conftest.$ac_ext >&5
13231
13232   ac_header_preproc=no
13233 fi
13234
13235 rm -f conftest.err conftest.$ac_ext
13236 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13237 $as_echo "$ac_header_preproc" >&6; }
13238
13239 # So?  What about this header?
13240 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13241   yes:no: )
13242     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&5
13243 $as_echo "$as_me: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13244     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the compiler's result" >&5
13245 $as_echo "$as_me: WARNING: libxml/parser.h: proceeding with the compiler's result" >&2;}
13246     ac_header_preproc=yes
13247     ;;
13248   no:yes:* )
13249     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: present but cannot be compiled" >&5
13250 $as_echo "$as_me: WARNING: libxml/parser.h: present but cannot be compiled" >&2;}
13251     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&5
13252 $as_echo "$as_me: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&2;}
13253     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: see the Autoconf documentation" >&5
13254 $as_echo "$as_me: WARNING: libxml/parser.h: see the Autoconf documentation" >&2;}
13255     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&5
13256 $as_echo "$as_me: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13257     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&5
13258 $as_echo "$as_me: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&2;}
13259     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&5
13260 $as_echo "$as_me: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&2;}
13261     ( cat <<\_ASBOX
13262 ## ---------------------------------------- ##
13263 ## Report this to pgsql-bugs@postgresql.org ##
13264 ## ---------------------------------------- ##
13265 _ASBOX
13266      ) | sed "s/^/$as_me: WARNING:     /" >&2
13267     ;;
13268 esac
13269 { $as_echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
13270 $as_echo_n "checking for libxml/parser.h... " >&6; }
13271 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13272   $as_echo_n "(cached) " >&6
13273 else
13274   ac_cv_header_libxml_parser_h=$ac_header_preproc
13275 fi
13276 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
13277 $as_echo "$ac_cv_header_libxml_parser_h" >&6; }
13278
13279 fi
13280 if test "x$ac_cv_header_libxml_parser_h" = x""yes; then
13281   :
13282 else
13283   { { $as_echo "$as_me:$LINENO: error: header file <libxml/parser.h> is required for XML support" >&5
13284 $as_echo "$as_me: error: header file <libxml/parser.h> is required for XML support" >&2;}
13285    { (exit 1); exit 1; }; }
13286 fi
13287
13288
13289 fi
13290
13291 if test "$with_libxslt" = yes ; then
13292   if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13293   { $as_echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
13294 $as_echo_n "checking for libxslt/xslt.h... " >&6; }
13295 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13296   $as_echo_n "(cached) " >&6
13297 fi
13298 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
13299 $as_echo "$ac_cv_header_libxslt_xslt_h" >&6; }
13300 else
13301   # Is the header compilable?
13302 { $as_echo "$as_me:$LINENO: checking libxslt/xslt.h usability" >&5
13303 $as_echo_n "checking libxslt/xslt.h usability... " >&6; }
13304 cat >conftest.$ac_ext <<_ACEOF
13305 /* confdefs.h.  */
13306 _ACEOF
13307 cat confdefs.h >>conftest.$ac_ext
13308 cat >>conftest.$ac_ext <<_ACEOF
13309 /* end confdefs.h.  */
13310 $ac_includes_default
13311 #include <libxslt/xslt.h>
13312 _ACEOF
13313 rm -f conftest.$ac_objext
13314 if { (ac_try="$ac_compile"
13315 case "(($ac_try" in
13316   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13317   *) ac_try_echo=$ac_try;;
13318 esac
13319 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13320 $as_echo "$ac_try_echo") >&5
13321   (eval "$ac_compile") 2>conftest.er1
13322   ac_status=$?
13323   grep -v '^ *+' conftest.er1 >conftest.err
13324   rm -f conftest.er1
13325   cat conftest.err >&5
13326   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13327   (exit $ac_status); } && {
13328          test -z "$ac_c_werror_flag" ||
13329          test ! -s conftest.err
13330        } && test -s conftest.$ac_objext; then
13331   ac_header_compiler=yes
13332 else
13333   $as_echo "$as_me: failed program was:" >&5
13334 sed 's/^/| /' conftest.$ac_ext >&5
13335
13336         ac_header_compiler=no
13337 fi
13338
13339 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13340 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13341 $as_echo "$ac_header_compiler" >&6; }
13342
13343 # Is the header present?
13344 { $as_echo "$as_me:$LINENO: checking libxslt/xslt.h presence" >&5
13345 $as_echo_n "checking libxslt/xslt.h presence... " >&6; }
13346 cat >conftest.$ac_ext <<_ACEOF
13347 /* confdefs.h.  */
13348 _ACEOF
13349 cat confdefs.h >>conftest.$ac_ext
13350 cat >>conftest.$ac_ext <<_ACEOF
13351 /* end confdefs.h.  */
13352 #include <libxslt/xslt.h>
13353 _ACEOF
13354 if { (ac_try="$ac_cpp conftest.$ac_ext"
13355 case "(($ac_try" in
13356   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13357   *) ac_try_echo=$ac_try;;
13358 esac
13359 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13360 $as_echo "$ac_try_echo") >&5
13361   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13362   ac_status=$?
13363   grep -v '^ *+' conftest.er1 >conftest.err
13364   rm -f conftest.er1
13365   cat conftest.err >&5
13366   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13367   (exit $ac_status); } >/dev/null && {
13368          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13369          test ! -s conftest.err
13370        }; then
13371   ac_header_preproc=yes
13372 else
13373   $as_echo "$as_me: failed program was:" >&5
13374 sed 's/^/| /' conftest.$ac_ext >&5
13375
13376   ac_header_preproc=no
13377 fi
13378
13379 rm -f conftest.err conftest.$ac_ext
13380 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13381 $as_echo "$ac_header_preproc" >&6; }
13382
13383 # So?  What about this header?
13384 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13385   yes:no: )
13386     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&5
13387 $as_echo "$as_me: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13388     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&5
13389 $as_echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&2;}
13390     ac_header_preproc=yes
13391     ;;
13392   no:yes:* )
13393     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: present but cannot be compiled" >&5
13394 $as_echo "$as_me: WARNING: libxslt/xslt.h: present but cannot be compiled" >&2;}
13395     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&5
13396 $as_echo "$as_me: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&2;}
13397     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&5
13398 $as_echo "$as_me: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&2;}
13399     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&5
13400 $as_echo "$as_me: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13401     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&5
13402 $as_echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&2;}
13403     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&5
13404 $as_echo "$as_me: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&2;}
13405     ( cat <<\_ASBOX
13406 ## ---------------------------------------- ##
13407 ## Report this to pgsql-bugs@postgresql.org ##
13408 ## ---------------------------------------- ##
13409 _ASBOX
13410      ) | sed "s/^/$as_me: WARNING:     /" >&2
13411     ;;
13412 esac
13413 { $as_echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
13414 $as_echo_n "checking for libxslt/xslt.h... " >&6; }
13415 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13416   $as_echo_n "(cached) " >&6
13417 else
13418   ac_cv_header_libxslt_xslt_h=$ac_header_preproc
13419 fi
13420 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
13421 $as_echo "$ac_cv_header_libxslt_xslt_h" >&6; }
13422
13423 fi
13424 if test "x$ac_cv_header_libxslt_xslt_h" = x""yes; then
13425   :
13426 else
13427   { { $as_echo "$as_me:$LINENO: error: header file <libxslt/xslt.h> is required for XSLT support" >&5
13428 $as_echo "$as_me: error: header file <libxslt/xslt.h> is required for XSLT support" >&2;}
13429    { (exit 1); exit 1; }; }
13430 fi
13431
13432
13433 fi
13434
13435 if test "$with_ldap" = yes ; then
13436   if test "$PORTNAME" != "win32"; then
13437
13438 for ac_header in ldap.h
13439 do
13440 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13441 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13442   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13443 $as_echo_n "checking for $ac_header... " >&6; }
13444 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13445   $as_echo_n "(cached) " >&6
13446 fi
13447 ac_res=`eval 'as_val=${'$as_ac_Header'}
13448                  $as_echo "$as_val"'`
13449                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13450 $as_echo "$ac_res" >&6; }
13451 else
13452   # Is the header compilable?
13453 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13454 $as_echo_n "checking $ac_header usability... " >&6; }
13455 cat >conftest.$ac_ext <<_ACEOF
13456 /* confdefs.h.  */
13457 _ACEOF
13458 cat confdefs.h >>conftest.$ac_ext
13459 cat >>conftest.$ac_ext <<_ACEOF
13460 /* end confdefs.h.  */
13461 $ac_includes_default
13462 #include <$ac_header>
13463 _ACEOF
13464 rm -f conftest.$ac_objext
13465 if { (ac_try="$ac_compile"
13466 case "(($ac_try" in
13467   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13468   *) ac_try_echo=$ac_try;;
13469 esac
13470 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13471 $as_echo "$ac_try_echo") >&5
13472   (eval "$ac_compile") 2>conftest.er1
13473   ac_status=$?
13474   grep -v '^ *+' conftest.er1 >conftest.err
13475   rm -f conftest.er1
13476   cat conftest.err >&5
13477   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13478   (exit $ac_status); } && {
13479          test -z "$ac_c_werror_flag" ||
13480          test ! -s conftest.err
13481        } && test -s conftest.$ac_objext; then
13482   ac_header_compiler=yes
13483 else
13484   $as_echo "$as_me: failed program was:" >&5
13485 sed 's/^/| /' conftest.$ac_ext >&5
13486
13487         ac_header_compiler=no
13488 fi
13489
13490 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13491 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13492 $as_echo "$ac_header_compiler" >&6; }
13493
13494 # Is the header present?
13495 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13496 $as_echo_n "checking $ac_header presence... " >&6; }
13497 cat >conftest.$ac_ext <<_ACEOF
13498 /* confdefs.h.  */
13499 _ACEOF
13500 cat confdefs.h >>conftest.$ac_ext
13501 cat >>conftest.$ac_ext <<_ACEOF
13502 /* end confdefs.h.  */
13503 #include <$ac_header>
13504 _ACEOF
13505 if { (ac_try="$ac_cpp conftest.$ac_ext"
13506 case "(($ac_try" in
13507   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13508   *) ac_try_echo=$ac_try;;
13509 esac
13510 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13511 $as_echo "$ac_try_echo") >&5
13512   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13513   ac_status=$?
13514   grep -v '^ *+' conftest.er1 >conftest.err
13515   rm -f conftest.er1
13516   cat conftest.err >&5
13517   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13518   (exit $ac_status); } >/dev/null && {
13519          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13520          test ! -s conftest.err
13521        }; then
13522   ac_header_preproc=yes
13523 else
13524   $as_echo "$as_me: failed program was:" >&5
13525 sed 's/^/| /' conftest.$ac_ext >&5
13526
13527   ac_header_preproc=no
13528 fi
13529
13530 rm -f conftest.err conftest.$ac_ext
13531 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13532 $as_echo "$ac_header_preproc" >&6; }
13533
13534 # So?  What about this header?
13535 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13536   yes:no: )
13537     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13538 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13539     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13540 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13541     ac_header_preproc=yes
13542     ;;
13543   no:yes:* )
13544     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13545 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13546     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13547 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13548     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13549 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13550     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13551 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13552     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13553 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13554     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13555 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13556     ( cat <<\_ASBOX
13557 ## ---------------------------------------- ##
13558 ## Report this to pgsql-bugs@postgresql.org ##
13559 ## ---------------------------------------- ##
13560 _ASBOX
13561      ) | sed "s/^/$as_me: WARNING:     /" >&2
13562     ;;
13563 esac
13564 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13565 $as_echo_n "checking for $ac_header... " >&6; }
13566 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13567   $as_echo_n "(cached) " >&6
13568 else
13569   eval "$as_ac_Header=\$ac_header_preproc"
13570 fi
13571 ac_res=`eval 'as_val=${'$as_ac_Header'}
13572                  $as_echo "$as_val"'`
13573                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13574 $as_echo "$ac_res" >&6; }
13575
13576 fi
13577 as_val=`eval 'as_val=${'$as_ac_Header'}
13578                  $as_echo "$as_val"'`
13579    if test "x$as_val" = x""yes; then
13580   cat >>confdefs.h <<_ACEOF
13581 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13582 _ACEOF
13583
13584 else
13585   { { $as_echo "$as_me:$LINENO: error: header file <ldap.h> is required for LDAP" >&5
13586 $as_echo "$as_me: error: header file <ldap.h> is required for LDAP" >&2;}
13587    { (exit 1); exit 1; }; }
13588 fi
13589
13590 done
13591
13592   else
13593
13594 for ac_header in winldap.h
13595 do
13596 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13597 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13598 $as_echo_n "checking for $ac_header... " >&6; }
13599 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13600   $as_echo_n "(cached) " >&6
13601 else
13602   cat >conftest.$ac_ext <<_ACEOF
13603 /* confdefs.h.  */
13604 _ACEOF
13605 cat confdefs.h >>conftest.$ac_ext
13606 cat >>conftest.$ac_ext <<_ACEOF
13607 /* end confdefs.h.  */
13608 $ac_includes_default
13609 #include <windows.h>
13610
13611
13612 #include <$ac_header>
13613 _ACEOF
13614 rm -f conftest.$ac_objext
13615 if { (ac_try="$ac_compile"
13616 case "(($ac_try" in
13617   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13618   *) ac_try_echo=$ac_try;;
13619 esac
13620 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13621 $as_echo "$ac_try_echo") >&5
13622   (eval "$ac_compile") 2>conftest.er1
13623   ac_status=$?
13624   grep -v '^ *+' conftest.er1 >conftest.err
13625   rm -f conftest.er1
13626   cat conftest.err >&5
13627   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13628   (exit $ac_status); } && {
13629          test -z "$ac_c_werror_flag" ||
13630          test ! -s conftest.err
13631        } && test -s conftest.$ac_objext; then
13632   eval "$as_ac_Header=yes"
13633 else
13634   $as_echo "$as_me: failed program was:" >&5
13635 sed 's/^/| /' conftest.$ac_ext >&5
13636
13637         eval "$as_ac_Header=no"
13638 fi
13639
13640 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13641 fi
13642 ac_res=`eval 'as_val=${'$as_ac_Header'}
13643                  $as_echo "$as_val"'`
13644                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13645 $as_echo "$ac_res" >&6; }
13646 as_val=`eval 'as_val=${'$as_ac_Header'}
13647                  $as_echo "$as_val"'`
13648    if test "x$as_val" = x""yes; then
13649   cat >>confdefs.h <<_ACEOF
13650 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13651 _ACEOF
13652
13653 else
13654   { { $as_echo "$as_me:$LINENO: error: header file <winldap.h> is required for LDAP" >&5
13655 $as_echo "$as_me: error: header file <winldap.h> is required for LDAP" >&2;}
13656    { (exit 1); exit 1; }; }
13657 fi
13658
13659 done
13660
13661   fi
13662 fi
13663
13664 if test "$with_bonjour" = yes ; then
13665   if test "${ac_cv_header_dns_sd_h+set}" = set; then
13666   { $as_echo "$as_me:$LINENO: checking for dns_sd.h" >&5
13667 $as_echo_n "checking for dns_sd.h... " >&6; }
13668 if test "${ac_cv_header_dns_sd_h+set}" = set; then
13669   $as_echo_n "(cached) " >&6
13670 fi
13671 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_dns_sd_h" >&5
13672 $as_echo "$ac_cv_header_dns_sd_h" >&6; }
13673 else
13674   # Is the header compilable?
13675 { $as_echo "$as_me:$LINENO: checking dns_sd.h usability" >&5
13676 $as_echo_n "checking dns_sd.h usability... " >&6; }
13677 cat >conftest.$ac_ext <<_ACEOF
13678 /* confdefs.h.  */
13679 _ACEOF
13680 cat confdefs.h >>conftest.$ac_ext
13681 cat >>conftest.$ac_ext <<_ACEOF
13682 /* end confdefs.h.  */
13683 $ac_includes_default
13684 #include <dns_sd.h>
13685 _ACEOF
13686 rm -f conftest.$ac_objext
13687 if { (ac_try="$ac_compile"
13688 case "(($ac_try" in
13689   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13690   *) ac_try_echo=$ac_try;;
13691 esac
13692 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13693 $as_echo "$ac_try_echo") >&5
13694   (eval "$ac_compile") 2>conftest.er1
13695   ac_status=$?
13696   grep -v '^ *+' conftest.er1 >conftest.err
13697   rm -f conftest.er1
13698   cat conftest.err >&5
13699   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13700   (exit $ac_status); } && {
13701          test -z "$ac_c_werror_flag" ||
13702          test ! -s conftest.err
13703        } && test -s conftest.$ac_objext; then
13704   ac_header_compiler=yes
13705 else
13706   $as_echo "$as_me: failed program was:" >&5
13707 sed 's/^/| /' conftest.$ac_ext >&5
13708
13709         ac_header_compiler=no
13710 fi
13711
13712 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13713 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13714 $as_echo "$ac_header_compiler" >&6; }
13715
13716 # Is the header present?
13717 { $as_echo "$as_me:$LINENO: checking dns_sd.h presence" >&5
13718 $as_echo_n "checking dns_sd.h presence... " >&6; }
13719 cat >conftest.$ac_ext <<_ACEOF
13720 /* confdefs.h.  */
13721 _ACEOF
13722 cat confdefs.h >>conftest.$ac_ext
13723 cat >>conftest.$ac_ext <<_ACEOF
13724 /* end confdefs.h.  */
13725 #include <dns_sd.h>
13726 _ACEOF
13727 if { (ac_try="$ac_cpp conftest.$ac_ext"
13728 case "(($ac_try" in
13729   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13730   *) ac_try_echo=$ac_try;;
13731 esac
13732 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13733 $as_echo "$ac_try_echo") >&5
13734   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13735   ac_status=$?
13736   grep -v '^ *+' conftest.er1 >conftest.err
13737   rm -f conftest.er1
13738   cat conftest.err >&5
13739   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13740   (exit $ac_status); } >/dev/null && {
13741          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13742          test ! -s conftest.err
13743        }; then
13744   ac_header_preproc=yes
13745 else
13746   $as_echo "$as_me: failed program was:" >&5
13747 sed 's/^/| /' conftest.$ac_ext >&5
13748
13749   ac_header_preproc=no
13750 fi
13751
13752 rm -f conftest.err conftest.$ac_ext
13753 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13754 $as_echo "$ac_header_preproc" >&6; }
13755
13756 # So?  What about this header?
13757 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13758   yes:no: )
13759     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: accepted by the compiler, rejected by the preprocessor!" >&5
13760 $as_echo "$as_me: WARNING: dns_sd.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13761     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: proceeding with the compiler's result" >&5
13762 $as_echo "$as_me: WARNING: dns_sd.h: proceeding with the compiler's result" >&2;}
13763     ac_header_preproc=yes
13764     ;;
13765   no:yes:* )
13766     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: present but cannot be compiled" >&5
13767 $as_echo "$as_me: WARNING: dns_sd.h: present but cannot be compiled" >&2;}
13768     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h:     check for missing prerequisite headers?" >&5
13769 $as_echo "$as_me: WARNING: dns_sd.h:     check for missing prerequisite headers?" >&2;}
13770     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: see the Autoconf documentation" >&5
13771 $as_echo "$as_me: WARNING: dns_sd.h: see the Autoconf documentation" >&2;}
13772     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h:     section \"Present But Cannot Be Compiled\"" >&5
13773 $as_echo "$as_me: WARNING: dns_sd.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13774     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: proceeding with the preprocessor's result" >&5
13775 $as_echo "$as_me: WARNING: dns_sd.h: proceeding with the preprocessor's result" >&2;}
13776     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: in the future, the compiler will take precedence" >&5
13777 $as_echo "$as_me: WARNING: dns_sd.h: in the future, the compiler will take precedence" >&2;}
13778     ( cat <<\_ASBOX
13779 ## ---------------------------------------- ##
13780 ## Report this to pgsql-bugs@postgresql.org ##
13781 ## ---------------------------------------- ##
13782 _ASBOX
13783      ) | sed "s/^/$as_me: WARNING:     /" >&2
13784     ;;
13785 esac
13786 { $as_echo "$as_me:$LINENO: checking for dns_sd.h" >&5
13787 $as_echo_n "checking for dns_sd.h... " >&6; }
13788 if test "${ac_cv_header_dns_sd_h+set}" = set; then
13789   $as_echo_n "(cached) " >&6
13790 else
13791   ac_cv_header_dns_sd_h=$ac_header_preproc
13792 fi
13793 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_dns_sd_h" >&5
13794 $as_echo "$ac_cv_header_dns_sd_h" >&6; }
13795
13796 fi
13797 if test "x$ac_cv_header_dns_sd_h" = x""yes; then
13798   :
13799 else
13800   { { $as_echo "$as_me:$LINENO: error: header file <dns_sd.h> is required for Bonjour" >&5
13801 $as_echo "$as_me: error: header file <dns_sd.h> is required for Bonjour" >&2;}
13802    { (exit 1); exit 1; }; }
13803 fi
13804
13805
13806 fi
13807
13808 # for contrib/uuid-ossp
13809 if test "$with_ossp_uuid" = yes ; then
13810
13811 for ac_header in ossp/uuid.h
13812 do
13813 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13814 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13815   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13816 $as_echo_n "checking for $ac_header... " >&6; }
13817 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13818   $as_echo_n "(cached) " >&6
13819 fi
13820 ac_res=`eval 'as_val=${'$as_ac_Header'}
13821                  $as_echo "$as_val"'`
13822                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13823 $as_echo "$ac_res" >&6; }
13824 else
13825   # Is the header compilable?
13826 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13827 $as_echo_n "checking $ac_header usability... " >&6; }
13828 cat >conftest.$ac_ext <<_ACEOF
13829 /* confdefs.h.  */
13830 _ACEOF
13831 cat confdefs.h >>conftest.$ac_ext
13832 cat >>conftest.$ac_ext <<_ACEOF
13833 /* end confdefs.h.  */
13834 $ac_includes_default
13835 #include <$ac_header>
13836 _ACEOF
13837 rm -f conftest.$ac_objext
13838 if { (ac_try="$ac_compile"
13839 case "(($ac_try" in
13840   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13841   *) ac_try_echo=$ac_try;;
13842 esac
13843 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13844 $as_echo "$ac_try_echo") >&5
13845   (eval "$ac_compile") 2>conftest.er1
13846   ac_status=$?
13847   grep -v '^ *+' conftest.er1 >conftest.err
13848   rm -f conftest.er1
13849   cat conftest.err >&5
13850   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13851   (exit $ac_status); } && {
13852          test -z "$ac_c_werror_flag" ||
13853          test ! -s conftest.err
13854        } && test -s conftest.$ac_objext; then
13855   ac_header_compiler=yes
13856 else
13857   $as_echo "$as_me: failed program was:" >&5
13858 sed 's/^/| /' conftest.$ac_ext >&5
13859
13860         ac_header_compiler=no
13861 fi
13862
13863 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13864 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13865 $as_echo "$ac_header_compiler" >&6; }
13866
13867 # Is the header present?
13868 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13869 $as_echo_n "checking $ac_header presence... " >&6; }
13870 cat >conftest.$ac_ext <<_ACEOF
13871 /* confdefs.h.  */
13872 _ACEOF
13873 cat confdefs.h >>conftest.$ac_ext
13874 cat >>conftest.$ac_ext <<_ACEOF
13875 /* end confdefs.h.  */
13876 #include <$ac_header>
13877 _ACEOF
13878 if { (ac_try="$ac_cpp conftest.$ac_ext"
13879 case "(($ac_try" in
13880   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13881   *) ac_try_echo=$ac_try;;
13882 esac
13883 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13884 $as_echo "$ac_try_echo") >&5
13885   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13886   ac_status=$?
13887   grep -v '^ *+' conftest.er1 >conftest.err
13888   rm -f conftest.er1
13889   cat conftest.err >&5
13890   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13891   (exit $ac_status); } >/dev/null && {
13892          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13893          test ! -s conftest.err
13894        }; then
13895   ac_header_preproc=yes
13896 else
13897   $as_echo "$as_me: failed program was:" >&5
13898 sed 's/^/| /' conftest.$ac_ext >&5
13899
13900   ac_header_preproc=no
13901 fi
13902
13903 rm -f conftest.err conftest.$ac_ext
13904 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13905 $as_echo "$ac_header_preproc" >&6; }
13906
13907 # So?  What about this header?
13908 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13909   yes:no: )
13910     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13911 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13912     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13913 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13914     ac_header_preproc=yes
13915     ;;
13916   no:yes:* )
13917     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13918 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13919     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13920 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13921     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13922 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13923     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13924 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13925     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13926 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13927     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13928 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13929     ( cat <<\_ASBOX
13930 ## ---------------------------------------- ##
13931 ## Report this to pgsql-bugs@postgresql.org ##
13932 ## ---------------------------------------- ##
13933 _ASBOX
13934      ) | sed "s/^/$as_me: WARNING:     /" >&2
13935     ;;
13936 esac
13937 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13938 $as_echo_n "checking for $ac_header... " >&6; }
13939 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13940   $as_echo_n "(cached) " >&6
13941 else
13942   eval "$as_ac_Header=\$ac_header_preproc"
13943 fi
13944 ac_res=`eval 'as_val=${'$as_ac_Header'}
13945                  $as_echo "$as_val"'`
13946                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13947 $as_echo "$ac_res" >&6; }
13948
13949 fi
13950 as_val=`eval 'as_val=${'$as_ac_Header'}
13951                  $as_echo "$as_val"'`
13952    if test "x$as_val" = x""yes; then
13953   cat >>confdefs.h <<_ACEOF
13954 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13955 _ACEOF
13956
13957 else
13958
13959
13960 for ac_header in uuid.h
13961 do
13962 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13963 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13964   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13965 $as_echo_n "checking for $ac_header... " >&6; }
13966 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13967   $as_echo_n "(cached) " >&6
13968 fi
13969 ac_res=`eval 'as_val=${'$as_ac_Header'}
13970                  $as_echo "$as_val"'`
13971                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13972 $as_echo "$ac_res" >&6; }
13973 else
13974   # Is the header compilable?
13975 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13976 $as_echo_n "checking $ac_header usability... " >&6; }
13977 cat >conftest.$ac_ext <<_ACEOF
13978 /* confdefs.h.  */
13979 _ACEOF
13980 cat confdefs.h >>conftest.$ac_ext
13981 cat >>conftest.$ac_ext <<_ACEOF
13982 /* end confdefs.h.  */
13983 $ac_includes_default
13984 #include <$ac_header>
13985 _ACEOF
13986 rm -f conftest.$ac_objext
13987 if { (ac_try="$ac_compile"
13988 case "(($ac_try" in
13989   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13990   *) ac_try_echo=$ac_try;;
13991 esac
13992 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13993 $as_echo "$ac_try_echo") >&5
13994   (eval "$ac_compile") 2>conftest.er1
13995   ac_status=$?
13996   grep -v '^ *+' conftest.er1 >conftest.err
13997   rm -f conftest.er1
13998   cat conftest.err >&5
13999   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14000   (exit $ac_status); } && {
14001          test -z "$ac_c_werror_flag" ||
14002          test ! -s conftest.err
14003        } && test -s conftest.$ac_objext; then
14004   ac_header_compiler=yes
14005 else
14006   $as_echo "$as_me: failed program was:" >&5
14007 sed 's/^/| /' conftest.$ac_ext >&5
14008
14009         ac_header_compiler=no
14010 fi
14011
14012 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14013 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
14014 $as_echo "$ac_header_compiler" >&6; }
14015
14016 # Is the header present?
14017 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
14018 $as_echo_n "checking $ac_header presence... " >&6; }
14019 cat >conftest.$ac_ext <<_ACEOF
14020 /* confdefs.h.  */
14021 _ACEOF
14022 cat confdefs.h >>conftest.$ac_ext
14023 cat >>conftest.$ac_ext <<_ACEOF
14024 /* end confdefs.h.  */
14025 #include <$ac_header>
14026 _ACEOF
14027 if { (ac_try="$ac_cpp conftest.$ac_ext"
14028 case "(($ac_try" in
14029   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14030   *) ac_try_echo=$ac_try;;
14031 esac
14032 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14033 $as_echo "$ac_try_echo") >&5
14034   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
14035   ac_status=$?
14036   grep -v '^ *+' conftest.er1 >conftest.err
14037   rm -f conftest.er1
14038   cat conftest.err >&5
14039   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14040   (exit $ac_status); } >/dev/null && {
14041          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
14042          test ! -s conftest.err
14043        }; then
14044   ac_header_preproc=yes
14045 else
14046   $as_echo "$as_me: failed program was:" >&5
14047 sed 's/^/| /' conftest.$ac_ext >&5
14048
14049   ac_header_preproc=no
14050 fi
14051
14052 rm -f conftest.err conftest.$ac_ext
14053 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
14054 $as_echo "$ac_header_preproc" >&6; }
14055
14056 # So?  What about this header?
14057 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
14058   yes:no: )
14059     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
14060 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
14061     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
14062 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
14063     ac_header_preproc=yes
14064     ;;
14065   no:yes:* )
14066     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
14067 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
14068     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
14069 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
14070     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
14071 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
14072     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
14073 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
14074     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
14075 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
14076     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
14077 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
14078     ( cat <<\_ASBOX
14079 ## ---------------------------------------- ##
14080 ## Report this to pgsql-bugs@postgresql.org ##
14081 ## ---------------------------------------- ##
14082 _ASBOX
14083      ) | sed "s/^/$as_me: WARNING:     /" >&2
14084     ;;
14085 esac
14086 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
14087 $as_echo_n "checking for $ac_header... " >&6; }
14088 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
14089   $as_echo_n "(cached) " >&6
14090 else
14091   eval "$as_ac_Header=\$ac_header_preproc"
14092 fi
14093 ac_res=`eval 'as_val=${'$as_ac_Header'}
14094                  $as_echo "$as_val"'`
14095                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
14096 $as_echo "$ac_res" >&6; }
14097
14098 fi
14099 as_val=`eval 'as_val=${'$as_ac_Header'}
14100                  $as_echo "$as_val"'`
14101    if test "x$as_val" = x""yes; then
14102   cat >>confdefs.h <<_ACEOF
14103 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
14104 _ACEOF
14105
14106 else
14107   { { $as_echo "$as_me:$LINENO: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&5
14108 $as_echo "$as_me: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&2;}
14109    { (exit 1); exit 1; }; }
14110 fi
14111
14112 done
14113
14114 fi
14115
14116 done
14117
14118 fi
14119
14120
14121 ##
14122 ## Types, structures, compiler characteristics
14123 ##
14124
14125
14126  { $as_echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
14127 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
14128 if test "${ac_cv_c_bigendian+set}" = set; then
14129   $as_echo_n "(cached) " >&6
14130 else
14131   ac_cv_c_bigendian=unknown
14132     # See if we're dealing with a universal compiler.
14133     cat >conftest.$ac_ext <<_ACEOF
14134 /* confdefs.h.  */
14135 _ACEOF
14136 cat confdefs.h >>conftest.$ac_ext
14137 cat >>conftest.$ac_ext <<_ACEOF
14138 /* end confdefs.h.  */
14139 #ifndef __APPLE_CC__
14140                not a universal capable compiler
14141              #endif
14142              typedef int dummy;
14143
14144 _ACEOF
14145 rm -f conftest.$ac_objext
14146 if { (ac_try="$ac_compile"
14147 case "(($ac_try" in
14148   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14149   *) ac_try_echo=$ac_try;;
14150 esac
14151 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14152 $as_echo "$ac_try_echo") >&5
14153   (eval "$ac_compile") 2>conftest.er1
14154   ac_status=$?
14155   grep -v '^ *+' conftest.er1 >conftest.err
14156   rm -f conftest.er1
14157   cat conftest.err >&5
14158   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14159   (exit $ac_status); } && {
14160          test -z "$ac_c_werror_flag" ||
14161          test ! -s conftest.err
14162        } && test -s conftest.$ac_objext; then
14163
14164         # Check for potential -arch flags.  It is not universal unless
14165         # there are some -arch flags.  Note that *ppc* also matches
14166         # ppc64.  This check is also rather less than ideal.
14167         case "${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}" in  #(
14168           *-arch*ppc*|*-arch*i386*|*-arch*x86_64*) ac_cv_c_bigendian=universal;;
14169         esac
14170 else
14171   $as_echo "$as_me: failed program was:" >&5
14172 sed 's/^/| /' conftest.$ac_ext >&5
14173
14174
14175 fi
14176
14177 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14178     if test $ac_cv_c_bigendian = unknown; then
14179       # See if sys/param.h defines the BYTE_ORDER macro.
14180       cat >conftest.$ac_ext <<_ACEOF
14181 /* confdefs.h.  */
14182 _ACEOF
14183 cat confdefs.h >>conftest.$ac_ext
14184 cat >>conftest.$ac_ext <<_ACEOF
14185 /* end confdefs.h.  */
14186 #include <sys/types.h>
14187              #include <sys/param.h>
14188
14189 int
14190 main ()
14191 {
14192 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
14193                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
14194                      && LITTLE_ENDIAN)
14195               bogus endian macros
14196              #endif
14197
14198   ;
14199   return 0;
14200 }
14201 _ACEOF
14202 rm -f conftest.$ac_objext
14203 if { (ac_try="$ac_compile"
14204 case "(($ac_try" in
14205   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14206   *) ac_try_echo=$ac_try;;
14207 esac
14208 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14209 $as_echo "$ac_try_echo") >&5
14210   (eval "$ac_compile") 2>conftest.er1
14211   ac_status=$?
14212   grep -v '^ *+' conftest.er1 >conftest.err
14213   rm -f conftest.er1
14214   cat conftest.err >&5
14215   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14216   (exit $ac_status); } && {
14217          test -z "$ac_c_werror_flag" ||
14218          test ! -s conftest.err
14219        } && test -s conftest.$ac_objext; then
14220   # It does; now see whether it defined to BIG_ENDIAN or not.
14221          cat >conftest.$ac_ext <<_ACEOF
14222 /* confdefs.h.  */
14223 _ACEOF
14224 cat confdefs.h >>conftest.$ac_ext
14225 cat >>conftest.$ac_ext <<_ACEOF
14226 /* end confdefs.h.  */
14227 #include <sys/types.h>
14228                 #include <sys/param.h>
14229
14230 int
14231 main ()
14232 {
14233 #if BYTE_ORDER != BIG_ENDIAN
14234                  not big endian
14235                 #endif
14236
14237   ;
14238   return 0;
14239 }
14240 _ACEOF
14241 rm -f conftest.$ac_objext
14242 if { (ac_try="$ac_compile"
14243 case "(($ac_try" in
14244   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14245   *) ac_try_echo=$ac_try;;
14246 esac
14247 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14248 $as_echo "$ac_try_echo") >&5
14249   (eval "$ac_compile") 2>conftest.er1
14250   ac_status=$?
14251   grep -v '^ *+' conftest.er1 >conftest.err
14252   rm -f conftest.er1
14253   cat conftest.err >&5
14254   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14255   (exit $ac_status); } && {
14256          test -z "$ac_c_werror_flag" ||
14257          test ! -s conftest.err
14258        } && test -s conftest.$ac_objext; then
14259   ac_cv_c_bigendian=yes
14260 else
14261   $as_echo "$as_me: failed program was:" >&5
14262 sed 's/^/| /' conftest.$ac_ext >&5
14263
14264         ac_cv_c_bigendian=no
14265 fi
14266
14267 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14268 else
14269   $as_echo "$as_me: failed program was:" >&5
14270 sed 's/^/| /' conftest.$ac_ext >&5
14271
14272
14273 fi
14274
14275 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14276     fi
14277     if test $ac_cv_c_bigendian = unknown; then
14278       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
14279       cat >conftest.$ac_ext <<_ACEOF
14280 /* confdefs.h.  */
14281 _ACEOF
14282 cat confdefs.h >>conftest.$ac_ext
14283 cat >>conftest.$ac_ext <<_ACEOF
14284 /* end confdefs.h.  */
14285 #include <limits.h>
14286
14287 int
14288 main ()
14289 {
14290 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
14291               bogus endian macros
14292              #endif
14293
14294   ;
14295   return 0;
14296 }
14297 _ACEOF
14298 rm -f conftest.$ac_objext
14299 if { (ac_try="$ac_compile"
14300 case "(($ac_try" in
14301   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14302   *) ac_try_echo=$ac_try;;
14303 esac
14304 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14305 $as_echo "$ac_try_echo") >&5
14306   (eval "$ac_compile") 2>conftest.er1
14307   ac_status=$?
14308   grep -v '^ *+' conftest.er1 >conftest.err
14309   rm -f conftest.er1
14310   cat conftest.err >&5
14311   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14312   (exit $ac_status); } && {
14313          test -z "$ac_c_werror_flag" ||
14314          test ! -s conftest.err
14315        } && test -s conftest.$ac_objext; then
14316   # It does; now see whether it defined to _BIG_ENDIAN or not.
14317          cat >conftest.$ac_ext <<_ACEOF
14318 /* confdefs.h.  */
14319 _ACEOF
14320 cat confdefs.h >>conftest.$ac_ext
14321 cat >>conftest.$ac_ext <<_ACEOF
14322 /* end confdefs.h.  */
14323 #include <limits.h>
14324
14325 int
14326 main ()
14327 {
14328 #ifndef _BIG_ENDIAN
14329                  not big endian
14330                 #endif
14331
14332   ;
14333   return 0;
14334 }
14335 _ACEOF
14336 rm -f conftest.$ac_objext
14337 if { (ac_try="$ac_compile"
14338 case "(($ac_try" in
14339   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14340   *) ac_try_echo=$ac_try;;
14341 esac
14342 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14343 $as_echo "$ac_try_echo") >&5
14344   (eval "$ac_compile") 2>conftest.er1
14345   ac_status=$?
14346   grep -v '^ *+' conftest.er1 >conftest.err
14347   rm -f conftest.er1
14348   cat conftest.err >&5
14349   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14350   (exit $ac_status); } && {
14351          test -z "$ac_c_werror_flag" ||
14352          test ! -s conftest.err
14353        } && test -s conftest.$ac_objext; then
14354   ac_cv_c_bigendian=yes
14355 else
14356   $as_echo "$as_me: failed program was:" >&5
14357 sed 's/^/| /' conftest.$ac_ext >&5
14358
14359         ac_cv_c_bigendian=no
14360 fi
14361
14362 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14363 else
14364   $as_echo "$as_me: failed program was:" >&5
14365 sed 's/^/| /' conftest.$ac_ext >&5
14366
14367
14368 fi
14369
14370 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14371     fi
14372     if test $ac_cv_c_bigendian = unknown; then
14373       # Compile a test program.
14374       if test "$cross_compiling" = yes; then
14375   # Try to guess by grepping values from an object file.
14376          cat >conftest.$ac_ext <<_ACEOF
14377 /* confdefs.h.  */
14378 _ACEOF
14379 cat confdefs.h >>conftest.$ac_ext
14380 cat >>conftest.$ac_ext <<_ACEOF
14381 /* end confdefs.h.  */
14382 short int ascii_mm[] =
14383                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
14384                 short int ascii_ii[] =
14385                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
14386                 int use_ascii (int i) {
14387                   return ascii_mm[i] + ascii_ii[i];
14388                 }
14389                 short int ebcdic_ii[] =
14390                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
14391                 short int ebcdic_mm[] =
14392                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
14393                 int use_ebcdic (int i) {
14394                   return ebcdic_mm[i] + ebcdic_ii[i];
14395                 }
14396                 extern int foo;
14397
14398 int
14399 main ()
14400 {
14401 return use_ascii (foo) == use_ebcdic (foo);
14402   ;
14403   return 0;
14404 }
14405 _ACEOF
14406 rm -f conftest.$ac_objext
14407 if { (ac_try="$ac_compile"
14408 case "(($ac_try" in
14409   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14410   *) ac_try_echo=$ac_try;;
14411 esac
14412 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14413 $as_echo "$ac_try_echo") >&5
14414   (eval "$ac_compile") 2>conftest.er1
14415   ac_status=$?
14416   grep -v '^ *+' conftest.er1 >conftest.err
14417   rm -f conftest.er1
14418   cat conftest.err >&5
14419   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14420   (exit $ac_status); } && {
14421          test -z "$ac_c_werror_flag" ||
14422          test ! -s conftest.err
14423        } && test -s conftest.$ac_objext; then
14424   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
14425               ac_cv_c_bigendian=yes
14426             fi
14427             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
14428               if test "$ac_cv_c_bigendian" = unknown; then
14429                 ac_cv_c_bigendian=no
14430               else
14431                 # finding both strings is unlikely to happen, but who knows?
14432                 ac_cv_c_bigendian=unknown
14433               fi
14434             fi
14435 else
14436   $as_echo "$as_me: failed program was:" >&5
14437 sed 's/^/| /' conftest.$ac_ext >&5
14438
14439
14440 fi
14441
14442 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14443 else
14444   cat >conftest.$ac_ext <<_ACEOF
14445 /* confdefs.h.  */
14446 _ACEOF
14447 cat confdefs.h >>conftest.$ac_ext
14448 cat >>conftest.$ac_ext <<_ACEOF
14449 /* end confdefs.h.  */
14450 $ac_includes_default
14451 int
14452 main ()
14453 {
14454
14455              /* Are we little or big endian?  From Harbison&Steele.  */
14456              union
14457              {
14458                long int l;
14459                char c[sizeof (long int)];
14460              } u;
14461              u.l = 1;
14462              return u.c[sizeof (long int) - 1] == 1;
14463
14464   ;
14465   return 0;
14466 }
14467 _ACEOF
14468 rm -f conftest$ac_exeext
14469 if { (ac_try="$ac_link"
14470 case "(($ac_try" in
14471   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14472   *) ac_try_echo=$ac_try;;
14473 esac
14474 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14475 $as_echo "$ac_try_echo") >&5
14476   (eval "$ac_link") 2>&5
14477   ac_status=$?
14478   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14479   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14480   { (case "(($ac_try" in
14481   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14482   *) ac_try_echo=$ac_try;;
14483 esac
14484 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14485 $as_echo "$ac_try_echo") >&5
14486   (eval "$ac_try") 2>&5
14487   ac_status=$?
14488   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14489   (exit $ac_status); }; }; then
14490   ac_cv_c_bigendian=no
14491 else
14492   $as_echo "$as_me: program exited with status $ac_status" >&5
14493 $as_echo "$as_me: failed program was:" >&5
14494 sed 's/^/| /' conftest.$ac_ext >&5
14495
14496 ( exit $ac_status )
14497 ac_cv_c_bigendian=yes
14498 fi
14499 rm -rf conftest.dSYM
14500 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14501 fi
14502
14503
14504     fi
14505 fi
14506 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
14507 $as_echo "$ac_cv_c_bigendian" >&6; }
14508  case $ac_cv_c_bigendian in #(
14509    yes)
14510      cat >>confdefs.h <<\_ACEOF
14511 #define WORDS_BIGENDIAN 1
14512 _ACEOF
14513 ;; #(
14514    no)
14515       ;; #(
14516    universal)
14517
14518 cat >>confdefs.h <<\_ACEOF
14519 #define AC_APPLE_UNIVERSAL_BUILD 1
14520 _ACEOF
14521
14522      ;; #(
14523    *)
14524      { { $as_echo "$as_me:$LINENO: error: unknown endianness
14525  presetting ac_cv_c_bigendian=no (or yes) will help" >&5
14526 $as_echo "$as_me: error: unknown endianness
14527  presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
14528    { (exit 1); exit 1; }; } ;;
14529  esac
14530
14531 { $as_echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
14532 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
14533 if test "${ac_cv_c_const+set}" = set; then
14534   $as_echo_n "(cached) " >&6
14535 else
14536   cat >conftest.$ac_ext <<_ACEOF
14537 /* confdefs.h.  */
14538 _ACEOF
14539 cat confdefs.h >>conftest.$ac_ext
14540 cat >>conftest.$ac_ext <<_ACEOF
14541 /* end confdefs.h.  */
14542
14543 int
14544 main ()
14545 {
14546 /* FIXME: Include the comments suggested by Paul. */
14547 #ifndef __cplusplus
14548   /* Ultrix mips cc rejects this.  */
14549   typedef int charset[2];
14550   const charset cs;
14551   /* SunOS 4.1.1 cc rejects this.  */
14552   char const *const *pcpcc;
14553   char **ppc;
14554   /* NEC SVR4.0.2 mips cc rejects this.  */
14555   struct point {int x, y;};
14556   static struct point const zero = {0,0};
14557   /* AIX XL C 1.02.0.0 rejects this.
14558      It does not let you subtract one const X* pointer from another in
14559      an arm of an if-expression whose if-part is not a constant
14560      expression */
14561   const char *g = "string";
14562   pcpcc = &g + (g ? g-g : 0);
14563   /* HPUX 7.0 cc rejects these. */
14564   ++pcpcc;
14565   ppc = (char**) pcpcc;
14566   pcpcc = (char const *const *) ppc;
14567   { /* SCO 3.2v4 cc rejects this.  */
14568     char *t;
14569     char const *s = 0 ? (char *) 0 : (char const *) 0;
14570
14571     *t++ = 0;
14572     if (s) return 0;
14573   }
14574   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
14575     int x[] = {25, 17};
14576     const int *foo = &x[0];
14577     ++foo;
14578   }
14579   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
14580     typedef const int *iptr;
14581     iptr p = 0;
14582     ++p;
14583   }
14584   { /* AIX XL C 1.02.0.0 rejects this saying
14585        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
14586     struct s { int j; const int *ap[3]; };
14587     struct s *b; b->j = 5;
14588   }
14589   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
14590     const int foo = 10;
14591     if (!foo) return 0;
14592   }
14593   return !cs[0] && !zero.x;
14594 #endif
14595
14596   ;
14597   return 0;
14598 }
14599 _ACEOF
14600 rm -f conftest.$ac_objext
14601 if { (ac_try="$ac_compile"
14602 case "(($ac_try" in
14603   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14604   *) ac_try_echo=$ac_try;;
14605 esac
14606 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14607 $as_echo "$ac_try_echo") >&5
14608   (eval "$ac_compile") 2>conftest.er1
14609   ac_status=$?
14610   grep -v '^ *+' conftest.er1 >conftest.err
14611   rm -f conftest.er1
14612   cat conftest.err >&5
14613   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14614   (exit $ac_status); } && {
14615          test -z "$ac_c_werror_flag" ||
14616          test ! -s conftest.err
14617        } && test -s conftest.$ac_objext; then
14618   ac_cv_c_const=yes
14619 else
14620   $as_echo "$as_me: failed program was:" >&5
14621 sed 's/^/| /' conftest.$ac_ext >&5
14622
14623         ac_cv_c_const=no
14624 fi
14625
14626 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14627 fi
14628 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
14629 $as_echo "$ac_cv_c_const" >&6; }
14630 if test $ac_cv_c_const = no; then
14631
14632 cat >>confdefs.h <<\_ACEOF
14633 #define const /**/
14634 _ACEOF
14635
14636 fi
14637
14638 { $as_echo "$as_me:$LINENO: checking for inline" >&5
14639 $as_echo_n "checking for inline... " >&6; }
14640 if test "${ac_cv_c_inline+set}" = set; then
14641   $as_echo_n "(cached) " >&6
14642 else
14643   ac_cv_c_inline=no
14644 for ac_kw in inline __inline__ __inline; do
14645   cat >conftest.$ac_ext <<_ACEOF
14646 /* confdefs.h.  */
14647 _ACEOF
14648 cat confdefs.h >>conftest.$ac_ext
14649 cat >>conftest.$ac_ext <<_ACEOF
14650 /* end confdefs.h.  */
14651 #ifndef __cplusplus
14652 typedef int foo_t;
14653 static $ac_kw foo_t static_foo () {return 0; }
14654 $ac_kw foo_t foo () {return 0; }
14655 #endif
14656
14657 _ACEOF
14658 rm -f conftest.$ac_objext
14659 if { (ac_try="$ac_compile"
14660 case "(($ac_try" in
14661   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14662   *) ac_try_echo=$ac_try;;
14663 esac
14664 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14665 $as_echo "$ac_try_echo") >&5
14666   (eval "$ac_compile") 2>conftest.er1
14667   ac_status=$?
14668   grep -v '^ *+' conftest.er1 >conftest.err
14669   rm -f conftest.er1
14670   cat conftest.err >&5
14671   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14672   (exit $ac_status); } && {
14673          test -z "$ac_c_werror_flag" ||
14674          test ! -s conftest.err
14675        } && test -s conftest.$ac_objext; then
14676   ac_cv_c_inline=$ac_kw
14677 else
14678   $as_echo "$as_me: failed program was:" >&5
14679 sed 's/^/| /' conftest.$ac_ext >&5
14680
14681
14682 fi
14683
14684 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14685   test "$ac_cv_c_inline" != no && break
14686 done
14687
14688 fi
14689 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
14690 $as_echo "$ac_cv_c_inline" >&6; }
14691
14692
14693 case $ac_cv_c_inline in
14694   inline | yes) ;;
14695   *)
14696     case $ac_cv_c_inline in
14697       no) ac_val=;;
14698       *) ac_val=$ac_cv_c_inline;;
14699     esac
14700     cat >>confdefs.h <<_ACEOF
14701 #ifndef __cplusplus
14702 #define inline $ac_val
14703 #endif
14704 _ACEOF
14705     ;;
14706 esac
14707
14708 { $as_echo "$as_me:$LINENO: checking for quiet inline (no complaint if unreferenced)" >&5
14709 $as_echo_n "checking for quiet inline (no complaint if unreferenced)... " >&6; }
14710 if test "${pgac_cv_c_inline_quietly+set}" = set; then
14711   $as_echo_n "(cached) " >&6
14712 else
14713   pgac_cv_c_inline_quietly=no
14714   if test "$ac_cv_c_inline" != no; then
14715     pgac_c_inline_save_werror=$ac_c_werror_flag
14716     ac_c_werror_flag=yes
14717     cat >conftest.$ac_ext <<_ACEOF
14718 /* confdefs.h.  */
14719 _ACEOF
14720 cat confdefs.h >>conftest.$ac_ext
14721 cat >>conftest.$ac_ext <<_ACEOF
14722 /* end confdefs.h.  */
14723 static inline int fun () {return 0;}
14724 int
14725 main ()
14726 {
14727
14728   ;
14729   return 0;
14730 }
14731 _ACEOF
14732 rm -f conftest.$ac_objext conftest$ac_exeext
14733 if { (ac_try="$ac_link"
14734 case "(($ac_try" in
14735   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14736   *) ac_try_echo=$ac_try;;
14737 esac
14738 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14739 $as_echo "$ac_try_echo") >&5
14740   (eval "$ac_link") 2>conftest.er1
14741   ac_status=$?
14742   grep -v '^ *+' conftest.er1 >conftest.err
14743   rm -f conftest.er1
14744   cat conftest.err >&5
14745   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14746   (exit $ac_status); } && {
14747          test -z "$ac_c_werror_flag" ||
14748          test ! -s conftest.err
14749        } && test -s conftest$ac_exeext && {
14750          test "$cross_compiling" = yes ||
14751          $as_test_x conftest$ac_exeext
14752        }; then
14753   pgac_cv_c_inline_quietly=yes
14754 else
14755   $as_echo "$as_me: failed program was:" >&5
14756 sed 's/^/| /' conftest.$ac_ext >&5
14757
14758
14759 fi
14760
14761 rm -rf conftest.dSYM
14762 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14763       conftest$ac_exeext conftest.$ac_ext
14764     ac_c_werror_flag=$pgac_c_inline_save_werror
14765   fi
14766 fi
14767 { $as_echo "$as_me:$LINENO: result: $pgac_cv_c_inline_quietly" >&5
14768 $as_echo "$pgac_cv_c_inline_quietly" >&6; }
14769 if test "$pgac_cv_c_inline_quietly" != no; then
14770
14771 cat >>confdefs.h <<_ACEOF
14772 #define USE_INLINE 1
14773 _ACEOF
14774
14775 fi
14776
14777 { $as_echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
14778 $as_echo_n "checking for preprocessor stringizing operator... " >&6; }
14779 if test "${ac_cv_c_stringize+set}" = set; then
14780   $as_echo_n "(cached) " >&6
14781 else
14782   cat >conftest.$ac_ext <<_ACEOF
14783 /* confdefs.h.  */
14784 _ACEOF
14785 cat confdefs.h >>conftest.$ac_ext
14786 cat >>conftest.$ac_ext <<_ACEOF
14787 /* end confdefs.h.  */
14788 #define x(y) #y
14789
14790 char *s = x(teststring);
14791 _ACEOF
14792 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14793   $EGREP "#teststring" >/dev/null 2>&1; then
14794   ac_cv_c_stringize=no
14795 else
14796   ac_cv_c_stringize=yes
14797 fi
14798 rm -f conftest*
14799
14800 fi
14801 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
14802 $as_echo "$ac_cv_c_stringize" >&6; }
14803 if test $ac_cv_c_stringize = yes; then
14804
14805 cat >>confdefs.h <<\_ACEOF
14806 #define HAVE_STRINGIZE 1
14807 _ACEOF
14808
14809 fi
14810
14811 { $as_echo "$as_me:$LINENO: checking for signed types" >&5
14812 $as_echo_n "checking for signed types... " >&6; }
14813 if test "${pgac_cv_c_signed+set}" = set; then
14814   $as_echo_n "(cached) " >&6
14815 else
14816   cat >conftest.$ac_ext <<_ACEOF
14817 /* confdefs.h.  */
14818 _ACEOF
14819 cat confdefs.h >>conftest.$ac_ext
14820 cat >>conftest.$ac_ext <<_ACEOF
14821 /* end confdefs.h.  */
14822
14823 int
14824 main ()
14825 {
14826 signed char c; signed short s; signed int i;
14827   ;
14828   return 0;
14829 }
14830 _ACEOF
14831 rm -f conftest.$ac_objext
14832 if { (ac_try="$ac_compile"
14833 case "(($ac_try" in
14834   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14835   *) ac_try_echo=$ac_try;;
14836 esac
14837 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14838 $as_echo "$ac_try_echo") >&5
14839   (eval "$ac_compile") 2>conftest.er1
14840   ac_status=$?
14841   grep -v '^ *+' conftest.er1 >conftest.err
14842   rm -f conftest.er1
14843   cat conftest.err >&5
14844   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14845   (exit $ac_status); } && {
14846          test -z "$ac_c_werror_flag" ||
14847          test ! -s conftest.err
14848        } && test -s conftest.$ac_objext; then
14849   pgac_cv_c_signed=yes
14850 else
14851   $as_echo "$as_me: failed program was:" >&5
14852 sed 's/^/| /' conftest.$ac_ext >&5
14853
14854         pgac_cv_c_signed=no
14855 fi
14856
14857 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14858 fi
14859 { $as_echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
14860 $as_echo "$pgac_cv_c_signed" >&6; }
14861 if test x"$pgac_cv_c_signed" = xno ; then
14862
14863 cat >>confdefs.h <<\_ACEOF
14864 #define signed /**/
14865 _ACEOF
14866
14867 fi
14868 { $as_echo "$as_me:$LINENO: checking for working volatile" >&5
14869 $as_echo_n "checking for working volatile... " >&6; }
14870 if test "${ac_cv_c_volatile+set}" = set; then
14871   $as_echo_n "(cached) " >&6
14872 else
14873   cat >conftest.$ac_ext <<_ACEOF
14874 /* confdefs.h.  */
14875 _ACEOF
14876 cat confdefs.h >>conftest.$ac_ext
14877 cat >>conftest.$ac_ext <<_ACEOF
14878 /* end confdefs.h.  */
14879
14880 int
14881 main ()
14882 {
14883
14884 volatile int x;
14885 int * volatile y = (int *) 0;
14886 return !x && !y;
14887   ;
14888   return 0;
14889 }
14890 _ACEOF
14891 rm -f conftest.$ac_objext
14892 if { (ac_try="$ac_compile"
14893 case "(($ac_try" in
14894   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14895   *) ac_try_echo=$ac_try;;
14896 esac
14897 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14898 $as_echo "$ac_try_echo") >&5
14899   (eval "$ac_compile") 2>conftest.er1
14900   ac_status=$?
14901   grep -v '^ *+' conftest.er1 >conftest.err
14902   rm -f conftest.er1
14903   cat conftest.err >&5
14904   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14905   (exit $ac_status); } && {
14906          test -z "$ac_c_werror_flag" ||
14907          test ! -s conftest.err
14908        } && test -s conftest.$ac_objext; then
14909   ac_cv_c_volatile=yes
14910 else
14911   $as_echo "$as_me: failed program was:" >&5
14912 sed 's/^/| /' conftest.$ac_ext >&5
14913
14914         ac_cv_c_volatile=no
14915 fi
14916
14917 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14918 fi
14919 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
14920 $as_echo "$ac_cv_c_volatile" >&6; }
14921 if test $ac_cv_c_volatile = no; then
14922
14923 cat >>confdefs.h <<\_ACEOF
14924 #define volatile /**/
14925 _ACEOF
14926
14927 fi
14928
14929 { $as_echo "$as_me:$LINENO: checking for __func__" >&5
14930 $as_echo_n "checking for __func__... " >&6; }
14931 if test "${pgac_cv_funcname_func_support+set}" = set; then
14932   $as_echo_n "(cached) " >&6
14933 else
14934   cat >conftest.$ac_ext <<_ACEOF
14935 /* confdefs.h.  */
14936 _ACEOF
14937 cat confdefs.h >>conftest.$ac_ext
14938 cat >>conftest.$ac_ext <<_ACEOF
14939 /* end confdefs.h.  */
14940 #include <stdio.h>
14941 int
14942 main ()
14943 {
14944 printf("%s\n", __func__);
14945   ;
14946   return 0;
14947 }
14948 _ACEOF
14949 rm -f conftest.$ac_objext
14950 if { (ac_try="$ac_compile"
14951 case "(($ac_try" in
14952   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14953   *) ac_try_echo=$ac_try;;
14954 esac
14955 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14956 $as_echo "$ac_try_echo") >&5
14957   (eval "$ac_compile") 2>conftest.er1
14958   ac_status=$?
14959   grep -v '^ *+' conftest.er1 >conftest.err
14960   rm -f conftest.er1
14961   cat conftest.err >&5
14962   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14963   (exit $ac_status); } && {
14964          test -z "$ac_c_werror_flag" ||
14965          test ! -s conftest.err
14966        } && test -s conftest.$ac_objext; then
14967   pgac_cv_funcname_func_support=yes
14968 else
14969   $as_echo "$as_me: failed program was:" >&5
14970 sed 's/^/| /' conftest.$ac_ext >&5
14971
14972         pgac_cv_funcname_func_support=no
14973 fi
14974
14975 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14976 fi
14977 { $as_echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
14978 $as_echo "$pgac_cv_funcname_func_support" >&6; }
14979 if test x"$pgac_cv_funcname_func_support" = xyes ; then
14980
14981 cat >>confdefs.h <<\_ACEOF
14982 #define HAVE_FUNCNAME__FUNC 1
14983 _ACEOF
14984
14985 else
14986 { $as_echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
14987 $as_echo_n "checking for __FUNCTION__... " >&6; }
14988 if test "${pgac_cv_funcname_function_support+set}" = set; then
14989   $as_echo_n "(cached) " >&6
14990 else
14991   cat >conftest.$ac_ext <<_ACEOF
14992 /* confdefs.h.  */
14993 _ACEOF
14994 cat confdefs.h >>conftest.$ac_ext
14995 cat >>conftest.$ac_ext <<_ACEOF
14996 /* end confdefs.h.  */
14997 #include <stdio.h>
14998 int
14999 main ()
15000 {
15001 printf("%s\n", __FUNCTION__);
15002   ;
15003   return 0;
15004 }
15005 _ACEOF
15006 rm -f conftest.$ac_objext
15007 if { (ac_try="$ac_compile"
15008 case "(($ac_try" in
15009   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15010   *) ac_try_echo=$ac_try;;
15011 esac
15012 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15013 $as_echo "$ac_try_echo") >&5
15014   (eval "$ac_compile") 2>conftest.er1
15015   ac_status=$?
15016   grep -v '^ *+' conftest.er1 >conftest.err
15017   rm -f conftest.er1
15018   cat conftest.err >&5
15019   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15020   (exit $ac_status); } && {
15021          test -z "$ac_c_werror_flag" ||
15022          test ! -s conftest.err
15023        } && test -s conftest.$ac_objext; then
15024   pgac_cv_funcname_function_support=yes
15025 else
15026   $as_echo "$as_me: failed program was:" >&5
15027 sed 's/^/| /' conftest.$ac_ext >&5
15028
15029         pgac_cv_funcname_function_support=no
15030 fi
15031
15032 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15033 fi
15034 { $as_echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
15035 $as_echo "$pgac_cv_funcname_function_support" >&6; }
15036 if test x"$pgac_cv_funcname_function_support" = xyes ; then
15037
15038 cat >>confdefs.h <<\_ACEOF
15039 #define HAVE_FUNCNAME__FUNCTION 1
15040 _ACEOF
15041
15042 fi
15043 fi
15044 { $as_echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
15045 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
15046 if test "${ac_cv_struct_tm+set}" = set; then
15047   $as_echo_n "(cached) " >&6
15048 else
15049   cat >conftest.$ac_ext <<_ACEOF
15050 /* confdefs.h.  */
15051 _ACEOF
15052 cat confdefs.h >>conftest.$ac_ext
15053 cat >>conftest.$ac_ext <<_ACEOF
15054 /* end confdefs.h.  */
15055 #include <sys/types.h>
15056 #include <time.h>
15057
15058 int
15059 main ()
15060 {
15061 struct tm tm;
15062                                      int *p = &tm.tm_sec;
15063                                      return !p;
15064   ;
15065   return 0;
15066 }
15067 _ACEOF
15068 rm -f conftest.$ac_objext
15069 if { (ac_try="$ac_compile"
15070 case "(($ac_try" in
15071   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15072   *) ac_try_echo=$ac_try;;
15073 esac
15074 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15075 $as_echo "$ac_try_echo") >&5
15076   (eval "$ac_compile") 2>conftest.er1
15077   ac_status=$?
15078   grep -v '^ *+' conftest.er1 >conftest.err
15079   rm -f conftest.er1
15080   cat conftest.err >&5
15081   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15082   (exit $ac_status); } && {
15083          test -z "$ac_c_werror_flag" ||
15084          test ! -s conftest.err
15085        } && test -s conftest.$ac_objext; then
15086   ac_cv_struct_tm=time.h
15087 else
15088   $as_echo "$as_me: failed program was:" >&5
15089 sed 's/^/| /' conftest.$ac_ext >&5
15090
15091         ac_cv_struct_tm=sys/time.h
15092 fi
15093
15094 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15095 fi
15096 { $as_echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
15097 $as_echo "$ac_cv_struct_tm" >&6; }
15098 if test $ac_cv_struct_tm = sys/time.h; then
15099
15100 cat >>confdefs.h <<\_ACEOF
15101 #define TM_IN_SYS_TIME 1
15102 _ACEOF
15103
15104 fi
15105
15106 { $as_echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
15107 $as_echo_n "checking for struct tm.tm_zone... " >&6; }
15108 if test "${ac_cv_member_struct_tm_tm_zone+set}" = set; then
15109   $as_echo_n "(cached) " >&6
15110 else
15111   cat >conftest.$ac_ext <<_ACEOF
15112 /* confdefs.h.  */
15113 _ACEOF
15114 cat confdefs.h >>conftest.$ac_ext
15115 cat >>conftest.$ac_ext <<_ACEOF
15116 /* end confdefs.h.  */
15117 #include <sys/types.h>
15118 #include <$ac_cv_struct_tm>
15119
15120
15121 int
15122 main ()
15123 {
15124 static struct tm ac_aggr;
15125 if (ac_aggr.tm_zone)
15126 return 0;
15127   ;
15128   return 0;
15129 }
15130 _ACEOF
15131 rm -f conftest.$ac_objext
15132 if { (ac_try="$ac_compile"
15133 case "(($ac_try" in
15134   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15135   *) ac_try_echo=$ac_try;;
15136 esac
15137 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15138 $as_echo "$ac_try_echo") >&5
15139   (eval "$ac_compile") 2>conftest.er1
15140   ac_status=$?
15141   grep -v '^ *+' conftest.er1 >conftest.err
15142   rm -f conftest.er1
15143   cat conftest.err >&5
15144   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15145   (exit $ac_status); } && {
15146          test -z "$ac_c_werror_flag" ||
15147          test ! -s conftest.err
15148        } && test -s conftest.$ac_objext; then
15149   ac_cv_member_struct_tm_tm_zone=yes
15150 else
15151   $as_echo "$as_me: failed program was:" >&5
15152 sed 's/^/| /' conftest.$ac_ext >&5
15153
15154         cat >conftest.$ac_ext <<_ACEOF
15155 /* confdefs.h.  */
15156 _ACEOF
15157 cat confdefs.h >>conftest.$ac_ext
15158 cat >>conftest.$ac_ext <<_ACEOF
15159 /* end confdefs.h.  */
15160 #include <sys/types.h>
15161 #include <$ac_cv_struct_tm>
15162
15163
15164 int
15165 main ()
15166 {
15167 static struct tm ac_aggr;
15168 if (sizeof ac_aggr.tm_zone)
15169 return 0;
15170   ;
15171   return 0;
15172 }
15173 _ACEOF
15174 rm -f conftest.$ac_objext
15175 if { (ac_try="$ac_compile"
15176 case "(($ac_try" in
15177   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15178   *) ac_try_echo=$ac_try;;
15179 esac
15180 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15181 $as_echo "$ac_try_echo") >&5
15182   (eval "$ac_compile") 2>conftest.er1
15183   ac_status=$?
15184   grep -v '^ *+' conftest.er1 >conftest.err
15185   rm -f conftest.er1
15186   cat conftest.err >&5
15187   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15188   (exit $ac_status); } && {
15189          test -z "$ac_c_werror_flag" ||
15190          test ! -s conftest.err
15191        } && test -s conftest.$ac_objext; then
15192   ac_cv_member_struct_tm_tm_zone=yes
15193 else
15194   $as_echo "$as_me: failed program was:" >&5
15195 sed 's/^/| /' conftest.$ac_ext >&5
15196
15197         ac_cv_member_struct_tm_tm_zone=no
15198 fi
15199
15200 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15201 fi
15202
15203 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15204 fi
15205 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
15206 $as_echo "$ac_cv_member_struct_tm_tm_zone" >&6; }
15207 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then
15208
15209 cat >>confdefs.h <<_ACEOF
15210 #define HAVE_STRUCT_TM_TM_ZONE 1
15211 _ACEOF
15212
15213
15214 fi
15215
15216 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
15217
15218 cat >>confdefs.h <<\_ACEOF
15219 #define HAVE_TM_ZONE 1
15220 _ACEOF
15221
15222 fi
15223 { $as_echo "$as_me:$LINENO: checking for tzname" >&5
15224 $as_echo_n "checking for tzname... " >&6; }
15225 if test "${ac_cv_var_tzname+set}" = set; then
15226   $as_echo_n "(cached) " >&6
15227 else
15228   cat >conftest.$ac_ext <<_ACEOF
15229 /* confdefs.h.  */
15230 _ACEOF
15231 cat confdefs.h >>conftest.$ac_ext
15232 cat >>conftest.$ac_ext <<_ACEOF
15233 /* end confdefs.h.  */
15234 #include <time.h>
15235 #ifndef tzname /* For SGI.  */
15236 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
15237 #endif
15238
15239 int
15240 main ()
15241 {
15242 atoi(*tzname);
15243   ;
15244   return 0;
15245 }
15246 _ACEOF
15247 rm -f conftest.$ac_objext conftest$ac_exeext
15248 if { (ac_try="$ac_link"
15249 case "(($ac_try" in
15250   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15251   *) ac_try_echo=$ac_try;;
15252 esac
15253 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15254 $as_echo "$ac_try_echo") >&5
15255   (eval "$ac_link") 2>conftest.er1
15256   ac_status=$?
15257   grep -v '^ *+' conftest.er1 >conftest.err
15258   rm -f conftest.er1
15259   cat conftest.err >&5
15260   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15261   (exit $ac_status); } && {
15262          test -z "$ac_c_werror_flag" ||
15263          test ! -s conftest.err
15264        } && test -s conftest$ac_exeext && {
15265          test "$cross_compiling" = yes ||
15266          $as_test_x conftest$ac_exeext
15267        }; then
15268   ac_cv_var_tzname=yes
15269 else
15270   $as_echo "$as_me: failed program was:" >&5
15271 sed 's/^/| /' conftest.$ac_ext >&5
15272
15273         ac_cv_var_tzname=no
15274 fi
15275
15276 rm -rf conftest.dSYM
15277 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15278       conftest$ac_exeext conftest.$ac_ext
15279 fi
15280 { $as_echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
15281 $as_echo "$ac_cv_var_tzname" >&6; }
15282 if test $ac_cv_var_tzname = yes; then
15283
15284 cat >>confdefs.h <<\_ACEOF
15285 #define HAVE_TZNAME 1
15286 _ACEOF
15287
15288 fi
15289
15290 { $as_echo "$as_me:$LINENO: checking for union semun" >&5
15291 $as_echo_n "checking for union semun... " >&6; }
15292 if test "${ac_cv_type_union_semun+set}" = set; then
15293   $as_echo_n "(cached) " >&6
15294 else
15295   ac_cv_type_union_semun=no
15296 cat >conftest.$ac_ext <<_ACEOF
15297 /* confdefs.h.  */
15298 _ACEOF
15299 cat confdefs.h >>conftest.$ac_ext
15300 cat >>conftest.$ac_ext <<_ACEOF
15301 /* end confdefs.h.  */
15302 #include <sys/types.h>
15303 #include <sys/ipc.h>
15304 #include <sys/sem.h>
15305
15306 int
15307 main ()
15308 {
15309 if (sizeof (union semun))
15310        return 0;
15311   ;
15312   return 0;
15313 }
15314 _ACEOF
15315 rm -f conftest.$ac_objext
15316 if { (ac_try="$ac_compile"
15317 case "(($ac_try" in
15318   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15319   *) ac_try_echo=$ac_try;;
15320 esac
15321 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15322 $as_echo "$ac_try_echo") >&5
15323   (eval "$ac_compile") 2>conftest.er1
15324   ac_status=$?
15325   grep -v '^ *+' conftest.er1 >conftest.err
15326   rm -f conftest.er1
15327   cat conftest.err >&5
15328   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15329   (exit $ac_status); } && {
15330          test -z "$ac_c_werror_flag" ||
15331          test ! -s conftest.err
15332        } && test -s conftest.$ac_objext; then
15333   cat >conftest.$ac_ext <<_ACEOF
15334 /* confdefs.h.  */
15335 _ACEOF
15336 cat confdefs.h >>conftest.$ac_ext
15337 cat >>conftest.$ac_ext <<_ACEOF
15338 /* end confdefs.h.  */
15339 #include <sys/types.h>
15340 #include <sys/ipc.h>
15341 #include <sys/sem.h>
15342
15343 int
15344 main ()
15345 {
15346 if (sizeof ((union semun)))
15347           return 0;
15348   ;
15349   return 0;
15350 }
15351 _ACEOF
15352 rm -f conftest.$ac_objext
15353 if { (ac_try="$ac_compile"
15354 case "(($ac_try" in
15355   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15356   *) ac_try_echo=$ac_try;;
15357 esac
15358 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15359 $as_echo "$ac_try_echo") >&5
15360   (eval "$ac_compile") 2>conftest.er1
15361   ac_status=$?
15362   grep -v '^ *+' conftest.er1 >conftest.err
15363   rm -f conftest.er1
15364   cat conftest.err >&5
15365   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15366   (exit $ac_status); } && {
15367          test -z "$ac_c_werror_flag" ||
15368          test ! -s conftest.err
15369        } && test -s conftest.$ac_objext; then
15370   :
15371 else
15372   $as_echo "$as_me: failed program was:" >&5
15373 sed 's/^/| /' conftest.$ac_ext >&5
15374
15375         ac_cv_type_union_semun=yes
15376 fi
15377
15378 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15379 else
15380   $as_echo "$as_me: failed program was:" >&5
15381 sed 's/^/| /' conftest.$ac_ext >&5
15382
15383
15384 fi
15385
15386 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15387 fi
15388 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
15389 $as_echo "$ac_cv_type_union_semun" >&6; }
15390 if test "x$ac_cv_type_union_semun" = x""yes; then
15391
15392 cat >>confdefs.h <<_ACEOF
15393 #define HAVE_UNION_SEMUN 1
15394 _ACEOF
15395
15396
15397 fi
15398
15399 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
15400 $as_echo_n "checking for struct sockaddr_un... " >&6; }
15401 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
15402   $as_echo_n "(cached) " >&6
15403 else
15404   ac_cv_type_struct_sockaddr_un=no
15405 cat >conftest.$ac_ext <<_ACEOF
15406 /* confdefs.h.  */
15407 _ACEOF
15408 cat confdefs.h >>conftest.$ac_ext
15409 cat >>conftest.$ac_ext <<_ACEOF
15410 /* end confdefs.h.  */
15411 #include <sys/types.h>
15412 #ifdef HAVE_SYS_UN_H
15413 #include <sys/un.h>
15414 #endif
15415
15416
15417 int
15418 main ()
15419 {
15420 if (sizeof (struct sockaddr_un))
15421        return 0;
15422   ;
15423   return 0;
15424 }
15425 _ACEOF
15426 rm -f conftest.$ac_objext
15427 if { (ac_try="$ac_compile"
15428 case "(($ac_try" in
15429   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15430   *) ac_try_echo=$ac_try;;
15431 esac
15432 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15433 $as_echo "$ac_try_echo") >&5
15434   (eval "$ac_compile") 2>conftest.er1
15435   ac_status=$?
15436   grep -v '^ *+' conftest.er1 >conftest.err
15437   rm -f conftest.er1
15438   cat conftest.err >&5
15439   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15440   (exit $ac_status); } && {
15441          test -z "$ac_c_werror_flag" ||
15442          test ! -s conftest.err
15443        } && test -s conftest.$ac_objext; then
15444   cat >conftest.$ac_ext <<_ACEOF
15445 /* confdefs.h.  */
15446 _ACEOF
15447 cat confdefs.h >>conftest.$ac_ext
15448 cat >>conftest.$ac_ext <<_ACEOF
15449 /* end confdefs.h.  */
15450 #include <sys/types.h>
15451 #ifdef HAVE_SYS_UN_H
15452 #include <sys/un.h>
15453 #endif
15454
15455
15456 int
15457 main ()
15458 {
15459 if (sizeof ((struct sockaddr_un)))
15460           return 0;
15461   ;
15462   return 0;
15463 }
15464 _ACEOF
15465 rm -f conftest.$ac_objext
15466 if { (ac_try="$ac_compile"
15467 case "(($ac_try" in
15468   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15469   *) ac_try_echo=$ac_try;;
15470 esac
15471 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15472 $as_echo "$ac_try_echo") >&5
15473   (eval "$ac_compile") 2>conftest.er1
15474   ac_status=$?
15475   grep -v '^ *+' conftest.er1 >conftest.err
15476   rm -f conftest.er1
15477   cat conftest.err >&5
15478   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15479   (exit $ac_status); } && {
15480          test -z "$ac_c_werror_flag" ||
15481          test ! -s conftest.err
15482        } && test -s conftest.$ac_objext; then
15483   :
15484 else
15485   $as_echo "$as_me: failed program was:" >&5
15486 sed 's/^/| /' conftest.$ac_ext >&5
15487
15488         ac_cv_type_struct_sockaddr_un=yes
15489 fi
15490
15491 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15492 else
15493   $as_echo "$as_me: failed program was:" >&5
15494 sed 's/^/| /' conftest.$ac_ext >&5
15495
15496
15497 fi
15498
15499 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15500 fi
15501 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
15502 $as_echo "$ac_cv_type_struct_sockaddr_un" >&6; }
15503 if test "x$ac_cv_type_struct_sockaddr_un" = x""yes; then
15504
15505 cat >>confdefs.h <<_ACEOF
15506 #define HAVE_STRUCT_SOCKADDR_UN 1
15507 _ACEOF
15508
15509
15510 cat >>confdefs.h <<\_ACEOF
15511 #define HAVE_UNIX_SOCKETS 1
15512 _ACEOF
15513
15514 fi
15515
15516 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
15517 $as_echo_n "checking for struct sockaddr_storage... " >&6; }
15518 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
15519   $as_echo_n "(cached) " >&6
15520 else
15521   ac_cv_type_struct_sockaddr_storage=no
15522 cat >conftest.$ac_ext <<_ACEOF
15523 /* confdefs.h.  */
15524 _ACEOF
15525 cat confdefs.h >>conftest.$ac_ext
15526 cat >>conftest.$ac_ext <<_ACEOF
15527 /* end confdefs.h.  */
15528 #include <sys/types.h>
15529 #ifdef HAVE_SYS_SOCKET_H
15530 #include <sys/socket.h>
15531 #endif
15532
15533
15534 int
15535 main ()
15536 {
15537 if (sizeof (struct sockaddr_storage))
15538        return 0;
15539   ;
15540   return 0;
15541 }
15542 _ACEOF
15543 rm -f conftest.$ac_objext
15544 if { (ac_try="$ac_compile"
15545 case "(($ac_try" in
15546   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15547   *) ac_try_echo=$ac_try;;
15548 esac
15549 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15550 $as_echo "$ac_try_echo") >&5
15551   (eval "$ac_compile") 2>conftest.er1
15552   ac_status=$?
15553   grep -v '^ *+' conftest.er1 >conftest.err
15554   rm -f conftest.er1
15555   cat conftest.err >&5
15556   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15557   (exit $ac_status); } && {
15558          test -z "$ac_c_werror_flag" ||
15559          test ! -s conftest.err
15560        } && test -s conftest.$ac_objext; then
15561   cat >conftest.$ac_ext <<_ACEOF
15562 /* confdefs.h.  */
15563 _ACEOF
15564 cat confdefs.h >>conftest.$ac_ext
15565 cat >>conftest.$ac_ext <<_ACEOF
15566 /* end confdefs.h.  */
15567 #include <sys/types.h>
15568 #ifdef HAVE_SYS_SOCKET_H
15569 #include <sys/socket.h>
15570 #endif
15571
15572
15573 int
15574 main ()
15575 {
15576 if (sizeof ((struct sockaddr_storage)))
15577           return 0;
15578   ;
15579   return 0;
15580 }
15581 _ACEOF
15582 rm -f conftest.$ac_objext
15583 if { (ac_try="$ac_compile"
15584 case "(($ac_try" in
15585   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15586   *) ac_try_echo=$ac_try;;
15587 esac
15588 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15589 $as_echo "$ac_try_echo") >&5
15590   (eval "$ac_compile") 2>conftest.er1
15591   ac_status=$?
15592   grep -v '^ *+' conftest.er1 >conftest.err
15593   rm -f conftest.er1
15594   cat conftest.err >&5
15595   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15596   (exit $ac_status); } && {
15597          test -z "$ac_c_werror_flag" ||
15598          test ! -s conftest.err
15599        } && test -s conftest.$ac_objext; then
15600   :
15601 else
15602   $as_echo "$as_me: failed program was:" >&5
15603 sed 's/^/| /' conftest.$ac_ext >&5
15604
15605         ac_cv_type_struct_sockaddr_storage=yes
15606 fi
15607
15608 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15609 else
15610   $as_echo "$as_me: failed program was:" >&5
15611 sed 's/^/| /' conftest.$ac_ext >&5
15612
15613
15614 fi
15615
15616 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15617 fi
15618 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
15619 $as_echo "$ac_cv_type_struct_sockaddr_storage" >&6; }
15620 if test "x$ac_cv_type_struct_sockaddr_storage" = x""yes; then
15621
15622 cat >>confdefs.h <<_ACEOF
15623 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
15624 _ACEOF
15625
15626
15627 fi
15628
15629 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
15630 $as_echo_n "checking for struct sockaddr_storage.ss_family... " >&6; }
15631 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
15632   $as_echo_n "(cached) " >&6
15633 else
15634   cat >conftest.$ac_ext <<_ACEOF
15635 /* confdefs.h.  */
15636 _ACEOF
15637 cat confdefs.h >>conftest.$ac_ext
15638 cat >>conftest.$ac_ext <<_ACEOF
15639 /* end confdefs.h.  */
15640 #include <sys/types.h>
15641 #ifdef HAVE_SYS_SOCKET_H
15642 #include <sys/socket.h>
15643 #endif
15644
15645
15646 int
15647 main ()
15648 {
15649 static struct sockaddr_storage ac_aggr;
15650 if (ac_aggr.ss_family)
15651 return 0;
15652   ;
15653   return 0;
15654 }
15655 _ACEOF
15656 rm -f conftest.$ac_objext
15657 if { (ac_try="$ac_compile"
15658 case "(($ac_try" in
15659   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15660   *) ac_try_echo=$ac_try;;
15661 esac
15662 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15663 $as_echo "$ac_try_echo") >&5
15664   (eval "$ac_compile") 2>conftest.er1
15665   ac_status=$?
15666   grep -v '^ *+' conftest.er1 >conftest.err
15667   rm -f conftest.er1
15668   cat conftest.err >&5
15669   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15670   (exit $ac_status); } && {
15671          test -z "$ac_c_werror_flag" ||
15672          test ! -s conftest.err
15673        } && test -s conftest.$ac_objext; then
15674   ac_cv_member_struct_sockaddr_storage_ss_family=yes
15675 else
15676   $as_echo "$as_me: failed program was:" >&5
15677 sed 's/^/| /' conftest.$ac_ext >&5
15678
15679         cat >conftest.$ac_ext <<_ACEOF
15680 /* confdefs.h.  */
15681 _ACEOF
15682 cat confdefs.h >>conftest.$ac_ext
15683 cat >>conftest.$ac_ext <<_ACEOF
15684 /* end confdefs.h.  */
15685 #include <sys/types.h>
15686 #ifdef HAVE_SYS_SOCKET_H
15687 #include <sys/socket.h>
15688 #endif
15689
15690
15691 int
15692 main ()
15693 {
15694 static struct sockaddr_storage ac_aggr;
15695 if (sizeof ac_aggr.ss_family)
15696 return 0;
15697   ;
15698   return 0;
15699 }
15700 _ACEOF
15701 rm -f conftest.$ac_objext
15702 if { (ac_try="$ac_compile"
15703 case "(($ac_try" in
15704   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15705   *) ac_try_echo=$ac_try;;
15706 esac
15707 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15708 $as_echo "$ac_try_echo") >&5
15709   (eval "$ac_compile") 2>conftest.er1
15710   ac_status=$?
15711   grep -v '^ *+' conftest.er1 >conftest.err
15712   rm -f conftest.er1
15713   cat conftest.err >&5
15714   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15715   (exit $ac_status); } && {
15716          test -z "$ac_c_werror_flag" ||
15717          test ! -s conftest.err
15718        } && test -s conftest.$ac_objext; then
15719   ac_cv_member_struct_sockaddr_storage_ss_family=yes
15720 else
15721   $as_echo "$as_me: failed program was:" >&5
15722 sed 's/^/| /' conftest.$ac_ext >&5
15723
15724         ac_cv_member_struct_sockaddr_storage_ss_family=no
15725 fi
15726
15727 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15728 fi
15729
15730 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15731 fi
15732 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
15733 $as_echo "$ac_cv_member_struct_sockaddr_storage_ss_family" >&6; }
15734 if test "x$ac_cv_member_struct_sockaddr_storage_ss_family" = x""yes; then
15735
15736 cat >>confdefs.h <<_ACEOF
15737 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
15738 _ACEOF
15739
15740
15741 fi
15742 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
15743 $as_echo_n "checking for struct sockaddr_storage.__ss_family... " >&6; }
15744 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
15745   $as_echo_n "(cached) " >&6
15746 else
15747   cat >conftest.$ac_ext <<_ACEOF
15748 /* confdefs.h.  */
15749 _ACEOF
15750 cat confdefs.h >>conftest.$ac_ext
15751 cat >>conftest.$ac_ext <<_ACEOF
15752 /* end confdefs.h.  */
15753 #include <sys/types.h>
15754 #ifdef HAVE_SYS_SOCKET_H
15755 #include <sys/socket.h>
15756 #endif
15757
15758
15759 int
15760 main ()
15761 {
15762 static struct sockaddr_storage ac_aggr;
15763 if (ac_aggr.__ss_family)
15764 return 0;
15765   ;
15766   return 0;
15767 }
15768 _ACEOF
15769 rm -f conftest.$ac_objext
15770 if { (ac_try="$ac_compile"
15771 case "(($ac_try" in
15772   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15773   *) ac_try_echo=$ac_try;;
15774 esac
15775 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15776 $as_echo "$ac_try_echo") >&5
15777   (eval "$ac_compile") 2>conftest.er1
15778   ac_status=$?
15779   grep -v '^ *+' conftest.er1 >conftest.err
15780   rm -f conftest.er1
15781   cat conftest.err >&5
15782   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15783   (exit $ac_status); } && {
15784          test -z "$ac_c_werror_flag" ||
15785          test ! -s conftest.err
15786        } && test -s conftest.$ac_objext; then
15787   ac_cv_member_struct_sockaddr_storage___ss_family=yes
15788 else
15789   $as_echo "$as_me: failed program was:" >&5
15790 sed 's/^/| /' conftest.$ac_ext >&5
15791
15792         cat >conftest.$ac_ext <<_ACEOF
15793 /* confdefs.h.  */
15794 _ACEOF
15795 cat confdefs.h >>conftest.$ac_ext
15796 cat >>conftest.$ac_ext <<_ACEOF
15797 /* end confdefs.h.  */
15798 #include <sys/types.h>
15799 #ifdef HAVE_SYS_SOCKET_H
15800 #include <sys/socket.h>
15801 #endif
15802
15803
15804 int
15805 main ()
15806 {
15807 static struct sockaddr_storage ac_aggr;
15808 if (sizeof ac_aggr.__ss_family)
15809 return 0;
15810   ;
15811   return 0;
15812 }
15813 _ACEOF
15814 rm -f conftest.$ac_objext
15815 if { (ac_try="$ac_compile"
15816 case "(($ac_try" in
15817   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15818   *) ac_try_echo=$ac_try;;
15819 esac
15820 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15821 $as_echo "$ac_try_echo") >&5
15822   (eval "$ac_compile") 2>conftest.er1
15823   ac_status=$?
15824   grep -v '^ *+' conftest.er1 >conftest.err
15825   rm -f conftest.er1
15826   cat conftest.err >&5
15827   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15828   (exit $ac_status); } && {
15829          test -z "$ac_c_werror_flag" ||
15830          test ! -s conftest.err
15831        } && test -s conftest.$ac_objext; then
15832   ac_cv_member_struct_sockaddr_storage___ss_family=yes
15833 else
15834   $as_echo "$as_me: failed program was:" >&5
15835 sed 's/^/| /' conftest.$ac_ext >&5
15836
15837         ac_cv_member_struct_sockaddr_storage___ss_family=no
15838 fi
15839
15840 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15841 fi
15842
15843 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15844 fi
15845 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
15846 $as_echo "$ac_cv_member_struct_sockaddr_storage___ss_family" >&6; }
15847 if test "x$ac_cv_member_struct_sockaddr_storage___ss_family" = x""yes; then
15848
15849 cat >>confdefs.h <<_ACEOF
15850 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
15851 _ACEOF
15852
15853
15854 fi
15855 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
15856 $as_echo_n "checking for struct sockaddr_storage.ss_len... " >&6; }
15857 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
15858   $as_echo_n "(cached) " >&6
15859 else
15860   cat >conftest.$ac_ext <<_ACEOF
15861 /* confdefs.h.  */
15862 _ACEOF
15863 cat confdefs.h >>conftest.$ac_ext
15864 cat >>conftest.$ac_ext <<_ACEOF
15865 /* end confdefs.h.  */
15866 #include <sys/types.h>
15867 #ifdef HAVE_SYS_SOCKET_H
15868 #include <sys/socket.h>
15869 #endif
15870
15871
15872 int
15873 main ()
15874 {
15875 static struct sockaddr_storage ac_aggr;
15876 if (ac_aggr.ss_len)
15877 return 0;
15878   ;
15879   return 0;
15880 }
15881 _ACEOF
15882 rm -f conftest.$ac_objext
15883 if { (ac_try="$ac_compile"
15884 case "(($ac_try" in
15885   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15886   *) ac_try_echo=$ac_try;;
15887 esac
15888 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15889 $as_echo "$ac_try_echo") >&5
15890   (eval "$ac_compile") 2>conftest.er1
15891   ac_status=$?
15892   grep -v '^ *+' conftest.er1 >conftest.err
15893   rm -f conftest.er1
15894   cat conftest.err >&5
15895   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15896   (exit $ac_status); } && {
15897          test -z "$ac_c_werror_flag" ||
15898          test ! -s conftest.err
15899        } && test -s conftest.$ac_objext; then
15900   ac_cv_member_struct_sockaddr_storage_ss_len=yes
15901 else
15902   $as_echo "$as_me: failed program was:" >&5
15903 sed 's/^/| /' conftest.$ac_ext >&5
15904
15905         cat >conftest.$ac_ext <<_ACEOF
15906 /* confdefs.h.  */
15907 _ACEOF
15908 cat confdefs.h >>conftest.$ac_ext
15909 cat >>conftest.$ac_ext <<_ACEOF
15910 /* end confdefs.h.  */
15911 #include <sys/types.h>
15912 #ifdef HAVE_SYS_SOCKET_H
15913 #include <sys/socket.h>
15914 #endif
15915
15916
15917 int
15918 main ()
15919 {
15920 static struct sockaddr_storage ac_aggr;
15921 if (sizeof ac_aggr.ss_len)
15922 return 0;
15923   ;
15924   return 0;
15925 }
15926 _ACEOF
15927 rm -f conftest.$ac_objext
15928 if { (ac_try="$ac_compile"
15929 case "(($ac_try" in
15930   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15931   *) ac_try_echo=$ac_try;;
15932 esac
15933 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15934 $as_echo "$ac_try_echo") >&5
15935   (eval "$ac_compile") 2>conftest.er1
15936   ac_status=$?
15937   grep -v '^ *+' conftest.er1 >conftest.err
15938   rm -f conftest.er1
15939   cat conftest.err >&5
15940   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15941   (exit $ac_status); } && {
15942          test -z "$ac_c_werror_flag" ||
15943          test ! -s conftest.err
15944        } && test -s conftest.$ac_objext; then
15945   ac_cv_member_struct_sockaddr_storage_ss_len=yes
15946 else
15947   $as_echo "$as_me: failed program was:" >&5
15948 sed 's/^/| /' conftest.$ac_ext >&5
15949
15950         ac_cv_member_struct_sockaddr_storage_ss_len=no
15951 fi
15952
15953 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15954 fi
15955
15956 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15957 fi
15958 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
15959 $as_echo "$ac_cv_member_struct_sockaddr_storage_ss_len" >&6; }
15960 if test "x$ac_cv_member_struct_sockaddr_storage_ss_len" = x""yes; then
15961
15962 cat >>confdefs.h <<_ACEOF
15963 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
15964 _ACEOF
15965
15966
15967 fi
15968 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
15969 $as_echo_n "checking for struct sockaddr_storage.__ss_len... " >&6; }
15970 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
15971   $as_echo_n "(cached) " >&6
15972 else
15973   cat >conftest.$ac_ext <<_ACEOF
15974 /* confdefs.h.  */
15975 _ACEOF
15976 cat confdefs.h >>conftest.$ac_ext
15977 cat >>conftest.$ac_ext <<_ACEOF
15978 /* end confdefs.h.  */
15979 #include <sys/types.h>
15980 #ifdef HAVE_SYS_SOCKET_H
15981 #include <sys/socket.h>
15982 #endif
15983
15984
15985 int
15986 main ()
15987 {
15988 static struct sockaddr_storage ac_aggr;
15989 if (ac_aggr.__ss_len)
15990 return 0;
15991   ;
15992   return 0;
15993 }
15994 _ACEOF
15995 rm -f conftest.$ac_objext
15996 if { (ac_try="$ac_compile"
15997 case "(($ac_try" in
15998   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15999   *) ac_try_echo=$ac_try;;
16000 esac
16001 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16002 $as_echo "$ac_try_echo") >&5
16003   (eval "$ac_compile") 2>conftest.er1
16004   ac_status=$?
16005   grep -v '^ *+' conftest.er1 >conftest.err
16006   rm -f conftest.er1
16007   cat conftest.err >&5
16008   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16009   (exit $ac_status); } && {
16010          test -z "$ac_c_werror_flag" ||
16011          test ! -s conftest.err
16012        } && test -s conftest.$ac_objext; then
16013   ac_cv_member_struct_sockaddr_storage___ss_len=yes
16014 else
16015   $as_echo "$as_me: failed program was:" >&5
16016 sed 's/^/| /' conftest.$ac_ext >&5
16017
16018         cat >conftest.$ac_ext <<_ACEOF
16019 /* confdefs.h.  */
16020 _ACEOF
16021 cat confdefs.h >>conftest.$ac_ext
16022 cat >>conftest.$ac_ext <<_ACEOF
16023 /* end confdefs.h.  */
16024 #include <sys/types.h>
16025 #ifdef HAVE_SYS_SOCKET_H
16026 #include <sys/socket.h>
16027 #endif
16028
16029
16030 int
16031 main ()
16032 {
16033 static struct sockaddr_storage ac_aggr;
16034 if (sizeof ac_aggr.__ss_len)
16035 return 0;
16036   ;
16037   return 0;
16038 }
16039 _ACEOF
16040 rm -f conftest.$ac_objext
16041 if { (ac_try="$ac_compile"
16042 case "(($ac_try" in
16043   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16044   *) ac_try_echo=$ac_try;;
16045 esac
16046 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16047 $as_echo "$ac_try_echo") >&5
16048   (eval "$ac_compile") 2>conftest.er1
16049   ac_status=$?
16050   grep -v '^ *+' conftest.er1 >conftest.err
16051   rm -f conftest.er1
16052   cat conftest.err >&5
16053   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16054   (exit $ac_status); } && {
16055          test -z "$ac_c_werror_flag" ||
16056          test ! -s conftest.err
16057        } && test -s conftest.$ac_objext; then
16058   ac_cv_member_struct_sockaddr_storage___ss_len=yes
16059 else
16060   $as_echo "$as_me: failed program was:" >&5
16061 sed 's/^/| /' conftest.$ac_ext >&5
16062
16063         ac_cv_member_struct_sockaddr_storage___ss_len=no
16064 fi
16065
16066 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16067 fi
16068
16069 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16070 fi
16071 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
16072 $as_echo "$ac_cv_member_struct_sockaddr_storage___ss_len" >&6; }
16073 if test "x$ac_cv_member_struct_sockaddr_storage___ss_len" = x""yes; then
16074
16075 cat >>confdefs.h <<_ACEOF
16076 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
16077 _ACEOF
16078
16079
16080 fi
16081 { $as_echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
16082 $as_echo_n "checking for struct sockaddr.sa_len... " >&6; }
16083 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
16084   $as_echo_n "(cached) " >&6
16085 else
16086   cat >conftest.$ac_ext <<_ACEOF
16087 /* confdefs.h.  */
16088 _ACEOF
16089 cat confdefs.h >>conftest.$ac_ext
16090 cat >>conftest.$ac_ext <<_ACEOF
16091 /* end confdefs.h.  */
16092 #include <sys/types.h>
16093 #ifdef HAVE_SYS_SOCKET_H
16094 #include <sys/socket.h>
16095 #endif
16096
16097
16098 int
16099 main ()
16100 {
16101 static struct sockaddr ac_aggr;
16102 if (ac_aggr.sa_len)
16103 return 0;
16104   ;
16105   return 0;
16106 }
16107 _ACEOF
16108 rm -f conftest.$ac_objext
16109 if { (ac_try="$ac_compile"
16110 case "(($ac_try" in
16111   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16112   *) ac_try_echo=$ac_try;;
16113 esac
16114 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16115 $as_echo "$ac_try_echo") >&5
16116   (eval "$ac_compile") 2>conftest.er1
16117   ac_status=$?
16118   grep -v '^ *+' conftest.er1 >conftest.err
16119   rm -f conftest.er1
16120   cat conftest.err >&5
16121   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16122   (exit $ac_status); } && {
16123          test -z "$ac_c_werror_flag" ||
16124          test ! -s conftest.err
16125        } && test -s conftest.$ac_objext; then
16126   ac_cv_member_struct_sockaddr_sa_len=yes
16127 else
16128   $as_echo "$as_me: failed program was:" >&5
16129 sed 's/^/| /' conftest.$ac_ext >&5
16130
16131         cat >conftest.$ac_ext <<_ACEOF
16132 /* confdefs.h.  */
16133 _ACEOF
16134 cat confdefs.h >>conftest.$ac_ext
16135 cat >>conftest.$ac_ext <<_ACEOF
16136 /* end confdefs.h.  */
16137 #include <sys/types.h>
16138 #ifdef HAVE_SYS_SOCKET_H
16139 #include <sys/socket.h>
16140 #endif
16141
16142
16143 int
16144 main ()
16145 {
16146 static struct sockaddr ac_aggr;
16147 if (sizeof ac_aggr.sa_len)
16148 return 0;
16149   ;
16150   return 0;
16151 }
16152 _ACEOF
16153 rm -f conftest.$ac_objext
16154 if { (ac_try="$ac_compile"
16155 case "(($ac_try" in
16156   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16157   *) ac_try_echo=$ac_try;;
16158 esac
16159 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16160 $as_echo "$ac_try_echo") >&5
16161   (eval "$ac_compile") 2>conftest.er1
16162   ac_status=$?
16163   grep -v '^ *+' conftest.er1 >conftest.err
16164   rm -f conftest.er1
16165   cat conftest.err >&5
16166   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16167   (exit $ac_status); } && {
16168          test -z "$ac_c_werror_flag" ||
16169          test ! -s conftest.err
16170        } && test -s conftest.$ac_objext; then
16171   ac_cv_member_struct_sockaddr_sa_len=yes
16172 else
16173   $as_echo "$as_me: failed program was:" >&5
16174 sed 's/^/| /' conftest.$ac_ext >&5
16175
16176         ac_cv_member_struct_sockaddr_sa_len=no
16177 fi
16178
16179 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16180 fi
16181
16182 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16183 fi
16184 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
16185 $as_echo "$ac_cv_member_struct_sockaddr_sa_len" >&6; }
16186 if test "x$ac_cv_member_struct_sockaddr_sa_len" = x""yes; then
16187
16188 cat >>confdefs.h <<_ACEOF
16189 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
16190 _ACEOF
16191
16192
16193 fi
16194
16195 { $as_echo "$as_me:$LINENO: checking for struct addrinfo" >&5
16196 $as_echo_n "checking for struct addrinfo... " >&6; }
16197 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
16198   $as_echo_n "(cached) " >&6
16199 else
16200   ac_cv_type_struct_addrinfo=no
16201 cat >conftest.$ac_ext <<_ACEOF
16202 /* confdefs.h.  */
16203 _ACEOF
16204 cat confdefs.h >>conftest.$ac_ext
16205 cat >>conftest.$ac_ext <<_ACEOF
16206 /* end confdefs.h.  */
16207 #include <sys/types.h>
16208 #include <sys/socket.h>
16209 #include <netdb.h>
16210
16211
16212 int
16213 main ()
16214 {
16215 if (sizeof (struct addrinfo))
16216        return 0;
16217   ;
16218   return 0;
16219 }
16220 _ACEOF
16221 rm -f conftest.$ac_objext
16222 if { (ac_try="$ac_compile"
16223 case "(($ac_try" in
16224   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16225   *) ac_try_echo=$ac_try;;
16226 esac
16227 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16228 $as_echo "$ac_try_echo") >&5
16229   (eval "$ac_compile") 2>conftest.er1
16230   ac_status=$?
16231   grep -v '^ *+' conftest.er1 >conftest.err
16232   rm -f conftest.er1
16233   cat conftest.err >&5
16234   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16235   (exit $ac_status); } && {
16236          test -z "$ac_c_werror_flag" ||
16237          test ! -s conftest.err
16238        } && test -s conftest.$ac_objext; then
16239   cat >conftest.$ac_ext <<_ACEOF
16240 /* confdefs.h.  */
16241 _ACEOF
16242 cat confdefs.h >>conftest.$ac_ext
16243 cat >>conftest.$ac_ext <<_ACEOF
16244 /* end confdefs.h.  */
16245 #include <sys/types.h>
16246 #include <sys/socket.h>
16247 #include <netdb.h>
16248
16249
16250 int
16251 main ()
16252 {
16253 if (sizeof ((struct addrinfo)))
16254           return 0;
16255   ;
16256   return 0;
16257 }
16258 _ACEOF
16259 rm -f conftest.$ac_objext
16260 if { (ac_try="$ac_compile"
16261 case "(($ac_try" in
16262   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16263   *) ac_try_echo=$ac_try;;
16264 esac
16265 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16266 $as_echo "$ac_try_echo") >&5
16267   (eval "$ac_compile") 2>conftest.er1
16268   ac_status=$?
16269   grep -v '^ *+' conftest.er1 >conftest.err
16270   rm -f conftest.er1
16271   cat conftest.err >&5
16272   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16273   (exit $ac_status); } && {
16274          test -z "$ac_c_werror_flag" ||
16275          test ! -s conftest.err
16276        } && test -s conftest.$ac_objext; then
16277   :
16278 else
16279   $as_echo "$as_me: failed program was:" >&5
16280 sed 's/^/| /' conftest.$ac_ext >&5
16281
16282         ac_cv_type_struct_addrinfo=yes
16283 fi
16284
16285 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16286 else
16287   $as_echo "$as_me: failed program was:" >&5
16288 sed 's/^/| /' conftest.$ac_ext >&5
16289
16290
16291 fi
16292
16293 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16294 fi
16295 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
16296 $as_echo "$ac_cv_type_struct_addrinfo" >&6; }
16297 if test "x$ac_cv_type_struct_addrinfo" = x""yes; then
16298
16299 cat >>confdefs.h <<_ACEOF
16300 #define HAVE_STRUCT_ADDRINFO 1
16301 _ACEOF
16302
16303
16304 fi
16305
16306
16307   { $as_echo "$as_me:$LINENO: checking for intptr_t" >&5
16308 $as_echo_n "checking for intptr_t... " >&6; }
16309 if test "${ac_cv_type_intptr_t+set}" = set; then
16310   $as_echo_n "(cached) " >&6
16311 else
16312   ac_cv_type_intptr_t=no
16313 cat >conftest.$ac_ext <<_ACEOF
16314 /* confdefs.h.  */
16315 _ACEOF
16316 cat confdefs.h >>conftest.$ac_ext
16317 cat >>conftest.$ac_ext <<_ACEOF
16318 /* end confdefs.h.  */
16319 $ac_includes_default
16320 int
16321 main ()
16322 {
16323 if (sizeof (intptr_t))
16324        return 0;
16325   ;
16326   return 0;
16327 }
16328 _ACEOF
16329 rm -f conftest.$ac_objext
16330 if { (ac_try="$ac_compile"
16331 case "(($ac_try" in
16332   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16333   *) ac_try_echo=$ac_try;;
16334 esac
16335 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16336 $as_echo "$ac_try_echo") >&5
16337   (eval "$ac_compile") 2>conftest.er1
16338   ac_status=$?
16339   grep -v '^ *+' conftest.er1 >conftest.err
16340   rm -f conftest.er1
16341   cat conftest.err >&5
16342   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16343   (exit $ac_status); } && {
16344          test -z "$ac_c_werror_flag" ||
16345          test ! -s conftest.err
16346        } && test -s conftest.$ac_objext; then
16347   cat >conftest.$ac_ext <<_ACEOF
16348 /* confdefs.h.  */
16349 _ACEOF
16350 cat confdefs.h >>conftest.$ac_ext
16351 cat >>conftest.$ac_ext <<_ACEOF
16352 /* end confdefs.h.  */
16353 $ac_includes_default
16354 int
16355 main ()
16356 {
16357 if (sizeof ((intptr_t)))
16358           return 0;
16359   ;
16360   return 0;
16361 }
16362 _ACEOF
16363 rm -f conftest.$ac_objext
16364 if { (ac_try="$ac_compile"
16365 case "(($ac_try" in
16366   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16367   *) ac_try_echo=$ac_try;;
16368 esac
16369 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16370 $as_echo "$ac_try_echo") >&5
16371   (eval "$ac_compile") 2>conftest.er1
16372   ac_status=$?
16373   grep -v '^ *+' conftest.er1 >conftest.err
16374   rm -f conftest.er1
16375   cat conftest.err >&5
16376   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16377   (exit $ac_status); } && {
16378          test -z "$ac_c_werror_flag" ||
16379          test ! -s conftest.err
16380        } && test -s conftest.$ac_objext; then
16381   :
16382 else
16383   $as_echo "$as_me: failed program was:" >&5
16384 sed 's/^/| /' conftest.$ac_ext >&5
16385
16386         ac_cv_type_intptr_t=yes
16387 fi
16388
16389 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16390 else
16391   $as_echo "$as_me: failed program was:" >&5
16392 sed 's/^/| /' conftest.$ac_ext >&5
16393
16394
16395 fi
16396
16397 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16398 fi
16399 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_intptr_t" >&5
16400 $as_echo "$ac_cv_type_intptr_t" >&6; }
16401 if test "x$ac_cv_type_intptr_t" = x""yes; then
16402
16403 cat >>confdefs.h <<\_ACEOF
16404 #define HAVE_INTPTR_T 1
16405 _ACEOF
16406
16407 else
16408   for ac_type in 'int' 'long int' 'long long int'; do
16409        cat >conftest.$ac_ext <<_ACEOF
16410 /* confdefs.h.  */
16411 _ACEOF
16412 cat confdefs.h >>conftest.$ac_ext
16413 cat >>conftest.$ac_ext <<_ACEOF
16414 /* end confdefs.h.  */
16415 $ac_includes_default
16416 int
16417 main ()
16418 {
16419 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
16420 test_array [0] = 0
16421
16422   ;
16423   return 0;
16424 }
16425 _ACEOF
16426 rm -f conftest.$ac_objext
16427 if { (ac_try="$ac_compile"
16428 case "(($ac_try" in
16429   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16430   *) ac_try_echo=$ac_try;;
16431 esac
16432 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16433 $as_echo "$ac_try_echo") >&5
16434   (eval "$ac_compile") 2>conftest.er1
16435   ac_status=$?
16436   grep -v '^ *+' conftest.er1 >conftest.err
16437   rm -f conftest.er1
16438   cat conftest.err >&5
16439   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16440   (exit $ac_status); } && {
16441          test -z "$ac_c_werror_flag" ||
16442          test ! -s conftest.err
16443        } && test -s conftest.$ac_objext; then
16444
16445 cat >>confdefs.h <<_ACEOF
16446 #define intptr_t $ac_type
16447 _ACEOF
16448
16449           ac_type=
16450 else
16451   $as_echo "$as_me: failed program was:" >&5
16452 sed 's/^/| /' conftest.$ac_ext >&5
16453
16454
16455 fi
16456
16457 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16458        test -z "$ac_type" && break
16459      done
16460 fi
16461
16462
16463
16464   { $as_echo "$as_me:$LINENO: checking for uintptr_t" >&5
16465 $as_echo_n "checking for uintptr_t... " >&6; }
16466 if test "${ac_cv_type_uintptr_t+set}" = set; then
16467   $as_echo_n "(cached) " >&6
16468 else
16469   ac_cv_type_uintptr_t=no
16470 cat >conftest.$ac_ext <<_ACEOF
16471 /* confdefs.h.  */
16472 _ACEOF
16473 cat confdefs.h >>conftest.$ac_ext
16474 cat >>conftest.$ac_ext <<_ACEOF
16475 /* end confdefs.h.  */
16476 $ac_includes_default
16477 int
16478 main ()
16479 {
16480 if (sizeof (uintptr_t))
16481        return 0;
16482   ;
16483   return 0;
16484 }
16485 _ACEOF
16486 rm -f conftest.$ac_objext
16487 if { (ac_try="$ac_compile"
16488 case "(($ac_try" in
16489   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16490   *) ac_try_echo=$ac_try;;
16491 esac
16492 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16493 $as_echo "$ac_try_echo") >&5
16494   (eval "$ac_compile") 2>conftest.er1
16495   ac_status=$?
16496   grep -v '^ *+' conftest.er1 >conftest.err
16497   rm -f conftest.er1
16498   cat conftest.err >&5
16499   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16500   (exit $ac_status); } && {
16501          test -z "$ac_c_werror_flag" ||
16502          test ! -s conftest.err
16503        } && test -s conftest.$ac_objext; then
16504   cat >conftest.$ac_ext <<_ACEOF
16505 /* confdefs.h.  */
16506 _ACEOF
16507 cat confdefs.h >>conftest.$ac_ext
16508 cat >>conftest.$ac_ext <<_ACEOF
16509 /* end confdefs.h.  */
16510 $ac_includes_default
16511 int
16512 main ()
16513 {
16514 if (sizeof ((uintptr_t)))
16515           return 0;
16516   ;
16517   return 0;
16518 }
16519 _ACEOF
16520 rm -f conftest.$ac_objext
16521 if { (ac_try="$ac_compile"
16522 case "(($ac_try" in
16523   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16524   *) ac_try_echo=$ac_try;;
16525 esac
16526 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16527 $as_echo "$ac_try_echo") >&5
16528   (eval "$ac_compile") 2>conftest.er1
16529   ac_status=$?
16530   grep -v '^ *+' conftest.er1 >conftest.err
16531   rm -f conftest.er1
16532   cat conftest.err >&5
16533   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16534   (exit $ac_status); } && {
16535          test -z "$ac_c_werror_flag" ||
16536          test ! -s conftest.err
16537        } && test -s conftest.$ac_objext; then
16538   :
16539 else
16540   $as_echo "$as_me: failed program was:" >&5
16541 sed 's/^/| /' conftest.$ac_ext >&5
16542
16543         ac_cv_type_uintptr_t=yes
16544 fi
16545
16546 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16547 else
16548   $as_echo "$as_me: failed program was:" >&5
16549 sed 's/^/| /' conftest.$ac_ext >&5
16550
16551
16552 fi
16553
16554 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16555 fi
16556 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
16557 $as_echo "$ac_cv_type_uintptr_t" >&6; }
16558 if test "x$ac_cv_type_uintptr_t" = x""yes; then
16559
16560 cat >>confdefs.h <<\_ACEOF
16561 #define HAVE_UINTPTR_T 1
16562 _ACEOF
16563
16564 else
16565   for ac_type in 'unsigned int' 'unsigned long int' \
16566         'unsigned long long int'; do
16567        cat >conftest.$ac_ext <<_ACEOF
16568 /* confdefs.h.  */
16569 _ACEOF
16570 cat confdefs.h >>conftest.$ac_ext
16571 cat >>conftest.$ac_ext <<_ACEOF
16572 /* end confdefs.h.  */
16573 $ac_includes_default
16574 int
16575 main ()
16576 {
16577 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
16578 test_array [0] = 0
16579
16580   ;
16581   return 0;
16582 }
16583 _ACEOF
16584 rm -f conftest.$ac_objext
16585 if { (ac_try="$ac_compile"
16586 case "(($ac_try" in
16587   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16588   *) ac_try_echo=$ac_try;;
16589 esac
16590 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16591 $as_echo "$ac_try_echo") >&5
16592   (eval "$ac_compile") 2>conftest.er1
16593   ac_status=$?
16594   grep -v '^ *+' conftest.er1 >conftest.err
16595   rm -f conftest.er1
16596   cat conftest.err >&5
16597   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16598   (exit $ac_status); } && {
16599          test -z "$ac_c_werror_flag" ||
16600          test ! -s conftest.err
16601        } && test -s conftest.$ac_objext; then
16602
16603 cat >>confdefs.h <<_ACEOF
16604 #define uintptr_t $ac_type
16605 _ACEOF
16606
16607           ac_type=
16608 else
16609   $as_echo "$as_me: failed program was:" >&5
16610 sed 's/^/| /' conftest.$ac_ext >&5
16611
16612
16613 fi
16614
16615 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16616        test -z "$ac_type" && break
16617      done
16618 fi
16619
16620
16621
16622   { $as_echo "$as_me:$LINENO: checking for long long int" >&5
16623 $as_echo_n "checking for long long int... " >&6; }
16624 if test "${ac_cv_type_long_long_int+set}" = set; then
16625   $as_echo_n "(cached) " >&6
16626 else
16627   cat >conftest.$ac_ext <<_ACEOF
16628
16629   /* confdefs.h.  */
16630 _ACEOF
16631 cat confdefs.h >>conftest.$ac_ext
16632 cat >>conftest.$ac_ext <<_ACEOF
16633 /* end confdefs.h.  */
16634 /* For now, do not test the preprocessor; as of 2007 there are too many
16635          implementations with broken preprocessors.  Perhaps this can
16636          be revisited in 2012.  In the meantime, code should not expect
16637          #if to work with literals wider than 32 bits.  */
16638       /* Test literals.  */
16639       long long int ll = 9223372036854775807ll;
16640       long long int nll = -9223372036854775807LL;
16641       unsigned long long int ull = 18446744073709551615ULL;
16642       /* Test constant expressions.   */
16643       typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
16644                      ? 1 : -1)];
16645       typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
16646                      ? 1 : -1)];
16647       int i = 63;
16648 int
16649 main ()
16650 {
16651 /* Test availability of runtime routines for shift and division.  */
16652       long long int llmax = 9223372036854775807ll;
16653       unsigned long long int ullmax = 18446744073709551615ull;
16654       return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
16655               | (llmax / ll) | (llmax % ll)
16656               | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
16657               | (ullmax / ull) | (ullmax % ull));
16658   ;
16659   return 0;
16660 }
16661
16662 _ACEOF
16663 rm -f conftest.$ac_objext conftest$ac_exeext
16664 if { (ac_try="$ac_link"
16665 case "(($ac_try" in
16666   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16667   *) ac_try_echo=$ac_try;;
16668 esac
16669 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16670 $as_echo "$ac_try_echo") >&5
16671   (eval "$ac_link") 2>conftest.er1
16672   ac_status=$?
16673   grep -v '^ *+' conftest.er1 >conftest.err
16674   rm -f conftest.er1
16675   cat conftest.err >&5
16676   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16677   (exit $ac_status); } && {
16678          test -z "$ac_c_werror_flag" ||
16679          test ! -s conftest.err
16680        } && test -s conftest$ac_exeext && {
16681          test "$cross_compiling" = yes ||
16682          $as_test_x conftest$ac_exeext
16683        }; then
16684                         if test "$cross_compiling" = yes; then
16685   ac_cv_type_long_long_int=yes
16686 else
16687   cat >conftest.$ac_ext <<_ACEOF
16688 /* confdefs.h.  */
16689 _ACEOF
16690 cat confdefs.h >>conftest.$ac_ext
16691 cat >>conftest.$ac_ext <<_ACEOF
16692 /* end confdefs.h.  */
16693 #include <limits.h>
16694                #ifndef LLONG_MAX
16695                # define HALF \
16696                         (1LL << (sizeof (long long int) * CHAR_BIT - 2))
16697                # define LLONG_MAX (HALF - 1 + HALF)
16698                #endif
16699 int
16700 main ()
16701 {
16702 long long int n = 1;
16703                int i;
16704                for (i = 0; ; i++)
16705                  {
16706                    long long int m = n << i;
16707                    if (m >> i != n)
16708                      return 1;
16709                    if (LLONG_MAX / 2 < m)
16710                      break;
16711                  }
16712                return 0;
16713   ;
16714   return 0;
16715 }
16716 _ACEOF
16717 rm -f conftest$ac_exeext
16718 if { (ac_try="$ac_link"
16719 case "(($ac_try" in
16720   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16721   *) ac_try_echo=$ac_try;;
16722 esac
16723 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16724 $as_echo "$ac_try_echo") >&5
16725   (eval "$ac_link") 2>&5
16726   ac_status=$?
16727   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16728   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16729   { (case "(($ac_try" in
16730   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16731   *) ac_try_echo=$ac_try;;
16732 esac
16733 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16734 $as_echo "$ac_try_echo") >&5
16735   (eval "$ac_try") 2>&5
16736   ac_status=$?
16737   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16738   (exit $ac_status); }; }; then
16739   ac_cv_type_long_long_int=yes
16740 else
16741   $as_echo "$as_me: program exited with status $ac_status" >&5
16742 $as_echo "$as_me: failed program was:" >&5
16743 sed 's/^/| /' conftest.$ac_ext >&5
16744
16745 ( exit $ac_status )
16746 ac_cv_type_long_long_int=no
16747 fi
16748 rm -rf conftest.dSYM
16749 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16750 fi
16751
16752
16753 else
16754   $as_echo "$as_me: failed program was:" >&5
16755 sed 's/^/| /' conftest.$ac_ext >&5
16756
16757         ac_cv_type_long_long_int=no
16758 fi
16759
16760 rm -rf conftest.dSYM
16761 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16762       conftest$ac_exeext conftest.$ac_ext
16763 fi
16764 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
16765 $as_echo "$ac_cv_type_long_long_int" >&6; }
16766   if test $ac_cv_type_long_long_int = yes; then
16767
16768 cat >>confdefs.h <<\_ACEOF
16769 #define HAVE_LONG_LONG_INT 1
16770 _ACEOF
16771
16772   fi
16773
16774
16775 { $as_echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
16776 $as_echo_n "checking for struct cmsgcred... " >&6; }
16777 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
16778   $as_echo_n "(cached) " >&6
16779 else
16780   ac_cv_type_struct_cmsgcred=no
16781 cat >conftest.$ac_ext <<_ACEOF
16782 /* confdefs.h.  */
16783 _ACEOF
16784 cat confdefs.h >>conftest.$ac_ext
16785 cat >>conftest.$ac_ext <<_ACEOF
16786 /* end confdefs.h.  */
16787 #include <sys/param.h>
16788 #include <sys/types.h>
16789 #include <sys/socket.h>
16790 #include <sys/ucred.h>
16791
16792 int
16793 main ()
16794 {
16795 if (sizeof (struct cmsgcred))
16796        return 0;
16797   ;
16798   return 0;
16799 }
16800 _ACEOF
16801 rm -f conftest.$ac_objext
16802 if { (ac_try="$ac_compile"
16803 case "(($ac_try" in
16804   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16805   *) ac_try_echo=$ac_try;;
16806 esac
16807 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16808 $as_echo "$ac_try_echo") >&5
16809   (eval "$ac_compile") 2>conftest.er1
16810   ac_status=$?
16811   grep -v '^ *+' conftest.er1 >conftest.err
16812   rm -f conftest.er1
16813   cat conftest.err >&5
16814   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16815   (exit $ac_status); } && {
16816          test -z "$ac_c_werror_flag" ||
16817          test ! -s conftest.err
16818        } && test -s conftest.$ac_objext; then
16819   cat >conftest.$ac_ext <<_ACEOF
16820 /* confdefs.h.  */
16821 _ACEOF
16822 cat confdefs.h >>conftest.$ac_ext
16823 cat >>conftest.$ac_ext <<_ACEOF
16824 /* end confdefs.h.  */
16825 #include <sys/param.h>
16826 #include <sys/types.h>
16827 #include <sys/socket.h>
16828 #include <sys/ucred.h>
16829
16830 int
16831 main ()
16832 {
16833 if (sizeof ((struct cmsgcred)))
16834           return 0;
16835   ;
16836   return 0;
16837 }
16838 _ACEOF
16839 rm -f conftest.$ac_objext
16840 if { (ac_try="$ac_compile"
16841 case "(($ac_try" in
16842   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16843   *) ac_try_echo=$ac_try;;
16844 esac
16845 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16846 $as_echo "$ac_try_echo") >&5
16847   (eval "$ac_compile") 2>conftest.er1
16848   ac_status=$?
16849   grep -v '^ *+' conftest.er1 >conftest.err
16850   rm -f conftest.er1
16851   cat conftest.err >&5
16852   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16853   (exit $ac_status); } && {
16854          test -z "$ac_c_werror_flag" ||
16855          test ! -s conftest.err
16856        } && test -s conftest.$ac_objext; then
16857   :
16858 else
16859   $as_echo "$as_me: failed program was:" >&5
16860 sed 's/^/| /' conftest.$ac_ext >&5
16861
16862         ac_cv_type_struct_cmsgcred=yes
16863 fi
16864
16865 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16866 else
16867   $as_echo "$as_me: failed program was:" >&5
16868 sed 's/^/| /' conftest.$ac_ext >&5
16869
16870
16871 fi
16872
16873 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16874 fi
16875 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
16876 $as_echo "$ac_cv_type_struct_cmsgcred" >&6; }
16877 if test "x$ac_cv_type_struct_cmsgcred" = x""yes; then
16878
16879 cat >>confdefs.h <<_ACEOF
16880 #define HAVE_STRUCT_CMSGCRED 1
16881 _ACEOF
16882
16883
16884 fi
16885 { $as_echo "$as_me:$LINENO: checking for struct fcred" >&5
16886 $as_echo_n "checking for struct fcred... " >&6; }
16887 if test "${ac_cv_type_struct_fcred+set}" = set; then
16888   $as_echo_n "(cached) " >&6
16889 else
16890   ac_cv_type_struct_fcred=no
16891 cat >conftest.$ac_ext <<_ACEOF
16892 /* confdefs.h.  */
16893 _ACEOF
16894 cat confdefs.h >>conftest.$ac_ext
16895 cat >>conftest.$ac_ext <<_ACEOF
16896 /* end confdefs.h.  */
16897 #include <sys/param.h>
16898 #include <sys/types.h>
16899 #include <sys/socket.h>
16900 #include <sys/ucred.h>
16901
16902 int
16903 main ()
16904 {
16905 if (sizeof (struct fcred))
16906        return 0;
16907   ;
16908   return 0;
16909 }
16910 _ACEOF
16911 rm -f conftest.$ac_objext
16912 if { (ac_try="$ac_compile"
16913 case "(($ac_try" in
16914   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16915   *) ac_try_echo=$ac_try;;
16916 esac
16917 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16918 $as_echo "$ac_try_echo") >&5
16919   (eval "$ac_compile") 2>conftest.er1
16920   ac_status=$?
16921   grep -v '^ *+' conftest.er1 >conftest.err
16922   rm -f conftest.er1
16923   cat conftest.err >&5
16924   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16925   (exit $ac_status); } && {
16926          test -z "$ac_c_werror_flag" ||
16927          test ! -s conftest.err
16928        } && test -s conftest.$ac_objext; then
16929   cat >conftest.$ac_ext <<_ACEOF
16930 /* confdefs.h.  */
16931 _ACEOF
16932 cat confdefs.h >>conftest.$ac_ext
16933 cat >>conftest.$ac_ext <<_ACEOF
16934 /* end confdefs.h.  */
16935 #include <sys/param.h>
16936 #include <sys/types.h>
16937 #include <sys/socket.h>
16938 #include <sys/ucred.h>
16939
16940 int
16941 main ()
16942 {
16943 if (sizeof ((struct fcred)))
16944           return 0;
16945   ;
16946   return 0;
16947 }
16948 _ACEOF
16949 rm -f conftest.$ac_objext
16950 if { (ac_try="$ac_compile"
16951 case "(($ac_try" in
16952   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16953   *) ac_try_echo=$ac_try;;
16954 esac
16955 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16956 $as_echo "$ac_try_echo") >&5
16957   (eval "$ac_compile") 2>conftest.er1
16958   ac_status=$?
16959   grep -v '^ *+' conftest.er1 >conftest.err
16960   rm -f conftest.er1
16961   cat conftest.err >&5
16962   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16963   (exit $ac_status); } && {
16964          test -z "$ac_c_werror_flag" ||
16965          test ! -s conftest.err
16966        } && test -s conftest.$ac_objext; then
16967   :
16968 else
16969   $as_echo "$as_me: failed program was:" >&5
16970 sed 's/^/| /' conftest.$ac_ext >&5
16971
16972         ac_cv_type_struct_fcred=yes
16973 fi
16974
16975 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16976 else
16977   $as_echo "$as_me: failed program was:" >&5
16978 sed 's/^/| /' conftest.$ac_ext >&5
16979
16980
16981 fi
16982
16983 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16984 fi
16985 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5
16986 $as_echo "$ac_cv_type_struct_fcred" >&6; }
16987 if test "x$ac_cv_type_struct_fcred" = x""yes; then
16988
16989 cat >>confdefs.h <<_ACEOF
16990 #define HAVE_STRUCT_FCRED 1
16991 _ACEOF
16992
16993
16994 fi
16995 { $as_echo "$as_me:$LINENO: checking for struct sockcred" >&5
16996 $as_echo_n "checking for struct sockcred... " >&6; }
16997 if test "${ac_cv_type_struct_sockcred+set}" = set; then
16998   $as_echo_n "(cached) " >&6
16999 else
17000   ac_cv_type_struct_sockcred=no
17001 cat >conftest.$ac_ext <<_ACEOF
17002 /* confdefs.h.  */
17003 _ACEOF
17004 cat confdefs.h >>conftest.$ac_ext
17005 cat >>conftest.$ac_ext <<_ACEOF
17006 /* end confdefs.h.  */
17007 #include <sys/param.h>
17008 #include <sys/types.h>
17009 #include <sys/socket.h>
17010 #include <sys/ucred.h>
17011
17012 int
17013 main ()
17014 {
17015 if (sizeof (struct sockcred))
17016        return 0;
17017   ;
17018   return 0;
17019 }
17020 _ACEOF
17021 rm -f conftest.$ac_objext
17022 if { (ac_try="$ac_compile"
17023 case "(($ac_try" in
17024   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17025   *) ac_try_echo=$ac_try;;
17026 esac
17027 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17028 $as_echo "$ac_try_echo") >&5
17029   (eval "$ac_compile") 2>conftest.er1
17030   ac_status=$?
17031   grep -v '^ *+' conftest.er1 >conftest.err
17032   rm -f conftest.er1
17033   cat conftest.err >&5
17034   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17035   (exit $ac_status); } && {
17036          test -z "$ac_c_werror_flag" ||
17037          test ! -s conftest.err
17038        } && test -s conftest.$ac_objext; then
17039   cat >conftest.$ac_ext <<_ACEOF
17040 /* confdefs.h.  */
17041 _ACEOF
17042 cat confdefs.h >>conftest.$ac_ext
17043 cat >>conftest.$ac_ext <<_ACEOF
17044 /* end confdefs.h.  */
17045 #include <sys/param.h>
17046 #include <sys/types.h>
17047 #include <sys/socket.h>
17048 #include <sys/ucred.h>
17049
17050 int
17051 main ()
17052 {
17053 if (sizeof ((struct sockcred)))
17054           return 0;
17055   ;
17056   return 0;
17057 }
17058 _ACEOF
17059 rm -f conftest.$ac_objext
17060 if { (ac_try="$ac_compile"
17061 case "(($ac_try" in
17062   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17063   *) ac_try_echo=$ac_try;;
17064 esac
17065 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17066 $as_echo "$ac_try_echo") >&5
17067   (eval "$ac_compile") 2>conftest.er1
17068   ac_status=$?
17069   grep -v '^ *+' conftest.er1 >conftest.err
17070   rm -f conftest.er1
17071   cat conftest.err >&5
17072   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17073   (exit $ac_status); } && {
17074          test -z "$ac_c_werror_flag" ||
17075          test ! -s conftest.err
17076        } && test -s conftest.$ac_objext; then
17077   :
17078 else
17079   $as_echo "$as_me: failed program was:" >&5
17080 sed 's/^/| /' conftest.$ac_ext >&5
17081
17082         ac_cv_type_struct_sockcred=yes
17083 fi
17084
17085 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17086 else
17087   $as_echo "$as_me: failed program was:" >&5
17088 sed 's/^/| /' conftest.$ac_ext >&5
17089
17090
17091 fi
17092
17093 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17094 fi
17095 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5
17096 $as_echo "$ac_cv_type_struct_sockcred" >&6; }
17097 if test "x$ac_cv_type_struct_sockcred" = x""yes; then
17098
17099 cat >>confdefs.h <<_ACEOF
17100 #define HAVE_STRUCT_SOCKCRED 1
17101 _ACEOF
17102
17103
17104 fi
17105
17106
17107 { $as_echo "$as_me:$LINENO: checking for struct option" >&5
17108 $as_echo_n "checking for struct option... " >&6; }
17109 if test "${ac_cv_type_struct_option+set}" = set; then
17110   $as_echo_n "(cached) " >&6
17111 else
17112   ac_cv_type_struct_option=no
17113 cat >conftest.$ac_ext <<_ACEOF
17114 /* confdefs.h.  */
17115 _ACEOF
17116 cat confdefs.h >>conftest.$ac_ext
17117 cat >>conftest.$ac_ext <<_ACEOF
17118 /* end confdefs.h.  */
17119 #ifdef HAVE_GETOPT_H
17120 #include <getopt.h>
17121 #endif
17122
17123 int
17124 main ()
17125 {
17126 if (sizeof (struct option))
17127        return 0;
17128   ;
17129   return 0;
17130 }
17131 _ACEOF
17132 rm -f conftest.$ac_objext
17133 if { (ac_try="$ac_compile"
17134 case "(($ac_try" in
17135   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17136   *) ac_try_echo=$ac_try;;
17137 esac
17138 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17139 $as_echo "$ac_try_echo") >&5
17140   (eval "$ac_compile") 2>conftest.er1
17141   ac_status=$?
17142   grep -v '^ *+' conftest.er1 >conftest.err
17143   rm -f conftest.er1
17144   cat conftest.err >&5
17145   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17146   (exit $ac_status); } && {
17147          test -z "$ac_c_werror_flag" ||
17148          test ! -s conftest.err
17149        } && test -s conftest.$ac_objext; then
17150   cat >conftest.$ac_ext <<_ACEOF
17151 /* confdefs.h.  */
17152 _ACEOF
17153 cat confdefs.h >>conftest.$ac_ext
17154 cat >>conftest.$ac_ext <<_ACEOF
17155 /* end confdefs.h.  */
17156 #ifdef HAVE_GETOPT_H
17157 #include <getopt.h>
17158 #endif
17159
17160 int
17161 main ()
17162 {
17163 if (sizeof ((struct option)))
17164           return 0;
17165   ;
17166   return 0;
17167 }
17168 _ACEOF
17169 rm -f conftest.$ac_objext
17170 if { (ac_try="$ac_compile"
17171 case "(($ac_try" in
17172   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17173   *) ac_try_echo=$ac_try;;
17174 esac
17175 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17176 $as_echo "$ac_try_echo") >&5
17177   (eval "$ac_compile") 2>conftest.er1
17178   ac_status=$?
17179   grep -v '^ *+' conftest.er1 >conftest.err
17180   rm -f conftest.er1
17181   cat conftest.err >&5
17182   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17183   (exit $ac_status); } && {
17184          test -z "$ac_c_werror_flag" ||
17185          test ! -s conftest.err
17186        } && test -s conftest.$ac_objext; then
17187   :
17188 else
17189   $as_echo "$as_me: failed program was:" >&5
17190 sed 's/^/| /' conftest.$ac_ext >&5
17191
17192         ac_cv_type_struct_option=yes
17193 fi
17194
17195 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17196 else
17197   $as_echo "$as_me: failed program was:" >&5
17198 sed 's/^/| /' conftest.$ac_ext >&5
17199
17200
17201 fi
17202
17203 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17204 fi
17205 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
17206 $as_echo "$ac_cv_type_struct_option" >&6; }
17207 if test "x$ac_cv_type_struct_option" = x""yes; then
17208
17209 cat >>confdefs.h <<_ACEOF
17210 #define HAVE_STRUCT_OPTION 1
17211 _ACEOF
17212
17213
17214 fi
17215
17216
17217 if test "$with_zlib" = yes; then
17218   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
17219   # did not).  While we could work around the lack of z_streamp, it
17220   # seems unwise to encourage people to use such old zlib versions...
17221   { $as_echo "$as_me:$LINENO: checking for z_streamp" >&5
17222 $as_echo_n "checking for z_streamp... " >&6; }
17223 if test "${ac_cv_type_z_streamp+set}" = set; then
17224   $as_echo_n "(cached) " >&6
17225 else
17226   ac_cv_type_z_streamp=no
17227 cat >conftest.$ac_ext <<_ACEOF
17228 /* confdefs.h.  */
17229 _ACEOF
17230 cat confdefs.h >>conftest.$ac_ext
17231 cat >>conftest.$ac_ext <<_ACEOF
17232 /* end confdefs.h.  */
17233 #include <zlib.h>
17234
17235 int
17236 main ()
17237 {
17238 if (sizeof (z_streamp))
17239        return 0;
17240   ;
17241   return 0;
17242 }
17243 _ACEOF
17244 rm -f conftest.$ac_objext
17245 if { (ac_try="$ac_compile"
17246 case "(($ac_try" in
17247   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17248   *) ac_try_echo=$ac_try;;
17249 esac
17250 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17251 $as_echo "$ac_try_echo") >&5
17252   (eval "$ac_compile") 2>conftest.er1
17253   ac_status=$?
17254   grep -v '^ *+' conftest.er1 >conftest.err
17255   rm -f conftest.er1
17256   cat conftest.err >&5
17257   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17258   (exit $ac_status); } && {
17259          test -z "$ac_c_werror_flag" ||
17260          test ! -s conftest.err
17261        } && test -s conftest.$ac_objext; then
17262   cat >conftest.$ac_ext <<_ACEOF
17263 /* confdefs.h.  */
17264 _ACEOF
17265 cat confdefs.h >>conftest.$ac_ext
17266 cat >>conftest.$ac_ext <<_ACEOF
17267 /* end confdefs.h.  */
17268 #include <zlib.h>
17269
17270 int
17271 main ()
17272 {
17273 if (sizeof ((z_streamp)))
17274           return 0;
17275   ;
17276   return 0;
17277 }
17278 _ACEOF
17279 rm -f conftest.$ac_objext
17280 if { (ac_try="$ac_compile"
17281 case "(($ac_try" in
17282   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17283   *) ac_try_echo=$ac_try;;
17284 esac
17285 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17286 $as_echo "$ac_try_echo") >&5
17287   (eval "$ac_compile") 2>conftest.er1
17288   ac_status=$?
17289   grep -v '^ *+' conftest.er1 >conftest.err
17290   rm -f conftest.er1
17291   cat conftest.err >&5
17292   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17293   (exit $ac_status); } && {
17294          test -z "$ac_c_werror_flag" ||
17295          test ! -s conftest.err
17296        } && test -s conftest.$ac_objext; then
17297   :
17298 else
17299   $as_echo "$as_me: failed program was:" >&5
17300 sed 's/^/| /' conftest.$ac_ext >&5
17301
17302         ac_cv_type_z_streamp=yes
17303 fi
17304
17305 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17306 else
17307   $as_echo "$as_me: failed program was:" >&5
17308 sed 's/^/| /' conftest.$ac_ext >&5
17309
17310
17311 fi
17312
17313 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17314 fi
17315 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
17316 $as_echo "$ac_cv_type_z_streamp" >&6; }
17317 if test "x$ac_cv_type_z_streamp" = x""yes; then
17318   :
17319 else
17320   { { $as_echo "$as_me:$LINENO: error: zlib version is too old
17321 Use --without-zlib to disable zlib support." >&5
17322 $as_echo "$as_me: error: zlib version is too old
17323 Use --without-zlib to disable zlib support." >&2;}
17324    { (exit 1); exit 1; }; }
17325 fi
17326
17327 fi
17328
17329 if test "$with_krb5" = yes; then
17330 # Check for differences between MIT and Heimdal (KTH) releases
17331   { $as_echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
17332 $as_echo_n "checking for krb5_ticket.enc_part2... " >&6; }
17333 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
17334   $as_echo_n "(cached) " >&6
17335 else
17336   cat >conftest.$ac_ext <<_ACEOF
17337 /* confdefs.h.  */
17338 _ACEOF
17339 cat confdefs.h >>conftest.$ac_ext
17340 cat >>conftest.$ac_ext <<_ACEOF
17341 /* end confdefs.h.  */
17342 #include <krb5.h>
17343
17344 int
17345 main ()
17346 {
17347 static krb5_ticket ac_aggr;
17348 if (ac_aggr.enc_part2)
17349 return 0;
17350   ;
17351   return 0;
17352 }
17353 _ACEOF
17354 rm -f conftest.$ac_objext
17355 if { (ac_try="$ac_compile"
17356 case "(($ac_try" in
17357   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17358   *) ac_try_echo=$ac_try;;
17359 esac
17360 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17361 $as_echo "$ac_try_echo") >&5
17362   (eval "$ac_compile") 2>conftest.er1
17363   ac_status=$?
17364   grep -v '^ *+' conftest.er1 >conftest.err
17365   rm -f conftest.er1
17366   cat conftest.err >&5
17367   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17368   (exit $ac_status); } && {
17369          test -z "$ac_c_werror_flag" ||
17370          test ! -s conftest.err
17371        } && test -s conftest.$ac_objext; then
17372   ac_cv_member_krb5_ticket_enc_part2=yes
17373 else
17374   $as_echo "$as_me: failed program was:" >&5
17375 sed 's/^/| /' conftest.$ac_ext >&5
17376
17377         cat >conftest.$ac_ext <<_ACEOF
17378 /* confdefs.h.  */
17379 _ACEOF
17380 cat confdefs.h >>conftest.$ac_ext
17381 cat >>conftest.$ac_ext <<_ACEOF
17382 /* end confdefs.h.  */
17383 #include <krb5.h>
17384
17385 int
17386 main ()
17387 {
17388 static krb5_ticket ac_aggr;
17389 if (sizeof ac_aggr.enc_part2)
17390 return 0;
17391   ;
17392   return 0;
17393 }
17394 _ACEOF
17395 rm -f conftest.$ac_objext
17396 if { (ac_try="$ac_compile"
17397 case "(($ac_try" in
17398   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17399   *) ac_try_echo=$ac_try;;
17400 esac
17401 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17402 $as_echo "$ac_try_echo") >&5
17403   (eval "$ac_compile") 2>conftest.er1
17404   ac_status=$?
17405   grep -v '^ *+' conftest.er1 >conftest.err
17406   rm -f conftest.er1
17407   cat conftest.err >&5
17408   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17409   (exit $ac_status); } && {
17410          test -z "$ac_c_werror_flag" ||
17411          test ! -s conftest.err
17412        } && test -s conftest.$ac_objext; then
17413   ac_cv_member_krb5_ticket_enc_part2=yes
17414 else
17415   $as_echo "$as_me: failed program was:" >&5
17416 sed 's/^/| /' conftest.$ac_ext >&5
17417
17418         ac_cv_member_krb5_ticket_enc_part2=no
17419 fi
17420
17421 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17422 fi
17423
17424 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17425 fi
17426 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
17427 $as_echo "$ac_cv_member_krb5_ticket_enc_part2" >&6; }
17428 if test "x$ac_cv_member_krb5_ticket_enc_part2" = x""yes; then
17429
17430 cat >>confdefs.h <<_ACEOF
17431 #define HAVE_KRB5_TICKET_ENC_PART2 1
17432 _ACEOF
17433
17434
17435 else
17436   { $as_echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
17437 $as_echo_n "checking for krb5_ticket.client... " >&6; }
17438 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
17439   $as_echo_n "(cached) " >&6
17440 else
17441   cat >conftest.$ac_ext <<_ACEOF
17442 /* confdefs.h.  */
17443 _ACEOF
17444 cat confdefs.h >>conftest.$ac_ext
17445 cat >>conftest.$ac_ext <<_ACEOF
17446 /* end confdefs.h.  */
17447 #include <krb5.h>
17448
17449 int
17450 main ()
17451 {
17452 static krb5_ticket ac_aggr;
17453 if (ac_aggr.client)
17454 return 0;
17455   ;
17456   return 0;
17457 }
17458 _ACEOF
17459 rm -f conftest.$ac_objext
17460 if { (ac_try="$ac_compile"
17461 case "(($ac_try" in
17462   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17463   *) ac_try_echo=$ac_try;;
17464 esac
17465 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17466 $as_echo "$ac_try_echo") >&5
17467   (eval "$ac_compile") 2>conftest.er1
17468   ac_status=$?
17469   grep -v '^ *+' conftest.er1 >conftest.err
17470   rm -f conftest.er1
17471   cat conftest.err >&5
17472   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17473   (exit $ac_status); } && {
17474          test -z "$ac_c_werror_flag" ||
17475          test ! -s conftest.err
17476        } && test -s conftest.$ac_objext; then
17477   ac_cv_member_krb5_ticket_client=yes
17478 else
17479   $as_echo "$as_me: failed program was:" >&5
17480 sed 's/^/| /' conftest.$ac_ext >&5
17481
17482         cat >conftest.$ac_ext <<_ACEOF
17483 /* confdefs.h.  */
17484 _ACEOF
17485 cat confdefs.h >>conftest.$ac_ext
17486 cat >>conftest.$ac_ext <<_ACEOF
17487 /* end confdefs.h.  */
17488 #include <krb5.h>
17489
17490 int
17491 main ()
17492 {
17493 static krb5_ticket ac_aggr;
17494 if (sizeof ac_aggr.client)
17495 return 0;
17496   ;
17497   return 0;
17498 }
17499 _ACEOF
17500 rm -f conftest.$ac_objext
17501 if { (ac_try="$ac_compile"
17502 case "(($ac_try" in
17503   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17504   *) ac_try_echo=$ac_try;;
17505 esac
17506 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17507 $as_echo "$ac_try_echo") >&5
17508   (eval "$ac_compile") 2>conftest.er1
17509   ac_status=$?
17510   grep -v '^ *+' conftest.er1 >conftest.err
17511   rm -f conftest.er1
17512   cat conftest.err >&5
17513   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17514   (exit $ac_status); } && {
17515          test -z "$ac_c_werror_flag" ||
17516          test ! -s conftest.err
17517        } && test -s conftest.$ac_objext; then
17518   ac_cv_member_krb5_ticket_client=yes
17519 else
17520   $as_echo "$as_me: failed program was:" >&5
17521 sed 's/^/| /' conftest.$ac_ext >&5
17522
17523         ac_cv_member_krb5_ticket_client=no
17524 fi
17525
17526 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17527 fi
17528
17529 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17530 fi
17531 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
17532 $as_echo "$ac_cv_member_krb5_ticket_client" >&6; }
17533 if test "x$ac_cv_member_krb5_ticket_client" = x""yes; then
17534
17535 cat >>confdefs.h <<_ACEOF
17536 #define HAVE_KRB5_TICKET_CLIENT 1
17537 _ACEOF
17538
17539
17540 else
17541   { { $as_echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
17542 $as_echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
17543    { (exit 1); exit 1; }; }
17544 fi
17545
17546 fi
17547
17548   { $as_echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
17549 $as_echo_n "checking for krb5_error.text.data... " >&6; }
17550 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
17551   $as_echo_n "(cached) " >&6
17552 else
17553   cat >conftest.$ac_ext <<_ACEOF
17554 /* confdefs.h.  */
17555 _ACEOF
17556 cat confdefs.h >>conftest.$ac_ext
17557 cat >>conftest.$ac_ext <<_ACEOF
17558 /* end confdefs.h.  */
17559 #include <krb5.h>
17560
17561 int
17562 main ()
17563 {
17564 static krb5_error ac_aggr;
17565 if (ac_aggr.text.data)
17566 return 0;
17567   ;
17568   return 0;
17569 }
17570 _ACEOF
17571 rm -f conftest.$ac_objext
17572 if { (ac_try="$ac_compile"
17573 case "(($ac_try" in
17574   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17575   *) ac_try_echo=$ac_try;;
17576 esac
17577 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17578 $as_echo "$ac_try_echo") >&5
17579   (eval "$ac_compile") 2>conftest.er1
17580   ac_status=$?
17581   grep -v '^ *+' conftest.er1 >conftest.err
17582   rm -f conftest.er1
17583   cat conftest.err >&5
17584   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17585   (exit $ac_status); } && {
17586          test -z "$ac_c_werror_flag" ||
17587          test ! -s conftest.err
17588        } && test -s conftest.$ac_objext; then
17589   ac_cv_member_krb5_error_text_data=yes
17590 else
17591   $as_echo "$as_me: failed program was:" >&5
17592 sed 's/^/| /' conftest.$ac_ext >&5
17593
17594         cat >conftest.$ac_ext <<_ACEOF
17595 /* confdefs.h.  */
17596 _ACEOF
17597 cat confdefs.h >>conftest.$ac_ext
17598 cat >>conftest.$ac_ext <<_ACEOF
17599 /* end confdefs.h.  */
17600 #include <krb5.h>
17601
17602 int
17603 main ()
17604 {
17605 static krb5_error ac_aggr;
17606 if (sizeof ac_aggr.text.data)
17607 return 0;
17608   ;
17609   return 0;
17610 }
17611 _ACEOF
17612 rm -f conftest.$ac_objext
17613 if { (ac_try="$ac_compile"
17614 case "(($ac_try" in
17615   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17616   *) ac_try_echo=$ac_try;;
17617 esac
17618 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17619 $as_echo "$ac_try_echo") >&5
17620   (eval "$ac_compile") 2>conftest.er1
17621   ac_status=$?
17622   grep -v '^ *+' conftest.er1 >conftest.err
17623   rm -f conftest.er1
17624   cat conftest.err >&5
17625   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17626   (exit $ac_status); } && {
17627          test -z "$ac_c_werror_flag" ||
17628          test ! -s conftest.err
17629        } && test -s conftest.$ac_objext; then
17630   ac_cv_member_krb5_error_text_data=yes
17631 else
17632   $as_echo "$as_me: failed program was:" >&5
17633 sed 's/^/| /' conftest.$ac_ext >&5
17634
17635         ac_cv_member_krb5_error_text_data=no
17636 fi
17637
17638 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17639 fi
17640
17641 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17642 fi
17643 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
17644 $as_echo "$ac_cv_member_krb5_error_text_data" >&6; }
17645 if test "x$ac_cv_member_krb5_error_text_data" = x""yes; then
17646
17647 cat >>confdefs.h <<_ACEOF
17648 #define HAVE_KRB5_ERROR_TEXT_DATA 1
17649 _ACEOF
17650
17651
17652 else
17653   { $as_echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
17654 $as_echo_n "checking for krb5_error.e_data... " >&6; }
17655 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
17656   $as_echo_n "(cached) " >&6
17657 else
17658   cat >conftest.$ac_ext <<_ACEOF
17659 /* confdefs.h.  */
17660 _ACEOF
17661 cat confdefs.h >>conftest.$ac_ext
17662 cat >>conftest.$ac_ext <<_ACEOF
17663 /* end confdefs.h.  */
17664 #include <krb5.h>
17665
17666 int
17667 main ()
17668 {
17669 static krb5_error ac_aggr;
17670 if (ac_aggr.e_data)
17671 return 0;
17672   ;
17673   return 0;
17674 }
17675 _ACEOF
17676 rm -f conftest.$ac_objext
17677 if { (ac_try="$ac_compile"
17678 case "(($ac_try" in
17679   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17680   *) ac_try_echo=$ac_try;;
17681 esac
17682 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17683 $as_echo "$ac_try_echo") >&5
17684   (eval "$ac_compile") 2>conftest.er1
17685   ac_status=$?
17686   grep -v '^ *+' conftest.er1 >conftest.err
17687   rm -f conftest.er1
17688   cat conftest.err >&5
17689   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17690   (exit $ac_status); } && {
17691          test -z "$ac_c_werror_flag" ||
17692          test ! -s conftest.err
17693        } && test -s conftest.$ac_objext; then
17694   ac_cv_member_krb5_error_e_data=yes
17695 else
17696   $as_echo "$as_me: failed program was:" >&5
17697 sed 's/^/| /' conftest.$ac_ext >&5
17698
17699         cat >conftest.$ac_ext <<_ACEOF
17700 /* confdefs.h.  */
17701 _ACEOF
17702 cat confdefs.h >>conftest.$ac_ext
17703 cat >>conftest.$ac_ext <<_ACEOF
17704 /* end confdefs.h.  */
17705 #include <krb5.h>
17706
17707 int
17708 main ()
17709 {
17710 static krb5_error ac_aggr;
17711 if (sizeof ac_aggr.e_data)
17712 return 0;
17713   ;
17714   return 0;
17715 }
17716 _ACEOF
17717 rm -f conftest.$ac_objext
17718 if { (ac_try="$ac_compile"
17719 case "(($ac_try" in
17720   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17721   *) ac_try_echo=$ac_try;;
17722 esac
17723 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17724 $as_echo "$ac_try_echo") >&5
17725   (eval "$ac_compile") 2>conftest.er1
17726   ac_status=$?
17727   grep -v '^ *+' conftest.er1 >conftest.err
17728   rm -f conftest.er1
17729   cat conftest.err >&5
17730   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17731   (exit $ac_status); } && {
17732          test -z "$ac_c_werror_flag" ||
17733          test ! -s conftest.err
17734        } && test -s conftest.$ac_objext; then
17735   ac_cv_member_krb5_error_e_data=yes
17736 else
17737   $as_echo "$as_me: failed program was:" >&5
17738 sed 's/^/| /' conftest.$ac_ext >&5
17739
17740         ac_cv_member_krb5_error_e_data=no
17741 fi
17742
17743 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17744 fi
17745
17746 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17747 fi
17748 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
17749 $as_echo "$ac_cv_member_krb5_error_e_data" >&6; }
17750 if test "x$ac_cv_member_krb5_error_e_data" = x""yes; then
17751
17752 cat >>confdefs.h <<_ACEOF
17753 #define HAVE_KRB5_ERROR_E_DATA 1
17754 _ACEOF
17755
17756
17757 else
17758   { { $as_echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
17759 $as_echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
17760    { (exit 1); exit 1; }; }
17761 fi
17762
17763 fi
17764
17765
17766 # Win32 requires headers to be loaded for __stdcall, so can't use
17767 # AC_CHECK_FUNCS here.
17768   { $as_echo "$as_me:$LINENO: checking for krb5_free_unparsed_name" >&5
17769 $as_echo_n "checking for krb5_free_unparsed_name... " >&6; }
17770   cat >conftest.$ac_ext <<_ACEOF
17771 /* confdefs.h.  */
17772 _ACEOF
17773 cat confdefs.h >>conftest.$ac_ext
17774 cat >>conftest.$ac_ext <<_ACEOF
17775 /* end confdefs.h.  */
17776 #include <krb5.h>
17777 int
17778 main ()
17779 {
17780 krb5_free_unparsed_name(NULL,NULL);
17781   ;
17782   return 0;
17783 }
17784 _ACEOF
17785 rm -f conftest.$ac_objext conftest$ac_exeext
17786 if { (ac_try="$ac_link"
17787 case "(($ac_try" in
17788   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17789   *) ac_try_echo=$ac_try;;
17790 esac
17791 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17792 $as_echo "$ac_try_echo") >&5
17793   (eval "$ac_link") 2>conftest.er1
17794   ac_status=$?
17795   grep -v '^ *+' conftest.er1 >conftest.err
17796   rm -f conftest.er1
17797   cat conftest.err >&5
17798   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17799   (exit $ac_status); } && {
17800          test -z "$ac_c_werror_flag" ||
17801          test ! -s conftest.err
17802        } && test -s conftest$ac_exeext && {
17803          test "$cross_compiling" = yes ||
17804          $as_test_x conftest$ac_exeext
17805        }; then
17806
17807 cat >>confdefs.h <<\_ACEOF
17808 #define HAVE_KRB5_FREE_UNPARSED_NAME 1
17809 _ACEOF
17810
17811 { $as_echo "$as_me:$LINENO: result: yes" >&5
17812 $as_echo "yes" >&6; }
17813 else
17814   $as_echo "$as_me: failed program was:" >&5
17815 sed 's/^/| /' conftest.$ac_ext >&5
17816
17817         { $as_echo "$as_me:$LINENO: result: no" >&5
17818 $as_echo "no" >&6; }
17819 fi
17820
17821 rm -rf conftest.dSYM
17822 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17823       conftest$ac_exeext conftest.$ac_ext
17824 fi
17825
17826 # Check largefile support.  You might think this is a system service not a
17827 # compiler characteristic, but you'd be wrong.  We must check this before
17828 # probing existence of related functions such as fseeko, since the largefile
17829 # defines can affect what is generated for that.
17830 # Check whether --enable-largefile was given.
17831 if test "${enable_largefile+set}" = set; then
17832   enableval=$enable_largefile;
17833 fi
17834
17835 if test "$enable_largefile" != no; then
17836
17837   { $as_echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
17838 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
17839 if test "${ac_cv_sys_largefile_CC+set}" = set; then
17840   $as_echo_n "(cached) " >&6
17841 else
17842   ac_cv_sys_largefile_CC=no
17843      if test "$GCC" != yes; then
17844        ac_save_CC=$CC
17845        while :; do
17846          # IRIX 6.2 and later do not support large files by default,
17847          # so use the C compiler's -n32 option if that helps.
17848          cat >conftest.$ac_ext <<_ACEOF
17849 /* confdefs.h.  */
17850 _ACEOF
17851 cat confdefs.h >>conftest.$ac_ext
17852 cat >>conftest.$ac_ext <<_ACEOF
17853 /* end confdefs.h.  */
17854 #include <sys/types.h>
17855  /* Check that off_t can represent 2**63 - 1 correctly.
17856     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17857     since some C++ compilers masquerading as C compilers
17858     incorrectly reject 9223372036854775807.  */
17859 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17860   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17861                        && LARGE_OFF_T % 2147483647 == 1)
17862                       ? 1 : -1];
17863 int
17864 main ()
17865 {
17866
17867   ;
17868   return 0;
17869 }
17870 _ACEOF
17871          rm -f conftest.$ac_objext
17872 if { (ac_try="$ac_compile"
17873 case "(($ac_try" in
17874   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17875   *) ac_try_echo=$ac_try;;
17876 esac
17877 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17878 $as_echo "$ac_try_echo") >&5
17879   (eval "$ac_compile") 2>conftest.er1
17880   ac_status=$?
17881   grep -v '^ *+' conftest.er1 >conftest.err
17882   rm -f conftest.er1
17883   cat conftest.err >&5
17884   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17885   (exit $ac_status); } && {
17886          test -z "$ac_c_werror_flag" ||
17887          test ! -s conftest.err
17888        } && test -s conftest.$ac_objext; then
17889   break
17890 else
17891   $as_echo "$as_me: failed program was:" >&5
17892 sed 's/^/| /' conftest.$ac_ext >&5
17893
17894
17895 fi
17896
17897 rm -f core conftest.err conftest.$ac_objext
17898          CC="$CC -n32"
17899          rm -f conftest.$ac_objext
17900 if { (ac_try="$ac_compile"
17901 case "(($ac_try" in
17902   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17903   *) ac_try_echo=$ac_try;;
17904 esac
17905 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17906 $as_echo "$ac_try_echo") >&5
17907   (eval "$ac_compile") 2>conftest.er1
17908   ac_status=$?
17909   grep -v '^ *+' conftest.er1 >conftest.err
17910   rm -f conftest.er1
17911   cat conftest.err >&5
17912   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17913   (exit $ac_status); } && {
17914          test -z "$ac_c_werror_flag" ||
17915          test ! -s conftest.err
17916        } && test -s conftest.$ac_objext; then
17917   ac_cv_sys_largefile_CC=' -n32'; break
17918 else
17919   $as_echo "$as_me: failed program was:" >&5
17920 sed 's/^/| /' conftest.$ac_ext >&5
17921
17922
17923 fi
17924
17925 rm -f core conftest.err conftest.$ac_objext
17926          break
17927        done
17928        CC=$ac_save_CC
17929        rm -f conftest.$ac_ext
17930     fi
17931 fi
17932 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
17933 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
17934   if test "$ac_cv_sys_largefile_CC" != no; then
17935     CC=$CC$ac_cv_sys_largefile_CC
17936   fi
17937
17938   { $as_echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
17939 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
17940 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
17941   $as_echo_n "(cached) " >&6
17942 else
17943   while :; do
17944   cat >conftest.$ac_ext <<_ACEOF
17945 /* confdefs.h.  */
17946 _ACEOF
17947 cat confdefs.h >>conftest.$ac_ext
17948 cat >>conftest.$ac_ext <<_ACEOF
17949 /* end confdefs.h.  */
17950 #include <sys/types.h>
17951  /* Check that off_t can represent 2**63 - 1 correctly.
17952     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17953     since some C++ compilers masquerading as C compilers
17954     incorrectly reject 9223372036854775807.  */
17955 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17956   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17957                        && LARGE_OFF_T % 2147483647 == 1)
17958                       ? 1 : -1];
17959 int
17960 main ()
17961 {
17962
17963   ;
17964   return 0;
17965 }
17966 _ACEOF
17967 rm -f conftest.$ac_objext
17968 if { (ac_try="$ac_compile"
17969 case "(($ac_try" in
17970   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17971   *) ac_try_echo=$ac_try;;
17972 esac
17973 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17974 $as_echo "$ac_try_echo") >&5
17975   (eval "$ac_compile") 2>conftest.er1
17976   ac_status=$?
17977   grep -v '^ *+' conftest.er1 >conftest.err
17978   rm -f conftest.er1
17979   cat conftest.err >&5
17980   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17981   (exit $ac_status); } && {
17982          test -z "$ac_c_werror_flag" ||
17983          test ! -s conftest.err
17984        } && test -s conftest.$ac_objext; then
17985   ac_cv_sys_file_offset_bits=no; break
17986 else
17987   $as_echo "$as_me: failed program was:" >&5
17988 sed 's/^/| /' conftest.$ac_ext >&5
17989
17990
17991 fi
17992
17993 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17994   cat >conftest.$ac_ext <<_ACEOF
17995 /* confdefs.h.  */
17996 _ACEOF
17997 cat confdefs.h >>conftest.$ac_ext
17998 cat >>conftest.$ac_ext <<_ACEOF
17999 /* end confdefs.h.  */
18000 #define _FILE_OFFSET_BITS 64
18001 #include <sys/types.h>
18002  /* Check that off_t can represent 2**63 - 1 correctly.
18003     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18004     since some C++ compilers masquerading as C compilers
18005     incorrectly reject 9223372036854775807.  */
18006 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18007   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18008                        && LARGE_OFF_T % 2147483647 == 1)
18009                       ? 1 : -1];
18010 int
18011 main ()
18012 {
18013
18014   ;
18015   return 0;
18016 }
18017 _ACEOF
18018 rm -f conftest.$ac_objext
18019 if { (ac_try="$ac_compile"
18020 case "(($ac_try" in
18021   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18022   *) ac_try_echo=$ac_try;;
18023 esac
18024 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18025 $as_echo "$ac_try_echo") >&5
18026   (eval "$ac_compile") 2>conftest.er1
18027   ac_status=$?
18028   grep -v '^ *+' conftest.er1 >conftest.err
18029   rm -f conftest.er1
18030   cat conftest.err >&5
18031   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18032   (exit $ac_status); } && {
18033          test -z "$ac_c_werror_flag" ||
18034          test ! -s conftest.err
18035        } && test -s conftest.$ac_objext; then
18036   ac_cv_sys_file_offset_bits=64; break
18037 else
18038   $as_echo "$as_me: failed program was:" >&5
18039 sed 's/^/| /' conftest.$ac_ext >&5
18040
18041
18042 fi
18043
18044 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18045   ac_cv_sys_file_offset_bits=unknown
18046   break
18047 done
18048 fi
18049 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
18050 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
18051 case $ac_cv_sys_file_offset_bits in #(
18052   no | unknown) ;;
18053   *)
18054 cat >>confdefs.h <<_ACEOF
18055 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
18056 _ACEOF
18057 ;;
18058 esac
18059 rm -rf conftest*
18060   if test $ac_cv_sys_file_offset_bits = unknown; then
18061     { $as_echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
18062 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
18063 if test "${ac_cv_sys_large_files+set}" = set; then
18064   $as_echo_n "(cached) " >&6
18065 else
18066   while :; do
18067   cat >conftest.$ac_ext <<_ACEOF
18068 /* confdefs.h.  */
18069 _ACEOF
18070 cat confdefs.h >>conftest.$ac_ext
18071 cat >>conftest.$ac_ext <<_ACEOF
18072 /* end confdefs.h.  */
18073 #include <sys/types.h>
18074  /* Check that off_t can represent 2**63 - 1 correctly.
18075     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18076     since some C++ compilers masquerading as C compilers
18077     incorrectly reject 9223372036854775807.  */
18078 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18079   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18080                        && LARGE_OFF_T % 2147483647 == 1)
18081                       ? 1 : -1];
18082 int
18083 main ()
18084 {
18085
18086   ;
18087   return 0;
18088 }
18089 _ACEOF
18090 rm -f conftest.$ac_objext
18091 if { (ac_try="$ac_compile"
18092 case "(($ac_try" in
18093   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18094   *) ac_try_echo=$ac_try;;
18095 esac
18096 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18097 $as_echo "$ac_try_echo") >&5
18098   (eval "$ac_compile") 2>conftest.er1
18099   ac_status=$?
18100   grep -v '^ *+' conftest.er1 >conftest.err
18101   rm -f conftest.er1
18102   cat conftest.err >&5
18103   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18104   (exit $ac_status); } && {
18105          test -z "$ac_c_werror_flag" ||
18106          test ! -s conftest.err
18107        } && test -s conftest.$ac_objext; then
18108   ac_cv_sys_large_files=no; break
18109 else
18110   $as_echo "$as_me: failed program was:" >&5
18111 sed 's/^/| /' conftest.$ac_ext >&5
18112
18113
18114 fi
18115
18116 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18117   cat >conftest.$ac_ext <<_ACEOF
18118 /* confdefs.h.  */
18119 _ACEOF
18120 cat confdefs.h >>conftest.$ac_ext
18121 cat >>conftest.$ac_ext <<_ACEOF
18122 /* end confdefs.h.  */
18123 #define _LARGE_FILES 1
18124 #include <sys/types.h>
18125  /* Check that off_t can represent 2**63 - 1 correctly.
18126     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18127     since some C++ compilers masquerading as C compilers
18128     incorrectly reject 9223372036854775807.  */
18129 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18130   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18131                        && LARGE_OFF_T % 2147483647 == 1)
18132                       ? 1 : -1];
18133 int
18134 main ()
18135 {
18136
18137   ;
18138   return 0;
18139 }
18140 _ACEOF
18141 rm -f conftest.$ac_objext
18142 if { (ac_try="$ac_compile"
18143 case "(($ac_try" in
18144   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18145   *) ac_try_echo=$ac_try;;
18146 esac
18147 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18148 $as_echo "$ac_try_echo") >&5
18149   (eval "$ac_compile") 2>conftest.er1
18150   ac_status=$?
18151   grep -v '^ *+' conftest.er1 >conftest.err
18152   rm -f conftest.er1
18153   cat conftest.err >&5
18154   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18155   (exit $ac_status); } && {
18156          test -z "$ac_c_werror_flag" ||
18157          test ! -s conftest.err
18158        } && test -s conftest.$ac_objext; then
18159   ac_cv_sys_large_files=1; break
18160 else
18161   $as_echo "$as_me: failed program was:" >&5
18162 sed 's/^/| /' conftest.$ac_ext >&5
18163
18164
18165 fi
18166
18167 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18168   ac_cv_sys_large_files=unknown
18169   break
18170 done
18171 fi
18172 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
18173 $as_echo "$ac_cv_sys_large_files" >&6; }
18174 case $ac_cv_sys_large_files in #(
18175   no | unknown) ;;
18176   *)
18177 cat >>confdefs.h <<_ACEOF
18178 #define _LARGE_FILES $ac_cv_sys_large_files
18179 _ACEOF
18180 ;;
18181 esac
18182 rm -rf conftest*
18183   fi
18184 fi
18185
18186
18187 # Check for largefile support (must be after AC_SYS_LARGEFILE)
18188 # The cast to long int works around a bug in the HP C Compiler
18189 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18190 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18191 # This bug is HP SR number 8606223364.
18192 { $as_echo "$as_me:$LINENO: checking size of off_t" >&5
18193 $as_echo_n "checking size of off_t... " >&6; }
18194 if test "${ac_cv_sizeof_off_t+set}" = set; then
18195   $as_echo_n "(cached) " >&6
18196 else
18197   if test "$cross_compiling" = yes; then
18198   # Depending upon the size, compute the lo and hi bounds.
18199 cat >conftest.$ac_ext <<_ACEOF
18200 /* confdefs.h.  */
18201 _ACEOF
18202 cat confdefs.h >>conftest.$ac_ext
18203 cat >>conftest.$ac_ext <<_ACEOF
18204 /* end confdefs.h.  */
18205 $ac_includes_default
18206 int
18207 main ()
18208 {
18209 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= 0)];
18210 test_array [0] = 0
18211
18212   ;
18213   return 0;
18214 }
18215 _ACEOF
18216 rm -f conftest.$ac_objext
18217 if { (ac_try="$ac_compile"
18218 case "(($ac_try" in
18219   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18220   *) ac_try_echo=$ac_try;;
18221 esac
18222 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18223 $as_echo "$ac_try_echo") >&5
18224   (eval "$ac_compile") 2>conftest.er1
18225   ac_status=$?
18226   grep -v '^ *+' conftest.er1 >conftest.err
18227   rm -f conftest.er1
18228   cat conftest.err >&5
18229   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18230   (exit $ac_status); } && {
18231          test -z "$ac_c_werror_flag" ||
18232          test ! -s conftest.err
18233        } && test -s conftest.$ac_objext; then
18234   ac_lo=0 ac_mid=0
18235   while :; do
18236     cat >conftest.$ac_ext <<_ACEOF
18237 /* confdefs.h.  */
18238 _ACEOF
18239 cat confdefs.h >>conftest.$ac_ext
18240 cat >>conftest.$ac_ext <<_ACEOF
18241 /* end confdefs.h.  */
18242 $ac_includes_default
18243 int
18244 main ()
18245 {
18246 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)];
18247 test_array [0] = 0
18248
18249   ;
18250   return 0;
18251 }
18252 _ACEOF
18253 rm -f conftest.$ac_objext
18254 if { (ac_try="$ac_compile"
18255 case "(($ac_try" in
18256   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18257   *) ac_try_echo=$ac_try;;
18258 esac
18259 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18260 $as_echo "$ac_try_echo") >&5
18261   (eval "$ac_compile") 2>conftest.er1
18262   ac_status=$?
18263   grep -v '^ *+' conftest.er1 >conftest.err
18264   rm -f conftest.er1
18265   cat conftest.err >&5
18266   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18267   (exit $ac_status); } && {
18268          test -z "$ac_c_werror_flag" ||
18269          test ! -s conftest.err
18270        } && test -s conftest.$ac_objext; then
18271   ac_hi=$ac_mid; break
18272 else
18273   $as_echo "$as_me: failed program was:" >&5
18274 sed 's/^/| /' conftest.$ac_ext >&5
18275
18276         ac_lo=`expr $ac_mid + 1`
18277                         if test $ac_lo -le $ac_mid; then
18278                           ac_lo= ac_hi=
18279                           break
18280                         fi
18281                         ac_mid=`expr 2 '*' $ac_mid + 1`
18282 fi
18283
18284 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18285   done
18286 else
18287   $as_echo "$as_me: failed program was:" >&5
18288 sed 's/^/| /' conftest.$ac_ext >&5
18289
18290         cat >conftest.$ac_ext <<_ACEOF
18291 /* confdefs.h.  */
18292 _ACEOF
18293 cat confdefs.h >>conftest.$ac_ext
18294 cat >>conftest.$ac_ext <<_ACEOF
18295 /* end confdefs.h.  */
18296 $ac_includes_default
18297 int
18298 main ()
18299 {
18300 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) < 0)];
18301 test_array [0] = 0
18302
18303   ;
18304   return 0;
18305 }
18306 _ACEOF
18307 rm -f conftest.$ac_objext
18308 if { (ac_try="$ac_compile"
18309 case "(($ac_try" in
18310   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18311   *) ac_try_echo=$ac_try;;
18312 esac
18313 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18314 $as_echo "$ac_try_echo") >&5
18315   (eval "$ac_compile") 2>conftest.er1
18316   ac_status=$?
18317   grep -v '^ *+' conftest.er1 >conftest.err
18318   rm -f conftest.er1
18319   cat conftest.err >&5
18320   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18321   (exit $ac_status); } && {
18322          test -z "$ac_c_werror_flag" ||
18323          test ! -s conftest.err
18324        } && test -s conftest.$ac_objext; then
18325   ac_hi=-1 ac_mid=-1
18326   while :; do
18327     cat >conftest.$ac_ext <<_ACEOF
18328 /* confdefs.h.  */
18329 _ACEOF
18330 cat confdefs.h >>conftest.$ac_ext
18331 cat >>conftest.$ac_ext <<_ACEOF
18332 /* end confdefs.h.  */
18333 $ac_includes_default
18334 int
18335 main ()
18336 {
18337 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= $ac_mid)];
18338 test_array [0] = 0
18339
18340   ;
18341   return 0;
18342 }
18343 _ACEOF
18344 rm -f conftest.$ac_objext
18345 if { (ac_try="$ac_compile"
18346 case "(($ac_try" in
18347   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18348   *) ac_try_echo=$ac_try;;
18349 esac
18350 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18351 $as_echo "$ac_try_echo") >&5
18352   (eval "$ac_compile") 2>conftest.er1
18353   ac_status=$?
18354   grep -v '^ *+' conftest.er1 >conftest.err
18355   rm -f conftest.er1
18356   cat conftest.err >&5
18357   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18358   (exit $ac_status); } && {
18359          test -z "$ac_c_werror_flag" ||
18360          test ! -s conftest.err
18361        } && test -s conftest.$ac_objext; then
18362   ac_lo=$ac_mid; break
18363 else
18364   $as_echo "$as_me: failed program was:" >&5
18365 sed 's/^/| /' conftest.$ac_ext >&5
18366
18367         ac_hi=`expr '(' $ac_mid ')' - 1`
18368                         if test $ac_mid -le $ac_hi; then
18369                           ac_lo= ac_hi=
18370                           break
18371                         fi
18372                         ac_mid=`expr 2 '*' $ac_mid`
18373 fi
18374
18375 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18376   done
18377 else
18378   $as_echo "$as_me: failed program was:" >&5
18379 sed 's/^/| /' conftest.$ac_ext >&5
18380
18381         ac_lo= ac_hi=
18382 fi
18383
18384 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18385 fi
18386
18387 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18388 # Binary search between lo and hi bounds.
18389 while test "x$ac_lo" != "x$ac_hi"; do
18390   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
18391   cat >conftest.$ac_ext <<_ACEOF
18392 /* confdefs.h.  */
18393 _ACEOF
18394 cat confdefs.h >>conftest.$ac_ext
18395 cat >>conftest.$ac_ext <<_ACEOF
18396 /* end confdefs.h.  */
18397 $ac_includes_default
18398 int
18399 main ()
18400 {
18401 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)];
18402 test_array [0] = 0
18403
18404   ;
18405   return 0;
18406 }
18407 _ACEOF
18408 rm -f conftest.$ac_objext
18409 if { (ac_try="$ac_compile"
18410 case "(($ac_try" in
18411   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18412   *) ac_try_echo=$ac_try;;
18413 esac
18414 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18415 $as_echo "$ac_try_echo") >&5
18416   (eval "$ac_compile") 2>conftest.er1
18417   ac_status=$?
18418   grep -v '^ *+' conftest.er1 >conftest.err
18419   rm -f conftest.er1
18420   cat conftest.err >&5
18421   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18422   (exit $ac_status); } && {
18423          test -z "$ac_c_werror_flag" ||
18424          test ! -s conftest.err
18425        } && test -s conftest.$ac_objext; then
18426   ac_hi=$ac_mid
18427 else
18428   $as_echo "$as_me: failed program was:" >&5
18429 sed 's/^/| /' conftest.$ac_ext >&5
18430
18431         ac_lo=`expr '(' $ac_mid ')' + 1`
18432 fi
18433
18434 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18435 done
18436 case $ac_lo in
18437 ?*) ac_cv_sizeof_off_t=$ac_lo;;
18438 '') if test "$ac_cv_type_off_t" = yes; then
18439      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18440 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18441 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
18442 See \`config.log' for more details." >&5
18443 $as_echo "$as_me: error: cannot compute sizeof (off_t)
18444 See \`config.log' for more details." >&2;}
18445    { (exit 77); exit 77; }; }; }
18446    else
18447      ac_cv_sizeof_off_t=0
18448    fi ;;
18449 esac
18450 else
18451   cat >conftest.$ac_ext <<_ACEOF
18452 /* confdefs.h.  */
18453 _ACEOF
18454 cat confdefs.h >>conftest.$ac_ext
18455 cat >>conftest.$ac_ext <<_ACEOF
18456 /* end confdefs.h.  */
18457 $ac_includes_default
18458 static long int longval () { return (long int) (sizeof (off_t)); }
18459 static unsigned long int ulongval () { return (long int) (sizeof (off_t)); }
18460 #include <stdio.h>
18461 #include <stdlib.h>
18462 int
18463 main ()
18464 {
18465
18466   FILE *f = fopen ("conftest.val", "w");
18467   if (! f)
18468     return 1;
18469   if (((long int) (sizeof (off_t))) < 0)
18470     {
18471       long int i = longval ();
18472       if (i != ((long int) (sizeof (off_t))))
18473         return 1;
18474       fprintf (f, "%ld", i);
18475     }
18476   else
18477     {
18478       unsigned long int i = ulongval ();
18479       if (i != ((long int) (sizeof (off_t))))
18480         return 1;
18481       fprintf (f, "%lu", i);
18482     }
18483   /* Do not output a trailing newline, as this causes \r\n confusion
18484      on some platforms.  */
18485   return ferror (f) || fclose (f) != 0;
18486
18487   ;
18488   return 0;
18489 }
18490 _ACEOF
18491 rm -f conftest$ac_exeext
18492 if { (ac_try="$ac_link"
18493 case "(($ac_try" in
18494   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18495   *) ac_try_echo=$ac_try;;
18496 esac
18497 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18498 $as_echo "$ac_try_echo") >&5
18499   (eval "$ac_link") 2>&5
18500   ac_status=$?
18501   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18502   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18503   { (case "(($ac_try" in
18504   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18505   *) ac_try_echo=$ac_try;;
18506 esac
18507 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18508 $as_echo "$ac_try_echo") >&5
18509   (eval "$ac_try") 2>&5
18510   ac_status=$?
18511   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18512   (exit $ac_status); }; }; then
18513   ac_cv_sizeof_off_t=`cat conftest.val`
18514 else
18515   $as_echo "$as_me: program exited with status $ac_status" >&5
18516 $as_echo "$as_me: failed program was:" >&5
18517 sed 's/^/| /' conftest.$ac_ext >&5
18518
18519 ( exit $ac_status )
18520 if test "$ac_cv_type_off_t" = yes; then
18521      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18522 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18523 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
18524 See \`config.log' for more details." >&5
18525 $as_echo "$as_me: error: cannot compute sizeof (off_t)
18526 See \`config.log' for more details." >&2;}
18527    { (exit 77); exit 77; }; }; }
18528    else
18529      ac_cv_sizeof_off_t=0
18530    fi
18531 fi
18532 rm -rf conftest.dSYM
18533 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18534 fi
18535 rm -f conftest.val
18536 fi
18537 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
18538 $as_echo "$ac_cv_sizeof_off_t" >&6; }
18539
18540
18541
18542 cat >>confdefs.h <<_ACEOF
18543 #define SIZEOF_OFF_T $ac_cv_sizeof_off_t
18544 _ACEOF
18545
18546
18547
18548 # If we don't have largefile support, can't handle segsize >= 2GB.
18549 if test "$ac_cv_sizeof_off_t" -lt 8 -a "$segsize" != "1"; then
18550    { { $as_echo "$as_me:$LINENO: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&5
18551 $as_echo "$as_me: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&2;}
18552    { (exit 1); exit 1; }; }
18553 fi
18554
18555
18556 ##
18557 ## Functions, global variables
18558 ##
18559
18560 { $as_echo "$as_me:$LINENO: checking for int timezone" >&5
18561 $as_echo_n "checking for int timezone... " >&6; }
18562 if test "${pgac_cv_var_int_timezone+set}" = set; then
18563   $as_echo_n "(cached) " >&6
18564 else
18565   cat >conftest.$ac_ext <<_ACEOF
18566 /* confdefs.h.  */
18567 _ACEOF
18568 cat confdefs.h >>conftest.$ac_ext
18569 cat >>conftest.$ac_ext <<_ACEOF
18570 /* end confdefs.h.  */
18571 #include <time.h>
18572 int res;
18573 int
18574 main ()
18575 {
18576 #ifndef __CYGWIN__
18577 res = timezone / 60;
18578 #else
18579 res = _timezone / 60;
18580 #endif
18581   ;
18582   return 0;
18583 }
18584 _ACEOF
18585 rm -f conftest.$ac_objext conftest$ac_exeext
18586 if { (ac_try="$ac_link"
18587 case "(($ac_try" in
18588   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18589   *) ac_try_echo=$ac_try;;
18590 esac
18591 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18592 $as_echo "$ac_try_echo") >&5
18593   (eval "$ac_link") 2>conftest.er1
18594   ac_status=$?
18595   grep -v '^ *+' conftest.er1 >conftest.err
18596   rm -f conftest.er1
18597   cat conftest.err >&5
18598   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18599   (exit $ac_status); } && {
18600          test -z "$ac_c_werror_flag" ||
18601          test ! -s conftest.err
18602        } && test -s conftest$ac_exeext && {
18603          test "$cross_compiling" = yes ||
18604          $as_test_x conftest$ac_exeext
18605        }; then
18606   pgac_cv_var_int_timezone=yes
18607 else
18608   $as_echo "$as_me: failed program was:" >&5
18609 sed 's/^/| /' conftest.$ac_ext >&5
18610
18611         pgac_cv_var_int_timezone=no
18612 fi
18613
18614 rm -rf conftest.dSYM
18615 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18616       conftest$ac_exeext conftest.$ac_ext
18617 fi
18618 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
18619 $as_echo "$pgac_cv_var_int_timezone" >&6; }
18620 if test x"$pgac_cv_var_int_timezone" = xyes ; then
18621
18622 cat >>confdefs.h <<\_ACEOF
18623 #define HAVE_INT_TIMEZONE /**/
18624 _ACEOF
18625
18626 fi
18627 { $as_echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
18628 $as_echo_n "checking types of arguments for accept()... " >&6; }
18629  if test "${ac_cv_func_accept_return+set}" = set; then
18630   $as_echo_n "(cached) " >&6
18631 else
18632    if test "${ac_cv_func_accept_arg1+set}" = set; then
18633   $as_echo_n "(cached) " >&6
18634 else
18635     if test "${ac_cv_func_accept_arg2+set}" = set; then
18636   $as_echo_n "(cached) " >&6
18637 else
18638      if test "${ac_cv_func_accept_arg3+set}" = set; then
18639   $as_echo_n "(cached) " >&6
18640 else
18641       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL'; do
18642       for ac_cv_func_accept_arg1 in 'int' 'unsigned int'; do
18643        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
18644         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
18645          cat >conftest.$ac_ext <<_ACEOF
18646 /* confdefs.h.  */
18647 _ACEOF
18648 cat confdefs.h >>conftest.$ac_ext
18649 cat >>conftest.$ac_ext <<_ACEOF
18650 /* end confdefs.h.  */
18651 #ifdef HAVE_SYS_TYPES_H
18652 #include <sys/types.h>
18653 #endif
18654 #ifdef HAVE_SYS_SOCKET_H
18655 #include <sys/socket.h>
18656 #endif
18657 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
18658 int
18659 main ()
18660 {
18661
18662   ;
18663   return 0;
18664 }
18665 _ACEOF
18666 rm -f conftest.$ac_objext
18667 if { (ac_try="$ac_compile"
18668 case "(($ac_try" in
18669   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18670   *) ac_try_echo=$ac_try;;
18671 esac
18672 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18673 $as_echo "$ac_try_echo") >&5
18674   (eval "$ac_compile") 2>conftest.er1
18675   ac_status=$?
18676   grep -v '^ *+' conftest.er1 >conftest.err
18677   rm -f conftest.er1
18678   cat conftest.err >&5
18679   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18680   (exit $ac_status); } && {
18681          test -z "$ac_c_werror_flag" ||
18682          test ! -s conftest.err
18683        } && test -s conftest.$ac_objext; then
18684   ac_not_found=no; break 4
18685 else
18686   $as_echo "$as_me: failed program was:" >&5
18687 sed 's/^/| /' conftest.$ac_ext >&5
18688
18689         ac_not_found=yes
18690 fi
18691
18692 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18693        done
18694       done
18695      done
18696     done
18697     if test "$ac_not_found" = yes; then
18698       { { $as_echo "$as_me:$LINENO: error: could not determine argument types" >&5
18699 $as_echo "$as_me: error: could not determine argument types" >&2;}
18700    { (exit 1); exit 1; }; }
18701     fi
18702     if test "$ac_cv_func_accept_arg3" = "void"; then
18703       ac_cv_func_accept_arg3=int
18704     fi
18705
18706 fi
18707
18708 fi
18709
18710 fi
18711
18712 fi
18713  { $as_echo "$as_me:$LINENO: result: $ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&5
18714 $as_echo "$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6; }
18715
18716 cat >>confdefs.h <<_ACEOF
18717 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
18718 _ACEOF
18719
18720
18721 cat >>confdefs.h <<_ACEOF
18722 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
18723 _ACEOF
18724
18725
18726 cat >>confdefs.h <<_ACEOF
18727 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
18728 _ACEOF
18729
18730
18731 cat >>confdefs.h <<_ACEOF
18732 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
18733 _ACEOF
18734
18735
18736 { $as_echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
18737 $as_echo_n "checking whether gettimeofday takes only one argument... " >&6; }
18738 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
18739   $as_echo_n "(cached) " >&6
18740 else
18741   cat >conftest.$ac_ext <<_ACEOF
18742 /* confdefs.h.  */
18743 _ACEOF
18744 cat confdefs.h >>conftest.$ac_ext
18745 cat >>conftest.$ac_ext <<_ACEOF
18746 /* end confdefs.h.  */
18747 #include <sys/time.h>
18748 int
18749 main ()
18750 {
18751 struct timeval *tp;
18752 struct timezone *tzp;
18753 gettimeofday(tp,tzp);
18754   ;
18755   return 0;
18756 }
18757 _ACEOF
18758 rm -f conftest.$ac_objext
18759 if { (ac_try="$ac_compile"
18760 case "(($ac_try" in
18761   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18762   *) ac_try_echo=$ac_try;;
18763 esac
18764 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18765 $as_echo "$ac_try_echo") >&5
18766   (eval "$ac_compile") 2>conftest.er1
18767   ac_status=$?
18768   grep -v '^ *+' conftest.er1 >conftest.err
18769   rm -f conftest.er1
18770   cat conftest.err >&5
18771   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18772   (exit $ac_status); } && {
18773          test -z "$ac_c_werror_flag" ||
18774          test ! -s conftest.err
18775        } && test -s conftest.$ac_objext; then
18776   pgac_cv_func_gettimeofday_1arg=no
18777 else
18778   $as_echo "$as_me: failed program was:" >&5
18779 sed 's/^/| /' conftest.$ac_ext >&5
18780
18781         pgac_cv_func_gettimeofday_1arg=yes
18782 fi
18783
18784 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18785 fi
18786 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
18787 $as_echo "$pgac_cv_func_gettimeofday_1arg" >&6; }
18788 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
18789
18790 cat >>confdefs.h <<\_ACEOF
18791 #define GETTIMEOFDAY_1ARG /**/
18792 _ACEOF
18793
18794 fi
18795
18796
18797
18798
18799
18800
18801
18802
18803
18804
18805
18806
18807
18808
18809
18810
18811
18812
18813
18814
18815
18816
18817
18818
18819
18820
18821 for ac_func in cbrt dlopen fcvt fdatasync getifaddrs getpeereid getpeerucred getrlimit memmove poll pstat readlink scandir setproctitle setsid sigprocmask symlink sysconf towlower utime utimes waitpid wcstombs
18822 do
18823 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18824 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18825 $as_echo_n "checking for $ac_func... " >&6; }
18826 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18827   $as_echo_n "(cached) " >&6
18828 else
18829   cat >conftest.$ac_ext <<_ACEOF
18830 /* confdefs.h.  */
18831 _ACEOF
18832 cat confdefs.h >>conftest.$ac_ext
18833 cat >>conftest.$ac_ext <<_ACEOF
18834 /* end confdefs.h.  */
18835 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18836    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18837 #define $ac_func innocuous_$ac_func
18838
18839 /* System header to define __stub macros and hopefully few prototypes,
18840     which can conflict with char $ac_func (); below.
18841     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18842     <limits.h> exists even on freestanding compilers.  */
18843
18844 #ifdef __STDC__
18845 # include <limits.h>
18846 #else
18847 # include <assert.h>
18848 #endif
18849
18850 #undef $ac_func
18851
18852 /* Override any GCC internal prototype to avoid an error.
18853    Use char because int might match the return type of a GCC
18854    builtin and then its argument prototype would still apply.  */
18855 #ifdef __cplusplus
18856 extern "C"
18857 #endif
18858 char $ac_func ();
18859 /* The GNU C library defines this for functions which it implements
18860     to always fail with ENOSYS.  Some functions are actually named
18861     something starting with __ and the normal name is an alias.  */
18862 #if defined __stub_$ac_func || defined __stub___$ac_func
18863 choke me
18864 #endif
18865
18866 int
18867 main ()
18868 {
18869 return $ac_func ();
18870   ;
18871   return 0;
18872 }
18873 _ACEOF
18874 rm -f conftest.$ac_objext conftest$ac_exeext
18875 if { (ac_try="$ac_link"
18876 case "(($ac_try" in
18877   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18878   *) ac_try_echo=$ac_try;;
18879 esac
18880 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18881 $as_echo "$ac_try_echo") >&5
18882   (eval "$ac_link") 2>conftest.er1
18883   ac_status=$?
18884   grep -v '^ *+' conftest.er1 >conftest.err
18885   rm -f conftest.er1
18886   cat conftest.err >&5
18887   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18888   (exit $ac_status); } && {
18889          test -z "$ac_c_werror_flag" ||
18890          test ! -s conftest.err
18891        } && test -s conftest$ac_exeext && {
18892          test "$cross_compiling" = yes ||
18893          $as_test_x conftest$ac_exeext
18894        }; then
18895   eval "$as_ac_var=yes"
18896 else
18897   $as_echo "$as_me: failed program was:" >&5
18898 sed 's/^/| /' conftest.$ac_ext >&5
18899
18900         eval "$as_ac_var=no"
18901 fi
18902
18903 rm -rf conftest.dSYM
18904 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18905       conftest$ac_exeext conftest.$ac_ext
18906 fi
18907 ac_res=`eval 'as_val=${'$as_ac_var'}
18908                  $as_echo "$as_val"'`
18909                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
18910 $as_echo "$ac_res" >&6; }
18911 as_val=`eval 'as_val=${'$as_ac_var'}
18912                  $as_echo "$as_val"'`
18913    if test "x$as_val" = x""yes; then
18914   cat >>confdefs.h <<_ACEOF
18915 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18916 _ACEOF
18917
18918 fi
18919 done
18920
18921
18922
18923 for ac_func in fseeko
18924 do
18925 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18926 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18927 $as_echo_n "checking for $ac_func... " >&6; }
18928 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18929   $as_echo_n "(cached) " >&6
18930 else
18931   cat >conftest.$ac_ext <<_ACEOF
18932 /* confdefs.h.  */
18933 _ACEOF
18934 cat confdefs.h >>conftest.$ac_ext
18935 cat >>conftest.$ac_ext <<_ACEOF
18936 /* end confdefs.h.  */
18937 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18938    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18939 #define $ac_func innocuous_$ac_func
18940
18941 /* System header to define __stub macros and hopefully few prototypes,
18942     which can conflict with char $ac_func (); below.
18943     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18944     <limits.h> exists even on freestanding compilers.  */
18945
18946 #ifdef __STDC__
18947 # include <limits.h>
18948 #else
18949 # include <assert.h>
18950 #endif
18951
18952 #undef $ac_func
18953
18954 /* Override any GCC internal prototype to avoid an error.
18955    Use char because int might match the return type of a GCC
18956    builtin and then its argument prototype would still apply.  */
18957 #ifdef __cplusplus
18958 extern "C"
18959 #endif
18960 char $ac_func ();
18961 /* The GNU C library defines this for functions which it implements
18962     to always fail with ENOSYS.  Some functions are actually named
18963     something starting with __ and the normal name is an alias.  */
18964 #if defined __stub_$ac_func || defined __stub___$ac_func
18965 choke me
18966 #endif
18967
18968 int
18969 main ()
18970 {
18971 return $ac_func ();
18972   ;
18973   return 0;
18974 }
18975 _ACEOF
18976 rm -f conftest.$ac_objext conftest$ac_exeext
18977 if { (ac_try="$ac_link"
18978 case "(($ac_try" in
18979   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18980   *) ac_try_echo=$ac_try;;
18981 esac
18982 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18983 $as_echo "$ac_try_echo") >&5
18984   (eval "$ac_link") 2>conftest.er1
18985   ac_status=$?
18986   grep -v '^ *+' conftest.er1 >conftest.err
18987   rm -f conftest.er1
18988   cat conftest.err >&5
18989   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18990   (exit $ac_status); } && {
18991          test -z "$ac_c_werror_flag" ||
18992          test ! -s conftest.err
18993        } && test -s conftest$ac_exeext && {
18994          test "$cross_compiling" = yes ||
18995          $as_test_x conftest$ac_exeext
18996        }; then
18997   eval "$as_ac_var=yes"
18998 else
18999   $as_echo "$as_me: failed program was:" >&5
19000 sed 's/^/| /' conftest.$ac_ext >&5
19001
19002         eval "$as_ac_var=no"
19003 fi
19004
19005 rm -rf conftest.dSYM
19006 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19007       conftest$ac_exeext conftest.$ac_ext
19008 fi
19009 ac_res=`eval 'as_val=${'$as_ac_var'}
19010                  $as_echo "$as_val"'`
19011                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19012 $as_echo "$ac_res" >&6; }
19013 as_val=`eval 'as_val=${'$as_ac_var'}
19014                  $as_echo "$as_val"'`
19015    if test "x$as_val" = x""yes; then
19016   cat >>confdefs.h <<_ACEOF
19017 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19018 _ACEOF
19019
19020 else
19021   case " $LIBOBJS " in
19022   *" $ac_func.$ac_objext "* ) ;;
19023   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
19024  ;;
19025 esac
19026
19027 fi
19028 done
19029
19030
19031 case $host_os in
19032         # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
19033         # Mingw uses macros to access Win32 API calls
19034         bsdi*|netbsd*|mingw*)
19035
19036 cat >>confdefs.h <<\_ACEOF
19037 #define HAVE_FSEEKO 1
19038 _ACEOF
19039
19040                 ac_cv_func_fseeko=yes;;
19041         *)
19042                 { $as_echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
19043 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
19044 if test "${ac_cv_sys_largefile_source+set}" = set; then
19045   $as_echo_n "(cached) " >&6
19046 else
19047   while :; do
19048   cat >conftest.$ac_ext <<_ACEOF
19049 /* confdefs.h.  */
19050 _ACEOF
19051 cat confdefs.h >>conftest.$ac_ext
19052 cat >>conftest.$ac_ext <<_ACEOF
19053 /* end confdefs.h.  */
19054 #include <sys/types.h> /* for off_t */
19055      #include <stdio.h>
19056 int
19057 main ()
19058 {
19059 int (*fp) (FILE *, off_t, int) = fseeko;
19060      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
19061   ;
19062   return 0;
19063 }
19064 _ACEOF
19065 rm -f conftest.$ac_objext conftest$ac_exeext
19066 if { (ac_try="$ac_link"
19067 case "(($ac_try" in
19068   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19069   *) ac_try_echo=$ac_try;;
19070 esac
19071 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19072 $as_echo "$ac_try_echo") >&5
19073   (eval "$ac_link") 2>conftest.er1
19074   ac_status=$?
19075   grep -v '^ *+' conftest.er1 >conftest.err
19076   rm -f conftest.er1
19077   cat conftest.err >&5
19078   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19079   (exit $ac_status); } && {
19080          test -z "$ac_c_werror_flag" ||
19081          test ! -s conftest.err
19082        } && test -s conftest$ac_exeext && {
19083          test "$cross_compiling" = yes ||
19084          $as_test_x conftest$ac_exeext
19085        }; then
19086   ac_cv_sys_largefile_source=no; break
19087 else
19088   $as_echo "$as_me: failed program was:" >&5
19089 sed 's/^/| /' conftest.$ac_ext >&5
19090
19091
19092 fi
19093
19094 rm -rf conftest.dSYM
19095 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19096       conftest$ac_exeext conftest.$ac_ext
19097   cat >conftest.$ac_ext <<_ACEOF
19098 /* confdefs.h.  */
19099 _ACEOF
19100 cat confdefs.h >>conftest.$ac_ext
19101 cat >>conftest.$ac_ext <<_ACEOF
19102 /* end confdefs.h.  */
19103 #define _LARGEFILE_SOURCE 1
19104 #include <sys/types.h> /* for off_t */
19105      #include <stdio.h>
19106 int
19107 main ()
19108 {
19109 int (*fp) (FILE *, off_t, int) = fseeko;
19110      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
19111   ;
19112   return 0;
19113 }
19114 _ACEOF
19115 rm -f conftest.$ac_objext conftest$ac_exeext
19116 if { (ac_try="$ac_link"
19117 case "(($ac_try" in
19118   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19119   *) ac_try_echo=$ac_try;;
19120 esac
19121 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19122 $as_echo "$ac_try_echo") >&5
19123   (eval "$ac_link") 2>conftest.er1
19124   ac_status=$?
19125   grep -v '^ *+' conftest.er1 >conftest.err
19126   rm -f conftest.er1
19127   cat conftest.err >&5
19128   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19129   (exit $ac_status); } && {
19130          test -z "$ac_c_werror_flag" ||
19131          test ! -s conftest.err
19132        } && test -s conftest$ac_exeext && {
19133          test "$cross_compiling" = yes ||
19134          $as_test_x conftest$ac_exeext
19135        }; then
19136   ac_cv_sys_largefile_source=1; break
19137 else
19138   $as_echo "$as_me: failed program was:" >&5
19139 sed 's/^/| /' conftest.$ac_ext >&5
19140
19141
19142 fi
19143
19144 rm -rf conftest.dSYM
19145 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19146       conftest$ac_exeext conftest.$ac_ext
19147   ac_cv_sys_largefile_source=unknown
19148   break
19149 done
19150 fi
19151 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
19152 $as_echo "$ac_cv_sys_largefile_source" >&6; }
19153 case $ac_cv_sys_largefile_source in #(
19154   no | unknown) ;;
19155   *)
19156 cat >>confdefs.h <<_ACEOF
19157 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
19158 _ACEOF
19159 ;;
19160 esac
19161 rm -rf conftest*
19162
19163 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
19164 # in glibc 2.1.3, but that breaks too many other things.
19165 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
19166 if test $ac_cv_sys_largefile_source != unknown; then
19167
19168 cat >>confdefs.h <<\_ACEOF
19169 #define HAVE_FSEEKO 1
19170 _ACEOF
19171
19172 fi
19173 ;;
19174 esac
19175
19176 # posix_fadvise() is a no-op on Solaris, so don't incur function overhead
19177 # by calling it, 2009-04-02
19178 # http://src.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/lib/libc/port/gen/posix_fadvise.c
19179 if test "$PORTNAME" != "solaris"; then
19180
19181 for ac_func in posix_fadvise
19182 do
19183 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19184 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19185 $as_echo_n "checking for $ac_func... " >&6; }
19186 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19187   $as_echo_n "(cached) " >&6
19188 else
19189   cat >conftest.$ac_ext <<_ACEOF
19190 /* confdefs.h.  */
19191 _ACEOF
19192 cat confdefs.h >>conftest.$ac_ext
19193 cat >>conftest.$ac_ext <<_ACEOF
19194 /* end confdefs.h.  */
19195 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19196    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19197 #define $ac_func innocuous_$ac_func
19198
19199 /* System header to define __stub macros and hopefully few prototypes,
19200     which can conflict with char $ac_func (); below.
19201     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19202     <limits.h> exists even on freestanding compilers.  */
19203
19204 #ifdef __STDC__
19205 # include <limits.h>
19206 #else
19207 # include <assert.h>
19208 #endif
19209
19210 #undef $ac_func
19211
19212 /* Override any GCC internal prototype to avoid an error.
19213    Use char because int might match the return type of a GCC
19214    builtin and then its argument prototype would still apply.  */
19215 #ifdef __cplusplus
19216 extern "C"
19217 #endif
19218 char $ac_func ();
19219 /* The GNU C library defines this for functions which it implements
19220     to always fail with ENOSYS.  Some functions are actually named
19221     something starting with __ and the normal name is an alias.  */
19222 #if defined __stub_$ac_func || defined __stub___$ac_func
19223 choke me
19224 #endif
19225
19226 int
19227 main ()
19228 {
19229 return $ac_func ();
19230   ;
19231   return 0;
19232 }
19233 _ACEOF
19234 rm -f conftest.$ac_objext conftest$ac_exeext
19235 if { (ac_try="$ac_link"
19236 case "(($ac_try" in
19237   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19238   *) ac_try_echo=$ac_try;;
19239 esac
19240 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19241 $as_echo "$ac_try_echo") >&5
19242   (eval "$ac_link") 2>conftest.er1
19243   ac_status=$?
19244   grep -v '^ *+' conftest.er1 >conftest.err
19245   rm -f conftest.er1
19246   cat conftest.err >&5
19247   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19248   (exit $ac_status); } && {
19249          test -z "$ac_c_werror_flag" ||
19250          test ! -s conftest.err
19251        } && test -s conftest$ac_exeext && {
19252          test "$cross_compiling" = yes ||
19253          $as_test_x conftest$ac_exeext
19254        }; then
19255   eval "$as_ac_var=yes"
19256 else
19257   $as_echo "$as_me: failed program was:" >&5
19258 sed 's/^/| /' conftest.$ac_ext >&5
19259
19260         eval "$as_ac_var=no"
19261 fi
19262
19263 rm -rf conftest.dSYM
19264 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19265       conftest$ac_exeext conftest.$ac_ext
19266 fi
19267 ac_res=`eval 'as_val=${'$as_ac_var'}
19268                  $as_echo "$as_val"'`
19269                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19270 $as_echo "$ac_res" >&6; }
19271 as_val=`eval 'as_val=${'$as_ac_var'}
19272                  $as_echo "$as_val"'`
19273    if test "x$as_val" = x""yes; then
19274   cat >>confdefs.h <<_ACEOF
19275 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19276 _ACEOF
19277
19278 fi
19279 done
19280
19281 { $as_echo "$as_me:$LINENO: checking whether posix_fadvise is declared" >&5
19282 $as_echo_n "checking whether posix_fadvise is declared... " >&6; }
19283 if test "${ac_cv_have_decl_posix_fadvise+set}" = set; then
19284   $as_echo_n "(cached) " >&6
19285 else
19286   cat >conftest.$ac_ext <<_ACEOF
19287 /* confdefs.h.  */
19288 _ACEOF
19289 cat confdefs.h >>conftest.$ac_ext
19290 cat >>conftest.$ac_ext <<_ACEOF
19291 /* end confdefs.h.  */
19292 #include <fcntl.h>
19293
19294 int
19295 main ()
19296 {
19297 #ifndef posix_fadvise
19298   (void) posix_fadvise;
19299 #endif
19300
19301   ;
19302   return 0;
19303 }
19304 _ACEOF
19305 rm -f conftest.$ac_objext
19306 if { (ac_try="$ac_compile"
19307 case "(($ac_try" in
19308   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19309   *) ac_try_echo=$ac_try;;
19310 esac
19311 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19312 $as_echo "$ac_try_echo") >&5
19313   (eval "$ac_compile") 2>conftest.er1
19314   ac_status=$?
19315   grep -v '^ *+' conftest.er1 >conftest.err
19316   rm -f conftest.er1
19317   cat conftest.err >&5
19318   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19319   (exit $ac_status); } && {
19320          test -z "$ac_c_werror_flag" ||
19321          test ! -s conftest.err
19322        } && test -s conftest.$ac_objext; then
19323   ac_cv_have_decl_posix_fadvise=yes
19324 else
19325   $as_echo "$as_me: failed program was:" >&5
19326 sed 's/^/| /' conftest.$ac_ext >&5
19327
19328         ac_cv_have_decl_posix_fadvise=no
19329 fi
19330
19331 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19332 fi
19333 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_posix_fadvise" >&5
19334 $as_echo "$ac_cv_have_decl_posix_fadvise" >&6; }
19335 if test "x$ac_cv_have_decl_posix_fadvise" = x""yes; then
19336
19337 cat >>confdefs.h <<_ACEOF
19338 #define HAVE_DECL_POSIX_FADVISE 1
19339 _ACEOF
19340
19341
19342 else
19343   cat >>confdefs.h <<_ACEOF
19344 #define HAVE_DECL_POSIX_FADVISE 0
19345 _ACEOF
19346
19347
19348 fi
19349
19350
19351 fi
19352
19353 { $as_echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
19354 $as_echo_n "checking whether fdatasync is declared... " >&6; }
19355 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
19356   $as_echo_n "(cached) " >&6
19357 else
19358   cat >conftest.$ac_ext <<_ACEOF
19359 /* confdefs.h.  */
19360 _ACEOF
19361 cat confdefs.h >>conftest.$ac_ext
19362 cat >>conftest.$ac_ext <<_ACEOF
19363 /* end confdefs.h.  */
19364 #include <unistd.h>
19365
19366 int
19367 main ()
19368 {
19369 #ifndef fdatasync
19370   (void) fdatasync;
19371 #endif
19372
19373   ;
19374   return 0;
19375 }
19376 _ACEOF
19377 rm -f conftest.$ac_objext
19378 if { (ac_try="$ac_compile"
19379 case "(($ac_try" in
19380   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19381   *) ac_try_echo=$ac_try;;
19382 esac
19383 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19384 $as_echo "$ac_try_echo") >&5
19385   (eval "$ac_compile") 2>conftest.er1
19386   ac_status=$?
19387   grep -v '^ *+' conftest.er1 >conftest.err
19388   rm -f conftest.er1
19389   cat conftest.err >&5
19390   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19391   (exit $ac_status); } && {
19392          test -z "$ac_c_werror_flag" ||
19393          test ! -s conftest.err
19394        } && test -s conftest.$ac_objext; then
19395   ac_cv_have_decl_fdatasync=yes
19396 else
19397   $as_echo "$as_me: failed program was:" >&5
19398 sed 's/^/| /' conftest.$ac_ext >&5
19399
19400         ac_cv_have_decl_fdatasync=no
19401 fi
19402
19403 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19404 fi
19405 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
19406 $as_echo "$ac_cv_have_decl_fdatasync" >&6; }
19407 if test "x$ac_cv_have_decl_fdatasync" = x""yes; then
19408
19409 cat >>confdefs.h <<_ACEOF
19410 #define HAVE_DECL_FDATASYNC 1
19411 _ACEOF
19412
19413
19414 else
19415   cat >>confdefs.h <<_ACEOF
19416 #define HAVE_DECL_FDATASYNC 0
19417 _ACEOF
19418
19419
19420 fi
19421
19422
19423 { $as_echo "$as_me:$LINENO: checking whether strlcat is declared" >&5
19424 $as_echo_n "checking whether strlcat is declared... " >&6; }
19425 if test "${ac_cv_have_decl_strlcat+set}" = set; then
19426   $as_echo_n "(cached) " >&6
19427 else
19428   cat >conftest.$ac_ext <<_ACEOF
19429 /* confdefs.h.  */
19430 _ACEOF
19431 cat confdefs.h >>conftest.$ac_ext
19432 cat >>conftest.$ac_ext <<_ACEOF
19433 /* end confdefs.h.  */
19434 $ac_includes_default
19435 int
19436 main ()
19437 {
19438 #ifndef strlcat
19439   (void) strlcat;
19440 #endif
19441
19442   ;
19443   return 0;
19444 }
19445 _ACEOF
19446 rm -f conftest.$ac_objext
19447 if { (ac_try="$ac_compile"
19448 case "(($ac_try" in
19449   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19450   *) ac_try_echo=$ac_try;;
19451 esac
19452 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19453 $as_echo "$ac_try_echo") >&5
19454   (eval "$ac_compile") 2>conftest.er1
19455   ac_status=$?
19456   grep -v '^ *+' conftest.er1 >conftest.err
19457   rm -f conftest.er1
19458   cat conftest.err >&5
19459   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19460   (exit $ac_status); } && {
19461          test -z "$ac_c_werror_flag" ||
19462          test ! -s conftest.err
19463        } && test -s conftest.$ac_objext; then
19464   ac_cv_have_decl_strlcat=yes
19465 else
19466   $as_echo "$as_me: failed program was:" >&5
19467 sed 's/^/| /' conftest.$ac_ext >&5
19468
19469         ac_cv_have_decl_strlcat=no
19470 fi
19471
19472 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19473 fi
19474 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcat" >&5
19475 $as_echo "$ac_cv_have_decl_strlcat" >&6; }
19476 if test "x$ac_cv_have_decl_strlcat" = x""yes; then
19477
19478 cat >>confdefs.h <<_ACEOF
19479 #define HAVE_DECL_STRLCAT 1
19480 _ACEOF
19481
19482
19483 else
19484   cat >>confdefs.h <<_ACEOF
19485 #define HAVE_DECL_STRLCAT 0
19486 _ACEOF
19487
19488
19489 fi
19490 { $as_echo "$as_me:$LINENO: checking whether strlcpy is declared" >&5
19491 $as_echo_n "checking whether strlcpy is declared... " >&6; }
19492 if test "${ac_cv_have_decl_strlcpy+set}" = set; then
19493   $as_echo_n "(cached) " >&6
19494 else
19495   cat >conftest.$ac_ext <<_ACEOF
19496 /* confdefs.h.  */
19497 _ACEOF
19498 cat confdefs.h >>conftest.$ac_ext
19499 cat >>conftest.$ac_ext <<_ACEOF
19500 /* end confdefs.h.  */
19501 $ac_includes_default
19502 int
19503 main ()
19504 {
19505 #ifndef strlcpy
19506   (void) strlcpy;
19507 #endif
19508
19509   ;
19510   return 0;
19511 }
19512 _ACEOF
19513 rm -f conftest.$ac_objext
19514 if { (ac_try="$ac_compile"
19515 case "(($ac_try" in
19516   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19517   *) ac_try_echo=$ac_try;;
19518 esac
19519 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19520 $as_echo "$ac_try_echo") >&5
19521   (eval "$ac_compile") 2>conftest.er1
19522   ac_status=$?
19523   grep -v '^ *+' conftest.er1 >conftest.err
19524   rm -f conftest.er1
19525   cat conftest.err >&5
19526   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19527   (exit $ac_status); } && {
19528          test -z "$ac_c_werror_flag" ||
19529          test ! -s conftest.err
19530        } && test -s conftest.$ac_objext; then
19531   ac_cv_have_decl_strlcpy=yes
19532 else
19533   $as_echo "$as_me: failed program was:" >&5
19534 sed 's/^/| /' conftest.$ac_ext >&5
19535
19536         ac_cv_have_decl_strlcpy=no
19537 fi
19538
19539 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19540 fi
19541 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcpy" >&5
19542 $as_echo "$ac_cv_have_decl_strlcpy" >&6; }
19543 if test "x$ac_cv_have_decl_strlcpy" = x""yes; then
19544
19545 cat >>confdefs.h <<_ACEOF
19546 #define HAVE_DECL_STRLCPY 1
19547 _ACEOF
19548
19549
19550 else
19551   cat >>confdefs.h <<_ACEOF
19552 #define HAVE_DECL_STRLCPY 0
19553 _ACEOF
19554
19555
19556 fi
19557
19558
19559 # This is probably only present on Darwin, but may as well check always
19560 { $as_echo "$as_me:$LINENO: checking whether F_FULLFSYNC is declared" >&5
19561 $as_echo_n "checking whether F_FULLFSYNC is declared... " >&6; }
19562 if test "${ac_cv_have_decl_F_FULLFSYNC+set}" = set; then
19563   $as_echo_n "(cached) " >&6
19564 else
19565   cat >conftest.$ac_ext <<_ACEOF
19566 /* confdefs.h.  */
19567 _ACEOF
19568 cat confdefs.h >>conftest.$ac_ext
19569 cat >>conftest.$ac_ext <<_ACEOF
19570 /* end confdefs.h.  */
19571 #include <fcntl.h>
19572
19573 int
19574 main ()
19575 {
19576 #ifndef F_FULLFSYNC
19577   (void) F_FULLFSYNC;
19578 #endif
19579
19580   ;
19581   return 0;
19582 }
19583 _ACEOF
19584 rm -f conftest.$ac_objext
19585 if { (ac_try="$ac_compile"
19586 case "(($ac_try" in
19587   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19588   *) ac_try_echo=$ac_try;;
19589 esac
19590 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19591 $as_echo "$ac_try_echo") >&5
19592   (eval "$ac_compile") 2>conftest.er1
19593   ac_status=$?
19594   grep -v '^ *+' conftest.er1 >conftest.err
19595   rm -f conftest.er1
19596   cat conftest.err >&5
19597   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19598   (exit $ac_status); } && {
19599          test -z "$ac_c_werror_flag" ||
19600          test ! -s conftest.err
19601        } && test -s conftest.$ac_objext; then
19602   ac_cv_have_decl_F_FULLFSYNC=yes
19603 else
19604   $as_echo "$as_me: failed program was:" >&5
19605 sed 's/^/| /' conftest.$ac_ext >&5
19606
19607         ac_cv_have_decl_F_FULLFSYNC=no
19608 fi
19609
19610 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19611 fi
19612 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_F_FULLFSYNC" >&5
19613 $as_echo "$ac_cv_have_decl_F_FULLFSYNC" >&6; }
19614 if test "x$ac_cv_have_decl_F_FULLFSYNC" = x""yes; then
19615
19616 cat >>confdefs.h <<_ACEOF
19617 #define HAVE_DECL_F_FULLFSYNC 1
19618 _ACEOF
19619
19620
19621 else
19622   cat >>confdefs.h <<_ACEOF
19623 #define HAVE_DECL_F_FULLFSYNC 0
19624 _ACEOF
19625
19626
19627 fi
19628
19629
19630
19631 HAVE_IPV6=no
19632 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
19633 $as_echo_n "checking for struct sockaddr_in6... " >&6; }
19634 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
19635   $as_echo_n "(cached) " >&6
19636 else
19637   ac_cv_type_struct_sockaddr_in6=no
19638 cat >conftest.$ac_ext <<_ACEOF
19639 /* confdefs.h.  */
19640 _ACEOF
19641 cat confdefs.h >>conftest.$ac_ext
19642 cat >>conftest.$ac_ext <<_ACEOF
19643 /* end confdefs.h.  */
19644 $ac_includes_default
19645 #include <netinet/in.h>
19646
19647 int
19648 main ()
19649 {
19650 if (sizeof (struct sockaddr_in6))
19651        return 0;
19652   ;
19653   return 0;
19654 }
19655 _ACEOF
19656 rm -f conftest.$ac_objext
19657 if { (ac_try="$ac_compile"
19658 case "(($ac_try" in
19659   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19660   *) ac_try_echo=$ac_try;;
19661 esac
19662 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19663 $as_echo "$ac_try_echo") >&5
19664   (eval "$ac_compile") 2>conftest.er1
19665   ac_status=$?
19666   grep -v '^ *+' conftest.er1 >conftest.err
19667   rm -f conftest.er1
19668   cat conftest.err >&5
19669   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19670   (exit $ac_status); } && {
19671          test -z "$ac_c_werror_flag" ||
19672          test ! -s conftest.err
19673        } && test -s conftest.$ac_objext; then
19674   cat >conftest.$ac_ext <<_ACEOF
19675 /* confdefs.h.  */
19676 _ACEOF
19677 cat confdefs.h >>conftest.$ac_ext
19678 cat >>conftest.$ac_ext <<_ACEOF
19679 /* end confdefs.h.  */
19680 $ac_includes_default
19681 #include <netinet/in.h>
19682
19683 int
19684 main ()
19685 {
19686 if (sizeof ((struct sockaddr_in6)))
19687           return 0;
19688   ;
19689   return 0;
19690 }
19691 _ACEOF
19692 rm -f conftest.$ac_objext
19693 if { (ac_try="$ac_compile"
19694 case "(($ac_try" in
19695   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19696   *) ac_try_echo=$ac_try;;
19697 esac
19698 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19699 $as_echo "$ac_try_echo") >&5
19700   (eval "$ac_compile") 2>conftest.er1
19701   ac_status=$?
19702   grep -v '^ *+' conftest.er1 >conftest.err
19703   rm -f conftest.er1
19704   cat conftest.err >&5
19705   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19706   (exit $ac_status); } && {
19707          test -z "$ac_c_werror_flag" ||
19708          test ! -s conftest.err
19709        } && test -s conftest.$ac_objext; then
19710   :
19711 else
19712   $as_echo "$as_me: failed program was:" >&5
19713 sed 's/^/| /' conftest.$ac_ext >&5
19714
19715         ac_cv_type_struct_sockaddr_in6=yes
19716 fi
19717
19718 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19719 else
19720   $as_echo "$as_me: failed program was:" >&5
19721 sed 's/^/| /' conftest.$ac_ext >&5
19722
19723
19724 fi
19725
19726 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19727 fi
19728 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
19729 $as_echo "$ac_cv_type_struct_sockaddr_in6" >&6; }
19730 if test "x$ac_cv_type_struct_sockaddr_in6" = x""yes; then
19731
19732 cat >>confdefs.h <<\_ACEOF
19733 #define HAVE_IPV6 1
19734 _ACEOF
19735
19736          HAVE_IPV6=yes
19737 fi
19738
19739
19740
19741 { $as_echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
19742 $as_echo_n "checking for PS_STRINGS... " >&6; }
19743 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
19744   $as_echo_n "(cached) " >&6
19745 else
19746   cat >conftest.$ac_ext <<_ACEOF
19747 /* confdefs.h.  */
19748 _ACEOF
19749 cat confdefs.h >>conftest.$ac_ext
19750 cat >>conftest.$ac_ext <<_ACEOF
19751 /* end confdefs.h.  */
19752 #include <machine/vmparam.h>
19753 #include <sys/exec.h>
19754
19755 int
19756 main ()
19757 {
19758 PS_STRINGS->ps_nargvstr = 1;
19759 PS_STRINGS->ps_argvstr = "foo";
19760   ;
19761   return 0;
19762 }
19763 _ACEOF
19764 rm -f conftest.$ac_objext conftest$ac_exeext
19765 if { (ac_try="$ac_link"
19766 case "(($ac_try" in
19767   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19768   *) ac_try_echo=$ac_try;;
19769 esac
19770 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19771 $as_echo "$ac_try_echo") >&5
19772   (eval "$ac_link") 2>conftest.er1
19773   ac_status=$?
19774   grep -v '^ *+' conftest.er1 >conftest.err
19775   rm -f conftest.er1
19776   cat conftest.err >&5
19777   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19778   (exit $ac_status); } && {
19779          test -z "$ac_c_werror_flag" ||
19780          test ! -s conftest.err
19781        } && test -s conftest$ac_exeext && {
19782          test "$cross_compiling" = yes ||
19783          $as_test_x conftest$ac_exeext
19784        }; then
19785   pgac_cv_var_PS_STRINGS=yes
19786 else
19787   $as_echo "$as_me: failed program was:" >&5
19788 sed 's/^/| /' conftest.$ac_ext >&5
19789
19790         pgac_cv_var_PS_STRINGS=no
19791 fi
19792
19793 rm -rf conftest.dSYM
19794 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19795       conftest$ac_exeext conftest.$ac_ext
19796 fi
19797 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
19798 $as_echo "$pgac_cv_var_PS_STRINGS" >&6; }
19799 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
19800
19801 cat >>confdefs.h <<\_ACEOF
19802 #define HAVE_PS_STRINGS /**/
19803 _ACEOF
19804
19805 fi
19806
19807
19808 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
19809 # is missing.  Yes, there are machines that have only one.  We may
19810 # also decide to use snprintf.c if snprintf() is present but does not
19811 # have all the features we need --- see below.
19812
19813 if test "$PORTNAME" = "win32"; then
19814   # Win32 gets snprintf.c built unconditionally.
19815   #
19816   # To properly translate all NLS languages strings, we must support the
19817   # *printf() %$ format, which allows *printf() arguments to be selected
19818   # by position in the translated string.
19819   #
19820   # libintl versions < 0.13 use the native *printf() functions, and Win32
19821   # *printf() doesn't understand %$, so we must use our /port versions,
19822   # which do understand %$. libintl versions >= 0.13 include their own
19823   # *printf versions on Win32.  The libintl 0.13 release note text is:
19824   #
19825   #   C format strings with positions, as they arise when a translator
19826   #   needs to reorder a sentence, are now supported on all platforms.
19827   #   On those few platforms (NetBSD and Woe32) for which the native
19828   #   printf()/fprintf()/... functions don't support such format
19829   #   strings, replacements are provided through <libintl.h>.
19830   #
19831   # We could use libintl >= 0.13's *printf() if we were sure that we had
19832   # a litint >= 0.13 at runtime, but seeing that there is no clean way
19833   # to guarantee that, it is best to just use our own, so we are sure to
19834   # get %$ support. In include/port.h we disable the *printf() macros
19835   # that might have been defined by libintl.
19836   #
19837   # We do this unconditionally whether NLS is used or not so we are sure
19838   # that all Win32 libraries and binaries behave the same.
19839   pgac_need_repl_snprintf=yes
19840 else
19841   pgac_need_repl_snprintf=no
19842
19843 for ac_func in snprintf
19844 do
19845 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19846 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19847 $as_echo_n "checking for $ac_func... " >&6; }
19848 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19849   $as_echo_n "(cached) " >&6
19850 else
19851   cat >conftest.$ac_ext <<_ACEOF
19852 /* confdefs.h.  */
19853 _ACEOF
19854 cat confdefs.h >>conftest.$ac_ext
19855 cat >>conftest.$ac_ext <<_ACEOF
19856 /* end confdefs.h.  */
19857 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19858    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19859 #define $ac_func innocuous_$ac_func
19860
19861 /* System header to define __stub macros and hopefully few prototypes,
19862     which can conflict with char $ac_func (); below.
19863     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19864     <limits.h> exists even on freestanding compilers.  */
19865
19866 #ifdef __STDC__
19867 # include <limits.h>
19868 #else
19869 # include <assert.h>
19870 #endif
19871
19872 #undef $ac_func
19873
19874 /* Override any GCC internal prototype to avoid an error.
19875    Use char because int might match the return type of a GCC
19876    builtin and then its argument prototype would still apply.  */
19877 #ifdef __cplusplus
19878 extern "C"
19879 #endif
19880 char $ac_func ();
19881 /* The GNU C library defines this for functions which it implements
19882     to always fail with ENOSYS.  Some functions are actually named
19883     something starting with __ and the normal name is an alias.  */
19884 #if defined __stub_$ac_func || defined __stub___$ac_func
19885 choke me
19886 #endif
19887
19888 int
19889 main ()
19890 {
19891 return $ac_func ();
19892   ;
19893   return 0;
19894 }
19895 _ACEOF
19896 rm -f conftest.$ac_objext conftest$ac_exeext
19897 if { (ac_try="$ac_link"
19898 case "(($ac_try" in
19899   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19900   *) ac_try_echo=$ac_try;;
19901 esac
19902 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19903 $as_echo "$ac_try_echo") >&5
19904   (eval "$ac_link") 2>conftest.er1
19905   ac_status=$?
19906   grep -v '^ *+' conftest.er1 >conftest.err
19907   rm -f conftest.er1
19908   cat conftest.err >&5
19909   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19910   (exit $ac_status); } && {
19911          test -z "$ac_c_werror_flag" ||
19912          test ! -s conftest.err
19913        } && test -s conftest$ac_exeext && {
19914          test "$cross_compiling" = yes ||
19915          $as_test_x conftest$ac_exeext
19916        }; then
19917   eval "$as_ac_var=yes"
19918 else
19919   $as_echo "$as_me: failed program was:" >&5
19920 sed 's/^/| /' conftest.$ac_ext >&5
19921
19922         eval "$as_ac_var=no"
19923 fi
19924
19925 rm -rf conftest.dSYM
19926 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19927       conftest$ac_exeext conftest.$ac_ext
19928 fi
19929 ac_res=`eval 'as_val=${'$as_ac_var'}
19930                  $as_echo "$as_val"'`
19931                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19932 $as_echo "$ac_res" >&6; }
19933 as_val=`eval 'as_val=${'$as_ac_var'}
19934                  $as_echo "$as_val"'`
19935    if test "x$as_val" = x""yes; then
19936   cat >>confdefs.h <<_ACEOF
19937 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19938 _ACEOF
19939
19940 else
19941   pgac_need_repl_snprintf=yes
19942 fi
19943 done
19944
19945
19946 for ac_func in vsnprintf
19947 do
19948 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19949 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19950 $as_echo_n "checking for $ac_func... " >&6; }
19951 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19952   $as_echo_n "(cached) " >&6
19953 else
19954   cat >conftest.$ac_ext <<_ACEOF
19955 /* confdefs.h.  */
19956 _ACEOF
19957 cat confdefs.h >>conftest.$ac_ext
19958 cat >>conftest.$ac_ext <<_ACEOF
19959 /* end confdefs.h.  */
19960 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19961    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19962 #define $ac_func innocuous_$ac_func
19963
19964 /* System header to define __stub macros and hopefully few prototypes,
19965     which can conflict with char $ac_func (); below.
19966     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19967     <limits.h> exists even on freestanding compilers.  */
19968
19969 #ifdef __STDC__
19970 # include <limits.h>
19971 #else
19972 # include <assert.h>
19973 #endif
19974
19975 #undef $ac_func
19976
19977 /* Override any GCC internal prototype to avoid an error.
19978    Use char because int might match the return type of a GCC
19979    builtin and then its argument prototype would still apply.  */
19980 #ifdef __cplusplus
19981 extern "C"
19982 #endif
19983 char $ac_func ();
19984 /* The GNU C library defines this for functions which it implements
19985     to always fail with ENOSYS.  Some functions are actually named
19986     something starting with __ and the normal name is an alias.  */
19987 #if defined __stub_$ac_func || defined __stub___$ac_func
19988 choke me
19989 #endif
19990
19991 int
19992 main ()
19993 {
19994 return $ac_func ();
19995   ;
19996   return 0;
19997 }
19998 _ACEOF
19999 rm -f conftest.$ac_objext conftest$ac_exeext
20000 if { (ac_try="$ac_link"
20001 case "(($ac_try" in
20002   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20003   *) ac_try_echo=$ac_try;;
20004 esac
20005 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20006 $as_echo "$ac_try_echo") >&5
20007   (eval "$ac_link") 2>conftest.er1
20008   ac_status=$?
20009   grep -v '^ *+' conftest.er1 >conftest.err
20010   rm -f conftest.er1
20011   cat conftest.err >&5
20012   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20013   (exit $ac_status); } && {
20014          test -z "$ac_c_werror_flag" ||
20015          test ! -s conftest.err
20016        } && test -s conftest$ac_exeext && {
20017          test "$cross_compiling" = yes ||
20018          $as_test_x conftest$ac_exeext
20019        }; then
20020   eval "$as_ac_var=yes"
20021 else
20022   $as_echo "$as_me: failed program was:" >&5
20023 sed 's/^/| /' conftest.$ac_ext >&5
20024
20025         eval "$as_ac_var=no"
20026 fi
20027
20028 rm -rf conftest.dSYM
20029 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20030       conftest$ac_exeext conftest.$ac_ext
20031 fi
20032 ac_res=`eval 'as_val=${'$as_ac_var'}
20033                  $as_echo "$as_val"'`
20034                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20035 $as_echo "$ac_res" >&6; }
20036 as_val=`eval 'as_val=${'$as_ac_var'}
20037                  $as_echo "$as_val"'`
20038    if test "x$as_val" = x""yes; then
20039   cat >>confdefs.h <<_ACEOF
20040 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20041 _ACEOF
20042
20043 else
20044   pgac_need_repl_snprintf=yes
20045 fi
20046 done
20047
20048 fi
20049
20050
20051 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
20052 # include/c.h will provide declarations.  Note this is a separate test
20053 # from whether the functions exist in the C library --- there are
20054 # systems that have the functions but don't bother to declare them :-(
20055
20056 { $as_echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
20057 $as_echo_n "checking whether snprintf is declared... " >&6; }
20058 if test "${ac_cv_have_decl_snprintf+set}" = set; then
20059   $as_echo_n "(cached) " >&6
20060 else
20061   cat >conftest.$ac_ext <<_ACEOF
20062 /* confdefs.h.  */
20063 _ACEOF
20064 cat confdefs.h >>conftest.$ac_ext
20065 cat >>conftest.$ac_ext <<_ACEOF
20066 /* end confdefs.h.  */
20067 $ac_includes_default
20068 int
20069 main ()
20070 {
20071 #ifndef snprintf
20072   (void) snprintf;
20073 #endif
20074
20075   ;
20076   return 0;
20077 }
20078 _ACEOF
20079 rm -f conftest.$ac_objext
20080 if { (ac_try="$ac_compile"
20081 case "(($ac_try" in
20082   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20083   *) ac_try_echo=$ac_try;;
20084 esac
20085 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20086 $as_echo "$ac_try_echo") >&5
20087   (eval "$ac_compile") 2>conftest.er1
20088   ac_status=$?
20089   grep -v '^ *+' conftest.er1 >conftest.err
20090   rm -f conftest.er1
20091   cat conftest.err >&5
20092   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20093   (exit $ac_status); } && {
20094          test -z "$ac_c_werror_flag" ||
20095          test ! -s conftest.err
20096        } && test -s conftest.$ac_objext; then
20097   ac_cv_have_decl_snprintf=yes
20098 else
20099   $as_echo "$as_me: failed program was:" >&5
20100 sed 's/^/| /' conftest.$ac_ext >&5
20101
20102         ac_cv_have_decl_snprintf=no
20103 fi
20104
20105 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20106 fi
20107 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
20108 $as_echo "$ac_cv_have_decl_snprintf" >&6; }
20109 if test "x$ac_cv_have_decl_snprintf" = x""yes; then
20110
20111 cat >>confdefs.h <<_ACEOF
20112 #define HAVE_DECL_SNPRINTF 1
20113 _ACEOF
20114
20115
20116 else
20117   cat >>confdefs.h <<_ACEOF
20118 #define HAVE_DECL_SNPRINTF 0
20119 _ACEOF
20120
20121
20122 fi
20123 { $as_echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
20124 $as_echo_n "checking whether vsnprintf is declared... " >&6; }
20125 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
20126   $as_echo_n "(cached) " >&6
20127 else
20128   cat >conftest.$ac_ext <<_ACEOF
20129 /* confdefs.h.  */
20130 _ACEOF
20131 cat confdefs.h >>conftest.$ac_ext
20132 cat >>conftest.$ac_ext <<_ACEOF
20133 /* end confdefs.h.  */
20134 $ac_includes_default
20135 int
20136 main ()
20137 {
20138 #ifndef vsnprintf
20139   (void) vsnprintf;
20140 #endif
20141
20142   ;
20143   return 0;
20144 }
20145 _ACEOF
20146 rm -f conftest.$ac_objext
20147 if { (ac_try="$ac_compile"
20148 case "(($ac_try" in
20149   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20150   *) ac_try_echo=$ac_try;;
20151 esac
20152 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20153 $as_echo "$ac_try_echo") >&5
20154   (eval "$ac_compile") 2>conftest.er1
20155   ac_status=$?
20156   grep -v '^ *+' conftest.er1 >conftest.err
20157   rm -f conftest.er1
20158   cat conftest.err >&5
20159   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20160   (exit $ac_status); } && {
20161          test -z "$ac_c_werror_flag" ||
20162          test ! -s conftest.err
20163        } && test -s conftest.$ac_objext; then
20164   ac_cv_have_decl_vsnprintf=yes
20165 else
20166   $as_echo "$as_me: failed program was:" >&5
20167 sed 's/^/| /' conftest.$ac_ext >&5
20168
20169         ac_cv_have_decl_vsnprintf=no
20170 fi
20171
20172 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20173 fi
20174 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
20175 $as_echo "$ac_cv_have_decl_vsnprintf" >&6; }
20176 if test "x$ac_cv_have_decl_vsnprintf" = x""yes; then
20177
20178 cat >>confdefs.h <<_ACEOF
20179 #define HAVE_DECL_VSNPRINTF 1
20180 _ACEOF
20181
20182
20183 else
20184   cat >>confdefs.h <<_ACEOF
20185 #define HAVE_DECL_VSNPRINTF 0
20186 _ACEOF
20187
20188
20189 fi
20190
20191
20192
20193
20194 { $as_echo "$as_me:$LINENO: checking for isinf" >&5
20195 $as_echo_n "checking for isinf... " >&6; }
20196 if test "${ac_cv_func_isinf+set}" = set; then
20197   $as_echo_n "(cached) " >&6
20198 else
20199   cat >conftest.$ac_ext <<_ACEOF
20200 /* confdefs.h.  */
20201 _ACEOF
20202 cat confdefs.h >>conftest.$ac_ext
20203 cat >>conftest.$ac_ext <<_ACEOF
20204 /* end confdefs.h.  */
20205
20206 #include <math.h>
20207 double glob_double;
20208
20209 int
20210 main ()
20211 {
20212 return isinf(glob_double) ? 0 : 1;
20213   ;
20214   return 0;
20215 }
20216 _ACEOF
20217 rm -f conftest.$ac_objext conftest$ac_exeext
20218 if { (ac_try="$ac_link"
20219 case "(($ac_try" in
20220   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20221   *) ac_try_echo=$ac_try;;
20222 esac
20223 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20224 $as_echo "$ac_try_echo") >&5
20225   (eval "$ac_link") 2>conftest.er1
20226   ac_status=$?
20227   grep -v '^ *+' conftest.er1 >conftest.err
20228   rm -f conftest.er1
20229   cat conftest.err >&5
20230   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20231   (exit $ac_status); } && {
20232          test -z "$ac_c_werror_flag" ||
20233          test ! -s conftest.err
20234        } && test -s conftest$ac_exeext && {
20235          test "$cross_compiling" = yes ||
20236          $as_test_x conftest$ac_exeext
20237        }; then
20238   ac_cv_func_isinf=yes
20239 else
20240   $as_echo "$as_me: failed program was:" >&5
20241 sed 's/^/| /' conftest.$ac_ext >&5
20242
20243         ac_cv_func_isinf=no
20244 fi
20245
20246 rm -rf conftest.dSYM
20247 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20248       conftest$ac_exeext conftest.$ac_ext
20249 fi
20250 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
20251 $as_echo "$ac_cv_func_isinf" >&6; }
20252
20253 if test $ac_cv_func_isinf = yes ; then
20254
20255 cat >>confdefs.h <<\_ACEOF
20256 #define HAVE_ISINF 1
20257 _ACEOF
20258
20259 else
20260   case " $LIBOBJS " in
20261   *" isinf.$ac_objext "* ) ;;
20262   *) LIBOBJS="$LIBOBJS isinf.$ac_objext"
20263  ;;
20264 esac
20265
20266   # Look for a way to implement a substitute for isinf()
20267
20268
20269
20270
20271 for ac_func in fpclass fp_class fp_class_d class
20272 do
20273 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20274 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20275 $as_echo_n "checking for $ac_func... " >&6; }
20276 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20277   $as_echo_n "(cached) " >&6
20278 else
20279   cat >conftest.$ac_ext <<_ACEOF
20280 /* confdefs.h.  */
20281 _ACEOF
20282 cat confdefs.h >>conftest.$ac_ext
20283 cat >>conftest.$ac_ext <<_ACEOF
20284 /* end confdefs.h.  */
20285 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20286    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20287 #define $ac_func innocuous_$ac_func
20288
20289 /* System header to define __stub macros and hopefully few prototypes,
20290     which can conflict with char $ac_func (); below.
20291     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20292     <limits.h> exists even on freestanding compilers.  */
20293
20294 #ifdef __STDC__
20295 # include <limits.h>
20296 #else
20297 # include <assert.h>
20298 #endif
20299
20300 #undef $ac_func
20301
20302 /* Override any GCC internal prototype to avoid an error.
20303    Use char because int might match the return type of a GCC
20304    builtin and then its argument prototype would still apply.  */
20305 #ifdef __cplusplus
20306 extern "C"
20307 #endif
20308 char $ac_func ();
20309 /* The GNU C library defines this for functions which it implements
20310     to always fail with ENOSYS.  Some functions are actually named
20311     something starting with __ and the normal name is an alias.  */
20312 #if defined __stub_$ac_func || defined __stub___$ac_func
20313 choke me
20314 #endif
20315
20316 int
20317 main ()
20318 {
20319 return $ac_func ();
20320   ;
20321   return 0;
20322 }
20323 _ACEOF
20324 rm -f conftest.$ac_objext conftest$ac_exeext
20325 if { (ac_try="$ac_link"
20326 case "(($ac_try" in
20327   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20328   *) ac_try_echo=$ac_try;;
20329 esac
20330 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20331 $as_echo "$ac_try_echo") >&5
20332   (eval "$ac_link") 2>conftest.er1
20333   ac_status=$?
20334   grep -v '^ *+' conftest.er1 >conftest.err
20335   rm -f conftest.er1
20336   cat conftest.err >&5
20337   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20338   (exit $ac_status); } && {
20339          test -z "$ac_c_werror_flag" ||
20340          test ! -s conftest.err
20341        } && test -s conftest$ac_exeext && {
20342          test "$cross_compiling" = yes ||
20343          $as_test_x conftest$ac_exeext
20344        }; then
20345   eval "$as_ac_var=yes"
20346 else
20347   $as_echo "$as_me: failed program was:" >&5
20348 sed 's/^/| /' conftest.$ac_ext >&5
20349
20350         eval "$as_ac_var=no"
20351 fi
20352
20353 rm -rf conftest.dSYM
20354 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20355       conftest$ac_exeext conftest.$ac_ext
20356 fi
20357 ac_res=`eval 'as_val=${'$as_ac_var'}
20358                  $as_echo "$as_val"'`
20359                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20360 $as_echo "$ac_res" >&6; }
20361 as_val=`eval 'as_val=${'$as_ac_var'}
20362                  $as_echo "$as_val"'`
20363    if test "x$as_val" = x""yes; then
20364   cat >>confdefs.h <<_ACEOF
20365 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20366 _ACEOF
20367  break
20368 fi
20369 done
20370
20371 fi
20372
20373 # Some versions of libedit contain strlcpy(); so disregard that library while
20374 # checking for these standard libc functions.
20375 pgac_save_LIBS="$LIBS"
20376 LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
20377
20378
20379
20380
20381
20382
20383
20384
20385
20386
20387
20388
20389
20390
20391
20392 for ac_func in crypt erand48 getopt getrusage inet_aton random rint srandom strdup strerror strlcat strlcpy strtol strtoul
20393 do
20394 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20395 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20396 $as_echo_n "checking for $ac_func... " >&6; }
20397 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20398   $as_echo_n "(cached) " >&6
20399 else
20400   cat >conftest.$ac_ext <<_ACEOF
20401 /* confdefs.h.  */
20402 _ACEOF
20403 cat confdefs.h >>conftest.$ac_ext
20404 cat >>conftest.$ac_ext <<_ACEOF
20405 /* end confdefs.h.  */
20406 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20407    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20408 #define $ac_func innocuous_$ac_func
20409
20410 /* System header to define __stub macros and hopefully few prototypes,
20411     which can conflict with char $ac_func (); below.
20412     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20413     <limits.h> exists even on freestanding compilers.  */
20414
20415 #ifdef __STDC__
20416 # include <limits.h>
20417 #else
20418 # include <assert.h>
20419 #endif
20420
20421 #undef $ac_func
20422
20423 /* Override any GCC internal prototype to avoid an error.
20424    Use char because int might match the return type of a GCC
20425    builtin and then its argument prototype would still apply.  */
20426 #ifdef __cplusplus
20427 extern "C"
20428 #endif
20429 char $ac_func ();
20430 /* The GNU C library defines this for functions which it implements
20431     to always fail with ENOSYS.  Some functions are actually named
20432     something starting with __ and the normal name is an alias.  */
20433 #if defined __stub_$ac_func || defined __stub___$ac_func
20434 choke me
20435 #endif
20436
20437 int
20438 main ()
20439 {
20440 return $ac_func ();
20441   ;
20442   return 0;
20443 }
20444 _ACEOF
20445 rm -f conftest.$ac_objext conftest$ac_exeext
20446 if { (ac_try="$ac_link"
20447 case "(($ac_try" in
20448   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20449   *) ac_try_echo=$ac_try;;
20450 esac
20451 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20452 $as_echo "$ac_try_echo") >&5
20453   (eval "$ac_link") 2>conftest.er1
20454   ac_status=$?
20455   grep -v '^ *+' conftest.er1 >conftest.err
20456   rm -f conftest.er1
20457   cat conftest.err >&5
20458   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20459   (exit $ac_status); } && {
20460          test -z "$ac_c_werror_flag" ||
20461          test ! -s conftest.err
20462        } && test -s conftest$ac_exeext && {
20463          test "$cross_compiling" = yes ||
20464          $as_test_x conftest$ac_exeext
20465        }; then
20466   eval "$as_ac_var=yes"
20467 else
20468   $as_echo "$as_me: failed program was:" >&5
20469 sed 's/^/| /' conftest.$ac_ext >&5
20470
20471         eval "$as_ac_var=no"
20472 fi
20473
20474 rm -rf conftest.dSYM
20475 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20476       conftest$ac_exeext conftest.$ac_ext
20477 fi
20478 ac_res=`eval 'as_val=${'$as_ac_var'}
20479                  $as_echo "$as_val"'`
20480                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20481 $as_echo "$ac_res" >&6; }
20482 as_val=`eval 'as_val=${'$as_ac_var'}
20483                  $as_echo "$as_val"'`
20484    if test "x$as_val" = x""yes; then
20485   cat >>confdefs.h <<_ACEOF
20486 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20487 _ACEOF
20488
20489 else
20490   case " $LIBOBJS " in
20491   *" $ac_func.$ac_objext "* ) ;;
20492   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20493  ;;
20494 esac
20495
20496 fi
20497 done
20498
20499
20500
20501 case $host_os in
20502
20503         # Windows uses a specialised env handler
20504         mingw*)
20505
20506 cat >>confdefs.h <<\_ACEOF
20507 #define HAVE_UNSETENV 1
20508 _ACEOF
20509
20510                 ac_cv_func_unsetenv=yes;;
20511         *)
20512
20513 for ac_func in unsetenv
20514 do
20515 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20516 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20517 $as_echo_n "checking for $ac_func... " >&6; }
20518 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20519   $as_echo_n "(cached) " >&6
20520 else
20521   cat >conftest.$ac_ext <<_ACEOF
20522 /* confdefs.h.  */
20523 _ACEOF
20524 cat confdefs.h >>conftest.$ac_ext
20525 cat >>conftest.$ac_ext <<_ACEOF
20526 /* end confdefs.h.  */
20527 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20528    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20529 #define $ac_func innocuous_$ac_func
20530
20531 /* System header to define __stub macros and hopefully few prototypes,
20532     which can conflict with char $ac_func (); below.
20533     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20534     <limits.h> exists even on freestanding compilers.  */
20535
20536 #ifdef __STDC__
20537 # include <limits.h>
20538 #else
20539 # include <assert.h>
20540 #endif
20541
20542 #undef $ac_func
20543
20544 /* Override any GCC internal prototype to avoid an error.
20545    Use char because int might match the return type of a GCC
20546    builtin and then its argument prototype would still apply.  */
20547 #ifdef __cplusplus
20548 extern "C"
20549 #endif
20550 char $ac_func ();
20551 /* The GNU C library defines this for functions which it implements
20552     to always fail with ENOSYS.  Some functions are actually named
20553     something starting with __ and the normal name is an alias.  */
20554 #if defined __stub_$ac_func || defined __stub___$ac_func
20555 choke me
20556 #endif
20557
20558 int
20559 main ()
20560 {
20561 return $ac_func ();
20562   ;
20563   return 0;
20564 }
20565 _ACEOF
20566 rm -f conftest.$ac_objext conftest$ac_exeext
20567 if { (ac_try="$ac_link"
20568 case "(($ac_try" in
20569   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20570   *) ac_try_echo=$ac_try;;
20571 esac
20572 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20573 $as_echo "$ac_try_echo") >&5
20574   (eval "$ac_link") 2>conftest.er1
20575   ac_status=$?
20576   grep -v '^ *+' conftest.er1 >conftest.err
20577   rm -f conftest.er1
20578   cat conftest.err >&5
20579   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20580   (exit $ac_status); } && {
20581          test -z "$ac_c_werror_flag" ||
20582          test ! -s conftest.err
20583        } && test -s conftest$ac_exeext && {
20584          test "$cross_compiling" = yes ||
20585          $as_test_x conftest$ac_exeext
20586        }; then
20587   eval "$as_ac_var=yes"
20588 else
20589   $as_echo "$as_me: failed program was:" >&5
20590 sed 's/^/| /' conftest.$ac_ext >&5
20591
20592         eval "$as_ac_var=no"
20593 fi
20594
20595 rm -rf conftest.dSYM
20596 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20597       conftest$ac_exeext conftest.$ac_ext
20598 fi
20599 ac_res=`eval 'as_val=${'$as_ac_var'}
20600                  $as_echo "$as_val"'`
20601                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20602 $as_echo "$ac_res" >&6; }
20603 as_val=`eval 'as_val=${'$as_ac_var'}
20604                  $as_echo "$as_val"'`
20605    if test "x$as_val" = x""yes; then
20606   cat >>confdefs.h <<_ACEOF
20607 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20608 _ACEOF
20609
20610 else
20611   case " $LIBOBJS " in
20612   *" $ac_func.$ac_objext "* ) ;;
20613   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20614  ;;
20615 esac
20616
20617 fi
20618 done
20619
20620
20621                 ;;
20622 esac
20623
20624
20625 LIBS="$pgac_save_LIBS"
20626
20627 # System's version of getaddrinfo(), if any, may be used only if we found
20628 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
20629 # (Note: the AC_REPLACE_FUNCS probe fails on Windows, where the available
20630 # versions of getaddrinfo don't follow normal C call protocol.  This is OK
20631 # because we want to use our own getaddrinfo.c on Windows anyway.)
20632 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
20633
20634 for ac_func in getaddrinfo
20635 do
20636 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20637 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20638 $as_echo_n "checking for $ac_func... " >&6; }
20639 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20640   $as_echo_n "(cached) " >&6
20641 else
20642   cat >conftest.$ac_ext <<_ACEOF
20643 /* confdefs.h.  */
20644 _ACEOF
20645 cat confdefs.h >>conftest.$ac_ext
20646 cat >>conftest.$ac_ext <<_ACEOF
20647 /* end confdefs.h.  */
20648 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20649    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20650 #define $ac_func innocuous_$ac_func
20651
20652 /* System header to define __stub macros and hopefully few prototypes,
20653     which can conflict with char $ac_func (); below.
20654     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20655     <limits.h> exists even on freestanding compilers.  */
20656
20657 #ifdef __STDC__
20658 # include <limits.h>
20659 #else
20660 # include <assert.h>
20661 #endif
20662
20663 #undef $ac_func
20664
20665 /* Override any GCC internal prototype to avoid an error.
20666    Use char because int might match the return type of a GCC
20667    builtin and then its argument prototype would still apply.  */
20668 #ifdef __cplusplus
20669 extern "C"
20670 #endif
20671 char $ac_func ();
20672 /* The GNU C library defines this for functions which it implements
20673     to always fail with ENOSYS.  Some functions are actually named
20674     something starting with __ and the normal name is an alias.  */
20675 #if defined __stub_$ac_func || defined __stub___$ac_func
20676 choke me
20677 #endif
20678
20679 int
20680 main ()
20681 {
20682 return $ac_func ();
20683   ;
20684   return 0;
20685 }
20686 _ACEOF
20687 rm -f conftest.$ac_objext conftest$ac_exeext
20688 if { (ac_try="$ac_link"
20689 case "(($ac_try" in
20690   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20691   *) ac_try_echo=$ac_try;;
20692 esac
20693 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20694 $as_echo "$ac_try_echo") >&5
20695   (eval "$ac_link") 2>conftest.er1
20696   ac_status=$?
20697   grep -v '^ *+' conftest.er1 >conftest.err
20698   rm -f conftest.er1
20699   cat conftest.err >&5
20700   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20701   (exit $ac_status); } && {
20702          test -z "$ac_c_werror_flag" ||
20703          test ! -s conftest.err
20704        } && test -s conftest$ac_exeext && {
20705          test "$cross_compiling" = yes ||
20706          $as_test_x conftest$ac_exeext
20707        }; then
20708   eval "$as_ac_var=yes"
20709 else
20710   $as_echo "$as_me: failed program was:" >&5
20711 sed 's/^/| /' conftest.$ac_ext >&5
20712
20713         eval "$as_ac_var=no"
20714 fi
20715
20716 rm -rf conftest.dSYM
20717 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20718       conftest$ac_exeext conftest.$ac_ext
20719 fi
20720 ac_res=`eval 'as_val=${'$as_ac_var'}
20721                  $as_echo "$as_val"'`
20722                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20723 $as_echo "$ac_res" >&6; }
20724 as_val=`eval 'as_val=${'$as_ac_var'}
20725                  $as_echo "$as_val"'`
20726    if test "x$as_val" = x""yes; then
20727   cat >>confdefs.h <<_ACEOF
20728 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20729 _ACEOF
20730
20731 else
20732   case " $LIBOBJS " in
20733   *" $ac_func.$ac_objext "* ) ;;
20734   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20735  ;;
20736 esac
20737
20738 fi
20739 done
20740
20741
20742 else
20743   case " $LIBOBJS " in
20744   *" getaddrinfo.$ac_objext "* ) ;;
20745   *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
20746  ;;
20747 esac
20748
20749 fi
20750
20751 # Similarly, use system's getopt_long() only if system provides struct option.
20752 if test x"$ac_cv_type_struct_option" = xyes ; then
20753
20754 for ac_func in getopt_long
20755 do
20756 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20757 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20758 $as_echo_n "checking for $ac_func... " >&6; }
20759 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20760   $as_echo_n "(cached) " >&6
20761 else
20762   cat >conftest.$ac_ext <<_ACEOF
20763 /* confdefs.h.  */
20764 _ACEOF
20765 cat confdefs.h >>conftest.$ac_ext
20766 cat >>conftest.$ac_ext <<_ACEOF
20767 /* end confdefs.h.  */
20768 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20769    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20770 #define $ac_func innocuous_$ac_func
20771
20772 /* System header to define __stub macros and hopefully few prototypes,
20773     which can conflict with char $ac_func (); below.
20774     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20775     <limits.h> exists even on freestanding compilers.  */
20776
20777 #ifdef __STDC__
20778 # include <limits.h>
20779 #else
20780 # include <assert.h>
20781 #endif
20782
20783 #undef $ac_func
20784
20785 /* Override any GCC internal prototype to avoid an error.
20786    Use char because int might match the return type of a GCC
20787    builtin and then its argument prototype would still apply.  */
20788 #ifdef __cplusplus
20789 extern "C"
20790 #endif
20791 char $ac_func ();
20792 /* The GNU C library defines this for functions which it implements
20793     to always fail with ENOSYS.  Some functions are actually named
20794     something starting with __ and the normal name is an alias.  */
20795 #if defined __stub_$ac_func || defined __stub___$ac_func
20796 choke me
20797 #endif
20798
20799 int
20800 main ()
20801 {
20802 return $ac_func ();
20803   ;
20804   return 0;
20805 }
20806 _ACEOF
20807 rm -f conftest.$ac_objext conftest$ac_exeext
20808 if { (ac_try="$ac_link"
20809 case "(($ac_try" in
20810   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20811   *) ac_try_echo=$ac_try;;
20812 esac
20813 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20814 $as_echo "$ac_try_echo") >&5
20815   (eval "$ac_link") 2>conftest.er1
20816   ac_status=$?
20817   grep -v '^ *+' conftest.er1 >conftest.err
20818   rm -f conftest.er1
20819   cat conftest.err >&5
20820   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20821   (exit $ac_status); } && {
20822          test -z "$ac_c_werror_flag" ||
20823          test ! -s conftest.err
20824        } && test -s conftest$ac_exeext && {
20825          test "$cross_compiling" = yes ||
20826          $as_test_x conftest$ac_exeext
20827        }; then
20828   eval "$as_ac_var=yes"
20829 else
20830   $as_echo "$as_me: failed program was:" >&5
20831 sed 's/^/| /' conftest.$ac_ext >&5
20832
20833         eval "$as_ac_var=no"
20834 fi
20835
20836 rm -rf conftest.dSYM
20837 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20838       conftest$ac_exeext conftest.$ac_ext
20839 fi
20840 ac_res=`eval 'as_val=${'$as_ac_var'}
20841                  $as_echo "$as_val"'`
20842                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20843 $as_echo "$ac_res" >&6; }
20844 as_val=`eval 'as_val=${'$as_ac_var'}
20845                  $as_echo "$as_val"'`
20846    if test "x$as_val" = x""yes; then
20847   cat >>confdefs.h <<_ACEOF
20848 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20849 _ACEOF
20850
20851 else
20852   case " $LIBOBJS " in
20853   *" $ac_func.$ac_objext "* ) ;;
20854   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20855  ;;
20856 esac
20857
20858 fi
20859 done
20860
20861
20862 else
20863   case " $LIBOBJS " in
20864   *" getopt_long.$ac_objext "* ) ;;
20865   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
20866  ;;
20867 esac
20868
20869 fi
20870
20871 # Solaris' getopt() doesn't do what we want for long options, so always use
20872 # our version on that platform.
20873 if test "$PORTNAME" = "solaris"; then
20874   case " $LIBOBJS " in
20875   *" getopt.$ac_objext "* ) ;;
20876   *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
20877  ;;
20878 esac
20879
20880 fi
20881
20882 # mingw has adopted a GNU-centric interpretation of optind/optreset,
20883 # so always use our version on Windows.
20884 if test "$PORTNAME" = "win32"; then
20885   case " $LIBOBJS " in
20886   *" getopt.$ac_objext "* ) ;;
20887   *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
20888  ;;
20889 esac
20890
20891   case " $LIBOBJS " in
20892   *" getopt_long.$ac_objext "* ) ;;
20893   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
20894  ;;
20895 esac
20896
20897 fi
20898
20899 # Cygwin's erand48() is broken (always returns zero) in some releases,
20900 # so force use of ours.
20901 if test "$PORTNAME" = "cygwin"; then
20902   case " $LIBOBJS " in
20903   *" erand48.$ac_objext "* ) ;;
20904   *) LIBOBJS="$LIBOBJS erand48.$ac_objext"
20905  ;;
20906 esac
20907
20908 fi
20909
20910 # Win32 support
20911 if test "$PORTNAME" = "win32"; then
20912
20913 for ac_func in gettimeofday
20914 do
20915 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20916 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20917 $as_echo_n "checking for $ac_func... " >&6; }
20918 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20919   $as_echo_n "(cached) " >&6
20920 else
20921   cat >conftest.$ac_ext <<_ACEOF
20922 /* confdefs.h.  */
20923 _ACEOF
20924 cat confdefs.h >>conftest.$ac_ext
20925 cat >>conftest.$ac_ext <<_ACEOF
20926 /* end confdefs.h.  */
20927 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20928    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20929 #define $ac_func innocuous_$ac_func
20930
20931 /* System header to define __stub macros and hopefully few prototypes,
20932     which can conflict with char $ac_func (); below.
20933     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20934     <limits.h> exists even on freestanding compilers.  */
20935
20936 #ifdef __STDC__
20937 # include <limits.h>
20938 #else
20939 # include <assert.h>
20940 #endif
20941
20942 #undef $ac_func
20943
20944 /* Override any GCC internal prototype to avoid an error.
20945    Use char because int might match the return type of a GCC
20946    builtin and then its argument prototype would still apply.  */
20947 #ifdef __cplusplus
20948 extern "C"
20949 #endif
20950 char $ac_func ();
20951 /* The GNU C library defines this for functions which it implements
20952     to always fail with ENOSYS.  Some functions are actually named
20953     something starting with __ and the normal name is an alias.  */
20954 #if defined __stub_$ac_func || defined __stub___$ac_func
20955 choke me
20956 #endif
20957
20958 int
20959 main ()
20960 {
20961 return $ac_func ();
20962   ;
20963   return 0;
20964 }
20965 _ACEOF
20966 rm -f conftest.$ac_objext conftest$ac_exeext
20967 if { (ac_try="$ac_link"
20968 case "(($ac_try" in
20969   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20970   *) ac_try_echo=$ac_try;;
20971 esac
20972 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20973 $as_echo "$ac_try_echo") >&5
20974   (eval "$ac_link") 2>conftest.er1
20975   ac_status=$?
20976   grep -v '^ *+' conftest.er1 >conftest.err
20977   rm -f conftest.er1
20978   cat conftest.err >&5
20979   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20980   (exit $ac_status); } && {
20981          test -z "$ac_c_werror_flag" ||
20982          test ! -s conftest.err
20983        } && test -s conftest$ac_exeext && {
20984          test "$cross_compiling" = yes ||
20985          $as_test_x conftest$ac_exeext
20986        }; then
20987   eval "$as_ac_var=yes"
20988 else
20989   $as_echo "$as_me: failed program was:" >&5
20990 sed 's/^/| /' conftest.$ac_ext >&5
20991
20992         eval "$as_ac_var=no"
20993 fi
20994
20995 rm -rf conftest.dSYM
20996 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20997       conftest$ac_exeext conftest.$ac_ext
20998 fi
20999 ac_res=`eval 'as_val=${'$as_ac_var'}
21000                  $as_echo "$as_val"'`
21001                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21002 $as_echo "$ac_res" >&6; }
21003 as_val=`eval 'as_val=${'$as_ac_var'}
21004                  $as_echo "$as_val"'`
21005    if test "x$as_val" = x""yes; then
21006   cat >>confdefs.h <<_ACEOF
21007 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21008 _ACEOF
21009
21010 else
21011   case " $LIBOBJS " in
21012   *" $ac_func.$ac_objext "* ) ;;
21013   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
21014  ;;
21015 esac
21016
21017 fi
21018 done
21019
21020
21021   case " $LIBOBJS " in
21022   *" kill.$ac_objext "* ) ;;
21023   *) LIBOBJS="$LIBOBJS kill.$ac_objext"
21024  ;;
21025 esac
21026
21027   case " $LIBOBJS " in
21028   *" open.$ac_objext "* ) ;;
21029   *) LIBOBJS="$LIBOBJS open.$ac_objext"
21030  ;;
21031 esac
21032
21033   case " $LIBOBJS " in
21034   *" win32env.$ac_objext "* ) ;;
21035   *) LIBOBJS="$LIBOBJS win32env.$ac_objext"
21036  ;;
21037 esac
21038
21039   case " $LIBOBJS " in
21040   *" win32error.$ac_objext "* ) ;;
21041   *) LIBOBJS="$LIBOBJS win32error.$ac_objext"
21042  ;;
21043 esac
21044
21045
21046 cat >>confdefs.h <<\_ACEOF
21047 #define HAVE_SYMLINK 1
21048 _ACEOF
21049
21050   { $as_echo "$as_me:$LINENO: checking for MINIDUMP_TYPE" >&5
21051 $as_echo_n "checking for MINIDUMP_TYPE... " >&6; }
21052 if test "${ac_cv_type_MINIDUMP_TYPE+set}" = set; then
21053   $as_echo_n "(cached) " >&6
21054 else
21055   ac_cv_type_MINIDUMP_TYPE=no
21056 cat >conftest.$ac_ext <<_ACEOF
21057 /* confdefs.h.  */
21058 _ACEOF
21059 cat confdefs.h >>conftest.$ac_ext
21060 cat >>conftest.$ac_ext <<_ACEOF
21061 /* end confdefs.h.  */
21062
21063 #define WIN32_LEAN_AND_MEAN
21064 #include <windows.h>
21065 #include <string.h>
21066 #include <dbghelp.h>
21067
21068 int
21069 main ()
21070 {
21071 if (sizeof (MINIDUMP_TYPE))
21072        return 0;
21073   ;
21074   return 0;
21075 }
21076 _ACEOF
21077 rm -f conftest.$ac_objext
21078 if { (ac_try="$ac_compile"
21079 case "(($ac_try" in
21080   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21081   *) ac_try_echo=$ac_try;;
21082 esac
21083 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21084 $as_echo "$ac_try_echo") >&5
21085   (eval "$ac_compile") 2>conftest.er1
21086   ac_status=$?
21087   grep -v '^ *+' conftest.er1 >conftest.err
21088   rm -f conftest.er1
21089   cat conftest.err >&5
21090   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21091   (exit $ac_status); } && {
21092          test -z "$ac_c_werror_flag" ||
21093          test ! -s conftest.err
21094        } && test -s conftest.$ac_objext; then
21095   cat >conftest.$ac_ext <<_ACEOF
21096 /* confdefs.h.  */
21097 _ACEOF
21098 cat confdefs.h >>conftest.$ac_ext
21099 cat >>conftest.$ac_ext <<_ACEOF
21100 /* end confdefs.h.  */
21101
21102 #define WIN32_LEAN_AND_MEAN
21103 #include <windows.h>
21104 #include <string.h>
21105 #include <dbghelp.h>
21106
21107 int
21108 main ()
21109 {
21110 if (sizeof ((MINIDUMP_TYPE)))
21111           return 0;
21112   ;
21113   return 0;
21114 }
21115 _ACEOF
21116 rm -f conftest.$ac_objext
21117 if { (ac_try="$ac_compile"
21118 case "(($ac_try" in
21119   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21120   *) ac_try_echo=$ac_try;;
21121 esac
21122 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21123 $as_echo "$ac_try_echo") >&5
21124   (eval "$ac_compile") 2>conftest.er1
21125   ac_status=$?
21126   grep -v '^ *+' conftest.er1 >conftest.err
21127   rm -f conftest.er1
21128   cat conftest.err >&5
21129   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21130   (exit $ac_status); } && {
21131          test -z "$ac_c_werror_flag" ||
21132          test ! -s conftest.err
21133        } && test -s conftest.$ac_objext; then
21134   :
21135 else
21136   $as_echo "$as_me: failed program was:" >&5
21137 sed 's/^/| /' conftest.$ac_ext >&5
21138
21139         ac_cv_type_MINIDUMP_TYPE=yes
21140 fi
21141
21142 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21143 else
21144   $as_echo "$as_me: failed program was:" >&5
21145 sed 's/^/| /' conftest.$ac_ext >&5
21146
21147
21148 fi
21149
21150 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21151 fi
21152 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_MINIDUMP_TYPE" >&5
21153 $as_echo "$ac_cv_type_MINIDUMP_TYPE" >&6; }
21154 if test "x$ac_cv_type_MINIDUMP_TYPE" = x""yes; then
21155
21156 cat >>confdefs.h <<_ACEOF
21157 #define HAVE_MINIDUMP_TYPE 1
21158 _ACEOF
21159
21160 pgac_minidump_type=yes
21161 else
21162   pgac_minidump_type=no
21163 fi
21164
21165 fi
21166 if test x"$pgac_minidump_type" = x"yes" ; then
21167   have_win32_dbghelp=yes
21168
21169 else
21170   have_win32_dbghelp=no
21171
21172 fi
21173
21174 if test "$with_readline" = yes; then
21175   { $as_echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
21176 $as_echo_n "checking for rl_completion_append_character... " >&6; }
21177 if test "${pgac_cv_var_rl_completion_append_character+set}" = set; then
21178   $as_echo_n "(cached) " >&6
21179 else
21180   cat >conftest.$ac_ext <<_ACEOF
21181 /* confdefs.h.  */
21182 _ACEOF
21183 cat confdefs.h >>conftest.$ac_ext
21184 cat >>conftest.$ac_ext <<_ACEOF
21185 /* end confdefs.h.  */
21186 #include <stdio.h>
21187 #ifdef HAVE_READLINE_READLINE_H
21188 # include <readline/readline.h>
21189 #elif defined(HAVE_READLINE_H)
21190 # include <readline.h>
21191 #endif
21192
21193 int
21194 main ()
21195 {
21196 rl_completion_append_character = 'x';
21197   ;
21198   return 0;
21199 }
21200 _ACEOF
21201 rm -f conftest.$ac_objext conftest$ac_exeext
21202 if { (ac_try="$ac_link"
21203 case "(($ac_try" in
21204   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21205   *) ac_try_echo=$ac_try;;
21206 esac
21207 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21208 $as_echo "$ac_try_echo") >&5
21209   (eval "$ac_link") 2>conftest.er1
21210   ac_status=$?
21211   grep -v '^ *+' conftest.er1 >conftest.err
21212   rm -f conftest.er1
21213   cat conftest.err >&5
21214   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21215   (exit $ac_status); } && {
21216          test -z "$ac_c_werror_flag" ||
21217          test ! -s conftest.err
21218        } && test -s conftest$ac_exeext && {
21219          test "$cross_compiling" = yes ||
21220          $as_test_x conftest$ac_exeext
21221        }; then
21222   pgac_cv_var_rl_completion_append_character=yes
21223 else
21224   $as_echo "$as_me: failed program was:" >&5
21225 sed 's/^/| /' conftest.$ac_ext >&5
21226
21227         pgac_cv_var_rl_completion_append_character=no
21228 fi
21229
21230 rm -rf conftest.dSYM
21231 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21232       conftest$ac_exeext conftest.$ac_ext
21233 fi
21234 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_rl_completion_append_character" >&5
21235 $as_echo "$pgac_cv_var_rl_completion_append_character" >&6; }
21236 if test x"$pgac_cv_var_rl_completion_append_character" = x"yes"; then
21237
21238 cat >>confdefs.h <<\_ACEOF
21239 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
21240 _ACEOF
21241
21242 fi
21243
21244
21245 for ac_func in rl_completion_matches rl_filename_completion_function
21246 do
21247 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21248 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21249 $as_echo_n "checking for $ac_func... " >&6; }
21250 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21251   $as_echo_n "(cached) " >&6
21252 else
21253   cat >conftest.$ac_ext <<_ACEOF
21254 /* confdefs.h.  */
21255 _ACEOF
21256 cat confdefs.h >>conftest.$ac_ext
21257 cat >>conftest.$ac_ext <<_ACEOF
21258 /* end confdefs.h.  */
21259 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21260    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21261 #define $ac_func innocuous_$ac_func
21262
21263 /* System header to define __stub macros and hopefully few prototypes,
21264     which can conflict with char $ac_func (); below.
21265     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21266     <limits.h> exists even on freestanding compilers.  */
21267
21268 #ifdef __STDC__
21269 # include <limits.h>
21270 #else
21271 # include <assert.h>
21272 #endif
21273
21274 #undef $ac_func
21275
21276 /* Override any GCC internal prototype to avoid an error.
21277    Use char because int might match the return type of a GCC
21278    builtin and then its argument prototype would still apply.  */
21279 #ifdef __cplusplus
21280 extern "C"
21281 #endif
21282 char $ac_func ();
21283 /* The GNU C library defines this for functions which it implements
21284     to always fail with ENOSYS.  Some functions are actually named
21285     something starting with __ and the normal name is an alias.  */
21286 #if defined __stub_$ac_func || defined __stub___$ac_func
21287 choke me
21288 #endif
21289
21290 int
21291 main ()
21292 {
21293 return $ac_func ();
21294   ;
21295   return 0;
21296 }
21297 _ACEOF
21298 rm -f conftest.$ac_objext conftest$ac_exeext
21299 if { (ac_try="$ac_link"
21300 case "(($ac_try" in
21301   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21302   *) ac_try_echo=$ac_try;;
21303 esac
21304 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21305 $as_echo "$ac_try_echo") >&5
21306   (eval "$ac_link") 2>conftest.er1
21307   ac_status=$?
21308   grep -v '^ *+' conftest.er1 >conftest.err
21309   rm -f conftest.er1
21310   cat conftest.err >&5
21311   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21312   (exit $ac_status); } && {
21313          test -z "$ac_c_werror_flag" ||
21314          test ! -s conftest.err
21315        } && test -s conftest$ac_exeext && {
21316          test "$cross_compiling" = yes ||
21317          $as_test_x conftest$ac_exeext
21318        }; then
21319   eval "$as_ac_var=yes"
21320 else
21321   $as_echo "$as_me: failed program was:" >&5
21322 sed 's/^/| /' conftest.$ac_ext >&5
21323
21324         eval "$as_ac_var=no"
21325 fi
21326
21327 rm -rf conftest.dSYM
21328 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21329       conftest$ac_exeext conftest.$ac_ext
21330 fi
21331 ac_res=`eval 'as_val=${'$as_ac_var'}
21332                  $as_echo "$as_val"'`
21333                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21334 $as_echo "$ac_res" >&6; }
21335 as_val=`eval 'as_val=${'$as_ac_var'}
21336                  $as_echo "$as_val"'`
21337    if test "x$as_val" = x""yes; then
21338   cat >>confdefs.h <<_ACEOF
21339 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21340 _ACEOF
21341
21342 fi
21343 done
21344
21345
21346
21347 for ac_func in append_history history_truncate_file
21348 do
21349 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21350 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21351 $as_echo_n "checking for $ac_func... " >&6; }
21352 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21353   $as_echo_n "(cached) " >&6
21354 else
21355   cat >conftest.$ac_ext <<_ACEOF
21356 /* confdefs.h.  */
21357 _ACEOF
21358 cat confdefs.h >>conftest.$ac_ext
21359 cat >>conftest.$ac_ext <<_ACEOF
21360 /* end confdefs.h.  */
21361 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21362    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21363 #define $ac_func innocuous_$ac_func
21364
21365 /* System header to define __stub macros and hopefully few prototypes,
21366     which can conflict with char $ac_func (); below.
21367     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21368     <limits.h> exists even on freestanding compilers.  */
21369
21370 #ifdef __STDC__
21371 # include <limits.h>
21372 #else
21373 # include <assert.h>
21374 #endif
21375
21376 #undef $ac_func
21377
21378 /* Override any GCC internal prototype to avoid an error.
21379    Use char because int might match the return type of a GCC
21380    builtin and then its argument prototype would still apply.  */
21381 #ifdef __cplusplus
21382 extern "C"
21383 #endif
21384 char $ac_func ();
21385 /* The GNU C library defines this for functions which it implements
21386     to always fail with ENOSYS.  Some functions are actually named
21387     something starting with __ and the normal name is an alias.  */
21388 #if defined __stub_$ac_func || defined __stub___$ac_func
21389 choke me
21390 #endif
21391
21392 int
21393 main ()
21394 {
21395 return $ac_func ();
21396   ;
21397   return 0;
21398 }
21399 _ACEOF
21400 rm -f conftest.$ac_objext conftest$ac_exeext
21401 if { (ac_try="$ac_link"
21402 case "(($ac_try" in
21403   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21404   *) ac_try_echo=$ac_try;;
21405 esac
21406 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21407 $as_echo "$ac_try_echo") >&5
21408   (eval "$ac_link") 2>conftest.er1
21409   ac_status=$?
21410   grep -v '^ *+' conftest.er1 >conftest.err
21411   rm -f conftest.er1
21412   cat conftest.err >&5
21413   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21414   (exit $ac_status); } && {
21415          test -z "$ac_c_werror_flag" ||
21416          test ! -s conftest.err
21417        } && test -s conftest$ac_exeext && {
21418          test "$cross_compiling" = yes ||
21419          $as_test_x conftest$ac_exeext
21420        }; then
21421   eval "$as_ac_var=yes"
21422 else
21423   $as_echo "$as_me: failed program was:" >&5
21424 sed 's/^/| /' conftest.$ac_ext >&5
21425
21426         eval "$as_ac_var=no"
21427 fi
21428
21429 rm -rf conftest.dSYM
21430 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21431       conftest$ac_exeext conftest.$ac_ext
21432 fi
21433 ac_res=`eval 'as_val=${'$as_ac_var'}
21434                  $as_echo "$as_val"'`
21435                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21436 $as_echo "$ac_res" >&6; }
21437 as_val=`eval 'as_val=${'$as_ac_var'}
21438                  $as_echo "$as_val"'`
21439    if test "x$as_val" = x""yes; then
21440   cat >>confdefs.h <<_ACEOF
21441 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21442 _ACEOF
21443
21444 fi
21445 done
21446
21447 fi
21448
21449
21450 { $as_echo "$as_me:$LINENO: checking for sigsetjmp" >&5
21451 $as_echo_n "checking for sigsetjmp... " >&6; }
21452 if test "${pgac_cv_func_sigsetjmp+set}" = set; then
21453   $as_echo_n "(cached) " >&6
21454 else
21455   cat >conftest.$ac_ext <<_ACEOF
21456 /* confdefs.h.  */
21457 _ACEOF
21458 cat confdefs.h >>conftest.$ac_ext
21459 cat >>conftest.$ac_ext <<_ACEOF
21460 /* end confdefs.h.  */
21461 #include <setjmp.h>
21462 int
21463 main ()
21464 {
21465 sigjmp_buf x; sigsetjmp(x, 1);
21466   ;
21467   return 0;
21468 }
21469 _ACEOF
21470 rm -f conftest.$ac_objext conftest$ac_exeext
21471 if { (ac_try="$ac_link"
21472 case "(($ac_try" in
21473   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21474   *) ac_try_echo=$ac_try;;
21475 esac
21476 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21477 $as_echo "$ac_try_echo") >&5
21478   (eval "$ac_link") 2>conftest.er1
21479   ac_status=$?
21480   grep -v '^ *+' conftest.er1 >conftest.err
21481   rm -f conftest.er1
21482   cat conftest.err >&5
21483   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21484   (exit $ac_status); } && {
21485          test -z "$ac_c_werror_flag" ||
21486          test ! -s conftest.err
21487        } && test -s conftest$ac_exeext && {
21488          test "$cross_compiling" = yes ||
21489          $as_test_x conftest$ac_exeext
21490        }; then
21491   pgac_cv_func_sigsetjmp=yes
21492 else
21493   $as_echo "$as_me: failed program was:" >&5
21494 sed 's/^/| /' conftest.$ac_ext >&5
21495
21496         pgac_cv_func_sigsetjmp=no
21497 fi
21498
21499 rm -rf conftest.dSYM
21500 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21501       conftest$ac_exeext conftest.$ac_ext
21502 fi
21503 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_sigsetjmp" >&5
21504 $as_echo "$pgac_cv_func_sigsetjmp" >&6; }
21505 if test x"$pgac_cv_func_sigsetjmp" = x"yes"; then
21506
21507 cat >>confdefs.h <<\_ACEOF
21508 #define HAVE_SIGSETJMP 1
21509 _ACEOF
21510
21511 fi
21512
21513 { $as_echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
21514 $as_echo_n "checking whether sys_siglist is declared... " >&6; }
21515 if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
21516   $as_echo_n "(cached) " >&6
21517 else
21518   cat >conftest.$ac_ext <<_ACEOF
21519 /* confdefs.h.  */
21520 _ACEOF
21521 cat confdefs.h >>conftest.$ac_ext
21522 cat >>conftest.$ac_ext <<_ACEOF
21523 /* end confdefs.h.  */
21524 #include <signal.h>
21525 /* NetBSD declares sys_siglist in unistd.h.  */
21526 #ifdef HAVE_UNISTD_H
21527 # include <unistd.h>
21528 #endif
21529
21530
21531 int
21532 main ()
21533 {
21534 #ifndef sys_siglist
21535   (void) sys_siglist;
21536 #endif
21537
21538   ;
21539   return 0;
21540 }
21541 _ACEOF
21542 rm -f conftest.$ac_objext
21543 if { (ac_try="$ac_compile"
21544 case "(($ac_try" in
21545   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21546   *) ac_try_echo=$ac_try;;
21547 esac
21548 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21549 $as_echo "$ac_try_echo") >&5
21550   (eval "$ac_compile") 2>conftest.er1
21551   ac_status=$?
21552   grep -v '^ *+' conftest.er1 >conftest.err
21553   rm -f conftest.er1
21554   cat conftest.err >&5
21555   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21556   (exit $ac_status); } && {
21557          test -z "$ac_c_werror_flag" ||
21558          test ! -s conftest.err
21559        } && test -s conftest.$ac_objext; then
21560   ac_cv_have_decl_sys_siglist=yes
21561 else
21562   $as_echo "$as_me: failed program was:" >&5
21563 sed 's/^/| /' conftest.$ac_ext >&5
21564
21565         ac_cv_have_decl_sys_siglist=no
21566 fi
21567
21568 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21569 fi
21570 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
21571 $as_echo "$ac_cv_have_decl_sys_siglist" >&6; }
21572 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then
21573
21574 cat >>confdefs.h <<_ACEOF
21575 #define HAVE_DECL_SYS_SIGLIST 1
21576 _ACEOF
21577
21578
21579 else
21580   cat >>confdefs.h <<_ACEOF
21581 #define HAVE_DECL_SYS_SIGLIST 0
21582 _ACEOF
21583
21584
21585 fi
21586
21587
21588
21589
21590 { $as_echo "$as_me:$LINENO: checking for syslog" >&5
21591 $as_echo_n "checking for syslog... " >&6; }
21592 if test "${ac_cv_func_syslog+set}" = set; then
21593   $as_echo_n "(cached) " >&6
21594 else
21595   cat >conftest.$ac_ext <<_ACEOF
21596 /* confdefs.h.  */
21597 _ACEOF
21598 cat confdefs.h >>conftest.$ac_ext
21599 cat >>conftest.$ac_ext <<_ACEOF
21600 /* end confdefs.h.  */
21601 /* Define syslog to an innocuous variant, in case <limits.h> declares syslog.
21602    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21603 #define syslog innocuous_syslog
21604
21605 /* System header to define __stub macros and hopefully few prototypes,
21606     which can conflict with char syslog (); below.
21607     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21608     <limits.h> exists even on freestanding compilers.  */
21609
21610 #ifdef __STDC__
21611 # include <limits.h>
21612 #else
21613 # include <assert.h>
21614 #endif
21615
21616 #undef syslog
21617
21618 /* Override any GCC internal prototype to avoid an error.
21619    Use char because int might match the return type of a GCC
21620    builtin and then its argument prototype would still apply.  */
21621 #ifdef __cplusplus
21622 extern "C"
21623 #endif
21624 char syslog ();
21625 /* The GNU C library defines this for functions which it implements
21626     to always fail with ENOSYS.  Some functions are actually named
21627     something starting with __ and the normal name is an alias.  */
21628 #if defined __stub_syslog || defined __stub___syslog
21629 choke me
21630 #endif
21631
21632 int
21633 main ()
21634 {
21635 return syslog ();
21636   ;
21637   return 0;
21638 }
21639 _ACEOF
21640 rm -f conftest.$ac_objext conftest$ac_exeext
21641 if { (ac_try="$ac_link"
21642 case "(($ac_try" in
21643   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21644   *) ac_try_echo=$ac_try;;
21645 esac
21646 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21647 $as_echo "$ac_try_echo") >&5
21648   (eval "$ac_link") 2>conftest.er1
21649   ac_status=$?
21650   grep -v '^ *+' conftest.er1 >conftest.err
21651   rm -f conftest.er1
21652   cat conftest.err >&5
21653   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21654   (exit $ac_status); } && {
21655          test -z "$ac_c_werror_flag" ||
21656          test ! -s conftest.err
21657        } && test -s conftest$ac_exeext && {
21658          test "$cross_compiling" = yes ||
21659          $as_test_x conftest$ac_exeext
21660        }; then
21661   ac_cv_func_syslog=yes
21662 else
21663   $as_echo "$as_me: failed program was:" >&5
21664 sed 's/^/| /' conftest.$ac_ext >&5
21665
21666         ac_cv_func_syslog=no
21667 fi
21668
21669 rm -rf conftest.dSYM
21670 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21671       conftest$ac_exeext conftest.$ac_ext
21672 fi
21673 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
21674 $as_echo "$ac_cv_func_syslog" >&6; }
21675 if test "x$ac_cv_func_syslog" = x""yes; then
21676   if test "${ac_cv_header_syslog_h+set}" = set; then
21677   { $as_echo "$as_me:$LINENO: checking for syslog.h" >&5
21678 $as_echo_n "checking for syslog.h... " >&6; }
21679 if test "${ac_cv_header_syslog_h+set}" = set; then
21680   $as_echo_n "(cached) " >&6
21681 fi
21682 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
21683 $as_echo "$ac_cv_header_syslog_h" >&6; }
21684 else
21685   # Is the header compilable?
21686 { $as_echo "$as_me:$LINENO: checking syslog.h usability" >&5
21687 $as_echo_n "checking syslog.h usability... " >&6; }
21688 cat >conftest.$ac_ext <<_ACEOF
21689 /* confdefs.h.  */
21690 _ACEOF
21691 cat confdefs.h >>conftest.$ac_ext
21692 cat >>conftest.$ac_ext <<_ACEOF
21693 /* end confdefs.h.  */
21694 $ac_includes_default
21695 #include <syslog.h>
21696 _ACEOF
21697 rm -f conftest.$ac_objext
21698 if { (ac_try="$ac_compile"
21699 case "(($ac_try" in
21700   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21701   *) ac_try_echo=$ac_try;;
21702 esac
21703 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21704 $as_echo "$ac_try_echo") >&5
21705   (eval "$ac_compile") 2>conftest.er1
21706   ac_status=$?
21707   grep -v '^ *+' conftest.er1 >conftest.err
21708   rm -f conftest.er1
21709   cat conftest.err >&5
21710   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21711   (exit $ac_status); } && {
21712          test -z "$ac_c_werror_flag" ||
21713          test ! -s conftest.err
21714        } && test -s conftest.$ac_objext; then
21715   ac_header_compiler=yes
21716 else
21717   $as_echo "$as_me: failed program was:" >&5
21718 sed 's/^/| /' conftest.$ac_ext >&5
21719
21720         ac_header_compiler=no
21721 fi
21722
21723 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21724 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21725 $as_echo "$ac_header_compiler" >&6; }
21726
21727 # Is the header present?
21728 { $as_echo "$as_me:$LINENO: checking syslog.h presence" >&5
21729 $as_echo_n "checking syslog.h presence... " >&6; }
21730 cat >conftest.$ac_ext <<_ACEOF
21731 /* confdefs.h.  */
21732 _ACEOF
21733 cat confdefs.h >>conftest.$ac_ext
21734 cat >>conftest.$ac_ext <<_ACEOF
21735 /* end confdefs.h.  */
21736 #include <syslog.h>
21737 _ACEOF
21738 if { (ac_try="$ac_cpp conftest.$ac_ext"
21739 case "(($ac_try" in
21740   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21741   *) ac_try_echo=$ac_try;;
21742 esac
21743 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21744 $as_echo "$ac_try_echo") >&5
21745   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
21746   ac_status=$?
21747   grep -v '^ *+' conftest.er1 >conftest.err
21748   rm -f conftest.er1
21749   cat conftest.err >&5
21750   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21751   (exit $ac_status); } >/dev/null && {
21752          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
21753          test ! -s conftest.err
21754        }; then
21755   ac_header_preproc=yes
21756 else
21757   $as_echo "$as_me: failed program was:" >&5
21758 sed 's/^/| /' conftest.$ac_ext >&5
21759
21760   ac_header_preproc=no
21761 fi
21762
21763 rm -f conftest.err conftest.$ac_ext
21764 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21765 $as_echo "$ac_header_preproc" >&6; }
21766
21767 # So?  What about this header?
21768 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21769   yes:no: )
21770     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
21771 $as_echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
21772     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the compiler's result" >&5
21773 $as_echo "$as_me: WARNING: syslog.h: proceeding with the compiler's result" >&2;}
21774     ac_header_preproc=yes
21775     ;;
21776   no:yes:* )
21777     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
21778 $as_echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
21779     { $as_echo "$as_me:$LINENO: WARNING: syslog.h:     check for missing prerequisite headers?" >&5
21780 $as_echo "$as_me: WARNING: syslog.h:     check for missing prerequisite headers?" >&2;}
21781     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: see the Autoconf documentation" >&5
21782 $as_echo "$as_me: WARNING: syslog.h: see the Autoconf documentation" >&2;}
21783     { $as_echo "$as_me:$LINENO: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&5
21784 $as_echo "$as_me: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&2;}
21785     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
21786 $as_echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;}
21787     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: in the future, the compiler will take precedence" >&5
21788 $as_echo "$as_me: WARNING: syslog.h: in the future, the compiler will take precedence" >&2;}
21789     ( cat <<\_ASBOX
21790 ## ---------------------------------------- ##
21791 ## Report this to pgsql-bugs@postgresql.org ##
21792 ## ---------------------------------------- ##
21793 _ASBOX
21794      ) | sed "s/^/$as_me: WARNING:     /" >&2
21795     ;;
21796 esac
21797 { $as_echo "$as_me:$LINENO: checking for syslog.h" >&5
21798 $as_echo_n "checking for syslog.h... " >&6; }
21799 if test "${ac_cv_header_syslog_h+set}" = set; then
21800   $as_echo_n "(cached) " >&6
21801 else
21802   ac_cv_header_syslog_h=$ac_header_preproc
21803 fi
21804 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
21805 $as_echo "$ac_cv_header_syslog_h" >&6; }
21806
21807 fi
21808 if test "x$ac_cv_header_syslog_h" = x""yes; then
21809
21810 cat >>confdefs.h <<\_ACEOF
21811 #define HAVE_SYSLOG 1
21812 _ACEOF
21813
21814 fi
21815
21816
21817 fi
21818
21819
21820 { $as_echo "$as_me:$LINENO: checking for opterr" >&5
21821 $as_echo_n "checking for opterr... " >&6; }
21822 if test "${pgac_cv_var_int_opterr+set}" = set; then
21823   $as_echo_n "(cached) " >&6
21824 else
21825   cat >conftest.$ac_ext <<_ACEOF
21826 /* confdefs.h.  */
21827 _ACEOF
21828 cat confdefs.h >>conftest.$ac_ext
21829 cat >>conftest.$ac_ext <<_ACEOF
21830 /* end confdefs.h.  */
21831 #include <unistd.h>
21832 int
21833 main ()
21834 {
21835 extern int opterr; opterr = 1;
21836   ;
21837   return 0;
21838 }
21839 _ACEOF
21840 rm -f conftest.$ac_objext conftest$ac_exeext
21841 if { (ac_try="$ac_link"
21842 case "(($ac_try" in
21843   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21844   *) ac_try_echo=$ac_try;;
21845 esac
21846 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21847 $as_echo "$ac_try_echo") >&5
21848   (eval "$ac_link") 2>conftest.er1
21849   ac_status=$?
21850   grep -v '^ *+' conftest.er1 >conftest.err
21851   rm -f conftest.er1
21852   cat conftest.err >&5
21853   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21854   (exit $ac_status); } && {
21855          test -z "$ac_c_werror_flag" ||
21856          test ! -s conftest.err
21857        } && test -s conftest$ac_exeext && {
21858          test "$cross_compiling" = yes ||
21859          $as_test_x conftest$ac_exeext
21860        }; then
21861   pgac_cv_var_int_opterr=yes
21862 else
21863   $as_echo "$as_me: failed program was:" >&5
21864 sed 's/^/| /' conftest.$ac_ext >&5
21865
21866         pgac_cv_var_int_opterr=no
21867 fi
21868
21869 rm -rf conftest.dSYM
21870 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21871       conftest$ac_exeext conftest.$ac_ext
21872 fi
21873 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_opterr" >&5
21874 $as_echo "$pgac_cv_var_int_opterr" >&6; }
21875 if test x"$pgac_cv_var_int_opterr" = x"yes"; then
21876
21877 cat >>confdefs.h <<\_ACEOF
21878 #define HAVE_INT_OPTERR 1
21879 _ACEOF
21880
21881 fi
21882
21883 { $as_echo "$as_me:$LINENO: checking for optreset" >&5
21884 $as_echo_n "checking for optreset... " >&6; }
21885 if test "${pgac_cv_var_int_optreset+set}" = set; then
21886   $as_echo_n "(cached) " >&6
21887 else
21888   cat >conftest.$ac_ext <<_ACEOF
21889 /* confdefs.h.  */
21890 _ACEOF
21891 cat confdefs.h >>conftest.$ac_ext
21892 cat >>conftest.$ac_ext <<_ACEOF
21893 /* end confdefs.h.  */
21894 #include <unistd.h>
21895 int
21896 main ()
21897 {
21898 extern int optreset; optreset = 1;
21899   ;
21900   return 0;
21901 }
21902 _ACEOF
21903 rm -f conftest.$ac_objext conftest$ac_exeext
21904 if { (ac_try="$ac_link"
21905 case "(($ac_try" in
21906   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21907   *) ac_try_echo=$ac_try;;
21908 esac
21909 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21910 $as_echo "$ac_try_echo") >&5
21911   (eval "$ac_link") 2>conftest.er1
21912   ac_status=$?
21913   grep -v '^ *+' conftest.er1 >conftest.err
21914   rm -f conftest.er1
21915   cat conftest.err >&5
21916   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21917   (exit $ac_status); } && {
21918          test -z "$ac_c_werror_flag" ||
21919          test ! -s conftest.err
21920        } && test -s conftest$ac_exeext && {
21921          test "$cross_compiling" = yes ||
21922          $as_test_x conftest$ac_exeext
21923        }; then
21924   pgac_cv_var_int_optreset=yes
21925 else
21926   $as_echo "$as_me: failed program was:" >&5
21927 sed 's/^/| /' conftest.$ac_ext >&5
21928
21929         pgac_cv_var_int_optreset=no
21930 fi
21931
21932 rm -rf conftest.dSYM
21933 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21934       conftest$ac_exeext conftest.$ac_ext
21935 fi
21936 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
21937 $as_echo "$pgac_cv_var_int_optreset" >&6; }
21938 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
21939
21940 cat >>confdefs.h <<\_ACEOF
21941 #define HAVE_INT_OPTRESET 1
21942 _ACEOF
21943
21944 fi
21945
21946
21947
21948 for ac_func in strtoll strtoq
21949 do
21950 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21951 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21952 $as_echo_n "checking for $ac_func... " >&6; }
21953 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21954   $as_echo_n "(cached) " >&6
21955 else
21956   cat >conftest.$ac_ext <<_ACEOF
21957 /* confdefs.h.  */
21958 _ACEOF
21959 cat confdefs.h >>conftest.$ac_ext
21960 cat >>conftest.$ac_ext <<_ACEOF
21961 /* end confdefs.h.  */
21962 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21963    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21964 #define $ac_func innocuous_$ac_func
21965
21966 /* System header to define __stub macros and hopefully few prototypes,
21967     which can conflict with char $ac_func (); below.
21968     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21969     <limits.h> exists even on freestanding compilers.  */
21970
21971 #ifdef __STDC__
21972 # include <limits.h>
21973 #else
21974 # include <assert.h>
21975 #endif
21976
21977 #undef $ac_func
21978
21979 /* Override any GCC internal prototype to avoid an error.
21980    Use char because int might match the return type of a GCC
21981    builtin and then its argument prototype would still apply.  */
21982 #ifdef __cplusplus
21983 extern "C"
21984 #endif
21985 char $ac_func ();
21986 /* The GNU C library defines this for functions which it implements
21987     to always fail with ENOSYS.  Some functions are actually named
21988     something starting with __ and the normal name is an alias.  */
21989 #if defined __stub_$ac_func || defined __stub___$ac_func
21990 choke me
21991 #endif
21992
21993 int
21994 main ()
21995 {
21996 return $ac_func ();
21997   ;
21998   return 0;
21999 }
22000 _ACEOF
22001 rm -f conftest.$ac_objext conftest$ac_exeext
22002 if { (ac_try="$ac_link"
22003 case "(($ac_try" in
22004   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22005   *) ac_try_echo=$ac_try;;
22006 esac
22007 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22008 $as_echo "$ac_try_echo") >&5
22009   (eval "$ac_link") 2>conftest.er1
22010   ac_status=$?
22011   grep -v '^ *+' conftest.er1 >conftest.err
22012   rm -f conftest.er1
22013   cat conftest.err >&5
22014   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22015   (exit $ac_status); } && {
22016          test -z "$ac_c_werror_flag" ||
22017          test ! -s conftest.err
22018        } && test -s conftest$ac_exeext && {
22019          test "$cross_compiling" = yes ||
22020          $as_test_x conftest$ac_exeext
22021        }; then
22022   eval "$as_ac_var=yes"
22023 else
22024   $as_echo "$as_me: failed program was:" >&5
22025 sed 's/^/| /' conftest.$ac_ext >&5
22026
22027         eval "$as_ac_var=no"
22028 fi
22029
22030 rm -rf conftest.dSYM
22031 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22032       conftest$ac_exeext conftest.$ac_ext
22033 fi
22034 ac_res=`eval 'as_val=${'$as_ac_var'}
22035                  $as_echo "$as_val"'`
22036                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22037 $as_echo "$ac_res" >&6; }
22038 as_val=`eval 'as_val=${'$as_ac_var'}
22039                  $as_echo "$as_val"'`
22040    if test "x$as_val" = x""yes; then
22041   cat >>confdefs.h <<_ACEOF
22042 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22043 _ACEOF
22044  break
22045 fi
22046 done
22047
22048
22049
22050 for ac_func in strtoull strtouq
22051 do
22052 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22053 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22054 $as_echo_n "checking for $ac_func... " >&6; }
22055 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22056   $as_echo_n "(cached) " >&6
22057 else
22058   cat >conftest.$ac_ext <<_ACEOF
22059 /* confdefs.h.  */
22060 _ACEOF
22061 cat confdefs.h >>conftest.$ac_ext
22062 cat >>conftest.$ac_ext <<_ACEOF
22063 /* end confdefs.h.  */
22064 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22065    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22066 #define $ac_func innocuous_$ac_func
22067
22068 /* System header to define __stub macros and hopefully few prototypes,
22069     which can conflict with char $ac_func (); below.
22070     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22071     <limits.h> exists even on freestanding compilers.  */
22072
22073 #ifdef __STDC__
22074 # include <limits.h>
22075 #else
22076 # include <assert.h>
22077 #endif
22078
22079 #undef $ac_func
22080
22081 /* Override any GCC internal prototype to avoid an error.
22082    Use char because int might match the return type of a GCC
22083    builtin and then its argument prototype would still apply.  */
22084 #ifdef __cplusplus
22085 extern "C"
22086 #endif
22087 char $ac_func ();
22088 /* The GNU C library defines this for functions which it implements
22089     to always fail with ENOSYS.  Some functions are actually named
22090     something starting with __ and the normal name is an alias.  */
22091 #if defined __stub_$ac_func || defined __stub___$ac_func
22092 choke me
22093 #endif
22094
22095 int
22096 main ()
22097 {
22098 return $ac_func ();
22099   ;
22100   return 0;
22101 }
22102 _ACEOF
22103 rm -f conftest.$ac_objext conftest$ac_exeext
22104 if { (ac_try="$ac_link"
22105 case "(($ac_try" in
22106   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22107   *) ac_try_echo=$ac_try;;
22108 esac
22109 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22110 $as_echo "$ac_try_echo") >&5
22111   (eval "$ac_link") 2>conftest.er1
22112   ac_status=$?
22113   grep -v '^ *+' conftest.er1 >conftest.err
22114   rm -f conftest.er1
22115   cat conftest.err >&5
22116   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22117   (exit $ac_status); } && {
22118          test -z "$ac_c_werror_flag" ||
22119          test ! -s conftest.err
22120        } && test -s conftest$ac_exeext && {
22121          test "$cross_compiling" = yes ||
22122          $as_test_x conftest$ac_exeext
22123        }; then
22124   eval "$as_ac_var=yes"
22125 else
22126   $as_echo "$as_me: failed program was:" >&5
22127 sed 's/^/| /' conftest.$ac_ext >&5
22128
22129         eval "$as_ac_var=no"
22130 fi
22131
22132 rm -rf conftest.dSYM
22133 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22134       conftest$ac_exeext conftest.$ac_ext
22135 fi
22136 ac_res=`eval 'as_val=${'$as_ac_var'}
22137                  $as_echo "$as_val"'`
22138                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22139 $as_echo "$ac_res" >&6; }
22140 as_val=`eval 'as_val=${'$as_ac_var'}
22141                  $as_echo "$as_val"'`
22142    if test "x$as_val" = x""yes; then
22143   cat >>confdefs.h <<_ACEOF
22144 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22145 _ACEOF
22146  break
22147 fi
22148 done
22149
22150
22151 # Check for one of atexit() or on_exit()
22152
22153 for ac_func in atexit
22154 do
22155 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22156 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22157 $as_echo_n "checking for $ac_func... " >&6; }
22158 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22159   $as_echo_n "(cached) " >&6
22160 else
22161   cat >conftest.$ac_ext <<_ACEOF
22162 /* confdefs.h.  */
22163 _ACEOF
22164 cat confdefs.h >>conftest.$ac_ext
22165 cat >>conftest.$ac_ext <<_ACEOF
22166 /* end confdefs.h.  */
22167 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22168    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22169 #define $ac_func innocuous_$ac_func
22170
22171 /* System header to define __stub macros and hopefully few prototypes,
22172     which can conflict with char $ac_func (); below.
22173     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22174     <limits.h> exists even on freestanding compilers.  */
22175
22176 #ifdef __STDC__
22177 # include <limits.h>
22178 #else
22179 # include <assert.h>
22180 #endif
22181
22182 #undef $ac_func
22183
22184 /* Override any GCC internal prototype to avoid an error.
22185    Use char because int might match the return type of a GCC
22186    builtin and then its argument prototype would still apply.  */
22187 #ifdef __cplusplus
22188 extern "C"
22189 #endif
22190 char $ac_func ();
22191 /* The GNU C library defines this for functions which it implements
22192     to always fail with ENOSYS.  Some functions are actually named
22193     something starting with __ and the normal name is an alias.  */
22194 #if defined __stub_$ac_func || defined __stub___$ac_func
22195 choke me
22196 #endif
22197
22198 int
22199 main ()
22200 {
22201 return $ac_func ();
22202   ;
22203   return 0;
22204 }
22205 _ACEOF
22206 rm -f conftest.$ac_objext conftest$ac_exeext
22207 if { (ac_try="$ac_link"
22208 case "(($ac_try" in
22209   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22210   *) ac_try_echo=$ac_try;;
22211 esac
22212 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22213 $as_echo "$ac_try_echo") >&5
22214   (eval "$ac_link") 2>conftest.er1
22215   ac_status=$?
22216   grep -v '^ *+' conftest.er1 >conftest.err
22217   rm -f conftest.er1
22218   cat conftest.err >&5
22219   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22220   (exit $ac_status); } && {
22221          test -z "$ac_c_werror_flag" ||
22222          test ! -s conftest.err
22223        } && test -s conftest$ac_exeext && {
22224          test "$cross_compiling" = yes ||
22225          $as_test_x conftest$ac_exeext
22226        }; then
22227   eval "$as_ac_var=yes"
22228 else
22229   $as_echo "$as_me: failed program was:" >&5
22230 sed 's/^/| /' conftest.$ac_ext >&5
22231
22232         eval "$as_ac_var=no"
22233 fi
22234
22235 rm -rf conftest.dSYM
22236 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22237       conftest$ac_exeext conftest.$ac_ext
22238 fi
22239 ac_res=`eval 'as_val=${'$as_ac_var'}
22240                  $as_echo "$as_val"'`
22241                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22242 $as_echo "$ac_res" >&6; }
22243 as_val=`eval 'as_val=${'$as_ac_var'}
22244                  $as_echo "$as_val"'`
22245    if test "x$as_val" = x""yes; then
22246   cat >>confdefs.h <<_ACEOF
22247 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22248 _ACEOF
22249
22250 else
22251
22252 for ac_func in on_exit
22253 do
22254 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22255 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22256 $as_echo_n "checking for $ac_func... " >&6; }
22257 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22258   $as_echo_n "(cached) " >&6
22259 else
22260   cat >conftest.$ac_ext <<_ACEOF
22261 /* confdefs.h.  */
22262 _ACEOF
22263 cat confdefs.h >>conftest.$ac_ext
22264 cat >>conftest.$ac_ext <<_ACEOF
22265 /* end confdefs.h.  */
22266 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22267    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22268 #define $ac_func innocuous_$ac_func
22269
22270 /* System header to define __stub macros and hopefully few prototypes,
22271     which can conflict with char $ac_func (); below.
22272     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22273     <limits.h> exists even on freestanding compilers.  */
22274
22275 #ifdef __STDC__
22276 # include <limits.h>
22277 #else
22278 # include <assert.h>
22279 #endif
22280
22281 #undef $ac_func
22282
22283 /* Override any GCC internal prototype to avoid an error.
22284    Use char because int might match the return type of a GCC
22285    builtin and then its argument prototype would still apply.  */
22286 #ifdef __cplusplus
22287 extern "C"
22288 #endif
22289 char $ac_func ();
22290 /* The GNU C library defines this for functions which it implements
22291     to always fail with ENOSYS.  Some functions are actually named
22292     something starting with __ and the normal name is an alias.  */
22293 #if defined __stub_$ac_func || defined __stub___$ac_func
22294 choke me
22295 #endif
22296
22297 int
22298 main ()
22299 {
22300 return $ac_func ();
22301   ;
22302   return 0;
22303 }
22304 _ACEOF
22305 rm -f conftest.$ac_objext conftest$ac_exeext
22306 if { (ac_try="$ac_link"
22307 case "(($ac_try" in
22308   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22309   *) ac_try_echo=$ac_try;;
22310 esac
22311 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22312 $as_echo "$ac_try_echo") >&5
22313   (eval "$ac_link") 2>conftest.er1
22314   ac_status=$?
22315   grep -v '^ *+' conftest.er1 >conftest.err
22316   rm -f conftest.er1
22317   cat conftest.err >&5
22318   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22319   (exit $ac_status); } && {
22320          test -z "$ac_c_werror_flag" ||
22321          test ! -s conftest.err
22322        } && test -s conftest$ac_exeext && {
22323          test "$cross_compiling" = yes ||
22324          $as_test_x conftest$ac_exeext
22325        }; then
22326   eval "$as_ac_var=yes"
22327 else
22328   $as_echo "$as_me: failed program was:" >&5
22329 sed 's/^/| /' conftest.$ac_ext >&5
22330
22331         eval "$as_ac_var=no"
22332 fi
22333
22334 rm -rf conftest.dSYM
22335 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22336       conftest$ac_exeext conftest.$ac_ext
22337 fi
22338 ac_res=`eval 'as_val=${'$as_ac_var'}
22339                  $as_echo "$as_val"'`
22340                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22341 $as_echo "$ac_res" >&6; }
22342 as_val=`eval 'as_val=${'$as_ac_var'}
22343                  $as_echo "$as_val"'`
22344    if test "x$as_val" = x""yes; then
22345   cat >>confdefs.h <<_ACEOF
22346 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22347 _ACEOF
22348
22349 else
22350   { { $as_echo "$as_me:$LINENO: error: neither atexit() nor on_exit() found" >&5
22351 $as_echo "$as_me: error: neither atexit() nor on_exit() found" >&2;}
22352    { (exit 1); exit 1; }; }
22353 fi
22354 done
22355
22356 fi
22357 done
22358
22359
22360
22361 #
22362 # Pthreads
22363 #
22364 # For each platform, we need to know about any special compile and link
22365 # libraries, and whether the normal C function names are thread-safe.
22366 # See the comment at the top of src/port/thread.c for more information.
22367 # WIN32 doesn't need the pthread tests;  it always uses threads
22368 if test "$enable_thread_safety" = yes -a "$PORTNAME" != "win32"; then
22369
22370
22371
22372 ac_ext=c
22373 ac_cpp='$CPP $CPPFLAGS'
22374 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22375 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22376 ac_compiler_gnu=$ac_cv_c_compiler_gnu
22377
22378 acx_pthread_ok=no
22379
22380 # We used to check for pthread.h first, but this fails if pthread.h
22381 # requires special compiler flags (e.g. on True64 or Sequent).
22382 # It gets checked for in the link test anyway.
22383
22384 # First of all, check if the user has set any of the PTHREAD_LIBS,
22385 # etcetera environment variables, and if threads linking works using
22386 # them:
22387 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
22388         save_CFLAGS="$CFLAGS"
22389         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
22390         save_LIBS="$LIBS"
22391         LIBS="$PTHREAD_LIBS $LIBS"
22392         { $as_echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
22393 $as_echo_n "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... " >&6; }
22394         cat >conftest.$ac_ext <<_ACEOF
22395 /* confdefs.h.  */
22396 _ACEOF
22397 cat confdefs.h >>conftest.$ac_ext
22398 cat >>conftest.$ac_ext <<_ACEOF
22399 /* end confdefs.h.  */
22400
22401 /* Override any GCC internal prototype to avoid an error.
22402    Use char because int might match the return type of a GCC
22403    builtin and then its argument prototype would still apply.  */
22404 #ifdef __cplusplus
22405 extern "C"
22406 #endif
22407 char pthread_join ();
22408 int
22409 main ()
22410 {
22411 return pthread_join ();
22412   ;
22413   return 0;
22414 }
22415 _ACEOF
22416 rm -f conftest.$ac_objext conftest$ac_exeext
22417 if { (ac_try="$ac_link"
22418 case "(($ac_try" in
22419   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22420   *) ac_try_echo=$ac_try;;
22421 esac
22422 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22423 $as_echo "$ac_try_echo") >&5
22424   (eval "$ac_link") 2>conftest.er1
22425   ac_status=$?
22426   grep -v '^ *+' conftest.er1 >conftest.err
22427   rm -f conftest.er1
22428   cat conftest.err >&5
22429   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22430   (exit $ac_status); } && {
22431          test -z "$ac_c_werror_flag" ||
22432          test ! -s conftest.err
22433        } && test -s conftest$ac_exeext && {
22434          test "$cross_compiling" = yes ||
22435          $as_test_x conftest$ac_exeext
22436        }; then
22437   acx_pthread_ok=yes
22438 else
22439   $as_echo "$as_me: failed program was:" >&5
22440 sed 's/^/| /' conftest.$ac_ext >&5
22441
22442
22443 fi
22444
22445 rm -rf conftest.dSYM
22446 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22447       conftest$ac_exeext conftest.$ac_ext
22448         { $as_echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
22449 $as_echo "$acx_pthread_ok" >&6; }
22450         if test x"$acx_pthread_ok" = xno; then
22451                 PTHREAD_LIBS=""
22452                 PTHREAD_CFLAGS=""
22453         fi
22454         LIBS="$save_LIBS"
22455         CFLAGS="$save_CFLAGS"
22456 fi
22457
22458 # We must check for the threads library under a number of different
22459 # names; the ordering is very important because some systems
22460 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
22461 # libraries is broken (non-POSIX).
22462
22463 # Create a list of thread flags to try.  Items starting with a "-" are
22464 # C compiler flags, and other items are library names, except for "none"
22465 # which indicates that we try without any flags at all, and "pthread-config"
22466 # which is a program returning the flags for the Pth emulation library.
22467
22468 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config pthreadGC2"
22469
22470 # The ordering *is* (sometimes) important.  Some notes on the
22471 # individual items follow:
22472
22473 # pthreads: AIX (must check this before -lpthread)
22474 # none: in case threads are in libc; should be tried before -Kthread and
22475 #       other compiler flags to prevent continual compiler warnings
22476 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
22477 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
22478 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
22479 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
22480 # -pthreads: Solaris/gcc
22481 # -mthreads: Mingw32/gcc, Lynx/gcc
22482 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
22483 #      doesn't hurt to check since this sometimes defines pthreads too;
22484 #      also defines -D_REENTRANT)
22485 # pthread: Linux, etcetera
22486 # --thread-safe: KAI C++
22487 # pthread-config: use pthread-config program (for GNU Pth library)
22488
22489 case "${host_cpu}-${host_os}" in
22490         *solaris*)
22491
22492         # On Solaris (at least, for some versions), libc contains stubbed
22493         # (non-functional) versions of the pthreads routines, so link-based
22494         # tests will erroneously succeed.  (We need to link with -pthread or
22495         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
22496         # a function called by this macro, so we could check for that, but
22497         # who knows whether they'll stub that too in a future libc.)  So,
22498         # we'll just look for -pthreads and -lpthread first:
22499
22500         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
22501         ;;
22502 esac
22503
22504 if test x"$acx_pthread_ok" = xno; then
22505 for flag in $acx_pthread_flags; do
22506
22507         tryPTHREAD_CFLAGS=""
22508         tryPTHREAD_LIBS=""
22509         case $flag in
22510                 none)
22511                 { $as_echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
22512 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
22513                 ;;
22514
22515                 -*)
22516                 { $as_echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
22517 $as_echo_n "checking whether pthreads work with $flag... " >&6; }
22518                 tryPTHREAD_CFLAGS="$flag"
22519                 ;;
22520
22521                 pthread-config)
22522                 # skip this if we already have flags defined, for PostgreSQL
22523                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
22524                 # Extract the first word of "pthread-config", so it can be a program name with args.
22525 set dummy pthread-config; ac_word=$2
22526 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
22527 $as_echo_n "checking for $ac_word... " >&6; }
22528 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
22529   $as_echo_n "(cached) " >&6
22530 else
22531   if test -n "$acx_pthread_config"; then
22532   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
22533 else
22534 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22535 for as_dir in $PATH
22536 do
22537   IFS=$as_save_IFS
22538   test -z "$as_dir" && as_dir=.
22539   for ac_exec_ext in '' $ac_executable_extensions; do
22540   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
22541     ac_cv_prog_acx_pthread_config="yes"
22542     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22543     break 2
22544   fi
22545 done
22546 done
22547 IFS=$as_save_IFS
22548
22549   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
22550 fi
22551 fi
22552 acx_pthread_config=$ac_cv_prog_acx_pthread_config
22553 if test -n "$acx_pthread_config"; then
22554   { $as_echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
22555 $as_echo "$acx_pthread_config" >&6; }
22556 else
22557   { $as_echo "$as_me:$LINENO: result: no" >&5
22558 $as_echo "no" >&6; }
22559 fi
22560
22561
22562                 if test x"$acx_pthread_config" = xno; then continue; fi
22563                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
22564                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
22565                 ;;
22566
22567                 *)
22568                 { $as_echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
22569 $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
22570                 tryPTHREAD_LIBS="-l$flag"
22571                 ;;
22572         esac
22573
22574         save_LIBS="$LIBS"
22575         save_CFLAGS="$CFLAGS"
22576         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
22577         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
22578
22579         # Check for various functions.  We must include pthread.h,
22580         # since some functions may be macros.  (On the Sequent, we
22581         # need a special flag -Kthread to make this header compile.)
22582         # We check for pthread_join because it is in -lpthread on IRIX
22583         # while pthread_create is in libc.  We check for pthread_attr_init
22584         # due to DEC craziness with -lpthreads.  We check for
22585         # pthread_cleanup_push because it is one of the few pthread
22586         # functions on Solaris that doesn't have a non-functional libc stub.
22587         # We try pthread_create on general principles.
22588         cat >conftest.$ac_ext <<_ACEOF
22589 /* confdefs.h.  */
22590 _ACEOF
22591 cat confdefs.h >>conftest.$ac_ext
22592 cat >>conftest.$ac_ext <<_ACEOF
22593 /* end confdefs.h.  */
22594 #include <pthread.h>
22595 int
22596 main ()
22597 {
22598 pthread_t th; pthread_join(th, 0);
22599                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
22600                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
22601   ;
22602   return 0;
22603 }
22604 _ACEOF
22605 rm -f conftest.$ac_objext conftest$ac_exeext
22606 if { (ac_try="$ac_link"
22607 case "(($ac_try" in
22608   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22609   *) ac_try_echo=$ac_try;;
22610 esac
22611 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22612 $as_echo "$ac_try_echo") >&5
22613   (eval "$ac_link") 2>conftest.er1
22614   ac_status=$?
22615   grep -v '^ *+' conftest.er1 >conftest.err
22616   rm -f conftest.er1
22617   cat conftest.err >&5
22618   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22619   (exit $ac_status); } && {
22620          test -z "$ac_c_werror_flag" ||
22621          test ! -s conftest.err
22622        } && test -s conftest$ac_exeext && {
22623          test "$cross_compiling" = yes ||
22624          $as_test_x conftest$ac_exeext
22625        }; then
22626   acx_pthread_ok=yes
22627 else
22628   $as_echo "$as_me: failed program was:" >&5
22629 sed 's/^/| /' conftest.$ac_ext >&5
22630
22631         acx_pthread_ok=no
22632 fi
22633
22634 rm -rf conftest.dSYM
22635 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22636       conftest$ac_exeext conftest.$ac_ext
22637
22638         if test "x$acx_pthread_ok" = xyes; then
22639             # Don't use options that are ignored by the compiler.
22640             # We find them by checking stderror.
22641             cat >conftest.$ac_ext <<_ACEOF
22642 int
22643 main (int argc, char **argv)
22644 {
22645   (void) argc;
22646   (void) argv;
22647   return 0;
22648 }
22649 _ACEOF
22650             rm -f conftest.$ac_objext conftest$ac_exeext
22651             if test "`(eval $ac_link 2>&1 1>&5)`" = ""; then
22652                 # we continue with more flags because Linux needs -lpthread
22653                 # for libpq builds on PostgreSQL.  The test above only
22654                 # tests for building binaries, not shared libraries.
22655                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
22656                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
22657             else   acx_pthread_ok=no
22658             fi
22659         fi
22660
22661         LIBS="$save_LIBS"
22662         CFLAGS="$save_CFLAGS"
22663
22664         { $as_echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
22665 $as_echo "$acx_pthread_ok" >&6; }
22666 done
22667 fi
22668
22669 # Various other checks:
22670 if test "x$acx_pthread_ok" = xyes; then
22671         save_LIBS="$LIBS"
22672         LIBS="$PTHREAD_LIBS $LIBS"
22673         save_CFLAGS="$CFLAGS"
22674         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
22675
22676         # Detect AIX lossage: threads are created detached by default
22677         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
22678         { $as_echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
22679 $as_echo_n "checking for joinable pthread attribute... " >&6; }
22680         cat >conftest.$ac_ext <<_ACEOF
22681 /* confdefs.h.  */
22682 _ACEOF
22683 cat confdefs.h >>conftest.$ac_ext
22684 cat >>conftest.$ac_ext <<_ACEOF
22685 /* end confdefs.h.  */
22686 #include <pthread.h>
22687 int
22688 main ()
22689 {
22690 int attr=PTHREAD_CREATE_JOINABLE;
22691   ;
22692   return 0;
22693 }
22694 _ACEOF
22695 rm -f conftest.$ac_objext conftest$ac_exeext
22696 if { (ac_try="$ac_link"
22697 case "(($ac_try" in
22698   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22699   *) ac_try_echo=$ac_try;;
22700 esac
22701 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22702 $as_echo "$ac_try_echo") >&5
22703   (eval "$ac_link") 2>conftest.er1
22704   ac_status=$?
22705   grep -v '^ *+' conftest.er1 >conftest.err
22706   rm -f conftest.er1
22707   cat conftest.err >&5
22708   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22709   (exit $ac_status); } && {
22710          test -z "$ac_c_werror_flag" ||
22711          test ! -s conftest.err
22712        } && test -s conftest$ac_exeext && {
22713          test "$cross_compiling" = yes ||
22714          $as_test_x conftest$ac_exeext
22715        }; then
22716   ok=PTHREAD_CREATE_JOINABLE
22717 else
22718   $as_echo "$as_me: failed program was:" >&5
22719 sed 's/^/| /' conftest.$ac_ext >&5
22720
22721         ok=unknown
22722 fi
22723
22724 rm -rf conftest.dSYM
22725 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22726       conftest$ac_exeext conftest.$ac_ext
22727         if test x"$ok" = xunknown; then
22728                 cat >conftest.$ac_ext <<_ACEOF
22729 /* confdefs.h.  */
22730 _ACEOF
22731 cat confdefs.h >>conftest.$ac_ext
22732 cat >>conftest.$ac_ext <<_ACEOF
22733 /* end confdefs.h.  */
22734 #include <pthread.h>
22735 int
22736 main ()
22737 {
22738 int attr=PTHREAD_CREATE_UNDETACHED;
22739   ;
22740   return 0;
22741 }
22742 _ACEOF
22743 rm -f conftest.$ac_objext conftest$ac_exeext
22744 if { (ac_try="$ac_link"
22745 case "(($ac_try" in
22746   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22747   *) ac_try_echo=$ac_try;;
22748 esac
22749 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22750 $as_echo "$ac_try_echo") >&5
22751   (eval "$ac_link") 2>conftest.er1
22752   ac_status=$?
22753   grep -v '^ *+' conftest.er1 >conftest.err
22754   rm -f conftest.er1
22755   cat conftest.err >&5
22756   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22757   (exit $ac_status); } && {
22758          test -z "$ac_c_werror_flag" ||
22759          test ! -s conftest.err
22760        } && test -s conftest$ac_exeext && {
22761          test "$cross_compiling" = yes ||
22762          $as_test_x conftest$ac_exeext
22763        }; then
22764   ok=PTHREAD_CREATE_UNDETACHED
22765 else
22766   $as_echo "$as_me: failed program was:" >&5
22767 sed 's/^/| /' conftest.$ac_ext >&5
22768
22769         ok=unknown
22770 fi
22771
22772 rm -rf conftest.dSYM
22773 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22774       conftest$ac_exeext conftest.$ac_ext
22775         fi
22776         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
22777
22778 cat >>confdefs.h <<\_ACEOF
22779 #define PTHREAD_CREATE_JOINABLE $ok
22780 _ACEOF
22781
22782         fi
22783         { $as_echo "$as_me:$LINENO: result: ${ok}" >&5
22784 $as_echo "${ok}" >&6; }
22785         if test x"$ok" = xunknown; then
22786                 { $as_echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
22787 $as_echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
22788         fi
22789
22790         { $as_echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
22791 $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
22792         flag=no
22793 # We always add these in PostgreSQL
22794 #       case "${host_cpu}-${host_os}" in
22795 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
22796 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
22797 #       esac
22798         { $as_echo "$as_me:$LINENO: result: ${flag}" >&5
22799 $as_echo "${flag}" >&6; }
22800         if test "x$flag" != xno; then
22801                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
22802         fi
22803
22804         LIBS="$save_LIBS"
22805         CFLAGS="$save_CFLAGS"
22806
22807 # Supporting cc_r would require a special CC in all places that
22808 # use libpq, and that is ugly, so we don't do it.  Users can still
22809 # define their compiler as cc_r to do thread builds of everything.
22810         # More AIX lossage: must compile with cc_r
22811         # Extract the first word of "cc_r", so it can be a program name with args.
22812 set dummy cc_r; ac_word=$2
22813 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
22814 $as_echo_n "checking for $ac_word... " >&6; }
22815 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
22816   $as_echo_n "(cached) " >&6
22817 else
22818   if test -n "$PTHREAD_CC"; then
22819   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
22820 else
22821 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22822 for as_dir in $PATH
22823 do
22824   IFS=$as_save_IFS
22825   test -z "$as_dir" && as_dir=.
22826   for ac_exec_ext in '' $ac_executable_extensions; do
22827   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
22828     ac_cv_prog_PTHREAD_CC="cc_r"
22829     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22830     break 2
22831   fi
22832 done
22833 done
22834 IFS=$as_save_IFS
22835
22836   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
22837 fi
22838 fi
22839 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
22840 if test -n "$PTHREAD_CC"; then
22841   { $as_echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
22842 $as_echo "$PTHREAD_CC" >&6; }
22843 else
22844   { $as_echo "$as_me:$LINENO: result: no" >&5
22845 $as_echo "no" >&6; }
22846 fi
22847
22848
22849 else
22850         PTHREAD_CC="$CC"
22851 fi
22852
22853
22854
22855
22856
22857 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
22858 if test x"$acx_pthread_ok" = xyes; then
22859
22860 cat >>confdefs.h <<\_ACEOF
22861 #define HAVE_PTHREAD 1
22862 _ACEOF
22863
22864         :
22865 else
22866         acx_pthread_ok=no
22867
22868 fi
22869 ac_ext=c
22870 ac_cpp='$CPP $CPPFLAGS'
22871 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22872 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22873 ac_compiler_gnu=$ac_cv_c_compiler_gnu
22874
22875         # set thread flags
22876
22877 # Some platforms use these, so just define them.  They can't hurt if they
22878 # are not supported.  For example, on Solaris -D_POSIX_PTHREAD_SEMANTICS
22879 # enables 5-arg getpwuid_r, among other things.
22880 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
22881
22882
22883 # At this point, we don't want to muck with the compiler name for threading.
22884 # Let's see who fails, perhaps AIX.  2004-04-23
22885 if test "$PTHREAD_CC" != "$CC"; then
22886 { { $as_echo "$as_me:$LINENO: error:
22887 PostgreSQL does not support platforms that require a special compiler
22888 for thread safety;  use --disable-thread-safety to disable thread safety." >&5
22889 $as_echo "$as_me: error:
22890 PostgreSQL does not support platforms that require a special compiler
22891 for thread safety;  use --disable-thread-safety to disable thread safety." >&2;}
22892    { (exit 1); exit 1; }; }
22893 fi
22894
22895 # Check for *_r functions
22896 _CFLAGS="$CFLAGS"
22897 _LIBS="$LIBS"
22898 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
22899 LIBS="$LIBS $PTHREAD_LIBS"
22900
22901 if test "$PORTNAME" != "win32"; then
22902 if test "${ac_cv_header_pthread_h+set}" = set; then
22903   { $as_echo "$as_me:$LINENO: checking for pthread.h" >&5
22904 $as_echo_n "checking for pthread.h... " >&6; }
22905 if test "${ac_cv_header_pthread_h+set}" = set; then
22906   $as_echo_n "(cached) " >&6
22907 fi
22908 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
22909 $as_echo "$ac_cv_header_pthread_h" >&6; }
22910 else
22911   # Is the header compilable?
22912 { $as_echo "$as_me:$LINENO: checking pthread.h usability" >&5
22913 $as_echo_n "checking pthread.h usability... " >&6; }
22914 cat >conftest.$ac_ext <<_ACEOF
22915 /* confdefs.h.  */
22916 _ACEOF
22917 cat confdefs.h >>conftest.$ac_ext
22918 cat >>conftest.$ac_ext <<_ACEOF
22919 /* end confdefs.h.  */
22920 $ac_includes_default
22921 #include <pthread.h>
22922 _ACEOF
22923 rm -f conftest.$ac_objext
22924 if { (ac_try="$ac_compile"
22925 case "(($ac_try" in
22926   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22927   *) ac_try_echo=$ac_try;;
22928 esac
22929 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22930 $as_echo "$ac_try_echo") >&5
22931   (eval "$ac_compile") 2>conftest.er1
22932   ac_status=$?
22933   grep -v '^ *+' conftest.er1 >conftest.err
22934   rm -f conftest.er1
22935   cat conftest.err >&5
22936   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22937   (exit $ac_status); } && {
22938          test -z "$ac_c_werror_flag" ||
22939          test ! -s conftest.err
22940        } && test -s conftest.$ac_objext; then
22941   ac_header_compiler=yes
22942 else
22943   $as_echo "$as_me: failed program was:" >&5
22944 sed 's/^/| /' conftest.$ac_ext >&5
22945
22946         ac_header_compiler=no
22947 fi
22948
22949 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22950 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22951 $as_echo "$ac_header_compiler" >&6; }
22952
22953 # Is the header present?
22954 { $as_echo "$as_me:$LINENO: checking pthread.h presence" >&5
22955 $as_echo_n "checking pthread.h presence... " >&6; }
22956 cat >conftest.$ac_ext <<_ACEOF
22957 /* confdefs.h.  */
22958 _ACEOF
22959 cat confdefs.h >>conftest.$ac_ext
22960 cat >>conftest.$ac_ext <<_ACEOF
22961 /* end confdefs.h.  */
22962 #include <pthread.h>
22963 _ACEOF
22964 if { (ac_try="$ac_cpp conftest.$ac_ext"
22965 case "(($ac_try" in
22966   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22967   *) ac_try_echo=$ac_try;;
22968 esac
22969 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22970 $as_echo "$ac_try_echo") >&5
22971   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
22972   ac_status=$?
22973   grep -v '^ *+' conftest.er1 >conftest.err
22974   rm -f conftest.er1
22975   cat conftest.err >&5
22976   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22977   (exit $ac_status); } >/dev/null && {
22978          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
22979          test ! -s conftest.err
22980        }; then
22981   ac_header_preproc=yes
22982 else
22983   $as_echo "$as_me: failed program was:" >&5
22984 sed 's/^/| /' conftest.$ac_ext >&5
22985
22986   ac_header_preproc=no
22987 fi
22988
22989 rm -f conftest.err conftest.$ac_ext
22990 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22991 $as_echo "$ac_header_preproc" >&6; }
22992
22993 # So?  What about this header?
22994 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
22995   yes:no: )
22996     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
22997 $as_echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
22998     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the compiler's result" >&5
22999 $as_echo "$as_me: WARNING: pthread.h: proceeding with the compiler's result" >&2;}
23000     ac_header_preproc=yes
23001     ;;
23002   no:yes:* )
23003     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
23004 $as_echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
23005     { $as_echo "$as_me:$LINENO: WARNING: pthread.h:     check for missing prerequisite headers?" >&5
23006 $as_echo "$as_me: WARNING: pthread.h:     check for missing prerequisite headers?" >&2;}
23007     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: see the Autoconf documentation" >&5
23008 $as_echo "$as_me: WARNING: pthread.h: see the Autoconf documentation" >&2;}
23009     { $as_echo "$as_me:$LINENO: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&5
23010 $as_echo "$as_me: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&2;}
23011     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
23012 $as_echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;}
23013     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: in the future, the compiler will take precedence" >&5
23014 $as_echo "$as_me: WARNING: pthread.h: in the future, the compiler will take precedence" >&2;}
23015     ( cat <<\_ASBOX
23016 ## ---------------------------------------- ##
23017 ## Report this to pgsql-bugs@postgresql.org ##
23018 ## ---------------------------------------- ##
23019 _ASBOX
23020      ) | sed "s/^/$as_me: WARNING:     /" >&2
23021     ;;
23022 esac
23023 { $as_echo "$as_me:$LINENO: checking for pthread.h" >&5
23024 $as_echo_n "checking for pthread.h... " >&6; }
23025 if test "${ac_cv_header_pthread_h+set}" = set; then
23026   $as_echo_n "(cached) " >&6
23027 else
23028   ac_cv_header_pthread_h=$ac_header_preproc
23029 fi
23030 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
23031 $as_echo "$ac_cv_header_pthread_h" >&6; }
23032
23033 fi
23034 if test "x$ac_cv_header_pthread_h" = x""yes; then
23035   :
23036 else
23037   { { $as_echo "$as_me:$LINENO: error:
23038 pthread.h not found;  use --disable-thread-safety to disable thread safety" >&5
23039 $as_echo "$as_me: error:
23040 pthread.h not found;  use --disable-thread-safety to disable thread safety" >&2;}
23041    { (exit 1); exit 1; }; }
23042 fi
23043
23044
23045 fi
23046
23047
23048
23049
23050 for ac_func in strerror_r getpwuid_r gethostbyname_r
23051 do
23052 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
23053 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
23054 $as_echo_n "checking for $ac_func... " >&6; }
23055 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
23056   $as_echo_n "(cached) " >&6
23057 else
23058   cat >conftest.$ac_ext <<_ACEOF
23059 /* confdefs.h.  */
23060 _ACEOF
23061 cat confdefs.h >>conftest.$ac_ext
23062 cat >>conftest.$ac_ext <<_ACEOF
23063 /* end confdefs.h.  */
23064 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
23065    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
23066 #define $ac_func innocuous_$ac_func
23067
23068 /* System header to define __stub macros and hopefully few prototypes,
23069     which can conflict with char $ac_func (); below.
23070     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
23071     <limits.h> exists even on freestanding compilers.  */
23072
23073 #ifdef __STDC__
23074 # include <limits.h>
23075 #else
23076 # include <assert.h>
23077 #endif
23078
23079 #undef $ac_func
23080
23081 /* Override any GCC internal prototype to avoid an error.
23082    Use char because int might match the return type of a GCC
23083    builtin and then its argument prototype would still apply.  */
23084 #ifdef __cplusplus
23085 extern "C"
23086 #endif
23087 char $ac_func ();
23088 /* The GNU C library defines this for functions which it implements
23089     to always fail with ENOSYS.  Some functions are actually named
23090     something starting with __ and the normal name is an alias.  */
23091 #if defined __stub_$ac_func || defined __stub___$ac_func
23092 choke me
23093 #endif
23094
23095 int
23096 main ()
23097 {
23098 return $ac_func ();
23099   ;
23100   return 0;
23101 }
23102 _ACEOF
23103 rm -f conftest.$ac_objext conftest$ac_exeext
23104 if { (ac_try="$ac_link"
23105 case "(($ac_try" in
23106   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23107   *) ac_try_echo=$ac_try;;
23108 esac
23109 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23110 $as_echo "$ac_try_echo") >&5
23111   (eval "$ac_link") 2>conftest.er1
23112   ac_status=$?
23113   grep -v '^ *+' conftest.er1 >conftest.err
23114   rm -f conftest.er1
23115   cat conftest.err >&5
23116   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23117   (exit $ac_status); } && {
23118          test -z "$ac_c_werror_flag" ||
23119          test ! -s conftest.err
23120        } && test -s conftest$ac_exeext && {
23121          test "$cross_compiling" = yes ||
23122          $as_test_x conftest$ac_exeext
23123        }; then
23124   eval "$as_ac_var=yes"
23125 else
23126   $as_echo "$as_me: failed program was:" >&5
23127 sed 's/^/| /' conftest.$ac_ext >&5
23128
23129         eval "$as_ac_var=no"
23130 fi
23131
23132 rm -rf conftest.dSYM
23133 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23134       conftest$ac_exeext conftest.$ac_ext
23135 fi
23136 ac_res=`eval 'as_val=${'$as_ac_var'}
23137                  $as_echo "$as_val"'`
23138                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
23139 $as_echo "$ac_res" >&6; }
23140 as_val=`eval 'as_val=${'$as_ac_var'}
23141                  $as_echo "$as_val"'`
23142    if test "x$as_val" = x""yes; then
23143   cat >>confdefs.h <<_ACEOF
23144 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23145 _ACEOF
23146
23147 fi
23148 done
23149
23150
23151 # Do test here with the proper thread flags
23152 { $as_echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
23153 $as_echo_n "checking whether getpwuid_r takes a fifth argument... " >&6; }
23154 if test "${pgac_cv_func_getpwuid_r_5arg+set}" = set; then
23155   $as_echo_n "(cached) " >&6
23156 else
23157   cat >conftest.$ac_ext <<_ACEOF
23158 /* confdefs.h.  */
23159 _ACEOF
23160 cat confdefs.h >>conftest.$ac_ext
23161 cat >>conftest.$ac_ext <<_ACEOF
23162 /* end confdefs.h.  */
23163 #include <sys/types.h>
23164 #include <pwd.h>
23165 int
23166 main ()
23167 {
23168 uid_t uid;
23169 struct passwd *space;
23170 char *buf;
23171 size_t bufsize;
23172 struct passwd **result;
23173 getpwuid_r(uid, space, buf, bufsize, result);
23174   ;
23175   return 0;
23176 }
23177 _ACEOF
23178 rm -f conftest.$ac_objext
23179 if { (ac_try="$ac_compile"
23180 case "(($ac_try" in
23181   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23182   *) ac_try_echo=$ac_try;;
23183 esac
23184 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23185 $as_echo "$ac_try_echo") >&5
23186   (eval "$ac_compile") 2>conftest.er1
23187   ac_status=$?
23188   grep -v '^ *+' conftest.er1 >conftest.err
23189   rm -f conftest.er1
23190   cat conftest.err >&5
23191   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23192   (exit $ac_status); } && {
23193          test -z "$ac_c_werror_flag" ||
23194          test ! -s conftest.err
23195        } && test -s conftest.$ac_objext; then
23196   pgac_cv_func_getpwuid_r_5arg=yes
23197 else
23198   $as_echo "$as_me: failed program was:" >&5
23199 sed 's/^/| /' conftest.$ac_ext >&5
23200
23201         pgac_cv_func_getpwuid_r_5arg=no
23202 fi
23203
23204 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23205 fi
23206 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_getpwuid_r_5arg" >&5
23207 $as_echo "$pgac_cv_func_getpwuid_r_5arg" >&6; }
23208 if test x"$pgac_cv_func_getpwuid_r_5arg" = xyes ; then
23209
23210 cat >>confdefs.h <<\_ACEOF
23211 #define GETPWUID_R_5ARG /**/
23212 _ACEOF
23213
23214 fi
23215
23216 { $as_echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
23217 $as_echo_n "checking whether strerror_r returns int... " >&6; }
23218 if test "${pgac_cv_func_strerror_r_int+set}" = set; then
23219   $as_echo_n "(cached) " >&6
23220 else
23221   cat >conftest.$ac_ext <<_ACEOF
23222 /* confdefs.h.  */
23223 _ACEOF
23224 cat confdefs.h >>conftest.$ac_ext
23225 cat >>conftest.$ac_ext <<_ACEOF
23226 /* end confdefs.h.  */
23227 #include <string.h>
23228 int
23229 main ()
23230 {
23231 #ifndef _AIX
23232 int strerror_r(int, char *, size_t);
23233 #else
23234 /* Older AIX has 'int' for the third argument so we don't test the args. */
23235 int strerror_r();
23236 #endif
23237   ;
23238   return 0;
23239 }
23240 _ACEOF
23241 rm -f conftest.$ac_objext
23242 if { (ac_try="$ac_compile"
23243 case "(($ac_try" in
23244   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23245   *) ac_try_echo=$ac_try;;
23246 esac
23247 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23248 $as_echo "$ac_try_echo") >&5
23249   (eval "$ac_compile") 2>conftest.er1
23250   ac_status=$?
23251   grep -v '^ *+' conftest.er1 >conftest.err
23252   rm -f conftest.er1
23253   cat conftest.err >&5
23254   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23255   (exit $ac_status); } && {
23256          test -z "$ac_c_werror_flag" ||
23257          test ! -s conftest.err
23258        } && test -s conftest.$ac_objext; then
23259   pgac_cv_func_strerror_r_int=yes
23260 else
23261   $as_echo "$as_me: failed program was:" >&5
23262 sed 's/^/| /' conftest.$ac_ext >&5
23263
23264         pgac_cv_func_strerror_r_int=no
23265 fi
23266
23267 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23268 fi
23269 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_strerror_r_int" >&5
23270 $as_echo "$pgac_cv_func_strerror_r_int" >&6; }
23271 if test x"$pgac_cv_func_strerror_r_int" = xyes ; then
23272
23273 cat >>confdefs.h <<\_ACEOF
23274 #define STRERROR_R_INT /**/
23275 _ACEOF
23276
23277 fi
23278
23279
23280 CFLAGS="$_CFLAGS"
23281 LIBS="$_LIBS"
23282
23283 else
23284 # do not use values from template file
23285 PTHREAD_CFLAGS=
23286 PTHREAD_LIBS=
23287 fi
23288
23289
23290
23291
23292
23293 # We can test for libldap_r only after we know PTHREAD_LIBS
23294 if test "$with_ldap" = yes ; then
23295   _LIBS="$LIBS"
23296   if test "$PORTNAME" != "win32"; then
23297
23298 { $as_echo "$as_me:$LINENO: checking for ldap_bind in -lldap" >&5
23299 $as_echo_n "checking for ldap_bind in -lldap... " >&6; }
23300 if test "${ac_cv_lib_ldap_ldap_bind+set}" = set; then
23301   $as_echo_n "(cached) " >&6
23302 else
23303   ac_check_lib_save_LIBS=$LIBS
23304 LIBS="-lldap $EXTRA_LDAP_LIBS $LIBS"
23305 cat >conftest.$ac_ext <<_ACEOF
23306 /* confdefs.h.  */
23307 _ACEOF
23308 cat confdefs.h >>conftest.$ac_ext
23309 cat >>conftest.$ac_ext <<_ACEOF
23310 /* end confdefs.h.  */
23311
23312 /* Override any GCC internal prototype to avoid an error.
23313    Use char because int might match the return type of a GCC
23314    builtin and then its argument prototype would still apply.  */
23315 #ifdef __cplusplus
23316 extern "C"
23317 #endif
23318 char ldap_bind ();
23319 int
23320 main ()
23321 {
23322 return ldap_bind ();
23323   ;
23324   return 0;
23325 }
23326 _ACEOF
23327 rm -f conftest.$ac_objext conftest$ac_exeext
23328 if { (ac_try="$ac_link"
23329 case "(($ac_try" in
23330   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23331   *) ac_try_echo=$ac_try;;
23332 esac
23333 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23334 $as_echo "$ac_try_echo") >&5
23335   (eval "$ac_link") 2>conftest.er1
23336   ac_status=$?
23337   grep -v '^ *+' conftest.er1 >conftest.err
23338   rm -f conftest.er1
23339   cat conftest.err >&5
23340   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23341   (exit $ac_status); } && {
23342          test -z "$ac_c_werror_flag" ||
23343          test ! -s conftest.err
23344        } && test -s conftest$ac_exeext && {
23345          test "$cross_compiling" = yes ||
23346          $as_test_x conftest$ac_exeext
23347        }; then
23348   ac_cv_lib_ldap_ldap_bind=yes
23349 else
23350   $as_echo "$as_me: failed program was:" >&5
23351 sed 's/^/| /' conftest.$ac_ext >&5
23352
23353         ac_cv_lib_ldap_ldap_bind=no
23354 fi
23355
23356 rm -rf conftest.dSYM
23357 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23358       conftest$ac_exeext conftest.$ac_ext
23359 LIBS=$ac_check_lib_save_LIBS
23360 fi
23361 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_ldap_bind" >&5
23362 $as_echo "$ac_cv_lib_ldap_ldap_bind" >&6; }
23363 if test "x$ac_cv_lib_ldap_ldap_bind" = x""yes; then
23364   cat >>confdefs.h <<_ACEOF
23365 #define HAVE_LIBLDAP 1
23366 _ACEOF
23367
23368   LIBS="-lldap $LIBS"
23369
23370 else
23371   { { $as_echo "$as_me:$LINENO: error: library 'ldap' is required for LDAP" >&5
23372 $as_echo "$as_me: error: library 'ldap' is required for LDAP" >&2;}
23373    { (exit 1); exit 1; }; }
23374 fi
23375
23376     LDAP_LIBS_BE="-lldap $EXTRA_LDAP_LIBS"
23377     if test "$enable_thread_safety" = yes; then
23378       # on some platforms ldap_r fails to link without PTHREAD_LIBS
23379
23380 { $as_echo "$as_me:$LINENO: checking for ldap_simple_bind in -lldap_r" >&5
23381 $as_echo_n "checking for ldap_simple_bind in -lldap_r... " >&6; }
23382 if test "${ac_cv_lib_ldap_r_ldap_simple_bind+set}" = set; then
23383   $as_echo_n "(cached) " >&6
23384 else
23385   ac_check_lib_save_LIBS=$LIBS
23386 LIBS="-lldap_r $PTHREAD_CFLAGS $PTHREAD_LIBS $EXTRA_LDAP_LIBS $LIBS"
23387 cat >conftest.$ac_ext <<_ACEOF
23388 /* confdefs.h.  */
23389 _ACEOF
23390 cat confdefs.h >>conftest.$ac_ext
23391 cat >>conftest.$ac_ext <<_ACEOF
23392 /* end confdefs.h.  */
23393
23394 /* Override any GCC internal prototype to avoid an error.
23395    Use char because int might match the return type of a GCC
23396    builtin and then its argument prototype would still apply.  */
23397 #ifdef __cplusplus
23398 extern "C"
23399 #endif
23400 char ldap_simple_bind ();
23401 int
23402 main ()
23403 {
23404 return ldap_simple_bind ();
23405   ;
23406   return 0;
23407 }
23408 _ACEOF
23409 rm -f conftest.$ac_objext conftest$ac_exeext
23410 if { (ac_try="$ac_link"
23411 case "(($ac_try" in
23412   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23413   *) ac_try_echo=$ac_try;;
23414 esac
23415 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23416 $as_echo "$ac_try_echo") >&5
23417   (eval "$ac_link") 2>conftest.er1
23418   ac_status=$?
23419   grep -v '^ *+' conftest.er1 >conftest.err
23420   rm -f conftest.er1
23421   cat conftest.err >&5
23422   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23423   (exit $ac_status); } && {
23424          test -z "$ac_c_werror_flag" ||
23425          test ! -s conftest.err
23426        } && test -s conftest$ac_exeext && {
23427          test "$cross_compiling" = yes ||
23428          $as_test_x conftest$ac_exeext
23429        }; then
23430   ac_cv_lib_ldap_r_ldap_simple_bind=yes
23431 else
23432   $as_echo "$as_me: failed program was:" >&5
23433 sed 's/^/| /' conftest.$ac_ext >&5
23434
23435         ac_cv_lib_ldap_r_ldap_simple_bind=no
23436 fi
23437
23438 rm -rf conftest.dSYM
23439 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23440       conftest$ac_exeext conftest.$ac_ext
23441 LIBS=$ac_check_lib_save_LIBS
23442 fi
23443 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_r_ldap_simple_bind" >&5
23444 $as_echo "$ac_cv_lib_ldap_r_ldap_simple_bind" >&6; }
23445 if test "x$ac_cv_lib_ldap_r_ldap_simple_bind" = x""yes; then
23446   cat >>confdefs.h <<_ACEOF
23447 #define HAVE_LIBLDAP_R 1
23448 _ACEOF
23449
23450   LIBS="-lldap_r $LIBS"
23451
23452 else
23453   { { $as_echo "$as_me:$LINENO: error: library 'ldap_r' is required for LDAP" >&5
23454 $as_echo "$as_me: error: library 'ldap_r' is required for LDAP" >&2;}
23455    { (exit 1); exit 1; }; }
23456 fi
23457
23458       LDAP_LIBS_FE="-lldap_r $EXTRA_LDAP_LIBS"
23459     else
23460       LDAP_LIBS_FE="-lldap $EXTRA_LDAP_LIBS"
23461     fi
23462   else
23463
23464 { $as_echo "$as_me:$LINENO: checking for ldap_bind in -lwldap32" >&5
23465 $as_echo_n "checking for ldap_bind in -lwldap32... " >&6; }
23466 if test "${ac_cv_lib_wldap32_ldap_bind+set}" = set; then
23467   $as_echo_n "(cached) " >&6
23468 else
23469   ac_check_lib_save_LIBS=$LIBS
23470 LIBS="-lwldap32  $LIBS"
23471 cat >conftest.$ac_ext <<_ACEOF
23472 /* confdefs.h.  */
23473 _ACEOF
23474 cat confdefs.h >>conftest.$ac_ext
23475 cat >>conftest.$ac_ext <<_ACEOF
23476 /* end confdefs.h.  */
23477
23478 /* Override any GCC internal prototype to avoid an error.
23479    Use char because int might match the return type of a GCC
23480    builtin and then its argument prototype would still apply.  */
23481 #ifdef __cplusplus
23482 extern "C"
23483 #endif
23484 char ldap_bind ();
23485 int
23486 main ()
23487 {
23488 return ldap_bind ();
23489   ;
23490   return 0;
23491 }
23492 _ACEOF
23493 rm -f conftest.$ac_objext conftest$ac_exeext
23494 if { (ac_try="$ac_link"
23495 case "(($ac_try" in
23496   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23497   *) ac_try_echo=$ac_try;;
23498 esac
23499 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23500 $as_echo "$ac_try_echo") >&5
23501   (eval "$ac_link") 2>conftest.er1
23502   ac_status=$?
23503   grep -v '^ *+' conftest.er1 >conftest.err
23504   rm -f conftest.er1
23505   cat conftest.err >&5
23506   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23507   (exit $ac_status); } && {
23508          test -z "$ac_c_werror_flag" ||
23509          test ! -s conftest.err
23510        } && test -s conftest$ac_exeext && {
23511          test "$cross_compiling" = yes ||
23512          $as_test_x conftest$ac_exeext
23513        }; then
23514   ac_cv_lib_wldap32_ldap_bind=yes
23515 else
23516   $as_echo "$as_me: failed program was:" >&5
23517 sed 's/^/| /' conftest.$ac_ext >&5
23518
23519         ac_cv_lib_wldap32_ldap_bind=no
23520 fi
23521
23522 rm -rf conftest.dSYM
23523 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23524       conftest$ac_exeext conftest.$ac_ext
23525 LIBS=$ac_check_lib_save_LIBS
23526 fi
23527 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_wldap32_ldap_bind" >&5
23528 $as_echo "$ac_cv_lib_wldap32_ldap_bind" >&6; }
23529 if test "x$ac_cv_lib_wldap32_ldap_bind" = x""yes; then
23530   cat >>confdefs.h <<_ACEOF
23531 #define HAVE_LIBWLDAP32 1
23532 _ACEOF
23533
23534   LIBS="-lwldap32 $LIBS"
23535
23536 else
23537   { { $as_echo "$as_me:$LINENO: error: library 'wldap32' is required for LDAP" >&5
23538 $as_echo "$as_me: error: library 'wldap32' is required for LDAP" >&2;}
23539    { (exit 1); exit 1; }; }
23540 fi
23541
23542     LDAP_LIBS_FE="-lwldap32"
23543     LDAP_LIBS_BE="-lwldap32"
23544   fi
23545   LIBS="$_LIBS"
23546 fi
23547
23548
23549
23550
23551 # This test makes sure that run tests work at all.  Sometimes a shared
23552 # library is found by the linker, but the runtime linker can't find it.
23553 # This check should come after all modifications of compiler or linker
23554 # variables, and before any other run tests.
23555 { $as_echo "$as_me:$LINENO: checking test program" >&5
23556 $as_echo_n "checking test program... " >&6; }
23557 if test "$cross_compiling" = yes; then
23558   { $as_echo "$as_me:$LINENO: result: cross-compiling" >&5
23559 $as_echo "cross-compiling" >&6; }
23560 else
23561   cat >conftest.$ac_ext <<_ACEOF
23562 /* confdefs.h.  */
23563 _ACEOF
23564 cat confdefs.h >>conftest.$ac_ext
23565 cat >>conftest.$ac_ext <<_ACEOF
23566 /* end confdefs.h.  */
23567 int main() { return 0; }
23568 _ACEOF
23569 rm -f conftest$ac_exeext
23570 if { (ac_try="$ac_link"
23571 case "(($ac_try" in
23572   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23573   *) ac_try_echo=$ac_try;;
23574 esac
23575 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23576 $as_echo "$ac_try_echo") >&5
23577   (eval "$ac_link") 2>&5
23578   ac_status=$?
23579   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23580   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23581   { (case "(($ac_try" in
23582   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23583   *) ac_try_echo=$ac_try;;
23584 esac
23585 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23586 $as_echo "$ac_try_echo") >&5
23587   (eval "$ac_try") 2>&5
23588   ac_status=$?
23589   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23590   (exit $ac_status); }; }; then
23591   { $as_echo "$as_me:$LINENO: result: ok" >&5
23592 $as_echo "ok" >&6; }
23593 else
23594   $as_echo "$as_me: program exited with status $ac_status" >&5
23595 $as_echo "$as_me: failed program was:" >&5
23596 sed 's/^/| /' conftest.$ac_ext >&5
23597
23598 ( exit $ac_status )
23599 { $as_echo "$as_me:$LINENO: result: failed" >&5
23600 $as_echo "failed" >&6; }
23601 { { $as_echo "$as_me:$LINENO: error:
23602 Could not execute a simple test program.  This may be a problem
23603 related to locating shared libraries.  Check the file 'config.log'
23604 for the exact reason." >&5
23605 $as_echo "$as_me: error:
23606 Could not execute a simple test program.  This may be a problem
23607 related to locating shared libraries.  Check the file 'config.log'
23608 for the exact reason." >&2;}
23609    { (exit 1); exit 1; }; }
23610 fi
23611 rm -rf conftest.dSYM
23612 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23613 fi
23614
23615
23616
23617 # --------------------
23618 # Run tests below here
23619 # --------------------
23620
23621 # Force use of our snprintf if system's doesn't do arg control
23622 # See comment above at snprintf test for details.
23623 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
23624   { $as_echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
23625 $as_echo_n "checking whether printf supports argument control... " >&6; }
23626 if test "${pgac_cv_printf_arg_control+set}" = set; then
23627   $as_echo_n "(cached) " >&6
23628 else
23629   if test "$cross_compiling" = yes; then
23630   pgac_cv_printf_arg_control=cross
23631 else
23632   cat >conftest.$ac_ext <<_ACEOF
23633 /* confdefs.h.  */
23634 _ACEOF
23635 cat confdefs.h >>conftest.$ac_ext
23636 cat >>conftest.$ac_ext <<_ACEOF
23637 /* end confdefs.h.  */
23638 #include <stdio.h>
23639 #include <string.h>
23640
23641 int main()
23642 {
23643   char buf[100];
23644
23645   /* can it swap arguments? */
23646   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
23647   if (strcmp(buf, "4 3") != 0)
23648     return 1;
23649   return 0;
23650 }
23651 _ACEOF
23652 rm -f conftest$ac_exeext
23653 if { (ac_try="$ac_link"
23654 case "(($ac_try" in
23655   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23656   *) ac_try_echo=$ac_try;;
23657 esac
23658 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23659 $as_echo "$ac_try_echo") >&5
23660   (eval "$ac_link") 2>&5
23661   ac_status=$?
23662   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23663   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23664   { (case "(($ac_try" in
23665   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23666   *) ac_try_echo=$ac_try;;
23667 esac
23668 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23669 $as_echo "$ac_try_echo") >&5
23670   (eval "$ac_try") 2>&5
23671   ac_status=$?
23672   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23673   (exit $ac_status); }; }; then
23674   pgac_cv_printf_arg_control=yes
23675 else
23676   $as_echo "$as_me: program exited with status $ac_status" >&5
23677 $as_echo "$as_me: failed program was:" >&5
23678 sed 's/^/| /' conftest.$ac_ext >&5
23679
23680 ( exit $ac_status )
23681 pgac_cv_printf_arg_control=no
23682 fi
23683 rm -rf conftest.dSYM
23684 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23685 fi
23686
23687
23688
23689 fi
23690 { $as_echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
23691 $as_echo "$pgac_cv_printf_arg_control" >&6; }
23692
23693   if test $pgac_cv_printf_arg_control != yes ; then
23694     pgac_need_repl_snprintf=yes
23695   fi
23696 fi
23697
23698
23699
23700
23701 { $as_echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
23702 $as_echo_n "checking whether long int is 64 bits... " >&6; }
23703 if test "${pgac_cv_type_long_int_64+set}" = set; then
23704   $as_echo_n "(cached) " >&6
23705 else
23706   if test "$cross_compiling" = yes; then
23707   # If cross-compiling, check the size reported by the compiler and
23708 # trust that the arithmetic works.
23709 cat >conftest.$ac_ext <<_ACEOF
23710 /* confdefs.h.  */
23711 _ACEOF
23712 cat confdefs.h >>conftest.$ac_ext
23713 cat >>conftest.$ac_ext <<_ACEOF
23714 /* end confdefs.h.  */
23715
23716 int
23717 main ()
23718 {
23719 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
23720 test_array [0] = 0
23721
23722   ;
23723   return 0;
23724 }
23725 _ACEOF
23726 rm -f conftest.$ac_objext
23727 if { (ac_try="$ac_compile"
23728 case "(($ac_try" in
23729   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23730   *) ac_try_echo=$ac_try;;
23731 esac
23732 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23733 $as_echo "$ac_try_echo") >&5
23734   (eval "$ac_compile") 2>conftest.er1
23735   ac_status=$?
23736   grep -v '^ *+' conftest.er1 >conftest.err
23737   rm -f conftest.er1
23738   cat conftest.err >&5
23739   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23740   (exit $ac_status); } && {
23741          test -z "$ac_c_werror_flag" ||
23742          test ! -s conftest.err
23743        } && test -s conftest.$ac_objext; then
23744   pgac_cv_type_long_int_64=yes
23745 else
23746   $as_echo "$as_me: failed program was:" >&5
23747 sed 's/^/| /' conftest.$ac_ext >&5
23748
23749         pgac_cv_type_long_int_64=no
23750 fi
23751
23752 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23753 else
23754   cat >conftest.$ac_ext <<_ACEOF
23755 /* confdefs.h.  */
23756 _ACEOF
23757 cat confdefs.h >>conftest.$ac_ext
23758 cat >>conftest.$ac_ext <<_ACEOF
23759 /* end confdefs.h.  */
23760 typedef long int ac_int64;
23761
23762 /*
23763  * These are globals to discourage the compiler from folding all the
23764  * arithmetic tests down to compile-time constants.
23765  */
23766 ac_int64 a = 20000001;
23767 ac_int64 b = 40000005;
23768
23769 int does_int64_work()
23770 {
23771   ac_int64 c,d;
23772
23773   if (sizeof(ac_int64) != 8)
23774     return 0;                   /* definitely not the right size */
23775
23776   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
23777   c = a * b;
23778   d = (c + b) / b;
23779   if (d != a+1)
23780     return 0;
23781   return 1;
23782 }
23783 main() {
23784   exit(! does_int64_work());
23785 }
23786 _ACEOF
23787 rm -f conftest$ac_exeext
23788 if { (ac_try="$ac_link"
23789 case "(($ac_try" in
23790   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23791   *) ac_try_echo=$ac_try;;
23792 esac
23793 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23794 $as_echo "$ac_try_echo") >&5
23795   (eval "$ac_link") 2>&5
23796   ac_status=$?
23797   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23798   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23799   { (case "(($ac_try" in
23800   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23801   *) ac_try_echo=$ac_try;;
23802 esac
23803 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23804 $as_echo "$ac_try_echo") >&5
23805   (eval "$ac_try") 2>&5
23806   ac_status=$?
23807   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23808   (exit $ac_status); }; }; then
23809   pgac_cv_type_long_int_64=yes
23810 else
23811   $as_echo "$as_me: program exited with status $ac_status" >&5
23812 $as_echo "$as_me: failed program was:" >&5
23813 sed 's/^/| /' conftest.$ac_ext >&5
23814
23815 ( exit $ac_status )
23816 pgac_cv_type_long_int_64=no
23817 fi
23818 rm -rf conftest.dSYM
23819 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23820 fi
23821
23822
23823 fi
23824 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
23825 $as_echo "$pgac_cv_type_long_int_64" >&6; }
23826
23827 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
23828 if test x"$pgac_cv_type_long_int_64" = xyes ; then
23829
23830 cat >>confdefs.h <<\_ACEOF
23831 #define HAVE_LONG_INT_64 1
23832 _ACEOF
23833
23834 fi
23835
23836
23837 if test x"$HAVE_LONG_INT_64" = x"no" ; then
23838   { $as_echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
23839 $as_echo_n "checking whether long long int is 64 bits... " >&6; }
23840 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
23841   $as_echo_n "(cached) " >&6
23842 else
23843   if test "$cross_compiling" = yes; then
23844   # If cross-compiling, check the size reported by the compiler and
23845 # trust that the arithmetic works.
23846 cat >conftest.$ac_ext <<_ACEOF
23847 /* confdefs.h.  */
23848 _ACEOF
23849 cat confdefs.h >>conftest.$ac_ext
23850 cat >>conftest.$ac_ext <<_ACEOF
23851 /* end confdefs.h.  */
23852
23853 int
23854 main ()
23855 {
23856 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
23857 test_array [0] = 0
23858
23859   ;
23860   return 0;
23861 }
23862 _ACEOF
23863 rm -f conftest.$ac_objext
23864 if { (ac_try="$ac_compile"
23865 case "(($ac_try" in
23866   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23867   *) ac_try_echo=$ac_try;;
23868 esac
23869 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23870 $as_echo "$ac_try_echo") >&5
23871   (eval "$ac_compile") 2>conftest.er1
23872   ac_status=$?
23873   grep -v '^ *+' conftest.er1 >conftest.err
23874   rm -f conftest.er1
23875   cat conftest.err >&5
23876   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23877   (exit $ac_status); } && {
23878          test -z "$ac_c_werror_flag" ||
23879          test ! -s conftest.err
23880        } && test -s conftest.$ac_objext; then
23881   pgac_cv_type_long_long_int_64=yes
23882 else
23883   $as_echo "$as_me: failed program was:" >&5
23884 sed 's/^/| /' conftest.$ac_ext >&5
23885
23886         pgac_cv_type_long_long_int_64=no
23887 fi
23888
23889 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23890 else
23891   cat >conftest.$ac_ext <<_ACEOF
23892 /* confdefs.h.  */
23893 _ACEOF
23894 cat confdefs.h >>conftest.$ac_ext
23895 cat >>conftest.$ac_ext <<_ACEOF
23896 /* end confdefs.h.  */
23897 typedef long long int ac_int64;
23898
23899 /*
23900  * These are globals to discourage the compiler from folding all the
23901  * arithmetic tests down to compile-time constants.
23902  */
23903 ac_int64 a = 20000001;
23904 ac_int64 b = 40000005;
23905
23906 int does_int64_work()
23907 {
23908   ac_int64 c,d;
23909
23910   if (sizeof(ac_int64) != 8)
23911     return 0;                   /* definitely not the right size */
23912
23913   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
23914   c = a * b;
23915   d = (c + b) / b;
23916   if (d != a+1)
23917     return 0;
23918   return 1;
23919 }
23920 main() {
23921   exit(! does_int64_work());
23922 }
23923 _ACEOF
23924 rm -f conftest$ac_exeext
23925 if { (ac_try="$ac_link"
23926 case "(($ac_try" in
23927   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23928   *) ac_try_echo=$ac_try;;
23929 esac
23930 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23931 $as_echo "$ac_try_echo") >&5
23932   (eval "$ac_link") 2>&5
23933   ac_status=$?
23934   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23935   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23936   { (case "(($ac_try" in
23937   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23938   *) ac_try_echo=$ac_try;;
23939 esac
23940 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23941 $as_echo "$ac_try_echo") >&5
23942   (eval "$ac_try") 2>&5
23943   ac_status=$?
23944   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23945   (exit $ac_status); }; }; then
23946   pgac_cv_type_long_long_int_64=yes
23947 else
23948   $as_echo "$as_me: program exited with status $ac_status" >&5
23949 $as_echo "$as_me: failed program was:" >&5
23950 sed 's/^/| /' conftest.$ac_ext >&5
23951
23952 ( exit $ac_status )
23953 pgac_cv_type_long_long_int_64=no
23954 fi
23955 rm -rf conftest.dSYM
23956 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23957 fi
23958
23959
23960 fi
23961 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
23962 $as_echo "$pgac_cv_type_long_long_int_64" >&6; }
23963
23964 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
23965 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
23966
23967 cat >>confdefs.h <<\_ACEOF
23968 #define HAVE_LONG_LONG_INT_64 1
23969 _ACEOF
23970
23971 fi
23972
23973   if test x"$HAVE_LONG_LONG_INT_64" = x"no" ; then
23974     { { $as_echo "$as_me:$LINENO: error: Cannot find a working 64-bit integer type." >&5
23975 $as_echo "$as_me: error: Cannot find a working 64-bit integer type." >&2;}
23976    { (exit 1); exit 1; }; }
23977   fi
23978 fi
23979
23980
23981
23982 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
23983   cat >conftest.$ac_ext <<_ACEOF
23984 /* confdefs.h.  */
23985 _ACEOF
23986 cat confdefs.h >>conftest.$ac_ext
23987 cat >>conftest.$ac_ext <<_ACEOF
23988 /* end confdefs.h.  */
23989
23990 #define INT64CONST(x)  x##LL
23991 long long int foo = INT64CONST(0x1234567890123456);
23992
23993 int
23994 main ()
23995 {
23996
23997   ;
23998   return 0;
23999 }
24000 _ACEOF
24001 rm -f conftest.$ac_objext
24002 if { (ac_try="$ac_compile"
24003 case "(($ac_try" in
24004   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24005   *) ac_try_echo=$ac_try;;
24006 esac
24007 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24008 $as_echo "$ac_try_echo") >&5
24009   (eval "$ac_compile") 2>conftest.er1
24010   ac_status=$?
24011   grep -v '^ *+' conftest.er1 >conftest.err
24012   rm -f conftest.er1
24013   cat conftest.err >&5
24014   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24015   (exit $ac_status); } && {
24016          test -z "$ac_c_werror_flag" ||
24017          test ! -s conftest.err
24018        } && test -s conftest.$ac_objext; then
24019
24020 cat >>confdefs.h <<\_ACEOF
24021 #define HAVE_LL_CONSTANTS 1
24022 _ACEOF
24023
24024 else
24025   $as_echo "$as_me: failed program was:" >&5
24026 sed 's/^/| /' conftest.$ac_ext >&5
24027
24028
24029 fi
24030
24031 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24032 fi
24033
24034
24035 # If we found "long int" is 64 bits, assume snprintf handles it.  If
24036 # we found we need to use "long long int", better check.  We cope with
24037 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
24038 # work, fall back to our own snprintf emulation (which we know uses %lld).
24039
24040 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
24041   if test $pgac_need_repl_snprintf = no; then
24042     { $as_echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
24043 $as_echo_n "checking snprintf format for long long int... " >&6; }
24044 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
24045   $as_echo_n "(cached) " >&6
24046 else
24047   for pgac_format in '%lld' '%qd' '%I64d'; do
24048 if test "$cross_compiling" = yes; then
24049   pgac_cv_snprintf_long_long_int_format=cross; break
24050 else
24051   cat >conftest.$ac_ext <<_ACEOF
24052 /* confdefs.h.  */
24053 _ACEOF
24054 cat confdefs.h >>conftest.$ac_ext
24055 cat >>conftest.$ac_ext <<_ACEOF
24056 /* end confdefs.h.  */
24057 #include <stdio.h>
24058 typedef long long int ac_int64;
24059 #define INT64_FORMAT "$pgac_format"
24060
24061 ac_int64 a = 20000001;
24062 ac_int64 b = 40000005;
24063
24064 int does_int64_snprintf_work()
24065 {
24066   ac_int64 c;
24067   char buf[100];
24068
24069   if (sizeof(ac_int64) != 8)
24070     return 0;                   /* doesn't look like the right size */
24071
24072   c = a * b;
24073   snprintf(buf, 100, INT64_FORMAT, c);
24074   if (strcmp(buf, "800000140000005") != 0)
24075     return 0;                   /* either multiply or snprintf is busted */
24076   return 1;
24077 }
24078 main() {
24079   exit(! does_int64_snprintf_work());
24080 }
24081 _ACEOF
24082 rm -f conftest$ac_exeext
24083 if { (ac_try="$ac_link"
24084 case "(($ac_try" in
24085   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24086   *) ac_try_echo=$ac_try;;
24087 esac
24088 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24089 $as_echo "$ac_try_echo") >&5
24090   (eval "$ac_link") 2>&5
24091   ac_status=$?
24092   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24093   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24094   { (case "(($ac_try" in
24095   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24096   *) ac_try_echo=$ac_try;;
24097 esac
24098 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24099 $as_echo "$ac_try_echo") >&5
24100   (eval "$ac_try") 2>&5
24101   ac_status=$?
24102   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24103   (exit $ac_status); }; }; then
24104   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
24105 else
24106   $as_echo "$as_me: program exited with status $ac_status" >&5
24107 $as_echo "$as_me: failed program was:" >&5
24108 sed 's/^/| /' conftest.$ac_ext >&5
24109
24110 fi
24111 rm -rf conftest.dSYM
24112 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24113 fi
24114
24115
24116 done
24117 fi
24118
24119 LONG_LONG_INT_FORMAT=''
24120
24121 case $pgac_cv_snprintf_long_long_int_format in
24122   cross) { $as_echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
24123 $as_echo "cannot test (not on host machine)" >&6; };;
24124   ?*)    { $as_echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
24125 $as_echo "$pgac_cv_snprintf_long_long_int_format" >&6; }
24126          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
24127   *)     { $as_echo "$as_me:$LINENO: result: none" >&5
24128 $as_echo "none" >&6; };;
24129 esac
24130     if test "$LONG_LONG_INT_FORMAT" = ""; then
24131       # Force usage of our own snprintf, since system snprintf is broken
24132       pgac_need_repl_snprintf=yes
24133       LONG_LONG_INT_FORMAT='%lld'
24134     fi
24135   else
24136     # Here if we previously decided we needed to use our own snprintf
24137     LONG_LONG_INT_FORMAT='%lld'
24138   fi
24139   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
24140   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
24141   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
24142 else
24143   # Here if we are not using 'long long int' at all
24144   INT64_FORMAT='"%ld"'
24145   UINT64_FORMAT='"%lu"'
24146 fi
24147
24148
24149 cat >>confdefs.h <<_ACEOF
24150 #define INT64_FORMAT $INT64_FORMAT
24151 _ACEOF
24152
24153
24154
24155 cat >>confdefs.h <<_ACEOF
24156 #define UINT64_FORMAT $UINT64_FORMAT
24157 _ACEOF
24158
24159
24160 # Now we have checked all the reasons to replace snprintf
24161 if test $pgac_need_repl_snprintf = yes; then
24162
24163 cat >>confdefs.h <<\_ACEOF
24164 #define USE_REPL_SNPRINTF 1
24165 _ACEOF
24166
24167   case " $LIBOBJS " in
24168   *" snprintf.$ac_objext "* ) ;;
24169   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
24170  ;;
24171 esac
24172
24173 fi
24174
24175 # Check size of void *, size_t (enables tweaks for > 32bit address space)
24176 # The cast to long int works around a bug in the HP C Compiler
24177 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24178 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24179 # This bug is HP SR number 8606223364.
24180 { $as_echo "$as_me:$LINENO: checking size of void *" >&5
24181 $as_echo_n "checking size of void *... " >&6; }
24182 if test "${ac_cv_sizeof_void_p+set}" = set; then
24183   $as_echo_n "(cached) " >&6
24184 else
24185   if test "$cross_compiling" = yes; then
24186   # Depending upon the size, compute the lo and hi bounds.
24187 cat >conftest.$ac_ext <<_ACEOF
24188 /* confdefs.h.  */
24189 _ACEOF
24190 cat confdefs.h >>conftest.$ac_ext
24191 cat >>conftest.$ac_ext <<_ACEOF
24192 /* end confdefs.h.  */
24193 $ac_includes_default
24194 int
24195 main ()
24196 {
24197 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= 0)];
24198 test_array [0] = 0
24199
24200   ;
24201   return 0;
24202 }
24203 _ACEOF
24204 rm -f conftest.$ac_objext
24205 if { (ac_try="$ac_compile"
24206 case "(($ac_try" in
24207   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24208   *) ac_try_echo=$ac_try;;
24209 esac
24210 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24211 $as_echo "$ac_try_echo") >&5
24212   (eval "$ac_compile") 2>conftest.er1
24213   ac_status=$?
24214   grep -v '^ *+' conftest.er1 >conftest.err
24215   rm -f conftest.er1
24216   cat conftest.err >&5
24217   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24218   (exit $ac_status); } && {
24219          test -z "$ac_c_werror_flag" ||
24220          test ! -s conftest.err
24221        } && test -s conftest.$ac_objext; then
24222   ac_lo=0 ac_mid=0
24223   while :; do
24224     cat >conftest.$ac_ext <<_ACEOF
24225 /* confdefs.h.  */
24226 _ACEOF
24227 cat confdefs.h >>conftest.$ac_ext
24228 cat >>conftest.$ac_ext <<_ACEOF
24229 /* end confdefs.h.  */
24230 $ac_includes_default
24231 int
24232 main ()
24233 {
24234 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
24235 test_array [0] = 0
24236
24237   ;
24238   return 0;
24239 }
24240 _ACEOF
24241 rm -f conftest.$ac_objext
24242 if { (ac_try="$ac_compile"
24243 case "(($ac_try" in
24244   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24245   *) ac_try_echo=$ac_try;;
24246 esac
24247 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24248 $as_echo "$ac_try_echo") >&5
24249   (eval "$ac_compile") 2>conftest.er1
24250   ac_status=$?
24251   grep -v '^ *+' conftest.er1 >conftest.err
24252   rm -f conftest.er1
24253   cat conftest.err >&5
24254   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24255   (exit $ac_status); } && {
24256          test -z "$ac_c_werror_flag" ||
24257          test ! -s conftest.err
24258        } && test -s conftest.$ac_objext; then
24259   ac_hi=$ac_mid; break
24260 else
24261   $as_echo "$as_me: failed program was:" >&5
24262 sed 's/^/| /' conftest.$ac_ext >&5
24263
24264         ac_lo=`expr $ac_mid + 1`
24265                         if test $ac_lo -le $ac_mid; then
24266                           ac_lo= ac_hi=
24267                           break
24268                         fi
24269                         ac_mid=`expr 2 '*' $ac_mid + 1`
24270 fi
24271
24272 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24273   done
24274 else
24275   $as_echo "$as_me: failed program was:" >&5
24276 sed 's/^/| /' conftest.$ac_ext >&5
24277
24278         cat >conftest.$ac_ext <<_ACEOF
24279 /* confdefs.h.  */
24280 _ACEOF
24281 cat confdefs.h >>conftest.$ac_ext
24282 cat >>conftest.$ac_ext <<_ACEOF
24283 /* end confdefs.h.  */
24284 $ac_includes_default
24285 int
24286 main ()
24287 {
24288 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) < 0)];
24289 test_array [0] = 0
24290
24291   ;
24292   return 0;
24293 }
24294 _ACEOF
24295 rm -f conftest.$ac_objext
24296 if { (ac_try="$ac_compile"
24297 case "(($ac_try" in
24298   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24299   *) ac_try_echo=$ac_try;;
24300 esac
24301 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24302 $as_echo "$ac_try_echo") >&5
24303   (eval "$ac_compile") 2>conftest.er1
24304   ac_status=$?
24305   grep -v '^ *+' conftest.er1 >conftest.err
24306   rm -f conftest.er1
24307   cat conftest.err >&5
24308   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24309   (exit $ac_status); } && {
24310          test -z "$ac_c_werror_flag" ||
24311          test ! -s conftest.err
24312        } && test -s conftest.$ac_objext; then
24313   ac_hi=-1 ac_mid=-1
24314   while :; do
24315     cat >conftest.$ac_ext <<_ACEOF
24316 /* confdefs.h.  */
24317 _ACEOF
24318 cat confdefs.h >>conftest.$ac_ext
24319 cat >>conftest.$ac_ext <<_ACEOF
24320 /* end confdefs.h.  */
24321 $ac_includes_default
24322 int
24323 main ()
24324 {
24325 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= $ac_mid)];
24326 test_array [0] = 0
24327
24328   ;
24329   return 0;
24330 }
24331 _ACEOF
24332 rm -f conftest.$ac_objext
24333 if { (ac_try="$ac_compile"
24334 case "(($ac_try" in
24335   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24336   *) ac_try_echo=$ac_try;;
24337 esac
24338 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24339 $as_echo "$ac_try_echo") >&5
24340   (eval "$ac_compile") 2>conftest.er1
24341   ac_status=$?
24342   grep -v '^ *+' conftest.er1 >conftest.err
24343   rm -f conftest.er1
24344   cat conftest.err >&5
24345   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24346   (exit $ac_status); } && {
24347          test -z "$ac_c_werror_flag" ||
24348          test ! -s conftest.err
24349        } && test -s conftest.$ac_objext; then
24350   ac_lo=$ac_mid; break
24351 else
24352   $as_echo "$as_me: failed program was:" >&5
24353 sed 's/^/| /' conftest.$ac_ext >&5
24354
24355         ac_hi=`expr '(' $ac_mid ')' - 1`
24356                         if test $ac_mid -le $ac_hi; then
24357                           ac_lo= ac_hi=
24358                           break
24359                         fi
24360                         ac_mid=`expr 2 '*' $ac_mid`
24361 fi
24362
24363 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24364   done
24365 else
24366   $as_echo "$as_me: failed program was:" >&5
24367 sed 's/^/| /' conftest.$ac_ext >&5
24368
24369         ac_lo= ac_hi=
24370 fi
24371
24372 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24373 fi
24374
24375 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24376 # Binary search between lo and hi bounds.
24377 while test "x$ac_lo" != "x$ac_hi"; do
24378   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24379   cat >conftest.$ac_ext <<_ACEOF
24380 /* confdefs.h.  */
24381 _ACEOF
24382 cat confdefs.h >>conftest.$ac_ext
24383 cat >>conftest.$ac_ext <<_ACEOF
24384 /* end confdefs.h.  */
24385 $ac_includes_default
24386 int
24387 main ()
24388 {
24389 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
24390 test_array [0] = 0
24391
24392   ;
24393   return 0;
24394 }
24395 _ACEOF
24396 rm -f conftest.$ac_objext
24397 if { (ac_try="$ac_compile"
24398 case "(($ac_try" in
24399   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24400   *) ac_try_echo=$ac_try;;
24401 esac
24402 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24403 $as_echo "$ac_try_echo") >&5
24404   (eval "$ac_compile") 2>conftest.er1
24405   ac_status=$?
24406   grep -v '^ *+' conftest.er1 >conftest.err
24407   rm -f conftest.er1
24408   cat conftest.err >&5
24409   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24410   (exit $ac_status); } && {
24411          test -z "$ac_c_werror_flag" ||
24412          test ! -s conftest.err
24413        } && test -s conftest.$ac_objext; then
24414   ac_hi=$ac_mid
24415 else
24416   $as_echo "$as_me: failed program was:" >&5
24417 sed 's/^/| /' conftest.$ac_ext >&5
24418
24419         ac_lo=`expr '(' $ac_mid ')' + 1`
24420 fi
24421
24422 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24423 done
24424 case $ac_lo in
24425 ?*) ac_cv_sizeof_void_p=$ac_lo;;
24426 '') if test "$ac_cv_type_void_p" = yes; then
24427      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24428 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24429 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
24430 See \`config.log' for more details." >&5
24431 $as_echo "$as_me: error: cannot compute sizeof (void *)
24432 See \`config.log' for more details." >&2;}
24433    { (exit 77); exit 77; }; }; }
24434    else
24435      ac_cv_sizeof_void_p=0
24436    fi ;;
24437 esac
24438 else
24439   cat >conftest.$ac_ext <<_ACEOF
24440 /* confdefs.h.  */
24441 _ACEOF
24442 cat confdefs.h >>conftest.$ac_ext
24443 cat >>conftest.$ac_ext <<_ACEOF
24444 /* end confdefs.h.  */
24445 $ac_includes_default
24446 static long int longval () { return (long int) (sizeof (void *)); }
24447 static unsigned long int ulongval () { return (long int) (sizeof (void *)); }
24448 #include <stdio.h>
24449 #include <stdlib.h>
24450 int
24451 main ()
24452 {
24453
24454   FILE *f = fopen ("conftest.val", "w");
24455   if (! f)
24456     return 1;
24457   if (((long int) (sizeof (void *))) < 0)
24458     {
24459       long int i = longval ();
24460       if (i != ((long int) (sizeof (void *))))
24461         return 1;
24462       fprintf (f, "%ld", i);
24463     }
24464   else
24465     {
24466       unsigned long int i = ulongval ();
24467       if (i != ((long int) (sizeof (void *))))
24468         return 1;
24469       fprintf (f, "%lu", i);
24470     }
24471   /* Do not output a trailing newline, as this causes \r\n confusion
24472      on some platforms.  */
24473   return ferror (f) || fclose (f) != 0;
24474
24475   ;
24476   return 0;
24477 }
24478 _ACEOF
24479 rm -f conftest$ac_exeext
24480 if { (ac_try="$ac_link"
24481 case "(($ac_try" in
24482   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24483   *) ac_try_echo=$ac_try;;
24484 esac
24485 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24486 $as_echo "$ac_try_echo") >&5
24487   (eval "$ac_link") 2>&5
24488   ac_status=$?
24489   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24490   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24491   { (case "(($ac_try" in
24492   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24493   *) ac_try_echo=$ac_try;;
24494 esac
24495 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24496 $as_echo "$ac_try_echo") >&5
24497   (eval "$ac_try") 2>&5
24498   ac_status=$?
24499   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24500   (exit $ac_status); }; }; then
24501   ac_cv_sizeof_void_p=`cat conftest.val`
24502 else
24503   $as_echo "$as_me: program exited with status $ac_status" >&5
24504 $as_echo "$as_me: failed program was:" >&5
24505 sed 's/^/| /' conftest.$ac_ext >&5
24506
24507 ( exit $ac_status )
24508 if test "$ac_cv_type_void_p" = yes; then
24509      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24510 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24511 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
24512 See \`config.log' for more details." >&5
24513 $as_echo "$as_me: error: cannot compute sizeof (void *)
24514 See \`config.log' for more details." >&2;}
24515    { (exit 77); exit 77; }; }; }
24516    else
24517      ac_cv_sizeof_void_p=0
24518    fi
24519 fi
24520 rm -rf conftest.dSYM
24521 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24522 fi
24523 rm -f conftest.val
24524 fi
24525 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
24526 $as_echo "$ac_cv_sizeof_void_p" >&6; }
24527
24528
24529
24530 cat >>confdefs.h <<_ACEOF
24531 #define SIZEOF_VOID_P $ac_cv_sizeof_void_p
24532 _ACEOF
24533
24534
24535 # The cast to long int works around a bug in the HP C Compiler
24536 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24537 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24538 # This bug is HP SR number 8606223364.
24539 { $as_echo "$as_me:$LINENO: checking size of size_t" >&5
24540 $as_echo_n "checking size of size_t... " >&6; }
24541 if test "${ac_cv_sizeof_size_t+set}" = set; then
24542   $as_echo_n "(cached) " >&6
24543 else
24544   if test "$cross_compiling" = yes; then
24545   # Depending upon the size, compute the lo and hi bounds.
24546 cat >conftest.$ac_ext <<_ACEOF
24547 /* confdefs.h.  */
24548 _ACEOF
24549 cat confdefs.h >>conftest.$ac_ext
24550 cat >>conftest.$ac_ext <<_ACEOF
24551 /* end confdefs.h.  */
24552 $ac_includes_default
24553 int
24554 main ()
24555 {
24556 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= 0)];
24557 test_array [0] = 0
24558
24559   ;
24560   return 0;
24561 }
24562 _ACEOF
24563 rm -f conftest.$ac_objext
24564 if { (ac_try="$ac_compile"
24565 case "(($ac_try" in
24566   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24567   *) ac_try_echo=$ac_try;;
24568 esac
24569 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24570 $as_echo "$ac_try_echo") >&5
24571   (eval "$ac_compile") 2>conftest.er1
24572   ac_status=$?
24573   grep -v '^ *+' conftest.er1 >conftest.err
24574   rm -f conftest.er1
24575   cat conftest.err >&5
24576   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24577   (exit $ac_status); } && {
24578          test -z "$ac_c_werror_flag" ||
24579          test ! -s conftest.err
24580        } && test -s conftest.$ac_objext; then
24581   ac_lo=0 ac_mid=0
24582   while :; do
24583     cat >conftest.$ac_ext <<_ACEOF
24584 /* confdefs.h.  */
24585 _ACEOF
24586 cat confdefs.h >>conftest.$ac_ext
24587 cat >>conftest.$ac_ext <<_ACEOF
24588 /* end confdefs.h.  */
24589 $ac_includes_default
24590 int
24591 main ()
24592 {
24593 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
24594 test_array [0] = 0
24595
24596   ;
24597   return 0;
24598 }
24599 _ACEOF
24600 rm -f conftest.$ac_objext
24601 if { (ac_try="$ac_compile"
24602 case "(($ac_try" in
24603   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24604   *) ac_try_echo=$ac_try;;
24605 esac
24606 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24607 $as_echo "$ac_try_echo") >&5
24608   (eval "$ac_compile") 2>conftest.er1
24609   ac_status=$?
24610   grep -v '^ *+' conftest.er1 >conftest.err
24611   rm -f conftest.er1
24612   cat conftest.err >&5
24613   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24614   (exit $ac_status); } && {
24615          test -z "$ac_c_werror_flag" ||
24616          test ! -s conftest.err
24617        } && test -s conftest.$ac_objext; then
24618   ac_hi=$ac_mid; break
24619 else
24620   $as_echo "$as_me: failed program was:" >&5
24621 sed 's/^/| /' conftest.$ac_ext >&5
24622
24623         ac_lo=`expr $ac_mid + 1`
24624                         if test $ac_lo -le $ac_mid; then
24625                           ac_lo= ac_hi=
24626                           break
24627                         fi
24628                         ac_mid=`expr 2 '*' $ac_mid + 1`
24629 fi
24630
24631 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24632   done
24633 else
24634   $as_echo "$as_me: failed program was:" >&5
24635 sed 's/^/| /' conftest.$ac_ext >&5
24636
24637         cat >conftest.$ac_ext <<_ACEOF
24638 /* confdefs.h.  */
24639 _ACEOF
24640 cat confdefs.h >>conftest.$ac_ext
24641 cat >>conftest.$ac_ext <<_ACEOF
24642 /* end confdefs.h.  */
24643 $ac_includes_default
24644 int
24645 main ()
24646 {
24647 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) < 0)];
24648 test_array [0] = 0
24649
24650   ;
24651   return 0;
24652 }
24653 _ACEOF
24654 rm -f conftest.$ac_objext
24655 if { (ac_try="$ac_compile"
24656 case "(($ac_try" in
24657   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24658   *) ac_try_echo=$ac_try;;
24659 esac
24660 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24661 $as_echo "$ac_try_echo") >&5
24662   (eval "$ac_compile") 2>conftest.er1
24663   ac_status=$?
24664   grep -v '^ *+' conftest.er1 >conftest.err
24665   rm -f conftest.er1
24666   cat conftest.err >&5
24667   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24668   (exit $ac_status); } && {
24669          test -z "$ac_c_werror_flag" ||
24670          test ! -s conftest.err
24671        } && test -s conftest.$ac_objext; then
24672   ac_hi=-1 ac_mid=-1
24673   while :; do
24674     cat >conftest.$ac_ext <<_ACEOF
24675 /* confdefs.h.  */
24676 _ACEOF
24677 cat confdefs.h >>conftest.$ac_ext
24678 cat >>conftest.$ac_ext <<_ACEOF
24679 /* end confdefs.h.  */
24680 $ac_includes_default
24681 int
24682 main ()
24683 {
24684 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= $ac_mid)];
24685 test_array [0] = 0
24686
24687   ;
24688   return 0;
24689 }
24690 _ACEOF
24691 rm -f conftest.$ac_objext
24692 if { (ac_try="$ac_compile"
24693 case "(($ac_try" in
24694   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24695   *) ac_try_echo=$ac_try;;
24696 esac
24697 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24698 $as_echo "$ac_try_echo") >&5
24699   (eval "$ac_compile") 2>conftest.er1
24700   ac_status=$?
24701   grep -v '^ *+' conftest.er1 >conftest.err
24702   rm -f conftest.er1
24703   cat conftest.err >&5
24704   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24705   (exit $ac_status); } && {
24706          test -z "$ac_c_werror_flag" ||
24707          test ! -s conftest.err
24708        } && test -s conftest.$ac_objext; then
24709   ac_lo=$ac_mid; break
24710 else
24711   $as_echo "$as_me: failed program was:" >&5
24712 sed 's/^/| /' conftest.$ac_ext >&5
24713
24714         ac_hi=`expr '(' $ac_mid ')' - 1`
24715                         if test $ac_mid -le $ac_hi; then
24716                           ac_lo= ac_hi=
24717                           break
24718                         fi
24719                         ac_mid=`expr 2 '*' $ac_mid`
24720 fi
24721
24722 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24723   done
24724 else
24725   $as_echo "$as_me: failed program was:" >&5
24726 sed 's/^/| /' conftest.$ac_ext >&5
24727
24728         ac_lo= ac_hi=
24729 fi
24730
24731 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24732 fi
24733
24734 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24735 # Binary search between lo and hi bounds.
24736 while test "x$ac_lo" != "x$ac_hi"; do
24737   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24738   cat >conftest.$ac_ext <<_ACEOF
24739 /* confdefs.h.  */
24740 _ACEOF
24741 cat confdefs.h >>conftest.$ac_ext
24742 cat >>conftest.$ac_ext <<_ACEOF
24743 /* end confdefs.h.  */
24744 $ac_includes_default
24745 int
24746 main ()
24747 {
24748 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
24749 test_array [0] = 0
24750
24751   ;
24752   return 0;
24753 }
24754 _ACEOF
24755 rm -f conftest.$ac_objext
24756 if { (ac_try="$ac_compile"
24757 case "(($ac_try" in
24758   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24759   *) ac_try_echo=$ac_try;;
24760 esac
24761 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24762 $as_echo "$ac_try_echo") >&5
24763   (eval "$ac_compile") 2>conftest.er1
24764   ac_status=$?
24765   grep -v '^ *+' conftest.er1 >conftest.err
24766   rm -f conftest.er1
24767   cat conftest.err >&5
24768   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24769   (exit $ac_status); } && {
24770          test -z "$ac_c_werror_flag" ||
24771          test ! -s conftest.err
24772        } && test -s conftest.$ac_objext; then
24773   ac_hi=$ac_mid
24774 else
24775   $as_echo "$as_me: failed program was:" >&5
24776 sed 's/^/| /' conftest.$ac_ext >&5
24777
24778         ac_lo=`expr '(' $ac_mid ')' + 1`
24779 fi
24780
24781 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24782 done
24783 case $ac_lo in
24784 ?*) ac_cv_sizeof_size_t=$ac_lo;;
24785 '') if test "$ac_cv_type_size_t" = yes; then
24786      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24787 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24788 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
24789 See \`config.log' for more details." >&5
24790 $as_echo "$as_me: error: cannot compute sizeof (size_t)
24791 See \`config.log' for more details." >&2;}
24792    { (exit 77); exit 77; }; }; }
24793    else
24794      ac_cv_sizeof_size_t=0
24795    fi ;;
24796 esac
24797 else
24798   cat >conftest.$ac_ext <<_ACEOF
24799 /* confdefs.h.  */
24800 _ACEOF
24801 cat confdefs.h >>conftest.$ac_ext
24802 cat >>conftest.$ac_ext <<_ACEOF
24803 /* end confdefs.h.  */
24804 $ac_includes_default
24805 static long int longval () { return (long int) (sizeof (size_t)); }
24806 static unsigned long int ulongval () { return (long int) (sizeof (size_t)); }
24807 #include <stdio.h>
24808 #include <stdlib.h>
24809 int
24810 main ()
24811 {
24812
24813   FILE *f = fopen ("conftest.val", "w");
24814   if (! f)
24815     return 1;
24816   if (((long int) (sizeof (size_t))) < 0)
24817     {
24818       long int i = longval ();
24819       if (i != ((long int) (sizeof (size_t))))
24820         return 1;
24821       fprintf (f, "%ld", i);
24822     }
24823   else
24824     {
24825       unsigned long int i = ulongval ();
24826       if (i != ((long int) (sizeof (size_t))))
24827         return 1;
24828       fprintf (f, "%lu", i);
24829     }
24830   /* Do not output a trailing newline, as this causes \r\n confusion
24831      on some platforms.  */
24832   return ferror (f) || fclose (f) != 0;
24833
24834   ;
24835   return 0;
24836 }
24837 _ACEOF
24838 rm -f conftest$ac_exeext
24839 if { (ac_try="$ac_link"
24840 case "(($ac_try" in
24841   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24842   *) ac_try_echo=$ac_try;;
24843 esac
24844 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24845 $as_echo "$ac_try_echo") >&5
24846   (eval "$ac_link") 2>&5
24847   ac_status=$?
24848   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24849   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24850   { (case "(($ac_try" in
24851   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24852   *) ac_try_echo=$ac_try;;
24853 esac
24854 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24855 $as_echo "$ac_try_echo") >&5
24856   (eval "$ac_try") 2>&5
24857   ac_status=$?
24858   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24859   (exit $ac_status); }; }; then
24860   ac_cv_sizeof_size_t=`cat conftest.val`
24861 else
24862   $as_echo "$as_me: program exited with status $ac_status" >&5
24863 $as_echo "$as_me: failed program was:" >&5
24864 sed 's/^/| /' conftest.$ac_ext >&5
24865
24866 ( exit $ac_status )
24867 if test "$ac_cv_type_size_t" = yes; then
24868      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24869 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24870 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
24871 See \`config.log' for more details." >&5
24872 $as_echo "$as_me: error: cannot compute sizeof (size_t)
24873 See \`config.log' for more details." >&2;}
24874    { (exit 77); exit 77; }; }; }
24875    else
24876      ac_cv_sizeof_size_t=0
24877    fi
24878 fi
24879 rm -rf conftest.dSYM
24880 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24881 fi
24882 rm -f conftest.val
24883 fi
24884 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
24885 $as_echo "$ac_cv_sizeof_size_t" >&6; }
24886
24887
24888
24889 cat >>confdefs.h <<_ACEOF
24890 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
24891 _ACEOF
24892
24893
24894 # The cast to long int works around a bug in the HP C Compiler
24895 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24896 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24897 # This bug is HP SR number 8606223364.
24898 { $as_echo "$as_me:$LINENO: checking size of long" >&5
24899 $as_echo_n "checking size of long... " >&6; }
24900 if test "${ac_cv_sizeof_long+set}" = set; then
24901   $as_echo_n "(cached) " >&6
24902 else
24903   if test "$cross_compiling" = yes; then
24904   # Depending upon the size, compute the lo and hi bounds.
24905 cat >conftest.$ac_ext <<_ACEOF
24906 /* confdefs.h.  */
24907 _ACEOF
24908 cat confdefs.h >>conftest.$ac_ext
24909 cat >>conftest.$ac_ext <<_ACEOF
24910 /* end confdefs.h.  */
24911 $ac_includes_default
24912 int
24913 main ()
24914 {
24915 static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= 0)];
24916 test_array [0] = 0
24917
24918   ;
24919   return 0;
24920 }
24921 _ACEOF
24922 rm -f conftest.$ac_objext
24923 if { (ac_try="$ac_compile"
24924 case "(($ac_try" in
24925   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24926   *) ac_try_echo=$ac_try;;
24927 esac
24928 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24929 $as_echo "$ac_try_echo") >&5
24930   (eval "$ac_compile") 2>conftest.er1
24931   ac_status=$?
24932   grep -v '^ *+' conftest.er1 >conftest.err
24933   rm -f conftest.er1
24934   cat conftest.err >&5
24935   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24936   (exit $ac_status); } && {
24937          test -z "$ac_c_werror_flag" ||
24938          test ! -s conftest.err
24939        } && test -s conftest.$ac_objext; then
24940   ac_lo=0 ac_mid=0
24941   while :; do
24942     cat >conftest.$ac_ext <<_ACEOF
24943 /* confdefs.h.  */
24944 _ACEOF
24945 cat confdefs.h >>conftest.$ac_ext
24946 cat >>conftest.$ac_ext <<_ACEOF
24947 /* end confdefs.h.  */
24948 $ac_includes_default
24949 int
24950 main ()
24951 {
24952 static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)];
24953 test_array [0] = 0
24954
24955   ;
24956   return 0;
24957 }
24958 _ACEOF
24959 rm -f conftest.$ac_objext
24960 if { (ac_try="$ac_compile"
24961 case "(($ac_try" in
24962   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24963   *) ac_try_echo=$ac_try;;
24964 esac
24965 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24966 $as_echo "$ac_try_echo") >&5
24967   (eval "$ac_compile") 2>conftest.er1
24968   ac_status=$?
24969   grep -v '^ *+' conftest.er1 >conftest.err
24970   rm -f conftest.er1
24971   cat conftest.err >&5
24972   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24973   (exit $ac_status); } && {
24974          test -z "$ac_c_werror_flag" ||
24975          test ! -s conftest.err
24976        } && test -s conftest.$ac_objext; then
24977   ac_hi=$ac_mid; break
24978 else
24979   $as_echo "$as_me: failed program was:" >&5
24980 sed 's/^/| /' conftest.$ac_ext >&5
24981
24982         ac_lo=`expr $ac_mid + 1`
24983                         if test $ac_lo -le $ac_mid; then
24984                           ac_lo= ac_hi=
24985                           break
24986                         fi
24987                         ac_mid=`expr 2 '*' $ac_mid + 1`
24988 fi
24989
24990 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24991   done
24992 else
24993   $as_echo "$as_me: failed program was:" >&5
24994 sed 's/^/| /' conftest.$ac_ext >&5
24995
24996         cat >conftest.$ac_ext <<_ACEOF
24997 /* confdefs.h.  */
24998 _ACEOF
24999 cat confdefs.h >>conftest.$ac_ext
25000 cat >>conftest.$ac_ext <<_ACEOF
25001 /* end confdefs.h.  */
25002 $ac_includes_default
25003 int
25004 main ()
25005 {
25006 static int test_array [1 - 2 * !(((long int) (sizeof (long))) < 0)];
25007 test_array [0] = 0
25008
25009   ;
25010   return 0;
25011 }
25012 _ACEOF
25013 rm -f conftest.$ac_objext
25014 if { (ac_try="$ac_compile"
25015 case "(($ac_try" in
25016   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25017   *) ac_try_echo=$ac_try;;
25018 esac
25019 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25020 $as_echo "$ac_try_echo") >&5
25021   (eval "$ac_compile") 2>conftest.er1
25022   ac_status=$?
25023   grep -v '^ *+' conftest.er1 >conftest.err
25024   rm -f conftest.er1
25025   cat conftest.err >&5
25026   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25027   (exit $ac_status); } && {
25028          test -z "$ac_c_werror_flag" ||
25029          test ! -s conftest.err
25030        } && test -s conftest.$ac_objext; then
25031   ac_hi=-1 ac_mid=-1
25032   while :; do
25033     cat >conftest.$ac_ext <<_ACEOF
25034 /* confdefs.h.  */
25035 _ACEOF
25036 cat confdefs.h >>conftest.$ac_ext
25037 cat >>conftest.$ac_ext <<_ACEOF
25038 /* end confdefs.h.  */
25039 $ac_includes_default
25040 int
25041 main ()
25042 {
25043 static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= $ac_mid)];
25044 test_array [0] = 0
25045
25046   ;
25047   return 0;
25048 }
25049 _ACEOF
25050 rm -f conftest.$ac_objext
25051 if { (ac_try="$ac_compile"
25052 case "(($ac_try" in
25053   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25054   *) ac_try_echo=$ac_try;;
25055 esac
25056 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25057 $as_echo "$ac_try_echo") >&5
25058   (eval "$ac_compile") 2>conftest.er1
25059   ac_status=$?
25060   grep -v '^ *+' conftest.er1 >conftest.err
25061   rm -f conftest.er1
25062   cat conftest.err >&5
25063   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25064   (exit $ac_status); } && {
25065          test -z "$ac_c_werror_flag" ||
25066          test ! -s conftest.err
25067        } && test -s conftest.$ac_objext; then
25068   ac_lo=$ac_mid; break
25069 else
25070   $as_echo "$as_me: failed program was:" >&5
25071 sed 's/^/| /' conftest.$ac_ext >&5
25072
25073         ac_hi=`expr '(' $ac_mid ')' - 1`
25074                         if test $ac_mid -le $ac_hi; then
25075                           ac_lo= ac_hi=
25076                           break
25077                         fi
25078                         ac_mid=`expr 2 '*' $ac_mid`
25079 fi
25080
25081 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25082   done
25083 else
25084   $as_echo "$as_me: failed program was:" >&5
25085 sed 's/^/| /' conftest.$ac_ext >&5
25086
25087         ac_lo= ac_hi=
25088 fi
25089
25090 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25091 fi
25092
25093 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25094 # Binary search between lo and hi bounds.
25095 while test "x$ac_lo" != "x$ac_hi"; do
25096   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25097   cat >conftest.$ac_ext <<_ACEOF
25098 /* confdefs.h.  */
25099 _ACEOF
25100 cat confdefs.h >>conftest.$ac_ext
25101 cat >>conftest.$ac_ext <<_ACEOF
25102 /* end confdefs.h.  */
25103 $ac_includes_default
25104 int
25105 main ()
25106 {
25107 static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)];
25108 test_array [0] = 0
25109
25110   ;
25111   return 0;
25112 }
25113 _ACEOF
25114 rm -f conftest.$ac_objext
25115 if { (ac_try="$ac_compile"
25116 case "(($ac_try" in
25117   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25118   *) ac_try_echo=$ac_try;;
25119 esac
25120 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25121 $as_echo "$ac_try_echo") >&5
25122   (eval "$ac_compile") 2>conftest.er1
25123   ac_status=$?
25124   grep -v '^ *+' conftest.er1 >conftest.err
25125   rm -f conftest.er1
25126   cat conftest.err >&5
25127   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25128   (exit $ac_status); } && {
25129          test -z "$ac_c_werror_flag" ||
25130          test ! -s conftest.err
25131        } && test -s conftest.$ac_objext; then
25132   ac_hi=$ac_mid
25133 else
25134   $as_echo "$as_me: failed program was:" >&5
25135 sed 's/^/| /' conftest.$ac_ext >&5
25136
25137         ac_lo=`expr '(' $ac_mid ')' + 1`
25138 fi
25139
25140 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25141 done
25142 case $ac_lo in
25143 ?*) ac_cv_sizeof_long=$ac_lo;;
25144 '') if test "$ac_cv_type_long" = yes; then
25145      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25146 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25147 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long)
25148 See \`config.log' for more details." >&5
25149 $as_echo "$as_me: error: cannot compute sizeof (long)
25150 See \`config.log' for more details." >&2;}
25151    { (exit 77); exit 77; }; }; }
25152    else
25153      ac_cv_sizeof_long=0
25154    fi ;;
25155 esac
25156 else
25157   cat >conftest.$ac_ext <<_ACEOF
25158 /* confdefs.h.  */
25159 _ACEOF
25160 cat confdefs.h >>conftest.$ac_ext
25161 cat >>conftest.$ac_ext <<_ACEOF
25162 /* end confdefs.h.  */
25163 $ac_includes_default
25164 static long int longval () { return (long int) (sizeof (long)); }
25165 static unsigned long int ulongval () { return (long int) (sizeof (long)); }
25166 #include <stdio.h>
25167 #include <stdlib.h>
25168 int
25169 main ()
25170 {
25171
25172   FILE *f = fopen ("conftest.val", "w");
25173   if (! f)
25174     return 1;
25175   if (((long int) (sizeof (long))) < 0)
25176     {
25177       long int i = longval ();
25178       if (i != ((long int) (sizeof (long))))
25179         return 1;
25180       fprintf (f, "%ld", i);
25181     }
25182   else
25183     {
25184       unsigned long int i = ulongval ();
25185       if (i != ((long int) (sizeof (long))))
25186         return 1;
25187       fprintf (f, "%lu", i);
25188     }
25189   /* Do not output a trailing newline, as this causes \r\n confusion
25190      on some platforms.  */
25191   return ferror (f) || fclose (f) != 0;
25192
25193   ;
25194   return 0;
25195 }
25196 _ACEOF
25197 rm -f conftest$ac_exeext
25198 if { (ac_try="$ac_link"
25199 case "(($ac_try" in
25200   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25201   *) ac_try_echo=$ac_try;;
25202 esac
25203 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25204 $as_echo "$ac_try_echo") >&5
25205   (eval "$ac_link") 2>&5
25206   ac_status=$?
25207   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25208   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25209   { (case "(($ac_try" in
25210   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25211   *) ac_try_echo=$ac_try;;
25212 esac
25213 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25214 $as_echo "$ac_try_echo") >&5
25215   (eval "$ac_try") 2>&5
25216   ac_status=$?
25217   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25218   (exit $ac_status); }; }; then
25219   ac_cv_sizeof_long=`cat conftest.val`
25220 else
25221   $as_echo "$as_me: program exited with status $ac_status" >&5
25222 $as_echo "$as_me: failed program was:" >&5
25223 sed 's/^/| /' conftest.$ac_ext >&5
25224
25225 ( exit $ac_status )
25226 if test "$ac_cv_type_long" = yes; then
25227      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25228 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25229 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long)
25230 See \`config.log' for more details." >&5
25231 $as_echo "$as_me: error: cannot compute sizeof (long)
25232 See \`config.log' for more details." >&2;}
25233    { (exit 77); exit 77; }; }; }
25234    else
25235      ac_cv_sizeof_long=0
25236    fi
25237 fi
25238 rm -rf conftest.dSYM
25239 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25240 fi
25241 rm -f conftest.val
25242 fi
25243 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
25244 $as_echo "$ac_cv_sizeof_long" >&6; }
25245
25246
25247
25248 cat >>confdefs.h <<_ACEOF
25249 #define SIZEOF_LONG $ac_cv_sizeof_long
25250 _ACEOF
25251
25252
25253
25254 # Decide whether float4 is passed by value: user-selectable, enabled by default
25255 { $as_echo "$as_me:$LINENO: checking whether to build with float4 passed by value" >&5
25256 $as_echo_n "checking whether to build with float4 passed by value... " >&6; }
25257
25258
25259 # Check whether --enable-float4-byval was given.
25260 if test "${enable_float4_byval+set}" = set; then
25261   enableval=$enable_float4_byval;
25262   case $enableval in
25263     yes)
25264
25265 cat >>confdefs.h <<\_ACEOF
25266 #define USE_FLOAT4_BYVAL 1
25267 _ACEOF
25268
25269                float4passbyval=true
25270       ;;
25271     no)
25272       float4passbyval=false
25273       ;;
25274     *)
25275       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float4-byval option" >&5
25276 $as_echo "$as_me: error: no argument expected for --enable-float4-byval option" >&2;}
25277    { (exit 1); exit 1; }; }
25278       ;;
25279   esac
25280
25281 else
25282   enable_float4_byval=yes
25283
25284 cat >>confdefs.h <<\_ACEOF
25285 #define USE_FLOAT4_BYVAL 1
25286 _ACEOF
25287
25288                float4passbyval=true
25289 fi
25290
25291
25292 { $as_echo "$as_me:$LINENO: result: $enable_float4_byval" >&5
25293 $as_echo "$enable_float4_byval" >&6; }
25294
25295 cat >>confdefs.h <<_ACEOF
25296 #define FLOAT4PASSBYVAL $float4passbyval
25297 _ACEOF
25298
25299
25300 # Decide whether float8 is passed by value.
25301 # Note: this setting also controls int8 and related types such as timestamp.
25302 # If sizeof(Datum) >= 8, this is user-selectable, enabled by default.
25303 # If not, trying to select it is an error.
25304 { $as_echo "$as_me:$LINENO: checking whether to build with float8 passed by value" >&5
25305 $as_echo_n "checking whether to build with float8 passed by value... " >&6; }
25306 if test $ac_cv_sizeof_void_p -ge 8 ; then
25307
25308
25309 # Check whether --enable-float8-byval was given.
25310 if test "${enable_float8_byval+set}" = set; then
25311   enableval=$enable_float8_byval;
25312   case $enableval in
25313     yes)
25314       :
25315       ;;
25316     no)
25317       :
25318       ;;
25319     *)
25320       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
25321 $as_echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
25322    { (exit 1); exit 1; }; }
25323       ;;
25324   esac
25325
25326 else
25327   enable_float8_byval=yes
25328
25329 fi
25330
25331
25332 else
25333
25334
25335 # Check whether --enable-float8-byval was given.
25336 if test "${enable_float8_byval+set}" = set; then
25337   enableval=$enable_float8_byval;
25338   case $enableval in
25339     yes)
25340       :
25341       ;;
25342     no)
25343       :
25344       ;;
25345     *)
25346       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
25347 $as_echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
25348    { (exit 1); exit 1; }; }
25349       ;;
25350   esac
25351
25352 else
25353   enable_float8_byval=no
25354
25355 fi
25356
25357
25358   if test "$enable_float8_byval" = yes ; then
25359     { { $as_echo "$as_me:$LINENO: error: --enable-float8-byval is not supported on 32-bit platforms." >&5
25360 $as_echo "$as_me: error: --enable-float8-byval is not supported on 32-bit platforms." >&2;}
25361    { (exit 1); exit 1; }; }
25362   fi
25363 fi
25364 if test "$enable_float8_byval" = yes ; then
25365
25366 cat >>confdefs.h <<\_ACEOF
25367 #define USE_FLOAT8_BYVAL 1
25368 _ACEOF
25369
25370   float8passbyval=true
25371 else
25372   float8passbyval=false
25373 fi
25374 { $as_echo "$as_me:$LINENO: result: $enable_float8_byval" >&5
25375 $as_echo "$enable_float8_byval" >&6; }
25376
25377 cat >>confdefs.h <<_ACEOF
25378 #define FLOAT8PASSBYVAL $float8passbyval
25379 _ACEOF
25380
25381
25382 # Determine memory alignment requirements for the basic C data types.
25383
25384 # The cast to long int works around a bug in the HP C Compiler,
25385 # see AC_CHECK_SIZEOF for more information.
25386 { $as_echo "$as_me:$LINENO: checking alignment of short" >&5
25387 $as_echo_n "checking alignment of short... " >&6; }
25388 if test "${ac_cv_alignof_short+set}" = set; then
25389   $as_echo_n "(cached) " >&6
25390 else
25391   if test "$cross_compiling" = yes; then
25392   # Depending upon the size, compute the lo and hi bounds.
25393 cat >conftest.$ac_ext <<_ACEOF
25394 /* confdefs.h.  */
25395 _ACEOF
25396 cat confdefs.h >>conftest.$ac_ext
25397 cat >>conftest.$ac_ext <<_ACEOF
25398 /* end confdefs.h.  */
25399 $ac_includes_default
25400 #ifndef offsetof
25401 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25402 #endif
25403 typedef struct { char x; short y; } ac__type_alignof_;
25404 int
25405 main ()
25406 {
25407 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
25408 test_array [0] = 0
25409
25410   ;
25411   return 0;
25412 }
25413 _ACEOF
25414 rm -f conftest.$ac_objext
25415 if { (ac_try="$ac_compile"
25416 case "(($ac_try" in
25417   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25418   *) ac_try_echo=$ac_try;;
25419 esac
25420 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25421 $as_echo "$ac_try_echo") >&5
25422   (eval "$ac_compile") 2>conftest.er1
25423   ac_status=$?
25424   grep -v '^ *+' conftest.er1 >conftest.err
25425   rm -f conftest.er1
25426   cat conftest.err >&5
25427   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25428   (exit $ac_status); } && {
25429          test -z "$ac_c_werror_flag" ||
25430          test ! -s conftest.err
25431        } && test -s conftest.$ac_objext; then
25432   ac_lo=0 ac_mid=0
25433   while :; do
25434     cat >conftest.$ac_ext <<_ACEOF
25435 /* confdefs.h.  */
25436 _ACEOF
25437 cat confdefs.h >>conftest.$ac_ext
25438 cat >>conftest.$ac_ext <<_ACEOF
25439 /* end confdefs.h.  */
25440 $ac_includes_default
25441 #ifndef offsetof
25442 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25443 #endif
25444 typedef struct { char x; short y; } ac__type_alignof_;
25445 int
25446 main ()
25447 {
25448 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25449 test_array [0] = 0
25450
25451   ;
25452   return 0;
25453 }
25454 _ACEOF
25455 rm -f conftest.$ac_objext
25456 if { (ac_try="$ac_compile"
25457 case "(($ac_try" in
25458   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25459   *) ac_try_echo=$ac_try;;
25460 esac
25461 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25462 $as_echo "$ac_try_echo") >&5
25463   (eval "$ac_compile") 2>conftest.er1
25464   ac_status=$?
25465   grep -v '^ *+' conftest.er1 >conftest.err
25466   rm -f conftest.er1
25467   cat conftest.err >&5
25468   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25469   (exit $ac_status); } && {
25470          test -z "$ac_c_werror_flag" ||
25471          test ! -s conftest.err
25472        } && test -s conftest.$ac_objext; then
25473   ac_hi=$ac_mid; break
25474 else
25475   $as_echo "$as_me: failed program was:" >&5
25476 sed 's/^/| /' conftest.$ac_ext >&5
25477
25478         ac_lo=`expr $ac_mid + 1`
25479                         if test $ac_lo -le $ac_mid; then
25480                           ac_lo= ac_hi=
25481                           break
25482                         fi
25483                         ac_mid=`expr 2 '*' $ac_mid + 1`
25484 fi
25485
25486 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25487   done
25488 else
25489   $as_echo "$as_me: failed program was:" >&5
25490 sed 's/^/| /' conftest.$ac_ext >&5
25491
25492         cat >conftest.$ac_ext <<_ACEOF
25493 /* confdefs.h.  */
25494 _ACEOF
25495 cat confdefs.h >>conftest.$ac_ext
25496 cat >>conftest.$ac_ext <<_ACEOF
25497 /* end confdefs.h.  */
25498 $ac_includes_default
25499 #ifndef offsetof
25500 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25501 #endif
25502 typedef struct { char x; short y; } ac__type_alignof_;
25503 int
25504 main ()
25505 {
25506 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
25507 test_array [0] = 0
25508
25509   ;
25510   return 0;
25511 }
25512 _ACEOF
25513 rm -f conftest.$ac_objext
25514 if { (ac_try="$ac_compile"
25515 case "(($ac_try" in
25516   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25517   *) ac_try_echo=$ac_try;;
25518 esac
25519 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25520 $as_echo "$ac_try_echo") >&5
25521   (eval "$ac_compile") 2>conftest.er1
25522   ac_status=$?
25523   grep -v '^ *+' conftest.er1 >conftest.err
25524   rm -f conftest.er1
25525   cat conftest.err >&5
25526   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25527   (exit $ac_status); } && {
25528          test -z "$ac_c_werror_flag" ||
25529          test ! -s conftest.err
25530        } && test -s conftest.$ac_objext; then
25531   ac_hi=-1 ac_mid=-1
25532   while :; do
25533     cat >conftest.$ac_ext <<_ACEOF
25534 /* confdefs.h.  */
25535 _ACEOF
25536 cat confdefs.h >>conftest.$ac_ext
25537 cat >>conftest.$ac_ext <<_ACEOF
25538 /* end confdefs.h.  */
25539 $ac_includes_default
25540 #ifndef offsetof
25541 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25542 #endif
25543 typedef struct { char x; short y; } ac__type_alignof_;
25544 int
25545 main ()
25546 {
25547 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
25548 test_array [0] = 0
25549
25550   ;
25551   return 0;
25552 }
25553 _ACEOF
25554 rm -f conftest.$ac_objext
25555 if { (ac_try="$ac_compile"
25556 case "(($ac_try" in
25557   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25558   *) ac_try_echo=$ac_try;;
25559 esac
25560 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25561 $as_echo "$ac_try_echo") >&5
25562   (eval "$ac_compile") 2>conftest.er1
25563   ac_status=$?
25564   grep -v '^ *+' conftest.er1 >conftest.err
25565   rm -f conftest.er1
25566   cat conftest.err >&5
25567   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25568   (exit $ac_status); } && {
25569          test -z "$ac_c_werror_flag" ||
25570          test ! -s conftest.err
25571        } && test -s conftest.$ac_objext; then
25572   ac_lo=$ac_mid; break
25573 else
25574   $as_echo "$as_me: failed program was:" >&5
25575 sed 's/^/| /' conftest.$ac_ext >&5
25576
25577         ac_hi=`expr '(' $ac_mid ')' - 1`
25578                         if test $ac_mid -le $ac_hi; then
25579                           ac_lo= ac_hi=
25580                           break
25581                         fi
25582                         ac_mid=`expr 2 '*' $ac_mid`
25583 fi
25584
25585 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25586   done
25587 else
25588   $as_echo "$as_me: failed program was:" >&5
25589 sed 's/^/| /' conftest.$ac_ext >&5
25590
25591         ac_lo= ac_hi=
25592 fi
25593
25594 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25595 fi
25596
25597 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25598 # Binary search between lo and hi bounds.
25599 while test "x$ac_lo" != "x$ac_hi"; do
25600   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25601   cat >conftest.$ac_ext <<_ACEOF
25602 /* confdefs.h.  */
25603 _ACEOF
25604 cat confdefs.h >>conftest.$ac_ext
25605 cat >>conftest.$ac_ext <<_ACEOF
25606 /* end confdefs.h.  */
25607 $ac_includes_default
25608 #ifndef offsetof
25609 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25610 #endif
25611 typedef struct { char x; short y; } ac__type_alignof_;
25612 int
25613 main ()
25614 {
25615 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25616 test_array [0] = 0
25617
25618   ;
25619   return 0;
25620 }
25621 _ACEOF
25622 rm -f conftest.$ac_objext
25623 if { (ac_try="$ac_compile"
25624 case "(($ac_try" in
25625   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25626   *) ac_try_echo=$ac_try;;
25627 esac
25628 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25629 $as_echo "$ac_try_echo") >&5
25630   (eval "$ac_compile") 2>conftest.er1
25631   ac_status=$?
25632   grep -v '^ *+' conftest.er1 >conftest.err
25633   rm -f conftest.er1
25634   cat conftest.err >&5
25635   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25636   (exit $ac_status); } && {
25637          test -z "$ac_c_werror_flag" ||
25638          test ! -s conftest.err
25639        } && test -s conftest.$ac_objext; then
25640   ac_hi=$ac_mid
25641 else
25642   $as_echo "$as_me: failed program was:" >&5
25643 sed 's/^/| /' conftest.$ac_ext >&5
25644
25645         ac_lo=`expr '(' $ac_mid ')' + 1`
25646 fi
25647
25648 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25649 done
25650 case $ac_lo in
25651 ?*) ac_cv_alignof_short=$ac_lo;;
25652 '') if test "$ac_cv_type_short" = yes; then
25653      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25654 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25655 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of short
25656 See \`config.log' for more details." >&5
25657 $as_echo "$as_me: error: cannot compute alignment of short
25658 See \`config.log' for more details." >&2;}
25659    { (exit 77); exit 77; }; }; }
25660    else
25661      ac_cv_alignof_short=0
25662    fi ;;
25663 esac
25664 else
25665   cat >conftest.$ac_ext <<_ACEOF
25666 /* confdefs.h.  */
25667 _ACEOF
25668 cat confdefs.h >>conftest.$ac_ext
25669 cat >>conftest.$ac_ext <<_ACEOF
25670 /* end confdefs.h.  */
25671 $ac_includes_default
25672 #ifndef offsetof
25673 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25674 #endif
25675 typedef struct { char x; short y; } ac__type_alignof_;
25676 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
25677 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
25678 #include <stdio.h>
25679 #include <stdlib.h>
25680 int
25681 main ()
25682 {
25683
25684   FILE *f = fopen ("conftest.val", "w");
25685   if (! f)
25686     return 1;
25687   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
25688     {
25689       long int i = longval ();
25690       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25691         return 1;
25692       fprintf (f, "%ld", i);
25693     }
25694   else
25695     {
25696       unsigned long int i = ulongval ();
25697       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25698         return 1;
25699       fprintf (f, "%lu", i);
25700     }
25701   /* Do not output a trailing newline, as this causes \r\n confusion
25702      on some platforms.  */
25703   return ferror (f) || fclose (f) != 0;
25704
25705   ;
25706   return 0;
25707 }
25708 _ACEOF
25709 rm -f conftest$ac_exeext
25710 if { (ac_try="$ac_link"
25711 case "(($ac_try" in
25712   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25713   *) ac_try_echo=$ac_try;;
25714 esac
25715 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25716 $as_echo "$ac_try_echo") >&5
25717   (eval "$ac_link") 2>&5
25718   ac_status=$?
25719   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25720   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25721   { (case "(($ac_try" in
25722   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25723   *) ac_try_echo=$ac_try;;
25724 esac
25725 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25726 $as_echo "$ac_try_echo") >&5
25727   (eval "$ac_try") 2>&5
25728   ac_status=$?
25729   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25730   (exit $ac_status); }; }; then
25731   ac_cv_alignof_short=`cat conftest.val`
25732 else
25733   $as_echo "$as_me: program exited with status $ac_status" >&5
25734 $as_echo "$as_me: failed program was:" >&5
25735 sed 's/^/| /' conftest.$ac_ext >&5
25736
25737 ( exit $ac_status )
25738 if test "$ac_cv_type_short" = yes; then
25739      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25740 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25741 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of short
25742 See \`config.log' for more details." >&5
25743 $as_echo "$as_me: error: cannot compute alignment of short
25744 See \`config.log' for more details." >&2;}
25745    { (exit 77); exit 77; }; }; }
25746    else
25747      ac_cv_alignof_short=0
25748    fi
25749 fi
25750 rm -rf conftest.dSYM
25751 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25752 fi
25753 rm -f conftest.val
25754 fi
25755 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_short" >&5
25756 $as_echo "$ac_cv_alignof_short" >&6; }
25757
25758
25759
25760 cat >>confdefs.h <<_ACEOF
25761 #define ALIGNOF_SHORT $ac_cv_alignof_short
25762 _ACEOF
25763
25764
25765 # The cast to long int works around a bug in the HP C Compiler,
25766 # see AC_CHECK_SIZEOF for more information.
25767 { $as_echo "$as_me:$LINENO: checking alignment of int" >&5
25768 $as_echo_n "checking alignment of int... " >&6; }
25769 if test "${ac_cv_alignof_int+set}" = set; then
25770   $as_echo_n "(cached) " >&6
25771 else
25772   if test "$cross_compiling" = yes; then
25773   # Depending upon the size, compute the lo and hi bounds.
25774 cat >conftest.$ac_ext <<_ACEOF
25775 /* confdefs.h.  */
25776 _ACEOF
25777 cat confdefs.h >>conftest.$ac_ext
25778 cat >>conftest.$ac_ext <<_ACEOF
25779 /* end confdefs.h.  */
25780 $ac_includes_default
25781 #ifndef offsetof
25782 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25783 #endif
25784 typedef struct { char x; int y; } ac__type_alignof_;
25785 int
25786 main ()
25787 {
25788 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
25789 test_array [0] = 0
25790
25791   ;
25792   return 0;
25793 }
25794 _ACEOF
25795 rm -f conftest.$ac_objext
25796 if { (ac_try="$ac_compile"
25797 case "(($ac_try" in
25798   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25799   *) ac_try_echo=$ac_try;;
25800 esac
25801 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25802 $as_echo "$ac_try_echo") >&5
25803   (eval "$ac_compile") 2>conftest.er1
25804   ac_status=$?
25805   grep -v '^ *+' conftest.er1 >conftest.err
25806   rm -f conftest.er1
25807   cat conftest.err >&5
25808   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25809   (exit $ac_status); } && {
25810          test -z "$ac_c_werror_flag" ||
25811          test ! -s conftest.err
25812        } && test -s conftest.$ac_objext; then
25813   ac_lo=0 ac_mid=0
25814   while :; do
25815     cat >conftest.$ac_ext <<_ACEOF
25816 /* confdefs.h.  */
25817 _ACEOF
25818 cat confdefs.h >>conftest.$ac_ext
25819 cat >>conftest.$ac_ext <<_ACEOF
25820 /* end confdefs.h.  */
25821 $ac_includes_default
25822 #ifndef offsetof
25823 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25824 #endif
25825 typedef struct { char x; int y; } ac__type_alignof_;
25826 int
25827 main ()
25828 {
25829 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25830 test_array [0] = 0
25831
25832   ;
25833   return 0;
25834 }
25835 _ACEOF
25836 rm -f conftest.$ac_objext
25837 if { (ac_try="$ac_compile"
25838 case "(($ac_try" in
25839   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25840   *) ac_try_echo=$ac_try;;
25841 esac
25842 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25843 $as_echo "$ac_try_echo") >&5
25844   (eval "$ac_compile") 2>conftest.er1
25845   ac_status=$?
25846   grep -v '^ *+' conftest.er1 >conftest.err
25847   rm -f conftest.er1
25848   cat conftest.err >&5
25849   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25850   (exit $ac_status); } && {
25851          test -z "$ac_c_werror_flag" ||
25852          test ! -s conftest.err
25853        } && test -s conftest.$ac_objext; then
25854   ac_hi=$ac_mid; break
25855 else
25856   $as_echo "$as_me: failed program was:" >&5
25857 sed 's/^/| /' conftest.$ac_ext >&5
25858
25859         ac_lo=`expr $ac_mid + 1`
25860                         if test $ac_lo -le $ac_mid; then
25861                           ac_lo= ac_hi=
25862                           break
25863                         fi
25864                         ac_mid=`expr 2 '*' $ac_mid + 1`
25865 fi
25866
25867 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25868   done
25869 else
25870   $as_echo "$as_me: failed program was:" >&5
25871 sed 's/^/| /' conftest.$ac_ext >&5
25872
25873         cat >conftest.$ac_ext <<_ACEOF
25874 /* confdefs.h.  */
25875 _ACEOF
25876 cat confdefs.h >>conftest.$ac_ext
25877 cat >>conftest.$ac_ext <<_ACEOF
25878 /* end confdefs.h.  */
25879 $ac_includes_default
25880 #ifndef offsetof
25881 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25882 #endif
25883 typedef struct { char x; int y; } ac__type_alignof_;
25884 int
25885 main ()
25886 {
25887 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
25888 test_array [0] = 0
25889
25890   ;
25891   return 0;
25892 }
25893 _ACEOF
25894 rm -f conftest.$ac_objext
25895 if { (ac_try="$ac_compile"
25896 case "(($ac_try" in
25897   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25898   *) ac_try_echo=$ac_try;;
25899 esac
25900 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25901 $as_echo "$ac_try_echo") >&5
25902   (eval "$ac_compile") 2>conftest.er1
25903   ac_status=$?
25904   grep -v '^ *+' conftest.er1 >conftest.err
25905   rm -f conftest.er1
25906   cat conftest.err >&5
25907   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25908   (exit $ac_status); } && {
25909          test -z "$ac_c_werror_flag" ||
25910          test ! -s conftest.err
25911        } && test -s conftest.$ac_objext; then
25912   ac_hi=-1 ac_mid=-1
25913   while :; do
25914     cat >conftest.$ac_ext <<_ACEOF
25915 /* confdefs.h.  */
25916 _ACEOF
25917 cat confdefs.h >>conftest.$ac_ext
25918 cat >>conftest.$ac_ext <<_ACEOF
25919 /* end confdefs.h.  */
25920 $ac_includes_default
25921 #ifndef offsetof
25922 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25923 #endif
25924 typedef struct { char x; int y; } ac__type_alignof_;
25925 int
25926 main ()
25927 {
25928 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
25929 test_array [0] = 0
25930
25931   ;
25932   return 0;
25933 }
25934 _ACEOF
25935 rm -f conftest.$ac_objext
25936 if { (ac_try="$ac_compile"
25937 case "(($ac_try" in
25938   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25939   *) ac_try_echo=$ac_try;;
25940 esac
25941 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25942 $as_echo "$ac_try_echo") >&5
25943   (eval "$ac_compile") 2>conftest.er1
25944   ac_status=$?
25945   grep -v '^ *+' conftest.er1 >conftest.err
25946   rm -f conftest.er1
25947   cat conftest.err >&5
25948   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25949   (exit $ac_status); } && {
25950          test -z "$ac_c_werror_flag" ||
25951          test ! -s conftest.err
25952        } && test -s conftest.$ac_objext; then
25953   ac_lo=$ac_mid; break
25954 else
25955   $as_echo "$as_me: failed program was:" >&5
25956 sed 's/^/| /' conftest.$ac_ext >&5
25957
25958         ac_hi=`expr '(' $ac_mid ')' - 1`
25959                         if test $ac_mid -le $ac_hi; then
25960                           ac_lo= ac_hi=
25961                           break
25962                         fi
25963                         ac_mid=`expr 2 '*' $ac_mid`
25964 fi
25965
25966 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25967   done
25968 else
25969   $as_echo "$as_me: failed program was:" >&5
25970 sed 's/^/| /' conftest.$ac_ext >&5
25971
25972         ac_lo= ac_hi=
25973 fi
25974
25975 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25976 fi
25977
25978 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25979 # Binary search between lo and hi bounds.
25980 while test "x$ac_lo" != "x$ac_hi"; do
25981   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25982   cat >conftest.$ac_ext <<_ACEOF
25983 /* confdefs.h.  */
25984 _ACEOF
25985 cat confdefs.h >>conftest.$ac_ext
25986 cat >>conftest.$ac_ext <<_ACEOF
25987 /* end confdefs.h.  */
25988 $ac_includes_default
25989 #ifndef offsetof
25990 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25991 #endif
25992 typedef struct { char x; int y; } ac__type_alignof_;
25993 int
25994 main ()
25995 {
25996 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25997 test_array [0] = 0
25998
25999   ;
26000   return 0;
26001 }
26002 _ACEOF
26003 rm -f conftest.$ac_objext
26004 if { (ac_try="$ac_compile"
26005 case "(($ac_try" in
26006   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26007   *) ac_try_echo=$ac_try;;
26008 esac
26009 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26010 $as_echo "$ac_try_echo") >&5
26011   (eval "$ac_compile") 2>conftest.er1
26012   ac_status=$?
26013   grep -v '^ *+' conftest.er1 >conftest.err
26014   rm -f conftest.er1
26015   cat conftest.err >&5
26016   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26017   (exit $ac_status); } && {
26018          test -z "$ac_c_werror_flag" ||
26019          test ! -s conftest.err
26020        } && test -s conftest.$ac_objext; then
26021   ac_hi=$ac_mid
26022 else
26023   $as_echo "$as_me: failed program was:" >&5
26024 sed 's/^/| /' conftest.$ac_ext >&5
26025
26026         ac_lo=`expr '(' $ac_mid ')' + 1`
26027 fi
26028
26029 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26030 done
26031 case $ac_lo in
26032 ?*) ac_cv_alignof_int=$ac_lo;;
26033 '') if test "$ac_cv_type_int" = yes; then
26034      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26035 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26036 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of int
26037 See \`config.log' for more details." >&5
26038 $as_echo "$as_me: error: cannot compute alignment of int
26039 See \`config.log' for more details." >&2;}
26040    { (exit 77); exit 77; }; }; }
26041    else
26042      ac_cv_alignof_int=0
26043    fi ;;
26044 esac
26045 else
26046   cat >conftest.$ac_ext <<_ACEOF
26047 /* confdefs.h.  */
26048 _ACEOF
26049 cat confdefs.h >>conftest.$ac_ext
26050 cat >>conftest.$ac_ext <<_ACEOF
26051 /* end confdefs.h.  */
26052 $ac_includes_default
26053 #ifndef offsetof
26054 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26055 #endif
26056 typedef struct { char x; int y; } ac__type_alignof_;
26057 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26058 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26059 #include <stdio.h>
26060 #include <stdlib.h>
26061 int
26062 main ()
26063 {
26064
26065   FILE *f = fopen ("conftest.val", "w");
26066   if (! f)
26067     return 1;
26068   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
26069     {
26070       long int i = longval ();
26071       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26072         return 1;
26073       fprintf (f, "%ld", i);
26074     }
26075   else
26076     {
26077       unsigned long int i = ulongval ();
26078       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26079         return 1;
26080       fprintf (f, "%lu", i);
26081     }
26082   /* Do not output a trailing newline, as this causes \r\n confusion
26083      on some platforms.  */
26084   return ferror (f) || fclose (f) != 0;
26085
26086   ;
26087   return 0;
26088 }
26089 _ACEOF
26090 rm -f conftest$ac_exeext
26091 if { (ac_try="$ac_link"
26092 case "(($ac_try" in
26093   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26094   *) ac_try_echo=$ac_try;;
26095 esac
26096 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26097 $as_echo "$ac_try_echo") >&5
26098   (eval "$ac_link") 2>&5
26099   ac_status=$?
26100   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26101   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26102   { (case "(($ac_try" in
26103   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26104   *) ac_try_echo=$ac_try;;
26105 esac
26106 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26107 $as_echo "$ac_try_echo") >&5
26108   (eval "$ac_try") 2>&5
26109   ac_status=$?
26110   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26111   (exit $ac_status); }; }; then
26112   ac_cv_alignof_int=`cat conftest.val`
26113 else
26114   $as_echo "$as_me: program exited with status $ac_status" >&5
26115 $as_echo "$as_me: failed program was:" >&5
26116 sed 's/^/| /' conftest.$ac_ext >&5
26117
26118 ( exit $ac_status )
26119 if test "$ac_cv_type_int" = yes; then
26120      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26121 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26122 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of int
26123 See \`config.log' for more details." >&5
26124 $as_echo "$as_me: error: cannot compute alignment of int
26125 See \`config.log' for more details." >&2;}
26126    { (exit 77); exit 77; }; }; }
26127    else
26128      ac_cv_alignof_int=0
26129    fi
26130 fi
26131 rm -rf conftest.dSYM
26132 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26133 fi
26134 rm -f conftest.val
26135 fi
26136 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_int" >&5
26137 $as_echo "$ac_cv_alignof_int" >&6; }
26138
26139
26140
26141 cat >>confdefs.h <<_ACEOF
26142 #define ALIGNOF_INT $ac_cv_alignof_int
26143 _ACEOF
26144
26145
26146 # The cast to long int works around a bug in the HP C Compiler,
26147 # see AC_CHECK_SIZEOF for more information.
26148 { $as_echo "$as_me:$LINENO: checking alignment of long" >&5
26149 $as_echo_n "checking alignment of long... " >&6; }
26150 if test "${ac_cv_alignof_long+set}" = set; then
26151   $as_echo_n "(cached) " >&6
26152 else
26153   if test "$cross_compiling" = yes; then
26154   # Depending upon the size, compute the lo and hi bounds.
26155 cat >conftest.$ac_ext <<_ACEOF
26156 /* confdefs.h.  */
26157 _ACEOF
26158 cat confdefs.h >>conftest.$ac_ext
26159 cat >>conftest.$ac_ext <<_ACEOF
26160 /* end confdefs.h.  */
26161 $ac_includes_default
26162 #ifndef offsetof
26163 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26164 #endif
26165 typedef struct { char x; long y; } ac__type_alignof_;
26166 int
26167 main ()
26168 {
26169 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26170 test_array [0] = 0
26171
26172   ;
26173   return 0;
26174 }
26175 _ACEOF
26176 rm -f conftest.$ac_objext
26177 if { (ac_try="$ac_compile"
26178 case "(($ac_try" in
26179   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26180   *) ac_try_echo=$ac_try;;
26181 esac
26182 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26183 $as_echo "$ac_try_echo") >&5
26184   (eval "$ac_compile") 2>conftest.er1
26185   ac_status=$?
26186   grep -v '^ *+' conftest.er1 >conftest.err
26187   rm -f conftest.er1
26188   cat conftest.err >&5
26189   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26190   (exit $ac_status); } && {
26191          test -z "$ac_c_werror_flag" ||
26192          test ! -s conftest.err
26193        } && test -s conftest.$ac_objext; then
26194   ac_lo=0 ac_mid=0
26195   while :; do
26196     cat >conftest.$ac_ext <<_ACEOF
26197 /* confdefs.h.  */
26198 _ACEOF
26199 cat confdefs.h >>conftest.$ac_ext
26200 cat >>conftest.$ac_ext <<_ACEOF
26201 /* end confdefs.h.  */
26202 $ac_includes_default
26203 #ifndef offsetof
26204 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26205 #endif
26206 typedef struct { char x; long y; } ac__type_alignof_;
26207 int
26208 main ()
26209 {
26210 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26211 test_array [0] = 0
26212
26213   ;
26214   return 0;
26215 }
26216 _ACEOF
26217 rm -f conftest.$ac_objext
26218 if { (ac_try="$ac_compile"
26219 case "(($ac_try" in
26220   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26221   *) ac_try_echo=$ac_try;;
26222 esac
26223 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26224 $as_echo "$ac_try_echo") >&5
26225   (eval "$ac_compile") 2>conftest.er1
26226   ac_status=$?
26227   grep -v '^ *+' conftest.er1 >conftest.err
26228   rm -f conftest.er1
26229   cat conftest.err >&5
26230   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26231   (exit $ac_status); } && {
26232          test -z "$ac_c_werror_flag" ||
26233          test ! -s conftest.err
26234        } && test -s conftest.$ac_objext; then
26235   ac_hi=$ac_mid; break
26236 else
26237   $as_echo "$as_me: failed program was:" >&5
26238 sed 's/^/| /' conftest.$ac_ext >&5
26239
26240         ac_lo=`expr $ac_mid + 1`
26241                         if test $ac_lo -le $ac_mid; then
26242                           ac_lo= ac_hi=
26243                           break
26244                         fi
26245                         ac_mid=`expr 2 '*' $ac_mid + 1`
26246 fi
26247
26248 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26249   done
26250 else
26251   $as_echo "$as_me: failed program was:" >&5
26252 sed 's/^/| /' conftest.$ac_ext >&5
26253
26254         cat >conftest.$ac_ext <<_ACEOF
26255 /* confdefs.h.  */
26256 _ACEOF
26257 cat confdefs.h >>conftest.$ac_ext
26258 cat >>conftest.$ac_ext <<_ACEOF
26259 /* end confdefs.h.  */
26260 $ac_includes_default
26261 #ifndef offsetof
26262 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26263 #endif
26264 typedef struct { char x; long y; } ac__type_alignof_;
26265 int
26266 main ()
26267 {
26268 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26269 test_array [0] = 0
26270
26271   ;
26272   return 0;
26273 }
26274 _ACEOF
26275 rm -f conftest.$ac_objext
26276 if { (ac_try="$ac_compile"
26277 case "(($ac_try" in
26278   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26279   *) ac_try_echo=$ac_try;;
26280 esac
26281 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26282 $as_echo "$ac_try_echo") >&5
26283   (eval "$ac_compile") 2>conftest.er1
26284   ac_status=$?
26285   grep -v '^ *+' conftest.er1 >conftest.err
26286   rm -f conftest.er1
26287   cat conftest.err >&5
26288   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26289   (exit $ac_status); } && {
26290          test -z "$ac_c_werror_flag" ||
26291          test ! -s conftest.err
26292        } && test -s conftest.$ac_objext; then
26293   ac_hi=-1 ac_mid=-1
26294   while :; do
26295     cat >conftest.$ac_ext <<_ACEOF
26296 /* confdefs.h.  */
26297 _ACEOF
26298 cat confdefs.h >>conftest.$ac_ext
26299 cat >>conftest.$ac_ext <<_ACEOF
26300 /* end confdefs.h.  */
26301 $ac_includes_default
26302 #ifndef offsetof
26303 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26304 #endif
26305 typedef struct { char x; long y; } ac__type_alignof_;
26306 int
26307 main ()
26308 {
26309 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26310 test_array [0] = 0
26311
26312   ;
26313   return 0;
26314 }
26315 _ACEOF
26316 rm -f conftest.$ac_objext
26317 if { (ac_try="$ac_compile"
26318 case "(($ac_try" in
26319   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26320   *) ac_try_echo=$ac_try;;
26321 esac
26322 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26323 $as_echo "$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   $as_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   ac_lo=$ac_mid; break
26335 else
26336   $as_echo "$as_me: failed program was:" >&5
26337 sed 's/^/| /' conftest.$ac_ext >&5
26338
26339         ac_hi=`expr '(' $ac_mid ')' - 1`
26340                         if test $ac_mid -le $ac_hi; then
26341                           ac_lo= ac_hi=
26342                           break
26343                         fi
26344                         ac_mid=`expr 2 '*' $ac_mid`
26345 fi
26346
26347 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26348   done
26349 else
26350   $as_echo "$as_me: failed program was:" >&5
26351 sed 's/^/| /' conftest.$ac_ext >&5
26352
26353         ac_lo= ac_hi=
26354 fi
26355
26356 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26357 fi
26358
26359 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26360 # Binary search between lo and hi bounds.
26361 while test "x$ac_lo" != "x$ac_hi"; do
26362   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26363   cat >conftest.$ac_ext <<_ACEOF
26364 /* confdefs.h.  */
26365 _ACEOF
26366 cat confdefs.h >>conftest.$ac_ext
26367 cat >>conftest.$ac_ext <<_ACEOF
26368 /* end confdefs.h.  */
26369 $ac_includes_default
26370 #ifndef offsetof
26371 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26372 #endif
26373 typedef struct { char x; long y; } ac__type_alignof_;
26374 int
26375 main ()
26376 {
26377 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26378 test_array [0] = 0
26379
26380   ;
26381   return 0;
26382 }
26383 _ACEOF
26384 rm -f conftest.$ac_objext
26385 if { (ac_try="$ac_compile"
26386 case "(($ac_try" in
26387   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26388   *) ac_try_echo=$ac_try;;
26389 esac
26390 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26391 $as_echo "$ac_try_echo") >&5
26392   (eval "$ac_compile") 2>conftest.er1
26393   ac_status=$?
26394   grep -v '^ *+' conftest.er1 >conftest.err
26395   rm -f conftest.er1
26396   cat conftest.err >&5
26397   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26398   (exit $ac_status); } && {
26399          test -z "$ac_c_werror_flag" ||
26400          test ! -s conftest.err
26401        } && test -s conftest.$ac_objext; then
26402   ac_hi=$ac_mid
26403 else
26404   $as_echo "$as_me: failed program was:" >&5
26405 sed 's/^/| /' conftest.$ac_ext >&5
26406
26407         ac_lo=`expr '(' $ac_mid ')' + 1`
26408 fi
26409
26410 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26411 done
26412 case $ac_lo in
26413 ?*) ac_cv_alignof_long=$ac_lo;;
26414 '') if test "$ac_cv_type_long" = yes; then
26415      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26416 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26417 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long
26418 See \`config.log' for more details." >&5
26419 $as_echo "$as_me: error: cannot compute alignment of long
26420 See \`config.log' for more details." >&2;}
26421    { (exit 77); exit 77; }; }; }
26422    else
26423      ac_cv_alignof_long=0
26424    fi ;;
26425 esac
26426 else
26427   cat >conftest.$ac_ext <<_ACEOF
26428 /* confdefs.h.  */
26429 _ACEOF
26430 cat confdefs.h >>conftest.$ac_ext
26431 cat >>conftest.$ac_ext <<_ACEOF
26432 /* end confdefs.h.  */
26433 $ac_includes_default
26434 #ifndef offsetof
26435 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26436 #endif
26437 typedef struct { char x; long y; } ac__type_alignof_;
26438 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26439 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26440 #include <stdio.h>
26441 #include <stdlib.h>
26442 int
26443 main ()
26444 {
26445
26446   FILE *f = fopen ("conftest.val", "w");
26447   if (! f)
26448     return 1;
26449   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
26450     {
26451       long int i = longval ();
26452       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26453         return 1;
26454       fprintf (f, "%ld", i);
26455     }
26456   else
26457     {
26458       unsigned long int i = ulongval ();
26459       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26460         return 1;
26461       fprintf (f, "%lu", i);
26462     }
26463   /* Do not output a trailing newline, as this causes \r\n confusion
26464      on some platforms.  */
26465   return ferror (f) || fclose (f) != 0;
26466
26467   ;
26468   return 0;
26469 }
26470 _ACEOF
26471 rm -f conftest$ac_exeext
26472 if { (ac_try="$ac_link"
26473 case "(($ac_try" in
26474   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26475   *) ac_try_echo=$ac_try;;
26476 esac
26477 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26478 $as_echo "$ac_try_echo") >&5
26479   (eval "$ac_link") 2>&5
26480   ac_status=$?
26481   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26482   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26483   { (case "(($ac_try" in
26484   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26485   *) ac_try_echo=$ac_try;;
26486 esac
26487 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26488 $as_echo "$ac_try_echo") >&5
26489   (eval "$ac_try") 2>&5
26490   ac_status=$?
26491   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26492   (exit $ac_status); }; }; then
26493   ac_cv_alignof_long=`cat conftest.val`
26494 else
26495   $as_echo "$as_me: program exited with status $ac_status" >&5
26496 $as_echo "$as_me: failed program was:" >&5
26497 sed 's/^/| /' conftest.$ac_ext >&5
26498
26499 ( exit $ac_status )
26500 if test "$ac_cv_type_long" = yes; then
26501      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26502 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26503 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long
26504 See \`config.log' for more details." >&5
26505 $as_echo "$as_me: error: cannot compute alignment of long
26506 See \`config.log' for more details." >&2;}
26507    { (exit 77); exit 77; }; }; }
26508    else
26509      ac_cv_alignof_long=0
26510    fi
26511 fi
26512 rm -rf conftest.dSYM
26513 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26514 fi
26515 rm -f conftest.val
26516 fi
26517 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_long" >&5
26518 $as_echo "$ac_cv_alignof_long" >&6; }
26519
26520
26521
26522 cat >>confdefs.h <<_ACEOF
26523 #define ALIGNOF_LONG $ac_cv_alignof_long
26524 _ACEOF
26525
26526
26527 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
26528   # The cast to long int works around a bug in the HP C Compiler,
26529 # see AC_CHECK_SIZEOF for more information.
26530 { $as_echo "$as_me:$LINENO: checking alignment of long long int" >&5
26531 $as_echo_n "checking alignment of long long int... " >&6; }
26532 if test "${ac_cv_alignof_long_long_int+set}" = set; then
26533   $as_echo_n "(cached) " >&6
26534 else
26535   if test "$cross_compiling" = yes; then
26536   # Depending upon the size, compute the lo and hi bounds.
26537 cat >conftest.$ac_ext <<_ACEOF
26538 /* confdefs.h.  */
26539 _ACEOF
26540 cat confdefs.h >>conftest.$ac_ext
26541 cat >>conftest.$ac_ext <<_ACEOF
26542 /* end confdefs.h.  */
26543 $ac_includes_default
26544 #ifndef offsetof
26545 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26546 #endif
26547 typedef struct { char x; long long int y; } ac__type_alignof_;
26548 int
26549 main ()
26550 {
26551 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26552 test_array [0] = 0
26553
26554   ;
26555   return 0;
26556 }
26557 _ACEOF
26558 rm -f conftest.$ac_objext
26559 if { (ac_try="$ac_compile"
26560 case "(($ac_try" in
26561   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26562   *) ac_try_echo=$ac_try;;
26563 esac
26564 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26565 $as_echo "$ac_try_echo") >&5
26566   (eval "$ac_compile") 2>conftest.er1
26567   ac_status=$?
26568   grep -v '^ *+' conftest.er1 >conftest.err
26569   rm -f conftest.er1
26570   cat conftest.err >&5
26571   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26572   (exit $ac_status); } && {
26573          test -z "$ac_c_werror_flag" ||
26574          test ! -s conftest.err
26575        } && test -s conftest.$ac_objext; then
26576   ac_lo=0 ac_mid=0
26577   while :; do
26578     cat >conftest.$ac_ext <<_ACEOF
26579 /* confdefs.h.  */
26580 _ACEOF
26581 cat confdefs.h >>conftest.$ac_ext
26582 cat >>conftest.$ac_ext <<_ACEOF
26583 /* end confdefs.h.  */
26584 $ac_includes_default
26585 #ifndef offsetof
26586 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26587 #endif
26588 typedef struct { char x; long long int y; } ac__type_alignof_;
26589 int
26590 main ()
26591 {
26592 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26593 test_array [0] = 0
26594
26595   ;
26596   return 0;
26597 }
26598 _ACEOF
26599 rm -f conftest.$ac_objext
26600 if { (ac_try="$ac_compile"
26601 case "(($ac_try" in
26602   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26603   *) ac_try_echo=$ac_try;;
26604 esac
26605 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26606 $as_echo "$ac_try_echo") >&5
26607   (eval "$ac_compile") 2>conftest.er1
26608   ac_status=$?
26609   grep -v '^ *+' conftest.er1 >conftest.err
26610   rm -f conftest.er1
26611   cat conftest.err >&5
26612   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26613   (exit $ac_status); } && {
26614          test -z "$ac_c_werror_flag" ||
26615          test ! -s conftest.err
26616        } && test -s conftest.$ac_objext; then
26617   ac_hi=$ac_mid; break
26618 else
26619   $as_echo "$as_me: failed program was:" >&5
26620 sed 's/^/| /' conftest.$ac_ext >&5
26621
26622         ac_lo=`expr $ac_mid + 1`
26623                         if test $ac_lo -le $ac_mid; then
26624                           ac_lo= ac_hi=
26625                           break
26626                         fi
26627                         ac_mid=`expr 2 '*' $ac_mid + 1`
26628 fi
26629
26630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26631   done
26632 else
26633   $as_echo "$as_me: failed program was:" >&5
26634 sed 's/^/| /' conftest.$ac_ext >&5
26635
26636         cat >conftest.$ac_ext <<_ACEOF
26637 /* confdefs.h.  */
26638 _ACEOF
26639 cat confdefs.h >>conftest.$ac_ext
26640 cat >>conftest.$ac_ext <<_ACEOF
26641 /* end confdefs.h.  */
26642 $ac_includes_default
26643 #ifndef offsetof
26644 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26645 #endif
26646 typedef struct { char x; long long int y; } ac__type_alignof_;
26647 int
26648 main ()
26649 {
26650 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26651 test_array [0] = 0
26652
26653   ;
26654   return 0;
26655 }
26656 _ACEOF
26657 rm -f conftest.$ac_objext
26658 if { (ac_try="$ac_compile"
26659 case "(($ac_try" in
26660   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26661   *) ac_try_echo=$ac_try;;
26662 esac
26663 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26664 $as_echo "$ac_try_echo") >&5
26665   (eval "$ac_compile") 2>conftest.er1
26666   ac_status=$?
26667   grep -v '^ *+' conftest.er1 >conftest.err
26668   rm -f conftest.er1
26669   cat conftest.err >&5
26670   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26671   (exit $ac_status); } && {
26672          test -z "$ac_c_werror_flag" ||
26673          test ! -s conftest.err
26674        } && test -s conftest.$ac_objext; then
26675   ac_hi=-1 ac_mid=-1
26676   while :; do
26677     cat >conftest.$ac_ext <<_ACEOF
26678 /* confdefs.h.  */
26679 _ACEOF
26680 cat confdefs.h >>conftest.$ac_ext
26681 cat >>conftest.$ac_ext <<_ACEOF
26682 /* end confdefs.h.  */
26683 $ac_includes_default
26684 #ifndef offsetof
26685 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26686 #endif
26687 typedef struct { char x; long long int y; } ac__type_alignof_;
26688 int
26689 main ()
26690 {
26691 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26692 test_array [0] = 0
26693
26694   ;
26695   return 0;
26696 }
26697 _ACEOF
26698 rm -f conftest.$ac_objext
26699 if { (ac_try="$ac_compile"
26700 case "(($ac_try" in
26701   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26702   *) ac_try_echo=$ac_try;;
26703 esac
26704 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26705 $as_echo "$ac_try_echo") >&5
26706   (eval "$ac_compile") 2>conftest.er1
26707   ac_status=$?
26708   grep -v '^ *+' conftest.er1 >conftest.err
26709   rm -f conftest.er1
26710   cat conftest.err >&5
26711   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26712   (exit $ac_status); } && {
26713          test -z "$ac_c_werror_flag" ||
26714          test ! -s conftest.err
26715        } && test -s conftest.$ac_objext; then
26716   ac_lo=$ac_mid; break
26717 else
26718   $as_echo "$as_me: failed program was:" >&5
26719 sed 's/^/| /' conftest.$ac_ext >&5
26720
26721         ac_hi=`expr '(' $ac_mid ')' - 1`
26722                         if test $ac_mid -le $ac_hi; then
26723                           ac_lo= ac_hi=
26724                           break
26725                         fi
26726                         ac_mid=`expr 2 '*' $ac_mid`
26727 fi
26728
26729 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26730   done
26731 else
26732   $as_echo "$as_me: failed program was:" >&5
26733 sed 's/^/| /' conftest.$ac_ext >&5
26734
26735         ac_lo= ac_hi=
26736 fi
26737
26738 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26739 fi
26740
26741 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26742 # Binary search between lo and hi bounds.
26743 while test "x$ac_lo" != "x$ac_hi"; do
26744   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26745   cat >conftest.$ac_ext <<_ACEOF
26746 /* confdefs.h.  */
26747 _ACEOF
26748 cat confdefs.h >>conftest.$ac_ext
26749 cat >>conftest.$ac_ext <<_ACEOF
26750 /* end confdefs.h.  */
26751 $ac_includes_default
26752 #ifndef offsetof
26753 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26754 #endif
26755 typedef struct { char x; long long int y; } ac__type_alignof_;
26756 int
26757 main ()
26758 {
26759 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26760 test_array [0] = 0
26761
26762   ;
26763   return 0;
26764 }
26765 _ACEOF
26766 rm -f conftest.$ac_objext
26767 if { (ac_try="$ac_compile"
26768 case "(($ac_try" in
26769   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26770   *) ac_try_echo=$ac_try;;
26771 esac
26772 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26773 $as_echo "$ac_try_echo") >&5
26774   (eval "$ac_compile") 2>conftest.er1
26775   ac_status=$?
26776   grep -v '^ *+' conftest.er1 >conftest.err
26777   rm -f conftest.er1
26778   cat conftest.err >&5
26779   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26780   (exit $ac_status); } && {
26781          test -z "$ac_c_werror_flag" ||
26782          test ! -s conftest.err
26783        } && test -s conftest.$ac_objext; then
26784   ac_hi=$ac_mid
26785 else
26786   $as_echo "$as_me: failed program was:" >&5
26787 sed 's/^/| /' conftest.$ac_ext >&5
26788
26789         ac_lo=`expr '(' $ac_mid ')' + 1`
26790 fi
26791
26792 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26793 done
26794 case $ac_lo in
26795 ?*) ac_cv_alignof_long_long_int=$ac_lo;;
26796 '') if test "$ac_cv_type_long_long_int" = yes; then
26797      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26798 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26799 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long long int
26800 See \`config.log' for more details." >&5
26801 $as_echo "$as_me: error: cannot compute alignment of long long int
26802 See \`config.log' for more details." >&2;}
26803    { (exit 77); exit 77; }; }; }
26804    else
26805      ac_cv_alignof_long_long_int=0
26806    fi ;;
26807 esac
26808 else
26809   cat >conftest.$ac_ext <<_ACEOF
26810 /* confdefs.h.  */
26811 _ACEOF
26812 cat confdefs.h >>conftest.$ac_ext
26813 cat >>conftest.$ac_ext <<_ACEOF
26814 /* end confdefs.h.  */
26815 $ac_includes_default
26816 #ifndef offsetof
26817 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26818 #endif
26819 typedef struct { char x; long long int y; } ac__type_alignof_;
26820 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26821 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26822 #include <stdio.h>
26823 #include <stdlib.h>
26824 int
26825 main ()
26826 {
26827
26828   FILE *f = fopen ("conftest.val", "w");
26829   if (! f)
26830     return 1;
26831   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
26832     {
26833       long int i = longval ();
26834       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26835         return 1;
26836       fprintf (f, "%ld", i);
26837     }
26838   else
26839     {
26840       unsigned long int i = ulongval ();
26841       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26842         return 1;
26843       fprintf (f, "%lu", i);
26844     }
26845   /* Do not output a trailing newline, as this causes \r\n confusion
26846      on some platforms.  */
26847   return ferror (f) || fclose (f) != 0;
26848
26849   ;
26850   return 0;
26851 }
26852 _ACEOF
26853 rm -f conftest$ac_exeext
26854 if { (ac_try="$ac_link"
26855 case "(($ac_try" in
26856   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26857   *) ac_try_echo=$ac_try;;
26858 esac
26859 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26860 $as_echo "$ac_try_echo") >&5
26861   (eval "$ac_link") 2>&5
26862   ac_status=$?
26863   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26864   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26865   { (case "(($ac_try" in
26866   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26867   *) ac_try_echo=$ac_try;;
26868 esac
26869 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26870 $as_echo "$ac_try_echo") >&5
26871   (eval "$ac_try") 2>&5
26872   ac_status=$?
26873   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26874   (exit $ac_status); }; }; then
26875   ac_cv_alignof_long_long_int=`cat conftest.val`
26876 else
26877   $as_echo "$as_me: program exited with status $ac_status" >&5
26878 $as_echo "$as_me: failed program was:" >&5
26879 sed 's/^/| /' conftest.$ac_ext >&5
26880
26881 ( exit $ac_status )
26882 if test "$ac_cv_type_long_long_int" = yes; then
26883      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26884 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26885 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long long int
26886 See \`config.log' for more details." >&5
26887 $as_echo "$as_me: error: cannot compute alignment of long long int
26888 See \`config.log' for more details." >&2;}
26889    { (exit 77); exit 77; }; }; }
26890    else
26891      ac_cv_alignof_long_long_int=0
26892    fi
26893 fi
26894 rm -rf conftest.dSYM
26895 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26896 fi
26897 rm -f conftest.val
26898 fi
26899 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_long_long_int" >&5
26900 $as_echo "$ac_cv_alignof_long_long_int" >&6; }
26901
26902
26903
26904 cat >>confdefs.h <<_ACEOF
26905 #define ALIGNOF_LONG_LONG_INT $ac_cv_alignof_long_long_int
26906 _ACEOF
26907
26908
26909 fi
26910 # The cast to long int works around a bug in the HP C Compiler,
26911 # see AC_CHECK_SIZEOF for more information.
26912 { $as_echo "$as_me:$LINENO: checking alignment of double" >&5
26913 $as_echo_n "checking alignment of double... " >&6; }
26914 if test "${ac_cv_alignof_double+set}" = set; then
26915   $as_echo_n "(cached) " >&6
26916 else
26917   if test "$cross_compiling" = yes; then
26918   # Depending upon the size, compute the lo and hi bounds.
26919 cat >conftest.$ac_ext <<_ACEOF
26920 /* confdefs.h.  */
26921 _ACEOF
26922 cat confdefs.h >>conftest.$ac_ext
26923 cat >>conftest.$ac_ext <<_ACEOF
26924 /* end confdefs.h.  */
26925 $ac_includes_default
26926 #ifndef offsetof
26927 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26928 #endif
26929 typedef struct { char x; double y; } ac__type_alignof_;
26930 int
26931 main ()
26932 {
26933 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26934 test_array [0] = 0
26935
26936   ;
26937   return 0;
26938 }
26939 _ACEOF
26940 rm -f conftest.$ac_objext
26941 if { (ac_try="$ac_compile"
26942 case "(($ac_try" in
26943   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26944   *) ac_try_echo=$ac_try;;
26945 esac
26946 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26947 $as_echo "$ac_try_echo") >&5
26948   (eval "$ac_compile") 2>conftest.er1
26949   ac_status=$?
26950   grep -v '^ *+' conftest.er1 >conftest.err
26951   rm -f conftest.er1
26952   cat conftest.err >&5
26953   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26954   (exit $ac_status); } && {
26955          test -z "$ac_c_werror_flag" ||
26956          test ! -s conftest.err
26957        } && test -s conftest.$ac_objext; then
26958   ac_lo=0 ac_mid=0
26959   while :; do
26960     cat >conftest.$ac_ext <<_ACEOF
26961 /* confdefs.h.  */
26962 _ACEOF
26963 cat confdefs.h >>conftest.$ac_ext
26964 cat >>conftest.$ac_ext <<_ACEOF
26965 /* end confdefs.h.  */
26966 $ac_includes_default
26967 #ifndef offsetof
26968 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26969 #endif
26970 typedef struct { char x; double y; } ac__type_alignof_;
26971 int
26972 main ()
26973 {
26974 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26975 test_array [0] = 0
26976
26977   ;
26978   return 0;
26979 }
26980 _ACEOF
26981 rm -f conftest.$ac_objext
26982 if { (ac_try="$ac_compile"
26983 case "(($ac_try" in
26984   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26985   *) ac_try_echo=$ac_try;;
26986 esac
26987 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26988 $as_echo "$ac_try_echo") >&5
26989   (eval "$ac_compile") 2>conftest.er1
26990   ac_status=$?
26991   grep -v '^ *+' conftest.er1 >conftest.err
26992   rm -f conftest.er1
26993   cat conftest.err >&5
26994   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26995   (exit $ac_status); } && {
26996          test -z "$ac_c_werror_flag" ||
26997          test ! -s conftest.err
26998        } && test -s conftest.$ac_objext; then
26999   ac_hi=$ac_mid; break
27000 else
27001   $as_echo "$as_me: failed program was:" >&5
27002 sed 's/^/| /' conftest.$ac_ext >&5
27003
27004         ac_lo=`expr $ac_mid + 1`
27005                         if test $ac_lo -le $ac_mid; then
27006                           ac_lo= ac_hi=
27007                           break
27008                         fi
27009                         ac_mid=`expr 2 '*' $ac_mid + 1`
27010 fi
27011
27012 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27013   done
27014 else
27015   $as_echo "$as_me: failed program was:" >&5
27016 sed 's/^/| /' conftest.$ac_ext >&5
27017
27018         cat >conftest.$ac_ext <<_ACEOF
27019 /* confdefs.h.  */
27020 _ACEOF
27021 cat confdefs.h >>conftest.$ac_ext
27022 cat >>conftest.$ac_ext <<_ACEOF
27023 /* end confdefs.h.  */
27024 $ac_includes_default
27025 #ifndef offsetof
27026 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27027 #endif
27028 typedef struct { char x; double y; } ac__type_alignof_;
27029 int
27030 main ()
27031 {
27032 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
27033 test_array [0] = 0
27034
27035   ;
27036   return 0;
27037 }
27038 _ACEOF
27039 rm -f conftest.$ac_objext
27040 if { (ac_try="$ac_compile"
27041 case "(($ac_try" in
27042   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27043   *) ac_try_echo=$ac_try;;
27044 esac
27045 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27046 $as_echo "$ac_try_echo") >&5
27047   (eval "$ac_compile") 2>conftest.er1
27048   ac_status=$?
27049   grep -v '^ *+' conftest.er1 >conftest.err
27050   rm -f conftest.er1
27051   cat conftest.err >&5
27052   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27053   (exit $ac_status); } && {
27054          test -z "$ac_c_werror_flag" ||
27055          test ! -s conftest.err
27056        } && test -s conftest.$ac_objext; then
27057   ac_hi=-1 ac_mid=-1
27058   while :; do
27059     cat >conftest.$ac_ext <<_ACEOF
27060 /* confdefs.h.  */
27061 _ACEOF
27062 cat confdefs.h >>conftest.$ac_ext
27063 cat >>conftest.$ac_ext <<_ACEOF
27064 /* end confdefs.h.  */
27065 $ac_includes_default
27066 #ifndef offsetof
27067 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27068 #endif
27069 typedef struct { char x; double y; } ac__type_alignof_;
27070 int
27071 main ()
27072 {
27073 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
27074 test_array [0] = 0
27075
27076   ;
27077   return 0;
27078 }
27079 _ACEOF
27080 rm -f conftest.$ac_objext
27081 if { (ac_try="$ac_compile"
27082 case "(($ac_try" in
27083   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27084   *) ac_try_echo=$ac_try;;
27085 esac
27086 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27087 $as_echo "$ac_try_echo") >&5
27088   (eval "$ac_compile") 2>conftest.er1
27089   ac_status=$?
27090   grep -v '^ *+' conftest.er1 >conftest.err
27091   rm -f conftest.er1
27092   cat conftest.err >&5
27093   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27094   (exit $ac_status); } && {
27095          test -z "$ac_c_werror_flag" ||
27096          test ! -s conftest.err
27097        } && test -s conftest.$ac_objext; then
27098   ac_lo=$ac_mid; break
27099 else
27100   $as_echo "$as_me: failed program was:" >&5
27101 sed 's/^/| /' conftest.$ac_ext >&5
27102
27103         ac_hi=`expr '(' $ac_mid ')' - 1`
27104                         if test $ac_mid -le $ac_hi; then
27105                           ac_lo= ac_hi=
27106                           break
27107                         fi
27108                         ac_mid=`expr 2 '*' $ac_mid`
27109 fi
27110
27111 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27112   done
27113 else
27114   $as_echo "$as_me: failed program was:" >&5
27115 sed 's/^/| /' conftest.$ac_ext >&5
27116
27117         ac_lo= ac_hi=
27118 fi
27119
27120 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27121 fi
27122
27123 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27124 # Binary search between lo and hi bounds.
27125 while test "x$ac_lo" != "x$ac_hi"; do
27126   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
27127   cat >conftest.$ac_ext <<_ACEOF
27128 /* confdefs.h.  */
27129 _ACEOF
27130 cat confdefs.h >>conftest.$ac_ext
27131 cat >>conftest.$ac_ext <<_ACEOF
27132 /* end confdefs.h.  */
27133 $ac_includes_default
27134 #ifndef offsetof
27135 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27136 #endif
27137 typedef struct { char x; double y; } ac__type_alignof_;
27138 int
27139 main ()
27140 {
27141 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
27142 test_array [0] = 0
27143
27144   ;
27145   return 0;
27146 }
27147 _ACEOF
27148 rm -f conftest.$ac_objext
27149 if { (ac_try="$ac_compile"
27150 case "(($ac_try" in
27151   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27152   *) ac_try_echo=$ac_try;;
27153 esac
27154 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27155 $as_echo "$ac_try_echo") >&5
27156   (eval "$ac_compile") 2>conftest.er1
27157   ac_status=$?
27158   grep -v '^ *+' conftest.er1 >conftest.err
27159   rm -f conftest.er1
27160   cat conftest.err >&5
27161   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27162   (exit $ac_status); } && {
27163          test -z "$ac_c_werror_flag" ||
27164          test ! -s conftest.err
27165        } && test -s conftest.$ac_objext; then
27166   ac_hi=$ac_mid
27167 else
27168   $as_echo "$as_me: failed program was:" >&5
27169 sed 's/^/| /' conftest.$ac_ext >&5
27170
27171         ac_lo=`expr '(' $ac_mid ')' + 1`
27172 fi
27173
27174 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27175 done
27176 case $ac_lo in
27177 ?*) ac_cv_alignof_double=$ac_lo;;
27178 '') if test "$ac_cv_type_double" = yes; then
27179      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27180 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27181 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of double
27182 See \`config.log' for more details." >&5
27183 $as_echo "$as_me: error: cannot compute alignment of double
27184 See \`config.log' for more details." >&2;}
27185    { (exit 77); exit 77; }; }; }
27186    else
27187      ac_cv_alignof_double=0
27188    fi ;;
27189 esac
27190 else
27191   cat >conftest.$ac_ext <<_ACEOF
27192 /* confdefs.h.  */
27193 _ACEOF
27194 cat confdefs.h >>conftest.$ac_ext
27195 cat >>conftest.$ac_ext <<_ACEOF
27196 /* end confdefs.h.  */
27197 $ac_includes_default
27198 #ifndef offsetof
27199 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27200 #endif
27201 typedef struct { char x; double y; } ac__type_alignof_;
27202 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
27203 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
27204 #include <stdio.h>
27205 #include <stdlib.h>
27206 int
27207 main ()
27208 {
27209
27210   FILE *f = fopen ("conftest.val", "w");
27211   if (! f)
27212     return 1;
27213   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
27214     {
27215       long int i = longval ();
27216       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27217         return 1;
27218       fprintf (f, "%ld", i);
27219     }
27220   else
27221     {
27222       unsigned long int i = ulongval ();
27223       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27224         return 1;
27225       fprintf (f, "%lu", i);
27226     }
27227   /* Do not output a trailing newline, as this causes \r\n confusion
27228      on some platforms.  */
27229   return ferror (f) || fclose (f) != 0;
27230
27231   ;
27232   return 0;
27233 }
27234 _ACEOF
27235 rm -f conftest$ac_exeext
27236 if { (ac_try="$ac_link"
27237 case "(($ac_try" in
27238   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27239   *) ac_try_echo=$ac_try;;
27240 esac
27241 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27242 $as_echo "$ac_try_echo") >&5
27243   (eval "$ac_link") 2>&5
27244   ac_status=$?
27245   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27246   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27247   { (case "(($ac_try" in
27248   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27249   *) ac_try_echo=$ac_try;;
27250 esac
27251 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27252 $as_echo "$ac_try_echo") >&5
27253   (eval "$ac_try") 2>&5
27254   ac_status=$?
27255   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27256   (exit $ac_status); }; }; then
27257   ac_cv_alignof_double=`cat conftest.val`
27258 else
27259   $as_echo "$as_me: program exited with status $ac_status" >&5
27260 $as_echo "$as_me: failed program was:" >&5
27261 sed 's/^/| /' conftest.$ac_ext >&5
27262
27263 ( exit $ac_status )
27264 if test "$ac_cv_type_double" = yes; then
27265      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27266 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27267 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of double
27268 See \`config.log' for more details." >&5
27269 $as_echo "$as_me: error: cannot compute alignment of double
27270 See \`config.log' for more details." >&2;}
27271    { (exit 77); exit 77; }; }; }
27272    else
27273      ac_cv_alignof_double=0
27274    fi
27275 fi
27276 rm -rf conftest.dSYM
27277 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27278 fi
27279 rm -f conftest.val
27280 fi
27281 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_double" >&5
27282 $as_echo "$ac_cv_alignof_double" >&6; }
27283
27284
27285
27286 cat >>confdefs.h <<_ACEOF
27287 #define ALIGNOF_DOUBLE $ac_cv_alignof_double
27288 _ACEOF
27289
27290
27291
27292 # Compute maximum alignment of any basic type.
27293 # We assume long's alignment is at least as strong as char, short, or int;
27294 # but we must check long long (if it exists) and double.
27295
27296 MAX_ALIGNOF=$ac_cv_alignof_long
27297 if test $MAX_ALIGNOF -lt $ac_cv_alignof_double ; then
27298   MAX_ALIGNOF=$ac_cv_alignof_double
27299 fi
27300 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $ac_cv_alignof_long_long_int ; then
27301   MAX_ALIGNOF="$ac_cv_alignof_long_long_int"
27302 fi
27303
27304 cat >>confdefs.h <<_ACEOF
27305 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
27306 _ACEOF
27307
27308
27309
27310 # Some platforms predefine the types int8, int16, etc.  Only check
27311 # a (hopefully) representative subset.
27312 { $as_echo "$as_me:$LINENO: checking for int8" >&5
27313 $as_echo_n "checking for int8... " >&6; }
27314 if test "${ac_cv_type_int8+set}" = set; then
27315   $as_echo_n "(cached) " >&6
27316 else
27317   ac_cv_type_int8=no
27318 cat >conftest.$ac_ext <<_ACEOF
27319 /* confdefs.h.  */
27320 _ACEOF
27321 cat confdefs.h >>conftest.$ac_ext
27322 cat >>conftest.$ac_ext <<_ACEOF
27323 /* end confdefs.h.  */
27324 #include <stdio.h>
27325 #ifdef HAVE_SUPPORTDEFS_H
27326 #include <SupportDefs.h>
27327 #endif
27328
27329 int
27330 main ()
27331 {
27332 if (sizeof (int8))
27333        return 0;
27334   ;
27335   return 0;
27336 }
27337 _ACEOF
27338 rm -f conftest.$ac_objext
27339 if { (ac_try="$ac_compile"
27340 case "(($ac_try" in
27341   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27342   *) ac_try_echo=$ac_try;;
27343 esac
27344 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27345 $as_echo "$ac_try_echo") >&5
27346   (eval "$ac_compile") 2>conftest.er1
27347   ac_status=$?
27348   grep -v '^ *+' conftest.er1 >conftest.err
27349   rm -f conftest.er1
27350   cat conftest.err >&5
27351   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27352   (exit $ac_status); } && {
27353          test -z "$ac_c_werror_flag" ||
27354          test ! -s conftest.err
27355        } && test -s conftest.$ac_objext; then
27356   cat >conftest.$ac_ext <<_ACEOF
27357 /* confdefs.h.  */
27358 _ACEOF
27359 cat confdefs.h >>conftest.$ac_ext
27360 cat >>conftest.$ac_ext <<_ACEOF
27361 /* end confdefs.h.  */
27362 #include <stdio.h>
27363 #ifdef HAVE_SUPPORTDEFS_H
27364 #include <SupportDefs.h>
27365 #endif
27366
27367 int
27368 main ()
27369 {
27370 if (sizeof ((int8)))
27371           return 0;
27372   ;
27373   return 0;
27374 }
27375 _ACEOF
27376 rm -f conftest.$ac_objext
27377 if { (ac_try="$ac_compile"
27378 case "(($ac_try" in
27379   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27380   *) ac_try_echo=$ac_try;;
27381 esac
27382 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27383 $as_echo "$ac_try_echo") >&5
27384   (eval "$ac_compile") 2>conftest.er1
27385   ac_status=$?
27386   grep -v '^ *+' conftest.er1 >conftest.err
27387   rm -f conftest.er1
27388   cat conftest.err >&5
27389   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27390   (exit $ac_status); } && {
27391          test -z "$ac_c_werror_flag" ||
27392          test ! -s conftest.err
27393        } && test -s conftest.$ac_objext; then
27394   :
27395 else
27396   $as_echo "$as_me: failed program was:" >&5
27397 sed 's/^/| /' conftest.$ac_ext >&5
27398
27399         ac_cv_type_int8=yes
27400 fi
27401
27402 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27403 else
27404   $as_echo "$as_me: failed program was:" >&5
27405 sed 's/^/| /' conftest.$ac_ext >&5
27406
27407
27408 fi
27409
27410 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27411 fi
27412 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
27413 $as_echo "$ac_cv_type_int8" >&6; }
27414 if test "x$ac_cv_type_int8" = x""yes; then
27415
27416 cat >>confdefs.h <<_ACEOF
27417 #define HAVE_INT8 1
27418 _ACEOF
27419
27420
27421 fi
27422 { $as_echo "$as_me:$LINENO: checking for uint8" >&5
27423 $as_echo_n "checking for uint8... " >&6; }
27424 if test "${ac_cv_type_uint8+set}" = set; then
27425   $as_echo_n "(cached) " >&6
27426 else
27427   ac_cv_type_uint8=no
27428 cat >conftest.$ac_ext <<_ACEOF
27429 /* confdefs.h.  */
27430 _ACEOF
27431 cat confdefs.h >>conftest.$ac_ext
27432 cat >>conftest.$ac_ext <<_ACEOF
27433 /* end confdefs.h.  */
27434 #include <stdio.h>
27435 #ifdef HAVE_SUPPORTDEFS_H
27436 #include <SupportDefs.h>
27437 #endif
27438
27439 int
27440 main ()
27441 {
27442 if (sizeof (uint8))
27443        return 0;
27444   ;
27445   return 0;
27446 }
27447 _ACEOF
27448 rm -f conftest.$ac_objext
27449 if { (ac_try="$ac_compile"
27450 case "(($ac_try" in
27451   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27452   *) ac_try_echo=$ac_try;;
27453 esac
27454 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27455 $as_echo "$ac_try_echo") >&5
27456   (eval "$ac_compile") 2>conftest.er1
27457   ac_status=$?
27458   grep -v '^ *+' conftest.er1 >conftest.err
27459   rm -f conftest.er1
27460   cat conftest.err >&5
27461   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27462   (exit $ac_status); } && {
27463          test -z "$ac_c_werror_flag" ||
27464          test ! -s conftest.err
27465        } && test -s conftest.$ac_objext; then
27466   cat >conftest.$ac_ext <<_ACEOF
27467 /* confdefs.h.  */
27468 _ACEOF
27469 cat confdefs.h >>conftest.$ac_ext
27470 cat >>conftest.$ac_ext <<_ACEOF
27471 /* end confdefs.h.  */
27472 #include <stdio.h>
27473 #ifdef HAVE_SUPPORTDEFS_H
27474 #include <SupportDefs.h>
27475 #endif
27476
27477 int
27478 main ()
27479 {
27480 if (sizeof ((uint8)))
27481           return 0;
27482   ;
27483   return 0;
27484 }
27485 _ACEOF
27486 rm -f conftest.$ac_objext
27487 if { (ac_try="$ac_compile"
27488 case "(($ac_try" in
27489   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27490   *) ac_try_echo=$ac_try;;
27491 esac
27492 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27493 $as_echo "$ac_try_echo") >&5
27494   (eval "$ac_compile") 2>conftest.er1
27495   ac_status=$?
27496   grep -v '^ *+' conftest.er1 >conftest.err
27497   rm -f conftest.er1
27498   cat conftest.err >&5
27499   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27500   (exit $ac_status); } && {
27501          test -z "$ac_c_werror_flag" ||
27502          test ! -s conftest.err
27503        } && test -s conftest.$ac_objext; then
27504   :
27505 else
27506   $as_echo "$as_me: failed program was:" >&5
27507 sed 's/^/| /' conftest.$ac_ext >&5
27508
27509         ac_cv_type_uint8=yes
27510 fi
27511
27512 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27513 else
27514   $as_echo "$as_me: failed program was:" >&5
27515 sed 's/^/| /' conftest.$ac_ext >&5
27516
27517
27518 fi
27519
27520 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27521 fi
27522 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
27523 $as_echo "$ac_cv_type_uint8" >&6; }
27524 if test "x$ac_cv_type_uint8" = x""yes; then
27525
27526 cat >>confdefs.h <<_ACEOF
27527 #define HAVE_UINT8 1
27528 _ACEOF
27529
27530
27531 fi
27532 { $as_echo "$as_me:$LINENO: checking for int64" >&5
27533 $as_echo_n "checking for int64... " >&6; }
27534 if test "${ac_cv_type_int64+set}" = set; then
27535   $as_echo_n "(cached) " >&6
27536 else
27537   ac_cv_type_int64=no
27538 cat >conftest.$ac_ext <<_ACEOF
27539 /* confdefs.h.  */
27540 _ACEOF
27541 cat confdefs.h >>conftest.$ac_ext
27542 cat >>conftest.$ac_ext <<_ACEOF
27543 /* end confdefs.h.  */
27544 #include <stdio.h>
27545 #ifdef HAVE_SUPPORTDEFS_H
27546 #include <SupportDefs.h>
27547 #endif
27548
27549 int
27550 main ()
27551 {
27552 if (sizeof (int64))
27553        return 0;
27554   ;
27555   return 0;
27556 }
27557 _ACEOF
27558 rm -f conftest.$ac_objext
27559 if { (ac_try="$ac_compile"
27560 case "(($ac_try" in
27561   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27562   *) ac_try_echo=$ac_try;;
27563 esac
27564 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27565 $as_echo "$ac_try_echo") >&5
27566   (eval "$ac_compile") 2>conftest.er1
27567   ac_status=$?
27568   grep -v '^ *+' conftest.er1 >conftest.err
27569   rm -f conftest.er1
27570   cat conftest.err >&5
27571   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27572   (exit $ac_status); } && {
27573          test -z "$ac_c_werror_flag" ||
27574          test ! -s conftest.err
27575        } && test -s conftest.$ac_objext; then
27576   cat >conftest.$ac_ext <<_ACEOF
27577 /* confdefs.h.  */
27578 _ACEOF
27579 cat confdefs.h >>conftest.$ac_ext
27580 cat >>conftest.$ac_ext <<_ACEOF
27581 /* end confdefs.h.  */
27582 #include <stdio.h>
27583 #ifdef HAVE_SUPPORTDEFS_H
27584 #include <SupportDefs.h>
27585 #endif
27586
27587 int
27588 main ()
27589 {
27590 if (sizeof ((int64)))
27591           return 0;
27592   ;
27593   return 0;
27594 }
27595 _ACEOF
27596 rm -f conftest.$ac_objext
27597 if { (ac_try="$ac_compile"
27598 case "(($ac_try" in
27599   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27600   *) ac_try_echo=$ac_try;;
27601 esac
27602 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27603 $as_echo "$ac_try_echo") >&5
27604   (eval "$ac_compile") 2>conftest.er1
27605   ac_status=$?
27606   grep -v '^ *+' conftest.er1 >conftest.err
27607   rm -f conftest.er1
27608   cat conftest.err >&5
27609   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27610   (exit $ac_status); } && {
27611          test -z "$ac_c_werror_flag" ||
27612          test ! -s conftest.err
27613        } && test -s conftest.$ac_objext; then
27614   :
27615 else
27616   $as_echo "$as_me: failed program was:" >&5
27617 sed 's/^/| /' conftest.$ac_ext >&5
27618
27619         ac_cv_type_int64=yes
27620 fi
27621
27622 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27623 else
27624   $as_echo "$as_me: failed program was:" >&5
27625 sed 's/^/| /' conftest.$ac_ext >&5
27626
27627
27628 fi
27629
27630 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27631 fi
27632 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
27633 $as_echo "$ac_cv_type_int64" >&6; }
27634 if test "x$ac_cv_type_int64" = x""yes; then
27635
27636 cat >>confdefs.h <<_ACEOF
27637 #define HAVE_INT64 1
27638 _ACEOF
27639
27640
27641 fi
27642 { $as_echo "$as_me:$LINENO: checking for uint64" >&5
27643 $as_echo_n "checking for uint64... " >&6; }
27644 if test "${ac_cv_type_uint64+set}" = set; then
27645   $as_echo_n "(cached) " >&6
27646 else
27647   ac_cv_type_uint64=no
27648 cat >conftest.$ac_ext <<_ACEOF
27649 /* confdefs.h.  */
27650 _ACEOF
27651 cat confdefs.h >>conftest.$ac_ext
27652 cat >>conftest.$ac_ext <<_ACEOF
27653 /* end confdefs.h.  */
27654 #include <stdio.h>
27655 #ifdef HAVE_SUPPORTDEFS_H
27656 #include <SupportDefs.h>
27657 #endif
27658
27659 int
27660 main ()
27661 {
27662 if (sizeof (uint64))
27663        return 0;
27664   ;
27665   return 0;
27666 }
27667 _ACEOF
27668 rm -f conftest.$ac_objext
27669 if { (ac_try="$ac_compile"
27670 case "(($ac_try" in
27671   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27672   *) ac_try_echo=$ac_try;;
27673 esac
27674 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27675 $as_echo "$ac_try_echo") >&5
27676   (eval "$ac_compile") 2>conftest.er1
27677   ac_status=$?
27678   grep -v '^ *+' conftest.er1 >conftest.err
27679   rm -f conftest.er1
27680   cat conftest.err >&5
27681   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27682   (exit $ac_status); } && {
27683          test -z "$ac_c_werror_flag" ||
27684          test ! -s conftest.err
27685        } && test -s conftest.$ac_objext; then
27686   cat >conftest.$ac_ext <<_ACEOF
27687 /* confdefs.h.  */
27688 _ACEOF
27689 cat confdefs.h >>conftest.$ac_ext
27690 cat >>conftest.$ac_ext <<_ACEOF
27691 /* end confdefs.h.  */
27692 #include <stdio.h>
27693 #ifdef HAVE_SUPPORTDEFS_H
27694 #include <SupportDefs.h>
27695 #endif
27696
27697 int
27698 main ()
27699 {
27700 if (sizeof ((uint64)))
27701           return 0;
27702   ;
27703   return 0;
27704 }
27705 _ACEOF
27706 rm -f conftest.$ac_objext
27707 if { (ac_try="$ac_compile"
27708 case "(($ac_try" in
27709   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27710   *) ac_try_echo=$ac_try;;
27711 esac
27712 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27713 $as_echo "$ac_try_echo") >&5
27714   (eval "$ac_compile") 2>conftest.er1
27715   ac_status=$?
27716   grep -v '^ *+' conftest.er1 >conftest.err
27717   rm -f conftest.er1
27718   cat conftest.err >&5
27719   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27720   (exit $ac_status); } && {
27721          test -z "$ac_c_werror_flag" ||
27722          test ! -s conftest.err
27723        } && test -s conftest.$ac_objext; then
27724   :
27725 else
27726   $as_echo "$as_me: failed program was:" >&5
27727 sed 's/^/| /' conftest.$ac_ext >&5
27728
27729         ac_cv_type_uint64=yes
27730 fi
27731
27732 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27733 else
27734   $as_echo "$as_me: failed program was:" >&5
27735 sed 's/^/| /' conftest.$ac_ext >&5
27736
27737
27738 fi
27739
27740 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27741 fi
27742 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
27743 $as_echo "$ac_cv_type_uint64" >&6; }
27744 if test "x$ac_cv_type_uint64" = x""yes; then
27745
27746 cat >>confdefs.h <<_ACEOF
27747 #define HAVE_UINT64 1
27748 _ACEOF
27749
27750
27751 fi
27752
27753
27754 # We also check for sig_atomic_t, which *should* be defined per ANSI
27755 # C, but is missing on some old platforms.
27756 { $as_echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
27757 $as_echo_n "checking for sig_atomic_t... " >&6; }
27758 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
27759   $as_echo_n "(cached) " >&6
27760 else
27761   ac_cv_type_sig_atomic_t=no
27762 cat >conftest.$ac_ext <<_ACEOF
27763 /* confdefs.h.  */
27764 _ACEOF
27765 cat confdefs.h >>conftest.$ac_ext
27766 cat >>conftest.$ac_ext <<_ACEOF
27767 /* end confdefs.h.  */
27768 #include <signal.h>
27769
27770 int
27771 main ()
27772 {
27773 if (sizeof (sig_atomic_t))
27774        return 0;
27775   ;
27776   return 0;
27777 }
27778 _ACEOF
27779 rm -f conftest.$ac_objext
27780 if { (ac_try="$ac_compile"
27781 case "(($ac_try" in
27782   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27783   *) ac_try_echo=$ac_try;;
27784 esac
27785 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27786 $as_echo "$ac_try_echo") >&5
27787   (eval "$ac_compile") 2>conftest.er1
27788   ac_status=$?
27789   grep -v '^ *+' conftest.er1 >conftest.err
27790   rm -f conftest.er1
27791   cat conftest.err >&5
27792   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27793   (exit $ac_status); } && {
27794          test -z "$ac_c_werror_flag" ||
27795          test ! -s conftest.err
27796        } && test -s conftest.$ac_objext; then
27797   cat >conftest.$ac_ext <<_ACEOF
27798 /* confdefs.h.  */
27799 _ACEOF
27800 cat confdefs.h >>conftest.$ac_ext
27801 cat >>conftest.$ac_ext <<_ACEOF
27802 /* end confdefs.h.  */
27803 #include <signal.h>
27804
27805 int
27806 main ()
27807 {
27808 if (sizeof ((sig_atomic_t)))
27809           return 0;
27810   ;
27811   return 0;
27812 }
27813 _ACEOF
27814 rm -f conftest.$ac_objext
27815 if { (ac_try="$ac_compile"
27816 case "(($ac_try" in
27817   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27818   *) ac_try_echo=$ac_try;;
27819 esac
27820 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27821 $as_echo "$ac_try_echo") >&5
27822   (eval "$ac_compile") 2>conftest.er1
27823   ac_status=$?
27824   grep -v '^ *+' conftest.er1 >conftest.err
27825   rm -f conftest.er1
27826   cat conftest.err >&5
27827   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27828   (exit $ac_status); } && {
27829          test -z "$ac_c_werror_flag" ||
27830          test ! -s conftest.err
27831        } && test -s conftest.$ac_objext; then
27832   :
27833 else
27834   $as_echo "$as_me: failed program was:" >&5
27835 sed 's/^/| /' conftest.$ac_ext >&5
27836
27837         ac_cv_type_sig_atomic_t=yes
27838 fi
27839
27840 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27841 else
27842   $as_echo "$as_me: failed program was:" >&5
27843 sed 's/^/| /' conftest.$ac_ext >&5
27844
27845
27846 fi
27847
27848 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27849 fi
27850 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
27851 $as_echo "$ac_cv_type_sig_atomic_t" >&6; }
27852 if test "x$ac_cv_type_sig_atomic_t" = x""yes; then
27853
27854 cat >>confdefs.h <<_ACEOF
27855 #define HAVE_SIG_ATOMIC_T 1
27856 _ACEOF
27857
27858
27859 fi
27860
27861
27862
27863 if test "$PORTNAME" != "win32"
27864 then
27865 { $as_echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
27866 $as_echo_n "checking for POSIX signal interface... " >&6; }
27867 if test "${pgac_cv_func_posix_signals+set}" = set; then
27868   $as_echo_n "(cached) " >&6
27869 else
27870   cat >conftest.$ac_ext <<_ACEOF
27871 /* confdefs.h.  */
27872 _ACEOF
27873 cat confdefs.h >>conftest.$ac_ext
27874 cat >>conftest.$ac_ext <<_ACEOF
27875 /* end confdefs.h.  */
27876 #include <signal.h>
27877
27878 int
27879 main ()
27880 {
27881 struct sigaction act, oact;
27882 sigemptyset(&act.sa_mask);
27883 act.sa_flags = SA_RESTART;
27884 sigaction(0, &act, &oact);
27885   ;
27886   return 0;
27887 }
27888 _ACEOF
27889 rm -f conftest.$ac_objext conftest$ac_exeext
27890 if { (ac_try="$ac_link"
27891 case "(($ac_try" in
27892   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27893   *) ac_try_echo=$ac_try;;
27894 esac
27895 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27896 $as_echo "$ac_try_echo") >&5
27897   (eval "$ac_link") 2>conftest.er1
27898   ac_status=$?
27899   grep -v '^ *+' conftest.er1 >conftest.err
27900   rm -f conftest.er1
27901   cat conftest.err >&5
27902   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27903   (exit $ac_status); } && {
27904          test -z "$ac_c_werror_flag" ||
27905          test ! -s conftest.err
27906        } && test -s conftest$ac_exeext && {
27907          test "$cross_compiling" = yes ||
27908          $as_test_x conftest$ac_exeext
27909        }; then
27910   pgac_cv_func_posix_signals=yes
27911 else
27912   $as_echo "$as_me: failed program was:" >&5
27913 sed 's/^/| /' conftest.$ac_ext >&5
27914
27915         pgac_cv_func_posix_signals=no
27916 fi
27917
27918 rm -rf conftest.dSYM
27919 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
27920       conftest$ac_exeext conftest.$ac_ext
27921 fi
27922 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
27923 $as_echo "$pgac_cv_func_posix_signals" >&6; }
27924 if test x"$pgac_cv_func_posix_signals" = xyes ; then
27925
27926 cat >>confdefs.h <<\_ACEOF
27927 #define HAVE_POSIX_SIGNALS /**/
27928 _ACEOF
27929
27930 fi
27931 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
27932
27933 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
27934   { { $as_echo "$as_me:$LINENO: error:
27935 Thread-safety requires POSIX signals, which are not supported by this
27936 operating system;  use --disable-thread-safety to disable thread safety." >&5
27937 $as_echo "$as_me: error:
27938 Thread-safety requires POSIX signals, which are not supported by this
27939 operating system;  use --disable-thread-safety to disable thread safety." >&2;}
27940    { (exit 1); exit 1; }; }
27941 fi
27942 fi
27943
27944 # SunOS doesn't handle negative byte comparisons properly with +/- return
27945 { $as_echo "$as_me:$LINENO: checking for working memcmp" >&5
27946 $as_echo_n "checking for working memcmp... " >&6; }
27947 if test "${ac_cv_func_memcmp_working+set}" = set; then
27948   $as_echo_n "(cached) " >&6
27949 else
27950   if test "$cross_compiling" = yes; then
27951   ac_cv_func_memcmp_working=no
27952 else
27953   cat >conftest.$ac_ext <<_ACEOF
27954 /* confdefs.h.  */
27955 _ACEOF
27956 cat confdefs.h >>conftest.$ac_ext
27957 cat >>conftest.$ac_ext <<_ACEOF
27958 /* end confdefs.h.  */
27959 $ac_includes_default
27960 int
27961 main ()
27962 {
27963
27964   /* Some versions of memcmp are not 8-bit clean.  */
27965   char c0 = '\100', c1 = '\200', c2 = '\201';
27966   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
27967     return 1;
27968
27969   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
27970      or more and with at least one buffer not starting on a 4-byte boundary.
27971      William Lewis provided this test program.   */
27972   {
27973     char foo[21];
27974     char bar[21];
27975     int i;
27976     for (i = 0; i < 4; i++)
27977       {
27978         char *a = foo + i;
27979         char *b = bar + i;
27980         strcpy (a, "--------01111111");
27981         strcpy (b, "--------10000000");
27982         if (memcmp (a, b, 16) >= 0)
27983           return 1;
27984       }
27985     return 0;
27986   }
27987
27988   ;
27989   return 0;
27990 }
27991 _ACEOF
27992 rm -f conftest$ac_exeext
27993 if { (ac_try="$ac_link"
27994 case "(($ac_try" in
27995   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27996   *) ac_try_echo=$ac_try;;
27997 esac
27998 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27999 $as_echo "$ac_try_echo") >&5
28000   (eval "$ac_link") 2>&5
28001   ac_status=$?
28002   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28003   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28004   { (case "(($ac_try" in
28005   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28006   *) ac_try_echo=$ac_try;;
28007 esac
28008 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28009 $as_echo "$ac_try_echo") >&5
28010   (eval "$ac_try") 2>&5
28011   ac_status=$?
28012   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28013   (exit $ac_status); }; }; then
28014   ac_cv_func_memcmp_working=yes
28015 else
28016   $as_echo "$as_me: program exited with status $ac_status" >&5
28017 $as_echo "$as_me: failed program was:" >&5
28018 sed 's/^/| /' conftest.$ac_ext >&5
28019
28020 ( exit $ac_status )
28021 ac_cv_func_memcmp_working=no
28022 fi
28023 rm -rf conftest.dSYM
28024 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
28025 fi
28026
28027
28028 fi
28029 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
28030 $as_echo "$ac_cv_func_memcmp_working" >&6; }
28031 test $ac_cv_func_memcmp_working = no && case " $LIBOBJS " in
28032   *" memcmp.$ac_objext "* ) ;;
28033   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
28034  ;;
28035 esac
28036
28037
28038
28039
28040 # Select semaphore implementation type.
28041 if test "$PORTNAME" != "win32"; then
28042   if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
28043
28044 cat >>confdefs.h <<\_ACEOF
28045 #define USE_NAMED_POSIX_SEMAPHORES 1
28046 _ACEOF
28047
28048     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
28049   else
28050     if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
28051
28052 cat >>confdefs.h <<\_ACEOF
28053 #define USE_UNNAMED_POSIX_SEMAPHORES 1
28054 _ACEOF
28055
28056       SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
28057     else
28058
28059 cat >>confdefs.h <<\_ACEOF
28060 #define USE_SYSV_SEMAPHORES 1
28061 _ACEOF
28062
28063       SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
28064     fi
28065   fi
28066 else
28067
28068 cat >>confdefs.h <<\_ACEOF
28069 #define USE_WIN32_SEMAPHORES 1
28070 _ACEOF
28071
28072   SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
28073 fi
28074
28075
28076 # Select shared-memory implementation type.
28077 if test "$PORTNAME" != "win32"; then
28078
28079 cat >>confdefs.h <<\_ACEOF
28080 #define USE_SYSV_SHARED_MEMORY 1
28081 _ACEOF
28082
28083   SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
28084 else
28085
28086 cat >>confdefs.h <<\_ACEOF
28087 #define USE_WIN32_SHARED_MEMORY 1
28088 _ACEOF
28089
28090   SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.c"
28091 fi
28092
28093 # Select latch implementation type.
28094 if test "$PORTNAME" != "win32"; then
28095   LATCH_IMPLEMENTATION="src/backend/port/unix_latch.c"
28096 else
28097   LATCH_IMPLEMENTATION="src/backend/port/win32_latch.c"
28098 fi
28099
28100 # If not set in template file, set bytes to use libc memset()
28101 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
28102   MEMSET_LOOP_LIMIT=1024
28103 fi
28104
28105 cat >>confdefs.h <<_ACEOF
28106 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
28107 _ACEOF
28108
28109
28110
28111 if test "$enable_nls" = yes ; then
28112
28113   { $as_echo "$as_me:$LINENO: checking for library containing bind_textdomain_codeset" >&5
28114 $as_echo_n "checking for library containing bind_textdomain_codeset... " >&6; }
28115 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
28116   $as_echo_n "(cached) " >&6
28117 else
28118   ac_func_search_save_LIBS=$LIBS
28119 cat >conftest.$ac_ext <<_ACEOF
28120 /* confdefs.h.  */
28121 _ACEOF
28122 cat confdefs.h >>conftest.$ac_ext
28123 cat >>conftest.$ac_ext <<_ACEOF
28124 /* end confdefs.h.  */
28125
28126 /* Override any GCC internal prototype to avoid an error.
28127    Use char because int might match the return type of a GCC
28128    builtin and then its argument prototype would still apply.  */
28129 #ifdef __cplusplus
28130 extern "C"
28131 #endif
28132 char bind_textdomain_codeset ();
28133 int
28134 main ()
28135 {
28136 return bind_textdomain_codeset ();
28137   ;
28138   return 0;
28139 }
28140 _ACEOF
28141 for ac_lib in '' intl; do
28142   if test -z "$ac_lib"; then
28143     ac_res="none required"
28144   else
28145     ac_res=-l$ac_lib
28146     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
28147   fi
28148   rm -f conftest.$ac_objext conftest$ac_exeext
28149 if { (ac_try="$ac_link"
28150 case "(($ac_try" in
28151   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28152   *) ac_try_echo=$ac_try;;
28153 esac
28154 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28155 $as_echo "$ac_try_echo") >&5
28156   (eval "$ac_link") 2>conftest.er1
28157   ac_status=$?
28158   grep -v '^ *+' conftest.er1 >conftest.err
28159   rm -f conftest.er1
28160   cat conftest.err >&5
28161   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28162   (exit $ac_status); } && {
28163          test -z "$ac_c_werror_flag" ||
28164          test ! -s conftest.err
28165        } && test -s conftest$ac_exeext && {
28166          test "$cross_compiling" = yes ||
28167          $as_test_x conftest$ac_exeext
28168        }; then
28169   ac_cv_search_bind_textdomain_codeset=$ac_res
28170 else
28171   $as_echo "$as_me: failed program was:" >&5
28172 sed 's/^/| /' conftest.$ac_ext >&5
28173
28174
28175 fi
28176
28177 rm -rf conftest.dSYM
28178 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
28179       conftest$ac_exeext
28180   if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
28181   break
28182 fi
28183 done
28184 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
28185   :
28186 else
28187   ac_cv_search_bind_textdomain_codeset=no
28188 fi
28189 rm conftest.$ac_ext
28190 LIBS=$ac_func_search_save_LIBS
28191 fi
28192 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_bind_textdomain_codeset" >&5
28193 $as_echo "$ac_cv_search_bind_textdomain_codeset" >&6; }
28194 ac_res=$ac_cv_search_bind_textdomain_codeset
28195 if test "$ac_res" != no; then
28196   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
28197
28198 else
28199   { { $as_echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
28200 $as_echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
28201    { (exit 1); exit 1; }; }
28202 fi
28203
28204   if test "${ac_cv_header_libintl_h+set}" = set; then
28205   { $as_echo "$as_me:$LINENO: checking for libintl.h" >&5
28206 $as_echo_n "checking for libintl.h... " >&6; }
28207 if test "${ac_cv_header_libintl_h+set}" = set; then
28208   $as_echo_n "(cached) " >&6
28209 fi
28210 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
28211 $as_echo "$ac_cv_header_libintl_h" >&6; }
28212 else
28213   # Is the header compilable?
28214 { $as_echo "$as_me:$LINENO: checking libintl.h usability" >&5
28215 $as_echo_n "checking libintl.h usability... " >&6; }
28216 cat >conftest.$ac_ext <<_ACEOF
28217 /* confdefs.h.  */
28218 _ACEOF
28219 cat confdefs.h >>conftest.$ac_ext
28220 cat >>conftest.$ac_ext <<_ACEOF
28221 /* end confdefs.h.  */
28222 $ac_includes_default
28223 #include <libintl.h>
28224 _ACEOF
28225 rm -f conftest.$ac_objext
28226 if { (ac_try="$ac_compile"
28227 case "(($ac_try" in
28228   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28229   *) ac_try_echo=$ac_try;;
28230 esac
28231 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28232 $as_echo "$ac_try_echo") >&5
28233   (eval "$ac_compile") 2>conftest.er1
28234   ac_status=$?
28235   grep -v '^ *+' conftest.er1 >conftest.err
28236   rm -f conftest.er1
28237   cat conftest.err >&5
28238   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28239   (exit $ac_status); } && {
28240          test -z "$ac_c_werror_flag" ||
28241          test ! -s conftest.err
28242        } && test -s conftest.$ac_objext; then
28243   ac_header_compiler=yes
28244 else
28245   $as_echo "$as_me: failed program was:" >&5
28246 sed 's/^/| /' conftest.$ac_ext >&5
28247
28248         ac_header_compiler=no
28249 fi
28250
28251 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28252 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28253 $as_echo "$ac_header_compiler" >&6; }
28254
28255 # Is the header present?
28256 { $as_echo "$as_me:$LINENO: checking libintl.h presence" >&5
28257 $as_echo_n "checking libintl.h presence... " >&6; }
28258 cat >conftest.$ac_ext <<_ACEOF
28259 /* confdefs.h.  */
28260 _ACEOF
28261 cat confdefs.h >>conftest.$ac_ext
28262 cat >>conftest.$ac_ext <<_ACEOF
28263 /* end confdefs.h.  */
28264 #include <libintl.h>
28265 _ACEOF
28266 if { (ac_try="$ac_cpp conftest.$ac_ext"
28267 case "(($ac_try" in
28268   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28269   *) ac_try_echo=$ac_try;;
28270 esac
28271 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28272 $as_echo "$ac_try_echo") >&5
28273   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
28274   ac_status=$?
28275   grep -v '^ *+' conftest.er1 >conftest.err
28276   rm -f conftest.er1
28277   cat conftest.err >&5
28278   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28279   (exit $ac_status); } >/dev/null && {
28280          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
28281          test ! -s conftest.err
28282        }; then
28283   ac_header_preproc=yes
28284 else
28285   $as_echo "$as_me: failed program was:" >&5
28286 sed 's/^/| /' conftest.$ac_ext >&5
28287
28288   ac_header_preproc=no
28289 fi
28290
28291 rm -f conftest.err conftest.$ac_ext
28292 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28293 $as_echo "$ac_header_preproc" >&6; }
28294
28295 # So?  What about this header?
28296 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
28297   yes:no: )
28298     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
28299 $as_echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
28300     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5
28301 $as_echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;}
28302     ac_header_preproc=yes
28303     ;;
28304   no:yes:* )
28305     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
28306 $as_echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
28307     { $as_echo "$as_me:$LINENO: WARNING: libintl.h:     check for missing prerequisite headers?" >&5
28308 $as_echo "$as_me: WARNING: libintl.h:     check for missing prerequisite headers?" >&2;}
28309     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5
28310 $as_echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;}
28311     { $as_echo "$as_me:$LINENO: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&5
28312 $as_echo "$as_me: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
28313     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
28314 $as_echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;}
28315     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5
28316 $as_echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;}
28317     ( cat <<\_ASBOX
28318 ## ---------------------------------------- ##
28319 ## Report this to pgsql-bugs@postgresql.org ##
28320 ## ---------------------------------------- ##
28321 _ASBOX
28322      ) | sed "s/^/$as_me: WARNING:     /" >&2
28323     ;;
28324 esac
28325 { $as_echo "$as_me:$LINENO: checking for libintl.h" >&5
28326 $as_echo_n "checking for libintl.h... " >&6; }
28327 if test "${ac_cv_header_libintl_h+set}" = set; then
28328   $as_echo_n "(cached) " >&6
28329 else
28330   ac_cv_header_libintl_h=$ac_header_preproc
28331 fi
28332 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
28333 $as_echo "$ac_cv_header_libintl_h" >&6; }
28334
28335 fi
28336 if test "x$ac_cv_header_libintl_h" = x""yes; then
28337   :
28338 else
28339   { { $as_echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
28340 $as_echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
28341    { (exit 1); exit 1; }; }
28342 fi
28343
28344
28345   for ac_prog in msgfmt
28346 do
28347   # Extract the first word of "$ac_prog", so it can be a program name with args.
28348 set dummy $ac_prog; ac_word=$2
28349 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28350 $as_echo_n "checking for $ac_word... " >&6; }
28351 if test "${ac_cv_prog_MSGFMT+set}" = set; then
28352   $as_echo_n "(cached) " >&6
28353 else
28354   if test -n "$MSGFMT"; then
28355   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
28356 else
28357 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28358 for as_dir in $PATH
28359 do
28360   IFS=$as_save_IFS
28361   test -z "$as_dir" && as_dir=.
28362   for ac_exec_ext in '' $ac_executable_extensions; do
28363   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28364     ac_cv_prog_MSGFMT="$ac_prog"
28365     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28366     break 2
28367   fi
28368 done
28369 done
28370 IFS=$as_save_IFS
28371
28372 fi
28373 fi
28374 MSGFMT=$ac_cv_prog_MSGFMT
28375 if test -n "$MSGFMT"; then
28376   { $as_echo "$as_me:$LINENO: result: $MSGFMT" >&5
28377 $as_echo "$MSGFMT" >&6; }
28378 else
28379   { $as_echo "$as_me:$LINENO: result: no" >&5
28380 $as_echo "no" >&6; }
28381 fi
28382
28383
28384   test -n "$MSGFMT" && break
28385 done
28386
28387   if test -z "$MSGFMT"; then
28388     { { $as_echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
28389 $as_echo "$as_me: error: msgfmt is required for NLS" >&2;}
28390    { (exit 1); exit 1; }; }
28391   fi
28392   for ac_prog in msgmerge
28393 do
28394   # Extract the first word of "$ac_prog", so it can be a program name with args.
28395 set dummy $ac_prog; ac_word=$2
28396 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28397 $as_echo_n "checking for $ac_word... " >&6; }
28398 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
28399   $as_echo_n "(cached) " >&6
28400 else
28401   if test -n "$MSGMERGE"; then
28402   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
28403 else
28404 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28405 for as_dir in $PATH
28406 do
28407   IFS=$as_save_IFS
28408   test -z "$as_dir" && as_dir=.
28409   for ac_exec_ext in '' $ac_executable_extensions; do
28410   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28411     ac_cv_prog_MSGMERGE="$ac_prog"
28412     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28413     break 2
28414   fi
28415 done
28416 done
28417 IFS=$as_save_IFS
28418
28419 fi
28420 fi
28421 MSGMERGE=$ac_cv_prog_MSGMERGE
28422 if test -n "$MSGMERGE"; then
28423   { $as_echo "$as_me:$LINENO: result: $MSGMERGE" >&5
28424 $as_echo "$MSGMERGE" >&6; }
28425 else
28426   { $as_echo "$as_me:$LINENO: result: no" >&5
28427 $as_echo "no" >&6; }
28428 fi
28429
28430
28431   test -n "$MSGMERGE" && break
28432 done
28433
28434   for ac_prog in xgettext
28435 do
28436   # Extract the first word of "$ac_prog", so it can be a program name with args.
28437 set dummy $ac_prog; ac_word=$2
28438 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28439 $as_echo_n "checking for $ac_word... " >&6; }
28440 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
28441   $as_echo_n "(cached) " >&6
28442 else
28443   if test -n "$XGETTEXT"; then
28444   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
28445 else
28446 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28447 for as_dir in $PATH
28448 do
28449   IFS=$as_save_IFS
28450   test -z "$as_dir" && as_dir=.
28451   for ac_exec_ext in '' $ac_executable_extensions; do
28452   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28453     ac_cv_prog_XGETTEXT="$ac_prog"
28454     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28455     break 2
28456   fi
28457 done
28458 done
28459 IFS=$as_save_IFS
28460
28461 fi
28462 fi
28463 XGETTEXT=$ac_cv_prog_XGETTEXT
28464 if test -n "$XGETTEXT"; then
28465   { $as_echo "$as_me:$LINENO: result: $XGETTEXT" >&5
28466 $as_echo "$XGETTEXT" >&6; }
28467 else
28468   { $as_echo "$as_me:$LINENO: result: no" >&5
28469 $as_echo "no" >&6; }
28470 fi
28471
28472
28473   test -n "$XGETTEXT" && break
28474 done
28475
28476
28477 fi
28478
28479 # Check for Tcl configuration script tclConfig.sh
28480 if test "$with_tcl" = yes; then
28481     for ac_prog in tclsh tcl tclsh8.5 tclsh85 tclsh8.4 tclsh84 tclsh8.3 tclsh83
28482 do
28483   # Extract the first word of "$ac_prog", so it can be a program name with args.
28484 set dummy $ac_prog; ac_word=$2
28485 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28486 $as_echo_n "checking for $ac_word... " >&6; }
28487 if test "${ac_cv_path_TCLSH+set}" = set; then
28488   $as_echo_n "(cached) " >&6
28489 else
28490   case $TCLSH in
28491   [\\/]* | ?:[\\/]*)
28492   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
28493   ;;
28494   *)
28495   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28496 for as_dir in $PATH
28497 do
28498   IFS=$as_save_IFS
28499   test -z "$as_dir" && as_dir=.
28500   for ac_exec_ext in '' $ac_executable_extensions; do
28501   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28502     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
28503     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28504     break 2
28505   fi
28506 done
28507 done
28508 IFS=$as_save_IFS
28509
28510   ;;
28511 esac
28512 fi
28513 TCLSH=$ac_cv_path_TCLSH
28514 if test -n "$TCLSH"; then
28515   { $as_echo "$as_me:$LINENO: result: $TCLSH" >&5
28516 $as_echo "$TCLSH" >&6; }
28517 else
28518   { $as_echo "$as_me:$LINENO: result: no" >&5
28519 $as_echo "no" >&6; }
28520 fi
28521
28522
28523   test -n "$TCLSH" && break
28524 done
28525
28526 if test x"$TCLSH" = x""; then
28527   { { $as_echo "$as_me:$LINENO: error: Tcl shell not found" >&5
28528 $as_echo "$as_me: error: Tcl shell not found" >&2;}
28529    { (exit 1); exit 1; }; }
28530 fi
28531
28532 { $as_echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
28533 $as_echo_n "checking for tclConfig.sh... " >&6; }
28534 # Let user override test
28535 if test -z "$TCL_CONFIG_SH"; then
28536     pgac_test_dirs="$with_tclconfig"
28537
28538     set X $pgac_test_dirs; shift
28539     if test $# -eq 0; then
28540         test -z "$TCLSH" && { { $as_echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
28541 $as_echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
28542    { (exit 1); exit 1; }; }
28543         set X `echo 'puts $auto_path' | $TCLSH`; shift
28544     fi
28545
28546     for pgac_dir do
28547         if test -r "$pgac_dir/tclConfig.sh"; then
28548             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
28549             break
28550         fi
28551     done
28552 fi
28553
28554 if test -z "$TCL_CONFIG_SH"; then
28555     { $as_echo "$as_me:$LINENO: result: no" >&5
28556 $as_echo "no" >&6; }
28557     { { $as_echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
28558 $as_echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
28559    { (exit 1); exit 1; }; }
28560 else
28561     { $as_echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
28562 $as_echo "$TCL_CONFIG_SH" >&6; }
28563 fi
28564
28565
28566
28567     . "$TCL_CONFIG_SH"
28568 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
28569 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
28570 eval TCL_LIBS=\"$TCL_LIBS\"
28571 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
28572 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
28573
28574         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
28575     ac_save_CPPFLAGS=$CPPFLAGS
28576     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
28577     if test "${ac_cv_header_tcl_h+set}" = set; then
28578   { $as_echo "$as_me:$LINENO: checking for tcl.h" >&5
28579 $as_echo_n "checking for tcl.h... " >&6; }
28580 if test "${ac_cv_header_tcl_h+set}" = set; then
28581   $as_echo_n "(cached) " >&6
28582 fi
28583 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
28584 $as_echo "$ac_cv_header_tcl_h" >&6; }
28585 else
28586   # Is the header compilable?
28587 { $as_echo "$as_me:$LINENO: checking tcl.h usability" >&5
28588 $as_echo_n "checking tcl.h usability... " >&6; }
28589 cat >conftest.$ac_ext <<_ACEOF
28590 /* confdefs.h.  */
28591 _ACEOF
28592 cat confdefs.h >>conftest.$ac_ext
28593 cat >>conftest.$ac_ext <<_ACEOF
28594 /* end confdefs.h.  */
28595 $ac_includes_default
28596 #include <tcl.h>
28597 _ACEOF
28598 rm -f conftest.$ac_objext
28599 if { (ac_try="$ac_compile"
28600 case "(($ac_try" in
28601   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28602   *) ac_try_echo=$ac_try;;
28603 esac
28604 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28605 $as_echo "$ac_try_echo") >&5
28606   (eval "$ac_compile") 2>conftest.er1
28607   ac_status=$?
28608   grep -v '^ *+' conftest.er1 >conftest.err
28609   rm -f conftest.er1
28610   cat conftest.err >&5
28611   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28612   (exit $ac_status); } && {
28613          test -z "$ac_c_werror_flag" ||
28614          test ! -s conftest.err
28615        } && test -s conftest.$ac_objext; then
28616   ac_header_compiler=yes
28617 else
28618   $as_echo "$as_me: failed program was:" >&5
28619 sed 's/^/| /' conftest.$ac_ext >&5
28620
28621         ac_header_compiler=no
28622 fi
28623
28624 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28625 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28626 $as_echo "$ac_header_compiler" >&6; }
28627
28628 # Is the header present?
28629 { $as_echo "$as_me:$LINENO: checking tcl.h presence" >&5
28630 $as_echo_n "checking tcl.h presence... " >&6; }
28631 cat >conftest.$ac_ext <<_ACEOF
28632 /* confdefs.h.  */
28633 _ACEOF
28634 cat confdefs.h >>conftest.$ac_ext
28635 cat >>conftest.$ac_ext <<_ACEOF
28636 /* end confdefs.h.  */
28637 #include <tcl.h>
28638 _ACEOF
28639 if { (ac_try="$ac_cpp conftest.$ac_ext"
28640 case "(($ac_try" in
28641   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28642   *) ac_try_echo=$ac_try;;
28643 esac
28644 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28645 $as_echo "$ac_try_echo") >&5
28646   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
28647   ac_status=$?
28648   grep -v '^ *+' conftest.er1 >conftest.err
28649   rm -f conftest.er1
28650   cat conftest.err >&5
28651   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28652   (exit $ac_status); } >/dev/null && {
28653          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
28654          test ! -s conftest.err
28655        }; then
28656   ac_header_preproc=yes
28657 else
28658   $as_echo "$as_me: failed program was:" >&5
28659 sed 's/^/| /' conftest.$ac_ext >&5
28660
28661   ac_header_preproc=no
28662 fi
28663
28664 rm -f conftest.err conftest.$ac_ext
28665 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28666 $as_echo "$ac_header_preproc" >&6; }
28667
28668 # So?  What about this header?
28669 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
28670   yes:no: )
28671     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
28672 $as_echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
28673     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the compiler's result" >&5
28674 $as_echo "$as_me: WARNING: tcl.h: proceeding with the compiler's result" >&2;}
28675     ac_header_preproc=yes
28676     ;;
28677   no:yes:* )
28678     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
28679 $as_echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
28680     { $as_echo "$as_me:$LINENO: WARNING: tcl.h:     check for missing prerequisite headers?" >&5
28681 $as_echo "$as_me: WARNING: tcl.h:     check for missing prerequisite headers?" >&2;}
28682     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: see the Autoconf documentation" >&5
28683 $as_echo "$as_me: WARNING: tcl.h: see the Autoconf documentation" >&2;}
28684     { $as_echo "$as_me:$LINENO: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&5
28685 $as_echo "$as_me: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
28686     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
28687 $as_echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;}
28688     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: in the future, the compiler will take precedence" >&5
28689 $as_echo "$as_me: WARNING: tcl.h: in the future, the compiler will take precedence" >&2;}
28690     ( cat <<\_ASBOX
28691 ## ---------------------------------------- ##
28692 ## Report this to pgsql-bugs@postgresql.org ##
28693 ## ---------------------------------------- ##
28694 _ASBOX
28695      ) | sed "s/^/$as_me: WARNING:     /" >&2
28696     ;;
28697 esac
28698 { $as_echo "$as_me:$LINENO: checking for tcl.h" >&5
28699 $as_echo_n "checking for tcl.h... " >&6; }
28700 if test "${ac_cv_header_tcl_h+set}" = set; then
28701   $as_echo_n "(cached) " >&6
28702 else
28703   ac_cv_header_tcl_h=$ac_header_preproc
28704 fi
28705 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
28706 $as_echo "$ac_cv_header_tcl_h" >&6; }
28707
28708 fi
28709 if test "x$ac_cv_header_tcl_h" = x""yes; then
28710   :
28711 else
28712   { { $as_echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
28713 $as_echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
28714    { (exit 1); exit 1; }; }
28715 fi
28716
28717
28718     CPPFLAGS=$ac_save_CPPFLAGS
28719 fi
28720
28721 #
28722 # Check for DocBook and tools
28723 #
28724 for ac_prog in onsgmls nsgmls
28725 do
28726   # Extract the first word of "$ac_prog", so it can be a program name with args.
28727 set dummy $ac_prog; ac_word=$2
28728 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28729 $as_echo_n "checking for $ac_word... " >&6; }
28730 if test "${ac_cv_prog_NSGMLS+set}" = set; then
28731   $as_echo_n "(cached) " >&6
28732 else
28733   if test -n "$NSGMLS"; then
28734   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
28735 else
28736 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28737 for as_dir in $PATH
28738 do
28739   IFS=$as_save_IFS
28740   test -z "$as_dir" && as_dir=.
28741   for ac_exec_ext in '' $ac_executable_extensions; do
28742   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28743     ac_cv_prog_NSGMLS="$ac_prog"
28744     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28745     break 2
28746   fi
28747 done
28748 done
28749 IFS=$as_save_IFS
28750
28751 fi
28752 fi
28753 NSGMLS=$ac_cv_prog_NSGMLS
28754 if test -n "$NSGMLS"; then
28755   { $as_echo "$as_me:$LINENO: result: $NSGMLS" >&5
28756 $as_echo "$NSGMLS" >&6; }
28757 else
28758   { $as_echo "$as_me:$LINENO: result: no" >&5
28759 $as_echo "no" >&6; }
28760 fi
28761
28762
28763   test -n "$NSGMLS" && break
28764 done
28765
28766 for ac_prog in openjade jade
28767 do
28768   # Extract the first word of "$ac_prog", so it can be a program name with args.
28769 set dummy $ac_prog; ac_word=$2
28770 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28771 $as_echo_n "checking for $ac_word... " >&6; }
28772 if test "${ac_cv_prog_JADE+set}" = set; then
28773   $as_echo_n "(cached) " >&6
28774 else
28775   if test -n "$JADE"; then
28776   ac_cv_prog_JADE="$JADE" # Let the user override the test.
28777 else
28778 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28779 for as_dir in $PATH
28780 do
28781   IFS=$as_save_IFS
28782   test -z "$as_dir" && as_dir=.
28783   for ac_exec_ext in '' $ac_executable_extensions; do
28784   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28785     ac_cv_prog_JADE="$ac_prog"
28786     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28787     break 2
28788   fi
28789 done
28790 done
28791 IFS=$as_save_IFS
28792
28793 fi
28794 fi
28795 JADE=$ac_cv_prog_JADE
28796 if test -n "$JADE"; then
28797   { $as_echo "$as_me:$LINENO: result: $JADE" >&5
28798 $as_echo "$JADE" >&6; }
28799 else
28800   { $as_echo "$as_me:$LINENO: result: no" >&5
28801 $as_echo "no" >&6; }
28802 fi
28803
28804
28805   test -n "$JADE" && break
28806 done
28807
28808
28809 { $as_echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
28810 $as_echo_n "checking for DocBook V4.2... " >&6; }
28811 if test "${pgac_cv_check_docbook+set}" = set; then
28812   $as_echo_n "(cached) " >&6
28813 else
28814   cat >conftest.sgml <<EOF
28815 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
28816 <book>
28817  <title>test</title>
28818  <chapter>
28819   <title>random</title>
28820    <sect1>
28821     <title>testsect</title>
28822     <para>text</para>
28823   </sect1>
28824  </chapter>
28825 </book>
28826 EOF
28827
28828 pgac_cv_check_docbook=no
28829
28830 if test -n "$NSGMLS"; then
28831   $NSGMLS -s conftest.sgml 1>&5 2>&1
28832   if test $? -eq 0; then
28833     pgac_cv_check_docbook=yes
28834   fi
28835 fi
28836 rm -f conftest.sgml
28837 fi
28838 { $as_echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
28839 $as_echo "$pgac_cv_check_docbook" >&6; }
28840
28841 have_docbook=$pgac_cv_check_docbook
28842
28843
28844 { $as_echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
28845 $as_echo_n "checking for DocBook stylesheets... " >&6; }
28846 if test "${pgac_cv_path_stylesheets+set}" = set; then
28847   $as_echo_n "(cached) " >&6
28848 else
28849   if test -n "$DOCBOOKSTYLE"; then
28850   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
28851 else
28852   for pgac_prefix in /usr /usr/local /opt /sw; do
28853     for pgac_infix in share lib; do
28854       for pgac_postfix in \
28855         sgml/stylesheets/nwalsh-modular \
28856         sgml/stylesheets/docbook \
28857         sgml/stylesheets/dsssl/docbook \
28858         sgml/docbook-dsssl \
28859         sgml/docbook/dsssl/modular \
28860         sgml/docbook/stylesheet/dsssl/modular \
28861         sgml/docbook/dsssl-stylesheets \
28862         sgml/dsssl/docbook-dsssl-nwalsh
28863       do
28864         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
28865         if test -r "$pgac_candidate/html/docbook.dsl" \
28866            && test -r "$pgac_candidate/print/docbook.dsl"
28867         then
28868           pgac_cv_path_stylesheets=$pgac_candidate
28869           break 3
28870         fi
28871       done
28872     done
28873   done
28874 fi
28875 fi
28876
28877 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
28878
28879 if test -n "$DOCBOOKSTYLE"; then
28880   { $as_echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
28881 $as_echo "$DOCBOOKSTYLE" >&6; }
28882 else
28883   { $as_echo "$as_me:$LINENO: result: no" >&5
28884 $as_echo "no" >&6; }
28885 fi
28886 if test -n "$DOCBOOKSTYLE"; then
28887   for ac_prog in collateindex.pl
28888 do
28889   # Extract the first word of "$ac_prog", so it can be a program name with args.
28890 set dummy $ac_prog; ac_word=$2
28891 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28892 $as_echo_n "checking for $ac_word... " >&6; }
28893 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
28894   $as_echo_n "(cached) " >&6
28895 else
28896   case $COLLATEINDEX in
28897   [\\/]* | ?:[\\/]*)
28898   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
28899   ;;
28900   *)
28901   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28902 for as_dir in $DOCBOOKSTYLE/bin $PATH
28903 do
28904   IFS=$as_save_IFS
28905   test -z "$as_dir" && as_dir=.
28906   for ac_exec_ext in '' $ac_executable_extensions; do
28907   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28908     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
28909     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28910     break 2
28911   fi
28912 done
28913 done
28914 IFS=$as_save_IFS
28915
28916   ;;
28917 esac
28918 fi
28919 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
28920 if test -n "$COLLATEINDEX"; then
28921   { $as_echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
28922 $as_echo "$COLLATEINDEX" >&6; }
28923 else
28924   { $as_echo "$as_me:$LINENO: result: no" >&5
28925 $as_echo "no" >&6; }
28926 fi
28927
28928
28929   test -n "$COLLATEINDEX" && break
28930 done
28931
28932 else
28933   for ac_prog in collateindex.pl
28934 do
28935   # Extract the first word of "$ac_prog", so it can be a program name with args.
28936 set dummy $ac_prog; ac_word=$2
28937 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28938 $as_echo_n "checking for $ac_word... " >&6; }
28939 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
28940   $as_echo_n "(cached) " >&6
28941 else
28942   case $COLLATEINDEX in
28943   [\\/]* | ?:[\\/]*)
28944   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
28945   ;;
28946   *)
28947   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28948 for as_dir in $PATH
28949 do
28950   IFS=$as_save_IFS
28951   test -z "$as_dir" && as_dir=.
28952   for ac_exec_ext in '' $ac_executable_extensions; do
28953   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28954     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
28955     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28956     break 2
28957   fi
28958 done
28959 done
28960 IFS=$as_save_IFS
28961
28962   ;;
28963 esac
28964 fi
28965 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
28966 if test -n "$COLLATEINDEX"; then
28967   { $as_echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
28968 $as_echo "$COLLATEINDEX" >&6; }
28969 else
28970   { $as_echo "$as_me:$LINENO: result: no" >&5
28971 $as_echo "no" >&6; }
28972 fi
28973
28974
28975   test -n "$COLLATEINDEX" && break
28976 done
28977
28978 fi
28979 for ac_prog in xsltproc
28980 do
28981   # Extract the first word of "$ac_prog", so it can be a program name with args.
28982 set dummy $ac_prog; ac_word=$2
28983 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28984 $as_echo_n "checking for $ac_word... " >&6; }
28985 if test "${ac_cv_prog_XSLTPROC+set}" = set; then
28986   $as_echo_n "(cached) " >&6
28987 else
28988   if test -n "$XSLTPROC"; then
28989   ac_cv_prog_XSLTPROC="$XSLTPROC" # Let the user override the test.
28990 else
28991 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28992 for as_dir in $PATH
28993 do
28994   IFS=$as_save_IFS
28995   test -z "$as_dir" && as_dir=.
28996   for ac_exec_ext in '' $ac_executable_extensions; do
28997   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28998     ac_cv_prog_XSLTPROC="$ac_prog"
28999     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29000     break 2
29001   fi
29002 done
29003 done
29004 IFS=$as_save_IFS
29005
29006 fi
29007 fi
29008 XSLTPROC=$ac_cv_prog_XSLTPROC
29009 if test -n "$XSLTPROC"; then
29010   { $as_echo "$as_me:$LINENO: result: $XSLTPROC" >&5
29011 $as_echo "$XSLTPROC" >&6; }
29012 else
29013   { $as_echo "$as_me:$LINENO: result: no" >&5
29014 $as_echo "no" >&6; }
29015 fi
29016
29017
29018   test -n "$XSLTPROC" && break
29019 done
29020
29021 for ac_prog in osx sgml2xml sx
29022 do
29023   # Extract the first word of "$ac_prog", so it can be a program name with args.
29024 set dummy $ac_prog; ac_word=$2
29025 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
29026 $as_echo_n "checking for $ac_word... " >&6; }
29027 if test "${ac_cv_prog_OSX+set}" = set; then
29028   $as_echo_n "(cached) " >&6
29029 else
29030   if test -n "$OSX"; then
29031   ac_cv_prog_OSX="$OSX" # Let the user override the test.
29032 else
29033 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29034 for as_dir in $PATH
29035 do
29036   IFS=$as_save_IFS
29037   test -z "$as_dir" && as_dir=.
29038   for ac_exec_ext in '' $ac_executable_extensions; do
29039   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
29040     ac_cv_prog_OSX="$ac_prog"
29041     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
29042     break 2
29043   fi
29044 done
29045 done
29046 IFS=$as_save_IFS
29047
29048 fi
29049 fi
29050 OSX=$ac_cv_prog_OSX
29051 if test -n "$OSX"; then
29052   { $as_echo "$as_me:$LINENO: result: $OSX" >&5
29053 $as_echo "$OSX" >&6; }
29054 else
29055   { $as_echo "$as_me:$LINENO: result: no" >&5
29056 $as_echo "no" >&6; }
29057 fi
29058
29059
29060   test -n "$OSX" && break
29061 done
29062
29063
29064 # Thread testing
29065
29066 # We have to run the thread test near the end so we have all our symbols
29067 # defined.  Cross compiling throws a warning.
29068 #
29069 if test "$enable_thread_safety" = yes; then
29070 if test "$PORTNAME" != "win32"
29071 then
29072 { $as_echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
29073 $as_echo_n "checking thread safety of required library functions... " >&6; }
29074
29075 _CFLAGS="$CFLAGS"
29076 _LIBS="$LIBS"
29077 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
29078 LIBS="$LIBS $PTHREAD_LIBS"
29079 if test "$cross_compiling" = yes; then
29080   { $as_echo "$as_me:$LINENO: result: maybe" >&5
29081 $as_echo "maybe" >&6; }
29082   { $as_echo "$as_me:$LINENO: WARNING:
29083 *** Skipping thread test program because of cross-compile build.
29084 *** Run the program in src/test/thread on the target machine.
29085 " >&5
29086 $as_echo "$as_me: WARNING:
29087 *** Skipping thread test program because of cross-compile build.
29088 *** Run the program in src/test/thread on the target machine.
29089 " >&2;}
29090 else
29091   cat >conftest.$ac_ext <<_ACEOF
29092 /* confdefs.h.  */
29093 _ACEOF
29094 cat confdefs.h >>conftest.$ac_ext
29095 cat >>conftest.$ac_ext <<_ACEOF
29096 /* end confdefs.h.  */
29097 #include "$srcdir/src/test/thread/thread_test.c"
29098 _ACEOF
29099 rm -f conftest$ac_exeext
29100 if { (ac_try="$ac_link"
29101 case "(($ac_try" in
29102   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29103   *) ac_try_echo=$ac_try;;
29104 esac
29105 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29106 $as_echo "$ac_try_echo") >&5
29107   (eval "$ac_link") 2>&5
29108   ac_status=$?
29109   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29110   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29111   { (case "(($ac_try" in
29112   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29113   *) ac_try_echo=$ac_try;;
29114 esac
29115 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29116 $as_echo "$ac_try_echo") >&5
29117   (eval "$ac_try") 2>&5
29118   ac_status=$?
29119   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29120   (exit $ac_status); }; }; then
29121   { $as_echo "$as_me:$LINENO: result: yes" >&5
29122 $as_echo "yes" >&6; }
29123 else
29124   $as_echo "$as_me: program exited with status $ac_status" >&5
29125 $as_echo "$as_me: failed program was:" >&5
29126 sed 's/^/| /' conftest.$ac_ext >&5
29127
29128 ( exit $ac_status )
29129 { $as_echo "$as_me:$LINENO: result: no" >&5
29130 $as_echo "no" >&6; }
29131   { { $as_echo "$as_me:$LINENO: error: thread test program failed
29132 This platform is not thread-safe.  Check the file 'config.log' or compile
29133 and run src/test/thread/thread_test for the exact reason.
29134 Use --disable-thread-safety to disable thread safety." >&5
29135 $as_echo "$as_me: error: thread test program failed
29136 This platform is not thread-safe.  Check the file 'config.log' or compile
29137 and run src/test/thread/thread_test for the exact reason.
29138 Use --disable-thread-safety to disable thread safety." >&2;}
29139    { (exit 1); exit 1; }; }
29140 fi
29141 rm -rf conftest.dSYM
29142 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29143 fi
29144
29145
29146 CFLAGS="$_CFLAGS"
29147 LIBS="$_LIBS"
29148 else
29149 { $as_echo "$as_me:$LINENO: WARNING: *** skipping thread test on Win32" >&5
29150 $as_echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
29151 fi
29152 fi
29153
29154 # If compiler will take -Wl,--as-needed (or various platform-specific
29155 # spellings thereof) then add that to LDFLAGS.  This is much easier than
29156 # trying to filter LIBS to the minimum for each executable.
29157 # On (at least) some Red-Hat-derived systems, this switch breaks linking to
29158 # libreadline; therefore we postpone testing it until we know what library
29159 # dependencies readline has.  The test code will try to link with $LIBS.
29160 if test "$with_readline" = yes; then
29161   link_test_func=readline
29162 else
29163   link_test_func=exit
29164 fi
29165
29166 if test "$PORTNAME" = "darwin"; then
29167   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,-dead_strip_dylibs" >&5
29168 $as_echo_n "checking whether $CC supports -Wl,-dead_strip_dylibs... " >&6; }
29169 if test "${pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs+set}" = set; then
29170   $as_echo_n "(cached) " >&6
29171 else
29172   pgac_save_LDFLAGS=$LDFLAGS
29173 LDFLAGS="$pgac_save_LDFLAGS -Wl,-dead_strip_dylibs"
29174 if test "$cross_compiling" = yes; then
29175   pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs="assuming no"
29176 else
29177   cat >conftest.$ac_ext <<_ACEOF
29178 /* confdefs.h.  */
29179 _ACEOF
29180 cat confdefs.h >>conftest.$ac_ext
29181 cat >>conftest.$ac_ext <<_ACEOF
29182 /* end confdefs.h.  */
29183 extern void $link_test_func (); void (*fptr) () = $link_test_func;
29184 int
29185 main ()
29186 {
29187
29188   ;
29189   return 0;
29190 }
29191 _ACEOF
29192 rm -f conftest$ac_exeext
29193 if { (ac_try="$ac_link"
29194 case "(($ac_try" in
29195   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29196   *) ac_try_echo=$ac_try;;
29197 esac
29198 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29199 $as_echo "$ac_try_echo") >&5
29200   (eval "$ac_link") 2>&5
29201   ac_status=$?
29202   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29203   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29204   { (case "(($ac_try" in
29205   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29206   *) ac_try_echo=$ac_try;;
29207 esac
29208 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29209 $as_echo "$ac_try_echo") >&5
29210   (eval "$ac_try") 2>&5
29211   ac_status=$?
29212   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29213   (exit $ac_status); }; }; then
29214   pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=yes
29215 else
29216   $as_echo "$as_me: program exited with status $ac_status" >&5
29217 $as_echo "$as_me: failed program was:" >&5
29218 sed 's/^/| /' conftest.$ac_ext >&5
29219
29220 ( exit $ac_status )
29221 pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=no
29222 fi
29223 rm -rf conftest.dSYM
29224 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29225 fi
29226
29227
29228 LDFLAGS="$pgac_save_LDFLAGS"
29229 fi
29230 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&5
29231 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&6; }
29232 if test x"$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" = x"yes"; then
29233   LDFLAGS="$LDFLAGS -Wl,-dead_strip_dylibs"
29234 fi
29235
29236 elif test "$PORTNAME" = "openbsd"; then
29237   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,-Bdynamic" >&5
29238 $as_echo_n "checking whether $CC supports -Wl,-Bdynamic... " >&6; }
29239 if test "${pgac_cv_prog_cc_ldflags__Wl__Bdynamic+set}" = set; then
29240   $as_echo_n "(cached) " >&6
29241 else
29242   pgac_save_LDFLAGS=$LDFLAGS
29243 LDFLAGS="$pgac_save_LDFLAGS -Wl,-Bdynamic"
29244 if test "$cross_compiling" = yes; then
29245   pgac_cv_prog_cc_ldflags__Wl__Bdynamic="assuming no"
29246 else
29247   cat >conftest.$ac_ext <<_ACEOF
29248 /* confdefs.h.  */
29249 _ACEOF
29250 cat confdefs.h >>conftest.$ac_ext
29251 cat >>conftest.$ac_ext <<_ACEOF
29252 /* end confdefs.h.  */
29253 extern void $link_test_func (); void (*fptr) () = $link_test_func;
29254 int
29255 main ()
29256 {
29257
29258   ;
29259   return 0;
29260 }
29261 _ACEOF
29262 rm -f conftest$ac_exeext
29263 if { (ac_try="$ac_link"
29264 case "(($ac_try" in
29265   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29266   *) ac_try_echo=$ac_try;;
29267 esac
29268 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29269 $as_echo "$ac_try_echo") >&5
29270   (eval "$ac_link") 2>&5
29271   ac_status=$?
29272   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29273   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29274   { (case "(($ac_try" in
29275   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29276   *) ac_try_echo=$ac_try;;
29277 esac
29278 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29279 $as_echo "$ac_try_echo") >&5
29280   (eval "$ac_try") 2>&5
29281   ac_status=$?
29282   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29283   (exit $ac_status); }; }; then
29284   pgac_cv_prog_cc_ldflags__Wl__Bdynamic=yes
29285 else
29286   $as_echo "$as_me: program exited with status $ac_status" >&5
29287 $as_echo "$as_me: failed program was:" >&5
29288 sed 's/^/| /' conftest.$ac_ext >&5
29289
29290 ( exit $ac_status )
29291 pgac_cv_prog_cc_ldflags__Wl__Bdynamic=no
29292 fi
29293 rm -rf conftest.dSYM
29294 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29295 fi
29296
29297
29298 LDFLAGS="$pgac_save_LDFLAGS"
29299 fi
29300 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&5
29301 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&6; }
29302 if test x"$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" = x"yes"; then
29303   LDFLAGS="$LDFLAGS -Wl,-Bdynamic"
29304 fi
29305
29306 else
29307   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,--as-needed" >&5
29308 $as_echo_n "checking whether $CC supports -Wl,--as-needed... " >&6; }
29309 if test "${pgac_cv_prog_cc_ldflags__Wl___as_needed+set}" = set; then
29310   $as_echo_n "(cached) " >&6
29311 else
29312   pgac_save_LDFLAGS=$LDFLAGS
29313 LDFLAGS="$pgac_save_LDFLAGS -Wl,--as-needed"
29314 if test "$cross_compiling" = yes; then
29315   pgac_cv_prog_cc_ldflags__Wl___as_needed="assuming no"
29316 else
29317   cat >conftest.$ac_ext <<_ACEOF
29318 /* confdefs.h.  */
29319 _ACEOF
29320 cat confdefs.h >>conftest.$ac_ext
29321 cat >>conftest.$ac_ext <<_ACEOF
29322 /* end confdefs.h.  */
29323 extern void $link_test_func (); void (*fptr) () = $link_test_func;
29324 int
29325 main ()
29326 {
29327
29328   ;
29329   return 0;
29330 }
29331 _ACEOF
29332 rm -f conftest$ac_exeext
29333 if { (ac_try="$ac_link"
29334 case "(($ac_try" in
29335   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29336   *) ac_try_echo=$ac_try;;
29337 esac
29338 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29339 $as_echo "$ac_try_echo") >&5
29340   (eval "$ac_link") 2>&5
29341   ac_status=$?
29342   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29343   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29344   { (case "(($ac_try" in
29345   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29346   *) ac_try_echo=$ac_try;;
29347 esac
29348 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29349 $as_echo "$ac_try_echo") >&5
29350   (eval "$ac_try") 2>&5
29351   ac_status=$?
29352   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29353   (exit $ac_status); }; }; then
29354   pgac_cv_prog_cc_ldflags__Wl___as_needed=yes
29355 else
29356   $as_echo "$as_me: program exited with status $ac_status" >&5
29357 $as_echo "$as_me: failed program was:" >&5
29358 sed 's/^/| /' conftest.$ac_ext >&5
29359
29360 ( exit $ac_status )
29361 pgac_cv_prog_cc_ldflags__Wl___as_needed=no
29362 fi
29363 rm -rf conftest.dSYM
29364 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29365 fi
29366
29367
29368 LDFLAGS="$pgac_save_LDFLAGS"
29369 fi
29370 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl___as_needed" >&5
29371 $as_echo "$pgac_cv_prog_cc_ldflags__Wl___as_needed" >&6; }
29372 if test x"$pgac_cv_prog_cc_ldflags__Wl___as_needed" = x"yes"; then
29373   LDFLAGS="$LDFLAGS -Wl,--as-needed"
29374 fi
29375
29376 fi
29377
29378
29379 # Begin output steps
29380
29381 { $as_echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
29382 $as_echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
29383 { $as_echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
29384 $as_echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
29385 { $as_echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
29386 $as_echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
29387
29388 # Create compiler version string
29389 if test x"$GCC" = x"yes" ; then
29390   cc_string="GCC `${CC} --version | sed q`"
29391 elif test x"$SUN_STUDIO_CC" = x"yes" ; then
29392   cc_string=`${CC} -V 2>&1 | sed q`
29393 else
29394   cc_string=$CC
29395 fi
29396
29397
29398 cat >>confdefs.h <<_ACEOF
29399 #define PG_VERSION_STR "PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string, `expr $ac_cv_sizeof_void_p \* 8`-bit"
29400 _ACEOF
29401
29402
29403 # Supply a numeric version string for use by 3rd party add-ons
29404 # awk -F is a regex on some platforms, and not on others, so make "." a tab
29405 PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/[A-Za-z].*$//' |
29406 tr '.' '        ' |
29407 $AWK '{printf "%d%02d%02d", $1, $2, (NF >= 3) ? $3 : 0}'`"
29408
29409 cat >>confdefs.h <<_ACEOF
29410 #define PG_VERSION_NUM $PG_VERSION_NUM
29411 _ACEOF
29412
29413
29414
29415 # prepare build tree if outside source tree
29416 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
29417 # Note 2: /bin/pwd might be better than shell's built-in at getting
29418 #         a symlink-free name.
29419 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
29420   vpath_build=no
29421 else
29422   vpath_build=yes
29423   if test "$no_create" != yes; then
29424     $as_echo_n "preparing build tree... " >&6
29425     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
29426     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
29427       || { { $as_echo "$as_me:$LINENO: error: failed" >&5
29428 $as_echo "$as_me: error: failed" >&2;}
29429    { (exit 1); exit 1; }; }
29430     { $as_echo "$as_me:$LINENO: result: done" >&5
29431 $as_echo "done" >&6; }
29432   fi
29433 fi
29434
29435
29436
29437 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
29438
29439
29440 ac_config_links="$ac_config_links src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION} src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION} src/backend/port/pg_latch.c:${LATCH_IMPLEMENTATION} src/include/dynloader.h:src/backend/port/dynloader/${template}.h src/include/pg_config_os.h:src/include/port/${template}.h src/Makefile.port:src/makefiles/Makefile.${template}"
29441
29442
29443 if test "$PORTNAME" = "win32"; then
29444 ac_config_commands="$ac_config_commands check_win32_symlinks"
29445
29446 fi
29447
29448 ac_config_headers="$ac_config_headers src/include/pg_config.h"
29449
29450
29451 ac_config_headers="$ac_config_headers src/interfaces/ecpg/include/ecpg_config.h"
29452
29453
29454 cat >confcache <<\_ACEOF
29455 # This file is a shell script that caches the results of configure
29456 # tests run on this system so they can be shared between configure
29457 # scripts and configure runs, see configure's option --config-cache.
29458 # It is not useful on other systems.  If it contains results you don't
29459 # want to keep, you may remove or edit it.
29460 #
29461 # config.status only pays attention to the cache file if you give it
29462 # the --recheck option to rerun configure.
29463 #
29464 # `ac_cv_env_foo' variables (set or unset) will be overridden when
29465 # loading this file, other *unset* `ac_cv_foo' will be assigned the
29466 # following values.
29467
29468 _ACEOF
29469
29470 # The following way of writing the cache mishandles newlines in values,
29471 # but we know of no workaround that is simple, portable, and efficient.
29472 # So, we kill variables containing newlines.
29473 # Ultrix sh set writes to stderr and can't be redirected directly,
29474 # and sets the high bit in the cache file unless we assign to the vars.
29475 (
29476   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
29477     eval ac_val=\$$ac_var
29478     case $ac_val in #(
29479     *${as_nl}*)
29480       case $ac_var in #(
29481       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
29482 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
29483       esac
29484       case $ac_var in #(
29485       _ | IFS | as_nl) ;; #(
29486       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
29487       *) $as_unset $ac_var ;;
29488       esac ;;
29489     esac
29490   done
29491
29492   (set) 2>&1 |
29493     case $as_nl`(ac_space=' '; set) 2>&1` in #(
29494     *${as_nl}ac_space=\ *)
29495       # `set' does not quote correctly, so add quotes (double-quote
29496       # substitution turns \\\\ into \\, and sed turns \\ into \).
29497       sed -n \
29498         "s/'/'\\\\''/g;
29499           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
29500       ;; #(
29501     *)
29502       # `set' quotes correctly as required by POSIX, so do not add quotes.
29503       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
29504       ;;
29505     esac |
29506     sort
29507 ) |
29508   sed '
29509      /^ac_cv_env_/b end
29510      t clear
29511      :clear
29512      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
29513      t end
29514      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
29515      :end' >>confcache
29516 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
29517   if test -w "$cache_file"; then
29518     test "x$cache_file" != "x/dev/null" &&
29519       { $as_echo "$as_me:$LINENO: updating cache $cache_file" >&5
29520 $as_echo "$as_me: updating cache $cache_file" >&6;}
29521     cat confcache >$cache_file
29522   else
29523     { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
29524 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
29525   fi
29526 fi
29527 rm -f confcache
29528
29529 test "x$prefix" = xNONE && prefix=$ac_default_prefix
29530 # Let make expand exec_prefix.
29531 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
29532
29533 DEFS=-DHAVE_CONFIG_H
29534
29535 ac_libobjs=
29536 ac_ltlibobjs=
29537 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
29538   # 1. Remove the extension, and $U if already installed.
29539   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
29540   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
29541   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
29542   #    will be set to the directory where LIBOBJS objects are built.
29543   ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
29544   ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
29545 done
29546 LIBOBJS=$ac_libobjs
29547
29548 LTLIBOBJS=$ac_ltlibobjs
29549
29550
29551
29552
29553 : ${CONFIG_STATUS=./config.status}
29554 ac_write_fail=0
29555 ac_clean_files_save=$ac_clean_files
29556 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
29557 { $as_echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
29558 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
29559 cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29560 #! $SHELL
29561 # Generated by $as_me.
29562 # Run this file to recreate the current configuration.
29563 # Compiler output produced by configure, useful for debugging
29564 # configure, is in config.log if it exists.
29565
29566 debug=false
29567 ac_cs_recheck=false
29568 ac_cs_silent=false
29569 SHELL=\${CONFIG_SHELL-$SHELL}
29570 _ACEOF
29571
29572 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29573 ## --------------------- ##
29574 ## M4sh Initialization.  ##
29575 ## --------------------- ##
29576
29577 # Be more Bourne compatible
29578 DUALCASE=1; export DUALCASE # for MKS sh
29579 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
29580   emulate sh
29581   NULLCMD=:
29582   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
29583   # is contrary to our usage.  Disable this feature.
29584   alias -g '${1+"$@"}'='"$@"'
29585   setopt NO_GLOB_SUBST
29586 else
29587   case `(set -o) 2>/dev/null` in
29588   *posix*) set -o posix ;;
29589 esac
29590
29591 fi
29592
29593
29594
29595
29596 # PATH needs CR
29597 # Avoid depending upon Character Ranges.
29598 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
29599 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
29600 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
29601 as_cr_digits='0123456789'
29602 as_cr_alnum=$as_cr_Letters$as_cr_digits
29603
29604 as_nl='
29605 '
29606 export as_nl
29607 # Printing a long string crashes Solaris 7 /usr/bin/printf.
29608 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
29609 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
29610 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
29611 if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
29612   as_echo='printf %s\n'
29613   as_echo_n='printf %s'
29614 else
29615   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
29616     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
29617     as_echo_n='/usr/ucb/echo -n'
29618   else
29619     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
29620     as_echo_n_body='eval
29621       arg=$1;
29622       case $arg in
29623       *"$as_nl"*)
29624         expr "X$arg" : "X\\(.*\\)$as_nl";
29625         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
29626       esac;
29627       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
29628     '
29629     export as_echo_n_body
29630     as_echo_n='sh -c $as_echo_n_body as_echo'
29631   fi
29632   export as_echo_body
29633   as_echo='sh -c $as_echo_body as_echo'
29634 fi
29635
29636 # The user is always right.
29637 if test "${PATH_SEPARATOR+set}" != set; then
29638   PATH_SEPARATOR=:
29639   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
29640     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
29641       PATH_SEPARATOR=';'
29642   }
29643 fi
29644
29645 # Support unset when possible.
29646 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
29647   as_unset=unset
29648 else
29649   as_unset=false
29650 fi
29651
29652
29653 # IFS
29654 # We need space, tab and new line, in precisely that order.  Quoting is
29655 # there to prevent editors from complaining about space-tab.
29656 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
29657 # splitting by setting IFS to empty value.)
29658 IFS=" ""        $as_nl"
29659
29660 # Find who we are.  Look in the path if we contain no directory separator.
29661 case $0 in
29662   *[\\/]* ) as_myself=$0 ;;
29663   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29664 for as_dir in $PATH
29665 do
29666   IFS=$as_save_IFS
29667   test -z "$as_dir" && as_dir=.
29668   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
29669 done
29670 IFS=$as_save_IFS
29671
29672      ;;
29673 esac
29674 # We did not find ourselves, most probably we were run as `sh COMMAND'
29675 # in which case we are not to be found in the path.
29676 if test "x$as_myself" = x; then
29677   as_myself=$0
29678 fi
29679 if test ! -f "$as_myself"; then
29680   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
29681   { (exit 1); exit 1; }
29682 fi
29683
29684 # Work around bugs in pre-3.0 UWIN ksh.
29685 for as_var in ENV MAIL MAILPATH
29686 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
29687 done
29688 PS1='$ '
29689 PS2='> '
29690 PS4='+ '
29691
29692 # NLS nuisances.
29693 LC_ALL=C
29694 export LC_ALL
29695 LANGUAGE=C
29696 export LANGUAGE
29697
29698 # Required to use basename.
29699 if expr a : '\(a\)' >/dev/null 2>&1 &&
29700    test "X`expr 00001 : '.*\(...\)'`" = X001; then
29701   as_expr=expr
29702 else
29703   as_expr=false
29704 fi
29705
29706 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
29707   as_basename=basename
29708 else
29709   as_basename=false
29710 fi
29711
29712
29713 # Name of the executable.
29714 as_me=`$as_basename -- "$0" ||
29715 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
29716          X"$0" : 'X\(//\)$' \| \
29717          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
29718 $as_echo X/"$0" |
29719     sed '/^.*\/\([^/][^/]*\)\/*$/{
29720             s//\1/
29721             q
29722           }
29723           /^X\/\(\/\/\)$/{
29724             s//\1/
29725             q
29726           }
29727           /^X\/\(\/\).*/{
29728             s//\1/
29729             q
29730           }
29731           s/.*/./; q'`
29732
29733 # CDPATH.
29734 $as_unset CDPATH
29735
29736
29737
29738   as_lineno_1=$LINENO
29739   as_lineno_2=$LINENO
29740   test "x$as_lineno_1" != "x$as_lineno_2" &&
29741   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
29742
29743   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
29744   # uniformly replaced by the line number.  The first 'sed' inserts a
29745   # line-number line after each line using $LINENO; the second 'sed'
29746   # does the real work.  The second script uses 'N' to pair each
29747   # line-number line with the line containing $LINENO, and appends
29748   # trailing '-' during substitution so that $LINENO is not a special
29749   # case at line end.
29750   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
29751   # scripts with optimization help from Paolo Bonzini.  Blame Lee
29752   # E. McMahon (1931-1989) for sed's syntax.  :-)
29753   sed -n '
29754     p
29755     /[$]LINENO/=
29756   ' <$as_myself |
29757     sed '
29758       s/[$]LINENO.*/&-/
29759       t lineno
29760       b
29761       :lineno
29762       N
29763       :loop
29764       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
29765       t loop
29766       s/-\n.*//
29767     ' >$as_me.lineno &&
29768   chmod +x "$as_me.lineno" ||
29769     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
29770    { (exit 1); exit 1; }; }
29771
29772   # Don't try to exec as it changes $[0], causing all sort of problems
29773   # (the dirname of $[0] is not the place where we might find the
29774   # original and so on.  Autoconf is especially sensitive to this).
29775   . "./$as_me.lineno"
29776   # Exit status is that of the last command.
29777   exit
29778 }
29779
29780
29781 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
29782   as_dirname=dirname
29783 else
29784   as_dirname=false
29785 fi
29786
29787 ECHO_C= ECHO_N= ECHO_T=
29788 case `echo -n x` in
29789 -n*)
29790   case `echo 'x\c'` in
29791   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
29792   *)   ECHO_C='\c';;
29793   esac;;
29794 *)
29795   ECHO_N='-n';;
29796 esac
29797 if expr a : '\(a\)' >/dev/null 2>&1 &&
29798    test "X`expr 00001 : '.*\(...\)'`" = X001; then
29799   as_expr=expr
29800 else
29801   as_expr=false
29802 fi
29803
29804 rm -f conf$$ conf$$.exe conf$$.file
29805 if test -d conf$$.dir; then
29806   rm -f conf$$.dir/conf$$.file
29807 else
29808   rm -f conf$$.dir
29809   mkdir conf$$.dir 2>/dev/null
29810 fi
29811 if (echo >conf$$.file) 2>/dev/null; then
29812   if ln -s conf$$.file conf$$ 2>/dev/null; then
29813     as_ln_s='ln -s'
29814     # ... but there are two gotchas:
29815     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
29816     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
29817     # In both cases, we have to default to `cp -p'.
29818     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
29819       as_ln_s='cp -p'
29820   elif ln conf$$.file conf$$ 2>/dev/null; then
29821     as_ln_s=ln
29822   else
29823     as_ln_s='cp -p'
29824   fi
29825 else
29826   as_ln_s='cp -p'
29827 fi
29828 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
29829 rmdir conf$$.dir 2>/dev/null
29830
29831 if mkdir -p . 2>/dev/null; then
29832   as_mkdir_p=:
29833 else
29834   test -d ./-p && rmdir ./-p
29835   as_mkdir_p=false
29836 fi
29837
29838 if test -x / >/dev/null 2>&1; then
29839   as_test_x='test -x'
29840 else
29841   if ls -dL / >/dev/null 2>&1; then
29842     as_ls_L_option=L
29843   else
29844     as_ls_L_option=
29845   fi
29846   as_test_x='
29847     eval sh -c '\''
29848       if test -d "$1"; then
29849         test -d "$1/.";
29850       else
29851         case $1 in
29852         -*)set "./$1";;
29853         esac;
29854         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
29855         ???[sx]*):;;*)false;;esac;fi
29856     '\'' sh
29857   '
29858 fi
29859 as_executable_p=$as_test_x
29860
29861 # Sed expression to map a string onto a valid CPP name.
29862 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
29863
29864 # Sed expression to map a string onto a valid variable name.
29865 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
29866
29867
29868 exec 6>&1
29869
29870 # Save the log message, to keep $[0] and so on meaningful, and to
29871 # report actual input values of CONFIG_FILES etc. instead of their
29872 # values after options handling.
29873 ac_log="
29874 This file was extended by PostgreSQL $as_me 9.1devel, which was
29875 generated by GNU Autoconf 2.63.  Invocation command line was
29876
29877   CONFIG_FILES    = $CONFIG_FILES
29878   CONFIG_HEADERS  = $CONFIG_HEADERS
29879   CONFIG_LINKS    = $CONFIG_LINKS
29880   CONFIG_COMMANDS = $CONFIG_COMMANDS
29881   $ $0 $@
29882
29883 on `(hostname || uname -n) 2>/dev/null | sed 1q`
29884 "
29885
29886 _ACEOF
29887
29888 case $ac_config_files in *"
29889 "*) set x $ac_config_files; shift; ac_config_files=$*;;
29890 esac
29891
29892 case $ac_config_headers in *"
29893 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
29894 esac
29895
29896
29897 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29898 # Files that config.status was made for.
29899 config_files="$ac_config_files"
29900 config_headers="$ac_config_headers"
29901 config_links="$ac_config_links"
29902 config_commands="$ac_config_commands"
29903
29904 _ACEOF
29905
29906 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29907 ac_cs_usage="\
29908 \`$as_me' instantiates files from templates according to the
29909 current configuration.
29910
29911 Usage: $0 [OPTION]... [FILE]...
29912
29913   -h, --help       print this help, then exit
29914   -V, --version    print version number and configuration settings, then exit
29915   -q, --quiet, --silent
29916                    do not print progress messages
29917   -d, --debug      don't remove temporary files
29918       --recheck    update $as_me by reconfiguring in the same conditions
29919       --file=FILE[:TEMPLATE]
29920                    instantiate the configuration file FILE
29921       --header=FILE[:TEMPLATE]
29922                    instantiate the configuration header FILE
29923
29924 Configuration files:
29925 $config_files
29926
29927 Configuration headers:
29928 $config_headers
29929
29930 Configuration links:
29931 $config_links
29932
29933 Configuration commands:
29934 $config_commands
29935
29936 Report bugs to <bug-autoconf@gnu.org>."
29937
29938 _ACEOF
29939 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29940 ac_cs_version="\\
29941 PostgreSQL config.status 9.1devel
29942 configured by $0, generated by GNU Autoconf 2.63,
29943   with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
29944
29945 Copyright (C) 2008 Free Software Foundation, Inc.
29946 This config.status script is free software; the Free Software Foundation
29947 gives unlimited permission to copy, distribute and modify it."
29948
29949 ac_pwd='$ac_pwd'
29950 srcdir='$srcdir'
29951 MKDIR_P='$MKDIR_P'
29952 AWK='$AWK'
29953 test -n "\$AWK" || AWK=awk
29954 _ACEOF
29955
29956 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29957 # The default lists apply if the user does not specify any file.
29958 ac_need_defaults=:
29959 while test $# != 0
29960 do
29961   case $1 in
29962   --*=*)
29963     ac_option=`expr "X$1" : 'X\([^=]*\)='`
29964     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
29965     ac_shift=:
29966     ;;
29967   *)
29968     ac_option=$1
29969     ac_optarg=$2
29970     ac_shift=shift
29971     ;;
29972   esac
29973
29974   case $ac_option in
29975   # Handling of the options.
29976   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
29977     ac_cs_recheck=: ;;
29978   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
29979     $as_echo "$ac_cs_version"; exit ;;
29980   --debug | --debu | --deb | --de | --d | -d )
29981     debug=: ;;
29982   --file | --fil | --fi | --f )
29983     $ac_shift
29984     case $ac_optarg in
29985     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29986     esac
29987     CONFIG_FILES="$CONFIG_FILES '$ac_optarg'"
29988     ac_need_defaults=false;;
29989   --header | --heade | --head | --hea )
29990     $ac_shift
29991     case $ac_optarg in
29992     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29993     esac
29994     CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'"
29995     ac_need_defaults=false;;
29996   --he | --h)
29997     # Conflict between --help and --header
29998     { $as_echo "$as_me: error: ambiguous option: $1
29999 Try \`$0 --help' for more information." >&2
30000    { (exit 1); exit 1; }; };;
30001   --help | --hel | -h )
30002     $as_echo "$ac_cs_usage"; exit ;;
30003   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
30004   | -silent | --silent | --silen | --sile | --sil | --si | --s)
30005     ac_cs_silent=: ;;
30006
30007   # This is an error.
30008   -*) { $as_echo "$as_me: error: unrecognized option: $1
30009 Try \`$0 --help' for more information." >&2
30010    { (exit 1); exit 1; }; } ;;
30011
30012   *) ac_config_targets="$ac_config_targets $1"
30013      ac_need_defaults=false ;;
30014
30015   esac
30016   shift
30017 done
30018
30019 ac_configure_extra_args=
30020
30021 if $ac_cs_silent; then
30022   exec 6>/dev/null
30023   ac_configure_extra_args="$ac_configure_extra_args --silent"
30024 fi
30025
30026 _ACEOF
30027 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30028 if \$ac_cs_recheck; then
30029   set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
30030   shift
30031   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
30032   CONFIG_SHELL='$SHELL'
30033   export CONFIG_SHELL
30034   exec "\$@"
30035 fi
30036
30037 _ACEOF
30038 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30039 exec 5>>config.log
30040 {
30041   echo
30042   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
30043 ## Running $as_me. ##
30044 _ASBOX
30045   $as_echo "$ac_log"
30046 } >&5
30047
30048 _ACEOF
30049 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30050 _ACEOF
30051
30052 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30053
30054 # Handling of arguments.
30055 for ac_config_target in $ac_config_targets
30056 do
30057   case $ac_config_target in
30058     "src/backend/port/tas.s") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
30059     "GNUmakefile") CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
30060     "src/Makefile.global") CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
30061     "src/backend/port/dynloader.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
30062     "src/backend/port/pg_sema.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
30063     "src/backend/port/pg_shmem.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
30064     "src/backend/port/pg_latch.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_latch.c:${LATCH_IMPLEMENTATION}" ;;
30065     "src/include/dynloader.h") CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
30066     "src/include/pg_config_os.h") CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
30067     "src/Makefile.port") CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
30068     "check_win32_symlinks") CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
30069     "src/include/pg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
30070     "src/interfaces/ecpg/include/ecpg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/interfaces/ecpg/include/ecpg_config.h" ;;
30071
30072   *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
30073 $as_echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
30074    { (exit 1); exit 1; }; };;
30075   esac
30076 done
30077
30078
30079 # If the user did not use the arguments to specify the items to instantiate,
30080 # then the envvar interface is used.  Set only those that are not.
30081 # We use the long form for the default assignment because of an extremely
30082 # bizarre bug on SunOS 4.1.3.
30083 if $ac_need_defaults; then
30084   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
30085   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
30086   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
30087   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
30088 fi
30089
30090 # Have a temporary directory for convenience.  Make it in the build tree
30091 # simply because there is no reason against having it here, and in addition,
30092 # creating and moving files from /tmp can sometimes cause problems.
30093 # Hook for its removal unless debugging.
30094 # Note that there is a small window in which the directory will not be cleaned:
30095 # after its creation but before its name has been assigned to `$tmp'.
30096 $debug ||
30097 {
30098   tmp=
30099   trap 'exit_status=$?
30100   { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
30101 ' 0
30102   trap '{ (exit 1); exit 1; }' 1 2 13 15
30103 }
30104 # Create a (secure) tmp directory for tmp files.
30105
30106 {
30107   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
30108   test -n "$tmp" && test -d "$tmp"
30109 }  ||
30110 {
30111   tmp=./conf$$-$RANDOM
30112   (umask 077 && mkdir "$tmp")
30113 } ||
30114 {
30115    $as_echo "$as_me: cannot create a temporary directory in ." >&2
30116    { (exit 1); exit 1; }
30117 }
30118
30119 # Set up the scripts for CONFIG_FILES section.
30120 # No need to generate them if there are no CONFIG_FILES.
30121 # This happens for instance with `./config.status config.h'.
30122 if test -n "$CONFIG_FILES"; then
30123
30124
30125 ac_cr='\r'
30126 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
30127 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
30128   ac_cs_awk_cr='\\r'
30129 else
30130   ac_cs_awk_cr=$ac_cr
30131 fi
30132
30133 echo 'BEGIN {' >"$tmp/subs1.awk" &&
30134 _ACEOF
30135
30136
30137 {
30138   echo "cat >conf$$subs.awk <<_ACEOF" &&
30139   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
30140   echo "_ACEOF"
30141 } >conf$$subs.sh ||
30142   { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
30143 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
30144    { (exit 1); exit 1; }; }
30145 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
30146 ac_delim='%!_!# '
30147 for ac_last_try in false false false false false :; do
30148   . ./conf$$subs.sh ||
30149     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
30150 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
30151    { (exit 1); exit 1; }; }
30152
30153   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
30154   if test $ac_delim_n = $ac_delim_num; then
30155     break
30156   elif $ac_last_try; then
30157     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
30158 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
30159    { (exit 1); exit 1; }; }
30160   else
30161     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30162   fi
30163 done
30164 rm -f conf$$subs.sh
30165
30166 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30167 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
30168 _ACEOF
30169 sed -n '
30170 h
30171 s/^/S["/; s/!.*/"]=/
30172 p
30173 g
30174 s/^[^!]*!//
30175 :repl
30176 t repl
30177 s/'"$ac_delim"'$//
30178 t delim
30179 :nl
30180 h
30181 s/\(.\{148\}\).*/\1/
30182 t more1
30183 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
30184 p
30185 n
30186 b repl
30187 :more1
30188 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30189 p
30190 g
30191 s/.\{148\}//
30192 t nl
30193 :delim
30194 h
30195 s/\(.\{148\}\).*/\1/
30196 t more2
30197 s/["\\]/\\&/g; s/^/"/; s/$/"/
30198 p
30199 b
30200 :more2
30201 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30202 p
30203 g
30204 s/.\{148\}//
30205 t delim
30206 ' <conf$$subs.awk | sed '
30207 /^[^""]/{
30208   N
30209   s/\n//
30210 }
30211 ' >>$CONFIG_STATUS || ac_write_fail=1
30212 rm -f conf$$subs.awk
30213 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30214 _ACAWK
30215 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
30216   for (key in S) S_is_set[key] = 1
30217   FS = "\a"
30218
30219 }
30220 {
30221   line = $ 0
30222   nfields = split(line, field, "@")
30223   substed = 0
30224   len = length(field[1])
30225   for (i = 2; i < nfields; i++) {
30226     key = field[i]
30227     keylen = length(key)
30228     if (S_is_set[key]) {
30229       value = S[key]
30230       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
30231       len += length(value) + length(field[++i])
30232       substed = 1
30233     } else
30234       len += 1 + keylen
30235   }
30236
30237   print line
30238 }
30239
30240 _ACAWK
30241 _ACEOF
30242 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30243 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
30244   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
30245 else
30246   cat
30247 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
30248   || { { $as_echo "$as_me:$LINENO: error: could not setup config files machinery" >&5
30249 $as_echo "$as_me: error: could not setup config files machinery" >&2;}
30250    { (exit 1); exit 1; }; }
30251 _ACEOF
30252
30253 # VPATH may cause trouble with some makes, so we remove $(srcdir),
30254 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
30255 # trailing colons and then remove the whole line if VPATH becomes empty
30256 # (actually we leave an empty line to preserve line numbers).
30257 if test "x$srcdir" = x.; then
30258   ac_vpsub='/^[  ]*VPATH[        ]*=/{
30259 s/:*\$(srcdir):*/:/
30260 s/:*\${srcdir}:*/:/
30261 s/:*@srcdir@:*/:/
30262 s/^\([^=]*=[     ]*\):*/\1/
30263 s/:*$//
30264 s/^[^=]*=[       ]*$//
30265 }'
30266 fi
30267
30268 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30269 fi # test -n "$CONFIG_FILES"
30270
30271 # Set up the scripts for CONFIG_HEADERS section.
30272 # No need to generate them if there are no CONFIG_HEADERS.
30273 # This happens for instance with `./config.status Makefile'.
30274 if test -n "$CONFIG_HEADERS"; then
30275 cat >"$tmp/defines.awk" <<\_ACAWK ||
30276 BEGIN {
30277 _ACEOF
30278
30279 # Transform confdefs.h into an awk script `defines.awk', embedded as
30280 # here-document in config.status, that substitutes the proper values into
30281 # config.h.in to produce config.h.
30282
30283 # Create a delimiter string that does not exist in confdefs.h, to ease
30284 # handling of long lines.
30285 ac_delim='%!_!# '
30286 for ac_last_try in false false :; do
30287   ac_t=`sed -n "/$ac_delim/p" confdefs.h`
30288   if test -z "$ac_t"; then
30289     break
30290   elif $ac_last_try; then
30291     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5
30292 $as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;}
30293    { (exit 1); exit 1; }; }
30294   else
30295     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30296   fi
30297 done
30298
30299 # For the awk script, D is an array of macro values keyed by name,
30300 # likewise P contains macro parameters if any.  Preserve backslash
30301 # newline sequences.
30302
30303 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
30304 sed -n '
30305 s/.\{148\}/&'"$ac_delim"'/g
30306 t rset
30307 :rset
30308 s/^[     ]*#[    ]*define[       ][      ]*/ /
30309 t def
30310 d
30311 :def
30312 s/\\$//
30313 t bsnl
30314 s/["\\]/\\&/g
30315 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
30316 D["\1"]=" \3"/p
30317 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
30318 d
30319 :bsnl
30320 s/["\\]/\\&/g
30321 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
30322 D["\1"]=" \3\\\\\\n"\\/p
30323 t cont
30324 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
30325 t cont
30326 d
30327 :cont
30328 n
30329 s/.\{148\}/&'"$ac_delim"'/g
30330 t clear
30331 :clear
30332 s/\\$//
30333 t bsnlc
30334 s/["\\]/\\&/g; s/^/"/; s/$/"/p
30335 d
30336 :bsnlc
30337 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
30338 b cont
30339 ' <confdefs.h | sed '
30340 s/'"$ac_delim"'/"\\\
30341 "/g' >>$CONFIG_STATUS || ac_write_fail=1
30342
30343 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30344   for (key in D) D_is_set[key] = 1
30345   FS = "\a"
30346 }
30347 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
30348   line = \$ 0
30349   split(line, arg, " ")
30350   if (arg[1] == "#") {
30351     defundef = arg[2]
30352     mac1 = arg[3]
30353   } else {
30354     defundef = substr(arg[1], 2)
30355     mac1 = arg[2]
30356   }
30357   split(mac1, mac2, "(") #)
30358   macro = mac2[1]
30359   prefix = substr(line, 1, index(line, defundef) - 1)
30360   if (D_is_set[macro]) {
30361     # Preserve the white space surrounding the "#".
30362     print prefix "define", macro P[macro] D[macro]
30363     next
30364   } else {
30365     # Replace #undef with comments.  This is necessary, for example,
30366     # in the case of _POSIX_SOURCE, which is predefined and required
30367     # on some systems where configure will not decide to define it.
30368     if (defundef == "undef") {
30369       print "/*", prefix defundef, macro, "*/"
30370       next
30371     }
30372   }
30373 }
30374 { print }
30375 _ACAWK
30376 _ACEOF
30377 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30378   { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5
30379 $as_echo "$as_me: error: could not setup config headers machinery" >&2;}
30380    { (exit 1); exit 1; }; }
30381 fi # test -n "$CONFIG_HEADERS"
30382
30383
30384 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS  :L $CONFIG_LINKS  :C $CONFIG_COMMANDS"
30385 shift
30386 for ac_tag
30387 do
30388   case $ac_tag in
30389   :[FHLC]) ac_mode=$ac_tag; continue;;
30390   esac
30391   case $ac_mode$ac_tag in
30392   :[FHL]*:*);;
30393   :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5
30394 $as_echo "$as_me: error: invalid tag $ac_tag" >&2;}
30395    { (exit 1); exit 1; }; };;
30396   :[FH]-) ac_tag=-:-;;
30397   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
30398   esac
30399   ac_save_IFS=$IFS
30400   IFS=:
30401   set x $ac_tag
30402   IFS=$ac_save_IFS
30403   shift
30404   ac_file=$1
30405   shift
30406
30407   case $ac_mode in
30408   :L) ac_source=$1;;
30409   :[FH])
30410     ac_file_inputs=
30411     for ac_f
30412     do
30413       case $ac_f in
30414       -) ac_f="$tmp/stdin";;
30415       *) # Look for the file first in the build tree, then in the source tree
30416          # (if the path is not absolute).  The absolute path cannot be DOS-style,
30417          # because $ac_f cannot contain `:'.
30418          test -f "$ac_f" ||
30419            case $ac_f in
30420            [\\/$]*) false;;
30421            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
30422            esac ||
30423            { { $as_echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
30424 $as_echo "$as_me: error: cannot find input file: $ac_f" >&2;}
30425    { (exit 1); exit 1; }; };;
30426       esac
30427       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
30428       ac_file_inputs="$ac_file_inputs '$ac_f'"
30429     done
30430
30431     # Let's still pretend it is `configure' which instantiates (i.e., don't
30432     # use $as_me), people would be surprised to read:
30433     #    /* config.h.  Generated by config.status.  */
30434     configure_input='Generated from '`
30435           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
30436         `' by configure.'
30437     if test x"$ac_file" != x-; then
30438       configure_input="$ac_file.  $configure_input"
30439       { $as_echo "$as_me:$LINENO: creating $ac_file" >&5
30440 $as_echo "$as_me: creating $ac_file" >&6;}
30441     fi
30442     # Neutralize special characters interpreted by sed in replacement strings.
30443     case $configure_input in #(
30444     *\&* | *\|* | *\\* )
30445        ac_sed_conf_input=`$as_echo "$configure_input" |
30446        sed 's/[\\\\&|]/\\\\&/g'`;; #(
30447     *) ac_sed_conf_input=$configure_input;;
30448     esac
30449
30450     case $ac_tag in
30451     *:-:* | *:-) cat >"$tmp/stdin" \
30452       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30453 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30454    { (exit 1); exit 1; }; } ;;
30455     esac
30456     ;;
30457   esac
30458
30459   ac_dir=`$as_dirname -- "$ac_file" ||
30460 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30461          X"$ac_file" : 'X\(//\)[^/]' \| \
30462          X"$ac_file" : 'X\(//\)$' \| \
30463          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
30464 $as_echo X"$ac_file" |
30465     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30466             s//\1/
30467             q
30468           }
30469           /^X\(\/\/\)[^/].*/{
30470             s//\1/
30471             q
30472           }
30473           /^X\(\/\/\)$/{
30474             s//\1/
30475             q
30476           }
30477           /^X\(\/\).*/{
30478             s//\1/
30479             q
30480           }
30481           s/.*/./; q'`
30482   { as_dir="$ac_dir"
30483   case $as_dir in #(
30484   -*) as_dir=./$as_dir;;
30485   esac
30486   test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
30487     as_dirs=
30488     while :; do
30489       case $as_dir in #(
30490       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
30491       *) as_qdir=$as_dir;;
30492       esac
30493       as_dirs="'$as_qdir' $as_dirs"
30494       as_dir=`$as_dirname -- "$as_dir" ||
30495 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30496          X"$as_dir" : 'X\(//\)[^/]' \| \
30497          X"$as_dir" : 'X\(//\)$' \| \
30498          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
30499 $as_echo X"$as_dir" |
30500     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30501             s//\1/
30502             q
30503           }
30504           /^X\(\/\/\)[^/].*/{
30505             s//\1/
30506             q
30507           }
30508           /^X\(\/\/\)$/{
30509             s//\1/
30510             q
30511           }
30512           /^X\(\/\).*/{
30513             s//\1/
30514             q
30515           }
30516           s/.*/./; q'`
30517       test -d "$as_dir" && break
30518     done
30519     test -z "$as_dirs" || eval "mkdir $as_dirs"
30520   } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
30521 $as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
30522    { (exit 1); exit 1; }; }; }
30523   ac_builddir=.
30524
30525 case "$ac_dir" in
30526 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
30527 *)
30528   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
30529   # A ".." for each directory in $ac_dir_suffix.
30530   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
30531   case $ac_top_builddir_sub in
30532   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
30533   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
30534   esac ;;
30535 esac
30536 ac_abs_top_builddir=$ac_pwd
30537 ac_abs_builddir=$ac_pwd$ac_dir_suffix
30538 # for backward compatibility:
30539 ac_top_builddir=$ac_top_build_prefix
30540
30541 case $srcdir in
30542   .)  # We are building in place.
30543     ac_srcdir=.
30544     ac_top_srcdir=$ac_top_builddir_sub
30545     ac_abs_top_srcdir=$ac_pwd ;;
30546   [\\/]* | ?:[\\/]* )  # Absolute name.
30547     ac_srcdir=$srcdir$ac_dir_suffix;
30548     ac_top_srcdir=$srcdir
30549     ac_abs_top_srcdir=$srcdir ;;
30550   *) # Relative name.
30551     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
30552     ac_top_srcdir=$ac_top_build_prefix$srcdir
30553     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
30554 esac
30555 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
30556
30557
30558   case $ac_mode in
30559   :F)
30560   #
30561   # CONFIG_FILE
30562   #
30563
30564   ac_MKDIR_P=$MKDIR_P
30565   case $MKDIR_P in
30566   [\\/$]* | ?:[\\/]* ) ;;
30567   */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
30568   esac
30569 _ACEOF
30570
30571 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30572 # If the template does not know about datarootdir, expand it.
30573 # FIXME: This hack should be removed a few years after 2.60.
30574 ac_datarootdir_hack=; ac_datarootdir_seen=
30575
30576 ac_sed_dataroot='
30577 /datarootdir/ {
30578   p
30579   q
30580 }
30581 /@datadir@/p
30582 /@docdir@/p
30583 /@infodir@/p
30584 /@localedir@/p
30585 /@mandir@/p
30586 '
30587 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
30588 *datarootdir*) ac_datarootdir_seen=yes;;
30589 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
30590   { $as_echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
30591 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
30592 _ACEOF
30593 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30594   ac_datarootdir_hack='
30595   s&@datadir@&$datadir&g
30596   s&@docdir@&$docdir&g
30597   s&@infodir@&$infodir&g
30598   s&@localedir@&$localedir&g
30599   s&@mandir@&$mandir&g
30600     s&\\\${datarootdir}&$datarootdir&g' ;;
30601 esac
30602 _ACEOF
30603
30604 # Neutralize VPATH when `$srcdir' = `.'.
30605 # Shell code in configure.ac might set extrasub.
30606 # FIXME: do we really want to maintain this feature?
30607 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30608 ac_sed_extra="$ac_vpsub
30609 $extrasub
30610 _ACEOF
30611 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30612 :t
30613 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
30614 s|@configure_input@|$ac_sed_conf_input|;t t
30615 s&@top_builddir@&$ac_top_builddir_sub&;t t
30616 s&@top_build_prefix@&$ac_top_build_prefix&;t t
30617 s&@srcdir@&$ac_srcdir&;t t
30618 s&@abs_srcdir@&$ac_abs_srcdir&;t t
30619 s&@top_srcdir@&$ac_top_srcdir&;t t
30620 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
30621 s&@builddir@&$ac_builddir&;t t
30622 s&@abs_builddir@&$ac_abs_builddir&;t t
30623 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
30624 s&@MKDIR_P@&$ac_MKDIR_P&;t t
30625 $ac_datarootdir_hack
30626 "
30627 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
30628   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30629 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30630    { (exit 1); exit 1; }; }
30631
30632 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
30633   { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
30634   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
30635   { $as_echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30636 which seems to be undefined.  Please make sure it is defined." >&5
30637 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30638 which seems to be undefined.  Please make sure it is defined." >&2;}
30639
30640   rm -f "$tmp/stdin"
30641   case $ac_file in
30642   -) cat "$tmp/out" && rm -f "$tmp/out";;
30643   *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
30644   esac \
30645   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30646 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30647    { (exit 1); exit 1; }; }
30648  ;;
30649   :H)
30650   #
30651   # CONFIG_HEADER
30652   #
30653   if test x"$ac_file" != x-; then
30654     {
30655       $as_echo "/* $configure_input  */" \
30656       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
30657     } >"$tmp/config.h" \
30658       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30659 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30660    { (exit 1); exit 1; }; }
30661     if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
30662       { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5
30663 $as_echo "$as_me: $ac_file is unchanged" >&6;}
30664     else
30665       rm -f "$ac_file"
30666       mv "$tmp/config.h" "$ac_file" \
30667         || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30668 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30669    { (exit 1); exit 1; }; }
30670     fi
30671   else
30672     $as_echo "/* $configure_input  */" \
30673       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
30674       || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5
30675 $as_echo "$as_me: error: could not create -" >&2;}
30676    { (exit 1); exit 1; }; }
30677   fi
30678  ;;
30679   :L)
30680   #
30681   # CONFIG_LINK
30682   #
30683
30684   if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
30685     :
30686   else
30687     # Prefer the file from the source tree if names are identical.
30688     if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
30689       ac_source=$srcdir/$ac_source
30690     fi
30691
30692     { $as_echo "$as_me:$LINENO: linking $ac_source to $ac_file" >&5
30693 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
30694
30695     if test ! -r "$ac_source"; then
30696       { { $as_echo "$as_me:$LINENO: error: $ac_source: file not found" >&5
30697 $as_echo "$as_me: error: $ac_source: file not found" >&2;}
30698    { (exit 1); exit 1; }; }
30699     fi
30700     rm -f "$ac_file"
30701
30702     # Try a relative symlink, then a hard link, then a copy.
30703     case $srcdir in
30704     [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
30705         *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
30706     esac
30707     ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
30708       ln "$ac_source" "$ac_file" 2>/dev/null ||
30709       cp -p "$ac_source" "$ac_file" ||
30710       { { $as_echo "$as_me:$LINENO: error: cannot link or copy $ac_source to $ac_file" >&5
30711 $as_echo "$as_me: error: cannot link or copy $ac_source to $ac_file" >&2;}
30712    { (exit 1); exit 1; }; }
30713   fi
30714  ;;
30715   :C)  { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5
30716 $as_echo "$as_me: executing $ac_file commands" >&6;}
30717  ;;
30718   esac
30719
30720
30721   case $ac_file$ac_mode in
30722     "check_win32_symlinks":C)
30723 # Links sometimes fail undetected on Mingw -
30724 # so here we detect it and warn the user
30725 for FILE in $CONFIG_LINKS
30726  do
30727         # test -e works for symlinks in the MinGW console
30728         test -e `expr "$FILE" : '\([^:]*\)'` || { $as_echo "$as_me:$LINENO: WARNING: *** link for $FILE -- please fix by hand" >&5
30729 $as_echo "$as_me: WARNING: *** link for $FILE -- please fix by hand" >&2;}
30730  done
30731  ;;
30732     "src/include/pg_config.h":H)
30733 # Update timestamp for pg_config.h (see Makefile.global)
30734 echo >src/include/stamp-h
30735  ;;
30736     "src/interfaces/ecpg/include/ecpg_config.h":H) echo >src/interfaces/ecpg/include/stamp-h ;;
30737
30738   esac
30739 done # for ac_tag
30740
30741
30742 { (exit 0); exit 0; }
30743 _ACEOF
30744 chmod +x $CONFIG_STATUS
30745 ac_clean_files=$ac_clean_files_save
30746
30747 test $ac_write_fail = 0 ||
30748   { { $as_echo "$as_me:$LINENO: error: write failure creating $CONFIG_STATUS" >&5
30749 $as_echo "$as_me: error: write failure creating $CONFIG_STATUS" >&2;}
30750    { (exit 1); exit 1; }; }
30751
30752
30753 # configure is writing to config.log, and then calls config.status.
30754 # config.status does its own redirection, appending to config.log.
30755 # Unfortunately, on DOS this fails, as config.log is still kept open
30756 # by configure, so config.status won't be able to write to it; its
30757 # output is simply discarded.  So we exec the FD to /dev/null,
30758 # effectively closing config.log, so it can be properly (re)opened and
30759 # appended to by config.status.  When coming back to configure, we
30760 # need to make the FD available again.
30761 if test "$no_create" != yes; then
30762   ac_cs_success=:
30763   ac_config_status_args=
30764   test "$silent" = yes &&
30765     ac_config_status_args="$ac_config_status_args --quiet"
30766   exec 5>/dev/null
30767   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
30768   exec 5>>config.log
30769   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
30770   # would make configure fail if this is the last instruction.
30771   $ac_cs_success || { (exit 1); exit 1; }
30772 fi
30773 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
30774   { $as_echo "$as_me:$LINENO: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
30775 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
30776 fi
30777