]> granicus.if.org Git - postgresql/blob - configure
Add .gitignore file to silence complaints about pg_basebackup.
[postgresql] / 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_openssl
719 with_bonjour
720 with_ldap
721 with_pam
722 krb_srvtab
723 with_krb5
724 with_gssapi
725 with_python
726 with_perl
727 with_tcl
728 enable_thread_safety
729 INCLUDES
730 autodepend
731 TAS
732 GCC
733 CPP
734 SUN_STUDIO_CC
735 OBJEXT
736 EXEEXT
737 ac_ct_CC
738 CPPFLAGS
739 LDFLAGS
740 CFLAGS
741 CC
742 enable_dtrace
743 DTRACEFLAGS
744 DTRACE
745 enable_coverage
746 GENHTML
747 LCOV
748 GCOV
749 enable_profiling
750 enable_debug
751 enable_rpath
752 enable_shared
753 default_port
754 WANTED_LANGUAGES
755 enable_nls
756 PORTNAME
757 host_os
758 host_vendor
759 host_cpu
760 host
761 build_os
762 build_vendor
763 build_cpu
764 build
765 PG_MAJORVERSION
766 configure_args
767 target_alias
768 host_alias
769 build_alias
770 LIBS
771 ECHO_T
772 ECHO_N
773 ECHO_C
774 DEFS
775 mandir
776 localedir
777 libdir
778 psdir
779 pdfdir
780 dvidir
781 htmldir
782 infodir
783 docdir
784 oldincludedir
785 includedir
786 localstatedir
787 sharedstatedir
788 sysconfdir
789 datadir
790 datarootdir
791 libexecdir
792 sbindir
793 bindir
794 program_transform_name
795 prefix
796 exec_prefix
797 PACKAGE_BUGREPORT
798 PACKAGE_STRING
799 PACKAGE_VERSION
800 PACKAGE_TARNAME
801 PACKAGE_NAME
802 PATH_SEPARATOR
803 SHELL'
804 ac_subst_files=''
805 ac_user_opts='
806 enable_option_checking
807 with_template
808 with_includes
809 with_libraries
810 with_libs
811 enable_integer_datetimes
812 enable_nls
813 with_pgport
814 enable_shared
815 enable_rpath
816 enable_spinlocks
817 enable_debug
818 enable_profiling
819 enable_coverage
820 enable_dtrace
821 with_blocksize
822 with_segsize
823 with_wal_blocksize
824 with_wal_segsize
825 with_CC
826 enable_depend
827 enable_cassert
828 enable_thread_safety
829 with_tcl
830 with_tclconfig
831 with_perl
832 with_python
833 with_gssapi
834 with_krb5
835 with_krb_srvnam
836 with_pam
837 with_ldap
838 with_bonjour
839 with_openssl
840 with_readline
841 with_libedit_preferred
842 with_ossp_uuid
843 with_libxml
844 with_libxslt
845 with_system_tzdata
846 with_zlib
847 with_gnu_ld
848 enable_largefile
849 enable_float4_byval
850 enable_float8_byval
851 '
852       ac_precious_vars='build_alias
853 host_alias
854 target_alias
855 CC
856 CFLAGS
857 LDFLAGS
858 LIBS
859 CPPFLAGS
860 CPP
861 LDFLAGS_EX
862 LDFLAGS_SL
863 DOCBOOKSTYLE'
864
865
866 # Initialize some variables set by options.
867 ac_init_help=
868 ac_init_version=false
869 ac_unrecognized_opts=
870 ac_unrecognized_sep=
871 # The variables have the same names as the options, with
872 # dashes changed to underlines.
873 cache_file=/dev/null
874 exec_prefix=NONE
875 no_create=
876 no_recursion=
877 prefix=NONE
878 program_prefix=NONE
879 program_suffix=NONE
880 program_transform_name=s,x,x,
881 silent=
882 site=
883 srcdir=
884 verbose=
885 x_includes=NONE
886 x_libraries=NONE
887
888 # Installation directory options.
889 # These are left unexpanded so users can "make install exec_prefix=/foo"
890 # and all the variables that are supposed to be based on exec_prefix
891 # by default will actually change.
892 # Use braces instead of parens because sh, perl, etc. also accept them.
893 # (The list follows the same order as the GNU Coding Standards.)
894 bindir='${exec_prefix}/bin'
895 sbindir='${exec_prefix}/sbin'
896 libexecdir='${exec_prefix}/libexec'
897 datarootdir='${prefix}/share'
898 datadir='${datarootdir}'
899 sysconfdir='${prefix}/etc'
900 sharedstatedir='${prefix}/com'
901 localstatedir='${prefix}/var'
902 includedir='${prefix}/include'
903 oldincludedir='/usr/include'
904 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
905 infodir='${datarootdir}/info'
906 htmldir='${docdir}'
907 dvidir='${docdir}'
908 pdfdir='${docdir}'
909 psdir='${docdir}'
910 libdir='${exec_prefix}/lib'
911 localedir='${datarootdir}/locale'
912 mandir='${datarootdir}/man'
913
914 ac_prev=
915 ac_dashdash=
916 for ac_option
917 do
918   # If the previous option needs an argument, assign it.
919   if test -n "$ac_prev"; then
920     eval $ac_prev=\$ac_option
921     ac_prev=
922     continue
923   fi
924
925   case $ac_option in
926   *=*)  ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;;
927   *)    ac_optarg=yes ;;
928   esac
929
930   # Accept the important Cygnus configure options, so we can diagnose typos.
931
932   case $ac_dashdash$ac_option in
933   --)
934     ac_dashdash=yes ;;
935
936   -bindir | --bindir | --bindi | --bind | --bin | --bi)
937     ac_prev=bindir ;;
938   -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*)
939     bindir=$ac_optarg ;;
940
941   -build | --build | --buil | --bui | --bu)
942     ac_prev=build_alias ;;
943   -build=* | --build=* | --buil=* | --bui=* | --bu=*)
944     build_alias=$ac_optarg ;;
945
946   -cache-file | --cache-file | --cache-fil | --cache-fi \
947   | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c)
948     ac_prev=cache_file ;;
949   -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \
950   | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*)
951     cache_file=$ac_optarg ;;
952
953   --config-cache | -C)
954     cache_file=config.cache ;;
955
956   -datadir | --datadir | --datadi | --datad)
957     ac_prev=datadir ;;
958   -datadir=* | --datadir=* | --datadi=* | --datad=*)
959     datadir=$ac_optarg ;;
960
961   -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \
962   | --dataroo | --dataro | --datar)
963     ac_prev=datarootdir ;;
964   -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \
965   | --dataroot=* | --dataroo=* | --dataro=* | --datar=*)
966     datarootdir=$ac_optarg ;;
967
968   -disable-* | --disable-*)
969     ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'`
970     # Reject names that are not valid shell variable names.
971     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
972       { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
973    { (exit 1); exit 1; }; }
974     ac_useropt_orig=$ac_useropt
975     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
976     case $ac_user_opts in
977       *"
978 "enable_$ac_useropt"
979 "*) ;;
980       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig"
981          ac_unrecognized_sep=', ';;
982     esac
983     eval enable_$ac_useropt=no ;;
984
985   -docdir | --docdir | --docdi | --doc | --do)
986     ac_prev=docdir ;;
987   -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*)
988     docdir=$ac_optarg ;;
989
990   -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv)
991     ac_prev=dvidir ;;
992   -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*)
993     dvidir=$ac_optarg ;;
994
995   -enable-* | --enable-*)
996     ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'`
997     # Reject names that are not valid shell variable names.
998     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
999       { $as_echo "$as_me: error: invalid feature name: $ac_useropt" >&2
1000    { (exit 1); exit 1; }; }
1001     ac_useropt_orig=$ac_useropt
1002     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1003     case $ac_user_opts in
1004       *"
1005 "enable_$ac_useropt"
1006 "*) ;;
1007       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig"
1008          ac_unrecognized_sep=', ';;
1009     esac
1010     eval enable_$ac_useropt=\$ac_optarg ;;
1011
1012   -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \
1013   | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \
1014   | --exec | --exe | --ex)
1015     ac_prev=exec_prefix ;;
1016   -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \
1017   | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \
1018   | --exec=* | --exe=* | --ex=*)
1019     exec_prefix=$ac_optarg ;;
1020
1021   -gas | --gas | --ga | --g)
1022     # Obsolete; use --with-gas.
1023     with_gas=yes ;;
1024
1025   -help | --help | --hel | --he | -h)
1026     ac_init_help=long ;;
1027   -help=r* | --help=r* | --hel=r* | --he=r* | -hr*)
1028     ac_init_help=recursive ;;
1029   -help=s* | --help=s* | --hel=s* | --he=s* | -hs*)
1030     ac_init_help=short ;;
1031
1032   -host | --host | --hos | --ho)
1033     ac_prev=host_alias ;;
1034   -host=* | --host=* | --hos=* | --ho=*)
1035     host_alias=$ac_optarg ;;
1036
1037   -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht)
1038     ac_prev=htmldir ;;
1039   -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \
1040   | --ht=*)
1041     htmldir=$ac_optarg ;;
1042
1043   -includedir | --includedir | --includedi | --included | --include \
1044   | --includ | --inclu | --incl | --inc)
1045     ac_prev=includedir ;;
1046   -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \
1047   | --includ=* | --inclu=* | --incl=* | --inc=*)
1048     includedir=$ac_optarg ;;
1049
1050   -infodir | --infodir | --infodi | --infod | --info | --inf)
1051     ac_prev=infodir ;;
1052   -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*)
1053     infodir=$ac_optarg ;;
1054
1055   -libdir | --libdir | --libdi | --libd)
1056     ac_prev=libdir ;;
1057   -libdir=* | --libdir=* | --libdi=* | --libd=*)
1058     libdir=$ac_optarg ;;
1059
1060   -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \
1061   | --libexe | --libex | --libe)
1062     ac_prev=libexecdir ;;
1063   -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \
1064   | --libexe=* | --libex=* | --libe=*)
1065     libexecdir=$ac_optarg ;;
1066
1067   -localedir | --localedir | --localedi | --localed | --locale)
1068     ac_prev=localedir ;;
1069   -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*)
1070     localedir=$ac_optarg ;;
1071
1072   -localstatedir | --localstatedir | --localstatedi | --localstated \
1073   | --localstate | --localstat | --localsta | --localst | --locals)
1074     ac_prev=localstatedir ;;
1075   -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \
1076   | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*)
1077     localstatedir=$ac_optarg ;;
1078
1079   -mandir | --mandir | --mandi | --mand | --man | --ma | --m)
1080     ac_prev=mandir ;;
1081   -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*)
1082     mandir=$ac_optarg ;;
1083
1084   -nfp | --nfp | --nf)
1085     # Obsolete; use --without-fp.
1086     with_fp=no ;;
1087
1088   -no-create | --no-create | --no-creat | --no-crea | --no-cre \
1089   | --no-cr | --no-c | -n)
1090     no_create=yes ;;
1091
1092   -no-recursion | --no-recursion | --no-recursio | --no-recursi \
1093   | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r)
1094     no_recursion=yes ;;
1095
1096   -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \
1097   | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \
1098   | --oldin | --oldi | --old | --ol | --o)
1099     ac_prev=oldincludedir ;;
1100   -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \
1101   | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \
1102   | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*)
1103     oldincludedir=$ac_optarg ;;
1104
1105   -prefix | --prefix | --prefi | --pref | --pre | --pr | --p)
1106     ac_prev=prefix ;;
1107   -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*)
1108     prefix=$ac_optarg ;;
1109
1110   -program-prefix | --program-prefix | --program-prefi | --program-pref \
1111   | --program-pre | --program-pr | --program-p)
1112     ac_prev=program_prefix ;;
1113   -program-prefix=* | --program-prefix=* | --program-prefi=* \
1114   | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*)
1115     program_prefix=$ac_optarg ;;
1116
1117   -program-suffix | --program-suffix | --program-suffi | --program-suff \
1118   | --program-suf | --program-su | --program-s)
1119     ac_prev=program_suffix ;;
1120   -program-suffix=* | --program-suffix=* | --program-suffi=* \
1121   | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*)
1122     program_suffix=$ac_optarg ;;
1123
1124   -program-transform-name | --program-transform-name \
1125   | --program-transform-nam | --program-transform-na \
1126   | --program-transform-n | --program-transform- \
1127   | --program-transform | --program-transfor \
1128   | --program-transfo | --program-transf \
1129   | --program-trans | --program-tran \
1130   | --progr-tra | --program-tr | --program-t)
1131     ac_prev=program_transform_name ;;
1132   -program-transform-name=* | --program-transform-name=* \
1133   | --program-transform-nam=* | --program-transform-na=* \
1134   | --program-transform-n=* | --program-transform-=* \
1135   | --program-transform=* | --program-transfor=* \
1136   | --program-transfo=* | --program-transf=* \
1137   | --program-trans=* | --program-tran=* \
1138   | --progr-tra=* | --program-tr=* | --program-t=*)
1139     program_transform_name=$ac_optarg ;;
1140
1141   -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd)
1142     ac_prev=pdfdir ;;
1143   -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*)
1144     pdfdir=$ac_optarg ;;
1145
1146   -psdir | --psdir | --psdi | --psd | --ps)
1147     ac_prev=psdir ;;
1148   -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*)
1149     psdir=$ac_optarg ;;
1150
1151   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1152   | -silent | --silent | --silen | --sile | --sil)
1153     silent=yes ;;
1154
1155   -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
1156     ac_prev=sbindir ;;
1157   -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
1158   | --sbi=* | --sb=*)
1159     sbindir=$ac_optarg ;;
1160
1161   -sharedstatedir | --sharedstatedir | --sharedstatedi \
1162   | --sharedstated | --sharedstate | --sharedstat | --sharedsta \
1163   | --sharedst | --shareds | --shared | --share | --shar \
1164   | --sha | --sh)
1165     ac_prev=sharedstatedir ;;
1166   -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \
1167   | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \
1168   | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \
1169   | --sha=* | --sh=*)
1170     sharedstatedir=$ac_optarg ;;
1171
1172   -site | --site | --sit)
1173     ac_prev=site ;;
1174   -site=* | --site=* | --sit=*)
1175     site=$ac_optarg ;;
1176
1177   -srcdir | --srcdir | --srcdi | --srcd | --src | --sr)
1178     ac_prev=srcdir ;;
1179   -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*)
1180     srcdir=$ac_optarg ;;
1181
1182   -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \
1183   | --syscon | --sysco | --sysc | --sys | --sy)
1184     ac_prev=sysconfdir ;;
1185   -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \
1186   | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*)
1187     sysconfdir=$ac_optarg ;;
1188
1189   -target | --target | --targe | --targ | --tar | --ta | --t)
1190     ac_prev=target_alias ;;
1191   -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*)
1192     target_alias=$ac_optarg ;;
1193
1194   -v | -verbose | --verbose | --verbos | --verbo | --verb)
1195     verbose=yes ;;
1196
1197   -version | --version | --versio | --versi | --vers | -V)
1198     ac_init_version=: ;;
1199
1200   -with-* | --with-*)
1201     ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'`
1202     # Reject names that are not valid shell variable names.
1203     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1204       { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1205    { (exit 1); exit 1; }; }
1206     ac_useropt_orig=$ac_useropt
1207     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1208     case $ac_user_opts in
1209       *"
1210 "with_$ac_useropt"
1211 "*) ;;
1212       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig"
1213          ac_unrecognized_sep=', ';;
1214     esac
1215     eval with_$ac_useropt=\$ac_optarg ;;
1216
1217   -without-* | --without-*)
1218     ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'`
1219     # Reject names that are not valid shell variable names.
1220     expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null &&
1221       { $as_echo "$as_me: error: invalid package name: $ac_useropt" >&2
1222    { (exit 1); exit 1; }; }
1223     ac_useropt_orig=$ac_useropt
1224     ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'`
1225     case $ac_user_opts in
1226       *"
1227 "with_$ac_useropt"
1228 "*) ;;
1229       *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig"
1230          ac_unrecognized_sep=', ';;
1231     esac
1232     eval with_$ac_useropt=no ;;
1233
1234   --x)
1235     # Obsolete; use --with-x.
1236     with_x=yes ;;
1237
1238   -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \
1239   | --x-incl | --x-inc | --x-in | --x-i)
1240     ac_prev=x_includes ;;
1241   -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \
1242   | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*)
1243     x_includes=$ac_optarg ;;
1244
1245   -x-libraries | --x-libraries | --x-librarie | --x-librari \
1246   | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l)
1247     ac_prev=x_libraries ;;
1248   -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \
1249   | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*)
1250     x_libraries=$ac_optarg ;;
1251
1252   -*) { $as_echo "$as_me: error: unrecognized option: $ac_option
1253 Try \`$0 --help' for more information." >&2
1254    { (exit 1); exit 1; }; }
1255     ;;
1256
1257   *=*)
1258     ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='`
1259     # Reject names that are not valid shell variable names.
1260     expr "x$ac_envvar" : ".*[^_$as_cr_alnum]" >/dev/null &&
1261       { $as_echo "$as_me: error: invalid variable name: $ac_envvar" >&2
1262    { (exit 1); exit 1; }; }
1263     eval $ac_envvar=\$ac_optarg
1264     export $ac_envvar ;;
1265
1266   *)
1267     # FIXME: should be removed in autoconf 3.0.
1268     $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2
1269     expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null &&
1270       $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2
1271     : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}
1272     ;;
1273
1274   esac
1275 done
1276
1277 if test -n "$ac_prev"; then
1278   ac_option=--`echo $ac_prev | sed 's/_/-/g'`
1279   { $as_echo "$as_me: error: missing argument to $ac_option" >&2
1280    { (exit 1); exit 1; }; }
1281 fi
1282
1283 if test -n "$ac_unrecognized_opts"; then
1284   case $enable_option_checking in
1285     no) ;;
1286     fatal) { $as_echo "$as_me: error: unrecognized options: $ac_unrecognized_opts" >&2
1287    { (exit 1); exit 1; }; } ;;
1288     *)     $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;;
1289   esac
1290 fi
1291
1292 # Check all directory arguments for consistency.
1293 for ac_var in   exec_prefix prefix bindir sbindir libexecdir datarootdir \
1294                 datadir sysconfdir sharedstatedir localstatedir includedir \
1295                 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
1296                 libdir localedir mandir
1297 do
1298   eval ac_val=\$$ac_var
1299   # Remove trailing slashes.
1300   case $ac_val in
1301     */ )
1302       ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'`
1303       eval $ac_var=\$ac_val;;
1304   esac
1305   # Be sure to have absolute directory names.
1306   case $ac_val in
1307     [\\/$]* | ?:[\\/]* )  continue;;
1308     NONE | '' ) case $ac_var in *prefix ) continue;; esac;;
1309   esac
1310   { $as_echo "$as_me: error: expected an absolute directory name for --$ac_var: $ac_val" >&2
1311    { (exit 1); exit 1; }; }
1312 done
1313
1314 # There might be people who depend on the old broken behavior: `$host'
1315 # used to hold the argument of --host etc.
1316 # FIXME: To remove some day.
1317 build=$build_alias
1318 host=$host_alias
1319 target=$target_alias
1320
1321 # FIXME: To remove some day.
1322 if test "x$host_alias" != x; then
1323   if test "x$build_alias" = x; then
1324     cross_compiling=maybe
1325     $as_echo "$as_me: WARNING: If you wanted to set the --build type, don't use --host.
1326     If a cross compiler is detected then cross compile mode will be used." >&2
1327   elif test "x$build_alias" != "x$host_alias"; then
1328     cross_compiling=yes
1329   fi
1330 fi
1331
1332 ac_tool_prefix=
1333 test -n "$host_alias" && ac_tool_prefix=$host_alias-
1334
1335 test "$silent" = yes && exec 6>/dev/null
1336
1337
1338 ac_pwd=`pwd` && test -n "$ac_pwd" &&
1339 ac_ls_di=`ls -di .` &&
1340 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` ||
1341   { $as_echo "$as_me: error: working directory cannot be determined" >&2
1342    { (exit 1); exit 1; }; }
1343 test "X$ac_ls_di" = "X$ac_pwd_ls_di" ||
1344   { $as_echo "$as_me: error: pwd does not report name of working directory" >&2
1345    { (exit 1); exit 1; }; }
1346
1347
1348 # Find the source files, if location was not specified.
1349 if test -z "$srcdir"; then
1350   ac_srcdir_defaulted=yes
1351   # Try the directory containing this script, then the parent directory.
1352   ac_confdir=`$as_dirname -- "$as_myself" ||
1353 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
1354          X"$as_myself" : 'X\(//\)[^/]' \| \
1355          X"$as_myself" : 'X\(//\)$' \| \
1356          X"$as_myself" : 'X\(/\)' \| . 2>/dev/null ||
1357 $as_echo X"$as_myself" |
1358     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
1359             s//\1/
1360             q
1361           }
1362           /^X\(\/\/\)[^/].*/{
1363             s//\1/
1364             q
1365           }
1366           /^X\(\/\/\)$/{
1367             s//\1/
1368             q
1369           }
1370           /^X\(\/\).*/{
1371             s//\1/
1372             q
1373           }
1374           s/.*/./; q'`
1375   srcdir=$ac_confdir
1376   if test ! -r "$srcdir/$ac_unique_file"; then
1377     srcdir=..
1378   fi
1379 else
1380   ac_srcdir_defaulted=no
1381 fi
1382 if test ! -r "$srcdir/$ac_unique_file"; then
1383   test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .."
1384   { $as_echo "$as_me: error: cannot find sources ($ac_unique_file) in $srcdir" >&2
1385    { (exit 1); exit 1; }; }
1386 fi
1387 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work"
1388 ac_abs_confdir=`(
1389         cd "$srcdir" && test -r "./$ac_unique_file" || { $as_echo "$as_me: error: $ac_msg" >&2
1390    { (exit 1); exit 1; }; }
1391         pwd)`
1392 # When building in place, set srcdir=.
1393 if test "$ac_abs_confdir" = "$ac_pwd"; then
1394   srcdir=.
1395 fi
1396 # Remove unnecessary trailing slashes from srcdir.
1397 # Double slashes in file names in object file debugging info
1398 # mess up M-x gdb in Emacs.
1399 case $srcdir in
1400 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;;
1401 esac
1402 for ac_var in $ac_precious_vars; do
1403   eval ac_env_${ac_var}_set=\${${ac_var}+set}
1404   eval ac_env_${ac_var}_value=\$${ac_var}
1405   eval ac_cv_env_${ac_var}_set=\${${ac_var}+set}
1406   eval ac_cv_env_${ac_var}_value=\$${ac_var}
1407 done
1408
1409 #
1410 # Report the --help message.
1411 #
1412 if test "$ac_init_help" = "long"; then
1413   # Omit some internal or obsolete options to make the list less imposing.
1414   # This message is too long to be a string in the A/UX 3.1 sh.
1415   cat <<_ACEOF
1416 \`configure' configures PostgreSQL 9.1devel to adapt to many kinds of systems.
1417
1418 Usage: $0 [OPTION]... [VAR=VALUE]...
1419
1420 To assign environment variables (e.g., CC, CFLAGS...), specify them as
1421 VAR=VALUE.  See below for descriptions of some of the useful variables.
1422
1423 Defaults for the options are specified in brackets.
1424
1425 Configuration:
1426   -h, --help              display this help and exit
1427       --help=short        display options specific to this package
1428       --help=recursive    display the short help of all the included packages
1429   -V, --version           display version information and exit
1430   -q, --quiet, --silent   do not print \`checking...' messages
1431       --cache-file=FILE   cache test results in FILE [disabled]
1432   -C, --config-cache      alias for \`--cache-file=config.cache'
1433   -n, --no-create         do not create output files
1434       --srcdir=DIR        find the sources in DIR [configure dir or \`..']
1435
1436 Installation directories:
1437   --prefix=PREFIX         install architecture-independent files in PREFIX
1438                           [$ac_default_prefix]
1439   --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
1440                           [PREFIX]
1441
1442 By default, \`make install' will install all the files in
1443 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc.  You can specify
1444 an installation prefix other than \`$ac_default_prefix' using \`--prefix',
1445 for instance \`--prefix=\$HOME'.
1446
1447 For better control, use the options below.
1448
1449 Fine tuning of the installation directories:
1450   --bindir=DIR            user executables [EPREFIX/bin]
1451   --sbindir=DIR           system admin executables [EPREFIX/sbin]
1452   --libexecdir=DIR        program executables [EPREFIX/libexec]
1453   --sysconfdir=DIR        read-only single-machine data [PREFIX/etc]
1454   --sharedstatedir=DIR    modifiable architecture-independent data [PREFIX/com]
1455   --localstatedir=DIR     modifiable single-machine data [PREFIX/var]
1456   --libdir=DIR            object code libraries [EPREFIX/lib]
1457   --includedir=DIR        C header files [PREFIX/include]
1458   --oldincludedir=DIR     C header files for non-gcc [/usr/include]
1459   --datarootdir=DIR       read-only arch.-independent data root [PREFIX/share]
1460   --datadir=DIR           read-only architecture-independent data [DATAROOTDIR]
1461   --infodir=DIR           info documentation [DATAROOTDIR/info]
1462   --localedir=DIR         locale-dependent data [DATAROOTDIR/locale]
1463   --mandir=DIR            man documentation [DATAROOTDIR/man]
1464   --docdir=DIR            documentation root [DATAROOTDIR/doc/postgresql]
1465   --htmldir=DIR           html documentation [DOCDIR]
1466   --dvidir=DIR            dvi documentation [DOCDIR]
1467   --pdfdir=DIR            pdf documentation [DOCDIR]
1468   --psdir=DIR             ps documentation [DOCDIR]
1469 _ACEOF
1470
1471   cat <<\_ACEOF
1472
1473 System types:
1474   --build=BUILD     configure for building on BUILD [guessed]
1475   --host=HOST       cross-compile to build programs to run on HOST [BUILD]
1476 _ACEOF
1477 fi
1478
1479 if test -n "$ac_init_help"; then
1480   case $ac_init_help in
1481      short | recursive ) echo "Configuration of PostgreSQL 9.1devel:";;
1482    esac
1483   cat <<\_ACEOF
1484
1485 Optional Features:
1486   --disable-option-checking  ignore unrecognized --enable/--with options
1487   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
1488   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
1489   --disable-integer-datetimes
1490                           disable 64-bit integer date/time support
1491   --enable-nls[=LANGUAGES]
1492                           enable Native Language Support
1493   --disable-shared        do not build shared libraries
1494   --disable-rpath         do not embed shared library search path in
1495                           executables
1496   --disable-spinlocks     do not use spinlocks
1497   --enable-debug          build with debugging symbols (-g)
1498   --enable-profiling      build with profiling enabled
1499   --enable-coverage       build with coverage testing instrumentation
1500   --enable-dtrace         build with DTrace support
1501   --enable-depend         turn on automatic dependency tracking
1502   --enable-cassert        enable assertion checks (for debugging)
1503   --disable-thread-safety disable thread-safety in client libraries
1504   --disable-largefile     omit support for large files
1505   --disable-float4-byval  disable float4 passed by value
1506   --disable-float8-byval  disable float8 passed by value
1507
1508 Optional Packages:
1509   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1510   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1511   --with-template=NAME    override operating system template
1512   --with-includes=DIRS    look for additional header files in DIRS
1513   --with-libraries=DIRS   look for additional libraries in DIRS
1514   --with-libs=DIRS        alternative spelling of --with-libraries
1515   --with-pgport=PORTNUM   set default port number [5432]
1516   --with-blocksize=BLOCKSIZE
1517                           set table block size in kB [8]
1518   --with-segsize=SEGSIZE  set table segment size in GB [1]
1519   --with-wal-blocksize=BLOCKSIZE
1520                           set WAL block size in kB [8]
1521   --with-wal-segsize=SEGSIZE
1522                           set WAL segment size in MB [16]
1523   --with-CC=CMD           set compiler (deprecated)
1524   --with-tcl              build Tcl modules (PL/Tcl)
1525   --with-tclconfig=DIR    tclConfig.sh is in DIR
1526   --with-perl             build Perl modules (PL/Perl)
1527   --with-python           build Python modules (PL/Python)
1528   --with-gssapi           build with GSSAPI support
1529   --with-krb5             build with Kerberos 5 support
1530   --with-krb-srvnam=NAME  default service principal name in Kerberos
1531                           [postgres]
1532   --with-pam              build with PAM support
1533   --with-ldap             build with LDAP support
1534   --with-bonjour          build with Bonjour support
1535   --with-openssl          build with OpenSSL support
1536   --without-readline      do not use GNU Readline nor BSD Libedit for editing
1537   --with-libedit-preferred
1538                           prefer BSD Libedit over GNU Readline
1539   --with-ossp-uuid        use OSSP UUID library when building
1540                           contrib/uuid-ossp
1541   --with-libxml           build with XML support
1542   --with-libxslt          use XSLT support when building contrib/xml2
1543   --with-system-tzdata=DIR
1544                           use system time zone data in DIR
1545   --without-zlib          do not use Zlib
1546   --with-gnu-ld           assume the C compiler uses GNU ld [default=no]
1547
1548 Some influential environment variables:
1549   CC          C compiler command
1550   CFLAGS      C compiler flags
1551   LDFLAGS     linker flags, e.g. -L<lib dir> if you have libraries in a
1552               nonstandard directory <lib dir>
1553   LIBS        libraries to pass to the linker, e.g. -l<library>
1554   CPPFLAGS    C/C++/Objective C preprocessor flags, e.g. -I<include dir> if
1555               you have headers in a nonstandard directory <include dir>
1556   CPP         C preprocessor
1557   LDFLAGS_EX  extra linker flags for linking executables only
1558   LDFLAGS_SL  extra linker flags for linking shared libraries only
1559   DOCBOOKSTYLE
1560               location of DocBook stylesheets
1561
1562 Use these variables to override the choices made by `configure' or to help
1563 it to find libraries and programs with nonstandard names/locations.
1564
1565 Report bugs to <pgsql-bugs@postgresql.org>.
1566 _ACEOF
1567 ac_status=$?
1568 fi
1569
1570 if test "$ac_init_help" = "recursive"; then
1571   # If there are subdirs, report their specific --help.
1572   for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue
1573     test -d "$ac_dir" ||
1574       { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } ||
1575       continue
1576     ac_builddir=.
1577
1578 case "$ac_dir" in
1579 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
1580 *)
1581   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
1582   # A ".." for each directory in $ac_dir_suffix.
1583   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
1584   case $ac_top_builddir_sub in
1585   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
1586   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
1587   esac ;;
1588 esac
1589 ac_abs_top_builddir=$ac_pwd
1590 ac_abs_builddir=$ac_pwd$ac_dir_suffix
1591 # for backward compatibility:
1592 ac_top_builddir=$ac_top_build_prefix
1593
1594 case $srcdir in
1595   .)  # We are building in place.
1596     ac_srcdir=.
1597     ac_top_srcdir=$ac_top_builddir_sub
1598     ac_abs_top_srcdir=$ac_pwd ;;
1599   [\\/]* | ?:[\\/]* )  # Absolute name.
1600     ac_srcdir=$srcdir$ac_dir_suffix;
1601     ac_top_srcdir=$srcdir
1602     ac_abs_top_srcdir=$srcdir ;;
1603   *) # Relative name.
1604     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
1605     ac_top_srcdir=$ac_top_build_prefix$srcdir
1606     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
1607 esac
1608 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
1609
1610     cd "$ac_dir" || { ac_status=$?; continue; }
1611     # Check for guested configure.
1612     if test -f "$ac_srcdir/configure.gnu"; then
1613       echo &&
1614       $SHELL "$ac_srcdir/configure.gnu" --help=recursive
1615     elif test -f "$ac_srcdir/configure"; then
1616       echo &&
1617       $SHELL "$ac_srcdir/configure" --help=recursive
1618     else
1619       $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2
1620     fi || ac_status=$?
1621     cd "$ac_pwd" || { ac_status=$?; break; }
1622   done
1623 fi
1624
1625 test -n "$ac_init_help" && exit $ac_status
1626 if $ac_init_version; then
1627   cat <<\_ACEOF
1628 PostgreSQL configure 9.1devel
1629 generated by GNU Autoconf 2.63
1630
1631 Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001,
1632 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
1633 This configure script is free software; the Free Software Foundation
1634 gives unlimited permission to copy, distribute and modify it.
1635
1636 Copyright (c) 1996-2011, PostgreSQL Global Development Group
1637 _ACEOF
1638   exit
1639 fi
1640 cat >config.log <<_ACEOF
1641 This file contains any messages produced by compilers while
1642 running configure, to aid debugging if configure makes a mistake.
1643
1644 It was created by PostgreSQL $as_me 9.1devel, which was
1645 generated by GNU Autoconf 2.63.  Invocation command line was
1646
1647   $ $0 $@
1648
1649 _ACEOF
1650 exec 5>>config.log
1651 {
1652 cat <<_ASUNAME
1653 ## --------- ##
1654 ## Platform. ##
1655 ## --------- ##
1656
1657 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q`
1658 uname -m = `(uname -m) 2>/dev/null || echo unknown`
1659 uname -r = `(uname -r) 2>/dev/null || echo unknown`
1660 uname -s = `(uname -s) 2>/dev/null || echo unknown`
1661 uname -v = `(uname -v) 2>/dev/null || echo unknown`
1662
1663 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown`
1664 /bin/uname -X     = `(/bin/uname -X) 2>/dev/null     || echo unknown`
1665
1666 /bin/arch              = `(/bin/arch) 2>/dev/null              || echo unknown`
1667 /usr/bin/arch -k       = `(/usr/bin/arch -k) 2>/dev/null       || echo unknown`
1668 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown`
1669 /usr/bin/hostinfo      = `(/usr/bin/hostinfo) 2>/dev/null      || echo unknown`
1670 /bin/machine           = `(/bin/machine) 2>/dev/null           || echo unknown`
1671 /usr/bin/oslevel       = `(/usr/bin/oslevel) 2>/dev/null       || echo unknown`
1672 /bin/universe          = `(/bin/universe) 2>/dev/null          || echo unknown`
1673
1674 _ASUNAME
1675
1676 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
1677 for as_dir in $PATH
1678 do
1679   IFS=$as_save_IFS
1680   test -z "$as_dir" && as_dir=.
1681   $as_echo "PATH: $as_dir"
1682 done
1683 IFS=$as_save_IFS
1684
1685 } >&5
1686
1687 cat >&5 <<_ACEOF
1688
1689
1690 ## ----------- ##
1691 ## Core tests. ##
1692 ## ----------- ##
1693
1694 _ACEOF
1695
1696
1697 # Keep a trace of the command line.
1698 # Strip out --no-create and --no-recursion so they do not pile up.
1699 # Strip out --silent because we don't want to record it for future runs.
1700 # Also quote any args containing shell meta-characters.
1701 # Make two passes to allow for proper duplicate-argument suppression.
1702 ac_configure_args=
1703 ac_configure_args0=
1704 ac_configure_args1=
1705 ac_must_keep_next=false
1706 for ac_pass in 1 2
1707 do
1708   for ac_arg
1709   do
1710     case $ac_arg in
1711     -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;;
1712     -q | -quiet | --quiet | --quie | --qui | --qu | --q \
1713     | -silent | --silent | --silen | --sile | --sil)
1714       continue ;;
1715     *\'*)
1716       ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;;
1717     esac
1718     case $ac_pass in
1719     1) ac_configure_args0="$ac_configure_args0 '$ac_arg'" ;;
1720     2)
1721       ac_configure_args1="$ac_configure_args1 '$ac_arg'"
1722       if test $ac_must_keep_next = true; then
1723         ac_must_keep_next=false # Got value, back to normal.
1724       else
1725         case $ac_arg in
1726           *=* | --config-cache | -C | -disable-* | --disable-* \
1727           | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \
1728           | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \
1729           | -with-* | --with-* | -without-* | --without-* | --x)
1730             case "$ac_configure_args0 " in
1731               "$ac_configure_args1"*" '$ac_arg' "* ) continue ;;
1732             esac
1733             ;;
1734           -* ) ac_must_keep_next=true ;;
1735         esac
1736       fi
1737       ac_configure_args="$ac_configure_args '$ac_arg'"
1738       ;;
1739     esac
1740   done
1741 done
1742 $as_unset ac_configure_args0 || test "${ac_configure_args0+set}" != set || { ac_configure_args0=; export ac_configure_args0; }
1743 $as_unset ac_configure_args1 || test "${ac_configure_args1+set}" != set || { ac_configure_args1=; export ac_configure_args1; }
1744
1745 # When interrupted or exit'd, cleanup temporary files, and complete
1746 # config.log.  We remove comments because anyway the quotes in there
1747 # would cause problems or look ugly.
1748 # WARNING: Use '\'' to represent an apostrophe within the trap.
1749 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug.
1750 trap 'exit_status=$?
1751   # Save into config.log some information that might help in debugging.
1752   {
1753     echo
1754
1755     cat <<\_ASBOX
1756 ## ---------------- ##
1757 ## Cache variables. ##
1758 ## ---------------- ##
1759 _ASBOX
1760     echo
1761     # The following way of writing the cache mishandles newlines in values,
1762 (
1763   for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do
1764     eval ac_val=\$$ac_var
1765     case $ac_val in #(
1766     *${as_nl}*)
1767       case $ac_var in #(
1768       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
1769 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
1770       esac
1771       case $ac_var in #(
1772       _ | IFS | as_nl) ;; #(
1773       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
1774       *) $as_unset $ac_var ;;
1775       esac ;;
1776     esac
1777   done
1778   (set) 2>&1 |
1779     case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #(
1780     *${as_nl}ac_space=\ *)
1781       sed -n \
1782         "s/'\''/'\''\\\\'\'''\''/g;
1783           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p"
1784       ;; #(
1785     *)
1786       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
1787       ;;
1788     esac |
1789     sort
1790 )
1791     echo
1792
1793     cat <<\_ASBOX
1794 ## ----------------- ##
1795 ## Output variables. ##
1796 ## ----------------- ##
1797 _ASBOX
1798     echo
1799     for ac_var in $ac_subst_vars
1800     do
1801       eval ac_val=\$$ac_var
1802       case $ac_val in
1803       *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1804       esac
1805       $as_echo "$ac_var='\''$ac_val'\''"
1806     done | sort
1807     echo
1808
1809     if test -n "$ac_subst_files"; then
1810       cat <<\_ASBOX
1811 ## ------------------- ##
1812 ## File substitutions. ##
1813 ## ------------------- ##
1814 _ASBOX
1815       echo
1816       for ac_var in $ac_subst_files
1817       do
1818         eval ac_val=\$$ac_var
1819         case $ac_val in
1820         *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;;
1821         esac
1822         $as_echo "$ac_var='\''$ac_val'\''"
1823       done | sort
1824       echo
1825     fi
1826
1827     if test -s confdefs.h; then
1828       cat <<\_ASBOX
1829 ## ----------- ##
1830 ## confdefs.h. ##
1831 ## ----------- ##
1832 _ASBOX
1833       echo
1834       cat confdefs.h
1835       echo
1836     fi
1837     test "$ac_signal" != 0 &&
1838       $as_echo "$as_me: caught signal $ac_signal"
1839     $as_echo "$as_me: exit $exit_status"
1840   } >&5
1841   rm -f core *.core core.conftest.* &&
1842     rm -f -r conftest* confdefs* conf$$* $ac_clean_files &&
1843     exit $exit_status
1844 ' 0
1845 for ac_signal in 1 2 13 15; do
1846   trap 'ac_signal='$ac_signal'; { (exit 1); exit 1; }' $ac_signal
1847 done
1848 ac_signal=0
1849
1850 # confdefs.h avoids OS command line length limits that DEFS can exceed.
1851 rm -f -r conftest* confdefs.h
1852
1853 # Predefined preprocessor variables.
1854
1855 cat >>confdefs.h <<_ACEOF
1856 #define PACKAGE_NAME "$PACKAGE_NAME"
1857 _ACEOF
1858
1859
1860 cat >>confdefs.h <<_ACEOF
1861 #define PACKAGE_TARNAME "$PACKAGE_TARNAME"
1862 _ACEOF
1863
1864
1865 cat >>confdefs.h <<_ACEOF
1866 #define PACKAGE_VERSION "$PACKAGE_VERSION"
1867 _ACEOF
1868
1869
1870 cat >>confdefs.h <<_ACEOF
1871 #define PACKAGE_STRING "$PACKAGE_STRING"
1872 _ACEOF
1873
1874
1875 cat >>confdefs.h <<_ACEOF
1876 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT"
1877 _ACEOF
1878
1879
1880 # Let the site file select an alternate cache file if it wants to.
1881 # Prefer an explicitly selected file to automatically selected ones.
1882 ac_site_file1=NONE
1883 ac_site_file2=NONE
1884 if test -n "$CONFIG_SITE"; then
1885   ac_site_file1=$CONFIG_SITE
1886 elif test "x$prefix" != xNONE; then
1887   ac_site_file1=$prefix/share/config.site
1888   ac_site_file2=$prefix/etc/config.site
1889 else
1890   ac_site_file1=$ac_default_prefix/share/config.site
1891   ac_site_file2=$ac_default_prefix/etc/config.site
1892 fi
1893 for ac_site_file in "$ac_site_file1" "$ac_site_file2"
1894 do
1895   test "x$ac_site_file" = xNONE && continue
1896   if test -r "$ac_site_file"; then
1897     { $as_echo "$as_me:$LINENO: loading site script $ac_site_file" >&5
1898 $as_echo "$as_me: loading site script $ac_site_file" >&6;}
1899     sed 's/^/| /' "$ac_site_file" >&5
1900     . "$ac_site_file"
1901   fi
1902 done
1903
1904 if test -r "$cache_file"; then
1905   # Some versions of bash will fail to source /dev/null (special
1906   # files actually), so we avoid doing that.
1907   if test -f "$cache_file"; then
1908     { $as_echo "$as_me:$LINENO: loading cache $cache_file" >&5
1909 $as_echo "$as_me: loading cache $cache_file" >&6;}
1910     case $cache_file in
1911       [\\/]* | ?:[\\/]* ) . "$cache_file";;
1912       *)                      . "./$cache_file";;
1913     esac
1914   fi
1915 else
1916   { $as_echo "$as_me:$LINENO: creating cache $cache_file" >&5
1917 $as_echo "$as_me: creating cache $cache_file" >&6;}
1918   >$cache_file
1919 fi
1920
1921 # Check that the precious variables saved in the cache have kept the same
1922 # value.
1923 ac_cache_corrupted=false
1924 for ac_var in $ac_precious_vars; do
1925   eval ac_old_set=\$ac_cv_env_${ac_var}_set
1926   eval ac_new_set=\$ac_env_${ac_var}_set
1927   eval ac_old_val=\$ac_cv_env_${ac_var}_value
1928   eval ac_new_val=\$ac_env_${ac_var}_value
1929   case $ac_old_set,$ac_new_set in
1930     set,)
1931       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5
1932 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;}
1933       ac_cache_corrupted=: ;;
1934     ,set)
1935       { $as_echo "$as_me:$LINENO: error: \`$ac_var' was not set in the previous run" >&5
1936 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;}
1937       ac_cache_corrupted=: ;;
1938     ,);;
1939     *)
1940       if test "x$ac_old_val" != "x$ac_new_val"; then
1941         # differences in whitespace do not lead to failure.
1942         ac_old_val_w=`echo x $ac_old_val`
1943         ac_new_val_w=`echo x $ac_new_val`
1944         if test "$ac_old_val_w" != "$ac_new_val_w"; then
1945           { $as_echo "$as_me:$LINENO: error: \`$ac_var' has changed since the previous run:" >&5
1946 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;}
1947           ac_cache_corrupted=:
1948         else
1949           { $as_echo "$as_me:$LINENO: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5
1950 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;}
1951           eval $ac_var=\$ac_old_val
1952         fi
1953         { $as_echo "$as_me:$LINENO:   former value:  \`$ac_old_val'" >&5
1954 $as_echo "$as_me:   former value:  \`$ac_old_val'" >&2;}
1955         { $as_echo "$as_me:$LINENO:   current value: \`$ac_new_val'" >&5
1956 $as_echo "$as_me:   current value: \`$ac_new_val'" >&2;}
1957       fi;;
1958   esac
1959   # Pass precious variables to config.status.
1960   if test "$ac_new_set" = set; then
1961     case $ac_new_val in
1962     *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;;
1963     *) ac_arg=$ac_var=$ac_new_val ;;
1964     esac
1965     case " $ac_configure_args " in
1966       *" '$ac_arg' "*) ;; # Avoid dups.  Use of quotes ensures accuracy.
1967       *) ac_configure_args="$ac_configure_args '$ac_arg'" ;;
1968     esac
1969   fi
1970 done
1971 if $ac_cache_corrupted; then
1972   { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
1973 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
1974   { $as_echo "$as_me:$LINENO: error: changes in the environment can compromise the build" >&5
1975 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;}
1976   { { $as_echo "$as_me:$LINENO: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&5
1977 $as_echo "$as_me: error: run \`make distclean' and/or \`rm $cache_file' and start over" >&2;}
1978    { (exit 1); exit 1; }; }
1979 fi
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005 ac_ext=c
2006 ac_cpp='$CPP $CPPFLAGS'
2007 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
2008 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
2009 ac_compiler_gnu=$ac_cv_c_compiler_gnu
2010
2011
2012
2013
2014
2015
2016 ac_aux_dir=
2017 for ac_dir in config "$srcdir"/config; do
2018   if test -f "$ac_dir/install-sh"; then
2019     ac_aux_dir=$ac_dir
2020     ac_install_sh="$ac_aux_dir/install-sh -c"
2021     break
2022   elif test -f "$ac_dir/install.sh"; then
2023     ac_aux_dir=$ac_dir
2024     ac_install_sh="$ac_aux_dir/install.sh -c"
2025     break
2026   elif test -f "$ac_dir/shtool"; then
2027     ac_aux_dir=$ac_dir
2028     ac_install_sh="$ac_aux_dir/shtool install -c"
2029     break
2030   fi
2031 done
2032 if test -z "$ac_aux_dir"; then
2033   { { $as_echo "$as_me:$LINENO: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&5
2034 $as_echo "$as_me: error: cannot find install-sh or install.sh in config \"$srcdir\"/config" >&2;}
2035    { (exit 1); exit 1; }; }
2036 fi
2037
2038 # These three variables are undocumented and unsupported,
2039 # and are intended to be withdrawn in a future Autoconf release.
2040 # They can cause serious problems if a builder's source tree is in a directory
2041 # whose full name contains unusual characters.
2042 ac_config_guess="$SHELL $ac_aux_dir/config.guess"  # Please don't use this var.
2043 ac_config_sub="$SHELL $ac_aux_dir/config.sub"  # Please don't use this var.
2044 ac_configure="$SHELL $ac_aux_dir/configure"  # Please don't use this var.
2045
2046
2047
2048 configure_args=$ac_configure_args
2049
2050
2051
2052 cat >>confdefs.h <<_ACEOF
2053 #define PG_VERSION "$PACKAGE_VERSION"
2054 _ACEOF
2055
2056 PG_MAJORVERSION=`expr "$PACKAGE_VERSION" : '\([0-9][0-9]*\.[0-9][0-9]*\)'`
2057
2058
2059 cat >>confdefs.h <<_ACEOF
2060 #define PG_MAJORVERSION "$PG_MAJORVERSION"
2061 _ACEOF
2062
2063
2064 # Make sure we can run config.sub.
2065 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 ||
2066   { { $as_echo "$as_me:$LINENO: error: cannot run $SHELL $ac_aux_dir/config.sub" >&5
2067 $as_echo "$as_me: error: cannot run $SHELL $ac_aux_dir/config.sub" >&2;}
2068    { (exit 1); exit 1; }; }
2069
2070 { $as_echo "$as_me:$LINENO: checking build system type" >&5
2071 $as_echo_n "checking build system type... " >&6; }
2072 if test "${ac_cv_build+set}" = set; then
2073   $as_echo_n "(cached) " >&6
2074 else
2075   ac_build_alias=$build_alias
2076 test "x$ac_build_alias" = x &&
2077   ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"`
2078 test "x$ac_build_alias" = x &&
2079   { { $as_echo "$as_me:$LINENO: error: cannot guess build type; you must specify one" >&5
2080 $as_echo "$as_me: error: cannot guess build type; you must specify one" >&2;}
2081    { (exit 1); exit 1; }; }
2082 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` ||
2083   { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&5
2084 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $ac_build_alias failed" >&2;}
2085    { (exit 1); exit 1; }; }
2086
2087 fi
2088 { $as_echo "$as_me:$LINENO: result: $ac_cv_build" >&5
2089 $as_echo "$ac_cv_build" >&6; }
2090 case $ac_cv_build in
2091 *-*-*) ;;
2092 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical build" >&5
2093 $as_echo "$as_me: error: invalid value of canonical build" >&2;}
2094    { (exit 1); exit 1; }; };;
2095 esac
2096 build=$ac_cv_build
2097 ac_save_IFS=$IFS; IFS='-'
2098 set x $ac_cv_build
2099 shift
2100 build_cpu=$1
2101 build_vendor=$2
2102 shift; shift
2103 # Remember, the first character of IFS is used to create $*,
2104 # except with old shells:
2105 build_os=$*
2106 IFS=$ac_save_IFS
2107 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac
2108
2109
2110 { $as_echo "$as_me:$LINENO: checking host system type" >&5
2111 $as_echo_n "checking host system type... " >&6; }
2112 if test "${ac_cv_host+set}" = set; then
2113   $as_echo_n "(cached) " >&6
2114 else
2115   if test "x$host_alias" = x; then
2116   ac_cv_host=$ac_cv_build
2117 else
2118   ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` ||
2119     { { $as_echo "$as_me:$LINENO: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&5
2120 $as_echo "$as_me: error: $SHELL $ac_aux_dir/config.sub $host_alias failed" >&2;}
2121    { (exit 1); exit 1; }; }
2122 fi
2123
2124 fi
2125 { $as_echo "$as_me:$LINENO: result: $ac_cv_host" >&5
2126 $as_echo "$ac_cv_host" >&6; }
2127 case $ac_cv_host in
2128 *-*-*) ;;
2129 *) { { $as_echo "$as_me:$LINENO: error: invalid value of canonical host" >&5
2130 $as_echo "$as_me: error: invalid value of canonical host" >&2;}
2131    { (exit 1); exit 1; }; };;
2132 esac
2133 host=$ac_cv_host
2134 ac_save_IFS=$IFS; IFS='-'
2135 set x $ac_cv_host
2136 shift
2137 host_cpu=$1
2138 host_vendor=$2
2139 shift; shift
2140 # Remember, the first character of IFS is used to create $*,
2141 # except with old shells:
2142 host_os=$*
2143 IFS=$ac_save_IFS
2144 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac
2145
2146
2147
2148 template=
2149 { $as_echo "$as_me:$LINENO: checking which template to use" >&5
2150 $as_echo_n "checking which template to use... " >&6; }
2151
2152
2153
2154
2155 # Check whether --with-template was given.
2156 if test "${with_template+set}" = set; then
2157   withval=$with_template;
2158   case $withval in
2159     yes)
2160       { { $as_echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
2161 $as_echo "$as_me: error: argument required for --with-template option" >&2;}
2162    { (exit 1); exit 1; }; }
2163       ;;
2164     no)
2165       { { $as_echo "$as_me:$LINENO: error: argument required for --with-template option" >&5
2166 $as_echo "$as_me: error: argument required for --with-template option" >&2;}
2167    { (exit 1); exit 1; }; }
2168       ;;
2169     *)
2170
2171   case $withval in
2172     list)   echo; ls "$srcdir/src/template"; exit;;
2173     *)      if test -f "$srcdir/src/template/$with_template" ; then
2174               template=$withval
2175             else
2176               { { $as_echo "$as_me:$LINENO: error: '$withval' is not a valid template name. Use 'list' for a list." >&5
2177 $as_echo "$as_me: error: '$withval' is not a valid template name. Use 'list' for a list." >&2;}
2178    { (exit 1); exit 1; }; }
2179             fi;;
2180   esac
2181
2182       ;;
2183   esac
2184
2185 else
2186
2187 # --with-template not given
2188
2189 case $host_os in
2190      aix*) template=aix ;;
2191     bsdi*) template=bsdi ;;
2192   cygwin*) template=cygwin ;;
2193   darwin*) template=darwin ;;
2194     dgux*) template=dgux ;;
2195  freebsd*) template=freebsd ;;
2196     hpux*) template=hpux ;;
2197     irix*) template=irix ;;
2198  linux*|gnu*|k*bsd*-gnu)
2199            template=linux ;;
2200    mingw*) template=win32 ;;
2201   netbsd*) template=netbsd ;;
2202 nextstep*) template=nextstep ;;
2203  openbsd*) template=openbsd ;;
2204      osf*) template=osf ;;
2205      sco*) template=sco ;;
2206  solaris*) template=solaris ;;
2207    sunos*) template=sunos4 ;;
2208  sysv4.2*)
2209         case $host_vendor in
2210           univel) template=univel ;;
2211         esac ;;
2212    sysv4*) template=svr4 ;;
2213    sysv5*) template=unixware ;;
2214   ultrix*) template=ultrix4 ;;
2215 esac
2216
2217   if test x"$template" = x"" ; then
2218     { { $as_echo "$as_me:$LINENO: error:
2219 *******************************************************************
2220 PostgreSQL has apparently not been ported to your platform yet.
2221 To try a manual configuration, look into the src/template directory
2222 for a similar platform and use the '--with-template=' option.
2223
2224 Please also contact <pgsql-bugs@postgresql.org> to see about
2225 rectifying this.  Include the above 'checking host system type...'
2226 line.
2227 *******************************************************************
2228 " >&5
2229 $as_echo "$as_me: error:
2230 *******************************************************************
2231 PostgreSQL has apparently not been ported to your platform yet.
2232 To try a manual configuration, look into the src/template directory
2233 for a similar platform and use the '--with-template=' option.
2234
2235 Please also contact <pgsql-bugs@postgresql.org> to see about
2236 rectifying this.  Include the above 'checking host system type...'
2237 line.
2238 *******************************************************************
2239 " >&2;}
2240    { (exit 1); exit 1; }; }
2241   fi
2242
2243
2244 fi
2245
2246
2247
2248 { $as_echo "$as_me:$LINENO: result: $template" >&5
2249 $as_echo "$template" >&6; }
2250
2251 PORTNAME=$template
2252
2253
2254 # Initialize default assumption that we do not need separate assembly code
2255 # for TAS (test-and-set).  This can be overridden by the template file
2256 # when it's executed.
2257 need_tas=no
2258 tas_file=dummy.s
2259
2260
2261
2262 ##
2263 ## Command line options
2264 ##
2265
2266 #
2267 # Add non-standard directories to the include path
2268 #
2269
2270
2271
2272 # Check whether --with-includes was given.
2273 if test "${with_includes+set}" = set; then
2274   withval=$with_includes;
2275   case $withval in
2276     yes)
2277       { { $as_echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2278 $as_echo "$as_me: error: argument required for --with-includes option" >&2;}
2279    { (exit 1); exit 1; }; }
2280       ;;
2281     no)
2282       { { $as_echo "$as_me:$LINENO: error: argument required for --with-includes option" >&5
2283 $as_echo "$as_me: error: argument required for --with-includes option" >&2;}
2284    { (exit 1); exit 1; }; }
2285       ;;
2286     *)
2287
2288       ;;
2289   esac
2290
2291 fi
2292
2293
2294
2295
2296 #
2297 # Add non-standard directories to the library search path
2298 #
2299
2300
2301
2302 # Check whether --with-libraries was given.
2303 if test "${with_libraries+set}" = set; then
2304   withval=$with_libraries;
2305   case $withval in
2306     yes)
2307       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2308 $as_echo "$as_me: error: argument required for --with-libraries option" >&2;}
2309    { (exit 1); exit 1; }; }
2310       ;;
2311     no)
2312       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libraries option" >&5
2313 $as_echo "$as_me: error: argument required for --with-libraries option" >&2;}
2314    { (exit 1); exit 1; }; }
2315       ;;
2316     *)
2317       LIBRARY_DIRS=$withval
2318       ;;
2319   esac
2320
2321 fi
2322
2323
2324
2325
2326
2327
2328 # Check whether --with-libs was given.
2329 if test "${with_libs+set}" = set; then
2330   withval=$with_libs;
2331   case $withval in
2332     yes)
2333       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2334 $as_echo "$as_me: error: argument required for --with-libs option" >&2;}
2335    { (exit 1); exit 1; }; }
2336       ;;
2337     no)
2338       { { $as_echo "$as_me:$LINENO: error: argument required for --with-libs option" >&5
2339 $as_echo "$as_me: error: argument required for --with-libs option" >&2;}
2340    { (exit 1); exit 1; }; }
2341       ;;
2342     *)
2343       LIBRARY_DIRS=$withval
2344       ;;
2345   esac
2346
2347 fi
2348
2349
2350
2351
2352 #
2353 # 64-bit integer date/time storage: enabled by default.
2354 #
2355 { $as_echo "$as_me:$LINENO: checking whether to build with 64-bit integer date/time support" >&5
2356 $as_echo_n "checking whether to build with 64-bit integer date/time support... " >&6; }
2357
2358
2359 # Check whether --enable-integer-datetimes was given.
2360 if test "${enable_integer_datetimes+set}" = set; then
2361   enableval=$enable_integer_datetimes;
2362   case $enableval in
2363     yes)
2364
2365 cat >>confdefs.h <<\_ACEOF
2366 #define USE_INTEGER_DATETIMES 1
2367 _ACEOF
2368
2369       ;;
2370     no)
2371       :
2372       ;;
2373     *)
2374       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-integer-datetimes option" >&5
2375 $as_echo "$as_me: error: no argument expected for --enable-integer-datetimes option" >&2;}
2376    { (exit 1); exit 1; }; }
2377       ;;
2378   esac
2379
2380 else
2381   enable_integer_datetimes=yes
2382
2383 cat >>confdefs.h <<\_ACEOF
2384 #define USE_INTEGER_DATETIMES 1
2385 _ACEOF
2386
2387 fi
2388
2389
2390 { $as_echo "$as_me:$LINENO: result: $enable_integer_datetimes" >&5
2391 $as_echo "$enable_integer_datetimes" >&6; }
2392
2393
2394 #
2395 # NLS
2396 #
2397 { $as_echo "$as_me:$LINENO: checking whether NLS is wanted" >&5
2398 $as_echo_n "checking whether NLS is wanted... " >&6; }
2399
2400
2401 # Check whether --enable-nls was given.
2402 if test "${enable_nls+set}" = set; then
2403   enableval=$enable_nls;
2404   case $enableval in
2405     yes)
2406       :
2407       ;;
2408     no)
2409       :
2410       ;;
2411     *)
2412       enable_nls=yes
2413 WANTED_LANGUAGES=$enableval
2414       ;;
2415   esac
2416
2417 else
2418   enable_nls=no
2419 fi
2420
2421
2422
2423 if test "$enable_nls" = yes; then
2424
2425 cat >>confdefs.h <<\_ACEOF
2426 #define ENABLE_NLS 1
2427 _ACEOF
2428
2429 fi
2430
2431 { $as_echo "$as_me:$LINENO: result: $enable_nls" >&5
2432 $as_echo "$enable_nls" >&6; }
2433
2434
2435
2436 #
2437 # Default port number (--with-pgport), default 5432
2438 #
2439 { $as_echo "$as_me:$LINENO: checking for default port number" >&5
2440 $as_echo_n "checking for default port number... " >&6; }
2441
2442
2443
2444 # Check whether --with-pgport was given.
2445 if test "${with_pgport+set}" = set; then
2446   withval=$with_pgport;
2447   case $withval in
2448     yes)
2449       { { $as_echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2450 $as_echo "$as_me: error: argument required for --with-pgport option" >&2;}
2451    { (exit 1); exit 1; }; }
2452       ;;
2453     no)
2454       { { $as_echo "$as_me:$LINENO: error: argument required for --with-pgport option" >&5
2455 $as_echo "$as_me: error: argument required for --with-pgport option" >&2;}
2456    { (exit 1); exit 1; }; }
2457       ;;
2458     *)
2459       default_port=$withval
2460       ;;
2461   esac
2462
2463 else
2464   default_port=5432
2465 fi
2466
2467
2468 { $as_echo "$as_me:$LINENO: result: $default_port" >&5
2469 $as_echo "$default_port" >&6; }
2470 # Need both of these because some places want an integer and some a string
2471
2472 cat >>confdefs.h <<_ACEOF
2473 #define DEF_PGPORT ${default_port}
2474 _ACEOF
2475
2476
2477 cat >>confdefs.h <<_ACEOF
2478 #define DEF_PGPORT_STR "${default_port}"
2479 _ACEOF
2480
2481
2482
2483 #
2484 # Option to disable shared libraries
2485 #
2486
2487
2488 # Check whether --enable-shared was given.
2489 if test "${enable_shared+set}" = set; then
2490   enableval=$enable_shared;
2491   case $enableval in
2492     yes)
2493       :
2494       ;;
2495     no)
2496       :
2497       ;;
2498     *)
2499       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-shared option" >&5
2500 $as_echo "$as_me: error: no argument expected for --enable-shared option" >&2;}
2501    { (exit 1); exit 1; }; }
2502       ;;
2503   esac
2504
2505 else
2506   enable_shared=yes
2507
2508 fi
2509
2510
2511
2512
2513 #
2514 # '-rpath'-like feature can be disabled
2515 #
2516
2517
2518 # Check whether --enable-rpath was given.
2519 if test "${enable_rpath+set}" = set; then
2520   enableval=$enable_rpath;
2521   case $enableval in
2522     yes)
2523       :
2524       ;;
2525     no)
2526       :
2527       ;;
2528     *)
2529       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-rpath option" >&5
2530 $as_echo "$as_me: error: no argument expected for --enable-rpath option" >&2;}
2531    { (exit 1); exit 1; }; }
2532       ;;
2533   esac
2534
2535 else
2536   enable_rpath=yes
2537
2538 fi
2539
2540
2541
2542
2543 #
2544 # Spinlocks
2545 #
2546
2547
2548 # Check whether --enable-spinlocks was given.
2549 if test "${enable_spinlocks+set}" = set; then
2550   enableval=$enable_spinlocks;
2551   case $enableval in
2552     yes)
2553       :
2554       ;;
2555     no)
2556       :
2557       ;;
2558     *)
2559       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-spinlocks option" >&5
2560 $as_echo "$as_me: error: no argument expected for --enable-spinlocks option" >&2;}
2561    { (exit 1); exit 1; }; }
2562       ;;
2563   esac
2564
2565 else
2566   enable_spinlocks=yes
2567
2568 fi
2569
2570
2571
2572 #
2573 # --enable-debug adds -g to compiler flags
2574 #
2575
2576
2577 # Check whether --enable-debug was given.
2578 if test "${enable_debug+set}" = set; then
2579   enableval=$enable_debug;
2580   case $enableval in
2581     yes)
2582       :
2583       ;;
2584     no)
2585       :
2586       ;;
2587     *)
2588       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-debug option" >&5
2589 $as_echo "$as_me: error: no argument expected for --enable-debug option" >&2;}
2590    { (exit 1); exit 1; }; }
2591       ;;
2592   esac
2593
2594 else
2595   enable_debug=no
2596
2597 fi
2598
2599
2600
2601
2602 #
2603 # --enable-profiling enables gcc profiling
2604 #
2605
2606
2607 # Check whether --enable-profiling was given.
2608 if test "${enable_profiling+set}" = set; then
2609   enableval=$enable_profiling;
2610   case $enableval in
2611     yes)
2612       :
2613       ;;
2614     no)
2615       :
2616       ;;
2617     *)
2618       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-profiling option" >&5
2619 $as_echo "$as_me: error: no argument expected for --enable-profiling option" >&2;}
2620    { (exit 1); exit 1; }; }
2621       ;;
2622   esac
2623
2624 else
2625   enable_profiling=no
2626
2627 fi
2628
2629
2630
2631
2632 #
2633 # --enable-coverage enables generation of code coverage metrics with gcov
2634 #
2635
2636
2637 # Check whether --enable-coverage was given.
2638 if test "${enable_coverage+set}" = set; then
2639   enableval=$enable_coverage;
2640   case $enableval in
2641     yes)
2642       for ac_prog in gcov
2643 do
2644   # Extract the first word of "$ac_prog", so it can be a program name with args.
2645 set dummy $ac_prog; ac_word=$2
2646 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2647 $as_echo_n "checking for $ac_word... " >&6; }
2648 if test "${ac_cv_prog_GCOV+set}" = set; then
2649   $as_echo_n "(cached) " >&6
2650 else
2651   if test -n "$GCOV"; then
2652   ac_cv_prog_GCOV="$GCOV" # Let the user override the test.
2653 else
2654 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2655 for as_dir in $PATH
2656 do
2657   IFS=$as_save_IFS
2658   test -z "$as_dir" && as_dir=.
2659   for ac_exec_ext in '' $ac_executable_extensions; do
2660   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2661     ac_cv_prog_GCOV="$ac_prog"
2662     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2663     break 2
2664   fi
2665 done
2666 done
2667 IFS=$as_save_IFS
2668
2669 fi
2670 fi
2671 GCOV=$ac_cv_prog_GCOV
2672 if test -n "$GCOV"; then
2673   { $as_echo "$as_me:$LINENO: result: $GCOV" >&5
2674 $as_echo "$GCOV" >&6; }
2675 else
2676   { $as_echo "$as_me:$LINENO: result: no" >&5
2677 $as_echo "no" >&6; }
2678 fi
2679
2680
2681   test -n "$GCOV" && break
2682 done
2683
2684 if test -z "$GCOV"; then
2685   { { $as_echo "$as_me:$LINENO: error: gcov not found" >&5
2686 $as_echo "$as_me: error: gcov not found" >&2;}
2687    { (exit 1); exit 1; }; }
2688 fi
2689 for ac_prog in lcov
2690 do
2691   # Extract the first word of "$ac_prog", so it can be a program name with args.
2692 set dummy $ac_prog; ac_word=$2
2693 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2694 $as_echo_n "checking for $ac_word... " >&6; }
2695 if test "${ac_cv_prog_LCOV+set}" = set; then
2696   $as_echo_n "(cached) " >&6
2697 else
2698   if test -n "$LCOV"; then
2699   ac_cv_prog_LCOV="$LCOV" # Let the user override the test.
2700 else
2701 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2702 for as_dir in $PATH
2703 do
2704   IFS=$as_save_IFS
2705   test -z "$as_dir" && as_dir=.
2706   for ac_exec_ext in '' $ac_executable_extensions; do
2707   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2708     ac_cv_prog_LCOV="$ac_prog"
2709     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2710     break 2
2711   fi
2712 done
2713 done
2714 IFS=$as_save_IFS
2715
2716 fi
2717 fi
2718 LCOV=$ac_cv_prog_LCOV
2719 if test -n "$LCOV"; then
2720   { $as_echo "$as_me:$LINENO: result: $LCOV" >&5
2721 $as_echo "$LCOV" >&6; }
2722 else
2723   { $as_echo "$as_me:$LINENO: result: no" >&5
2724 $as_echo "no" >&6; }
2725 fi
2726
2727
2728   test -n "$LCOV" && break
2729 done
2730
2731 if test -z "$LCOV"; then
2732   { { $as_echo "$as_me:$LINENO: error: lcov not found" >&5
2733 $as_echo "$as_me: error: lcov not found" >&2;}
2734    { (exit 1); exit 1; }; }
2735 fi
2736 for ac_prog in genhtml
2737 do
2738   # Extract the first word of "$ac_prog", so it can be a program name with args.
2739 set dummy $ac_prog; ac_word=$2
2740 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2741 $as_echo_n "checking for $ac_word... " >&6; }
2742 if test "${ac_cv_prog_GENHTML+set}" = set; then
2743   $as_echo_n "(cached) " >&6
2744 else
2745   if test -n "$GENHTML"; then
2746   ac_cv_prog_GENHTML="$GENHTML" # Let the user override the test.
2747 else
2748 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2749 for as_dir in $PATH
2750 do
2751   IFS=$as_save_IFS
2752   test -z "$as_dir" && as_dir=.
2753   for ac_exec_ext in '' $ac_executable_extensions; do
2754   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2755     ac_cv_prog_GENHTML="$ac_prog"
2756     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2757     break 2
2758   fi
2759 done
2760 done
2761 IFS=$as_save_IFS
2762
2763 fi
2764 fi
2765 GENHTML=$ac_cv_prog_GENHTML
2766 if test -n "$GENHTML"; then
2767   { $as_echo "$as_me:$LINENO: result: $GENHTML" >&5
2768 $as_echo "$GENHTML" >&6; }
2769 else
2770   { $as_echo "$as_me:$LINENO: result: no" >&5
2771 $as_echo "no" >&6; }
2772 fi
2773
2774
2775   test -n "$GENHTML" && break
2776 done
2777
2778 if test -z "$GENHTML"; then
2779   { { $as_echo "$as_me:$LINENO: error: genhtml not found" >&5
2780 $as_echo "$as_me: error: genhtml not found" >&2;}
2781    { (exit 1); exit 1; }; }
2782 fi
2783       ;;
2784     no)
2785       :
2786       ;;
2787     *)
2788       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-coverage option" >&5
2789 $as_echo "$as_me: error: no argument expected for --enable-coverage option" >&2;}
2790    { (exit 1); exit 1; }; }
2791       ;;
2792   esac
2793
2794 else
2795   enable_coverage=no
2796
2797 fi
2798
2799
2800
2801
2802 #
2803 # DTrace
2804 #
2805
2806
2807 # Check whether --enable-dtrace was given.
2808 if test "${enable_dtrace+set}" = set; then
2809   enableval=$enable_dtrace;
2810   case $enableval in
2811     yes)
2812
2813 cat >>confdefs.h <<\_ACEOF
2814 #define ENABLE_DTRACE 1
2815 _ACEOF
2816
2817 for ac_prog in dtrace
2818 do
2819   # Extract the first word of "$ac_prog", so it can be a program name with args.
2820 set dummy $ac_prog; ac_word=$2
2821 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
2822 $as_echo_n "checking for $ac_word... " >&6; }
2823 if test "${ac_cv_prog_DTRACE+set}" = set; then
2824   $as_echo_n "(cached) " >&6
2825 else
2826   if test -n "$DTRACE"; then
2827   ac_cv_prog_DTRACE="$DTRACE" # Let the user override the test.
2828 else
2829 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
2830 for as_dir in $PATH
2831 do
2832   IFS=$as_save_IFS
2833   test -z "$as_dir" && as_dir=.
2834   for ac_exec_ext in '' $ac_executable_extensions; do
2835   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
2836     ac_cv_prog_DTRACE="$ac_prog"
2837     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
2838     break 2
2839   fi
2840 done
2841 done
2842 IFS=$as_save_IFS
2843
2844 fi
2845 fi
2846 DTRACE=$ac_cv_prog_DTRACE
2847 if test -n "$DTRACE"; then
2848   { $as_echo "$as_me:$LINENO: result: $DTRACE" >&5
2849 $as_echo "$DTRACE" >&6; }
2850 else
2851   { $as_echo "$as_me:$LINENO: result: no" >&5
2852 $as_echo "no" >&6; }
2853 fi
2854
2855
2856   test -n "$DTRACE" && break
2857 done
2858
2859 if test -z "$DTRACE"; then
2860   { { $as_echo "$as_me:$LINENO: error: dtrace not found" >&5
2861 $as_echo "$as_me: error: dtrace not found" >&2;}
2862    { (exit 1); exit 1; }; }
2863 fi
2864
2865       ;;
2866     no)
2867       :
2868       ;;
2869     *)
2870       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-dtrace option" >&5
2871 $as_echo "$as_me: error: no argument expected for --enable-dtrace option" >&2;}
2872    { (exit 1); exit 1; }; }
2873       ;;
2874   esac
2875
2876 else
2877   enable_dtrace=no
2878
2879 fi
2880
2881
2882
2883
2884 #
2885 # Block size
2886 #
2887 { $as_echo "$as_me:$LINENO: checking for block size" >&5
2888 $as_echo_n "checking for block size... " >&6; }
2889
2890
2891
2892 # Check whether --with-blocksize was given.
2893 if test "${with_blocksize+set}" = set; then
2894   withval=$with_blocksize;
2895   case $withval in
2896     yes)
2897       { { $as_echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2898 $as_echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2899    { (exit 1); exit 1; }; }
2900       ;;
2901     no)
2902       { { $as_echo "$as_me:$LINENO: error: argument required for --with-blocksize option" >&5
2903 $as_echo "$as_me: error: argument required for --with-blocksize option" >&2;}
2904    { (exit 1); exit 1; }; }
2905       ;;
2906     *)
2907       blocksize=$withval
2908       ;;
2909   esac
2910
2911 else
2912   blocksize=8
2913 fi
2914
2915
2916 case ${blocksize} in
2917   1) BLCKSZ=1024;;
2918   2) BLCKSZ=2048;;
2919   4) BLCKSZ=4096;;
2920   8) BLCKSZ=8192;;
2921  16) BLCKSZ=16384;;
2922  32) BLCKSZ=32768;;
2923   *) { { $as_echo "$as_me:$LINENO: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&5
2924 $as_echo "$as_me: error: Invalid block size. Allowed values are 1,2,4,8,16,32." >&2;}
2925    { (exit 1); exit 1; }; }
2926 esac
2927 { $as_echo "$as_me:$LINENO: result: ${blocksize}kB" >&5
2928 $as_echo "${blocksize}kB" >&6; }
2929
2930
2931 cat >>confdefs.h <<_ACEOF
2932 #define BLCKSZ ${BLCKSZ}
2933 _ACEOF
2934
2935
2936 #
2937 # Relation segment size
2938 #
2939 { $as_echo "$as_me:$LINENO: checking for segment size" >&5
2940 $as_echo_n "checking for segment size... " >&6; }
2941
2942
2943
2944 # Check whether --with-segsize was given.
2945 if test "${with_segsize+set}" = set; then
2946   withval=$with_segsize;
2947   case $withval in
2948     yes)
2949       { { $as_echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2950 $as_echo "$as_me: error: argument required for --with-segsize option" >&2;}
2951    { (exit 1); exit 1; }; }
2952       ;;
2953     no)
2954       { { $as_echo "$as_me:$LINENO: error: argument required for --with-segsize option" >&5
2955 $as_echo "$as_me: error: argument required for --with-segsize option" >&2;}
2956    { (exit 1); exit 1; }; }
2957       ;;
2958     *)
2959       segsize=$withval
2960       ;;
2961   esac
2962
2963 else
2964   segsize=1
2965 fi
2966
2967
2968 # this expression is set up to avoid unnecessary integer overflow
2969 # blocksize is already guaranteed to be a factor of 1024
2970 RELSEG_SIZE=`expr '(' 1024 / ${blocksize} ')' '*' ${segsize} '*' 1024`
2971 test $? -eq 0 || exit 1
2972 { $as_echo "$as_me:$LINENO: result: ${segsize}GB" >&5
2973 $as_echo "${segsize}GB" >&6; }
2974
2975
2976 cat >>confdefs.h <<_ACEOF
2977 #define RELSEG_SIZE ${RELSEG_SIZE}
2978 _ACEOF
2979
2980
2981 #
2982 # WAL block size
2983 #
2984 { $as_echo "$as_me:$LINENO: checking for WAL block size" >&5
2985 $as_echo_n "checking for WAL block size... " >&6; }
2986
2987
2988
2989 # Check whether --with-wal-blocksize was given.
2990 if test "${with_wal_blocksize+set}" = set; then
2991   withval=$with_wal_blocksize;
2992   case $withval in
2993     yes)
2994       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
2995 $as_echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
2996    { (exit 1); exit 1; }; }
2997       ;;
2998     no)
2999       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-blocksize option" >&5
3000 $as_echo "$as_me: error: argument required for --with-wal-blocksize option" >&2;}
3001    { (exit 1); exit 1; }; }
3002       ;;
3003     *)
3004       wal_blocksize=$withval
3005       ;;
3006   esac
3007
3008 else
3009   wal_blocksize=8
3010 fi
3011
3012
3013 case ${wal_blocksize} in
3014   1) XLOG_BLCKSZ=1024;;
3015   2) XLOG_BLCKSZ=2048;;
3016   4) XLOG_BLCKSZ=4096;;
3017   8) XLOG_BLCKSZ=8192;;
3018  16) XLOG_BLCKSZ=16384;;
3019  32) XLOG_BLCKSZ=32768;;
3020  64) XLOG_BLCKSZ=65536;;
3021   *) { { $as_echo "$as_me:$LINENO: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&5
3022 $as_echo "$as_me: error: Invalid WAL block size. Allowed values are 1,2,4,8,16,32,64." >&2;}
3023    { (exit 1); exit 1; }; }
3024 esac
3025 { $as_echo "$as_me:$LINENO: result: ${wal_blocksize}kB" >&5
3026 $as_echo "${wal_blocksize}kB" >&6; }
3027
3028
3029 cat >>confdefs.h <<_ACEOF
3030 #define XLOG_BLCKSZ ${XLOG_BLCKSZ}
3031 _ACEOF
3032
3033
3034 #
3035 # WAL segment size
3036 #
3037 { $as_echo "$as_me:$LINENO: checking for WAL segment size" >&5
3038 $as_echo_n "checking for WAL segment size... " >&6; }
3039
3040
3041
3042 # Check whether --with-wal-segsize was given.
3043 if test "${with_wal_segsize+set}" = set; then
3044   withval=$with_wal_segsize;
3045   case $withval in
3046     yes)
3047       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
3048 $as_echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
3049    { (exit 1); exit 1; }; }
3050       ;;
3051     no)
3052       { { $as_echo "$as_me:$LINENO: error: argument required for --with-wal-segsize option" >&5
3053 $as_echo "$as_me: error: argument required for --with-wal-segsize option" >&2;}
3054    { (exit 1); exit 1; }; }
3055       ;;
3056     *)
3057       wal_segsize=$withval
3058       ;;
3059   esac
3060
3061 else
3062   wal_segsize=16
3063 fi
3064
3065
3066 case ${wal_segsize} in
3067   1) ;;
3068   2) ;;
3069   4) ;;
3070   8) ;;
3071  16) ;;
3072  32) ;;
3073  64) ;;
3074   *) { { $as_echo "$as_me:$LINENO: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&5
3075 $as_echo "$as_me: error: Invalid WAL segment size. Allowed values are 1,2,4,8,16,32,64." >&2;}
3076    { (exit 1); exit 1; }; }
3077 esac
3078 { $as_echo "$as_me:$LINENO: result: ${wal_segsize}MB" >&5
3079 $as_echo "${wal_segsize}MB" >&6; }
3080
3081
3082 cat >>confdefs.h <<_ACEOF
3083 #define XLOG_SEG_SIZE (${wal_segsize} * 1024 * 1024)
3084 _ACEOF
3085
3086
3087 #
3088 # C compiler
3089 #
3090
3091 # For historical reasons you can also use --with-CC to specify the C compiler
3092 # to use, although the standard way to do this is to set the CC environment
3093 # variable.
3094
3095
3096
3097 # Check whether --with-CC was given.
3098 if test "${with_CC+set}" = set; then
3099   withval=$with_CC;
3100   case $withval in
3101     yes)
3102       { { $as_echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
3103 $as_echo "$as_me: error: argument required for --with-CC option" >&2;}
3104    { (exit 1); exit 1; }; }
3105       ;;
3106     no)
3107       { { $as_echo "$as_me:$LINENO: error: argument required for --with-CC option" >&5
3108 $as_echo "$as_me: error: argument required for --with-CC option" >&2;}
3109    { (exit 1); exit 1; }; }
3110       ;;
3111     *)
3112       CC=$with_CC
3113       ;;
3114   esac
3115
3116 fi
3117
3118
3119
3120 case $template in
3121   aix) pgac_cc_list="gcc xlc";;
3122  irix) pgac_cc_list="cc";; # no gcc
3123     *) pgac_cc_list="gcc cc";;
3124 esac
3125
3126 ac_ext=c
3127 ac_cpp='$CPP $CPPFLAGS'
3128 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3129 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3130 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3131 if test -n "$ac_tool_prefix"; then
3132   for ac_prog in $pgac_cc_list
3133   do
3134     # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args.
3135 set dummy $ac_tool_prefix$ac_prog; ac_word=$2
3136 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3137 $as_echo_n "checking for $ac_word... " >&6; }
3138 if test "${ac_cv_prog_CC+set}" = set; then
3139   $as_echo_n "(cached) " >&6
3140 else
3141   if test -n "$CC"; then
3142   ac_cv_prog_CC="$CC" # Let the user override the test.
3143 else
3144 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3145 for as_dir in $PATH
3146 do
3147   IFS=$as_save_IFS
3148   test -z "$as_dir" && as_dir=.
3149   for ac_exec_ext in '' $ac_executable_extensions; do
3150   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3151     ac_cv_prog_CC="$ac_tool_prefix$ac_prog"
3152     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3153     break 2
3154   fi
3155 done
3156 done
3157 IFS=$as_save_IFS
3158
3159 fi
3160 fi
3161 CC=$ac_cv_prog_CC
3162 if test -n "$CC"; then
3163   { $as_echo "$as_me:$LINENO: result: $CC" >&5
3164 $as_echo "$CC" >&6; }
3165 else
3166   { $as_echo "$as_me:$LINENO: result: no" >&5
3167 $as_echo "no" >&6; }
3168 fi
3169
3170
3171     test -n "$CC" && break
3172   done
3173 fi
3174 if test -z "$CC"; then
3175   ac_ct_CC=$CC
3176   for ac_prog in $pgac_cc_list
3177 do
3178   # Extract the first word of "$ac_prog", so it can be a program name with args.
3179 set dummy $ac_prog; ac_word=$2
3180 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
3181 $as_echo_n "checking for $ac_word... " >&6; }
3182 if test "${ac_cv_prog_ac_ct_CC+set}" = set; then
3183   $as_echo_n "(cached) " >&6
3184 else
3185   if test -n "$ac_ct_CC"; then
3186   ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test.
3187 else
3188 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
3189 for as_dir in $PATH
3190 do
3191   IFS=$as_save_IFS
3192   test -z "$as_dir" && as_dir=.
3193   for ac_exec_ext in '' $ac_executable_extensions; do
3194   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
3195     ac_cv_prog_ac_ct_CC="$ac_prog"
3196     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
3197     break 2
3198   fi
3199 done
3200 done
3201 IFS=$as_save_IFS
3202
3203 fi
3204 fi
3205 ac_ct_CC=$ac_cv_prog_ac_ct_CC
3206 if test -n "$ac_ct_CC"; then
3207   { $as_echo "$as_me:$LINENO: result: $ac_ct_CC" >&5
3208 $as_echo "$ac_ct_CC" >&6; }
3209 else
3210   { $as_echo "$as_me:$LINENO: result: no" >&5
3211 $as_echo "no" >&6; }
3212 fi
3213
3214
3215   test -n "$ac_ct_CC" && break
3216 done
3217
3218   if test "x$ac_ct_CC" = x; then
3219     CC=""
3220   else
3221     case $cross_compiling:$ac_tool_warned in
3222 yes:)
3223 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
3224 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
3225 ac_tool_warned=yes ;;
3226 esac
3227     CC=$ac_ct_CC
3228   fi
3229 fi
3230
3231
3232 test -z "$CC" && { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3233 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3234 { { $as_echo "$as_me:$LINENO: error: no acceptable C compiler found in \$PATH
3235 See \`config.log' for more details." >&5
3236 $as_echo "$as_me: error: no acceptable C compiler found in \$PATH
3237 See \`config.log' for more details." >&2;}
3238    { (exit 1); exit 1; }; }; }
3239
3240 # Provide some information about the compiler.
3241 $as_echo "$as_me:$LINENO: checking for C compiler version" >&5
3242 set X $ac_compile
3243 ac_compiler=$2
3244 { (ac_try="$ac_compiler --version >&5"
3245 case "(($ac_try" in
3246   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3247   *) ac_try_echo=$ac_try;;
3248 esac
3249 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3250 $as_echo "$ac_try_echo") >&5
3251   (eval "$ac_compiler --version >&5") 2>&5
3252   ac_status=$?
3253   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3254   (exit $ac_status); }
3255 { (ac_try="$ac_compiler -v >&5"
3256 case "(($ac_try" in
3257   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3258   *) ac_try_echo=$ac_try;;
3259 esac
3260 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3261 $as_echo "$ac_try_echo") >&5
3262   (eval "$ac_compiler -v >&5") 2>&5
3263   ac_status=$?
3264   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3265   (exit $ac_status); }
3266 { (ac_try="$ac_compiler -V >&5"
3267 case "(($ac_try" in
3268   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3269   *) ac_try_echo=$ac_try;;
3270 esac
3271 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3272 $as_echo "$ac_try_echo") >&5
3273   (eval "$ac_compiler -V >&5") 2>&5
3274   ac_status=$?
3275   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3276   (exit $ac_status); }
3277
3278 cat >conftest.$ac_ext <<_ACEOF
3279 /* confdefs.h.  */
3280 _ACEOF
3281 cat confdefs.h >>conftest.$ac_ext
3282 cat >>conftest.$ac_ext <<_ACEOF
3283 /* end confdefs.h.  */
3284
3285 int
3286 main ()
3287 {
3288
3289   ;
3290   return 0;
3291 }
3292 _ACEOF
3293 ac_clean_files_save=$ac_clean_files
3294 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out"
3295 # Try to create an executable without -o first, disregard a.out.
3296 # It will help us diagnose broken compilers, and finding out an intuition
3297 # of exeext.
3298 { $as_echo "$as_me:$LINENO: checking for C compiler default output file name" >&5
3299 $as_echo_n "checking for C compiler default output file name... " >&6; }
3300 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'`
3301
3302 # The possible output files:
3303 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*"
3304
3305 ac_rmfiles=
3306 for ac_file in $ac_files
3307 do
3308   case $ac_file in
3309     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3310     * ) ac_rmfiles="$ac_rmfiles $ac_file";;
3311   esac
3312 done
3313 rm -f $ac_rmfiles
3314
3315 if { (ac_try="$ac_link_default"
3316 case "(($ac_try" in
3317   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3318   *) ac_try_echo=$ac_try;;
3319 esac
3320 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3321 $as_echo "$ac_try_echo") >&5
3322   (eval "$ac_link_default") 2>&5
3323   ac_status=$?
3324   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3325   (exit $ac_status); }; then
3326   # Autoconf-2.13 could set the ac_cv_exeext variable to `no'.
3327 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no'
3328 # in a Makefile.  We should not override ac_cv_exeext if it was cached,
3329 # so that the user can short-circuit this test for compilers unknown to
3330 # Autoconf.
3331 for ac_file in $ac_files ''
3332 do
3333   test -f "$ac_file" || continue
3334   case $ac_file in
3335     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj )
3336         ;;
3337     [ab].out )
3338         # We found the default executable, but exeext='' is most
3339         # certainly right.
3340         break;;
3341     *.* )
3342         if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no;
3343         then :; else
3344            ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3345         fi
3346         # We set ac_cv_exeext here because the later test for it is not
3347         # safe: cross compilers may not add the suffix if given an `-o'
3348         # argument, so we may need to know it at that point already.
3349         # Even if this section looks crufty: it has the advantage of
3350         # actually working.
3351         break;;
3352     * )
3353         break;;
3354   esac
3355 done
3356 test "$ac_cv_exeext" = no && ac_cv_exeext=
3357
3358 else
3359   ac_file=''
3360 fi
3361
3362 { $as_echo "$as_me:$LINENO: result: $ac_file" >&5
3363 $as_echo "$ac_file" >&6; }
3364 if test -z "$ac_file"; then
3365   $as_echo "$as_me: failed program was:" >&5
3366 sed 's/^/| /' conftest.$ac_ext >&5
3367
3368 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3369 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3370 { { $as_echo "$as_me:$LINENO: error: C compiler cannot create executables
3371 See \`config.log' for more details." >&5
3372 $as_echo "$as_me: error: C compiler cannot create executables
3373 See \`config.log' for more details." >&2;}
3374    { (exit 77); exit 77; }; }; }
3375 fi
3376
3377 ac_exeext=$ac_cv_exeext
3378
3379 # Check that the compiler produces executables we can run.  If not, either
3380 # the compiler is broken, or we cross compile.
3381 { $as_echo "$as_me:$LINENO: checking whether the C compiler works" >&5
3382 $as_echo_n "checking whether the C compiler works... " >&6; }
3383 # FIXME: These cross compiler hacks should be removed for Autoconf 3.0
3384 # If not cross compiling, check that we can run a simple program.
3385 if test "$cross_compiling" != yes; then
3386   if { ac_try='./$ac_file'
3387   { (case "(($ac_try" in
3388   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3389   *) ac_try_echo=$ac_try;;
3390 esac
3391 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3392 $as_echo "$ac_try_echo") >&5
3393   (eval "$ac_try") 2>&5
3394   ac_status=$?
3395   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3396   (exit $ac_status); }; }; then
3397     cross_compiling=no
3398   else
3399     if test "$cross_compiling" = maybe; then
3400         cross_compiling=yes
3401     else
3402         { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3403 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3404 { { $as_echo "$as_me:$LINENO: error: cannot run C compiled programs.
3405 If you meant to cross compile, use \`--host'.
3406 See \`config.log' for more details." >&5
3407 $as_echo "$as_me: error: cannot run C compiled programs.
3408 If you meant to cross compile, use \`--host'.
3409 See \`config.log' for more details." >&2;}
3410    { (exit 1); exit 1; }; }; }
3411     fi
3412   fi
3413 fi
3414 { $as_echo "$as_me:$LINENO: result: yes" >&5
3415 $as_echo "yes" >&6; }
3416
3417 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out
3418 ac_clean_files=$ac_clean_files_save
3419 # Check that the compiler produces executables we can run.  If not, either
3420 # the compiler is broken, or we cross compile.
3421 { $as_echo "$as_me:$LINENO: checking whether we are cross compiling" >&5
3422 $as_echo_n "checking whether we are cross compiling... " >&6; }
3423 { $as_echo "$as_me:$LINENO: result: $cross_compiling" >&5
3424 $as_echo "$cross_compiling" >&6; }
3425
3426 { $as_echo "$as_me:$LINENO: checking for suffix of executables" >&5
3427 $as_echo_n "checking for suffix of executables... " >&6; }
3428 if { (ac_try="$ac_link"
3429 case "(($ac_try" in
3430   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3431   *) ac_try_echo=$ac_try;;
3432 esac
3433 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3434 $as_echo "$ac_try_echo") >&5
3435   (eval "$ac_link") 2>&5
3436   ac_status=$?
3437   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3438   (exit $ac_status); }; then
3439   # If both `conftest.exe' and `conftest' are `present' (well, observable)
3440 # catch `conftest.exe'.  For instance with Cygwin, `ls conftest' will
3441 # work properly (i.e., refer to `conftest.exe'), while it won't with
3442 # `rm'.
3443 for ac_file in conftest.exe conftest conftest.*; do
3444   test -f "$ac_file" || continue
3445   case $ac_file in
3446     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;;
3447     *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'`
3448           break;;
3449     * ) break;;
3450   esac
3451 done
3452 else
3453   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3454 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3455 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of executables: cannot compile and link
3456 See \`config.log' for more details." >&5
3457 $as_echo "$as_me: error: cannot compute suffix of executables: cannot compile and link
3458 See \`config.log' for more details." >&2;}
3459    { (exit 1); exit 1; }; }; }
3460 fi
3461
3462 rm -f conftest$ac_cv_exeext
3463 { $as_echo "$as_me:$LINENO: result: $ac_cv_exeext" >&5
3464 $as_echo "$ac_cv_exeext" >&6; }
3465
3466 rm -f conftest.$ac_ext
3467 EXEEXT=$ac_cv_exeext
3468 ac_exeext=$EXEEXT
3469 { $as_echo "$as_me:$LINENO: checking for suffix of object files" >&5
3470 $as_echo_n "checking for suffix of object files... " >&6; }
3471 if test "${ac_cv_objext+set}" = set; then
3472   $as_echo_n "(cached) " >&6
3473 else
3474   cat >conftest.$ac_ext <<_ACEOF
3475 /* confdefs.h.  */
3476 _ACEOF
3477 cat confdefs.h >>conftest.$ac_ext
3478 cat >>conftest.$ac_ext <<_ACEOF
3479 /* end confdefs.h.  */
3480
3481 int
3482 main ()
3483 {
3484
3485   ;
3486   return 0;
3487 }
3488 _ACEOF
3489 rm -f conftest.o conftest.obj
3490 if { (ac_try="$ac_compile"
3491 case "(($ac_try" in
3492   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3493   *) ac_try_echo=$ac_try;;
3494 esac
3495 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3496 $as_echo "$ac_try_echo") >&5
3497   (eval "$ac_compile") 2>&5
3498   ac_status=$?
3499   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3500   (exit $ac_status); }; then
3501   for ac_file in conftest.o conftest.obj conftest.*; do
3502   test -f "$ac_file" || continue;
3503   case $ac_file in
3504     *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;;
3505     *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'`
3506        break;;
3507   esac
3508 done
3509 else
3510   $as_echo "$as_me: failed program was:" >&5
3511 sed 's/^/| /' conftest.$ac_ext >&5
3512
3513 { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
3514 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
3515 { { $as_echo "$as_me:$LINENO: error: cannot compute suffix of object files: cannot compile
3516 See \`config.log' for more details." >&5
3517 $as_echo "$as_me: error: cannot compute suffix of object files: cannot compile
3518 See \`config.log' for more details." >&2;}
3519    { (exit 1); exit 1; }; }; }
3520 fi
3521
3522 rm -f conftest.$ac_cv_objext conftest.$ac_ext
3523 fi
3524 { $as_echo "$as_me:$LINENO: result: $ac_cv_objext" >&5
3525 $as_echo "$ac_cv_objext" >&6; }
3526 OBJEXT=$ac_cv_objext
3527 ac_objext=$OBJEXT
3528 { $as_echo "$as_me:$LINENO: checking whether we are using the GNU C compiler" >&5
3529 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; }
3530 if test "${ac_cv_c_compiler_gnu+set}" = set; then
3531   $as_echo_n "(cached) " >&6
3532 else
3533   cat >conftest.$ac_ext <<_ACEOF
3534 /* confdefs.h.  */
3535 _ACEOF
3536 cat confdefs.h >>conftest.$ac_ext
3537 cat >>conftest.$ac_ext <<_ACEOF
3538 /* end confdefs.h.  */
3539
3540 int
3541 main ()
3542 {
3543 #ifndef __GNUC__
3544        choke me
3545 #endif
3546
3547   ;
3548   return 0;
3549 }
3550 _ACEOF
3551 rm -f conftest.$ac_objext
3552 if { (ac_try="$ac_compile"
3553 case "(($ac_try" in
3554   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3555   *) ac_try_echo=$ac_try;;
3556 esac
3557 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3558 $as_echo "$ac_try_echo") >&5
3559   (eval "$ac_compile") 2>conftest.er1
3560   ac_status=$?
3561   grep -v '^ *+' conftest.er1 >conftest.err
3562   rm -f conftest.er1
3563   cat conftest.err >&5
3564   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3565   (exit $ac_status); } && {
3566          test -z "$ac_c_werror_flag" ||
3567          test ! -s conftest.err
3568        } && test -s conftest.$ac_objext; then
3569   ac_compiler_gnu=yes
3570 else
3571   $as_echo "$as_me: failed program was:" >&5
3572 sed 's/^/| /' conftest.$ac_ext >&5
3573
3574         ac_compiler_gnu=no
3575 fi
3576
3577 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3578 ac_cv_c_compiler_gnu=$ac_compiler_gnu
3579
3580 fi
3581 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_compiler_gnu" >&5
3582 $as_echo "$ac_cv_c_compiler_gnu" >&6; }
3583 if test $ac_compiler_gnu = yes; then
3584   GCC=yes
3585 else
3586   GCC=
3587 fi
3588 ac_test_CFLAGS=${CFLAGS+set}
3589 ac_save_CFLAGS=$CFLAGS
3590 { $as_echo "$as_me:$LINENO: checking whether $CC accepts -g" >&5
3591 $as_echo_n "checking whether $CC accepts -g... " >&6; }
3592 if test "${ac_cv_prog_cc_g+set}" = set; then
3593   $as_echo_n "(cached) " >&6
3594 else
3595   ac_save_c_werror_flag=$ac_c_werror_flag
3596    ac_c_werror_flag=yes
3597    ac_cv_prog_cc_g=no
3598    CFLAGS="-g"
3599    cat >conftest.$ac_ext <<_ACEOF
3600 /* confdefs.h.  */
3601 _ACEOF
3602 cat confdefs.h >>conftest.$ac_ext
3603 cat >>conftest.$ac_ext <<_ACEOF
3604 /* end confdefs.h.  */
3605
3606 int
3607 main ()
3608 {
3609
3610   ;
3611   return 0;
3612 }
3613 _ACEOF
3614 rm -f conftest.$ac_objext
3615 if { (ac_try="$ac_compile"
3616 case "(($ac_try" in
3617   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3618   *) ac_try_echo=$ac_try;;
3619 esac
3620 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3621 $as_echo "$ac_try_echo") >&5
3622   (eval "$ac_compile") 2>conftest.er1
3623   ac_status=$?
3624   grep -v '^ *+' conftest.er1 >conftest.err
3625   rm -f conftest.er1
3626   cat conftest.err >&5
3627   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3628   (exit $ac_status); } && {
3629          test -z "$ac_c_werror_flag" ||
3630          test ! -s conftest.err
3631        } && test -s conftest.$ac_objext; then
3632   ac_cv_prog_cc_g=yes
3633 else
3634   $as_echo "$as_me: failed program was:" >&5
3635 sed 's/^/| /' conftest.$ac_ext >&5
3636
3637         CFLAGS=""
3638       cat >conftest.$ac_ext <<_ACEOF
3639 /* confdefs.h.  */
3640 _ACEOF
3641 cat confdefs.h >>conftest.$ac_ext
3642 cat >>conftest.$ac_ext <<_ACEOF
3643 /* end confdefs.h.  */
3644
3645 int
3646 main ()
3647 {
3648
3649   ;
3650   return 0;
3651 }
3652 _ACEOF
3653 rm -f conftest.$ac_objext
3654 if { (ac_try="$ac_compile"
3655 case "(($ac_try" in
3656   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3657   *) ac_try_echo=$ac_try;;
3658 esac
3659 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3660 $as_echo "$ac_try_echo") >&5
3661   (eval "$ac_compile") 2>conftest.er1
3662   ac_status=$?
3663   grep -v '^ *+' conftest.er1 >conftest.err
3664   rm -f conftest.er1
3665   cat conftest.err >&5
3666   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3667   (exit $ac_status); } && {
3668          test -z "$ac_c_werror_flag" ||
3669          test ! -s conftest.err
3670        } && test -s conftest.$ac_objext; then
3671   :
3672 else
3673   $as_echo "$as_me: failed program was:" >&5
3674 sed 's/^/| /' conftest.$ac_ext >&5
3675
3676         ac_c_werror_flag=$ac_save_c_werror_flag
3677          CFLAGS="-g"
3678          cat >conftest.$ac_ext <<_ACEOF
3679 /* confdefs.h.  */
3680 _ACEOF
3681 cat confdefs.h >>conftest.$ac_ext
3682 cat >>conftest.$ac_ext <<_ACEOF
3683 /* end confdefs.h.  */
3684
3685 int
3686 main ()
3687 {
3688
3689   ;
3690   return 0;
3691 }
3692 _ACEOF
3693 rm -f conftest.$ac_objext
3694 if { (ac_try="$ac_compile"
3695 case "(($ac_try" in
3696   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3697   *) ac_try_echo=$ac_try;;
3698 esac
3699 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3700 $as_echo "$ac_try_echo") >&5
3701   (eval "$ac_compile") 2>conftest.er1
3702   ac_status=$?
3703   grep -v '^ *+' conftest.er1 >conftest.err
3704   rm -f conftest.er1
3705   cat conftest.err >&5
3706   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3707   (exit $ac_status); } && {
3708          test -z "$ac_c_werror_flag" ||
3709          test ! -s conftest.err
3710        } && test -s conftest.$ac_objext; then
3711   ac_cv_prog_cc_g=yes
3712 else
3713   $as_echo "$as_me: failed program was:" >&5
3714 sed 's/^/| /' conftest.$ac_ext >&5
3715
3716
3717 fi
3718
3719 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
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    ac_c_werror_flag=$ac_save_c_werror_flag
3727 fi
3728 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_g" >&5
3729 $as_echo "$ac_cv_prog_cc_g" >&6; }
3730 if test "$ac_test_CFLAGS" = set; then
3731   CFLAGS=$ac_save_CFLAGS
3732 elif test $ac_cv_prog_cc_g = yes; then
3733   if test "$GCC" = yes; then
3734     CFLAGS="-g -O2"
3735   else
3736     CFLAGS="-g"
3737   fi
3738 else
3739   if test "$GCC" = yes; then
3740     CFLAGS="-O2"
3741   else
3742     CFLAGS=
3743   fi
3744 fi
3745 { $as_echo "$as_me:$LINENO: checking for $CC option to accept ISO C89" >&5
3746 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; }
3747 if test "${ac_cv_prog_cc_c89+set}" = set; then
3748   $as_echo_n "(cached) " >&6
3749 else
3750   ac_cv_prog_cc_c89=no
3751 ac_save_CC=$CC
3752 cat >conftest.$ac_ext <<_ACEOF
3753 /* confdefs.h.  */
3754 _ACEOF
3755 cat confdefs.h >>conftest.$ac_ext
3756 cat >>conftest.$ac_ext <<_ACEOF
3757 /* end confdefs.h.  */
3758 #include <stdarg.h>
3759 #include <stdio.h>
3760 #include <sys/types.h>
3761 #include <sys/stat.h>
3762 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh.  */
3763 struct buf { int x; };
3764 FILE * (*rcsopen) (struct buf *, struct stat *, int);
3765 static char *e (p, i)
3766      char **p;
3767      int i;
3768 {
3769   return p[i];
3770 }
3771 static char *f (char * (*g) (char **, int), char **p, ...)
3772 {
3773   char *s;
3774   va_list v;
3775   va_start (v,p);
3776   s = g (p, va_arg (v,int));
3777   va_end (v);
3778   return s;
3779 }
3780
3781 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default.  It has
3782    function prototypes and stuff, but not '\xHH' hex character constants.
3783    These don't provoke an error unfortunately, instead are silently treated
3784    as 'x'.  The following induces an error, until -std is added to get
3785    proper ANSI mode.  Curiously '\x00'!='x' always comes out true, for an
3786    array size at least.  It's necessary to write '\x00'==0 to get something
3787    that's true only with -std.  */
3788 int osf4_cc_array ['\x00' == 0 ? 1 : -1];
3789
3790 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters
3791    inside strings and character constants.  */
3792 #define FOO(x) 'x'
3793 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1];
3794
3795 int test (int i, double x);
3796 struct s1 {int (*f) (int a);};
3797 struct s2 {int (*f) (double a);};
3798 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int);
3799 int argc;
3800 char **argv;
3801 int
3802 main ()
3803 {
3804 return f (e, argv, 0) != argv[0]  ||  f (e, argv, 1) != argv[1];
3805   ;
3806   return 0;
3807 }
3808 _ACEOF
3809 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \
3810         -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__"
3811 do
3812   CC="$ac_save_CC $ac_arg"
3813   rm -f conftest.$ac_objext
3814 if { (ac_try="$ac_compile"
3815 case "(($ac_try" in
3816   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3817   *) ac_try_echo=$ac_try;;
3818 esac
3819 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3820 $as_echo "$ac_try_echo") >&5
3821   (eval "$ac_compile") 2>conftest.er1
3822   ac_status=$?
3823   grep -v '^ *+' conftest.er1 >conftest.err
3824   rm -f conftest.er1
3825   cat conftest.err >&5
3826   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3827   (exit $ac_status); } && {
3828          test -z "$ac_c_werror_flag" ||
3829          test ! -s conftest.err
3830        } && test -s conftest.$ac_objext; then
3831   ac_cv_prog_cc_c89=$ac_arg
3832 else
3833   $as_echo "$as_me: failed program was:" >&5
3834 sed 's/^/| /' conftest.$ac_ext >&5
3835
3836
3837 fi
3838
3839 rm -f core conftest.err conftest.$ac_objext
3840   test "x$ac_cv_prog_cc_c89" != "xno" && break
3841 done
3842 rm -f conftest.$ac_ext
3843 CC=$ac_save_CC
3844
3845 fi
3846 # AC_CACHE_VAL
3847 case "x$ac_cv_prog_cc_c89" in
3848   x)
3849     { $as_echo "$as_me:$LINENO: result: none needed" >&5
3850 $as_echo "none needed" >&6; } ;;
3851   xno)
3852     { $as_echo "$as_me:$LINENO: result: unsupported" >&5
3853 $as_echo "unsupported" >&6; } ;;
3854   *)
3855     CC="$CC $ac_cv_prog_cc_c89"
3856     { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_cc_c89" >&5
3857 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;;
3858 esac
3859
3860
3861 ac_ext=c
3862 ac_cpp='$CPP $CPPFLAGS'
3863 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
3864 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
3865 ac_compiler_gnu=$ac_cv_c_compiler_gnu
3866
3867
3868 # Check if it's Intel's compiler, which (usually) pretends to be gcc,
3869 # but has idiosyncrasies of its own.  We assume icc will define
3870 # __INTEL_COMPILER regardless of CFLAGS.
3871
3872 cat >conftest.$ac_ext <<_ACEOF
3873 /* confdefs.h.  */
3874 _ACEOF
3875 cat confdefs.h >>conftest.$ac_ext
3876 cat >>conftest.$ac_ext <<_ACEOF
3877 /* end confdefs.h.  */
3878
3879 int
3880 main ()
3881 {
3882 #ifndef __INTEL_COMPILER
3883 choke me
3884 #endif
3885   ;
3886   return 0;
3887 }
3888 _ACEOF
3889 rm -f conftest.$ac_objext
3890 if { (ac_try="$ac_compile"
3891 case "(($ac_try" in
3892   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3893   *) ac_try_echo=$ac_try;;
3894 esac
3895 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3896 $as_echo "$ac_try_echo") >&5
3897   (eval "$ac_compile") 2>conftest.er1
3898   ac_status=$?
3899   grep -v '^ *+' conftest.er1 >conftest.err
3900   rm -f conftest.er1
3901   cat conftest.err >&5
3902   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3903   (exit $ac_status); } && {
3904          test -z "$ac_c_werror_flag" ||
3905          test ! -s conftest.err
3906        } && test -s conftest.$ac_objext; then
3907   ICC=yes
3908 else
3909   $as_echo "$as_me: failed program was:" >&5
3910 sed 's/^/| /' conftest.$ac_ext >&5
3911
3912         ICC=no
3913 fi
3914
3915 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3916
3917 # Check if it's Sun Studio compiler. We assume that
3918 # __SUNPRO_C will be defined for Sun Studio compilers
3919 cat >conftest.$ac_ext <<_ACEOF
3920 /* confdefs.h.  */
3921 _ACEOF
3922 cat confdefs.h >>conftest.$ac_ext
3923 cat >>conftest.$ac_ext <<_ACEOF
3924 /* end confdefs.h.  */
3925
3926 int
3927 main ()
3928 {
3929 #ifndef __SUNPRO_C
3930 choke me
3931 #endif
3932   ;
3933   return 0;
3934 }
3935 _ACEOF
3936 rm -f conftest.$ac_objext
3937 if { (ac_try="$ac_compile"
3938 case "(($ac_try" in
3939   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
3940   *) ac_try_echo=$ac_try;;
3941 esac
3942 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
3943 $as_echo "$ac_try_echo") >&5
3944   (eval "$ac_compile") 2>conftest.er1
3945   ac_status=$?
3946   grep -v '^ *+' conftest.er1 >conftest.err
3947   rm -f conftest.er1
3948   cat conftest.err >&5
3949   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
3950   (exit $ac_status); } && {
3951          test -z "$ac_c_werror_flag" ||
3952          test ! -s conftest.err
3953        } && test -s conftest.$ac_objext; then
3954   SUN_STUDIO_CC=yes
3955 else
3956   $as_echo "$as_me: failed program was:" >&5
3957 sed 's/^/| /' conftest.$ac_ext >&5
3958
3959         SUN_STUDIO_CC=no
3960 fi
3961
3962 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
3963
3964
3965
3966 unset CFLAGS
3967
3968 #
3969 # Read the template
3970 #
3971 . "$srcdir/src/template/$template" || exit
3972
3973 # CFLAGS are selected so:
3974 # If the user specifies something in the environment, that is used.
3975 # else:  If the template file set something, that is used.
3976 # else:  If coverage was enabled, don't set anything.
3977 # else:  If the compiler is GCC, then we use -O2.
3978 # else:  If the compiler is something else, then we use -O, unless debugging.
3979
3980 if test "$ac_env_CFLAGS_set" = set; then
3981   CFLAGS=$ac_env_CFLAGS_value
3982 elif test "${CFLAGS+set}" = set; then
3983   : # (keep what template set)
3984 elif test "$enable_coverage" = yes; then
3985   : # no optimization by default
3986 elif test "$GCC" = yes; then
3987   CFLAGS="-O2"
3988 else
3989   # if the user selected debug mode, don't use -O
3990   if test "$enable_debug" != yes; then
3991     CFLAGS="-O"
3992   fi
3993 fi
3994
3995 # Some versions of GCC support some additional useful warning flags.
3996 # Check whether they are supported, and add them to CFLAGS if so.
3997 # ICC pretends to be GCC but it's lying; it doesn't support these flags,
3998 # but has its own.  Also check other compiler-specific flags here.
3999
4000 if test "$GCC" = yes -a "$ICC" = no; then
4001   CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wpointer-arith"
4002   # These work in some but not all gcc versions
4003   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wdeclaration-after-statement" >&5
4004 $as_echo_n "checking whether $CC supports -Wdeclaration-after-statement... " >&6; }
4005 if test "${pgac_cv_prog_cc_cflags__Wdeclaration_after_statement+set}" = set; then
4006   $as_echo_n "(cached) " >&6
4007 else
4008   pgac_save_CFLAGS=$CFLAGS
4009 CFLAGS="$pgac_save_CFLAGS -Wdeclaration-after-statement"
4010 cat >conftest.$ac_ext <<_ACEOF
4011 /* confdefs.h.  */
4012 _ACEOF
4013 cat confdefs.h >>conftest.$ac_ext
4014 cat >>conftest.$ac_ext <<_ACEOF
4015 /* end confdefs.h.  */
4016
4017 int
4018 main ()
4019 {
4020
4021   ;
4022   return 0;
4023 }
4024 _ACEOF
4025 rm -f conftest.$ac_objext
4026 if { (ac_try="$ac_compile"
4027 case "(($ac_try" in
4028   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4029   *) ac_try_echo=$ac_try;;
4030 esac
4031 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4032 $as_echo "$ac_try_echo") >&5
4033   (eval "$ac_compile") 2>conftest.er1
4034   ac_status=$?
4035   grep -v '^ *+' conftest.er1 >conftest.err
4036   rm -f conftest.er1
4037   cat conftest.err >&5
4038   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4039   (exit $ac_status); } && {
4040          test -z "$ac_c_werror_flag" ||
4041          test ! -s conftest.err
4042        } && test -s conftest.$ac_objext; then
4043   pgac_cv_prog_cc_cflags__Wdeclaration_after_statement=yes
4044 else
4045   $as_echo "$as_me: failed program was:" >&5
4046 sed 's/^/| /' conftest.$ac_ext >&5
4047
4048         pgac_cv_prog_cc_cflags__Wdeclaration_after_statement=no
4049 fi
4050
4051 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4052 CFLAGS="$pgac_save_CFLAGS"
4053 fi
4054 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" >&5
4055 $as_echo "$pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" >&6; }
4056 if test x"$pgac_cv_prog_cc_cflags__Wdeclaration_after_statement" = x"yes"; then
4057   CFLAGS="$CFLAGS -Wdeclaration-after-statement"
4058 fi
4059
4060   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wendif-labels" >&5
4061 $as_echo_n "checking whether $CC supports -Wendif-labels... " >&6; }
4062 if test "${pgac_cv_prog_cc_cflags__Wendif_labels+set}" = set; then
4063   $as_echo_n "(cached) " >&6
4064 else
4065   pgac_save_CFLAGS=$CFLAGS
4066 CFLAGS="$pgac_save_CFLAGS -Wendif-labels"
4067 cat >conftest.$ac_ext <<_ACEOF
4068 /* confdefs.h.  */
4069 _ACEOF
4070 cat confdefs.h >>conftest.$ac_ext
4071 cat >>conftest.$ac_ext <<_ACEOF
4072 /* end confdefs.h.  */
4073
4074 int
4075 main ()
4076 {
4077
4078   ;
4079   return 0;
4080 }
4081 _ACEOF
4082 rm -f conftest.$ac_objext
4083 if { (ac_try="$ac_compile"
4084 case "(($ac_try" in
4085   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4086   *) ac_try_echo=$ac_try;;
4087 esac
4088 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4089 $as_echo "$ac_try_echo") >&5
4090   (eval "$ac_compile") 2>conftest.er1
4091   ac_status=$?
4092   grep -v '^ *+' conftest.er1 >conftest.err
4093   rm -f conftest.er1
4094   cat conftest.err >&5
4095   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4096   (exit $ac_status); } && {
4097          test -z "$ac_c_werror_flag" ||
4098          test ! -s conftest.err
4099        } && test -s conftest.$ac_objext; then
4100   pgac_cv_prog_cc_cflags__Wendif_labels=yes
4101 else
4102   $as_echo "$as_me: failed program was:" >&5
4103 sed 's/^/| /' conftest.$ac_ext >&5
4104
4105         pgac_cv_prog_cc_cflags__Wendif_labels=no
4106 fi
4107
4108 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4109 CFLAGS="$pgac_save_CFLAGS"
4110 fi
4111 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__Wendif_labels" >&5
4112 $as_echo "$pgac_cv_prog_cc_cflags__Wendif_labels" >&6; }
4113 if test x"$pgac_cv_prog_cc_cflags__Wendif_labels" = x"yes"; then
4114   CFLAGS="$CFLAGS -Wendif-labels"
4115 fi
4116
4117   # Disable strict-aliasing rules; needed for gcc 3.3+
4118   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fno-strict-aliasing" >&5
4119 $as_echo_n "checking whether $CC supports -fno-strict-aliasing... " >&6; }
4120 if test "${pgac_cv_prog_cc_cflags__fno_strict_aliasing+set}" = set; then
4121   $as_echo_n "(cached) " >&6
4122 else
4123   pgac_save_CFLAGS=$CFLAGS
4124 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
4125 cat >conftest.$ac_ext <<_ACEOF
4126 /* confdefs.h.  */
4127 _ACEOF
4128 cat confdefs.h >>conftest.$ac_ext
4129 cat >>conftest.$ac_ext <<_ACEOF
4130 /* end confdefs.h.  */
4131
4132 int
4133 main ()
4134 {
4135
4136   ;
4137   return 0;
4138 }
4139 _ACEOF
4140 rm -f conftest.$ac_objext
4141 if { (ac_try="$ac_compile"
4142 case "(($ac_try" in
4143   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4144   *) ac_try_echo=$ac_try;;
4145 esac
4146 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4147 $as_echo "$ac_try_echo") >&5
4148   (eval "$ac_compile") 2>conftest.er1
4149   ac_status=$?
4150   grep -v '^ *+' conftest.er1 >conftest.err
4151   rm -f conftest.er1
4152   cat conftest.err >&5
4153   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4154   (exit $ac_status); } && {
4155          test -z "$ac_c_werror_flag" ||
4156          test ! -s conftest.err
4157        } && test -s conftest.$ac_objext; then
4158   pgac_cv_prog_cc_cflags__fno_strict_aliasing=yes
4159 else
4160   $as_echo "$as_me: failed program was:" >&5
4161 sed 's/^/| /' conftest.$ac_ext >&5
4162
4163         pgac_cv_prog_cc_cflags__fno_strict_aliasing=no
4164 fi
4165
4166 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4167 CFLAGS="$pgac_save_CFLAGS"
4168 fi
4169 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&5
4170 $as_echo "$pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&6; }
4171 if test x"$pgac_cv_prog_cc_cflags__fno_strict_aliasing" = x"yes"; then
4172   CFLAGS="$CFLAGS -fno-strict-aliasing"
4173 fi
4174
4175   # Disable optimizations that assume no overflow; needed for gcc 4.3+
4176   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fwrapv" >&5
4177 $as_echo_n "checking whether $CC supports -fwrapv... " >&6; }
4178 if test "${pgac_cv_prog_cc_cflags__fwrapv+set}" = set; then
4179   $as_echo_n "(cached) " >&6
4180 else
4181   pgac_save_CFLAGS=$CFLAGS
4182 CFLAGS="$pgac_save_CFLAGS -fwrapv"
4183 cat >conftest.$ac_ext <<_ACEOF
4184 /* confdefs.h.  */
4185 _ACEOF
4186 cat confdefs.h >>conftest.$ac_ext
4187 cat >>conftest.$ac_ext <<_ACEOF
4188 /* end confdefs.h.  */
4189
4190 int
4191 main ()
4192 {
4193
4194   ;
4195   return 0;
4196 }
4197 _ACEOF
4198 rm -f conftest.$ac_objext
4199 if { (ac_try="$ac_compile"
4200 case "(($ac_try" in
4201   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4202   *) ac_try_echo=$ac_try;;
4203 esac
4204 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4205 $as_echo "$ac_try_echo") >&5
4206   (eval "$ac_compile") 2>conftest.er1
4207   ac_status=$?
4208   grep -v '^ *+' conftest.er1 >conftest.err
4209   rm -f conftest.er1
4210   cat conftest.err >&5
4211   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4212   (exit $ac_status); } && {
4213          test -z "$ac_c_werror_flag" ||
4214          test ! -s conftest.err
4215        } && test -s conftest.$ac_objext; then
4216   pgac_cv_prog_cc_cflags__fwrapv=yes
4217 else
4218   $as_echo "$as_me: failed program was:" >&5
4219 sed 's/^/| /' conftest.$ac_ext >&5
4220
4221         pgac_cv_prog_cc_cflags__fwrapv=no
4222 fi
4223
4224 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4225 CFLAGS="$pgac_save_CFLAGS"
4226 fi
4227 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fwrapv" >&5
4228 $as_echo "$pgac_cv_prog_cc_cflags__fwrapv" >&6; }
4229 if test x"$pgac_cv_prog_cc_cflags__fwrapv" = x"yes"; then
4230   CFLAGS="$CFLAGS -fwrapv"
4231 fi
4232
4233 elif test "$ICC" = yes; then
4234   # Intel's compiler has a bug/misoptimization in checking for
4235   # division by NAN (NaN == 0), -mp1 fixes it, so add it to the CFLAGS.
4236   { $as_echo "$as_me:$LINENO: checking whether $CC supports -mp1" >&5
4237 $as_echo_n "checking whether $CC supports -mp1... " >&6; }
4238 if test "${pgac_cv_prog_cc_cflags__mp1+set}" = set; then
4239   $as_echo_n "(cached) " >&6
4240 else
4241   pgac_save_CFLAGS=$CFLAGS
4242 CFLAGS="$pgac_save_CFLAGS -mp1"
4243 cat >conftest.$ac_ext <<_ACEOF
4244 /* confdefs.h.  */
4245 _ACEOF
4246 cat confdefs.h >>conftest.$ac_ext
4247 cat >>conftest.$ac_ext <<_ACEOF
4248 /* end confdefs.h.  */
4249
4250 int
4251 main ()
4252 {
4253
4254   ;
4255   return 0;
4256 }
4257 _ACEOF
4258 rm -f conftest.$ac_objext
4259 if { (ac_try="$ac_compile"
4260 case "(($ac_try" in
4261   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4262   *) ac_try_echo=$ac_try;;
4263 esac
4264 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4265 $as_echo "$ac_try_echo") >&5
4266   (eval "$ac_compile") 2>conftest.er1
4267   ac_status=$?
4268   grep -v '^ *+' conftest.er1 >conftest.err
4269   rm -f conftest.er1
4270   cat conftest.err >&5
4271   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4272   (exit $ac_status); } && {
4273          test -z "$ac_c_werror_flag" ||
4274          test ! -s conftest.err
4275        } && test -s conftest.$ac_objext; then
4276   pgac_cv_prog_cc_cflags__mp1=yes
4277 else
4278   $as_echo "$as_me: failed program was:" >&5
4279 sed 's/^/| /' conftest.$ac_ext >&5
4280
4281         pgac_cv_prog_cc_cflags__mp1=no
4282 fi
4283
4284 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4285 CFLAGS="$pgac_save_CFLAGS"
4286 fi
4287 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__mp1" >&5
4288 $as_echo "$pgac_cv_prog_cc_cflags__mp1" >&6; }
4289 if test x"$pgac_cv_prog_cc_cflags__mp1" = x"yes"; then
4290   CFLAGS="$CFLAGS -mp1"
4291 fi
4292
4293   # Make sure strict aliasing is off (though this is said to be the default)
4294   { $as_echo "$as_me:$LINENO: checking whether $CC supports -fno-strict-aliasing" >&5
4295 $as_echo_n "checking whether $CC supports -fno-strict-aliasing... " >&6; }
4296 if test "${pgac_cv_prog_cc_cflags__fno_strict_aliasing+set}" = set; then
4297   $as_echo_n "(cached) " >&6
4298 else
4299   pgac_save_CFLAGS=$CFLAGS
4300 CFLAGS="$pgac_save_CFLAGS -fno-strict-aliasing"
4301 cat >conftest.$ac_ext <<_ACEOF
4302 /* confdefs.h.  */
4303 _ACEOF
4304 cat confdefs.h >>conftest.$ac_ext
4305 cat >>conftest.$ac_ext <<_ACEOF
4306 /* end confdefs.h.  */
4307
4308 int
4309 main ()
4310 {
4311
4312   ;
4313   return 0;
4314 }
4315 _ACEOF
4316 rm -f conftest.$ac_objext
4317 if { (ac_try="$ac_compile"
4318 case "(($ac_try" in
4319   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4320   *) ac_try_echo=$ac_try;;
4321 esac
4322 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4323 $as_echo "$ac_try_echo") >&5
4324   (eval "$ac_compile") 2>conftest.er1
4325   ac_status=$?
4326   grep -v '^ *+' conftest.er1 >conftest.err
4327   rm -f conftest.er1
4328   cat conftest.err >&5
4329   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4330   (exit $ac_status); } && {
4331          test -z "$ac_c_werror_flag" ||
4332          test ! -s conftest.err
4333        } && test -s conftest.$ac_objext; then
4334   pgac_cv_prog_cc_cflags__fno_strict_aliasing=yes
4335 else
4336   $as_echo "$as_me: failed program was:" >&5
4337 sed 's/^/| /' conftest.$ac_ext >&5
4338
4339         pgac_cv_prog_cc_cflags__fno_strict_aliasing=no
4340 fi
4341
4342 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4343 CFLAGS="$pgac_save_CFLAGS"
4344 fi
4345 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&5
4346 $as_echo "$pgac_cv_prog_cc_cflags__fno_strict_aliasing" >&6; }
4347 if test x"$pgac_cv_prog_cc_cflags__fno_strict_aliasing" = x"yes"; then
4348   CFLAGS="$CFLAGS -fno-strict-aliasing"
4349 fi
4350
4351 elif test "$PORTNAME" = "aix"; then
4352   # AIX's xlc has to have strict aliasing turned off too
4353   { $as_echo "$as_me:$LINENO: checking whether $CC supports -qnoansialias" >&5
4354 $as_echo_n "checking whether $CC supports -qnoansialias... " >&6; }
4355 if test "${pgac_cv_prog_cc_cflags__qnoansialias+set}" = set; then
4356   $as_echo_n "(cached) " >&6
4357 else
4358   pgac_save_CFLAGS=$CFLAGS
4359 CFLAGS="$pgac_save_CFLAGS -qnoansialias"
4360 cat >conftest.$ac_ext <<_ACEOF
4361 /* confdefs.h.  */
4362 _ACEOF
4363 cat confdefs.h >>conftest.$ac_ext
4364 cat >>conftest.$ac_ext <<_ACEOF
4365 /* end confdefs.h.  */
4366
4367 int
4368 main ()
4369 {
4370
4371   ;
4372   return 0;
4373 }
4374 _ACEOF
4375 rm -f conftest.$ac_objext
4376 if { (ac_try="$ac_compile"
4377 case "(($ac_try" in
4378   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4379   *) ac_try_echo=$ac_try;;
4380 esac
4381 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4382 $as_echo "$ac_try_echo") >&5
4383   (eval "$ac_compile") 2>conftest.er1
4384   ac_status=$?
4385   grep -v '^ *+' conftest.er1 >conftest.err
4386   rm -f conftest.er1
4387   cat conftest.err >&5
4388   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4389   (exit $ac_status); } && {
4390          test -z "$ac_c_werror_flag" ||
4391          test ! -s conftest.err
4392        } && test -s conftest.$ac_objext; then
4393   pgac_cv_prog_cc_cflags__qnoansialias=yes
4394 else
4395   $as_echo "$as_me: failed program was:" >&5
4396 sed 's/^/| /' conftest.$ac_ext >&5
4397
4398         pgac_cv_prog_cc_cflags__qnoansialias=no
4399 fi
4400
4401 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4402 CFLAGS="$pgac_save_CFLAGS"
4403 fi
4404 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_cflags__qnoansialias" >&5
4405 $as_echo "$pgac_cv_prog_cc_cflags__qnoansialias" >&6; }
4406 if test x"$pgac_cv_prog_cc_cflags__qnoansialias" = x"yes"; then
4407   CFLAGS="$CFLAGS -qnoansialias"
4408 fi
4409
4410 fi
4411
4412 # supply -g if --enable-debug
4413 if test "$enable_debug" = yes && test "$ac_cv_prog_cc_g" = yes; then
4414   CFLAGS="$CFLAGS -g"
4415 fi
4416
4417 # enable code coverage if --enable-coverage
4418 if test "$enable_coverage" = yes; then
4419   if test "$GCC" = yes; then
4420     CFLAGS="$CFLAGS -fprofile-arcs -ftest-coverage"
4421   else
4422     { { $as_echo "$as_me:$LINENO: error: --enable-coverage is supported only when using GCC" >&5
4423 $as_echo "$as_me: error: --enable-coverage is supported only when using GCC" >&2;}
4424    { (exit 1); exit 1; }; }
4425   fi
4426 fi
4427
4428 # enable profiling if --enable-profiling
4429 if test "$enable_profiling" = yes && test "$ac_cv_prog_cc_g" = yes; then
4430   if test "$GCC" = yes; then
4431
4432 cat >>confdefs.h <<\_ACEOF
4433 #define PROFILE_PID_DIR 1
4434 _ACEOF
4435
4436     CFLAGS="$CFLAGS -pg $PLATFORM_PROFILE_FLAGS"
4437   else
4438     { { $as_echo "$as_me:$LINENO: error: --enable-profiling is supported only when using GCC" >&5
4439 $as_echo "$as_me: error: --enable-profiling is supported only when using GCC" >&2;}
4440    { (exit 1); exit 1; }; }
4441   fi
4442 fi
4443
4444 # We already have this in Makefile.win32, but configure needs it too
4445 if test "$PORTNAME" = "win32"; then
4446   CPPFLAGS="$CPPFLAGS -I$srcdir/src/include/port/win32 -DEXEC_BACKEND"
4447 fi
4448
4449 # Check if the compiler still works with the template settings
4450 { $as_echo "$as_me:$LINENO: checking whether the C compiler still works" >&5
4451 $as_echo_n "checking whether the C compiler still works... " >&6; }
4452 cat >conftest.$ac_ext <<_ACEOF
4453 /* confdefs.h.  */
4454 _ACEOF
4455 cat confdefs.h >>conftest.$ac_ext
4456 cat >>conftest.$ac_ext <<_ACEOF
4457 /* end confdefs.h.  */
4458
4459 int
4460 main ()
4461 {
4462 return 0;
4463   ;
4464   return 0;
4465 }
4466 _ACEOF
4467 rm -f conftest.$ac_objext conftest$ac_exeext
4468 if { (ac_try="$ac_link"
4469 case "(($ac_try" in
4470   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4471   *) ac_try_echo=$ac_try;;
4472 esac
4473 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4474 $as_echo "$ac_try_echo") >&5
4475   (eval "$ac_link") 2>conftest.er1
4476   ac_status=$?
4477   grep -v '^ *+' conftest.er1 >conftest.err
4478   rm -f conftest.er1
4479   cat conftest.err >&5
4480   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4481   (exit $ac_status); } && {
4482          test -z "$ac_c_werror_flag" ||
4483          test ! -s conftest.err
4484        } && test -s conftest$ac_exeext && {
4485          test "$cross_compiling" = yes ||
4486          $as_test_x conftest$ac_exeext
4487        }; then
4488   { $as_echo "$as_me:$LINENO: result: yes" >&5
4489 $as_echo "yes" >&6; }
4490 else
4491   $as_echo "$as_me: failed program was:" >&5
4492 sed 's/^/| /' conftest.$ac_ext >&5
4493
4494         { $as_echo "$as_me:$LINENO: result: no" >&5
4495 $as_echo "no" >&6; }
4496    { { $as_echo "$as_me:$LINENO: error: cannot proceed" >&5
4497 $as_echo "$as_me: error: cannot proceed" >&2;}
4498    { (exit 1); exit 1; }; }
4499 fi
4500
4501 rm -rf conftest.dSYM
4502 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
4503       conftest$ac_exeext conftest.$ac_ext
4504
4505 # Defend against gcc -ffast-math
4506 if test "$GCC" = yes; then
4507 cat >conftest.$ac_ext <<_ACEOF
4508 /* confdefs.h.  */
4509 _ACEOF
4510 cat confdefs.h >>conftest.$ac_ext
4511 cat >>conftest.$ac_ext <<_ACEOF
4512 /* end confdefs.h.  */
4513
4514 int
4515 main ()
4516 {
4517 #ifdef __FAST_MATH__
4518 choke me
4519 #endif
4520   ;
4521   return 0;
4522 }
4523 _ACEOF
4524 rm -f conftest.$ac_objext
4525 if { (ac_try="$ac_compile"
4526 case "(($ac_try" in
4527   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4528   *) ac_try_echo=$ac_try;;
4529 esac
4530 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4531 $as_echo "$ac_try_echo") >&5
4532   (eval "$ac_compile") 2>conftest.er1
4533   ac_status=$?
4534   grep -v '^ *+' conftest.er1 >conftest.err
4535   rm -f conftest.er1
4536   cat conftest.err >&5
4537   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4538   (exit $ac_status); } && {
4539          test -z "$ac_c_werror_flag" ||
4540          test ! -s conftest.err
4541        } && test -s conftest.$ac_objext; then
4542   :
4543 else
4544   $as_echo "$as_me: failed program was:" >&5
4545 sed 's/^/| /' conftest.$ac_ext >&5
4546
4547         { { $as_echo "$as_me:$LINENO: error: do not put -ffast-math in CFLAGS" >&5
4548 $as_echo "$as_me: error: do not put -ffast-math in CFLAGS" >&2;}
4549    { (exit 1); exit 1; }; }
4550 fi
4551
4552 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
4553 fi
4554
4555 ac_ext=c
4556 ac_cpp='$CPP $CPPFLAGS'
4557 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4558 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4559 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4560 { $as_echo "$as_me:$LINENO: checking how to run the C preprocessor" >&5
4561 $as_echo_n "checking how to run the C preprocessor... " >&6; }
4562 # On Suns, sometimes $CPP names a directory.
4563 if test -n "$CPP" && test -d "$CPP"; then
4564   CPP=
4565 fi
4566 if test -z "$CPP"; then
4567   if test "${ac_cv_prog_CPP+set}" = set; then
4568   $as_echo_n "(cached) " >&6
4569 else
4570       # Double quotes because CPP needs to be expanded
4571     for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp"
4572     do
4573       ac_preproc_ok=false
4574 for ac_c_preproc_warn_flag in '' yes
4575 do
4576   # Use a header file that comes with gcc, so configuring glibc
4577   # with a fresh cross-compiler works.
4578   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4579   # <limits.h> exists even on freestanding compilers.
4580   # On the NeXT, cc -E runs the code through the compiler's parser,
4581   # not just through cpp. "Syntax error" is here to catch this case.
4582   cat >conftest.$ac_ext <<_ACEOF
4583 /* confdefs.h.  */
4584 _ACEOF
4585 cat confdefs.h >>conftest.$ac_ext
4586 cat >>conftest.$ac_ext <<_ACEOF
4587 /* end confdefs.h.  */
4588 #ifdef __STDC__
4589 # include <limits.h>
4590 #else
4591 # include <assert.h>
4592 #endif
4593                      Syntax error
4594 _ACEOF
4595 if { (ac_try="$ac_cpp conftest.$ac_ext"
4596 case "(($ac_try" in
4597   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4598   *) ac_try_echo=$ac_try;;
4599 esac
4600 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4601 $as_echo "$ac_try_echo") >&5
4602   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4603   ac_status=$?
4604   grep -v '^ *+' conftest.er1 >conftest.err
4605   rm -f conftest.er1
4606   cat conftest.err >&5
4607   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4608   (exit $ac_status); } >/dev/null && {
4609          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4610          test ! -s conftest.err
4611        }; then
4612   :
4613 else
4614   $as_echo "$as_me: failed program was:" >&5
4615 sed 's/^/| /' conftest.$ac_ext >&5
4616
4617   # Broken: fails on valid input.
4618 continue
4619 fi
4620
4621 rm -f conftest.err conftest.$ac_ext
4622
4623   # OK, works on sane cases.  Now check whether nonexistent headers
4624   # can be detected and how.
4625   cat >conftest.$ac_ext <<_ACEOF
4626 /* confdefs.h.  */
4627 _ACEOF
4628 cat confdefs.h >>conftest.$ac_ext
4629 cat >>conftest.$ac_ext <<_ACEOF
4630 /* end confdefs.h.  */
4631 #include <ac_nonexistent.h>
4632 _ACEOF
4633 if { (ac_try="$ac_cpp conftest.$ac_ext"
4634 case "(($ac_try" in
4635   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4636   *) ac_try_echo=$ac_try;;
4637 esac
4638 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4639 $as_echo "$ac_try_echo") >&5
4640   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4641   ac_status=$?
4642   grep -v '^ *+' conftest.er1 >conftest.err
4643   rm -f conftest.er1
4644   cat conftest.err >&5
4645   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4646   (exit $ac_status); } >/dev/null && {
4647          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4648          test ! -s conftest.err
4649        }; then
4650   # Broken: success on invalid input.
4651 continue
4652 else
4653   $as_echo "$as_me: failed program was:" >&5
4654 sed 's/^/| /' conftest.$ac_ext >&5
4655
4656   # Passes both tests.
4657 ac_preproc_ok=:
4658 break
4659 fi
4660
4661 rm -f conftest.err conftest.$ac_ext
4662
4663 done
4664 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4665 rm -f conftest.err conftest.$ac_ext
4666 if $ac_preproc_ok; then
4667   break
4668 fi
4669
4670     done
4671     ac_cv_prog_CPP=$CPP
4672
4673 fi
4674   CPP=$ac_cv_prog_CPP
4675 else
4676   ac_cv_prog_CPP=$CPP
4677 fi
4678 { $as_echo "$as_me:$LINENO: result: $CPP" >&5
4679 $as_echo "$CPP" >&6; }
4680 ac_preproc_ok=false
4681 for ac_c_preproc_warn_flag in '' yes
4682 do
4683   # Use a header file that comes with gcc, so configuring glibc
4684   # with a fresh cross-compiler works.
4685   # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
4686   # <limits.h> exists even on freestanding compilers.
4687   # On the NeXT, cc -E runs the code through the compiler's parser,
4688   # not just through cpp. "Syntax error" is here to catch this case.
4689   cat >conftest.$ac_ext <<_ACEOF
4690 /* confdefs.h.  */
4691 _ACEOF
4692 cat confdefs.h >>conftest.$ac_ext
4693 cat >>conftest.$ac_ext <<_ACEOF
4694 /* end confdefs.h.  */
4695 #ifdef __STDC__
4696 # include <limits.h>
4697 #else
4698 # include <assert.h>
4699 #endif
4700                      Syntax error
4701 _ACEOF
4702 if { (ac_try="$ac_cpp conftest.$ac_ext"
4703 case "(($ac_try" in
4704   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4705   *) ac_try_echo=$ac_try;;
4706 esac
4707 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4708 $as_echo "$ac_try_echo") >&5
4709   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4710   ac_status=$?
4711   grep -v '^ *+' conftest.er1 >conftest.err
4712   rm -f conftest.er1
4713   cat conftest.err >&5
4714   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4715   (exit $ac_status); } >/dev/null && {
4716          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4717          test ! -s conftest.err
4718        }; then
4719   :
4720 else
4721   $as_echo "$as_me: failed program was:" >&5
4722 sed 's/^/| /' conftest.$ac_ext >&5
4723
4724   # Broken: fails on valid input.
4725 continue
4726 fi
4727
4728 rm -f conftest.err conftest.$ac_ext
4729
4730   # OK, works on sane cases.  Now check whether nonexistent headers
4731   # can be detected and how.
4732   cat >conftest.$ac_ext <<_ACEOF
4733 /* confdefs.h.  */
4734 _ACEOF
4735 cat confdefs.h >>conftest.$ac_ext
4736 cat >>conftest.$ac_ext <<_ACEOF
4737 /* end confdefs.h.  */
4738 #include <ac_nonexistent.h>
4739 _ACEOF
4740 if { (ac_try="$ac_cpp conftest.$ac_ext"
4741 case "(($ac_try" in
4742   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
4743   *) ac_try_echo=$ac_try;;
4744 esac
4745 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
4746 $as_echo "$ac_try_echo") >&5
4747   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
4748   ac_status=$?
4749   grep -v '^ *+' conftest.er1 >conftest.err
4750   rm -f conftest.er1
4751   cat conftest.err >&5
4752   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
4753   (exit $ac_status); } >/dev/null && {
4754          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
4755          test ! -s conftest.err
4756        }; then
4757   # Broken: success on invalid input.
4758 continue
4759 else
4760   $as_echo "$as_me: failed program was:" >&5
4761 sed 's/^/| /' conftest.$ac_ext >&5
4762
4763   # Passes both tests.
4764 ac_preproc_ok=:
4765 break
4766 fi
4767
4768 rm -f conftest.err conftest.$ac_ext
4769
4770 done
4771 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped.
4772 rm -f conftest.err conftest.$ac_ext
4773 if $ac_preproc_ok; then
4774   :
4775 else
4776   { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
4777 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
4778 { { $as_echo "$as_me:$LINENO: error: C preprocessor \"$CPP\" fails sanity check
4779 See \`config.log' for more details." >&5
4780 $as_echo "$as_me: error: C preprocessor \"$CPP\" fails sanity check
4781 See \`config.log' for more details." >&2;}
4782    { (exit 1); exit 1; }; }; }
4783 fi
4784
4785 ac_ext=c
4786 ac_cpp='$CPP $CPPFLAGS'
4787 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
4788 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
4789 ac_compiler_gnu=$ac_cv_c_compiler_gnu
4790
4791
4792
4793
4794 #
4795 # Set up TAS assembly code if needed; the template file has now had its
4796 # chance to request this.
4797 #
4798 ac_config_links="$ac_config_links src/backend/port/tas.s:src/backend/port/tas/${tas_file}"
4799
4800
4801 if test "$need_tas" = yes ; then
4802   TAS=tas.o
4803 else
4804   TAS=""
4805 fi
4806
4807
4808
4809 #
4810 # Automatic dependency tracking
4811 #
4812
4813
4814 # Check whether --enable-depend was given.
4815 if test "${enable_depend+set}" = set; then
4816   enableval=$enable_depend;
4817   case $enableval in
4818     yes)
4819       autodepend=yes
4820       ;;
4821     no)
4822       :
4823       ;;
4824     *)
4825       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-depend option" >&5
4826 $as_echo "$as_me: error: no argument expected for --enable-depend option" >&2;}
4827    { (exit 1); exit 1; }; }
4828       ;;
4829   esac
4830
4831 else
4832   enable_depend=no
4833
4834 fi
4835
4836
4837
4838
4839
4840 #
4841 # Enable assert checks
4842 #
4843
4844
4845 # Check whether --enable-cassert was given.
4846 if test "${enable_cassert+set}" = set; then
4847   enableval=$enable_cassert;
4848   case $enableval in
4849     yes)
4850
4851 cat >>confdefs.h <<\_ACEOF
4852 #define USE_ASSERT_CHECKING 1
4853 _ACEOF
4854
4855       ;;
4856     no)
4857       :
4858       ;;
4859     *)
4860       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-cassert option" >&5
4861 $as_echo "$as_me: error: no argument expected for --enable-cassert option" >&2;}
4862    { (exit 1); exit 1; }; }
4863       ;;
4864   esac
4865
4866 else
4867   enable_cassert=no
4868
4869 fi
4870
4871
4872
4873
4874 #
4875 # Include directories
4876 #
4877 ac_save_IFS=$IFS
4878 IFS="${IFS}${PATH_SEPARATOR}"
4879 # SRCH_INC comes from the template file
4880 for dir in $with_includes $SRCH_INC; do
4881   if test -d "$dir"; then
4882     INCLUDES="$INCLUDES -I$dir"
4883   else
4884     { $as_echo "$as_me:$LINENO: WARNING: *** Include directory $dir does not exist." >&5
4885 $as_echo "$as_me: WARNING: *** Include directory $dir does not exist." >&2;}
4886   fi
4887 done
4888 IFS=$ac_save_IFS
4889
4890
4891
4892 #
4893 # Library directories
4894 #
4895 ac_save_IFS=$IFS
4896 IFS="${IFS}${PATH_SEPARATOR}"
4897 # LIBRARY_DIRS comes from command line, SRCH_LIB from template file.
4898 for dir in $LIBRARY_DIRS $SRCH_LIB; do
4899   if test -d "$dir"; then
4900     LIBDIRS="$LIBDIRS -L$dir"
4901   else
4902     { $as_echo "$as_me:$LINENO: WARNING: *** Library directory $dir does not exist." >&5
4903 $as_echo "$as_me: WARNING: *** Library directory $dir does not exist." >&2;}
4904   fi
4905 done
4906 IFS=$ac_save_IFS
4907
4908 #
4909 # Enable thread-safe client libraries
4910 #
4911 { $as_echo "$as_me:$LINENO: checking allow thread-safe client libraries" >&5
4912 $as_echo_n "checking allow thread-safe client libraries... " >&6; }
4913
4914
4915 # Check whether --enable-thread-safety was given.
4916 if test "${enable_thread_safety+set}" = set; then
4917   enableval=$enable_thread_safety;
4918   case $enableval in
4919     yes)
4920       :
4921       ;;
4922     no)
4923       :
4924       ;;
4925     *)
4926       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-thread-safety option" >&5
4927 $as_echo "$as_me: error: no argument expected for --enable-thread-safety option" >&2;}
4928    { (exit 1); exit 1; }; }
4929       ;;
4930   esac
4931
4932 else
4933   enable_thread_safety=yes
4934
4935 fi
4936
4937
4938 if test "$enable_thread_safety" = yes; then
4939
4940 cat >>confdefs.h <<\_ACEOF
4941 #define ENABLE_THREAD_SAFETY 1
4942 _ACEOF
4943
4944 fi
4945 { $as_echo "$as_me:$LINENO: result: $enable_thread_safety" >&5
4946 $as_echo "$enable_thread_safety" >&6; }
4947
4948
4949 #
4950 # Optionally build Tcl modules (PL/Tcl)
4951 #
4952 { $as_echo "$as_me:$LINENO: checking whether to build with Tcl" >&5
4953 $as_echo_n "checking whether to build with Tcl... " >&6; }
4954
4955
4956
4957 # Check whether --with-tcl was given.
4958 if test "${with_tcl+set}" = set; then
4959   withval=$with_tcl;
4960   case $withval in
4961     yes)
4962       :
4963       ;;
4964     no)
4965       :
4966       ;;
4967     *)
4968       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-tcl option" >&5
4969 $as_echo "$as_me: error: no argument expected for --with-tcl option" >&2;}
4970    { (exit 1); exit 1; }; }
4971       ;;
4972   esac
4973
4974 else
4975   with_tcl=no
4976
4977 fi
4978
4979
4980 { $as_echo "$as_me:$LINENO: result: $with_tcl" >&5
4981 $as_echo "$with_tcl" >&6; }
4982
4983
4984 # We see if the path to the Tcl/Tk configuration scripts is specified.
4985 # This will override the use of tclsh to find the paths to search.
4986
4987
4988
4989
4990 # Check whether --with-tclconfig was given.
4991 if test "${with_tclconfig+set}" = set; then
4992   withval=$with_tclconfig;
4993   case $withval in
4994     yes)
4995       { { $as_echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
4996 $as_echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
4997    { (exit 1); exit 1; }; }
4998       ;;
4999     no)
5000       { { $as_echo "$as_me:$LINENO: error: argument required for --with-tclconfig option" >&5
5001 $as_echo "$as_me: error: argument required for --with-tclconfig option" >&2;}
5002    { (exit 1); exit 1; }; }
5003       ;;
5004     *)
5005
5006       ;;
5007   esac
5008
5009 fi
5010
5011
5012
5013 #
5014 # Optionally build Perl modules (PL/Perl)
5015 #
5016 { $as_echo "$as_me:$LINENO: checking whether to build Perl modules" >&5
5017 $as_echo_n "checking whether to build Perl modules... " >&6; }
5018
5019
5020
5021 # Check whether --with-perl was given.
5022 if test "${with_perl+set}" = set; then
5023   withval=$with_perl;
5024   case $withval in
5025     yes)
5026       :
5027       ;;
5028     no)
5029       :
5030       ;;
5031     *)
5032       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-perl option" >&5
5033 $as_echo "$as_me: error: no argument expected for --with-perl option" >&2;}
5034    { (exit 1); exit 1; }; }
5035       ;;
5036   esac
5037
5038 else
5039   with_perl=no
5040
5041 fi
5042
5043
5044 { $as_echo "$as_me:$LINENO: result: $with_perl" >&5
5045 $as_echo "$with_perl" >&6; }
5046
5047
5048 #
5049 # Optionally build Python modules (PL/Python)
5050 #
5051 { $as_echo "$as_me:$LINENO: checking whether to build Python modules" >&5
5052 $as_echo_n "checking whether to build Python modules... " >&6; }
5053
5054
5055
5056 # Check whether --with-python was given.
5057 if test "${with_python+set}" = set; then
5058   withval=$with_python;
5059   case $withval in
5060     yes)
5061       :
5062       ;;
5063     no)
5064       :
5065       ;;
5066     *)
5067       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-python option" >&5
5068 $as_echo "$as_me: error: no argument expected for --with-python option" >&2;}
5069    { (exit 1); exit 1; }; }
5070       ;;
5071   esac
5072
5073 else
5074   with_python=no
5075
5076 fi
5077
5078
5079 { $as_echo "$as_me:$LINENO: result: $with_python" >&5
5080 $as_echo "$with_python" >&6; }
5081
5082
5083 #
5084 # GSSAPI
5085 #
5086 { $as_echo "$as_me:$LINENO: checking whether to build with GSSAPI support" >&5
5087 $as_echo_n "checking whether to build with GSSAPI support... " >&6; }
5088
5089
5090
5091 # Check whether --with-gssapi was given.
5092 if test "${with_gssapi+set}" = set; then
5093   withval=$with_gssapi;
5094   case $withval in
5095     yes)
5096
5097
5098 cat >>confdefs.h <<\_ACEOF
5099 #define ENABLE_GSS 1
5100 _ACEOF
5101
5102   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
5103
5104       ;;
5105     no)
5106       :
5107       ;;
5108     *)
5109       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-gssapi option" >&5
5110 $as_echo "$as_me: error: no argument expected for --with-gssapi option" >&2;}
5111    { (exit 1); exit 1; }; }
5112       ;;
5113   esac
5114
5115 else
5116   with_gssapi=no
5117
5118 fi
5119
5120
5121 { $as_echo "$as_me:$LINENO: result: $with_gssapi" >&5
5122 $as_echo "$with_gssapi" >&6; }
5123
5124
5125 #
5126 # Kerberos 5
5127 #
5128 { $as_echo "$as_me:$LINENO: checking whether to build with Kerberos 5 support" >&5
5129 $as_echo_n "checking whether to build with Kerberos 5 support... " >&6; }
5130
5131
5132
5133 # Check whether --with-krb5 was given.
5134 if test "${with_krb5+set}" = set; then
5135   withval=$with_krb5;
5136   case $withval in
5137     yes)
5138
5139
5140 cat >>confdefs.h <<\_ACEOF
5141 #define KRB5 1
5142 _ACEOF
5143
5144   krb_srvtab="FILE:\$(sysconfdir)/krb5.keytab"
5145
5146       ;;
5147     no)
5148       :
5149       ;;
5150     *)
5151       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-krb5 option" >&5
5152 $as_echo "$as_me: error: no argument expected for --with-krb5 option" >&2;}
5153    { (exit 1); exit 1; }; }
5154       ;;
5155   esac
5156
5157 else
5158   with_krb5=no
5159
5160 fi
5161
5162
5163 { $as_echo "$as_me:$LINENO: result: $with_krb5" >&5
5164 $as_echo "$with_krb5" >&6; }
5165
5166
5167
5168
5169
5170
5171 #
5172 # Kerberos configuration parameters
5173 #
5174
5175
5176
5177 # Check whether --with-krb-srvnam was given.
5178 if test "${with_krb_srvnam+set}" = set; then
5179   withval=$with_krb_srvnam;
5180   case $withval in
5181     yes)
5182       { { $as_echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
5183 $as_echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
5184    { (exit 1); exit 1; }; }
5185       ;;
5186     no)
5187       { { $as_echo "$as_me:$LINENO: error: argument required for --with-krb-srvnam option" >&5
5188 $as_echo "$as_me: error: argument required for --with-krb-srvnam option" >&2;}
5189    { (exit 1); exit 1; }; }
5190       ;;
5191     *)
5192
5193       ;;
5194   esac
5195
5196 else
5197   with_krb_srvnam="postgres"
5198 fi
5199
5200
5201
5202 cat >>confdefs.h <<_ACEOF
5203 #define PG_KRB_SRVNAM "$with_krb_srvnam"
5204 _ACEOF
5205
5206
5207
5208 #
5209 # PAM
5210 #
5211 { $as_echo "$as_me:$LINENO: checking whether to build with PAM support" >&5
5212 $as_echo_n "checking whether to build with PAM support... " >&6; }
5213
5214
5215
5216 # Check whether --with-pam was given.
5217 if test "${with_pam+set}" = set; then
5218   withval=$with_pam;
5219   case $withval in
5220     yes)
5221
5222 cat >>confdefs.h <<\_ACEOF
5223 #define USE_PAM 1
5224 _ACEOF
5225
5226       ;;
5227     no)
5228       :
5229       ;;
5230     *)
5231       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-pam option" >&5
5232 $as_echo "$as_me: error: no argument expected for --with-pam option" >&2;}
5233    { (exit 1); exit 1; }; }
5234       ;;
5235   esac
5236
5237 else
5238   with_pam=no
5239
5240 fi
5241
5242
5243 { $as_echo "$as_me:$LINENO: result: $with_pam" >&5
5244 $as_echo "$with_pam" >&6; }
5245
5246
5247
5248 #
5249 # LDAP
5250 #
5251 { $as_echo "$as_me:$LINENO: checking whether to build with LDAP support" >&5
5252 $as_echo_n "checking whether to build with LDAP support... " >&6; }
5253
5254
5255
5256 # Check whether --with-ldap was given.
5257 if test "${with_ldap+set}" = set; then
5258   withval=$with_ldap;
5259   case $withval in
5260     yes)
5261
5262 cat >>confdefs.h <<\_ACEOF
5263 #define USE_LDAP 1
5264 _ACEOF
5265
5266       ;;
5267     no)
5268       :
5269       ;;
5270     *)
5271       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-ldap option" >&5
5272 $as_echo "$as_me: error: no argument expected for --with-ldap option" >&2;}
5273    { (exit 1); exit 1; }; }
5274       ;;
5275   esac
5276
5277 else
5278   with_ldap=no
5279
5280 fi
5281
5282
5283 { $as_echo "$as_me:$LINENO: result: $with_ldap" >&5
5284 $as_echo "$with_ldap" >&6; }
5285
5286
5287
5288 #
5289 # Bonjour
5290 #
5291 { $as_echo "$as_me:$LINENO: checking whether to build with Bonjour support" >&5
5292 $as_echo_n "checking whether to build with Bonjour support... " >&6; }
5293
5294
5295
5296 # Check whether --with-bonjour was given.
5297 if test "${with_bonjour+set}" = set; then
5298   withval=$with_bonjour;
5299   case $withval in
5300     yes)
5301
5302 cat >>confdefs.h <<\_ACEOF
5303 #define USE_BONJOUR 1
5304 _ACEOF
5305
5306       ;;
5307     no)
5308       :
5309       ;;
5310     *)
5311       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-bonjour option" >&5
5312 $as_echo "$as_me: error: no argument expected for --with-bonjour option" >&2;}
5313    { (exit 1); exit 1; }; }
5314       ;;
5315   esac
5316
5317 else
5318   with_bonjour=no
5319
5320 fi
5321
5322
5323 { $as_echo "$as_me:$LINENO: result: $with_bonjour" >&5
5324 $as_echo "$with_bonjour" >&6; }
5325
5326
5327
5328 #
5329 # OpenSSL
5330 #
5331 { $as_echo "$as_me:$LINENO: checking whether to build with OpenSSL support" >&5
5332 $as_echo_n "checking whether to build with OpenSSL support... " >&6; }
5333
5334
5335
5336 # Check whether --with-openssl was given.
5337 if test "${with_openssl+set}" = set; then
5338   withval=$with_openssl;
5339   case $withval in
5340     yes)
5341
5342 cat >>confdefs.h <<\_ACEOF
5343 #define USE_SSL 1
5344 _ACEOF
5345
5346       ;;
5347     no)
5348       :
5349       ;;
5350     *)
5351       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-openssl option" >&5
5352 $as_echo "$as_me: error: no argument expected for --with-openssl option" >&2;}
5353    { (exit 1); exit 1; }; }
5354       ;;
5355   esac
5356
5357 else
5358   with_openssl=no
5359
5360 fi
5361
5362
5363 { $as_echo "$as_me:$LINENO: result: $with_openssl" >&5
5364 $as_echo "$with_openssl" >&6; }
5365
5366
5367
5368 #
5369 # Readline
5370 #
5371
5372
5373
5374 # Check whether --with-readline was given.
5375 if test "${with_readline+set}" = set; then
5376   withval=$with_readline;
5377   case $withval in
5378     yes)
5379       :
5380       ;;
5381     no)
5382       :
5383       ;;
5384     *)
5385       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-readline option" >&5
5386 $as_echo "$as_me: error: no argument expected for --with-readline option" >&2;}
5387    { (exit 1); exit 1; }; }
5388       ;;
5389   esac
5390
5391 else
5392   with_readline=yes
5393
5394 fi
5395
5396
5397 # readline on MinGW has problems with backslashes in psql and other bugs.
5398 # This is particularly a problem with non-US code pages.
5399 # Therefore disable its use until we understand the cause. 2004-07-20
5400 if test "$PORTNAME" = "win32"; then
5401   if test "$with_readline" = yes; then
5402     { $as_echo "$as_me:$LINENO: WARNING: *** Readline does not work on MinGW --- disabling" >&5
5403 $as_echo "$as_me: WARNING: *** Readline does not work on MinGW --- disabling" >&2;}
5404     with_readline=no
5405   fi
5406 fi
5407
5408
5409 #
5410 # Prefer libedit
5411 #
5412
5413
5414
5415 # Check whether --with-libedit-preferred was given.
5416 if test "${with_libedit_preferred+set}" = set; then
5417   withval=$with_libedit_preferred;
5418   case $withval in
5419     yes)
5420       :
5421       ;;
5422     no)
5423       :
5424       ;;
5425     *)
5426       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libedit-preferred option" >&5
5427 $as_echo "$as_me: error: no argument expected for --with-libedit-preferred option" >&2;}
5428    { (exit 1); exit 1; }; }
5429       ;;
5430   esac
5431
5432 else
5433   with_libedit_preferred=no
5434
5435 fi
5436
5437
5438
5439
5440 #
5441 # OSSP UUID library
5442 #
5443
5444
5445
5446 # Check whether --with-ossp-uuid was given.
5447 if test "${with_ossp_uuid+set}" = set; then
5448   withval=$with_ossp_uuid;
5449   case $withval in
5450     yes)
5451       :
5452       ;;
5453     no)
5454       :
5455       ;;
5456     *)
5457       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-ossp-uuid option" >&5
5458 $as_echo "$as_me: error: no argument expected for --with-ossp-uuid option" >&2;}
5459    { (exit 1); exit 1; }; }
5460       ;;
5461   esac
5462
5463 else
5464   with_ossp_uuid=no
5465
5466 fi
5467
5468
5469
5470
5471
5472 #
5473 # XML
5474 #
5475
5476
5477
5478 # Check whether --with-libxml was given.
5479 if test "${with_libxml+set}" = set; then
5480   withval=$with_libxml;
5481   case $withval in
5482     yes)
5483
5484 cat >>confdefs.h <<\_ACEOF
5485 #define USE_LIBXML 1
5486 _ACEOF
5487
5488       ;;
5489     no)
5490       :
5491       ;;
5492     *)
5493       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libxml option" >&5
5494 $as_echo "$as_me: error: no argument expected for --with-libxml option" >&2;}
5495    { (exit 1); exit 1; }; }
5496       ;;
5497   esac
5498
5499 else
5500   with_libxml=no
5501
5502 fi
5503
5504
5505
5506 if test "$with_libxml" = yes ; then
5507   for ac_prog in xml2-config
5508 do
5509   # Extract the first word of "$ac_prog", so it can be a program name with args.
5510 set dummy $ac_prog; ac_word=$2
5511 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
5512 $as_echo_n "checking for $ac_word... " >&6; }
5513 if test "${ac_cv_prog_XML2_CONFIG+set}" = set; then
5514   $as_echo_n "(cached) " >&6
5515 else
5516   if test -n "$XML2_CONFIG"; then
5517   ac_cv_prog_XML2_CONFIG="$XML2_CONFIG" # Let the user override the test.
5518 else
5519 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5520 for as_dir in $PATH
5521 do
5522   IFS=$as_save_IFS
5523   test -z "$as_dir" && as_dir=.
5524   for ac_exec_ext in '' $ac_executable_extensions; do
5525   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
5526     ac_cv_prog_XML2_CONFIG="$ac_prog"
5527     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
5528     break 2
5529   fi
5530 done
5531 done
5532 IFS=$as_save_IFS
5533
5534 fi
5535 fi
5536 XML2_CONFIG=$ac_cv_prog_XML2_CONFIG
5537 if test -n "$XML2_CONFIG"; then
5538   { $as_echo "$as_me:$LINENO: result: $XML2_CONFIG" >&5
5539 $as_echo "$XML2_CONFIG" >&6; }
5540 else
5541   { $as_echo "$as_me:$LINENO: result: no" >&5
5542 $as_echo "no" >&6; }
5543 fi
5544
5545
5546   test -n "$XML2_CONFIG" && break
5547 done
5548
5549   if test -n "$XML2_CONFIG"; then
5550     for pgac_option in `$XML2_CONFIG --cflags`; do
5551       case $pgac_option in
5552         -I*|-D*) CPPFLAGS="$CPPFLAGS $pgac_option";;
5553       esac
5554     done
5555     for pgac_option in `$XML2_CONFIG --libs`; do
5556       case $pgac_option in
5557         -L*) LDFLAGS="$LDFLAGS $pgac_option";;
5558       esac
5559     done
5560   fi
5561 fi
5562
5563
5564
5565 #
5566 # XSLT
5567 #
5568
5569
5570
5571 # Check whether --with-libxslt was given.
5572 if test "${with_libxslt+set}" = set; then
5573   withval=$with_libxslt;
5574   case $withval in
5575     yes)
5576
5577 cat >>confdefs.h <<\_ACEOF
5578 #define USE_LIBXSLT 1
5579 _ACEOF
5580
5581       ;;
5582     no)
5583       :
5584       ;;
5585     *)
5586       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-libxslt option" >&5
5587 $as_echo "$as_me: error: no argument expected for --with-libxslt option" >&2;}
5588    { (exit 1); exit 1; }; }
5589       ;;
5590   esac
5591
5592 else
5593   with_libxslt=no
5594
5595 fi
5596
5597
5598
5599
5600
5601
5602 #
5603 # tzdata
5604 #
5605
5606
5607
5608 # Check whether --with-system-tzdata was given.
5609 if test "${with_system_tzdata+set}" = set; then
5610   withval=$with_system_tzdata;
5611   case $withval in
5612     yes)
5613       { { $as_echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5614 $as_echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5615    { (exit 1); exit 1; }; }
5616       ;;
5617     no)
5618       { { $as_echo "$as_me:$LINENO: error: argument required for --with-system-tzdata option" >&5
5619 $as_echo "$as_me: error: argument required for --with-system-tzdata option" >&2;}
5620    { (exit 1); exit 1; }; }
5621       ;;
5622     *)
5623
5624       ;;
5625   esac
5626
5627 fi
5628
5629
5630
5631
5632 #
5633 # Zlib
5634 #
5635
5636
5637
5638 # Check whether --with-zlib was given.
5639 if test "${with_zlib+set}" = set; then
5640   withval=$with_zlib;
5641   case $withval in
5642     yes)
5643       :
5644       ;;
5645     no)
5646       :
5647       ;;
5648     *)
5649       { { $as_echo "$as_me:$LINENO: error: no argument expected for --with-zlib option" >&5
5650 $as_echo "$as_me: error: no argument expected for --with-zlib option" >&2;}
5651    { (exit 1); exit 1; }; }
5652       ;;
5653   esac
5654
5655 else
5656   with_zlib=yes
5657
5658 fi
5659
5660
5661
5662
5663 #
5664 # Elf
5665 #
5666
5667 # Assume system is ELF if it predefines __ELF__ as 1,
5668 # otherwise believe host_os based default.
5669 case $host_os in
5670     freebsd1*|freebsd2*) elf=no;;
5671     freebsd3*|freebsd4*) elf=yes;;
5672 esac
5673
5674
5675 { $as_echo "$as_me:$LINENO: checking for grep that handles long lines and -e" >&5
5676 $as_echo_n "checking for grep that handles long lines and -e... " >&6; }
5677 if test "${ac_cv_path_GREP+set}" = set; then
5678   $as_echo_n "(cached) " >&6
5679 else
5680   if test -z "$GREP"; then
5681   ac_path_GREP_found=false
5682   # Loop through the user's path and test for each of PROGNAME-LIST
5683   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5684 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5685 do
5686   IFS=$as_save_IFS
5687   test -z "$as_dir" && as_dir=.
5688   for ac_prog in grep ggrep; do
5689     for ac_exec_ext in '' $ac_executable_extensions; do
5690       ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext"
5691       { test -f "$ac_path_GREP" && $as_test_x "$ac_path_GREP"; } || continue
5692 # Check for GNU ac_path_GREP and select it if it is found.
5693   # Check for GNU $ac_path_GREP
5694 case `"$ac_path_GREP" --version 2>&1` in
5695 *GNU*)
5696   ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;;
5697 *)
5698   ac_count=0
5699   $as_echo_n 0123456789 >"conftest.in"
5700   while :
5701   do
5702     cat "conftest.in" "conftest.in" >"conftest.tmp"
5703     mv "conftest.tmp" "conftest.in"
5704     cp "conftest.in" "conftest.nl"
5705     $as_echo 'GREP' >> "conftest.nl"
5706     "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5707     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5708     ac_count=`expr $ac_count + 1`
5709     if test $ac_count -gt ${ac_path_GREP_max-0}; then
5710       # Best one so far, save it but keep looking for a better one
5711       ac_cv_path_GREP="$ac_path_GREP"
5712       ac_path_GREP_max=$ac_count
5713     fi
5714     # 10*(2^10) chars as input seems more than enough
5715     test $ac_count -gt 10 && break
5716   done
5717   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5718 esac
5719
5720       $ac_path_GREP_found && break 3
5721     done
5722   done
5723 done
5724 IFS=$as_save_IFS
5725   if test -z "$ac_cv_path_GREP"; then
5726     { { $as_echo "$as_me:$LINENO: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5727 $as_echo "$as_me: error: no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5728    { (exit 1); exit 1; }; }
5729   fi
5730 else
5731   ac_cv_path_GREP=$GREP
5732 fi
5733
5734 fi
5735 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_GREP" >&5
5736 $as_echo "$ac_cv_path_GREP" >&6; }
5737  GREP="$ac_cv_path_GREP"
5738
5739
5740 { $as_echo "$as_me:$LINENO: checking for egrep" >&5
5741 $as_echo_n "checking for egrep... " >&6; }
5742 if test "${ac_cv_path_EGREP+set}" = set; then
5743   $as_echo_n "(cached) " >&6
5744 else
5745   if echo a | $GREP -E '(a|b)' >/dev/null 2>&1
5746    then ac_cv_path_EGREP="$GREP -E"
5747    else
5748      if test -z "$EGREP"; then
5749   ac_path_EGREP_found=false
5750   # Loop through the user's path and test for each of PROGNAME-LIST
5751   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
5752 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin
5753 do
5754   IFS=$as_save_IFS
5755   test -z "$as_dir" && as_dir=.
5756   for ac_prog in egrep; do
5757     for ac_exec_ext in '' $ac_executable_extensions; do
5758       ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext"
5759       { test -f "$ac_path_EGREP" && $as_test_x "$ac_path_EGREP"; } || continue
5760 # Check for GNU ac_path_EGREP and select it if it is found.
5761   # Check for GNU $ac_path_EGREP
5762 case `"$ac_path_EGREP" --version 2>&1` in
5763 *GNU*)
5764   ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;;
5765 *)
5766   ac_count=0
5767   $as_echo_n 0123456789 >"conftest.in"
5768   while :
5769   do
5770     cat "conftest.in" "conftest.in" >"conftest.tmp"
5771     mv "conftest.tmp" "conftest.in"
5772     cp "conftest.in" "conftest.nl"
5773     $as_echo 'EGREP' >> "conftest.nl"
5774     "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break
5775     diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break
5776     ac_count=`expr $ac_count + 1`
5777     if test $ac_count -gt ${ac_path_EGREP_max-0}; then
5778       # Best one so far, save it but keep looking for a better one
5779       ac_cv_path_EGREP="$ac_path_EGREP"
5780       ac_path_EGREP_max=$ac_count
5781     fi
5782     # 10*(2^10) chars as input seems more than enough
5783     test $ac_count -gt 10 && break
5784   done
5785   rm -f conftest.in conftest.tmp conftest.nl conftest.out;;
5786 esac
5787
5788       $ac_path_EGREP_found && break 3
5789     done
5790   done
5791 done
5792 IFS=$as_save_IFS
5793   if test -z "$ac_cv_path_EGREP"; then
5794     { { $as_echo "$as_me:$LINENO: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&5
5795 $as_echo "$as_me: error: no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" >&2;}
5796    { (exit 1); exit 1; }; }
5797   fi
5798 else
5799   ac_cv_path_EGREP=$EGREP
5800 fi
5801
5802    fi
5803 fi
5804 { $as_echo "$as_me:$LINENO: result: $ac_cv_path_EGREP" >&5
5805 $as_echo "$ac_cv_path_EGREP" >&6; }
5806  EGREP="$ac_cv_path_EGREP"
5807
5808
5809 cat >conftest.$ac_ext <<_ACEOF
5810 /* confdefs.h.  */
5811 _ACEOF
5812 cat confdefs.h >>conftest.$ac_ext
5813 cat >>conftest.$ac_ext <<_ACEOF
5814 /* end confdefs.h.  */
5815 #if __ELF__
5816   yes
5817 #endif
5818
5819 _ACEOF
5820 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
5821   $EGREP "yes" >/dev/null 2>&1; then
5822   ELF_SYS=true
5823 else
5824   if test "X$elf" = "Xyes" ; then
5825   ELF_SYS=true
5826 else
5827   ELF_SYS=
5828 fi
5829 fi
5830 rm -f conftest*
5831
5832
5833
5834 #
5835 # Assignments
5836 #
5837
5838 CPPFLAGS="$CPPFLAGS $INCLUDES"
5839 LDFLAGS="$LDFLAGS $LIBDIRS"
5840
5841
5842
5843
5844
5845 # Check whether --with-gnu-ld was given.
5846 if test "${with_gnu_ld+set}" = set; then
5847   withval=$with_gnu_ld; test "$withval" = no || with_gnu_ld=yes
5848 else
5849   with_gnu_ld=no
5850 fi
5851
5852 ac_prog=ld
5853 if test "$GCC" = yes; then
5854   # Check if gcc -print-prog-name=ld gives a path.
5855   { $as_echo "$as_me:$LINENO: checking for ld used by GCC" >&5
5856 $as_echo_n "checking for ld used by GCC... " >&6; }
5857   case $host in
5858   *-*-mingw*)
5859     # gcc leaves a trailing carriage return which upsets mingw
5860     ac_prog=`($CC -print-prog-name=ld) 2>&5 | tr -d '\015'` ;;
5861   *)
5862     ac_prog=`($CC -print-prog-name=ld) 2>&5` ;;
5863   esac
5864   case "$ac_prog" in
5865     # Accept absolute paths.
5866     [\\/]* | [A-Za-z]:[\\/]*)
5867       re_direlt='/[^/][^/]*/\.\./'
5868       # Canonicalize the path of ld
5869       ac_prog=`echo $ac_prog| sed 's%\\\\%/%g'`
5870       while echo $ac_prog | grep "$re_direlt" > /dev/null 2>&1; do
5871         ac_prog=`echo $ac_prog| sed "s%$re_direlt%/%"`
5872       done
5873       test -z "$LD" && LD="$ac_prog"
5874       ;;
5875   "")
5876     # If it fails, then pretend we aren't using GCC.
5877     ac_prog=ld
5878     ;;
5879   *)
5880     # If it is relative, then search for the first ld in PATH.
5881     with_gnu_ld=unknown
5882     ;;
5883   esac
5884 elif test "$with_gnu_ld" = yes; then
5885   { $as_echo "$as_me:$LINENO: checking for GNU ld" >&5
5886 $as_echo_n "checking for GNU ld... " >&6; }
5887 else
5888   { $as_echo "$as_me:$LINENO: checking for non-GNU ld" >&5
5889 $as_echo_n "checking for non-GNU ld... " >&6; }
5890 fi
5891 if test "${ac_cv_path_LD+set}" = set; then
5892   $as_echo_n "(cached) " >&6
5893 else
5894   if test -z "$LD"; then
5895   IFS="${IFS=   }"; ac_save_ifs="$IFS"; IFS="${IFS}${PATH_SEPARATOR-:}"
5896   for ac_dir in $PATH; do
5897     test -z "$ac_dir" && ac_dir=.
5898     if test -f "$ac_dir/$ac_prog" || test -f "$ac_dir/$ac_prog$ac_exeext"; then
5899       ac_cv_path_LD="$ac_dir/$ac_prog"
5900       # Check to see if the program is GNU ld.  I'd rather use --version,
5901       # but apparently some GNU ld's only accept -v.
5902       # Break only if it was the GNU/non-GNU ld that we prefer.
5903       if "$ac_cv_path_LD" -v 2>&1 < /dev/null | egrep '(GNU|with BFD)' > /dev/null; then
5904         test "$with_gnu_ld" != no && break
5905       else
5906         test "$with_gnu_ld" != yes && break
5907       fi
5908     fi
5909   done
5910   IFS="$ac_save_ifs"
5911 else
5912   ac_cv_path_LD="$LD" # Let the user override the test with a path.
5913 fi
5914 fi
5915
5916 LD="$ac_cv_path_LD"
5917 if test -n "$LD"; then
5918   { $as_echo "$as_me:$LINENO: result: $LD" >&5
5919 $as_echo "$LD" >&6; }
5920 else
5921   { $as_echo "$as_me:$LINENO: result: no" >&5
5922 $as_echo "no" >&6; }
5923 fi
5924 test -z "$LD" && { { $as_echo "$as_me:$LINENO: error: no acceptable ld found in \$PATH" >&5
5925 $as_echo "$as_me: error: no acceptable ld found in \$PATH" >&2;}
5926    { (exit 1); exit 1; }; }
5927 { $as_echo "$as_me:$LINENO: checking if the linker ($LD) is GNU ld" >&5
5928 $as_echo_n "checking if the linker ($LD) is GNU ld... " >&6; }
5929 if test "${ac_cv_prog_gnu_ld+set}" = set; then
5930   $as_echo_n "(cached) " >&6
5931 else
5932   # I'd rather use --version here, but apparently some GNU ld's only accept -v.
5933 if $LD -v 2>&1 </dev/null | egrep '(GNU|with BFD)' 1>&5; then
5934   ac_cv_prog_gnu_ld=yes
5935 else
5936   ac_cv_prog_gnu_ld=no
5937 fi
5938 fi
5939 { $as_echo "$as_me:$LINENO: result: $ac_cv_prog_gnu_ld" >&5
5940 $as_echo "$ac_cv_prog_gnu_ld" >&6; }
5941 with_gnu_ld=$ac_cv_prog_gnu_ld
5942
5943
5944
5945
5946 case $host_os in sysv5*)
5947   { $as_echo "$as_me:$LINENO: checking whether ld -R works" >&5
5948 $as_echo_n "checking whether ld -R works... " >&6; }
5949 if test "${pgac_cv_prog_ld_R+set}" = set; then
5950   $as_echo_n "(cached) " >&6
5951 else
5952
5953     pgac_save_LDFLAGS=$LDFLAGS; LDFLAGS="$LDFLAGS -Wl,-R/usr/lib"
5954     cat >conftest.$ac_ext <<_ACEOF
5955 /* confdefs.h.  */
5956 _ACEOF
5957 cat confdefs.h >>conftest.$ac_ext
5958 cat >>conftest.$ac_ext <<_ACEOF
5959 /* end confdefs.h.  */
5960
5961 int
5962 main ()
5963 {
5964
5965   ;
5966   return 0;
5967 }
5968 _ACEOF
5969 rm -f conftest.$ac_objext conftest$ac_exeext
5970 if { (ac_try="$ac_link"
5971 case "(($ac_try" in
5972   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
5973   *) ac_try_echo=$ac_try;;
5974 esac
5975 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
5976 $as_echo "$ac_try_echo") >&5
5977   (eval "$ac_link") 2>conftest.er1
5978   ac_status=$?
5979   grep -v '^ *+' conftest.er1 >conftest.err
5980   rm -f conftest.er1
5981   cat conftest.err >&5
5982   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
5983   (exit $ac_status); } && {
5984          test -z "$ac_c_werror_flag" ||
5985          test ! -s conftest.err
5986        } && test -s conftest$ac_exeext && {
5987          test "$cross_compiling" = yes ||
5988          $as_test_x conftest$ac_exeext
5989        }; then
5990   pgac_cv_prog_ld_R=yes
5991 else
5992   $as_echo "$as_me: failed program was:" >&5
5993 sed 's/^/| /' conftest.$ac_ext >&5
5994
5995         pgac_cv_prog_ld_R=no
5996 fi
5997
5998 rm -rf conftest.dSYM
5999 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
6000       conftest$ac_exeext conftest.$ac_ext
6001     LDFLAGS=$pgac_save_LDFLAGS
6002
6003 fi
6004 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_ld_R" >&5
6005 $as_echo "$pgac_cv_prog_ld_R" >&6; }
6006   ld_R_works=$pgac_cv_prog_ld_R
6007
6008 esac
6009 if test -n "$ac_tool_prefix"; then
6010   # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args.
6011 set dummy ${ac_tool_prefix}ranlib; ac_word=$2
6012 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6013 $as_echo_n "checking for $ac_word... " >&6; }
6014 if test "${ac_cv_prog_RANLIB+set}" = set; then
6015   $as_echo_n "(cached) " >&6
6016 else
6017   if test -n "$RANLIB"; then
6018   ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test.
6019 else
6020 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6021 for as_dir in $PATH
6022 do
6023   IFS=$as_save_IFS
6024   test -z "$as_dir" && as_dir=.
6025   for ac_exec_ext in '' $ac_executable_extensions; do
6026   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6027     ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib"
6028     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6029     break 2
6030   fi
6031 done
6032 done
6033 IFS=$as_save_IFS
6034
6035 fi
6036 fi
6037 RANLIB=$ac_cv_prog_RANLIB
6038 if test -n "$RANLIB"; then
6039   { $as_echo "$as_me:$LINENO: result: $RANLIB" >&5
6040 $as_echo "$RANLIB" >&6; }
6041 else
6042   { $as_echo "$as_me:$LINENO: result: no" >&5
6043 $as_echo "no" >&6; }
6044 fi
6045
6046
6047 fi
6048 if test -z "$ac_cv_prog_RANLIB"; then
6049   ac_ct_RANLIB=$RANLIB
6050   # Extract the first word of "ranlib", so it can be a program name with args.
6051 set dummy ranlib; ac_word=$2
6052 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6053 $as_echo_n "checking for $ac_word... " >&6; }
6054 if test "${ac_cv_prog_ac_ct_RANLIB+set}" = set; then
6055   $as_echo_n "(cached) " >&6
6056 else
6057   if test -n "$ac_ct_RANLIB"; then
6058   ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test.
6059 else
6060 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6061 for as_dir in $PATH
6062 do
6063   IFS=$as_save_IFS
6064   test -z "$as_dir" && as_dir=.
6065   for ac_exec_ext in '' $ac_executable_extensions; do
6066   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6067     ac_cv_prog_ac_ct_RANLIB="ranlib"
6068     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6069     break 2
6070   fi
6071 done
6072 done
6073 IFS=$as_save_IFS
6074
6075 fi
6076 fi
6077 ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB
6078 if test -n "$ac_ct_RANLIB"; then
6079   { $as_echo "$as_me:$LINENO: result: $ac_ct_RANLIB" >&5
6080 $as_echo "$ac_ct_RANLIB" >&6; }
6081 else
6082   { $as_echo "$as_me:$LINENO: result: no" >&5
6083 $as_echo "no" >&6; }
6084 fi
6085
6086   if test "x$ac_ct_RANLIB" = x; then
6087     RANLIB=":"
6088   else
6089     case $cross_compiling:$ac_tool_warned in
6090 yes:)
6091 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6092 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6093 ac_tool_warned=yes ;;
6094 esac
6095     RANLIB=$ac_ct_RANLIB
6096   fi
6097 else
6098   RANLIB="$ac_cv_prog_RANLIB"
6099 fi
6100
6101
6102   if test -n "$ac_tool_prefix"; then
6103   # Extract the first word of "${ac_tool_prefix}strip", so it can be a program name with args.
6104 set dummy ${ac_tool_prefix}strip; ac_word=$2
6105 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6106 $as_echo_n "checking for $ac_word... " >&6; }
6107 if test "${ac_cv_prog_STRIP+set}" = set; then
6108   $as_echo_n "(cached) " >&6
6109 else
6110   if test -n "$STRIP"; then
6111   ac_cv_prog_STRIP="$STRIP" # Let the user override the test.
6112 else
6113 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6114 for as_dir in $PATH
6115 do
6116   IFS=$as_save_IFS
6117   test -z "$as_dir" && as_dir=.
6118   for ac_exec_ext in '' $ac_executable_extensions; do
6119   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6120     ac_cv_prog_STRIP="${ac_tool_prefix}strip"
6121     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6122     break 2
6123   fi
6124 done
6125 done
6126 IFS=$as_save_IFS
6127
6128 fi
6129 fi
6130 STRIP=$ac_cv_prog_STRIP
6131 if test -n "$STRIP"; then
6132   { $as_echo "$as_me:$LINENO: result: $STRIP" >&5
6133 $as_echo "$STRIP" >&6; }
6134 else
6135   { $as_echo "$as_me:$LINENO: result: no" >&5
6136 $as_echo "no" >&6; }
6137 fi
6138
6139
6140 fi
6141 if test -z "$ac_cv_prog_STRIP"; then
6142   ac_ct_STRIP=$STRIP
6143   # Extract the first word of "strip", so it can be a program name with args.
6144 set dummy strip; ac_word=$2
6145 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6146 $as_echo_n "checking for $ac_word... " >&6; }
6147 if test "${ac_cv_prog_ac_ct_STRIP+set}" = set; then
6148   $as_echo_n "(cached) " >&6
6149 else
6150   if test -n "$ac_ct_STRIP"; then
6151   ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test.
6152 else
6153 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6154 for as_dir in $PATH
6155 do
6156   IFS=$as_save_IFS
6157   test -z "$as_dir" && as_dir=.
6158   for ac_exec_ext in '' $ac_executable_extensions; do
6159   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6160     ac_cv_prog_ac_ct_STRIP="strip"
6161     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6162     break 2
6163   fi
6164 done
6165 done
6166 IFS=$as_save_IFS
6167
6168 fi
6169 fi
6170 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP
6171 if test -n "$ac_ct_STRIP"; then
6172   { $as_echo "$as_me:$LINENO: result: $ac_ct_STRIP" >&5
6173 $as_echo "$ac_ct_STRIP" >&6; }
6174 else
6175   { $as_echo "$as_me:$LINENO: result: no" >&5
6176 $as_echo "no" >&6; }
6177 fi
6178
6179   if test "x$ac_ct_STRIP" = x; then
6180     STRIP=":"
6181   else
6182     case $cross_compiling:$ac_tool_warned in
6183 yes:)
6184 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6185 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6186 ac_tool_warned=yes ;;
6187 esac
6188     STRIP=$ac_ct_STRIP
6189   fi
6190 else
6191   STRIP="$ac_cv_prog_STRIP"
6192 fi
6193
6194
6195   { $as_echo "$as_me:$LINENO: checking whether it is possible to strip libraries" >&5
6196 $as_echo_n "checking whether it is possible to strip libraries... " >&6; }
6197   if test x"$STRIP" != x"" && "$STRIP" -V 2>&1 | grep "GNU strip" >/dev/null; then
6198     STRIP_STATIC_LIB="$STRIP -x"
6199     STRIP_SHARED_LIB="$STRIP --strip-unneeded"
6200     { $as_echo "$as_me:$LINENO: result: yes" >&5
6201 $as_echo "yes" >&6; }
6202   else
6203     STRIP_STATIC_LIB=:
6204     STRIP_SHARED_LIB=:
6205     { $as_echo "$as_me:$LINENO: result: no" >&5
6206 $as_echo "no" >&6; }
6207   fi
6208
6209
6210
6211 if test -n "$ac_tool_prefix"; then
6212   # Extract the first word of "${ac_tool_prefix}ar", so it can be a program name with args.
6213 set dummy ${ac_tool_prefix}ar; ac_word=$2
6214 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6215 $as_echo_n "checking for $ac_word... " >&6; }
6216 if test "${ac_cv_prog_AR+set}" = set; then
6217   $as_echo_n "(cached) " >&6
6218 else
6219   if test -n "$AR"; then
6220   ac_cv_prog_AR="$AR" # Let the user override the test.
6221 else
6222 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6223 for as_dir in $PATH
6224 do
6225   IFS=$as_save_IFS
6226   test -z "$as_dir" && as_dir=.
6227   for ac_exec_ext in '' $ac_executable_extensions; do
6228   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6229     ac_cv_prog_AR="${ac_tool_prefix}ar"
6230     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6231     break 2
6232   fi
6233 done
6234 done
6235 IFS=$as_save_IFS
6236
6237 fi
6238 fi
6239 AR=$ac_cv_prog_AR
6240 if test -n "$AR"; then
6241   { $as_echo "$as_me:$LINENO: result: $AR" >&5
6242 $as_echo "$AR" >&6; }
6243 else
6244   { $as_echo "$as_me:$LINENO: result: no" >&5
6245 $as_echo "no" >&6; }
6246 fi
6247
6248
6249 fi
6250 if test -z "$ac_cv_prog_AR"; then
6251   ac_ct_AR=$AR
6252   # Extract the first word of "ar", so it can be a program name with args.
6253 set dummy ar; ac_word=$2
6254 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6255 $as_echo_n "checking for $ac_word... " >&6; }
6256 if test "${ac_cv_prog_ac_ct_AR+set}" = set; then
6257   $as_echo_n "(cached) " >&6
6258 else
6259   if test -n "$ac_ct_AR"; then
6260   ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test.
6261 else
6262 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6263 for as_dir in $PATH
6264 do
6265   IFS=$as_save_IFS
6266   test -z "$as_dir" && as_dir=.
6267   for ac_exec_ext in '' $ac_executable_extensions; do
6268   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6269     ac_cv_prog_ac_ct_AR="ar"
6270     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6271     break 2
6272   fi
6273 done
6274 done
6275 IFS=$as_save_IFS
6276
6277 fi
6278 fi
6279 ac_ct_AR=$ac_cv_prog_ac_ct_AR
6280 if test -n "$ac_ct_AR"; then
6281   { $as_echo "$as_me:$LINENO: result: $ac_ct_AR" >&5
6282 $as_echo "$ac_ct_AR" >&6; }
6283 else
6284   { $as_echo "$as_me:$LINENO: result: no" >&5
6285 $as_echo "no" >&6; }
6286 fi
6287
6288   if test "x$ac_ct_AR" = x; then
6289     AR="ar"
6290   else
6291     case $cross_compiling:$ac_tool_warned in
6292 yes:)
6293 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6294 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6295 ac_tool_warned=yes ;;
6296 esac
6297     AR=$ac_ct_AR
6298   fi
6299 else
6300   AR="$ac_cv_prog_AR"
6301 fi
6302
6303 if test "$PORTNAME" = "win32"; then
6304   if test -n "$ac_tool_prefix"; then
6305   # Extract the first word of "${ac_tool_prefix}dlltool", so it can be a program name with args.
6306 set dummy ${ac_tool_prefix}dlltool; ac_word=$2
6307 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6308 $as_echo_n "checking for $ac_word... " >&6; }
6309 if test "${ac_cv_prog_DLLTOOL+set}" = set; then
6310   $as_echo_n "(cached) " >&6
6311 else
6312   if test -n "$DLLTOOL"; then
6313   ac_cv_prog_DLLTOOL="$DLLTOOL" # Let the user override the test.
6314 else
6315 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6316 for as_dir in $PATH
6317 do
6318   IFS=$as_save_IFS
6319   test -z "$as_dir" && as_dir=.
6320   for ac_exec_ext in '' $ac_executable_extensions; do
6321   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6322     ac_cv_prog_DLLTOOL="${ac_tool_prefix}dlltool"
6323     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6324     break 2
6325   fi
6326 done
6327 done
6328 IFS=$as_save_IFS
6329
6330 fi
6331 fi
6332 DLLTOOL=$ac_cv_prog_DLLTOOL
6333 if test -n "$DLLTOOL"; then
6334   { $as_echo "$as_me:$LINENO: result: $DLLTOOL" >&5
6335 $as_echo "$DLLTOOL" >&6; }
6336 else
6337   { $as_echo "$as_me:$LINENO: result: no" >&5
6338 $as_echo "no" >&6; }
6339 fi
6340
6341
6342 fi
6343 if test -z "$ac_cv_prog_DLLTOOL"; then
6344   ac_ct_DLLTOOL=$DLLTOOL
6345   # Extract the first word of "dlltool", so it can be a program name with args.
6346 set dummy dlltool; ac_word=$2
6347 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6348 $as_echo_n "checking for $ac_word... " >&6; }
6349 if test "${ac_cv_prog_ac_ct_DLLTOOL+set}" = set; then
6350   $as_echo_n "(cached) " >&6
6351 else
6352   if test -n "$ac_ct_DLLTOOL"; then
6353   ac_cv_prog_ac_ct_DLLTOOL="$ac_ct_DLLTOOL" # Let the user override the test.
6354 else
6355 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6356 for as_dir in $PATH
6357 do
6358   IFS=$as_save_IFS
6359   test -z "$as_dir" && as_dir=.
6360   for ac_exec_ext in '' $ac_executable_extensions; do
6361   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6362     ac_cv_prog_ac_ct_DLLTOOL="dlltool"
6363     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6364     break 2
6365   fi
6366 done
6367 done
6368 IFS=$as_save_IFS
6369
6370 fi
6371 fi
6372 ac_ct_DLLTOOL=$ac_cv_prog_ac_ct_DLLTOOL
6373 if test -n "$ac_ct_DLLTOOL"; then
6374   { $as_echo "$as_me:$LINENO: result: $ac_ct_DLLTOOL" >&5
6375 $as_echo "$ac_ct_DLLTOOL" >&6; }
6376 else
6377   { $as_echo "$as_me:$LINENO: result: no" >&5
6378 $as_echo "no" >&6; }
6379 fi
6380
6381   if test "x$ac_ct_DLLTOOL" = x; then
6382     DLLTOOL="dlltool"
6383   else
6384     case $cross_compiling:$ac_tool_warned in
6385 yes:)
6386 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6387 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6388 ac_tool_warned=yes ;;
6389 esac
6390     DLLTOOL=$ac_ct_DLLTOOL
6391   fi
6392 else
6393   DLLTOOL="$ac_cv_prog_DLLTOOL"
6394 fi
6395
6396   if test -n "$ac_tool_prefix"; then
6397   # Extract the first word of "${ac_tool_prefix}dllwrap", so it can be a program name with args.
6398 set dummy ${ac_tool_prefix}dllwrap; ac_word=$2
6399 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6400 $as_echo_n "checking for $ac_word... " >&6; }
6401 if test "${ac_cv_prog_DLLWRAP+set}" = set; then
6402   $as_echo_n "(cached) " >&6
6403 else
6404   if test -n "$DLLWRAP"; then
6405   ac_cv_prog_DLLWRAP="$DLLWRAP" # Let the user override the test.
6406 else
6407 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6408 for as_dir in $PATH
6409 do
6410   IFS=$as_save_IFS
6411   test -z "$as_dir" && as_dir=.
6412   for ac_exec_ext in '' $ac_executable_extensions; do
6413   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6414     ac_cv_prog_DLLWRAP="${ac_tool_prefix}dllwrap"
6415     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6416     break 2
6417   fi
6418 done
6419 done
6420 IFS=$as_save_IFS
6421
6422 fi
6423 fi
6424 DLLWRAP=$ac_cv_prog_DLLWRAP
6425 if test -n "$DLLWRAP"; then
6426   { $as_echo "$as_me:$LINENO: result: $DLLWRAP" >&5
6427 $as_echo "$DLLWRAP" >&6; }
6428 else
6429   { $as_echo "$as_me:$LINENO: result: no" >&5
6430 $as_echo "no" >&6; }
6431 fi
6432
6433
6434 fi
6435 if test -z "$ac_cv_prog_DLLWRAP"; then
6436   ac_ct_DLLWRAP=$DLLWRAP
6437   # Extract the first word of "dllwrap", so it can be a program name with args.
6438 set dummy dllwrap; ac_word=$2
6439 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6440 $as_echo_n "checking for $ac_word... " >&6; }
6441 if test "${ac_cv_prog_ac_ct_DLLWRAP+set}" = set; then
6442   $as_echo_n "(cached) " >&6
6443 else
6444   if test -n "$ac_ct_DLLWRAP"; then
6445   ac_cv_prog_ac_ct_DLLWRAP="$ac_ct_DLLWRAP" # Let the user override the test.
6446 else
6447 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6448 for as_dir in $PATH
6449 do
6450   IFS=$as_save_IFS
6451   test -z "$as_dir" && as_dir=.
6452   for ac_exec_ext in '' $ac_executable_extensions; do
6453   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6454     ac_cv_prog_ac_ct_DLLWRAP="dllwrap"
6455     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6456     break 2
6457   fi
6458 done
6459 done
6460 IFS=$as_save_IFS
6461
6462 fi
6463 fi
6464 ac_ct_DLLWRAP=$ac_cv_prog_ac_ct_DLLWRAP
6465 if test -n "$ac_ct_DLLWRAP"; then
6466   { $as_echo "$as_me:$LINENO: result: $ac_ct_DLLWRAP" >&5
6467 $as_echo "$ac_ct_DLLWRAP" >&6; }
6468 else
6469   { $as_echo "$as_me:$LINENO: result: no" >&5
6470 $as_echo "no" >&6; }
6471 fi
6472
6473   if test "x$ac_ct_DLLWRAP" = x; then
6474     DLLWRAP="dllwrap"
6475   else
6476     case $cross_compiling:$ac_tool_warned in
6477 yes:)
6478 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6479 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6480 ac_tool_warned=yes ;;
6481 esac
6482     DLLWRAP=$ac_ct_DLLWRAP
6483   fi
6484 else
6485   DLLWRAP="$ac_cv_prog_DLLWRAP"
6486 fi
6487
6488   if test -n "$ac_tool_prefix"; then
6489   # Extract the first word of "${ac_tool_prefix}windres", so it can be a program name with args.
6490 set dummy ${ac_tool_prefix}windres; ac_word=$2
6491 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6492 $as_echo_n "checking for $ac_word... " >&6; }
6493 if test "${ac_cv_prog_WINDRES+set}" = set; then
6494   $as_echo_n "(cached) " >&6
6495 else
6496   if test -n "$WINDRES"; then
6497   ac_cv_prog_WINDRES="$WINDRES" # Let the user override the test.
6498 else
6499 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6500 for as_dir in $PATH
6501 do
6502   IFS=$as_save_IFS
6503   test -z "$as_dir" && as_dir=.
6504   for ac_exec_ext in '' $ac_executable_extensions; do
6505   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6506     ac_cv_prog_WINDRES="${ac_tool_prefix}windres"
6507     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6508     break 2
6509   fi
6510 done
6511 done
6512 IFS=$as_save_IFS
6513
6514 fi
6515 fi
6516 WINDRES=$ac_cv_prog_WINDRES
6517 if test -n "$WINDRES"; then
6518   { $as_echo "$as_me:$LINENO: result: $WINDRES" >&5
6519 $as_echo "$WINDRES" >&6; }
6520 else
6521   { $as_echo "$as_me:$LINENO: result: no" >&5
6522 $as_echo "no" >&6; }
6523 fi
6524
6525
6526 fi
6527 if test -z "$ac_cv_prog_WINDRES"; then
6528   ac_ct_WINDRES=$WINDRES
6529   # Extract the first word of "windres", so it can be a program name with args.
6530 set dummy windres; ac_word=$2
6531 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6532 $as_echo_n "checking for $ac_word... " >&6; }
6533 if test "${ac_cv_prog_ac_ct_WINDRES+set}" = set; then
6534   $as_echo_n "(cached) " >&6
6535 else
6536   if test -n "$ac_ct_WINDRES"; then
6537   ac_cv_prog_ac_ct_WINDRES="$ac_ct_WINDRES" # Let the user override the test.
6538 else
6539 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6540 for as_dir in $PATH
6541 do
6542   IFS=$as_save_IFS
6543   test -z "$as_dir" && as_dir=.
6544   for ac_exec_ext in '' $ac_executable_extensions; do
6545   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6546     ac_cv_prog_ac_ct_WINDRES="windres"
6547     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6548     break 2
6549   fi
6550 done
6551 done
6552 IFS=$as_save_IFS
6553
6554 fi
6555 fi
6556 ac_ct_WINDRES=$ac_cv_prog_ac_ct_WINDRES
6557 if test -n "$ac_ct_WINDRES"; then
6558   { $as_echo "$as_me:$LINENO: result: $ac_ct_WINDRES" >&5
6559 $as_echo "$ac_ct_WINDRES" >&6; }
6560 else
6561   { $as_echo "$as_me:$LINENO: result: no" >&5
6562 $as_echo "no" >&6; }
6563 fi
6564
6565   if test "x$ac_ct_WINDRES" = x; then
6566     WINDRES="windres"
6567   else
6568     case $cross_compiling:$ac_tool_warned in
6569 yes:)
6570 { $as_echo "$as_me:$LINENO: WARNING: using cross tools not prefixed with host triplet" >&5
6571 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
6572 ac_tool_warned=yes ;;
6573 esac
6574     WINDRES=$ac_ct_WINDRES
6575   fi
6576 else
6577   WINDRES="$ac_cv_prog_WINDRES"
6578 fi
6579
6580 fi
6581
6582 # Extract the first word of "tar", so it can be a program name with args.
6583 set dummy tar; ac_word=$2
6584 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6585 $as_echo_n "checking for $ac_word... " >&6; }
6586 if test "${ac_cv_path_TAR+set}" = set; then
6587   $as_echo_n "(cached) " >&6
6588 else
6589   case $TAR in
6590   [\\/]* | ?:[\\/]*)
6591   ac_cv_path_TAR="$TAR" # Let the user override the test with a path.
6592   ;;
6593   *)
6594   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6595 for as_dir in $PATH
6596 do
6597   IFS=$as_save_IFS
6598   test -z "$as_dir" && as_dir=.
6599   for ac_exec_ext in '' $ac_executable_extensions; do
6600   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6601     ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext"
6602     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6603     break 2
6604   fi
6605 done
6606 done
6607 IFS=$as_save_IFS
6608
6609   ;;
6610 esac
6611 fi
6612 TAR=$ac_cv_path_TAR
6613 if test -n "$TAR"; then
6614   { $as_echo "$as_me:$LINENO: result: $TAR" >&5
6615 $as_echo "$TAR" >&6; }
6616 else
6617   { $as_echo "$as_me:$LINENO: result: no" >&5
6618 $as_echo "no" >&6; }
6619 fi
6620
6621
6622 { $as_echo "$as_me:$LINENO: checking whether ln -s works" >&5
6623 $as_echo_n "checking whether ln -s works... " >&6; }
6624 LN_S=$as_ln_s
6625 if test "$LN_S" = "ln -s"; then
6626   { $as_echo "$as_me:$LINENO: result: yes" >&5
6627 $as_echo "yes" >&6; }
6628 else
6629   { $as_echo "$as_me:$LINENO: result: no, using $LN_S" >&5
6630 $as_echo "no, using $LN_S" >&6; }
6631 fi
6632
6633 for ac_prog in gawk mawk nawk awk
6634 do
6635   # Extract the first word of "$ac_prog", so it can be a program name with args.
6636 set dummy $ac_prog; ac_word=$2
6637 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6638 $as_echo_n "checking for $ac_word... " >&6; }
6639 if test "${ac_cv_prog_AWK+set}" = set; then
6640   $as_echo_n "(cached) " >&6
6641 else
6642   if test -n "$AWK"; then
6643   ac_cv_prog_AWK="$AWK" # Let the user override the test.
6644 else
6645 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6646 for as_dir in $PATH
6647 do
6648   IFS=$as_save_IFS
6649   test -z "$as_dir" && as_dir=.
6650   for ac_exec_ext in '' $ac_executable_extensions; do
6651   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6652     ac_cv_prog_AWK="$ac_prog"
6653     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6654     break 2
6655   fi
6656 done
6657 done
6658 IFS=$as_save_IFS
6659
6660 fi
6661 fi
6662 AWK=$ac_cv_prog_AWK
6663 if test -n "$AWK"; then
6664   { $as_echo "$as_me:$LINENO: result: $AWK" >&5
6665 $as_echo "$AWK" >&6; }
6666 else
6667   { $as_echo "$as_me:$LINENO: result: no" >&5
6668 $as_echo "no" >&6; }
6669 fi
6670
6671
6672   test -n "$AWK" && break
6673 done
6674
6675 { $as_echo "$as_me:$LINENO: checking for a thread-safe mkdir -p" >&5
6676 $as_echo_n "checking for a thread-safe mkdir -p... " >&6; }
6677 if test -z "$MKDIR_P"; then
6678   if test "${ac_cv_path_mkdir+set}" = set; then
6679   $as_echo_n "(cached) " >&6
6680 else
6681   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6682 for as_dir in $PATH$PATH_SEPARATOR/opt/sfw/bin
6683 do
6684   IFS=$as_save_IFS
6685   test -z "$as_dir" && as_dir=.
6686   for ac_prog in mkdir gmkdir; do
6687          for ac_exec_ext in '' $ac_executable_extensions; do
6688            { test -f "$as_dir/$ac_prog$ac_exec_ext" && $as_test_x "$as_dir/$ac_prog$ac_exec_ext"; } || continue
6689            case `"$as_dir/$ac_prog$ac_exec_ext" --version 2>&1` in #(
6690              'mkdir (GNU coreutils) '* | \
6691              'mkdir (coreutils) '* | \
6692              'mkdir (fileutils) '4.1*)
6693                ac_cv_path_mkdir=$as_dir/$ac_prog$ac_exec_ext
6694                break 3;;
6695            esac
6696          done
6697        done
6698 done
6699 IFS=$as_save_IFS
6700
6701 fi
6702
6703   if test "${ac_cv_path_mkdir+set}" = set; then
6704     MKDIR_P="$ac_cv_path_mkdir -p"
6705   else
6706     # As a last resort, use the slow shell script.  Don't cache a
6707     # value for MKDIR_P within a source directory, because that will
6708     # break other packages using the cache if that directory is
6709     # removed, or if the value is a relative name.
6710     test -d ./--version && rmdir ./--version
6711     MKDIR_P="$ac_install_sh -d"
6712   fi
6713 fi
6714 { $as_echo "$as_me:$LINENO: result: $MKDIR_P" >&5
6715 $as_echo "$MKDIR_P" >&6; }
6716
6717 # When Autoconf chooses install-sh as mkdir -p program it tries to generate
6718 # a relative path to it in each makefile where it subsitutes it. This clashes
6719 # with our Makefile.global concept. This workaround helps.
6720 case $MKDIR_P in
6721   *install-sh*) MKDIR_P='\${SHELL} \${top_srcdir}/config/install-sh -c -d';;
6722 esac
6723
6724 # Let the user override the search
6725 if test -z "$BISON"; then
6726   for ac_prog in bison
6727 do
6728   # Extract the first word of "$ac_prog", so it can be a program name with args.
6729 set dummy $ac_prog; ac_word=$2
6730 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6731 $as_echo_n "checking for $ac_word... " >&6; }
6732 if test "${ac_cv_path_BISON+set}" = set; then
6733   $as_echo_n "(cached) " >&6
6734 else
6735   case $BISON in
6736   [\\/]* | ?:[\\/]*)
6737   ac_cv_path_BISON="$BISON" # Let the user override the test with a path.
6738   ;;
6739   *)
6740   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6741 for as_dir in $PATH
6742 do
6743   IFS=$as_save_IFS
6744   test -z "$as_dir" && as_dir=.
6745   for ac_exec_ext in '' $ac_executable_extensions; do
6746   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6747     ac_cv_path_BISON="$as_dir/$ac_word$ac_exec_ext"
6748     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6749     break 2
6750   fi
6751 done
6752 done
6753 IFS=$as_save_IFS
6754
6755   ;;
6756 esac
6757 fi
6758 BISON=$ac_cv_path_BISON
6759 if test -n "$BISON"; then
6760   { $as_echo "$as_me:$LINENO: result: $BISON" >&5
6761 $as_echo "$BISON" >&6; }
6762 else
6763   { $as_echo "$as_me:$LINENO: result: no" >&5
6764 $as_echo "no" >&6; }
6765 fi
6766
6767
6768   test -n "$BISON" && break
6769 done
6770
6771 fi
6772
6773 if test "$BISON"; then
6774   pgac_bison_version=`$BISON --version 2>/dev/null | sed q`
6775   { $as_echo "$as_me:$LINENO: using $pgac_bison_version" >&5
6776 $as_echo "$as_me: using $pgac_bison_version" >&6;}
6777   if echo "$pgac_bison_version" | $AWK '{ if ($4 < 1.875) exit 0; else exit 1;}'
6778   then
6779     { $as_echo "$as_me:$LINENO: WARNING:
6780 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
6781 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&5
6782 $as_echo "$as_me: WARNING:
6783 *** The installed version of Bison, $BISON, is too old to use with PostgreSQL.
6784 *** Bison version 1.875 or later is required, but this is $pgac_bison_version." >&2;}
6785     BISON=""
6786   fi
6787 fi
6788
6789 if test -z "$BISON"; then
6790   { $as_echo "$as_me:$LINENO: WARNING:
6791 *** Without Bison you will not be able to build PostgreSQL from Git nor
6792 *** change any of the parser definition files.  You can obtain Bison from
6793 *** a GNU mirror site.  (If you are using the official distribution of
6794 *** PostgreSQL then you do not need to worry about this, because the Bison
6795 *** output is pre-generated.)" >&5
6796 $as_echo "$as_me: WARNING:
6797 *** Without Bison you will not be able to build PostgreSQL from Git nor
6798 *** change any of the parser definition files.  You can obtain Bison from
6799 *** a GNU mirror site.  (If you are using the official distribution of
6800 *** PostgreSQL then you do not need to worry about this, because the Bison
6801 *** output is pre-generated.)" >&2;}
6802 fi
6803 # We don't need AC_SUBST(BISON) because AC_PATH_PROG did it
6804
6805
6806 { $as_echo "$as_me:$LINENO: checking for flex" >&5
6807 $as_echo_n "checking for flex... " >&6; }
6808 if test "${pgac_cv_path_flex+set}" = set; then
6809   $as_echo_n "(cached) " >&6
6810 else
6811   # Let the user override the test
6812 if test -n "$FLEX"; then
6813   pgac_cv_path_flex=$FLEX
6814 else
6815   pgac_save_IFS=$IFS
6816   IFS=$PATH_SEPARATOR
6817   for pgac_dir in $PATH; do
6818     IFS=$pgac_save_IFS
6819     if test -z "$pgac_dir" || test x"$pgac_dir" = x"."; then
6820       pgac_dir=`pwd`
6821     fi
6822     for pgac_prog in flex lex; do
6823       pgac_candidate="$pgac_dir/$pgac_prog"
6824       if test -f "$pgac_candidate" \
6825         && $pgac_candidate --version </dev/null >/dev/null 2>&1
6826       then
6827         echo '%%'  > conftest.l
6828         if $pgac_candidate -t conftest.l 2>/dev/null | grep FLEX_SCANNER >/dev/null 2>&1; then
6829           pgac_flex_version=`$pgac_candidate --version 2>/dev/null`
6830           if echo "$pgac_flex_version" | sed 's/[.a-z]/ /g' | $AWK '{ if ($1 = 2 && $2 = 5 && $3 >= 31) exit 0; else exit 1;}'
6831           then
6832             pgac_cv_path_flex=$pgac_candidate
6833             break 2
6834           else
6835             { $as_echo "$as_me:$LINENO: WARNING:
6836 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
6837 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&5
6838 $as_echo "$as_me: WARNING:
6839 *** The installed version of Flex, $pgac_candidate, is too old to use with PostgreSQL.
6840 *** Flex version 2.5.31 or later is required, but this is $pgac_flex_version." >&2;}
6841           fi
6842         fi
6843       fi
6844     done
6845   done
6846   rm -f conftest.l lex.yy.c
6847   : ${pgac_cv_path_flex=no}
6848 fi
6849
6850 fi
6851 { $as_echo "$as_me:$LINENO: result: $pgac_cv_path_flex" >&5
6852 $as_echo "$pgac_cv_path_flex" >&6; }
6853 if test x"$pgac_cv_path_flex" = x"no"; then
6854   { $as_echo "$as_me:$LINENO: WARNING:
6855 *** Without Flex you will not be able to build PostgreSQL from Git nor
6856 *** change any of the scanner definition files.  You can obtain Flex from
6857 *** a GNU mirror site.  (If you are using the official distribution of
6858 *** PostgreSQL then you do not need to worry about this because the Flex
6859 *** output is pre-generated.)" >&5
6860 $as_echo "$as_me: WARNING:
6861 *** Without Flex you will not be able to build PostgreSQL from Git nor
6862 *** change any of the scanner definition files.  You can obtain Flex from
6863 *** a GNU mirror site.  (If you are using the official distribution of
6864 *** PostgreSQL then you do not need to worry about this because the Flex
6865 *** output is pre-generated.)" >&2;}
6866
6867   FLEX=
6868 else
6869   FLEX=$pgac_cv_path_flex
6870   pgac_flex_version=`$FLEX --version 2>/dev/null`
6871   { $as_echo "$as_me:$LINENO: using $pgac_flex_version" >&5
6872 $as_echo "$as_me: using $pgac_flex_version" >&6;}
6873 fi
6874
6875
6876
6877
6878
6879 # Let the user override the search
6880 if test -z "$PERL"; then
6881   # Extract the first word of "perl", so it can be a program name with args.
6882 set dummy perl; ac_word=$2
6883 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
6884 $as_echo_n "checking for $ac_word... " >&6; }
6885 if test "${ac_cv_path_PERL+set}" = set; then
6886   $as_echo_n "(cached) " >&6
6887 else
6888   case $PERL in
6889   [\\/]* | ?:[\\/]*)
6890   ac_cv_path_PERL="$PERL" # Let the user override the test with a path.
6891   ;;
6892   *)
6893   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
6894 for as_dir in $PATH
6895 do
6896   IFS=$as_save_IFS
6897   test -z "$as_dir" && as_dir=.
6898   for ac_exec_ext in '' $ac_executable_extensions; do
6899   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
6900     ac_cv_path_PERL="$as_dir/$ac_word$ac_exec_ext"
6901     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
6902     break 2
6903   fi
6904 done
6905 done
6906 IFS=$as_save_IFS
6907
6908   ;;
6909 esac
6910 fi
6911 PERL=$ac_cv_path_PERL
6912 if test -n "$PERL"; then
6913   { $as_echo "$as_me:$LINENO: result: $PERL" >&5
6914 $as_echo "$PERL" >&6; }
6915 else
6916   { $as_echo "$as_me:$LINENO: result: no" >&5
6917 $as_echo "no" >&6; }
6918 fi
6919
6920
6921 fi
6922
6923 if test "$PERL"; then
6924   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'`
6925   { $as_echo "$as_me:$LINENO: using perl $pgac_perl_version" >&5
6926 $as_echo "$as_me: using perl $pgac_perl_version" >&6;}
6927   if echo "$pgac_perl_version" | sed 's/[.a-z_]/ /g' | \
6928     $AWK '{ if ($1 = 5 && $2 >= 8) exit 1; else exit 0;}'
6929   then
6930     { $as_echo "$as_me:$LINENO: WARNING:
6931 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
6932 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&5
6933 $as_echo "$as_me: WARNING:
6934 *** The installed version of Perl, $PERL, is too old to use with PostgreSQL.
6935 *** Perl version 5.8 or later is required, but this is $pgac_perl_version." >&2;}
6936     PERL=""
6937   fi
6938 fi
6939
6940 if test -z "$PERL"; then
6941   { $as_echo "$as_me:$LINENO: WARNING:
6942 *** Without Perl you will not be able to build PostgreSQL from Git.
6943 *** You can obtain Perl from any CPAN mirror site.
6944 *** (If you are using the official distribution of PostgreSQL then you do not
6945 *** need to worry about this, because the Perl output is pre-generated.)" >&5
6946 $as_echo "$as_me: WARNING:
6947 *** Without Perl you will not be able to build PostgreSQL from Git.
6948 *** You can obtain Perl from any CPAN mirror site.
6949 *** (If you are using the official distribution of PostgreSQL then you do not
6950 *** need to worry about this, because the Perl output is pre-generated.)" >&2;}
6951 fi
6952
6953 if test "$with_perl" = yes; then
6954   if test -z "$PERL"; then
6955     { { $as_echo "$as_me:$LINENO: error: Perl not found" >&5
6956 $as_echo "$as_me: error: Perl not found" >&2;}
6957    { (exit 1); exit 1; }; }
6958   fi
6959
6960 { $as_echo "$as_me:$LINENO: checking for Perl archlibexp" >&5
6961 $as_echo_n "checking for Perl archlibexp... " >&6; }
6962 perl_archlibexp=`$PERL -MConfig -e 'print $Config{archlibexp}'`
6963 { $as_echo "$as_me:$LINENO: result: $perl_archlibexp" >&5
6964 $as_echo "$perl_archlibexp" >&6; }
6965 { $as_echo "$as_me:$LINENO: checking for Perl privlibexp" >&5
6966 $as_echo_n "checking for Perl privlibexp... " >&6; }
6967 perl_privlibexp=`$PERL -MConfig -e 'print $Config{privlibexp}'`
6968 { $as_echo "$as_me:$LINENO: result: $perl_privlibexp" >&5
6969 $as_echo "$perl_privlibexp" >&6; }
6970 { $as_echo "$as_me:$LINENO: checking for Perl useshrplib" >&5
6971 $as_echo_n "checking for Perl useshrplib... " >&6; }
6972 perl_useshrplib=`$PERL -MConfig -e 'print $Config{useshrplib}'`
6973 { $as_echo "$as_me:$LINENO: result: $perl_useshrplib" >&5
6974 $as_echo "$perl_useshrplib" >&6; }
6975
6976 { $as_echo "$as_me:$LINENO: checking for flags to link embedded Perl" >&5
6977 $as_echo_n "checking for flags to link embedded Perl... " >&6; }
6978 pgac_tmp1=`$PERL -MExtUtils::Embed -e ldopts`
6979 pgac_tmp2=`$PERL -MConfig -e 'print $Config{ccdlflags}'`
6980 perl_embed_ldflags=`echo X"$pgac_tmp1" | sed -e "s/^X//" -e "s%$pgac_tmp2%%" -e "s/ -arch [-a-zA-Z0-9_]*//g"`
6981 if test -z "$perl_embed_ldflags" ; then
6982         { $as_echo "$as_me:$LINENO: result: no" >&5
6983 $as_echo "no" >&6; }
6984         { { $as_echo "$as_me:$LINENO: error: could not determine flags for linking embedded Perl.
6985 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
6986 installed." >&5
6987 $as_echo "$as_me: error: could not determine flags for linking embedded Perl.
6988 This probably means that ExtUtils::Embed or ExtUtils::MakeMaker is not
6989 installed." >&2;}
6990    { (exit 1); exit 1; }; }
6991 else
6992         { $as_echo "$as_me:$LINENO: result: $perl_embed_ldflags" >&5
6993 $as_echo "$perl_embed_ldflags" >&6; }
6994 fi
6995
6996 fi
6997
6998 if test "$with_python" = yes; then
6999   # Extract the first word of "python", so it can be a program name with args.
7000 set dummy python; ac_word=$2
7001 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7002 $as_echo_n "checking for $ac_word... " >&6; }
7003 if test "${ac_cv_path_PYTHON+set}" = set; then
7004   $as_echo_n "(cached) " >&6
7005 else
7006   case $PYTHON in
7007   [\\/]* | ?:[\\/]*)
7008   ac_cv_path_PYTHON="$PYTHON" # Let the user override the test with a path.
7009   ;;
7010   *)
7011   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7012 for as_dir in $PATH
7013 do
7014   IFS=$as_save_IFS
7015   test -z "$as_dir" && as_dir=.
7016   for ac_exec_ext in '' $ac_executable_extensions; do
7017   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7018     ac_cv_path_PYTHON="$as_dir/$ac_word$ac_exec_ext"
7019     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7020     break 2
7021   fi
7022 done
7023 done
7024 IFS=$as_save_IFS
7025
7026   ;;
7027 esac
7028 fi
7029 PYTHON=$ac_cv_path_PYTHON
7030 if test -n "$PYTHON"; then
7031   { $as_echo "$as_me:$LINENO: result: $PYTHON" >&5
7032 $as_echo "$PYTHON" >&6; }
7033 else
7034   { $as_echo "$as_me:$LINENO: result: no" >&5
7035 $as_echo "no" >&6; }
7036 fi
7037
7038
7039 if test x"$PYTHON" = x""; then
7040   { { $as_echo "$as_me:$LINENO: error: Python not found" >&5
7041 $as_echo "$as_me: error: Python not found" >&2;}
7042    { (exit 1); exit 1; }; }
7043 fi
7044
7045
7046 { $as_echo "$as_me:$LINENO: checking for Python distutils module" >&5
7047 $as_echo_n "checking for Python distutils module... " >&6; }
7048 if "${PYTHON}" -c 'import distutils' 2>&5
7049 then
7050     { $as_echo "$as_me:$LINENO: result: yes" >&5
7051 $as_echo "yes" >&6; }
7052 else
7053     { $as_echo "$as_me:$LINENO: result: no" >&5
7054 $as_echo "no" >&6; }
7055     { { $as_echo "$as_me:$LINENO: error: distutils module not found" >&5
7056 $as_echo "$as_me: error: distutils module not found" >&2;}
7057    { (exit 1); exit 1; }; }
7058 fi
7059 { $as_echo "$as_me:$LINENO: checking Python configuration directory" >&5
7060 $as_echo_n "checking Python configuration directory... " >&6; }
7061 python_majorversion=`${PYTHON} -c "import sys; print(sys.version[0])"`
7062 python_version=`${PYTHON} -c "import sys; print(sys.version[:3])"`
7063 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'))"`
7064 python_includespec=`${PYTHON} -c "import distutils.sysconfig; print('-I'+distutils.sysconfig.get_python_inc())"`
7065
7066 # This should be enough of a message.
7067 { $as_echo "$as_me:$LINENO: result: $python_configdir" >&5
7068 $as_echo "$python_configdir" >&6; }
7069
7070
7071 { $as_echo "$as_me:$LINENO: checking how to link an embedded Python application" >&5
7072 $as_echo_n "checking how to link an embedded Python application... " >&6; }
7073
7074 python_libdir=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBDIR'))))"`
7075 python_ldlibrary=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LDLIBRARY'))))"`
7076 python_so=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('SO'))))"`
7077 ldlibrary=`echo "${python_ldlibrary}" | sed "s/${python_so}$//"`
7078
7079 if test x"${python_libdir}" != x"" -a x"${python_ldlibrary}" != x"" -a x"${python_ldlibrary}" != x"${ldlibrary}"
7080 then
7081         # New way: use the official shared library
7082         ldlibrary=`echo "${ldlibrary}" | sed "s/^lib//"`
7083         python_libspec="-L${python_libdir} -l${ldlibrary}"
7084 else
7085         # Old way: use libpython from python_configdir
7086         python_libdir="${python_configdir}"
7087         python_libspec="-L${python_libdir} -lpython${python_version}"
7088 fi
7089
7090 python_additional_libs=`${PYTHON} -c "import distutils.sysconfig,string; print(' '.join(filter(None,distutils.sysconfig.get_config_vars('LIBS','LIBC','LIBM','BASEMODLIBS'))))"`
7091
7092 { $as_echo "$as_me:$LINENO: result: ${python_libspec} ${python_additional_libs}" >&5
7093 $as_echo "${python_libspec} ${python_additional_libs}" >&6; }
7094
7095
7096 # threaded python is not supported on bsd's
7097 { $as_echo "$as_me:$LINENO: checking whether Python is compiled with thread support" >&5
7098 $as_echo_n "checking whether Python is compiled with thread support... " >&6; }
7099 pythreads=`${PYTHON} -c "import sys; print(int('thread' in sys.builtin_module_names))"`
7100 if test "$pythreads" = "1"; then
7101   { $as_echo "$as_me:$LINENO: result: yes" >&5
7102 $as_echo "yes" >&6; }
7103   case $host_os in
7104   openbsd*|freebsd*)
7105     { { $as_echo "$as_me:$LINENO: error: threaded Python not supported on this platform" >&5
7106 $as_echo "$as_me: error: threaded Python not supported on this platform" >&2;}
7107    { (exit 1); exit 1; }; }
7108     ;;
7109   esac
7110 else
7111   { $as_echo "$as_me:$LINENO: result: no" >&5
7112 $as_echo "no" >&6; }
7113 fi
7114
7115
7116 fi
7117
7118 if test "$cross_compiling" = yes && test -z "$with_system_tzdata"; then
7119   # Extract the first word of "zic", so it can be a program name with args.
7120 set dummy zic; ac_word=$2
7121 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
7122 $as_echo_n "checking for $ac_word... " >&6; }
7123 if test "${ac_cv_path_ZIC+set}" = set; then
7124   $as_echo_n "(cached) " >&6
7125 else
7126   case $ZIC in
7127   [\\/]* | ?:[\\/]*)
7128   ac_cv_path_ZIC="$ZIC" # Let the user override the test with a path.
7129   ;;
7130   *)
7131   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
7132 for as_dir in $PATH
7133 do
7134   IFS=$as_save_IFS
7135   test -z "$as_dir" && as_dir=.
7136   for ac_exec_ext in '' $ac_executable_extensions; do
7137   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
7138     ac_cv_path_ZIC="$as_dir/$ac_word$ac_exec_ext"
7139     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
7140     break 2
7141   fi
7142 done
7143 done
7144 IFS=$as_save_IFS
7145
7146   ;;
7147 esac
7148 fi
7149 ZIC=$ac_cv_path_ZIC
7150 if test -n "$ZIC"; then
7151   { $as_echo "$as_me:$LINENO: result: $ZIC" >&5
7152 $as_echo "$ZIC" >&6; }
7153 else
7154   { $as_echo "$as_me:$LINENO: result: no" >&5
7155 $as_echo "no" >&6; }
7156 fi
7157
7158
7159   if test -z "$ZIC"; then
7160     { { $as_echo "$as_me:$LINENO: error:
7161 When cross-compiling, either use the option --with-system-tzdata to use
7162 existing time-zone data, or set the environment variable ZIC to a zic
7163 program to use during the build." >&5
7164 $as_echo "$as_me: error:
7165 When cross-compiling, either use the option --with-system-tzdata to use
7166 existing time-zone data, or set the environment variable ZIC to a zic
7167 program to use during the build." >&2;}
7168    { (exit 1); exit 1; }; }
7169   fi
7170 fi
7171
7172
7173 ##
7174 ## Libraries
7175 ##
7176 ## Most libraries are included only if they demonstrably provide a function
7177 ## we need, but libm is an exception: always include it, because there are
7178 ## too many compilers that play cute optimization games that will break
7179 ## probes for standard functions such as pow().
7180 ##
7181
7182
7183 { $as_echo "$as_me:$LINENO: checking for main in -lm" >&5
7184 $as_echo_n "checking for main in -lm... " >&6; }
7185 if test "${ac_cv_lib_m_main+set}" = set; then
7186   $as_echo_n "(cached) " >&6
7187 else
7188   ac_check_lib_save_LIBS=$LIBS
7189 LIBS="-lm  $LIBS"
7190 cat >conftest.$ac_ext <<_ACEOF
7191 /* confdefs.h.  */
7192 _ACEOF
7193 cat confdefs.h >>conftest.$ac_ext
7194 cat >>conftest.$ac_ext <<_ACEOF
7195 /* end confdefs.h.  */
7196
7197
7198 int
7199 main ()
7200 {
7201 return main ();
7202   ;
7203   return 0;
7204 }
7205 _ACEOF
7206 rm -f conftest.$ac_objext conftest$ac_exeext
7207 if { (ac_try="$ac_link"
7208 case "(($ac_try" in
7209   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7210   *) ac_try_echo=$ac_try;;
7211 esac
7212 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7213 $as_echo "$ac_try_echo") >&5
7214   (eval "$ac_link") 2>conftest.er1
7215   ac_status=$?
7216   grep -v '^ *+' conftest.er1 >conftest.err
7217   rm -f conftest.er1
7218   cat conftest.err >&5
7219   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7220   (exit $ac_status); } && {
7221          test -z "$ac_c_werror_flag" ||
7222          test ! -s conftest.err
7223        } && test -s conftest$ac_exeext && {
7224          test "$cross_compiling" = yes ||
7225          $as_test_x conftest$ac_exeext
7226        }; then
7227   ac_cv_lib_m_main=yes
7228 else
7229   $as_echo "$as_me: failed program was:" >&5
7230 sed 's/^/| /' conftest.$ac_ext >&5
7231
7232         ac_cv_lib_m_main=no
7233 fi
7234
7235 rm -rf conftest.dSYM
7236 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7237       conftest$ac_exeext conftest.$ac_ext
7238 LIBS=$ac_check_lib_save_LIBS
7239 fi
7240 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_m_main" >&5
7241 $as_echo "$ac_cv_lib_m_main" >&6; }
7242 if test "x$ac_cv_lib_m_main" = x""yes; then
7243   cat >>confdefs.h <<_ACEOF
7244 #define HAVE_LIBM 1
7245 _ACEOF
7246
7247   LIBS="-lm $LIBS"
7248
7249 fi
7250
7251 { $as_echo "$as_me:$LINENO: checking for library containing setproctitle" >&5
7252 $as_echo_n "checking for library containing setproctitle... " >&6; }
7253 if test "${ac_cv_search_setproctitle+set}" = set; then
7254   $as_echo_n "(cached) " >&6
7255 else
7256   ac_func_search_save_LIBS=$LIBS
7257 cat >conftest.$ac_ext <<_ACEOF
7258 /* confdefs.h.  */
7259 _ACEOF
7260 cat confdefs.h >>conftest.$ac_ext
7261 cat >>conftest.$ac_ext <<_ACEOF
7262 /* end confdefs.h.  */
7263
7264 /* Override any GCC internal prototype to avoid an error.
7265    Use char because int might match the return type of a GCC
7266    builtin and then its argument prototype would still apply.  */
7267 #ifdef __cplusplus
7268 extern "C"
7269 #endif
7270 char setproctitle ();
7271 int
7272 main ()
7273 {
7274 return setproctitle ();
7275   ;
7276   return 0;
7277 }
7278 _ACEOF
7279 for ac_lib in '' util; do
7280   if test -z "$ac_lib"; then
7281     ac_res="none required"
7282   else
7283     ac_res=-l$ac_lib
7284     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7285   fi
7286   rm -f conftest.$ac_objext conftest$ac_exeext
7287 if { (ac_try="$ac_link"
7288 case "(($ac_try" in
7289   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7290   *) ac_try_echo=$ac_try;;
7291 esac
7292 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7293 $as_echo "$ac_try_echo") >&5
7294   (eval "$ac_link") 2>conftest.er1
7295   ac_status=$?
7296   grep -v '^ *+' conftest.er1 >conftest.err
7297   rm -f conftest.er1
7298   cat conftest.err >&5
7299   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7300   (exit $ac_status); } && {
7301          test -z "$ac_c_werror_flag" ||
7302          test ! -s conftest.err
7303        } && test -s conftest$ac_exeext && {
7304          test "$cross_compiling" = yes ||
7305          $as_test_x conftest$ac_exeext
7306        }; then
7307   ac_cv_search_setproctitle=$ac_res
7308 else
7309   $as_echo "$as_me: failed program was:" >&5
7310 sed 's/^/| /' conftest.$ac_ext >&5
7311
7312
7313 fi
7314
7315 rm -rf conftest.dSYM
7316 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7317       conftest$ac_exeext
7318   if test "${ac_cv_search_setproctitle+set}" = set; then
7319   break
7320 fi
7321 done
7322 if test "${ac_cv_search_setproctitle+set}" = set; then
7323   :
7324 else
7325   ac_cv_search_setproctitle=no
7326 fi
7327 rm conftest.$ac_ext
7328 LIBS=$ac_func_search_save_LIBS
7329 fi
7330 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_setproctitle" >&5
7331 $as_echo "$ac_cv_search_setproctitle" >&6; }
7332 ac_res=$ac_cv_search_setproctitle
7333 if test "$ac_res" != no; then
7334   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7335
7336 fi
7337
7338 { $as_echo "$as_me:$LINENO: checking for library containing dlopen" >&5
7339 $as_echo_n "checking for library containing dlopen... " >&6; }
7340 if test "${ac_cv_search_dlopen+set}" = set; then
7341   $as_echo_n "(cached) " >&6
7342 else
7343   ac_func_search_save_LIBS=$LIBS
7344 cat >conftest.$ac_ext <<_ACEOF
7345 /* confdefs.h.  */
7346 _ACEOF
7347 cat confdefs.h >>conftest.$ac_ext
7348 cat >>conftest.$ac_ext <<_ACEOF
7349 /* end confdefs.h.  */
7350
7351 /* Override any GCC internal prototype to avoid an error.
7352    Use char because int might match the return type of a GCC
7353    builtin and then its argument prototype would still apply.  */
7354 #ifdef __cplusplus
7355 extern "C"
7356 #endif
7357 char dlopen ();
7358 int
7359 main ()
7360 {
7361 return dlopen ();
7362   ;
7363   return 0;
7364 }
7365 _ACEOF
7366 for ac_lib in '' dl; do
7367   if test -z "$ac_lib"; then
7368     ac_res="none required"
7369   else
7370     ac_res=-l$ac_lib
7371     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7372   fi
7373   rm -f conftest.$ac_objext conftest$ac_exeext
7374 if { (ac_try="$ac_link"
7375 case "(($ac_try" in
7376   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7377   *) ac_try_echo=$ac_try;;
7378 esac
7379 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7380 $as_echo "$ac_try_echo") >&5
7381   (eval "$ac_link") 2>conftest.er1
7382   ac_status=$?
7383   grep -v '^ *+' conftest.er1 >conftest.err
7384   rm -f conftest.er1
7385   cat conftest.err >&5
7386   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7387   (exit $ac_status); } && {
7388          test -z "$ac_c_werror_flag" ||
7389          test ! -s conftest.err
7390        } && test -s conftest$ac_exeext && {
7391          test "$cross_compiling" = yes ||
7392          $as_test_x conftest$ac_exeext
7393        }; then
7394   ac_cv_search_dlopen=$ac_res
7395 else
7396   $as_echo "$as_me: failed program was:" >&5
7397 sed 's/^/| /' conftest.$ac_ext >&5
7398
7399
7400 fi
7401
7402 rm -rf conftest.dSYM
7403 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7404       conftest$ac_exeext
7405   if test "${ac_cv_search_dlopen+set}" = set; then
7406   break
7407 fi
7408 done
7409 if test "${ac_cv_search_dlopen+set}" = set; then
7410   :
7411 else
7412   ac_cv_search_dlopen=no
7413 fi
7414 rm conftest.$ac_ext
7415 LIBS=$ac_func_search_save_LIBS
7416 fi
7417 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_dlopen" >&5
7418 $as_echo "$ac_cv_search_dlopen" >&6; }
7419 ac_res=$ac_cv_search_dlopen
7420 if test "$ac_res" != no; then
7421   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7422
7423 fi
7424
7425 { $as_echo "$as_me:$LINENO: checking for library containing socket" >&5
7426 $as_echo_n "checking for library containing socket... " >&6; }
7427 if test "${ac_cv_search_socket+set}" = set; then
7428   $as_echo_n "(cached) " >&6
7429 else
7430   ac_func_search_save_LIBS=$LIBS
7431 cat >conftest.$ac_ext <<_ACEOF
7432 /* confdefs.h.  */
7433 _ACEOF
7434 cat confdefs.h >>conftest.$ac_ext
7435 cat >>conftest.$ac_ext <<_ACEOF
7436 /* end confdefs.h.  */
7437
7438 /* Override any GCC internal prototype to avoid an error.
7439    Use char because int might match the return type of a GCC
7440    builtin and then its argument prototype would still apply.  */
7441 #ifdef __cplusplus
7442 extern "C"
7443 #endif
7444 char socket ();
7445 int
7446 main ()
7447 {
7448 return socket ();
7449   ;
7450   return 0;
7451 }
7452 _ACEOF
7453 for ac_lib in '' socket wsock32; do
7454   if test -z "$ac_lib"; then
7455     ac_res="none required"
7456   else
7457     ac_res=-l$ac_lib
7458     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7459   fi
7460   rm -f conftest.$ac_objext conftest$ac_exeext
7461 if { (ac_try="$ac_link"
7462 case "(($ac_try" in
7463   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7464   *) ac_try_echo=$ac_try;;
7465 esac
7466 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7467 $as_echo "$ac_try_echo") >&5
7468   (eval "$ac_link") 2>conftest.er1
7469   ac_status=$?
7470   grep -v '^ *+' conftest.er1 >conftest.err
7471   rm -f conftest.er1
7472   cat conftest.err >&5
7473   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7474   (exit $ac_status); } && {
7475          test -z "$ac_c_werror_flag" ||
7476          test ! -s conftest.err
7477        } && test -s conftest$ac_exeext && {
7478          test "$cross_compiling" = yes ||
7479          $as_test_x conftest$ac_exeext
7480        }; then
7481   ac_cv_search_socket=$ac_res
7482 else
7483   $as_echo "$as_me: failed program was:" >&5
7484 sed 's/^/| /' conftest.$ac_ext >&5
7485
7486
7487 fi
7488
7489 rm -rf conftest.dSYM
7490 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7491       conftest$ac_exeext
7492   if test "${ac_cv_search_socket+set}" = set; then
7493   break
7494 fi
7495 done
7496 if test "${ac_cv_search_socket+set}" = set; then
7497   :
7498 else
7499   ac_cv_search_socket=no
7500 fi
7501 rm conftest.$ac_ext
7502 LIBS=$ac_func_search_save_LIBS
7503 fi
7504 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_socket" >&5
7505 $as_echo "$ac_cv_search_socket" >&6; }
7506 ac_res=$ac_cv_search_socket
7507 if test "$ac_res" != no; then
7508   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7509
7510 fi
7511
7512 { $as_echo "$as_me:$LINENO: checking for library containing shl_load" >&5
7513 $as_echo_n "checking for library containing shl_load... " >&6; }
7514 if test "${ac_cv_search_shl_load+set}" = set; then
7515   $as_echo_n "(cached) " >&6
7516 else
7517   ac_func_search_save_LIBS=$LIBS
7518 cat >conftest.$ac_ext <<_ACEOF
7519 /* confdefs.h.  */
7520 _ACEOF
7521 cat confdefs.h >>conftest.$ac_ext
7522 cat >>conftest.$ac_ext <<_ACEOF
7523 /* end confdefs.h.  */
7524
7525 /* Override any GCC internal prototype to avoid an error.
7526    Use char because int might match the return type of a GCC
7527    builtin and then its argument prototype would still apply.  */
7528 #ifdef __cplusplus
7529 extern "C"
7530 #endif
7531 char shl_load ();
7532 int
7533 main ()
7534 {
7535 return shl_load ();
7536   ;
7537   return 0;
7538 }
7539 _ACEOF
7540 for ac_lib in '' dld; do
7541   if test -z "$ac_lib"; then
7542     ac_res="none required"
7543   else
7544     ac_res=-l$ac_lib
7545     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7546   fi
7547   rm -f conftest.$ac_objext conftest$ac_exeext
7548 if { (ac_try="$ac_link"
7549 case "(($ac_try" in
7550   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7551   *) ac_try_echo=$ac_try;;
7552 esac
7553 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7554 $as_echo "$ac_try_echo") >&5
7555   (eval "$ac_link") 2>conftest.er1
7556   ac_status=$?
7557   grep -v '^ *+' conftest.er1 >conftest.err
7558   rm -f conftest.er1
7559   cat conftest.err >&5
7560   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7561   (exit $ac_status); } && {
7562          test -z "$ac_c_werror_flag" ||
7563          test ! -s conftest.err
7564        } && test -s conftest$ac_exeext && {
7565          test "$cross_compiling" = yes ||
7566          $as_test_x conftest$ac_exeext
7567        }; then
7568   ac_cv_search_shl_load=$ac_res
7569 else
7570   $as_echo "$as_me: failed program was:" >&5
7571 sed 's/^/| /' conftest.$ac_ext >&5
7572
7573
7574 fi
7575
7576 rm -rf conftest.dSYM
7577 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7578       conftest$ac_exeext
7579   if test "${ac_cv_search_shl_load+set}" = set; then
7580   break
7581 fi
7582 done
7583 if test "${ac_cv_search_shl_load+set}" = set; then
7584   :
7585 else
7586   ac_cv_search_shl_load=no
7587 fi
7588 rm conftest.$ac_ext
7589 LIBS=$ac_func_search_save_LIBS
7590 fi
7591 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shl_load" >&5
7592 $as_echo "$ac_cv_search_shl_load" >&6; }
7593 ac_res=$ac_cv_search_shl_load
7594 if test "$ac_res" != no; then
7595   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7596
7597 fi
7598
7599 # We only use libld in port/dynloader/aix.c
7600 case $host_os in
7601      aix*)
7602         { $as_echo "$as_me:$LINENO: checking for library containing ldopen" >&5
7603 $as_echo_n "checking for library containing ldopen... " >&6; }
7604 if test "${ac_cv_search_ldopen+set}" = set; then
7605   $as_echo_n "(cached) " >&6
7606 else
7607   ac_func_search_save_LIBS=$LIBS
7608 cat >conftest.$ac_ext <<_ACEOF
7609 /* confdefs.h.  */
7610 _ACEOF
7611 cat confdefs.h >>conftest.$ac_ext
7612 cat >>conftest.$ac_ext <<_ACEOF
7613 /* end confdefs.h.  */
7614
7615 /* Override any GCC internal prototype to avoid an error.
7616    Use char because int might match the return type of a GCC
7617    builtin and then its argument prototype would still apply.  */
7618 #ifdef __cplusplus
7619 extern "C"
7620 #endif
7621 char ldopen ();
7622 int
7623 main ()
7624 {
7625 return ldopen ();
7626   ;
7627   return 0;
7628 }
7629 _ACEOF
7630 for ac_lib in '' ld; do
7631   if test -z "$ac_lib"; then
7632     ac_res="none required"
7633   else
7634     ac_res=-l$ac_lib
7635     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7636   fi
7637   rm -f conftest.$ac_objext conftest$ac_exeext
7638 if { (ac_try="$ac_link"
7639 case "(($ac_try" in
7640   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7641   *) ac_try_echo=$ac_try;;
7642 esac
7643 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7644 $as_echo "$ac_try_echo") >&5
7645   (eval "$ac_link") 2>conftest.er1
7646   ac_status=$?
7647   grep -v '^ *+' conftest.er1 >conftest.err
7648   rm -f conftest.er1
7649   cat conftest.err >&5
7650   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7651   (exit $ac_status); } && {
7652          test -z "$ac_c_werror_flag" ||
7653          test ! -s conftest.err
7654        } && test -s conftest$ac_exeext && {
7655          test "$cross_compiling" = yes ||
7656          $as_test_x conftest$ac_exeext
7657        }; then
7658   ac_cv_search_ldopen=$ac_res
7659 else
7660   $as_echo "$as_me: failed program was:" >&5
7661 sed 's/^/| /' conftest.$ac_ext >&5
7662
7663
7664 fi
7665
7666 rm -rf conftest.dSYM
7667 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7668       conftest$ac_exeext
7669   if test "${ac_cv_search_ldopen+set}" = set; then
7670   break
7671 fi
7672 done
7673 if test "${ac_cv_search_ldopen+set}" = set; then
7674   :
7675 else
7676   ac_cv_search_ldopen=no
7677 fi
7678 rm conftest.$ac_ext
7679 LIBS=$ac_func_search_save_LIBS
7680 fi
7681 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_ldopen" >&5
7682 $as_echo "$ac_cv_search_ldopen" >&6; }
7683 ac_res=$ac_cv_search_ldopen
7684 if test "$ac_res" != no; then
7685   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7686
7687 fi
7688
7689         ;;
7690 esac
7691 { $as_echo "$as_me:$LINENO: checking for library containing getopt_long" >&5
7692 $as_echo_n "checking for library containing getopt_long... " >&6; }
7693 if test "${ac_cv_search_getopt_long+set}" = set; then
7694   $as_echo_n "(cached) " >&6
7695 else
7696   ac_func_search_save_LIBS=$LIBS
7697 cat >conftest.$ac_ext <<_ACEOF
7698 /* confdefs.h.  */
7699 _ACEOF
7700 cat confdefs.h >>conftest.$ac_ext
7701 cat >>conftest.$ac_ext <<_ACEOF
7702 /* end confdefs.h.  */
7703
7704 /* Override any GCC internal prototype to avoid an error.
7705    Use char because int might match the return type of a GCC
7706    builtin and then its argument prototype would still apply.  */
7707 #ifdef __cplusplus
7708 extern "C"
7709 #endif
7710 char getopt_long ();
7711 int
7712 main ()
7713 {
7714 return getopt_long ();
7715   ;
7716   return 0;
7717 }
7718 _ACEOF
7719 for ac_lib in '' getopt gnugetopt; do
7720   if test -z "$ac_lib"; then
7721     ac_res="none required"
7722   else
7723     ac_res=-l$ac_lib
7724     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7725   fi
7726   rm -f conftest.$ac_objext conftest$ac_exeext
7727 if { (ac_try="$ac_link"
7728 case "(($ac_try" in
7729   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7730   *) ac_try_echo=$ac_try;;
7731 esac
7732 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7733 $as_echo "$ac_try_echo") >&5
7734   (eval "$ac_link") 2>conftest.er1
7735   ac_status=$?
7736   grep -v '^ *+' conftest.er1 >conftest.err
7737   rm -f conftest.er1
7738   cat conftest.err >&5
7739   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7740   (exit $ac_status); } && {
7741          test -z "$ac_c_werror_flag" ||
7742          test ! -s conftest.err
7743        } && test -s conftest$ac_exeext && {
7744          test "$cross_compiling" = yes ||
7745          $as_test_x conftest$ac_exeext
7746        }; then
7747   ac_cv_search_getopt_long=$ac_res
7748 else
7749   $as_echo "$as_me: failed program was:" >&5
7750 sed 's/^/| /' conftest.$ac_ext >&5
7751
7752
7753 fi
7754
7755 rm -rf conftest.dSYM
7756 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7757       conftest$ac_exeext
7758   if test "${ac_cv_search_getopt_long+set}" = set; then
7759   break
7760 fi
7761 done
7762 if test "${ac_cv_search_getopt_long+set}" = set; then
7763   :
7764 else
7765   ac_cv_search_getopt_long=no
7766 fi
7767 rm conftest.$ac_ext
7768 LIBS=$ac_func_search_save_LIBS
7769 fi
7770 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_getopt_long" >&5
7771 $as_echo "$ac_cv_search_getopt_long" >&6; }
7772 ac_res=$ac_cv_search_getopt_long
7773 if test "$ac_res" != no; then
7774   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7775
7776 fi
7777
7778 { $as_echo "$as_me:$LINENO: checking for library containing crypt" >&5
7779 $as_echo_n "checking for library containing crypt... " >&6; }
7780 if test "${ac_cv_search_crypt+set}" = set; then
7781   $as_echo_n "(cached) " >&6
7782 else
7783   ac_func_search_save_LIBS=$LIBS
7784 cat >conftest.$ac_ext <<_ACEOF
7785 /* confdefs.h.  */
7786 _ACEOF
7787 cat confdefs.h >>conftest.$ac_ext
7788 cat >>conftest.$ac_ext <<_ACEOF
7789 /* end confdefs.h.  */
7790
7791 /* Override any GCC internal prototype to avoid an error.
7792    Use char because int might match the return type of a GCC
7793    builtin and then its argument prototype would still apply.  */
7794 #ifdef __cplusplus
7795 extern "C"
7796 #endif
7797 char crypt ();
7798 int
7799 main ()
7800 {
7801 return crypt ();
7802   ;
7803   return 0;
7804 }
7805 _ACEOF
7806 for ac_lib in '' crypt; do
7807   if test -z "$ac_lib"; then
7808     ac_res="none required"
7809   else
7810     ac_res=-l$ac_lib
7811     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7812   fi
7813   rm -f conftest.$ac_objext conftest$ac_exeext
7814 if { (ac_try="$ac_link"
7815 case "(($ac_try" in
7816   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7817   *) ac_try_echo=$ac_try;;
7818 esac
7819 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7820 $as_echo "$ac_try_echo") >&5
7821   (eval "$ac_link") 2>conftest.er1
7822   ac_status=$?
7823   grep -v '^ *+' conftest.er1 >conftest.err
7824   rm -f conftest.er1
7825   cat conftest.err >&5
7826   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7827   (exit $ac_status); } && {
7828          test -z "$ac_c_werror_flag" ||
7829          test ! -s conftest.err
7830        } && test -s conftest$ac_exeext && {
7831          test "$cross_compiling" = yes ||
7832          $as_test_x conftest$ac_exeext
7833        }; then
7834   ac_cv_search_crypt=$ac_res
7835 else
7836   $as_echo "$as_me: failed program was:" >&5
7837 sed 's/^/| /' conftest.$ac_ext >&5
7838
7839
7840 fi
7841
7842 rm -rf conftest.dSYM
7843 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7844       conftest$ac_exeext
7845   if test "${ac_cv_search_crypt+set}" = set; then
7846   break
7847 fi
7848 done
7849 if test "${ac_cv_search_crypt+set}" = set; then
7850   :
7851 else
7852   ac_cv_search_crypt=no
7853 fi
7854 rm conftest.$ac_ext
7855 LIBS=$ac_func_search_save_LIBS
7856 fi
7857 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_crypt" >&5
7858 $as_echo "$ac_cv_search_crypt" >&6; }
7859 ac_res=$ac_cv_search_crypt
7860 if test "$ac_res" != no; then
7861   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7862
7863 fi
7864
7865 # Solaris:
7866 { $as_echo "$as_me:$LINENO: checking for library containing fdatasync" >&5
7867 $as_echo_n "checking for library containing fdatasync... " >&6; }
7868 if test "${ac_cv_search_fdatasync+set}" = set; then
7869   $as_echo_n "(cached) " >&6
7870 else
7871   ac_func_search_save_LIBS=$LIBS
7872 cat >conftest.$ac_ext <<_ACEOF
7873 /* confdefs.h.  */
7874 _ACEOF
7875 cat confdefs.h >>conftest.$ac_ext
7876 cat >>conftest.$ac_ext <<_ACEOF
7877 /* end confdefs.h.  */
7878
7879 /* Override any GCC internal prototype to avoid an error.
7880    Use char because int might match the return type of a GCC
7881    builtin and then its argument prototype would still apply.  */
7882 #ifdef __cplusplus
7883 extern "C"
7884 #endif
7885 char fdatasync ();
7886 int
7887 main ()
7888 {
7889 return fdatasync ();
7890   ;
7891   return 0;
7892 }
7893 _ACEOF
7894 for ac_lib in '' rt posix4; do
7895   if test -z "$ac_lib"; then
7896     ac_res="none required"
7897   else
7898     ac_res=-l$ac_lib
7899     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7900   fi
7901   rm -f conftest.$ac_objext conftest$ac_exeext
7902 if { (ac_try="$ac_link"
7903 case "(($ac_try" in
7904   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7905   *) ac_try_echo=$ac_try;;
7906 esac
7907 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7908 $as_echo "$ac_try_echo") >&5
7909   (eval "$ac_link") 2>conftest.er1
7910   ac_status=$?
7911   grep -v '^ *+' conftest.er1 >conftest.err
7912   rm -f conftest.er1
7913   cat conftest.err >&5
7914   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
7915   (exit $ac_status); } && {
7916          test -z "$ac_c_werror_flag" ||
7917          test ! -s conftest.err
7918        } && test -s conftest$ac_exeext && {
7919          test "$cross_compiling" = yes ||
7920          $as_test_x conftest$ac_exeext
7921        }; then
7922   ac_cv_search_fdatasync=$ac_res
7923 else
7924   $as_echo "$as_me: failed program was:" >&5
7925 sed 's/^/| /' conftest.$ac_ext >&5
7926
7927
7928 fi
7929
7930 rm -rf conftest.dSYM
7931 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
7932       conftest$ac_exeext
7933   if test "${ac_cv_search_fdatasync+set}" = set; then
7934   break
7935 fi
7936 done
7937 if test "${ac_cv_search_fdatasync+set}" = set; then
7938   :
7939 else
7940   ac_cv_search_fdatasync=no
7941 fi
7942 rm conftest.$ac_ext
7943 LIBS=$ac_func_search_save_LIBS
7944 fi
7945 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_fdatasync" >&5
7946 $as_echo "$ac_cv_search_fdatasync" >&6; }
7947 ac_res=$ac_cv_search_fdatasync
7948 if test "$ac_res" != no; then
7949   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
7950
7951 fi
7952
7953 # Required for thread_test.c on Solaris 2.5:
7954 # Other ports use it too (HP-UX) so test unconditionally
7955 { $as_echo "$as_me:$LINENO: checking for library containing gethostbyname_r" >&5
7956 $as_echo_n "checking for library containing gethostbyname_r... " >&6; }
7957 if test "${ac_cv_search_gethostbyname_r+set}" = set; then
7958   $as_echo_n "(cached) " >&6
7959 else
7960   ac_func_search_save_LIBS=$LIBS
7961 cat >conftest.$ac_ext <<_ACEOF
7962 /* confdefs.h.  */
7963 _ACEOF
7964 cat confdefs.h >>conftest.$ac_ext
7965 cat >>conftest.$ac_ext <<_ACEOF
7966 /* end confdefs.h.  */
7967
7968 /* Override any GCC internal prototype to avoid an error.
7969    Use char because int might match the return type of a GCC
7970    builtin and then its argument prototype would still apply.  */
7971 #ifdef __cplusplus
7972 extern "C"
7973 #endif
7974 char gethostbyname_r ();
7975 int
7976 main ()
7977 {
7978 return gethostbyname_r ();
7979   ;
7980   return 0;
7981 }
7982 _ACEOF
7983 for ac_lib in '' nsl; do
7984   if test -z "$ac_lib"; then
7985     ac_res="none required"
7986   else
7987     ac_res=-l$ac_lib
7988     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
7989   fi
7990   rm -f conftest.$ac_objext conftest$ac_exeext
7991 if { (ac_try="$ac_link"
7992 case "(($ac_try" in
7993   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
7994   *) ac_try_echo=$ac_try;;
7995 esac
7996 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
7997 $as_echo "$ac_try_echo") >&5
7998   (eval "$ac_link") 2>conftest.er1
7999   ac_status=$?
8000   grep -v '^ *+' conftest.er1 >conftest.err
8001   rm -f conftest.er1
8002   cat conftest.err >&5
8003   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8004   (exit $ac_status); } && {
8005          test -z "$ac_c_werror_flag" ||
8006          test ! -s conftest.err
8007        } && test -s conftest$ac_exeext && {
8008          test "$cross_compiling" = yes ||
8009          $as_test_x conftest$ac_exeext
8010        }; then
8011   ac_cv_search_gethostbyname_r=$ac_res
8012 else
8013   $as_echo "$as_me: failed program was:" >&5
8014 sed 's/^/| /' conftest.$ac_ext >&5
8015
8016
8017 fi
8018
8019 rm -rf conftest.dSYM
8020 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8021       conftest$ac_exeext
8022   if test "${ac_cv_search_gethostbyname_r+set}" = set; then
8023   break
8024 fi
8025 done
8026 if test "${ac_cv_search_gethostbyname_r+set}" = set; then
8027   :
8028 else
8029   ac_cv_search_gethostbyname_r=no
8030 fi
8031 rm conftest.$ac_ext
8032 LIBS=$ac_func_search_save_LIBS
8033 fi
8034 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_gethostbyname_r" >&5
8035 $as_echo "$ac_cv_search_gethostbyname_r" >&6; }
8036 ac_res=$ac_cv_search_gethostbyname_r
8037 if test "$ac_res" != no; then
8038   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8039
8040 fi
8041
8042 # Cygwin:
8043 { $as_echo "$as_me:$LINENO: checking for library containing shmget" >&5
8044 $as_echo_n "checking for library containing shmget... " >&6; }
8045 if test "${ac_cv_search_shmget+set}" = set; then
8046   $as_echo_n "(cached) " >&6
8047 else
8048   ac_func_search_save_LIBS=$LIBS
8049 cat >conftest.$ac_ext <<_ACEOF
8050 /* confdefs.h.  */
8051 _ACEOF
8052 cat confdefs.h >>conftest.$ac_ext
8053 cat >>conftest.$ac_ext <<_ACEOF
8054 /* end confdefs.h.  */
8055
8056 /* Override any GCC internal prototype to avoid an error.
8057    Use char because int might match the return type of a GCC
8058    builtin and then its argument prototype would still apply.  */
8059 #ifdef __cplusplus
8060 extern "C"
8061 #endif
8062 char shmget ();
8063 int
8064 main ()
8065 {
8066 return shmget ();
8067   ;
8068   return 0;
8069 }
8070 _ACEOF
8071 for ac_lib in '' cygipc; do
8072   if test -z "$ac_lib"; then
8073     ac_res="none required"
8074   else
8075     ac_res=-l$ac_lib
8076     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8077   fi
8078   rm -f conftest.$ac_objext conftest$ac_exeext
8079 if { (ac_try="$ac_link"
8080 case "(($ac_try" in
8081   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8082   *) ac_try_echo=$ac_try;;
8083 esac
8084 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8085 $as_echo "$ac_try_echo") >&5
8086   (eval "$ac_link") 2>conftest.er1
8087   ac_status=$?
8088   grep -v '^ *+' conftest.er1 >conftest.err
8089   rm -f conftest.er1
8090   cat conftest.err >&5
8091   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8092   (exit $ac_status); } && {
8093          test -z "$ac_c_werror_flag" ||
8094          test ! -s conftest.err
8095        } && test -s conftest$ac_exeext && {
8096          test "$cross_compiling" = yes ||
8097          $as_test_x conftest$ac_exeext
8098        }; then
8099   ac_cv_search_shmget=$ac_res
8100 else
8101   $as_echo "$as_me: failed program was:" >&5
8102 sed 's/^/| /' conftest.$ac_ext >&5
8103
8104
8105 fi
8106
8107 rm -rf conftest.dSYM
8108 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8109       conftest$ac_exeext
8110   if test "${ac_cv_search_shmget+set}" = set; then
8111   break
8112 fi
8113 done
8114 if test "${ac_cv_search_shmget+set}" = set; then
8115   :
8116 else
8117   ac_cv_search_shmget=no
8118 fi
8119 rm conftest.$ac_ext
8120 LIBS=$ac_func_search_save_LIBS
8121 fi
8122 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_shmget" >&5
8123 $as_echo "$ac_cv_search_shmget" >&6; }
8124 ac_res=$ac_cv_search_shmget
8125 if test "$ac_res" != no; then
8126   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8127
8128 fi
8129
8130
8131 if test "$with_readline" = yes; then
8132
8133
8134 { $as_echo "$as_me:$LINENO: checking for library containing readline" >&5
8135 $as_echo_n "checking for library containing readline... " >&6; }
8136 if test "${pgac_cv_check_readline+set}" = set; then
8137   $as_echo_n "(cached) " >&6
8138 else
8139   pgac_cv_check_readline=no
8140 pgac_save_LIBS=$LIBS
8141 if test x"$with_libedit_preferred" != x"yes"
8142 then    READLINE_ORDER="-lreadline -ledit"
8143 else    READLINE_ORDER="-ledit -lreadline"
8144 fi
8145 for pgac_rllib in $READLINE_ORDER ; do
8146   for pgac_lib in "" " -ltermcap" " -lncurses" " -lcurses" ; do
8147     LIBS="${pgac_rllib}${pgac_lib} $pgac_save_LIBS"
8148     cat >conftest.$ac_ext <<_ACEOF
8149 /* confdefs.h.  */
8150 _ACEOF
8151 cat confdefs.h >>conftest.$ac_ext
8152 cat >>conftest.$ac_ext <<_ACEOF
8153 /* end confdefs.h.  */
8154
8155 /* Override any GCC internal prototype to avoid an error.
8156    Use char because int might match the return type of a GCC
8157    builtin and then its argument prototype would still apply.  */
8158 #ifdef __cplusplus
8159 extern "C"
8160 #endif
8161 char readline ();
8162 int
8163 main ()
8164 {
8165 return readline ();
8166   ;
8167   return 0;
8168 }
8169 _ACEOF
8170 rm -f conftest.$ac_objext conftest$ac_exeext
8171 if { (ac_try="$ac_link"
8172 case "(($ac_try" in
8173   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8174   *) ac_try_echo=$ac_try;;
8175 esac
8176 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8177 $as_echo "$ac_try_echo") >&5
8178   (eval "$ac_link") 2>conftest.er1
8179   ac_status=$?
8180   grep -v '^ *+' conftest.er1 >conftest.err
8181   rm -f conftest.er1
8182   cat conftest.err >&5
8183   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8184   (exit $ac_status); } && {
8185          test -z "$ac_c_werror_flag" ||
8186          test ! -s conftest.err
8187        } && test -s conftest$ac_exeext && {
8188          test "$cross_compiling" = yes ||
8189          $as_test_x conftest$ac_exeext
8190        }; then
8191
8192       # Older NetBSD, OpenBSD, and Irix have a broken linker that does not
8193       # recognize dependent libraries; assume curses is needed if we didn't
8194       # find any dependency.
8195       case $host_os in
8196         netbsd* | openbsd* | irix*)
8197           if test x"$pgac_lib" = x"" ; then
8198             pgac_lib=" -lcurses"
8199           fi ;;
8200       esac
8201
8202       pgac_cv_check_readline="${pgac_rllib}${pgac_lib}"
8203       break
8204
8205 else
8206   $as_echo "$as_me: failed program was:" >&5
8207 sed 's/^/| /' conftest.$ac_ext >&5
8208
8209
8210 fi
8211
8212 rm -rf conftest.dSYM
8213 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8214       conftest$ac_exeext conftest.$ac_ext
8215   done
8216   if test "$pgac_cv_check_readline" != no ; then
8217     break
8218   fi
8219 done
8220 LIBS=$pgac_save_LIBS
8221
8222 fi
8223 { $as_echo "$as_me:$LINENO: result: $pgac_cv_check_readline" >&5
8224 $as_echo "$pgac_cv_check_readline" >&6; }
8225 if test "$pgac_cv_check_readline" != no ; then
8226   LIBS="$pgac_cv_check_readline $LIBS"
8227
8228 cat >>confdefs.h <<\_ACEOF
8229 #define HAVE_LIBREADLINE 1
8230 _ACEOF
8231
8232 fi
8233
8234
8235   if test x"$pgac_cv_check_readline" = x"no"; then
8236     { { $as_echo "$as_me:$LINENO: error: readline library not found
8237 If you have readline already installed, see config.log for details on the
8238 failure.  It is possible the compiler isn't looking in the proper directory.
8239 Use --without-readline to disable readline support." >&5
8240 $as_echo "$as_me: error: readline library not found
8241 If you have readline already installed, see config.log for details on the
8242 failure.  It is possible the compiler isn't looking in the proper directory.
8243 Use --without-readline to disable readline support." >&2;}
8244    { (exit 1); exit 1; }; }
8245   fi
8246 fi
8247
8248 if test "$with_zlib" = yes; then
8249
8250 { $as_echo "$as_me:$LINENO: checking for inflate in -lz" >&5
8251 $as_echo_n "checking for inflate in -lz... " >&6; }
8252 if test "${ac_cv_lib_z_inflate+set}" = set; then
8253   $as_echo_n "(cached) " >&6
8254 else
8255   ac_check_lib_save_LIBS=$LIBS
8256 LIBS="-lz  $LIBS"
8257 cat >conftest.$ac_ext <<_ACEOF
8258 /* confdefs.h.  */
8259 _ACEOF
8260 cat confdefs.h >>conftest.$ac_ext
8261 cat >>conftest.$ac_ext <<_ACEOF
8262 /* end confdefs.h.  */
8263
8264 /* Override any GCC internal prototype to avoid an error.
8265    Use char because int might match the return type of a GCC
8266    builtin and then its argument prototype would still apply.  */
8267 #ifdef __cplusplus
8268 extern "C"
8269 #endif
8270 char inflate ();
8271 int
8272 main ()
8273 {
8274 return inflate ();
8275   ;
8276   return 0;
8277 }
8278 _ACEOF
8279 rm -f conftest.$ac_objext conftest$ac_exeext
8280 if { (ac_try="$ac_link"
8281 case "(($ac_try" in
8282   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8283   *) ac_try_echo=$ac_try;;
8284 esac
8285 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8286 $as_echo "$ac_try_echo") >&5
8287   (eval "$ac_link") 2>conftest.er1
8288   ac_status=$?
8289   grep -v '^ *+' conftest.er1 >conftest.err
8290   rm -f conftest.er1
8291   cat conftest.err >&5
8292   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8293   (exit $ac_status); } && {
8294          test -z "$ac_c_werror_flag" ||
8295          test ! -s conftest.err
8296        } && test -s conftest$ac_exeext && {
8297          test "$cross_compiling" = yes ||
8298          $as_test_x conftest$ac_exeext
8299        }; then
8300   ac_cv_lib_z_inflate=yes
8301 else
8302   $as_echo "$as_me: failed program was:" >&5
8303 sed 's/^/| /' conftest.$ac_ext >&5
8304
8305         ac_cv_lib_z_inflate=no
8306 fi
8307
8308 rm -rf conftest.dSYM
8309 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8310       conftest$ac_exeext conftest.$ac_ext
8311 LIBS=$ac_check_lib_save_LIBS
8312 fi
8313 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_z_inflate" >&5
8314 $as_echo "$ac_cv_lib_z_inflate" >&6; }
8315 if test "x$ac_cv_lib_z_inflate" = x""yes; then
8316   cat >>confdefs.h <<_ACEOF
8317 #define HAVE_LIBZ 1
8318 _ACEOF
8319
8320   LIBS="-lz $LIBS"
8321
8322 else
8323   { { $as_echo "$as_me:$LINENO: error: zlib library not found
8324 If you have zlib already installed, see config.log for details on the
8325 failure.  It is possible the compiler isn't looking in the proper directory.
8326 Use --without-zlib to disable zlib support." >&5
8327 $as_echo "$as_me: error: zlib library not found
8328 If you have zlib already installed, see config.log for details on the
8329 failure.  It is possible the compiler isn't looking in the proper directory.
8330 Use --without-zlib to disable zlib support." >&2;}
8331    { (exit 1); exit 1; }; }
8332 fi
8333
8334 fi
8335
8336 if test "$enable_spinlocks" = yes; then
8337
8338 cat >>confdefs.h <<\_ACEOF
8339 #define HAVE_SPINLOCKS 1
8340 _ACEOF
8341
8342 else
8343   { $as_echo "$as_me:$LINENO: WARNING:
8344 *** Not using spinlocks will cause poor performance." >&5
8345 $as_echo "$as_me: WARNING:
8346 *** Not using spinlocks will cause poor performance." >&2;}
8347 fi
8348
8349 if test "$with_gssapi" = yes ; then
8350   if test "$PORTNAME" != "win32"; then
8351     { $as_echo "$as_me:$LINENO: checking for library containing gss_init_sec_context" >&5
8352 $as_echo_n "checking for library containing gss_init_sec_context... " >&6; }
8353 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8354   $as_echo_n "(cached) " >&6
8355 else
8356   ac_func_search_save_LIBS=$LIBS
8357 cat >conftest.$ac_ext <<_ACEOF
8358 /* confdefs.h.  */
8359 _ACEOF
8360 cat confdefs.h >>conftest.$ac_ext
8361 cat >>conftest.$ac_ext <<_ACEOF
8362 /* end confdefs.h.  */
8363
8364 /* Override any GCC internal prototype to avoid an error.
8365    Use char because int might match the return type of a GCC
8366    builtin and then its argument prototype would still apply.  */
8367 #ifdef __cplusplus
8368 extern "C"
8369 #endif
8370 char gss_init_sec_context ();
8371 int
8372 main ()
8373 {
8374 return gss_init_sec_context ();
8375   ;
8376   return 0;
8377 }
8378 _ACEOF
8379 for ac_lib in '' gssapi_krb5 gss 'gssapi -lkrb5 -lcrypto'; do
8380   if test -z "$ac_lib"; then
8381     ac_res="none required"
8382   else
8383     ac_res=-l$ac_lib
8384     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8385   fi
8386   rm -f conftest.$ac_objext conftest$ac_exeext
8387 if { (ac_try="$ac_link"
8388 case "(($ac_try" in
8389   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8390   *) ac_try_echo=$ac_try;;
8391 esac
8392 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8393 $as_echo "$ac_try_echo") >&5
8394   (eval "$ac_link") 2>conftest.er1
8395   ac_status=$?
8396   grep -v '^ *+' conftest.er1 >conftest.err
8397   rm -f conftest.er1
8398   cat conftest.err >&5
8399   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8400   (exit $ac_status); } && {
8401          test -z "$ac_c_werror_flag" ||
8402          test ! -s conftest.err
8403        } && test -s conftest$ac_exeext && {
8404          test "$cross_compiling" = yes ||
8405          $as_test_x conftest$ac_exeext
8406        }; then
8407   ac_cv_search_gss_init_sec_context=$ac_res
8408 else
8409   $as_echo "$as_me: failed program was:" >&5
8410 sed 's/^/| /' conftest.$ac_ext >&5
8411
8412
8413 fi
8414
8415 rm -rf conftest.dSYM
8416 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8417       conftest$ac_exeext
8418   if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8419   break
8420 fi
8421 done
8422 if test "${ac_cv_search_gss_init_sec_context+set}" = set; then
8423   :
8424 else
8425   ac_cv_search_gss_init_sec_context=no
8426 fi
8427 rm conftest.$ac_ext
8428 LIBS=$ac_func_search_save_LIBS
8429 fi
8430 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_gss_init_sec_context" >&5
8431 $as_echo "$ac_cv_search_gss_init_sec_context" >&6; }
8432 ac_res=$ac_cv_search_gss_init_sec_context
8433 if test "$ac_res" != no; then
8434   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8435
8436 else
8437   { { $as_echo "$as_me:$LINENO: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&5
8438 $as_echo "$as_me: error: could not find function 'gss_init_sec_context' required for GSSAPI" >&2;}
8439    { (exit 1); exit 1; }; }
8440 fi
8441
8442   else
8443     LIBS="$LIBS -lgssapi32"
8444   fi
8445 fi
8446
8447 if test "$with_krb5" = yes ; then
8448   if test "$PORTNAME" != "win32"; then
8449      { $as_echo "$as_me:$LINENO: checking for library containing com_err" >&5
8450 $as_echo_n "checking for library containing com_err... " >&6; }
8451 if test "${ac_cv_search_com_err+set}" = set; then
8452   $as_echo_n "(cached) " >&6
8453 else
8454   ac_func_search_save_LIBS=$LIBS
8455 cat >conftest.$ac_ext <<_ACEOF
8456 /* confdefs.h.  */
8457 _ACEOF
8458 cat confdefs.h >>conftest.$ac_ext
8459 cat >>conftest.$ac_ext <<_ACEOF
8460 /* end confdefs.h.  */
8461
8462 /* Override any GCC internal prototype to avoid an error.
8463    Use char because int might match the return type of a GCC
8464    builtin and then its argument prototype would still apply.  */
8465 #ifdef __cplusplus
8466 extern "C"
8467 #endif
8468 char com_err ();
8469 int
8470 main ()
8471 {
8472 return com_err ();
8473   ;
8474   return 0;
8475 }
8476 _ACEOF
8477 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken' com_err 'com_err -lssl -lcrypto'; do
8478   if test -z "$ac_lib"; then
8479     ac_res="none required"
8480   else
8481     ac_res=-l$ac_lib
8482     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8483   fi
8484   rm -f conftest.$ac_objext conftest$ac_exeext
8485 if { (ac_try="$ac_link"
8486 case "(($ac_try" in
8487   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8488   *) ac_try_echo=$ac_try;;
8489 esac
8490 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8491 $as_echo "$ac_try_echo") >&5
8492   (eval "$ac_link") 2>conftest.er1
8493   ac_status=$?
8494   grep -v '^ *+' conftest.er1 >conftest.err
8495   rm -f conftest.er1
8496   cat conftest.err >&5
8497   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8498   (exit $ac_status); } && {
8499          test -z "$ac_c_werror_flag" ||
8500          test ! -s conftest.err
8501        } && test -s conftest$ac_exeext && {
8502          test "$cross_compiling" = yes ||
8503          $as_test_x conftest$ac_exeext
8504        }; then
8505   ac_cv_search_com_err=$ac_res
8506 else
8507   $as_echo "$as_me: failed program was:" >&5
8508 sed 's/^/| /' conftest.$ac_ext >&5
8509
8510
8511 fi
8512
8513 rm -rf conftest.dSYM
8514 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8515       conftest$ac_exeext
8516   if test "${ac_cv_search_com_err+set}" = set; then
8517   break
8518 fi
8519 done
8520 if test "${ac_cv_search_com_err+set}" = set; then
8521   :
8522 else
8523   ac_cv_search_com_err=no
8524 fi
8525 rm conftest.$ac_ext
8526 LIBS=$ac_func_search_save_LIBS
8527 fi
8528 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
8529 $as_echo "$ac_cv_search_com_err" >&6; }
8530 ac_res=$ac_cv_search_com_err
8531 if test "$ac_res" != no; then
8532   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8533
8534 else
8535   { { $as_echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
8536 $as_echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
8537    { (exit 1); exit 1; }; }
8538 fi
8539
8540      { $as_echo "$as_me:$LINENO: checking for library containing krb5_sendauth" >&5
8541 $as_echo_n "checking for library containing krb5_sendauth... " >&6; }
8542 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8543   $as_echo_n "(cached) " >&6
8544 else
8545   ac_func_search_save_LIBS=$LIBS
8546 cat >conftest.$ac_ext <<_ACEOF
8547 /* confdefs.h.  */
8548 _ACEOF
8549 cat confdefs.h >>conftest.$ac_ext
8550 cat >>conftest.$ac_ext <<_ACEOF
8551 /* end confdefs.h.  */
8552
8553 /* Override any GCC internal prototype to avoid an error.
8554    Use char because int might match the return type of a GCC
8555    builtin and then its argument prototype would still apply.  */
8556 #ifdef __cplusplus
8557 extern "C"
8558 #endif
8559 char krb5_sendauth ();
8560 int
8561 main ()
8562 {
8563 return krb5_sendauth ();
8564   ;
8565   return 0;
8566 }
8567 _ACEOF
8568 for ac_lib in '' krb5 'krb5 -lcrypto -ldes -lasn1 -lroken'; do
8569   if test -z "$ac_lib"; then
8570     ac_res="none required"
8571   else
8572     ac_res=-l$ac_lib
8573     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8574   fi
8575   rm -f conftest.$ac_objext conftest$ac_exeext
8576 if { (ac_try="$ac_link"
8577 case "(($ac_try" in
8578   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8579   *) ac_try_echo=$ac_try;;
8580 esac
8581 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8582 $as_echo "$ac_try_echo") >&5
8583   (eval "$ac_link") 2>conftest.er1
8584   ac_status=$?
8585   grep -v '^ *+' conftest.er1 >conftest.err
8586   rm -f conftest.er1
8587   cat conftest.err >&5
8588   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8589   (exit $ac_status); } && {
8590          test -z "$ac_c_werror_flag" ||
8591          test ! -s conftest.err
8592        } && test -s conftest$ac_exeext && {
8593          test "$cross_compiling" = yes ||
8594          $as_test_x conftest$ac_exeext
8595        }; then
8596   ac_cv_search_krb5_sendauth=$ac_res
8597 else
8598   $as_echo "$as_me: failed program was:" >&5
8599 sed 's/^/| /' conftest.$ac_ext >&5
8600
8601
8602 fi
8603
8604 rm -rf conftest.dSYM
8605 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8606       conftest$ac_exeext
8607   if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8608   break
8609 fi
8610 done
8611 if test "${ac_cv_search_krb5_sendauth+set}" = set; then
8612   :
8613 else
8614   ac_cv_search_krb5_sendauth=no
8615 fi
8616 rm conftest.$ac_ext
8617 LIBS=$ac_func_search_save_LIBS
8618 fi
8619 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_krb5_sendauth" >&5
8620 $as_echo "$ac_cv_search_krb5_sendauth" >&6; }
8621 ac_res=$ac_cv_search_krb5_sendauth
8622 if test "$ac_res" != no; then
8623   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8624
8625 else
8626   { { $as_echo "$as_me:$LINENO: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&5
8627 $as_echo "$as_me: error: could not find function 'krb5_sendauth' required for Kerberos 5" >&2;}
8628    { (exit 1); exit 1; }; }
8629 fi
8630
8631   else
8632      { $as_echo "$as_me:$LINENO: checking for library containing com_err" >&5
8633 $as_echo_n "checking for library containing com_err... " >&6; }
8634 if test "${ac_cv_search_com_err+set}" = set; then
8635   $as_echo_n "(cached) " >&6
8636 else
8637   ac_func_search_save_LIBS=$LIBS
8638 cat >conftest.$ac_ext <<_ACEOF
8639 /* confdefs.h.  */
8640 _ACEOF
8641 cat confdefs.h >>conftest.$ac_ext
8642 cat >>conftest.$ac_ext <<_ACEOF
8643 /* end confdefs.h.  */
8644
8645 /* Override any GCC internal prototype to avoid an error.
8646    Use char because int might match the return type of a GCC
8647    builtin and then its argument prototype would still apply.  */
8648 #ifdef __cplusplus
8649 extern "C"
8650 #endif
8651 char com_err ();
8652 int
8653 main ()
8654 {
8655 return com_err ();
8656   ;
8657   return 0;
8658 }
8659 _ACEOF
8660 for ac_lib in '' 'comerr32 -lkrb5_32'; do
8661   if test -z "$ac_lib"; then
8662     ac_res="none required"
8663   else
8664     ac_res=-l$ac_lib
8665     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
8666   fi
8667   rm -f conftest.$ac_objext conftest$ac_exeext
8668 if { (ac_try="$ac_link"
8669 case "(($ac_try" in
8670   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8671   *) ac_try_echo=$ac_try;;
8672 esac
8673 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8674 $as_echo "$ac_try_echo") >&5
8675   (eval "$ac_link") 2>conftest.er1
8676   ac_status=$?
8677   grep -v '^ *+' conftest.er1 >conftest.err
8678   rm -f conftest.er1
8679   cat conftest.err >&5
8680   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8681   (exit $ac_status); } && {
8682          test -z "$ac_c_werror_flag" ||
8683          test ! -s conftest.err
8684        } && test -s conftest$ac_exeext && {
8685          test "$cross_compiling" = yes ||
8686          $as_test_x conftest$ac_exeext
8687        }; then
8688   ac_cv_search_com_err=$ac_res
8689 else
8690   $as_echo "$as_me: failed program was:" >&5
8691 sed 's/^/| /' conftest.$ac_ext >&5
8692
8693
8694 fi
8695
8696 rm -rf conftest.dSYM
8697 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8698       conftest$ac_exeext
8699   if test "${ac_cv_search_com_err+set}" = set; then
8700   break
8701 fi
8702 done
8703 if test "${ac_cv_search_com_err+set}" = set; then
8704   :
8705 else
8706   ac_cv_search_com_err=no
8707 fi
8708 rm conftest.$ac_ext
8709 LIBS=$ac_func_search_save_LIBS
8710 fi
8711 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_com_err" >&5
8712 $as_echo "$ac_cv_search_com_err" >&6; }
8713 ac_res=$ac_cv_search_com_err
8714 if test "$ac_res" != no; then
8715   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
8716
8717 else
8718   { { $as_echo "$as_me:$LINENO: error: could not find function 'com_err' required for Kerberos 5" >&5
8719 $as_echo "$as_me: error: could not find function 'com_err' required for Kerberos 5" >&2;}
8720    { (exit 1); exit 1; }; }
8721 fi
8722
8723   fi
8724 fi
8725
8726 if test "$with_openssl" = yes ; then
8727     if test "$PORTNAME" != "win32"; then
8728
8729 { $as_echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -lcrypto" >&5
8730 $as_echo_n "checking for CRYPTO_new_ex_data in -lcrypto... " >&6; }
8731 if test "${ac_cv_lib_crypto_CRYPTO_new_ex_data+set}" = set; then
8732   $as_echo_n "(cached) " >&6
8733 else
8734   ac_check_lib_save_LIBS=$LIBS
8735 LIBS="-lcrypto  $LIBS"
8736 cat >conftest.$ac_ext <<_ACEOF
8737 /* confdefs.h.  */
8738 _ACEOF
8739 cat confdefs.h >>conftest.$ac_ext
8740 cat >>conftest.$ac_ext <<_ACEOF
8741 /* end confdefs.h.  */
8742
8743 /* Override any GCC internal prototype to avoid an error.
8744    Use char because int might match the return type of a GCC
8745    builtin and then its argument prototype would still apply.  */
8746 #ifdef __cplusplus
8747 extern "C"
8748 #endif
8749 char CRYPTO_new_ex_data ();
8750 int
8751 main ()
8752 {
8753 return CRYPTO_new_ex_data ();
8754   ;
8755   return 0;
8756 }
8757 _ACEOF
8758 rm -f conftest.$ac_objext conftest$ac_exeext
8759 if { (ac_try="$ac_link"
8760 case "(($ac_try" in
8761   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8762   *) ac_try_echo=$ac_try;;
8763 esac
8764 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8765 $as_echo "$ac_try_echo") >&5
8766   (eval "$ac_link") 2>conftest.er1
8767   ac_status=$?
8768   grep -v '^ *+' conftest.er1 >conftest.err
8769   rm -f conftest.er1
8770   cat conftest.err >&5
8771   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8772   (exit $ac_status); } && {
8773          test -z "$ac_c_werror_flag" ||
8774          test ! -s conftest.err
8775        } && test -s conftest$ac_exeext && {
8776          test "$cross_compiling" = yes ||
8777          $as_test_x conftest$ac_exeext
8778        }; then
8779   ac_cv_lib_crypto_CRYPTO_new_ex_data=yes
8780 else
8781   $as_echo "$as_me: failed program was:" >&5
8782 sed 's/^/| /' conftest.$ac_ext >&5
8783
8784         ac_cv_lib_crypto_CRYPTO_new_ex_data=no
8785 fi
8786
8787 rm -rf conftest.dSYM
8788 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8789       conftest$ac_exeext conftest.$ac_ext
8790 LIBS=$ac_check_lib_save_LIBS
8791 fi
8792 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_crypto_CRYPTO_new_ex_data" >&5
8793 $as_echo "$ac_cv_lib_crypto_CRYPTO_new_ex_data" >&6; }
8794 if test "x$ac_cv_lib_crypto_CRYPTO_new_ex_data" = x""yes; then
8795   cat >>confdefs.h <<_ACEOF
8796 #define HAVE_LIBCRYPTO 1
8797 _ACEOF
8798
8799   LIBS="-lcrypto $LIBS"
8800
8801 else
8802   { { $as_echo "$as_me:$LINENO: error: library 'crypto' is required for OpenSSL" >&5
8803 $as_echo "$as_me: error: library 'crypto' is required for OpenSSL" >&2;}
8804    { (exit 1); exit 1; }; }
8805 fi
8806
8807
8808 { $as_echo "$as_me:$LINENO: checking for SSL_library_init in -lssl" >&5
8809 $as_echo_n "checking for SSL_library_init in -lssl... " >&6; }
8810 if test "${ac_cv_lib_ssl_SSL_library_init+set}" = set; then
8811   $as_echo_n "(cached) " >&6
8812 else
8813   ac_check_lib_save_LIBS=$LIBS
8814 LIBS="-lssl  $LIBS"
8815 cat >conftest.$ac_ext <<_ACEOF
8816 /* confdefs.h.  */
8817 _ACEOF
8818 cat confdefs.h >>conftest.$ac_ext
8819 cat >>conftest.$ac_ext <<_ACEOF
8820 /* end confdefs.h.  */
8821
8822 /* Override any GCC internal prototype to avoid an error.
8823    Use char because int might match the return type of a GCC
8824    builtin and then its argument prototype would still apply.  */
8825 #ifdef __cplusplus
8826 extern "C"
8827 #endif
8828 char SSL_library_init ();
8829 int
8830 main ()
8831 {
8832 return SSL_library_init ();
8833   ;
8834   return 0;
8835 }
8836 _ACEOF
8837 rm -f conftest.$ac_objext conftest$ac_exeext
8838 if { (ac_try="$ac_link"
8839 case "(($ac_try" in
8840   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8841   *) ac_try_echo=$ac_try;;
8842 esac
8843 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8844 $as_echo "$ac_try_echo") >&5
8845   (eval "$ac_link") 2>conftest.er1
8846   ac_status=$?
8847   grep -v '^ *+' conftest.er1 >conftest.err
8848   rm -f conftest.er1
8849   cat conftest.err >&5
8850   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8851   (exit $ac_status); } && {
8852          test -z "$ac_c_werror_flag" ||
8853          test ! -s conftest.err
8854        } && test -s conftest$ac_exeext && {
8855          test "$cross_compiling" = yes ||
8856          $as_test_x conftest$ac_exeext
8857        }; then
8858   ac_cv_lib_ssl_SSL_library_init=yes
8859 else
8860   $as_echo "$as_me: failed program was:" >&5
8861 sed 's/^/| /' conftest.$ac_ext >&5
8862
8863         ac_cv_lib_ssl_SSL_library_init=no
8864 fi
8865
8866 rm -rf conftest.dSYM
8867 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8868       conftest$ac_exeext conftest.$ac_ext
8869 LIBS=$ac_check_lib_save_LIBS
8870 fi
8871 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ssl_SSL_library_init" >&5
8872 $as_echo "$ac_cv_lib_ssl_SSL_library_init" >&6; }
8873 if test "x$ac_cv_lib_ssl_SSL_library_init" = x""yes; then
8874   cat >>confdefs.h <<_ACEOF
8875 #define HAVE_LIBSSL 1
8876 _ACEOF
8877
8878   LIBS="-lssl $LIBS"
8879
8880 else
8881   { { $as_echo "$as_me:$LINENO: error: library 'ssl' is required for OpenSSL" >&5
8882 $as_echo "$as_me: error: library 'ssl' is required for OpenSSL" >&2;}
8883    { (exit 1); exit 1; }; }
8884 fi
8885
8886   else
8887
8888 { $as_echo "$as_me:$LINENO: checking for CRYPTO_new_ex_data in -leay32" >&5
8889 $as_echo_n "checking for CRYPTO_new_ex_data in -leay32... " >&6; }
8890 if test "${ac_cv_lib_eay32_CRYPTO_new_ex_data+set}" = set; then
8891   $as_echo_n "(cached) " >&6
8892 else
8893   ac_check_lib_save_LIBS=$LIBS
8894 LIBS="-leay32  $LIBS"
8895 cat >conftest.$ac_ext <<_ACEOF
8896 /* confdefs.h.  */
8897 _ACEOF
8898 cat confdefs.h >>conftest.$ac_ext
8899 cat >>conftest.$ac_ext <<_ACEOF
8900 /* end confdefs.h.  */
8901
8902 /* Override any GCC internal prototype to avoid an error.
8903    Use char because int might match the return type of a GCC
8904    builtin and then its argument prototype would still apply.  */
8905 #ifdef __cplusplus
8906 extern "C"
8907 #endif
8908 char CRYPTO_new_ex_data ();
8909 int
8910 main ()
8911 {
8912 return CRYPTO_new_ex_data ();
8913   ;
8914   return 0;
8915 }
8916 _ACEOF
8917 rm -f conftest.$ac_objext conftest$ac_exeext
8918 if { (ac_try="$ac_link"
8919 case "(($ac_try" in
8920   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
8921   *) ac_try_echo=$ac_try;;
8922 esac
8923 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
8924 $as_echo "$ac_try_echo") >&5
8925   (eval "$ac_link") 2>conftest.er1
8926   ac_status=$?
8927   grep -v '^ *+' conftest.er1 >conftest.err
8928   rm -f conftest.er1
8929   cat conftest.err >&5
8930   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
8931   (exit $ac_status); } && {
8932          test -z "$ac_c_werror_flag" ||
8933          test ! -s conftest.err
8934        } && test -s conftest$ac_exeext && {
8935          test "$cross_compiling" = yes ||
8936          $as_test_x conftest$ac_exeext
8937        }; then
8938   ac_cv_lib_eay32_CRYPTO_new_ex_data=yes
8939 else
8940   $as_echo "$as_me: failed program was:" >&5
8941 sed 's/^/| /' conftest.$ac_ext >&5
8942
8943         ac_cv_lib_eay32_CRYPTO_new_ex_data=no
8944 fi
8945
8946 rm -rf conftest.dSYM
8947 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
8948       conftest$ac_exeext conftest.$ac_ext
8949 LIBS=$ac_check_lib_save_LIBS
8950 fi
8951 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_eay32_CRYPTO_new_ex_data" >&5
8952 $as_echo "$ac_cv_lib_eay32_CRYPTO_new_ex_data" >&6; }
8953 if test "x$ac_cv_lib_eay32_CRYPTO_new_ex_data" = x""yes; then
8954   cat >>confdefs.h <<_ACEOF
8955 #define HAVE_LIBEAY32 1
8956 _ACEOF
8957
8958   LIBS="-leay32 $LIBS"
8959
8960 else
8961   { { $as_echo "$as_me:$LINENO: error: library 'eay32' is required for OpenSSL" >&5
8962 $as_echo "$as_me: error: library 'eay32' is required for OpenSSL" >&2;}
8963    { (exit 1); exit 1; }; }
8964 fi
8965
8966
8967 { $as_echo "$as_me:$LINENO: checking for SSL_library_init in -lssleay32" >&5
8968 $as_echo_n "checking for SSL_library_init in -lssleay32... " >&6; }
8969 if test "${ac_cv_lib_ssleay32_SSL_library_init+set}" = set; then
8970   $as_echo_n "(cached) " >&6
8971 else
8972   ac_check_lib_save_LIBS=$LIBS
8973 LIBS="-lssleay32  $LIBS"
8974 cat >conftest.$ac_ext <<_ACEOF
8975 /* confdefs.h.  */
8976 _ACEOF
8977 cat confdefs.h >>conftest.$ac_ext
8978 cat >>conftest.$ac_ext <<_ACEOF
8979 /* end confdefs.h.  */
8980
8981 /* Override any GCC internal prototype to avoid an error.
8982    Use char because int might match the return type of a GCC
8983    builtin and then its argument prototype would still apply.  */
8984 #ifdef __cplusplus
8985 extern "C"
8986 #endif
8987 char SSL_library_init ();
8988 int
8989 main ()
8990 {
8991 return SSL_library_init ();
8992   ;
8993   return 0;
8994 }
8995 _ACEOF
8996 rm -f conftest.$ac_objext conftest$ac_exeext
8997 if { (ac_try="$ac_link"
8998 case "(($ac_try" in
8999   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9000   *) ac_try_echo=$ac_try;;
9001 esac
9002 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9003 $as_echo "$ac_try_echo") >&5
9004   (eval "$ac_link") 2>conftest.er1
9005   ac_status=$?
9006   grep -v '^ *+' conftest.er1 >conftest.err
9007   rm -f conftest.er1
9008   cat conftest.err >&5
9009   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9010   (exit $ac_status); } && {
9011          test -z "$ac_c_werror_flag" ||
9012          test ! -s conftest.err
9013        } && test -s conftest$ac_exeext && {
9014          test "$cross_compiling" = yes ||
9015          $as_test_x conftest$ac_exeext
9016        }; then
9017   ac_cv_lib_ssleay32_SSL_library_init=yes
9018 else
9019   $as_echo "$as_me: failed program was:" >&5
9020 sed 's/^/| /' conftest.$ac_ext >&5
9021
9022         ac_cv_lib_ssleay32_SSL_library_init=no
9023 fi
9024
9025 rm -rf conftest.dSYM
9026 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9027       conftest$ac_exeext conftest.$ac_ext
9028 LIBS=$ac_check_lib_save_LIBS
9029 fi
9030 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ssleay32_SSL_library_init" >&5
9031 $as_echo "$ac_cv_lib_ssleay32_SSL_library_init" >&6; }
9032 if test "x$ac_cv_lib_ssleay32_SSL_library_init" = x""yes; then
9033   cat >>confdefs.h <<_ACEOF
9034 #define HAVE_LIBSSLEAY32 1
9035 _ACEOF
9036
9037   LIBS="-lssleay32 $LIBS"
9038
9039 else
9040   { { $as_echo "$as_me:$LINENO: error: library 'ssleay32' is required for OpenSSL" >&5
9041 $as_echo "$as_me: error: library 'ssleay32' is required for OpenSSL" >&2;}
9042    { (exit 1); exit 1; }; }
9043 fi
9044
9045   fi
9046 fi
9047
9048 if test "$with_pam" = yes ; then
9049
9050 { $as_echo "$as_me:$LINENO: checking for pam_start in -lpam" >&5
9051 $as_echo_n "checking for pam_start in -lpam... " >&6; }
9052 if test "${ac_cv_lib_pam_pam_start+set}" = set; then
9053   $as_echo_n "(cached) " >&6
9054 else
9055   ac_check_lib_save_LIBS=$LIBS
9056 LIBS="-lpam  $LIBS"
9057 cat >conftest.$ac_ext <<_ACEOF
9058 /* confdefs.h.  */
9059 _ACEOF
9060 cat confdefs.h >>conftest.$ac_ext
9061 cat >>conftest.$ac_ext <<_ACEOF
9062 /* end confdefs.h.  */
9063
9064 /* Override any GCC internal prototype to avoid an error.
9065    Use char because int might match the return type of a GCC
9066    builtin and then its argument prototype would still apply.  */
9067 #ifdef __cplusplus
9068 extern "C"
9069 #endif
9070 char pam_start ();
9071 int
9072 main ()
9073 {
9074 return pam_start ();
9075   ;
9076   return 0;
9077 }
9078 _ACEOF
9079 rm -f conftest.$ac_objext conftest$ac_exeext
9080 if { (ac_try="$ac_link"
9081 case "(($ac_try" in
9082   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9083   *) ac_try_echo=$ac_try;;
9084 esac
9085 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9086 $as_echo "$ac_try_echo") >&5
9087   (eval "$ac_link") 2>conftest.er1
9088   ac_status=$?
9089   grep -v '^ *+' conftest.er1 >conftest.err
9090   rm -f conftest.er1
9091   cat conftest.err >&5
9092   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9093   (exit $ac_status); } && {
9094          test -z "$ac_c_werror_flag" ||
9095          test ! -s conftest.err
9096        } && test -s conftest$ac_exeext && {
9097          test "$cross_compiling" = yes ||
9098          $as_test_x conftest$ac_exeext
9099        }; then
9100   ac_cv_lib_pam_pam_start=yes
9101 else
9102   $as_echo "$as_me: failed program was:" >&5
9103 sed 's/^/| /' conftest.$ac_ext >&5
9104
9105         ac_cv_lib_pam_pam_start=no
9106 fi
9107
9108 rm -rf conftest.dSYM
9109 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9110       conftest$ac_exeext conftest.$ac_ext
9111 LIBS=$ac_check_lib_save_LIBS
9112 fi
9113 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_pam_pam_start" >&5
9114 $as_echo "$ac_cv_lib_pam_pam_start" >&6; }
9115 if test "x$ac_cv_lib_pam_pam_start" = x""yes; then
9116   cat >>confdefs.h <<_ACEOF
9117 #define HAVE_LIBPAM 1
9118 _ACEOF
9119
9120   LIBS="-lpam $LIBS"
9121
9122 else
9123   { { $as_echo "$as_me:$LINENO: error: library 'pam' is required for PAM" >&5
9124 $as_echo "$as_me: error: library 'pam' is required for PAM" >&2;}
9125    { (exit 1); exit 1; }; }
9126 fi
9127
9128 fi
9129
9130 if test "$with_libxml" = yes ; then
9131
9132 { $as_echo "$as_me:$LINENO: checking for xmlSaveToBuffer in -lxml2" >&5
9133 $as_echo_n "checking for xmlSaveToBuffer in -lxml2... " >&6; }
9134 if test "${ac_cv_lib_xml2_xmlSaveToBuffer+set}" = set; then
9135   $as_echo_n "(cached) " >&6
9136 else
9137   ac_check_lib_save_LIBS=$LIBS
9138 LIBS="-lxml2  $LIBS"
9139 cat >conftest.$ac_ext <<_ACEOF
9140 /* confdefs.h.  */
9141 _ACEOF
9142 cat confdefs.h >>conftest.$ac_ext
9143 cat >>conftest.$ac_ext <<_ACEOF
9144 /* end confdefs.h.  */
9145
9146 /* Override any GCC internal prototype to avoid an error.
9147    Use char because int might match the return type of a GCC
9148    builtin and then its argument prototype would still apply.  */
9149 #ifdef __cplusplus
9150 extern "C"
9151 #endif
9152 char xmlSaveToBuffer ();
9153 int
9154 main ()
9155 {
9156 return xmlSaveToBuffer ();
9157   ;
9158   return 0;
9159 }
9160 _ACEOF
9161 rm -f conftest.$ac_objext conftest$ac_exeext
9162 if { (ac_try="$ac_link"
9163 case "(($ac_try" in
9164   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9165   *) ac_try_echo=$ac_try;;
9166 esac
9167 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9168 $as_echo "$ac_try_echo") >&5
9169   (eval "$ac_link") 2>conftest.er1
9170   ac_status=$?
9171   grep -v '^ *+' conftest.er1 >conftest.err
9172   rm -f conftest.er1
9173   cat conftest.err >&5
9174   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9175   (exit $ac_status); } && {
9176          test -z "$ac_c_werror_flag" ||
9177          test ! -s conftest.err
9178        } && test -s conftest$ac_exeext && {
9179          test "$cross_compiling" = yes ||
9180          $as_test_x conftest$ac_exeext
9181        }; then
9182   ac_cv_lib_xml2_xmlSaveToBuffer=yes
9183 else
9184   $as_echo "$as_me: failed program was:" >&5
9185 sed 's/^/| /' conftest.$ac_ext >&5
9186
9187         ac_cv_lib_xml2_xmlSaveToBuffer=no
9188 fi
9189
9190 rm -rf conftest.dSYM
9191 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9192       conftest$ac_exeext conftest.$ac_ext
9193 LIBS=$ac_check_lib_save_LIBS
9194 fi
9195 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xml2_xmlSaveToBuffer" >&5
9196 $as_echo "$ac_cv_lib_xml2_xmlSaveToBuffer" >&6; }
9197 if test "x$ac_cv_lib_xml2_xmlSaveToBuffer" = x""yes; then
9198   cat >>confdefs.h <<_ACEOF
9199 #define HAVE_LIBXML2 1
9200 _ACEOF
9201
9202   LIBS="-lxml2 $LIBS"
9203
9204 else
9205   { { $as_echo "$as_me:$LINENO: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&5
9206 $as_echo "$as_me: error: library 'xml2' (version >= 2.6.23) is required for XML support" >&2;}
9207    { (exit 1); exit 1; }; }
9208 fi
9209
9210 fi
9211
9212 if test "$with_libxslt" = yes ; then
9213
9214 { $as_echo "$as_me:$LINENO: checking for xsltCleanupGlobals in -lxslt" >&5
9215 $as_echo_n "checking for xsltCleanupGlobals in -lxslt... " >&6; }
9216 if test "${ac_cv_lib_xslt_xsltCleanupGlobals+set}" = set; then
9217   $as_echo_n "(cached) " >&6
9218 else
9219   ac_check_lib_save_LIBS=$LIBS
9220 LIBS="-lxslt  $LIBS"
9221 cat >conftest.$ac_ext <<_ACEOF
9222 /* confdefs.h.  */
9223 _ACEOF
9224 cat confdefs.h >>conftest.$ac_ext
9225 cat >>conftest.$ac_ext <<_ACEOF
9226 /* end confdefs.h.  */
9227
9228 /* Override any GCC internal prototype to avoid an error.
9229    Use char because int might match the return type of a GCC
9230    builtin and then its argument prototype would still apply.  */
9231 #ifdef __cplusplus
9232 extern "C"
9233 #endif
9234 char xsltCleanupGlobals ();
9235 int
9236 main ()
9237 {
9238 return xsltCleanupGlobals ();
9239   ;
9240   return 0;
9241 }
9242 _ACEOF
9243 rm -f conftest.$ac_objext conftest$ac_exeext
9244 if { (ac_try="$ac_link"
9245 case "(($ac_try" in
9246   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9247   *) ac_try_echo=$ac_try;;
9248 esac
9249 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9250 $as_echo "$ac_try_echo") >&5
9251   (eval "$ac_link") 2>conftest.er1
9252   ac_status=$?
9253   grep -v '^ *+' conftest.er1 >conftest.err
9254   rm -f conftest.er1
9255   cat conftest.err >&5
9256   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9257   (exit $ac_status); } && {
9258          test -z "$ac_c_werror_flag" ||
9259          test ! -s conftest.err
9260        } && test -s conftest$ac_exeext && {
9261          test "$cross_compiling" = yes ||
9262          $as_test_x conftest$ac_exeext
9263        }; then
9264   ac_cv_lib_xslt_xsltCleanupGlobals=yes
9265 else
9266   $as_echo "$as_me: failed program was:" >&5
9267 sed 's/^/| /' conftest.$ac_ext >&5
9268
9269         ac_cv_lib_xslt_xsltCleanupGlobals=no
9270 fi
9271
9272 rm -rf conftest.dSYM
9273 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9274       conftest$ac_exeext conftest.$ac_ext
9275 LIBS=$ac_check_lib_save_LIBS
9276 fi
9277 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_xslt_xsltCleanupGlobals" >&5
9278 $as_echo "$ac_cv_lib_xslt_xsltCleanupGlobals" >&6; }
9279 if test "x$ac_cv_lib_xslt_xsltCleanupGlobals" = x""yes; then
9280   cat >>confdefs.h <<_ACEOF
9281 #define HAVE_LIBXSLT 1
9282 _ACEOF
9283
9284   LIBS="-lxslt $LIBS"
9285
9286 else
9287   { { $as_echo "$as_me:$LINENO: error: library 'xslt' is required for XSLT support" >&5
9288 $as_echo "$as_me: error: library 'xslt' is required for XSLT support" >&2;}
9289    { (exit 1); exit 1; }; }
9290 fi
9291
9292 fi
9293
9294 # for contrib/uuid-ossp
9295 if test "$with_ossp_uuid" = yes ; then
9296   { $as_echo "$as_me:$LINENO: checking for uuid_export in -lossp-uuid" >&5
9297 $as_echo_n "checking for uuid_export in -lossp-uuid... " >&6; }
9298 if test "${ac_cv_lib_ossp_uuid_uuid_export+set}" = set; then
9299   $as_echo_n "(cached) " >&6
9300 else
9301   ac_check_lib_save_LIBS=$LIBS
9302 LIBS="-lossp-uuid  $LIBS"
9303 cat >conftest.$ac_ext <<_ACEOF
9304 /* confdefs.h.  */
9305 _ACEOF
9306 cat confdefs.h >>conftest.$ac_ext
9307 cat >>conftest.$ac_ext <<_ACEOF
9308 /* end confdefs.h.  */
9309
9310 /* Override any GCC internal prototype to avoid an error.
9311    Use char because int might match the return type of a GCC
9312    builtin and then its argument prototype would still apply.  */
9313 #ifdef __cplusplus
9314 extern "C"
9315 #endif
9316 char uuid_export ();
9317 int
9318 main ()
9319 {
9320 return uuid_export ();
9321   ;
9322   return 0;
9323 }
9324 _ACEOF
9325 rm -f conftest.$ac_objext conftest$ac_exeext
9326 if { (ac_try="$ac_link"
9327 case "(($ac_try" in
9328   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9329   *) ac_try_echo=$ac_try;;
9330 esac
9331 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9332 $as_echo "$ac_try_echo") >&5
9333   (eval "$ac_link") 2>conftest.er1
9334   ac_status=$?
9335   grep -v '^ *+' conftest.er1 >conftest.err
9336   rm -f conftest.er1
9337   cat conftest.err >&5
9338   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9339   (exit $ac_status); } && {
9340          test -z "$ac_c_werror_flag" ||
9341          test ! -s conftest.err
9342        } && test -s conftest$ac_exeext && {
9343          test "$cross_compiling" = yes ||
9344          $as_test_x conftest$ac_exeext
9345        }; then
9346   ac_cv_lib_ossp_uuid_uuid_export=yes
9347 else
9348   $as_echo "$as_me: failed program was:" >&5
9349 sed 's/^/| /' conftest.$ac_ext >&5
9350
9351         ac_cv_lib_ossp_uuid_uuid_export=no
9352 fi
9353
9354 rm -rf conftest.dSYM
9355 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9356       conftest$ac_exeext conftest.$ac_ext
9357 LIBS=$ac_check_lib_save_LIBS
9358 fi
9359 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ossp_uuid_uuid_export" >&5
9360 $as_echo "$ac_cv_lib_ossp_uuid_uuid_export" >&6; }
9361 if test "x$ac_cv_lib_ossp_uuid_uuid_export" = x""yes; then
9362   OSSP_UUID_LIBS="-lossp-uuid"
9363 else
9364   { $as_echo "$as_me:$LINENO: checking for uuid_export in -luuid" >&5
9365 $as_echo_n "checking for uuid_export in -luuid... " >&6; }
9366 if test "${ac_cv_lib_uuid_uuid_export+set}" = set; then
9367   $as_echo_n "(cached) " >&6
9368 else
9369   ac_check_lib_save_LIBS=$LIBS
9370 LIBS="-luuid  $LIBS"
9371 cat >conftest.$ac_ext <<_ACEOF
9372 /* confdefs.h.  */
9373 _ACEOF
9374 cat confdefs.h >>conftest.$ac_ext
9375 cat >>conftest.$ac_ext <<_ACEOF
9376 /* end confdefs.h.  */
9377
9378 /* Override any GCC internal prototype to avoid an error.
9379    Use char because int might match the return type of a GCC
9380    builtin and then its argument prototype would still apply.  */
9381 #ifdef __cplusplus
9382 extern "C"
9383 #endif
9384 char uuid_export ();
9385 int
9386 main ()
9387 {
9388 return uuid_export ();
9389   ;
9390   return 0;
9391 }
9392 _ACEOF
9393 rm -f conftest.$ac_objext conftest$ac_exeext
9394 if { (ac_try="$ac_link"
9395 case "(($ac_try" in
9396   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9397   *) ac_try_echo=$ac_try;;
9398 esac
9399 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9400 $as_echo "$ac_try_echo") >&5
9401   (eval "$ac_link") 2>conftest.er1
9402   ac_status=$?
9403   grep -v '^ *+' conftest.er1 >conftest.err
9404   rm -f conftest.er1
9405   cat conftest.err >&5
9406   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9407   (exit $ac_status); } && {
9408          test -z "$ac_c_werror_flag" ||
9409          test ! -s conftest.err
9410        } && test -s conftest$ac_exeext && {
9411          test "$cross_compiling" = yes ||
9412          $as_test_x conftest$ac_exeext
9413        }; then
9414   ac_cv_lib_uuid_uuid_export=yes
9415 else
9416   $as_echo "$as_me: failed program was:" >&5
9417 sed 's/^/| /' conftest.$ac_ext >&5
9418
9419         ac_cv_lib_uuid_uuid_export=no
9420 fi
9421
9422 rm -rf conftest.dSYM
9423 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
9424       conftest$ac_exeext conftest.$ac_ext
9425 LIBS=$ac_check_lib_save_LIBS
9426 fi
9427 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_uuid_uuid_export" >&5
9428 $as_echo "$ac_cv_lib_uuid_uuid_export" >&6; }
9429 if test "x$ac_cv_lib_uuid_uuid_export" = x""yes; then
9430   OSSP_UUID_LIBS="-luuid"
9431 else
9432   { { $as_echo "$as_me:$LINENO: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&5
9433 $as_echo "$as_me: error: library 'ossp-uuid' or 'uuid' is required for OSSP-UUID" >&2;}
9434    { (exit 1); exit 1; }; }
9435 fi
9436
9437 fi
9438
9439 fi
9440
9441
9442
9443 ##
9444 ## Header files
9445 ##
9446
9447 { $as_echo "$as_me:$LINENO: checking for ANSI C header files" >&5
9448 $as_echo_n "checking for ANSI C header files... " >&6; }
9449 if test "${ac_cv_header_stdc+set}" = set; then
9450   $as_echo_n "(cached) " >&6
9451 else
9452   cat >conftest.$ac_ext <<_ACEOF
9453 /* confdefs.h.  */
9454 _ACEOF
9455 cat confdefs.h >>conftest.$ac_ext
9456 cat >>conftest.$ac_ext <<_ACEOF
9457 /* end confdefs.h.  */
9458 #include <stdlib.h>
9459 #include <stdarg.h>
9460 #include <string.h>
9461 #include <float.h>
9462
9463 int
9464 main ()
9465 {
9466
9467   ;
9468   return 0;
9469 }
9470 _ACEOF
9471 rm -f conftest.$ac_objext
9472 if { (ac_try="$ac_compile"
9473 case "(($ac_try" in
9474   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9475   *) ac_try_echo=$ac_try;;
9476 esac
9477 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9478 $as_echo "$ac_try_echo") >&5
9479   (eval "$ac_compile") 2>conftest.er1
9480   ac_status=$?
9481   grep -v '^ *+' conftest.er1 >conftest.err
9482   rm -f conftest.er1
9483   cat conftest.err >&5
9484   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9485   (exit $ac_status); } && {
9486          test -z "$ac_c_werror_flag" ||
9487          test ! -s conftest.err
9488        } && test -s conftest.$ac_objext; then
9489   ac_cv_header_stdc=yes
9490 else
9491   $as_echo "$as_me: failed program was:" >&5
9492 sed 's/^/| /' conftest.$ac_ext >&5
9493
9494         ac_cv_header_stdc=no
9495 fi
9496
9497 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9498
9499 if test $ac_cv_header_stdc = yes; then
9500   # SunOS 4.x string.h does not declare mem*, contrary to ANSI.
9501   cat >conftest.$ac_ext <<_ACEOF
9502 /* confdefs.h.  */
9503 _ACEOF
9504 cat confdefs.h >>conftest.$ac_ext
9505 cat >>conftest.$ac_ext <<_ACEOF
9506 /* end confdefs.h.  */
9507 #include <string.h>
9508
9509 _ACEOF
9510 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9511   $EGREP "memchr" >/dev/null 2>&1; then
9512   :
9513 else
9514   ac_cv_header_stdc=no
9515 fi
9516 rm -f conftest*
9517
9518 fi
9519
9520 if test $ac_cv_header_stdc = yes; then
9521   # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
9522   cat >conftest.$ac_ext <<_ACEOF
9523 /* confdefs.h.  */
9524 _ACEOF
9525 cat confdefs.h >>conftest.$ac_ext
9526 cat >>conftest.$ac_ext <<_ACEOF
9527 /* end confdefs.h.  */
9528 #include <stdlib.h>
9529
9530 _ACEOF
9531 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
9532   $EGREP "free" >/dev/null 2>&1; then
9533   :
9534 else
9535   ac_cv_header_stdc=no
9536 fi
9537 rm -f conftest*
9538
9539 fi
9540
9541 if test $ac_cv_header_stdc = yes; then
9542   # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi.
9543   if test "$cross_compiling" = yes; then
9544   :
9545 else
9546   cat >conftest.$ac_ext <<_ACEOF
9547 /* confdefs.h.  */
9548 _ACEOF
9549 cat confdefs.h >>conftest.$ac_ext
9550 cat >>conftest.$ac_ext <<_ACEOF
9551 /* end confdefs.h.  */
9552 #include <ctype.h>
9553 #include <stdlib.h>
9554 #if ((' ' & 0x0FF) == 0x020)
9555 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
9556 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c))
9557 #else
9558 # define ISLOWER(c) \
9559                    (('a' <= (c) && (c) <= 'i') \
9560                      || ('j' <= (c) && (c) <= 'r') \
9561                      || ('s' <= (c) && (c) <= 'z'))
9562 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c))
9563 #endif
9564
9565 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f)))
9566 int
9567 main ()
9568 {
9569   int i;
9570   for (i = 0; i < 256; i++)
9571     if (XOR (islower (i), ISLOWER (i))
9572         || toupper (i) != TOUPPER (i))
9573       return 2;
9574   return 0;
9575 }
9576 _ACEOF
9577 rm -f conftest$ac_exeext
9578 if { (ac_try="$ac_link"
9579 case "(($ac_try" in
9580   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9581   *) ac_try_echo=$ac_try;;
9582 esac
9583 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9584 $as_echo "$ac_try_echo") >&5
9585   (eval "$ac_link") 2>&5
9586   ac_status=$?
9587   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9588   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
9589   { (case "(($ac_try" in
9590   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9591   *) ac_try_echo=$ac_try;;
9592 esac
9593 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9594 $as_echo "$ac_try_echo") >&5
9595   (eval "$ac_try") 2>&5
9596   ac_status=$?
9597   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9598   (exit $ac_status); }; }; then
9599   :
9600 else
9601   $as_echo "$as_me: program exited with status $ac_status" >&5
9602 $as_echo "$as_me: failed program was:" >&5
9603 sed 's/^/| /' conftest.$ac_ext >&5
9604
9605 ( exit $ac_status )
9606 ac_cv_header_stdc=no
9607 fi
9608 rm -rf conftest.dSYM
9609 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
9610 fi
9611
9612
9613 fi
9614 fi
9615 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_stdc" >&5
9616 $as_echo "$ac_cv_header_stdc" >&6; }
9617 if test $ac_cv_header_stdc = yes; then
9618
9619 cat >>confdefs.h <<\_ACEOF
9620 #define STDC_HEADERS 1
9621 _ACEOF
9622
9623 fi
9624
9625 # On IRIX 5.3, sys/types and inttypes.h are conflicting.
9626
9627
9628
9629
9630
9631
9632
9633
9634
9635 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \
9636                   inttypes.h stdint.h unistd.h
9637 do
9638 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9639 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9640 $as_echo_n "checking for $ac_header... " >&6; }
9641 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9642   $as_echo_n "(cached) " >&6
9643 else
9644   cat >conftest.$ac_ext <<_ACEOF
9645 /* confdefs.h.  */
9646 _ACEOF
9647 cat confdefs.h >>conftest.$ac_ext
9648 cat >>conftest.$ac_ext <<_ACEOF
9649 /* end confdefs.h.  */
9650 $ac_includes_default
9651
9652 #include <$ac_header>
9653 _ACEOF
9654 rm -f conftest.$ac_objext
9655 if { (ac_try="$ac_compile"
9656 case "(($ac_try" in
9657   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9658   *) ac_try_echo=$ac_try;;
9659 esac
9660 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9661 $as_echo "$ac_try_echo") >&5
9662   (eval "$ac_compile") 2>conftest.er1
9663   ac_status=$?
9664   grep -v '^ *+' conftest.er1 >conftest.err
9665   rm -f conftest.er1
9666   cat conftest.err >&5
9667   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9668   (exit $ac_status); } && {
9669          test -z "$ac_c_werror_flag" ||
9670          test ! -s conftest.err
9671        } && test -s conftest.$ac_objext; then
9672   eval "$as_ac_Header=yes"
9673 else
9674   $as_echo "$as_me: failed program was:" >&5
9675 sed 's/^/| /' conftest.$ac_ext >&5
9676
9677         eval "$as_ac_Header=no"
9678 fi
9679
9680 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9681 fi
9682 ac_res=`eval 'as_val=${'$as_ac_Header'}
9683                  $as_echo "$as_val"'`
9684                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9685 $as_echo "$ac_res" >&6; }
9686 as_val=`eval 'as_val=${'$as_ac_Header'}
9687                  $as_echo "$as_val"'`
9688    if test "x$as_val" = x""yes; then
9689   cat >>confdefs.h <<_ACEOF
9690 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9691 _ACEOF
9692
9693 fi
9694
9695 done
9696
9697
9698
9699
9700
9701
9702
9703
9704
9705
9706
9707
9708
9709
9710
9711
9712
9713
9714
9715
9716
9717
9718
9719
9720
9721
9722
9723
9724
9725
9726
9727
9728 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
9729 do
9730 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9731 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9732   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9733 $as_echo_n "checking for $ac_header... " >&6; }
9734 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9735   $as_echo_n "(cached) " >&6
9736 fi
9737 ac_res=`eval 'as_val=${'$as_ac_Header'}
9738                  $as_echo "$as_val"'`
9739                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9740 $as_echo "$ac_res" >&6; }
9741 else
9742   # Is the header compilable?
9743 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
9744 $as_echo_n "checking $ac_header usability... " >&6; }
9745 cat >conftest.$ac_ext <<_ACEOF
9746 /* confdefs.h.  */
9747 _ACEOF
9748 cat confdefs.h >>conftest.$ac_ext
9749 cat >>conftest.$ac_ext <<_ACEOF
9750 /* end confdefs.h.  */
9751 $ac_includes_default
9752 #include <$ac_header>
9753 _ACEOF
9754 rm -f conftest.$ac_objext
9755 if { (ac_try="$ac_compile"
9756 case "(($ac_try" in
9757   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9758   *) ac_try_echo=$ac_try;;
9759 esac
9760 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9761 $as_echo "$ac_try_echo") >&5
9762   (eval "$ac_compile") 2>conftest.er1
9763   ac_status=$?
9764   grep -v '^ *+' conftest.er1 >conftest.err
9765   rm -f conftest.er1
9766   cat conftest.err >&5
9767   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9768   (exit $ac_status); } && {
9769          test -z "$ac_c_werror_flag" ||
9770          test ! -s conftest.err
9771        } && test -s conftest.$ac_objext; then
9772   ac_header_compiler=yes
9773 else
9774   $as_echo "$as_me: failed program was:" >&5
9775 sed 's/^/| /' conftest.$ac_ext >&5
9776
9777         ac_header_compiler=no
9778 fi
9779
9780 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9781 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
9782 $as_echo "$ac_header_compiler" >&6; }
9783
9784 # Is the header present?
9785 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
9786 $as_echo_n "checking $ac_header presence... " >&6; }
9787 cat >conftest.$ac_ext <<_ACEOF
9788 /* confdefs.h.  */
9789 _ACEOF
9790 cat confdefs.h >>conftest.$ac_ext
9791 cat >>conftest.$ac_ext <<_ACEOF
9792 /* end confdefs.h.  */
9793 #include <$ac_header>
9794 _ACEOF
9795 if { (ac_try="$ac_cpp conftest.$ac_ext"
9796 case "(($ac_try" in
9797   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9798   *) ac_try_echo=$ac_try;;
9799 esac
9800 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9801 $as_echo "$ac_try_echo") >&5
9802   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
9803   ac_status=$?
9804   grep -v '^ *+' conftest.er1 >conftest.err
9805   rm -f conftest.er1
9806   cat conftest.err >&5
9807   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9808   (exit $ac_status); } >/dev/null && {
9809          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
9810          test ! -s conftest.err
9811        }; then
9812   ac_header_preproc=yes
9813 else
9814   $as_echo "$as_me: failed program was:" >&5
9815 sed 's/^/| /' conftest.$ac_ext >&5
9816
9817   ac_header_preproc=no
9818 fi
9819
9820 rm -f conftest.err conftest.$ac_ext
9821 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
9822 $as_echo "$ac_header_preproc" >&6; }
9823
9824 # So?  What about this header?
9825 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
9826   yes:no: )
9827     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
9828 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
9829     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
9830 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
9831     ac_header_preproc=yes
9832     ;;
9833   no:yes:* )
9834     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
9835 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
9836     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
9837 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
9838     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
9839 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
9840     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
9841 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
9842     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
9843 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
9844     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
9845 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
9846     ( cat <<\_ASBOX
9847 ## ---------------------------------------- ##
9848 ## Report this to pgsql-bugs@postgresql.org ##
9849 ## ---------------------------------------- ##
9850 _ASBOX
9851      ) | sed "s/^/$as_me: WARNING:     /" >&2
9852     ;;
9853 esac
9854 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9855 $as_echo_n "checking for $ac_header... " >&6; }
9856 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9857   $as_echo_n "(cached) " >&6
9858 else
9859   eval "$as_ac_Header=\$ac_header_preproc"
9860 fi
9861 ac_res=`eval 'as_val=${'$as_ac_Header'}
9862                  $as_echo "$as_val"'`
9863                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9864 $as_echo "$ac_res" >&6; }
9865
9866 fi
9867 as_val=`eval 'as_val=${'$as_ac_Header'}
9868                  $as_echo "$as_val"'`
9869    if test "x$as_val" = x""yes; then
9870   cat >>confdefs.h <<_ACEOF
9871 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9872 _ACEOF
9873
9874 fi
9875
9876 done
9877
9878
9879 # On BSD, cpp test for net/if.h will fail unless sys/socket.h
9880 # is included first.
9881
9882 for ac_header in net/if.h
9883 do
9884 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9885 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9886 $as_echo_n "checking for $ac_header... " >&6; }
9887 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9888   $as_echo_n "(cached) " >&6
9889 else
9890   cat >conftest.$ac_ext <<_ACEOF
9891 /* confdefs.h.  */
9892 _ACEOF
9893 cat confdefs.h >>conftest.$ac_ext
9894 cat >>conftest.$ac_ext <<_ACEOF
9895 /* end confdefs.h.  */
9896 $ac_includes_default
9897 #ifdef HAVE_SYS_SOCKET_H
9898 #include <sys/socket.h>
9899 #endif
9900
9901
9902 #include <$ac_header>
9903 _ACEOF
9904 rm -f conftest.$ac_objext
9905 if { (ac_try="$ac_compile"
9906 case "(($ac_try" in
9907   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9908   *) ac_try_echo=$ac_try;;
9909 esac
9910 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9911 $as_echo "$ac_try_echo") >&5
9912   (eval "$ac_compile") 2>conftest.er1
9913   ac_status=$?
9914   grep -v '^ *+' conftest.er1 >conftest.err
9915   rm -f conftest.er1
9916   cat conftest.err >&5
9917   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9918   (exit $ac_status); } && {
9919          test -z "$ac_c_werror_flag" ||
9920          test ! -s conftest.err
9921        } && test -s conftest.$ac_objext; then
9922   eval "$as_ac_Header=yes"
9923 else
9924   $as_echo "$as_me: failed program was:" >&5
9925 sed 's/^/| /' conftest.$ac_ext >&5
9926
9927         eval "$as_ac_Header=no"
9928 fi
9929
9930 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
9931 fi
9932 ac_res=`eval 'as_val=${'$as_ac_Header'}
9933                  $as_echo "$as_val"'`
9934                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9935 $as_echo "$ac_res" >&6; }
9936 as_val=`eval 'as_val=${'$as_ac_Header'}
9937                  $as_echo "$as_val"'`
9938    if test "x$as_val" = x""yes; then
9939   cat >>confdefs.h <<_ACEOF
9940 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
9941 _ACEOF
9942
9943 fi
9944
9945 done
9946
9947
9948 # At least on IRIX, cpp test for netinet/tcp.h will fail unless
9949 # netinet/in.h is included first.
9950
9951 for ac_header in netinet/in.h
9952 do
9953 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
9954 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9955   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
9956 $as_echo_n "checking for $ac_header... " >&6; }
9957 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
9958   $as_echo_n "(cached) " >&6
9959 fi
9960 ac_res=`eval 'as_val=${'$as_ac_Header'}
9961                  $as_echo "$as_val"'`
9962                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
9963 $as_echo "$ac_res" >&6; }
9964 else
9965   # Is the header compilable?
9966 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
9967 $as_echo_n "checking $ac_header usability... " >&6; }
9968 cat >conftest.$ac_ext <<_ACEOF
9969 /* confdefs.h.  */
9970 _ACEOF
9971 cat confdefs.h >>conftest.$ac_ext
9972 cat >>conftest.$ac_ext <<_ACEOF
9973 /* end confdefs.h.  */
9974 $ac_includes_default
9975 #include <$ac_header>
9976 _ACEOF
9977 rm -f conftest.$ac_objext
9978 if { (ac_try="$ac_compile"
9979 case "(($ac_try" in
9980   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
9981   *) ac_try_echo=$ac_try;;
9982 esac
9983 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
9984 $as_echo "$ac_try_echo") >&5
9985   (eval "$ac_compile") 2>conftest.er1
9986   ac_status=$?
9987   grep -v '^ *+' conftest.er1 >conftest.err
9988   rm -f conftest.er1
9989   cat conftest.err >&5
9990   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
9991   (exit $ac_status); } && {
9992          test -z "$ac_c_werror_flag" ||
9993          test ! -s conftest.err
9994        } && test -s conftest.$ac_objext; then
9995   ac_header_compiler=yes
9996 else
9997   $as_echo "$as_me: failed program was:" >&5
9998 sed 's/^/| /' conftest.$ac_ext >&5
9999
10000         ac_header_compiler=no
10001 fi
10002
10003 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10004 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10005 $as_echo "$ac_header_compiler" >&6; }
10006
10007 # Is the header present?
10008 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10009 $as_echo_n "checking $ac_header presence... " >&6; }
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 #include <$ac_header>
10017 _ACEOF
10018 if { (ac_try="$ac_cpp conftest.$ac_ext"
10019 case "(($ac_try" in
10020   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10021   *) ac_try_echo=$ac_try;;
10022 esac
10023 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10024 $as_echo "$ac_try_echo") >&5
10025   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10026   ac_status=$?
10027   grep -v '^ *+' conftest.er1 >conftest.err
10028   rm -f conftest.er1
10029   cat conftest.err >&5
10030   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10031   (exit $ac_status); } >/dev/null && {
10032          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10033          test ! -s conftest.err
10034        }; then
10035   ac_header_preproc=yes
10036 else
10037   $as_echo "$as_me: failed program was:" >&5
10038 sed 's/^/| /' conftest.$ac_ext >&5
10039
10040   ac_header_preproc=no
10041 fi
10042
10043 rm -f conftest.err conftest.$ac_ext
10044 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10045 $as_echo "$ac_header_preproc" >&6; }
10046
10047 # So?  What about this header?
10048 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10049   yes:no: )
10050     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10051 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10052     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10053 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10054     ac_header_preproc=yes
10055     ;;
10056   no:yes:* )
10057     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10058 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10059     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10060 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10061     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10062 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10063     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10064 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10065     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10066 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10067     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10068 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10069     ( cat <<\_ASBOX
10070 ## ---------------------------------------- ##
10071 ## Report this to pgsql-bugs@postgresql.org ##
10072 ## ---------------------------------------- ##
10073 _ASBOX
10074      ) | sed "s/^/$as_me: WARNING:     /" >&2
10075     ;;
10076 esac
10077 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10078 $as_echo_n "checking for $ac_header... " >&6; }
10079 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10080   $as_echo_n "(cached) " >&6
10081 else
10082   eval "$as_ac_Header=\$ac_header_preproc"
10083 fi
10084 ac_res=`eval 'as_val=${'$as_ac_Header'}
10085                  $as_echo "$as_val"'`
10086                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10087 $as_echo "$ac_res" >&6; }
10088
10089 fi
10090 as_val=`eval 'as_val=${'$as_ac_Header'}
10091                  $as_echo "$as_val"'`
10092    if test "x$as_val" = x""yes; then
10093   cat >>confdefs.h <<_ACEOF
10094 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10095 _ACEOF
10096
10097 fi
10098
10099 done
10100
10101
10102 for ac_header in netinet/tcp.h
10103 do
10104 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10105 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10106 $as_echo_n "checking for $ac_header... " >&6; }
10107 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10108   $as_echo_n "(cached) " >&6
10109 else
10110   cat >conftest.$ac_ext <<_ACEOF
10111 /* confdefs.h.  */
10112 _ACEOF
10113 cat confdefs.h >>conftest.$ac_ext
10114 cat >>conftest.$ac_ext <<_ACEOF
10115 /* end confdefs.h.  */
10116 $ac_includes_default
10117 #ifdef HAVE_NETINET_IN_H
10118 #include <netinet/in.h>
10119 #endif
10120
10121
10122 #include <$ac_header>
10123 _ACEOF
10124 rm -f conftest.$ac_objext
10125 if { (ac_try="$ac_compile"
10126 case "(($ac_try" in
10127   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10128   *) ac_try_echo=$ac_try;;
10129 esac
10130 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10131 $as_echo "$ac_try_echo") >&5
10132   (eval "$ac_compile") 2>conftest.er1
10133   ac_status=$?
10134   grep -v '^ *+' conftest.er1 >conftest.err
10135   rm -f conftest.er1
10136   cat conftest.err >&5
10137   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10138   (exit $ac_status); } && {
10139          test -z "$ac_c_werror_flag" ||
10140          test ! -s conftest.err
10141        } && test -s conftest.$ac_objext; then
10142   eval "$as_ac_Header=yes"
10143 else
10144   $as_echo "$as_me: failed program was:" >&5
10145 sed 's/^/| /' conftest.$ac_ext >&5
10146
10147         eval "$as_ac_Header=no"
10148 fi
10149
10150 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10151 fi
10152 ac_res=`eval 'as_val=${'$as_ac_Header'}
10153                  $as_echo "$as_val"'`
10154                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10155 $as_echo "$ac_res" >&6; }
10156 as_val=`eval 'as_val=${'$as_ac_Header'}
10157                  $as_echo "$as_val"'`
10158    if test "x$as_val" = x""yes; then
10159   cat >>confdefs.h <<_ACEOF
10160 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10161 _ACEOF
10162
10163 fi
10164
10165 done
10166
10167
10168 if expr x"$pgac_cv_check_readline" : 'x-lreadline' >/dev/null ; then
10169
10170 for ac_header in readline/readline.h
10171 do
10172 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10173 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10174   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10175 $as_echo_n "checking for $ac_header... " >&6; }
10176 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10177   $as_echo_n "(cached) " >&6
10178 fi
10179 ac_res=`eval 'as_val=${'$as_ac_Header'}
10180                  $as_echo "$as_val"'`
10181                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10182 $as_echo "$ac_res" >&6; }
10183 else
10184   # Is the header compilable?
10185 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10186 $as_echo_n "checking $ac_header usability... " >&6; }
10187 cat >conftest.$ac_ext <<_ACEOF
10188 /* confdefs.h.  */
10189 _ACEOF
10190 cat confdefs.h >>conftest.$ac_ext
10191 cat >>conftest.$ac_ext <<_ACEOF
10192 /* end confdefs.h.  */
10193 $ac_includes_default
10194 #include <$ac_header>
10195 _ACEOF
10196 rm -f conftest.$ac_objext
10197 if { (ac_try="$ac_compile"
10198 case "(($ac_try" in
10199   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10200   *) ac_try_echo=$ac_try;;
10201 esac
10202 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10203 $as_echo "$ac_try_echo") >&5
10204   (eval "$ac_compile") 2>conftest.er1
10205   ac_status=$?
10206   grep -v '^ *+' conftest.er1 >conftest.err
10207   rm -f conftest.er1
10208   cat conftest.err >&5
10209   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10210   (exit $ac_status); } && {
10211          test -z "$ac_c_werror_flag" ||
10212          test ! -s conftest.err
10213        } && test -s conftest.$ac_objext; then
10214   ac_header_compiler=yes
10215 else
10216   $as_echo "$as_me: failed program was:" >&5
10217 sed 's/^/| /' conftest.$ac_ext >&5
10218
10219         ac_header_compiler=no
10220 fi
10221
10222 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10223 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10224 $as_echo "$ac_header_compiler" >&6; }
10225
10226 # Is the header present?
10227 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10228 $as_echo_n "checking $ac_header presence... " >&6; }
10229 cat >conftest.$ac_ext <<_ACEOF
10230 /* confdefs.h.  */
10231 _ACEOF
10232 cat confdefs.h >>conftest.$ac_ext
10233 cat >>conftest.$ac_ext <<_ACEOF
10234 /* end confdefs.h.  */
10235 #include <$ac_header>
10236 _ACEOF
10237 if { (ac_try="$ac_cpp conftest.$ac_ext"
10238 case "(($ac_try" in
10239   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10240   *) ac_try_echo=$ac_try;;
10241 esac
10242 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10243 $as_echo "$ac_try_echo") >&5
10244   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10245   ac_status=$?
10246   grep -v '^ *+' conftest.er1 >conftest.err
10247   rm -f conftest.er1
10248   cat conftest.err >&5
10249   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10250   (exit $ac_status); } >/dev/null && {
10251          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10252          test ! -s conftest.err
10253        }; then
10254   ac_header_preproc=yes
10255 else
10256   $as_echo "$as_me: failed program was:" >&5
10257 sed 's/^/| /' conftest.$ac_ext >&5
10258
10259   ac_header_preproc=no
10260 fi
10261
10262 rm -f conftest.err conftest.$ac_ext
10263 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10264 $as_echo "$ac_header_preproc" >&6; }
10265
10266 # So?  What about this header?
10267 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10268   yes:no: )
10269     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10270 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10271     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10272 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10273     ac_header_preproc=yes
10274     ;;
10275   no:yes:* )
10276     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10277 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10278     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10279 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10280     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10281 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10282     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10283 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10284     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10285 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10286     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10287 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10288     ( cat <<\_ASBOX
10289 ## ---------------------------------------- ##
10290 ## Report this to pgsql-bugs@postgresql.org ##
10291 ## ---------------------------------------- ##
10292 _ASBOX
10293      ) | sed "s/^/$as_me: WARNING:     /" >&2
10294     ;;
10295 esac
10296 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10297 $as_echo_n "checking for $ac_header... " >&6; }
10298 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10299   $as_echo_n "(cached) " >&6
10300 else
10301   eval "$as_ac_Header=\$ac_header_preproc"
10302 fi
10303 ac_res=`eval 'as_val=${'$as_ac_Header'}
10304                  $as_echo "$as_val"'`
10305                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10306 $as_echo "$ac_res" >&6; }
10307
10308 fi
10309 as_val=`eval 'as_val=${'$as_ac_Header'}
10310                  $as_echo "$as_val"'`
10311    if test "x$as_val" = x""yes; then
10312   cat >>confdefs.h <<_ACEOF
10313 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10314 _ACEOF
10315
10316 else
10317
10318 for ac_header in readline.h
10319 do
10320 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10321 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10322   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10323 $as_echo_n "checking for $ac_header... " >&6; }
10324 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10325   $as_echo_n "(cached) " >&6
10326 fi
10327 ac_res=`eval 'as_val=${'$as_ac_Header'}
10328                  $as_echo "$as_val"'`
10329                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10330 $as_echo "$ac_res" >&6; }
10331 else
10332   # Is the header compilable?
10333 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10334 $as_echo_n "checking $ac_header usability... " >&6; }
10335 cat >conftest.$ac_ext <<_ACEOF
10336 /* confdefs.h.  */
10337 _ACEOF
10338 cat confdefs.h >>conftest.$ac_ext
10339 cat >>conftest.$ac_ext <<_ACEOF
10340 /* end confdefs.h.  */
10341 $ac_includes_default
10342 #include <$ac_header>
10343 _ACEOF
10344 rm -f conftest.$ac_objext
10345 if { (ac_try="$ac_compile"
10346 case "(($ac_try" in
10347   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10348   *) ac_try_echo=$ac_try;;
10349 esac
10350 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10351 $as_echo "$ac_try_echo") >&5
10352   (eval "$ac_compile") 2>conftest.er1
10353   ac_status=$?
10354   grep -v '^ *+' conftest.er1 >conftest.err
10355   rm -f conftest.er1
10356   cat conftest.err >&5
10357   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10358   (exit $ac_status); } && {
10359          test -z "$ac_c_werror_flag" ||
10360          test ! -s conftest.err
10361        } && test -s conftest.$ac_objext; then
10362   ac_header_compiler=yes
10363 else
10364   $as_echo "$as_me: failed program was:" >&5
10365 sed 's/^/| /' conftest.$ac_ext >&5
10366
10367         ac_header_compiler=no
10368 fi
10369
10370 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10371 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10372 $as_echo "$ac_header_compiler" >&6; }
10373
10374 # Is the header present?
10375 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10376 $as_echo_n "checking $ac_header presence... " >&6; }
10377 cat >conftest.$ac_ext <<_ACEOF
10378 /* confdefs.h.  */
10379 _ACEOF
10380 cat confdefs.h >>conftest.$ac_ext
10381 cat >>conftest.$ac_ext <<_ACEOF
10382 /* end confdefs.h.  */
10383 #include <$ac_header>
10384 _ACEOF
10385 if { (ac_try="$ac_cpp conftest.$ac_ext"
10386 case "(($ac_try" in
10387   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10388   *) ac_try_echo=$ac_try;;
10389 esac
10390 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10391 $as_echo "$ac_try_echo") >&5
10392   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10393   ac_status=$?
10394   grep -v '^ *+' conftest.er1 >conftest.err
10395   rm -f conftest.er1
10396   cat conftest.err >&5
10397   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10398   (exit $ac_status); } >/dev/null && {
10399          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10400          test ! -s conftest.err
10401        }; then
10402   ac_header_preproc=yes
10403 else
10404   $as_echo "$as_me: failed program was:" >&5
10405 sed 's/^/| /' conftest.$ac_ext >&5
10406
10407   ac_header_preproc=no
10408 fi
10409
10410 rm -f conftest.err conftest.$ac_ext
10411 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10412 $as_echo "$ac_header_preproc" >&6; }
10413
10414 # So?  What about this header?
10415 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10416   yes:no: )
10417     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10418 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10419     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10420 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10421     ac_header_preproc=yes
10422     ;;
10423   no:yes:* )
10424     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10425 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10426     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10427 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10428     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10429 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10430     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10431 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10432     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10433 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10434     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10435 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10436     ( cat <<\_ASBOX
10437 ## ---------------------------------------- ##
10438 ## Report this to pgsql-bugs@postgresql.org ##
10439 ## ---------------------------------------- ##
10440 _ASBOX
10441      ) | sed "s/^/$as_me: WARNING:     /" >&2
10442     ;;
10443 esac
10444 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10445 $as_echo_n "checking for $ac_header... " >&6; }
10446 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10447   $as_echo_n "(cached) " >&6
10448 else
10449   eval "$as_ac_Header=\$ac_header_preproc"
10450 fi
10451 ac_res=`eval 'as_val=${'$as_ac_Header'}
10452                  $as_echo "$as_val"'`
10453                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10454 $as_echo "$ac_res" >&6; }
10455
10456 fi
10457 as_val=`eval 'as_val=${'$as_ac_Header'}
10458                  $as_echo "$as_val"'`
10459    if test "x$as_val" = x""yes; then
10460   cat >>confdefs.h <<_ACEOF
10461 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10462 _ACEOF
10463
10464 else
10465   { { $as_echo "$as_me:$LINENO: error: readline header not found
10466 If you have readline already installed, see config.log for details on the
10467 failure.  It is possible the compiler isn't looking in the proper directory.
10468 Use --without-readline to disable readline support." >&5
10469 $as_echo "$as_me: error: readline header not found
10470 If you have readline already installed, see config.log for details on the
10471 failure.  It is possible the compiler isn't looking in the proper directory.
10472 Use --without-readline to disable readline support." >&2;}
10473    { (exit 1); exit 1; }; }
10474 fi
10475
10476 done
10477
10478 fi
10479
10480 done
10481
10482
10483 for ac_header in readline/history.h
10484 do
10485 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10486 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10487   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10488 $as_echo_n "checking for $ac_header... " >&6; }
10489 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10490   $as_echo_n "(cached) " >&6
10491 fi
10492 ac_res=`eval 'as_val=${'$as_ac_Header'}
10493                  $as_echo "$as_val"'`
10494                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10495 $as_echo "$ac_res" >&6; }
10496 else
10497   # Is the header compilable?
10498 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10499 $as_echo_n "checking $ac_header usability... " >&6; }
10500 cat >conftest.$ac_ext <<_ACEOF
10501 /* confdefs.h.  */
10502 _ACEOF
10503 cat confdefs.h >>conftest.$ac_ext
10504 cat >>conftest.$ac_ext <<_ACEOF
10505 /* end confdefs.h.  */
10506 $ac_includes_default
10507 #include <$ac_header>
10508 _ACEOF
10509 rm -f conftest.$ac_objext
10510 if { (ac_try="$ac_compile"
10511 case "(($ac_try" in
10512   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10513   *) ac_try_echo=$ac_try;;
10514 esac
10515 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10516 $as_echo "$ac_try_echo") >&5
10517   (eval "$ac_compile") 2>conftest.er1
10518   ac_status=$?
10519   grep -v '^ *+' conftest.er1 >conftest.err
10520   rm -f conftest.er1
10521   cat conftest.err >&5
10522   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10523   (exit $ac_status); } && {
10524          test -z "$ac_c_werror_flag" ||
10525          test ! -s conftest.err
10526        } && test -s conftest.$ac_objext; then
10527   ac_header_compiler=yes
10528 else
10529   $as_echo "$as_me: failed program was:" >&5
10530 sed 's/^/| /' conftest.$ac_ext >&5
10531
10532         ac_header_compiler=no
10533 fi
10534
10535 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10536 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10537 $as_echo "$ac_header_compiler" >&6; }
10538
10539 # Is the header present?
10540 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10541 $as_echo_n "checking $ac_header presence... " >&6; }
10542 cat >conftest.$ac_ext <<_ACEOF
10543 /* confdefs.h.  */
10544 _ACEOF
10545 cat confdefs.h >>conftest.$ac_ext
10546 cat >>conftest.$ac_ext <<_ACEOF
10547 /* end confdefs.h.  */
10548 #include <$ac_header>
10549 _ACEOF
10550 if { (ac_try="$ac_cpp conftest.$ac_ext"
10551 case "(($ac_try" in
10552   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10553   *) ac_try_echo=$ac_try;;
10554 esac
10555 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10556 $as_echo "$ac_try_echo") >&5
10557   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10558   ac_status=$?
10559   grep -v '^ *+' conftest.er1 >conftest.err
10560   rm -f conftest.er1
10561   cat conftest.err >&5
10562   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10563   (exit $ac_status); } >/dev/null && {
10564          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10565          test ! -s conftest.err
10566        }; then
10567   ac_header_preproc=yes
10568 else
10569   $as_echo "$as_me: failed program was:" >&5
10570 sed 's/^/| /' conftest.$ac_ext >&5
10571
10572   ac_header_preproc=no
10573 fi
10574
10575 rm -f conftest.err conftest.$ac_ext
10576 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10577 $as_echo "$ac_header_preproc" >&6; }
10578
10579 # So?  What about this header?
10580 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10581   yes:no: )
10582     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10583 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10584     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10585 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10586     ac_header_preproc=yes
10587     ;;
10588   no:yes:* )
10589     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10590 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10591     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10592 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10593     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10594 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10595     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10596 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10597     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10598 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10599     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10600 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10601     ( cat <<\_ASBOX
10602 ## ---------------------------------------- ##
10603 ## Report this to pgsql-bugs@postgresql.org ##
10604 ## ---------------------------------------- ##
10605 _ASBOX
10606      ) | sed "s/^/$as_me: WARNING:     /" >&2
10607     ;;
10608 esac
10609 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10610 $as_echo_n "checking for $ac_header... " >&6; }
10611 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10612   $as_echo_n "(cached) " >&6
10613 else
10614   eval "$as_ac_Header=\$ac_header_preproc"
10615 fi
10616 ac_res=`eval 'as_val=${'$as_ac_Header'}
10617                  $as_echo "$as_val"'`
10618                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10619 $as_echo "$ac_res" >&6; }
10620
10621 fi
10622 as_val=`eval 'as_val=${'$as_ac_Header'}
10623                  $as_echo "$as_val"'`
10624    if test "x$as_val" = x""yes; then
10625   cat >>confdefs.h <<_ACEOF
10626 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10627 _ACEOF
10628
10629 else
10630
10631 for ac_header in history.h
10632 do
10633 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10634 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10635   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10636 $as_echo_n "checking for $ac_header... " >&6; }
10637 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10638   $as_echo_n "(cached) " >&6
10639 fi
10640 ac_res=`eval 'as_val=${'$as_ac_Header'}
10641                  $as_echo "$as_val"'`
10642                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10643 $as_echo "$ac_res" >&6; }
10644 else
10645   # Is the header compilable?
10646 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10647 $as_echo_n "checking $ac_header usability... " >&6; }
10648 cat >conftest.$ac_ext <<_ACEOF
10649 /* confdefs.h.  */
10650 _ACEOF
10651 cat confdefs.h >>conftest.$ac_ext
10652 cat >>conftest.$ac_ext <<_ACEOF
10653 /* end confdefs.h.  */
10654 $ac_includes_default
10655 #include <$ac_header>
10656 _ACEOF
10657 rm -f conftest.$ac_objext
10658 if { (ac_try="$ac_compile"
10659 case "(($ac_try" in
10660   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10661   *) ac_try_echo=$ac_try;;
10662 esac
10663 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10664 $as_echo "$ac_try_echo") >&5
10665   (eval "$ac_compile") 2>conftest.er1
10666   ac_status=$?
10667   grep -v '^ *+' conftest.er1 >conftest.err
10668   rm -f conftest.er1
10669   cat conftest.err >&5
10670   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10671   (exit $ac_status); } && {
10672          test -z "$ac_c_werror_flag" ||
10673          test ! -s conftest.err
10674        } && test -s conftest.$ac_objext; then
10675   ac_header_compiler=yes
10676 else
10677   $as_echo "$as_me: failed program was:" >&5
10678 sed 's/^/| /' conftest.$ac_ext >&5
10679
10680         ac_header_compiler=no
10681 fi
10682
10683 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10684 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10685 $as_echo "$ac_header_compiler" >&6; }
10686
10687 # Is the header present?
10688 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10689 $as_echo_n "checking $ac_header presence... " >&6; }
10690 cat >conftest.$ac_ext <<_ACEOF
10691 /* confdefs.h.  */
10692 _ACEOF
10693 cat confdefs.h >>conftest.$ac_ext
10694 cat >>conftest.$ac_ext <<_ACEOF
10695 /* end confdefs.h.  */
10696 #include <$ac_header>
10697 _ACEOF
10698 if { (ac_try="$ac_cpp conftest.$ac_ext"
10699 case "(($ac_try" in
10700   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10701   *) ac_try_echo=$ac_try;;
10702 esac
10703 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10704 $as_echo "$ac_try_echo") >&5
10705   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10706   ac_status=$?
10707   grep -v '^ *+' conftest.er1 >conftest.err
10708   rm -f conftest.er1
10709   cat conftest.err >&5
10710   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10711   (exit $ac_status); } >/dev/null && {
10712          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10713          test ! -s conftest.err
10714        }; then
10715   ac_header_preproc=yes
10716 else
10717   $as_echo "$as_me: failed program was:" >&5
10718 sed 's/^/| /' conftest.$ac_ext >&5
10719
10720   ac_header_preproc=no
10721 fi
10722
10723 rm -f conftest.err conftest.$ac_ext
10724 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10725 $as_echo "$ac_header_preproc" >&6; }
10726
10727 # So?  What about this header?
10728 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10729   yes:no: )
10730     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10731 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10732     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10733 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10734     ac_header_preproc=yes
10735     ;;
10736   no:yes:* )
10737     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10738 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10739     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10740 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10741     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10742 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10743     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10744 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10745     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10746 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10747     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10748 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10749     ( cat <<\_ASBOX
10750 ## ---------------------------------------- ##
10751 ## Report this to pgsql-bugs@postgresql.org ##
10752 ## ---------------------------------------- ##
10753 _ASBOX
10754      ) | sed "s/^/$as_me: WARNING:     /" >&2
10755     ;;
10756 esac
10757 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10758 $as_echo_n "checking for $ac_header... " >&6; }
10759 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10760   $as_echo_n "(cached) " >&6
10761 else
10762   eval "$as_ac_Header=\$ac_header_preproc"
10763 fi
10764 ac_res=`eval 'as_val=${'$as_ac_Header'}
10765                  $as_echo "$as_val"'`
10766                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10767 $as_echo "$ac_res" >&6; }
10768
10769 fi
10770 as_val=`eval 'as_val=${'$as_ac_Header'}
10771                  $as_echo "$as_val"'`
10772    if test "x$as_val" = x""yes; then
10773   cat >>confdefs.h <<_ACEOF
10774 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10775 _ACEOF
10776
10777 else
10778   { { $as_echo "$as_me:$LINENO: error: history header not found
10779 If you have readline already installed, see config.log for details on the
10780 failure.  It is possible the compiler isn't looking in the proper directory.
10781 Use --without-readline to disable readline support." >&5
10782 $as_echo "$as_me: error: history header not found
10783 If you have readline already installed, see config.log for details on the
10784 failure.  It is possible the compiler isn't looking in the proper directory.
10785 Use --without-readline to disable readline support." >&2;}
10786    { (exit 1); exit 1; }; }
10787 fi
10788
10789 done
10790
10791 fi
10792
10793 done
10794
10795 fi
10796
10797 if expr x"$pgac_cv_check_readline" : 'x-ledit' >/dev/null ; then
10798 # Some installations of libedit usurp /usr/include/readline/, which seems
10799 # bad practice, since in combined installations readline will have its headers
10800 # there.  We might have to resort to AC_EGREP checks to make sure we found
10801 # the proper header...
10802
10803 for ac_header in editline/readline.h
10804 do
10805 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10806 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10807   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10808 $as_echo_n "checking for $ac_header... " >&6; }
10809 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10810   $as_echo_n "(cached) " >&6
10811 fi
10812 ac_res=`eval 'as_val=${'$as_ac_Header'}
10813                  $as_echo "$as_val"'`
10814                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10815 $as_echo "$ac_res" >&6; }
10816 else
10817   # Is the header compilable?
10818 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10819 $as_echo_n "checking $ac_header usability... " >&6; }
10820 cat >conftest.$ac_ext <<_ACEOF
10821 /* confdefs.h.  */
10822 _ACEOF
10823 cat confdefs.h >>conftest.$ac_ext
10824 cat >>conftest.$ac_ext <<_ACEOF
10825 /* end confdefs.h.  */
10826 $ac_includes_default
10827 #include <$ac_header>
10828 _ACEOF
10829 rm -f conftest.$ac_objext
10830 if { (ac_try="$ac_compile"
10831 case "(($ac_try" in
10832   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10833   *) ac_try_echo=$ac_try;;
10834 esac
10835 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10836 $as_echo "$ac_try_echo") >&5
10837   (eval "$ac_compile") 2>conftest.er1
10838   ac_status=$?
10839   grep -v '^ *+' conftest.er1 >conftest.err
10840   rm -f conftest.er1
10841   cat conftest.err >&5
10842   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10843   (exit $ac_status); } && {
10844          test -z "$ac_c_werror_flag" ||
10845          test ! -s conftest.err
10846        } && test -s conftest.$ac_objext; then
10847   ac_header_compiler=yes
10848 else
10849   $as_echo "$as_me: failed program was:" >&5
10850 sed 's/^/| /' conftest.$ac_ext >&5
10851
10852         ac_header_compiler=no
10853 fi
10854
10855 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
10856 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10857 $as_echo "$ac_header_compiler" >&6; }
10858
10859 # Is the header present?
10860 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
10861 $as_echo_n "checking $ac_header presence... " >&6; }
10862 cat >conftest.$ac_ext <<_ACEOF
10863 /* confdefs.h.  */
10864 _ACEOF
10865 cat confdefs.h >>conftest.$ac_ext
10866 cat >>conftest.$ac_ext <<_ACEOF
10867 /* end confdefs.h.  */
10868 #include <$ac_header>
10869 _ACEOF
10870 if { (ac_try="$ac_cpp conftest.$ac_ext"
10871 case "(($ac_try" in
10872   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10873   *) ac_try_echo=$ac_try;;
10874 esac
10875 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10876 $as_echo "$ac_try_echo") >&5
10877   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
10878   ac_status=$?
10879   grep -v '^ *+' conftest.er1 >conftest.err
10880   rm -f conftest.er1
10881   cat conftest.err >&5
10882   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10883   (exit $ac_status); } >/dev/null && {
10884          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
10885          test ! -s conftest.err
10886        }; then
10887   ac_header_preproc=yes
10888 else
10889   $as_echo "$as_me: failed program was:" >&5
10890 sed 's/^/| /' conftest.$ac_ext >&5
10891
10892   ac_header_preproc=no
10893 fi
10894
10895 rm -f conftest.err conftest.$ac_ext
10896 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10897 $as_echo "$ac_header_preproc" >&6; }
10898
10899 # So?  What about this header?
10900 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
10901   yes:no: )
10902     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10903 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10904     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10905 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10906     ac_header_preproc=yes
10907     ;;
10908   no:yes:* )
10909     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10910 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10911     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
10912 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
10913     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10914 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10915     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
10916 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
10917     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10918 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10919     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10920 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10921     ( cat <<\_ASBOX
10922 ## ---------------------------------------- ##
10923 ## Report this to pgsql-bugs@postgresql.org ##
10924 ## ---------------------------------------- ##
10925 _ASBOX
10926      ) | sed "s/^/$as_me: WARNING:     /" >&2
10927     ;;
10928 esac
10929 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10930 $as_echo_n "checking for $ac_header... " >&6; }
10931 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10932   $as_echo_n "(cached) " >&6
10933 else
10934   eval "$as_ac_Header=\$ac_header_preproc"
10935 fi
10936 ac_res=`eval 'as_val=${'$as_ac_Header'}
10937                  $as_echo "$as_val"'`
10938                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10939 $as_echo "$ac_res" >&6; }
10940
10941 fi
10942 as_val=`eval 'as_val=${'$as_ac_Header'}
10943                  $as_echo "$as_val"'`
10944    if test "x$as_val" = x""yes; then
10945   cat >>confdefs.h <<_ACEOF
10946 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
10947 _ACEOF
10948
10949 else
10950
10951 for ac_header in readline.h
10952 do
10953 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
10954 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10955   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
10956 $as_echo_n "checking for $ac_header... " >&6; }
10957 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
10958   $as_echo_n "(cached) " >&6
10959 fi
10960 ac_res=`eval 'as_val=${'$as_ac_Header'}
10961                  $as_echo "$as_val"'`
10962                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
10963 $as_echo "$ac_res" >&6; }
10964 else
10965   # Is the header compilable?
10966 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
10967 $as_echo_n "checking $ac_header usability... " >&6; }
10968 cat >conftest.$ac_ext <<_ACEOF
10969 /* confdefs.h.  */
10970 _ACEOF
10971 cat confdefs.h >>conftest.$ac_ext
10972 cat >>conftest.$ac_ext <<_ACEOF
10973 /* end confdefs.h.  */
10974 $ac_includes_default
10975 #include <$ac_header>
10976 _ACEOF
10977 rm -f conftest.$ac_objext
10978 if { (ac_try="$ac_compile"
10979 case "(($ac_try" in
10980   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
10981   *) ac_try_echo=$ac_try;;
10982 esac
10983 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
10984 $as_echo "$ac_try_echo") >&5
10985   (eval "$ac_compile") 2>conftest.er1
10986   ac_status=$?
10987   grep -v '^ *+' conftest.er1 >conftest.err
10988   rm -f conftest.er1
10989   cat conftest.err >&5
10990   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
10991   (exit $ac_status); } && {
10992          test -z "$ac_c_werror_flag" ||
10993          test ! -s conftest.err
10994        } && test -s conftest.$ac_objext; then
10995   ac_header_compiler=yes
10996 else
10997   $as_echo "$as_me: failed program was:" >&5
10998 sed 's/^/| /' conftest.$ac_ext >&5
10999
11000         ac_header_compiler=no
11001 fi
11002
11003 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11004 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11005 $as_echo "$ac_header_compiler" >&6; }
11006
11007 # Is the header present?
11008 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11009 $as_echo_n "checking $ac_header presence... " >&6; }
11010 cat >conftest.$ac_ext <<_ACEOF
11011 /* confdefs.h.  */
11012 _ACEOF
11013 cat confdefs.h >>conftest.$ac_ext
11014 cat >>conftest.$ac_ext <<_ACEOF
11015 /* end confdefs.h.  */
11016 #include <$ac_header>
11017 _ACEOF
11018 if { (ac_try="$ac_cpp conftest.$ac_ext"
11019 case "(($ac_try" in
11020   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11021   *) ac_try_echo=$ac_try;;
11022 esac
11023 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11024 $as_echo "$ac_try_echo") >&5
11025   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11026   ac_status=$?
11027   grep -v '^ *+' conftest.er1 >conftest.err
11028   rm -f conftest.er1
11029   cat conftest.err >&5
11030   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11031   (exit $ac_status); } >/dev/null && {
11032          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11033          test ! -s conftest.err
11034        }; then
11035   ac_header_preproc=yes
11036 else
11037   $as_echo "$as_me: failed program was:" >&5
11038 sed 's/^/| /' conftest.$ac_ext >&5
11039
11040   ac_header_preproc=no
11041 fi
11042
11043 rm -f conftest.err conftest.$ac_ext
11044 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11045 $as_echo "$ac_header_preproc" >&6; }
11046
11047 # So?  What about this header?
11048 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11049   yes:no: )
11050     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11051 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11052     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11053 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11054     ac_header_preproc=yes
11055     ;;
11056   no:yes:* )
11057     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11058 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11059     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11060 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11061     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11062 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11063     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11064 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11065     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11066 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11067     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11068 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11069     ( cat <<\_ASBOX
11070 ## ---------------------------------------- ##
11071 ## Report this to pgsql-bugs@postgresql.org ##
11072 ## ---------------------------------------- ##
11073 _ASBOX
11074      ) | sed "s/^/$as_me: WARNING:     /" >&2
11075     ;;
11076 esac
11077 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11078 $as_echo_n "checking for $ac_header... " >&6; }
11079 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11080   $as_echo_n "(cached) " >&6
11081 else
11082   eval "$as_ac_Header=\$ac_header_preproc"
11083 fi
11084 ac_res=`eval 'as_val=${'$as_ac_Header'}
11085                  $as_echo "$as_val"'`
11086                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11087 $as_echo "$ac_res" >&6; }
11088
11089 fi
11090 as_val=`eval 'as_val=${'$as_ac_Header'}
11091                  $as_echo "$as_val"'`
11092    if test "x$as_val" = x""yes; then
11093   cat >>confdefs.h <<_ACEOF
11094 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11095 _ACEOF
11096
11097 else
11098
11099 for ac_header in readline/readline.h
11100 do
11101 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11102 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11103   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11104 $as_echo_n "checking for $ac_header... " >&6; }
11105 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11106   $as_echo_n "(cached) " >&6
11107 fi
11108 ac_res=`eval 'as_val=${'$as_ac_Header'}
11109                  $as_echo "$as_val"'`
11110                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11111 $as_echo "$ac_res" >&6; }
11112 else
11113   # Is the header compilable?
11114 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11115 $as_echo_n "checking $ac_header usability... " >&6; }
11116 cat >conftest.$ac_ext <<_ACEOF
11117 /* confdefs.h.  */
11118 _ACEOF
11119 cat confdefs.h >>conftest.$ac_ext
11120 cat >>conftest.$ac_ext <<_ACEOF
11121 /* end confdefs.h.  */
11122 $ac_includes_default
11123 #include <$ac_header>
11124 _ACEOF
11125 rm -f conftest.$ac_objext
11126 if { (ac_try="$ac_compile"
11127 case "(($ac_try" in
11128   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11129   *) ac_try_echo=$ac_try;;
11130 esac
11131 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11132 $as_echo "$ac_try_echo") >&5
11133   (eval "$ac_compile") 2>conftest.er1
11134   ac_status=$?
11135   grep -v '^ *+' conftest.er1 >conftest.err
11136   rm -f conftest.er1
11137   cat conftest.err >&5
11138   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11139   (exit $ac_status); } && {
11140          test -z "$ac_c_werror_flag" ||
11141          test ! -s conftest.err
11142        } && test -s conftest.$ac_objext; then
11143   ac_header_compiler=yes
11144 else
11145   $as_echo "$as_me: failed program was:" >&5
11146 sed 's/^/| /' conftest.$ac_ext >&5
11147
11148         ac_header_compiler=no
11149 fi
11150
11151 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11152 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11153 $as_echo "$ac_header_compiler" >&6; }
11154
11155 # Is the header present?
11156 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11157 $as_echo_n "checking $ac_header presence... " >&6; }
11158 cat >conftest.$ac_ext <<_ACEOF
11159 /* confdefs.h.  */
11160 _ACEOF
11161 cat confdefs.h >>conftest.$ac_ext
11162 cat >>conftest.$ac_ext <<_ACEOF
11163 /* end confdefs.h.  */
11164 #include <$ac_header>
11165 _ACEOF
11166 if { (ac_try="$ac_cpp conftest.$ac_ext"
11167 case "(($ac_try" in
11168   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11169   *) ac_try_echo=$ac_try;;
11170 esac
11171 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11172 $as_echo "$ac_try_echo") >&5
11173   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11174   ac_status=$?
11175   grep -v '^ *+' conftest.er1 >conftest.err
11176   rm -f conftest.er1
11177   cat conftest.err >&5
11178   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11179   (exit $ac_status); } >/dev/null && {
11180          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11181          test ! -s conftest.err
11182        }; then
11183   ac_header_preproc=yes
11184 else
11185   $as_echo "$as_me: failed program was:" >&5
11186 sed 's/^/| /' conftest.$ac_ext >&5
11187
11188   ac_header_preproc=no
11189 fi
11190
11191 rm -f conftest.err conftest.$ac_ext
11192 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11193 $as_echo "$ac_header_preproc" >&6; }
11194
11195 # So?  What about this header?
11196 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11197   yes:no: )
11198     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11199 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11200     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11201 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11202     ac_header_preproc=yes
11203     ;;
11204   no:yes:* )
11205     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11206 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11207     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11208 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11209     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11210 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11211     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11212 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11213     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11214 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11215     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11216 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11217     ( cat <<\_ASBOX
11218 ## ---------------------------------------- ##
11219 ## Report this to pgsql-bugs@postgresql.org ##
11220 ## ---------------------------------------- ##
11221 _ASBOX
11222      ) | sed "s/^/$as_me: WARNING:     /" >&2
11223     ;;
11224 esac
11225 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11226 $as_echo_n "checking for $ac_header... " >&6; }
11227 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11228   $as_echo_n "(cached) " >&6
11229 else
11230   eval "$as_ac_Header=\$ac_header_preproc"
11231 fi
11232 ac_res=`eval 'as_val=${'$as_ac_Header'}
11233                  $as_echo "$as_val"'`
11234                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11235 $as_echo "$ac_res" >&6; }
11236
11237 fi
11238 as_val=`eval 'as_val=${'$as_ac_Header'}
11239                  $as_echo "$as_val"'`
11240    if test "x$as_val" = x""yes; then
11241   cat >>confdefs.h <<_ACEOF
11242 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11243 _ACEOF
11244
11245 else
11246   { { $as_echo "$as_me:$LINENO: error: readline header not found
11247 If you have libedit already installed, see config.log for details on the
11248 failure.  It is possible the compiler isn't looking in the proper directory.
11249 Use --without-readline to disable libedit support." >&5
11250 $as_echo "$as_me: error: readline header not found
11251 If you have libedit already installed, see config.log for details on the
11252 failure.  It is possible the compiler isn't looking in the proper directory.
11253 Use --without-readline to disable libedit support." >&2;}
11254    { (exit 1); exit 1; }; }
11255 fi
11256
11257 done
11258
11259 fi
11260
11261 done
11262
11263 fi
11264
11265 done
11266
11267 # Note: in a libedit installation, history.h is sometimes a dummy, and may
11268 # not be there at all.  Hence, don't complain if not found.  We must check
11269 # though, since in yet other versions it is an independent header.
11270
11271 for ac_header in editline/history.h
11272 do
11273 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11274 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11275   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11276 $as_echo_n "checking for $ac_header... " >&6; }
11277 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11278   $as_echo_n "(cached) " >&6
11279 fi
11280 ac_res=`eval 'as_val=${'$as_ac_Header'}
11281                  $as_echo "$as_val"'`
11282                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11283 $as_echo "$ac_res" >&6; }
11284 else
11285   # Is the header compilable?
11286 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11287 $as_echo_n "checking $ac_header usability... " >&6; }
11288 cat >conftest.$ac_ext <<_ACEOF
11289 /* confdefs.h.  */
11290 _ACEOF
11291 cat confdefs.h >>conftest.$ac_ext
11292 cat >>conftest.$ac_ext <<_ACEOF
11293 /* end confdefs.h.  */
11294 $ac_includes_default
11295 #include <$ac_header>
11296 _ACEOF
11297 rm -f conftest.$ac_objext
11298 if { (ac_try="$ac_compile"
11299 case "(($ac_try" in
11300   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11301   *) ac_try_echo=$ac_try;;
11302 esac
11303 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11304 $as_echo "$ac_try_echo") >&5
11305   (eval "$ac_compile") 2>conftest.er1
11306   ac_status=$?
11307   grep -v '^ *+' conftest.er1 >conftest.err
11308   rm -f conftest.er1
11309   cat conftest.err >&5
11310   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11311   (exit $ac_status); } && {
11312          test -z "$ac_c_werror_flag" ||
11313          test ! -s conftest.err
11314        } && test -s conftest.$ac_objext; then
11315   ac_header_compiler=yes
11316 else
11317   $as_echo "$as_me: failed program was:" >&5
11318 sed 's/^/| /' conftest.$ac_ext >&5
11319
11320         ac_header_compiler=no
11321 fi
11322
11323 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11324 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11325 $as_echo "$ac_header_compiler" >&6; }
11326
11327 # Is the header present?
11328 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11329 $as_echo_n "checking $ac_header presence... " >&6; }
11330 cat >conftest.$ac_ext <<_ACEOF
11331 /* confdefs.h.  */
11332 _ACEOF
11333 cat confdefs.h >>conftest.$ac_ext
11334 cat >>conftest.$ac_ext <<_ACEOF
11335 /* end confdefs.h.  */
11336 #include <$ac_header>
11337 _ACEOF
11338 if { (ac_try="$ac_cpp conftest.$ac_ext"
11339 case "(($ac_try" in
11340   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11341   *) ac_try_echo=$ac_try;;
11342 esac
11343 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11344 $as_echo "$ac_try_echo") >&5
11345   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11346   ac_status=$?
11347   grep -v '^ *+' conftest.er1 >conftest.err
11348   rm -f conftest.er1
11349   cat conftest.err >&5
11350   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11351   (exit $ac_status); } >/dev/null && {
11352          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11353          test ! -s conftest.err
11354        }; then
11355   ac_header_preproc=yes
11356 else
11357   $as_echo "$as_me: failed program was:" >&5
11358 sed 's/^/| /' conftest.$ac_ext >&5
11359
11360   ac_header_preproc=no
11361 fi
11362
11363 rm -f conftest.err conftest.$ac_ext
11364 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11365 $as_echo "$ac_header_preproc" >&6; }
11366
11367 # So?  What about this header?
11368 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11369   yes:no: )
11370     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11371 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11372     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11373 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11374     ac_header_preproc=yes
11375     ;;
11376   no:yes:* )
11377     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11378 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11379     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11380 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11381     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11382 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11383     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11384 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11385     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11386 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11387     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11388 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11389     ( cat <<\_ASBOX
11390 ## ---------------------------------------- ##
11391 ## Report this to pgsql-bugs@postgresql.org ##
11392 ## ---------------------------------------- ##
11393 _ASBOX
11394      ) | sed "s/^/$as_me: WARNING:     /" >&2
11395     ;;
11396 esac
11397 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11398 $as_echo_n "checking for $ac_header... " >&6; }
11399 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11400   $as_echo_n "(cached) " >&6
11401 else
11402   eval "$as_ac_Header=\$ac_header_preproc"
11403 fi
11404 ac_res=`eval 'as_val=${'$as_ac_Header'}
11405                  $as_echo "$as_val"'`
11406                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11407 $as_echo "$ac_res" >&6; }
11408
11409 fi
11410 as_val=`eval 'as_val=${'$as_ac_Header'}
11411                  $as_echo "$as_val"'`
11412    if test "x$as_val" = x""yes; then
11413   cat >>confdefs.h <<_ACEOF
11414 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11415 _ACEOF
11416
11417 else
11418
11419 for ac_header in history.h
11420 do
11421 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11422 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11423   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11424 $as_echo_n "checking for $ac_header... " >&6; }
11425 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11426   $as_echo_n "(cached) " >&6
11427 fi
11428 ac_res=`eval 'as_val=${'$as_ac_Header'}
11429                  $as_echo "$as_val"'`
11430                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11431 $as_echo "$ac_res" >&6; }
11432 else
11433   # Is the header compilable?
11434 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11435 $as_echo_n "checking $ac_header usability... " >&6; }
11436 cat >conftest.$ac_ext <<_ACEOF
11437 /* confdefs.h.  */
11438 _ACEOF
11439 cat confdefs.h >>conftest.$ac_ext
11440 cat >>conftest.$ac_ext <<_ACEOF
11441 /* end confdefs.h.  */
11442 $ac_includes_default
11443 #include <$ac_header>
11444 _ACEOF
11445 rm -f conftest.$ac_objext
11446 if { (ac_try="$ac_compile"
11447 case "(($ac_try" in
11448   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11449   *) ac_try_echo=$ac_try;;
11450 esac
11451 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11452 $as_echo "$ac_try_echo") >&5
11453   (eval "$ac_compile") 2>conftest.er1
11454   ac_status=$?
11455   grep -v '^ *+' conftest.er1 >conftest.err
11456   rm -f conftest.er1
11457   cat conftest.err >&5
11458   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11459   (exit $ac_status); } && {
11460          test -z "$ac_c_werror_flag" ||
11461          test ! -s conftest.err
11462        } && test -s conftest.$ac_objext; then
11463   ac_header_compiler=yes
11464 else
11465   $as_echo "$as_me: failed program was:" >&5
11466 sed 's/^/| /' conftest.$ac_ext >&5
11467
11468         ac_header_compiler=no
11469 fi
11470
11471 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11472 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11473 $as_echo "$ac_header_compiler" >&6; }
11474
11475 # Is the header present?
11476 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11477 $as_echo_n "checking $ac_header presence... " >&6; }
11478 cat >conftest.$ac_ext <<_ACEOF
11479 /* confdefs.h.  */
11480 _ACEOF
11481 cat confdefs.h >>conftest.$ac_ext
11482 cat >>conftest.$ac_ext <<_ACEOF
11483 /* end confdefs.h.  */
11484 #include <$ac_header>
11485 _ACEOF
11486 if { (ac_try="$ac_cpp conftest.$ac_ext"
11487 case "(($ac_try" in
11488   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11489   *) ac_try_echo=$ac_try;;
11490 esac
11491 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11492 $as_echo "$ac_try_echo") >&5
11493   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11494   ac_status=$?
11495   grep -v '^ *+' conftest.er1 >conftest.err
11496   rm -f conftest.er1
11497   cat conftest.err >&5
11498   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11499   (exit $ac_status); } >/dev/null && {
11500          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11501          test ! -s conftest.err
11502        }; then
11503   ac_header_preproc=yes
11504 else
11505   $as_echo "$as_me: failed program was:" >&5
11506 sed 's/^/| /' conftest.$ac_ext >&5
11507
11508   ac_header_preproc=no
11509 fi
11510
11511 rm -f conftest.err conftest.$ac_ext
11512 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11513 $as_echo "$ac_header_preproc" >&6; }
11514
11515 # So?  What about this header?
11516 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11517   yes:no: )
11518     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11519 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11520     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11521 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11522     ac_header_preproc=yes
11523     ;;
11524   no:yes:* )
11525     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11526 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11527     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11528 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11529     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11530 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11531     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11532 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11533     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11534 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11535     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11536 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11537     ( cat <<\_ASBOX
11538 ## ---------------------------------------- ##
11539 ## Report this to pgsql-bugs@postgresql.org ##
11540 ## ---------------------------------------- ##
11541 _ASBOX
11542      ) | sed "s/^/$as_me: WARNING:     /" >&2
11543     ;;
11544 esac
11545 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11546 $as_echo_n "checking for $ac_header... " >&6; }
11547 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11548   $as_echo_n "(cached) " >&6
11549 else
11550   eval "$as_ac_Header=\$ac_header_preproc"
11551 fi
11552 ac_res=`eval 'as_val=${'$as_ac_Header'}
11553                  $as_echo "$as_val"'`
11554                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11555 $as_echo "$ac_res" >&6; }
11556
11557 fi
11558 as_val=`eval 'as_val=${'$as_ac_Header'}
11559                  $as_echo "$as_val"'`
11560    if test "x$as_val" = x""yes; then
11561   cat >>confdefs.h <<_ACEOF
11562 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11563 _ACEOF
11564
11565 else
11566
11567 for ac_header in readline/history.h
11568 do
11569 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11570 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11571   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11572 $as_echo_n "checking for $ac_header... " >&6; }
11573 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11574   $as_echo_n "(cached) " >&6
11575 fi
11576 ac_res=`eval 'as_val=${'$as_ac_Header'}
11577                  $as_echo "$as_val"'`
11578                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11579 $as_echo "$ac_res" >&6; }
11580 else
11581   # Is the header compilable?
11582 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11583 $as_echo_n "checking $ac_header usability... " >&6; }
11584 cat >conftest.$ac_ext <<_ACEOF
11585 /* confdefs.h.  */
11586 _ACEOF
11587 cat confdefs.h >>conftest.$ac_ext
11588 cat >>conftest.$ac_ext <<_ACEOF
11589 /* end confdefs.h.  */
11590 $ac_includes_default
11591 #include <$ac_header>
11592 _ACEOF
11593 rm -f conftest.$ac_objext
11594 if { (ac_try="$ac_compile"
11595 case "(($ac_try" in
11596   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11597   *) ac_try_echo=$ac_try;;
11598 esac
11599 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11600 $as_echo "$ac_try_echo") >&5
11601   (eval "$ac_compile") 2>conftest.er1
11602   ac_status=$?
11603   grep -v '^ *+' conftest.er1 >conftest.err
11604   rm -f conftest.er1
11605   cat conftest.err >&5
11606   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11607   (exit $ac_status); } && {
11608          test -z "$ac_c_werror_flag" ||
11609          test ! -s conftest.err
11610        } && test -s conftest.$ac_objext; then
11611   ac_header_compiler=yes
11612 else
11613   $as_echo "$as_me: failed program was:" >&5
11614 sed 's/^/| /' conftest.$ac_ext >&5
11615
11616         ac_header_compiler=no
11617 fi
11618
11619 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11620 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11621 $as_echo "$ac_header_compiler" >&6; }
11622
11623 # Is the header present?
11624 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11625 $as_echo_n "checking $ac_header presence... " >&6; }
11626 cat >conftest.$ac_ext <<_ACEOF
11627 /* confdefs.h.  */
11628 _ACEOF
11629 cat confdefs.h >>conftest.$ac_ext
11630 cat >>conftest.$ac_ext <<_ACEOF
11631 /* end confdefs.h.  */
11632 #include <$ac_header>
11633 _ACEOF
11634 if { (ac_try="$ac_cpp conftest.$ac_ext"
11635 case "(($ac_try" in
11636   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11637   *) ac_try_echo=$ac_try;;
11638 esac
11639 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11640 $as_echo "$ac_try_echo") >&5
11641   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11642   ac_status=$?
11643   grep -v '^ *+' conftest.er1 >conftest.err
11644   rm -f conftest.er1
11645   cat conftest.err >&5
11646   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11647   (exit $ac_status); } >/dev/null && {
11648          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11649          test ! -s conftest.err
11650        }; then
11651   ac_header_preproc=yes
11652 else
11653   $as_echo "$as_me: failed program was:" >&5
11654 sed 's/^/| /' conftest.$ac_ext >&5
11655
11656   ac_header_preproc=no
11657 fi
11658
11659 rm -f conftest.err conftest.$ac_ext
11660 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11661 $as_echo "$ac_header_preproc" >&6; }
11662
11663 # So?  What about this header?
11664 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11665   yes:no: )
11666     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11667 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11668     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11669 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11670     ac_header_preproc=yes
11671     ;;
11672   no:yes:* )
11673     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11674 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11675     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11676 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11677     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11678 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11679     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11680 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11681     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11682 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11683     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11684 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11685     ( cat <<\_ASBOX
11686 ## ---------------------------------------- ##
11687 ## Report this to pgsql-bugs@postgresql.org ##
11688 ## ---------------------------------------- ##
11689 _ASBOX
11690      ) | sed "s/^/$as_me: WARNING:     /" >&2
11691     ;;
11692 esac
11693 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11694 $as_echo_n "checking for $ac_header... " >&6; }
11695 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11696   $as_echo_n "(cached) " >&6
11697 else
11698   eval "$as_ac_Header=\$ac_header_preproc"
11699 fi
11700 ac_res=`eval 'as_val=${'$as_ac_Header'}
11701                  $as_echo "$as_val"'`
11702                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11703 $as_echo "$ac_res" >&6; }
11704
11705 fi
11706 as_val=`eval 'as_val=${'$as_ac_Header'}
11707                  $as_echo "$as_val"'`
11708    if test "x$as_val" = x""yes; then
11709   cat >>confdefs.h <<_ACEOF
11710 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
11711 _ACEOF
11712
11713 fi
11714
11715 done
11716
11717 fi
11718
11719 done
11720
11721 fi
11722
11723 done
11724
11725 fi
11726
11727 if test "$with_zlib" = yes; then
11728   if test "${ac_cv_header_zlib_h+set}" = set; then
11729   { $as_echo "$as_me:$LINENO: checking for zlib.h" >&5
11730 $as_echo_n "checking for zlib.h... " >&6; }
11731 if test "${ac_cv_header_zlib_h+set}" = set; then
11732   $as_echo_n "(cached) " >&6
11733 fi
11734 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
11735 $as_echo "$ac_cv_header_zlib_h" >&6; }
11736 else
11737   # Is the header compilable?
11738 { $as_echo "$as_me:$LINENO: checking zlib.h usability" >&5
11739 $as_echo_n "checking zlib.h usability... " >&6; }
11740 cat >conftest.$ac_ext <<_ACEOF
11741 /* confdefs.h.  */
11742 _ACEOF
11743 cat confdefs.h >>conftest.$ac_ext
11744 cat >>conftest.$ac_ext <<_ACEOF
11745 /* end confdefs.h.  */
11746 $ac_includes_default
11747 #include <zlib.h>
11748 _ACEOF
11749 rm -f conftest.$ac_objext
11750 if { (ac_try="$ac_compile"
11751 case "(($ac_try" in
11752   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11753   *) ac_try_echo=$ac_try;;
11754 esac
11755 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11756 $as_echo "$ac_try_echo") >&5
11757   (eval "$ac_compile") 2>conftest.er1
11758   ac_status=$?
11759   grep -v '^ *+' conftest.er1 >conftest.err
11760   rm -f conftest.er1
11761   cat conftest.err >&5
11762   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11763   (exit $ac_status); } && {
11764          test -z "$ac_c_werror_flag" ||
11765          test ! -s conftest.err
11766        } && test -s conftest.$ac_objext; then
11767   ac_header_compiler=yes
11768 else
11769   $as_echo "$as_me: failed program was:" >&5
11770 sed 's/^/| /' conftest.$ac_ext >&5
11771
11772         ac_header_compiler=no
11773 fi
11774
11775 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11776 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11777 $as_echo "$ac_header_compiler" >&6; }
11778
11779 # Is the header present?
11780 { $as_echo "$as_me:$LINENO: checking zlib.h presence" >&5
11781 $as_echo_n "checking zlib.h presence... " >&6; }
11782 cat >conftest.$ac_ext <<_ACEOF
11783 /* confdefs.h.  */
11784 _ACEOF
11785 cat confdefs.h >>conftest.$ac_ext
11786 cat >>conftest.$ac_ext <<_ACEOF
11787 /* end confdefs.h.  */
11788 #include <zlib.h>
11789 _ACEOF
11790 if { (ac_try="$ac_cpp conftest.$ac_ext"
11791 case "(($ac_try" in
11792   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11793   *) ac_try_echo=$ac_try;;
11794 esac
11795 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11796 $as_echo "$ac_try_echo") >&5
11797   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11798   ac_status=$?
11799   grep -v '^ *+' conftest.er1 >conftest.err
11800   rm -f conftest.er1
11801   cat conftest.err >&5
11802   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11803   (exit $ac_status); } >/dev/null && {
11804          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11805          test ! -s conftest.err
11806        }; then
11807   ac_header_preproc=yes
11808 else
11809   $as_echo "$as_me: failed program was:" >&5
11810 sed 's/^/| /' conftest.$ac_ext >&5
11811
11812   ac_header_preproc=no
11813 fi
11814
11815 rm -f conftest.err conftest.$ac_ext
11816 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11817 $as_echo "$ac_header_preproc" >&6; }
11818
11819 # So?  What about this header?
11820 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11821   yes:no: )
11822     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&5
11823 $as_echo "$as_me: WARNING: zlib.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
11824     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the compiler's result" >&5
11825 $as_echo "$as_me: WARNING: zlib.h: proceeding with the compiler's result" >&2;}
11826     ac_header_preproc=yes
11827     ;;
11828   no:yes:* )
11829     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: present but cannot be compiled" >&5
11830 $as_echo "$as_me: WARNING: zlib.h: present but cannot be compiled" >&2;}
11831     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     check for missing prerequisite headers?" >&5
11832 $as_echo "$as_me: WARNING: zlib.h:     check for missing prerequisite headers?" >&2;}
11833     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: see the Autoconf documentation" >&5
11834 $as_echo "$as_me: WARNING: zlib.h: see the Autoconf documentation" >&2;}
11835     { $as_echo "$as_me:$LINENO: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&5
11836 $as_echo "$as_me: WARNING: zlib.h:     section \"Present But Cannot Be Compiled\"" >&2;}
11837     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: proceeding with the preprocessor's result" >&5
11838 $as_echo "$as_me: WARNING: zlib.h: proceeding with the preprocessor's result" >&2;}
11839     { $as_echo "$as_me:$LINENO: WARNING: zlib.h: in the future, the compiler will take precedence" >&5
11840 $as_echo "$as_me: WARNING: zlib.h: in the future, the compiler will take precedence" >&2;}
11841     ( cat <<\_ASBOX
11842 ## ---------------------------------------- ##
11843 ## Report this to pgsql-bugs@postgresql.org ##
11844 ## ---------------------------------------- ##
11845 _ASBOX
11846      ) | sed "s/^/$as_me: WARNING:     /" >&2
11847     ;;
11848 esac
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 else
11854   ac_cv_header_zlib_h=$ac_header_preproc
11855 fi
11856 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_zlib_h" >&5
11857 $as_echo "$ac_cv_header_zlib_h" >&6; }
11858
11859 fi
11860 if test "x$ac_cv_header_zlib_h" = x""yes; then
11861   :
11862 else
11863   { { $as_echo "$as_me:$LINENO: error: zlib header not found
11864 If you have zlib already installed, see config.log for details on the
11865 failure.  It is possible the compiler isn't looking in the proper directory.
11866 Use --without-zlib to disable zlib support." >&5
11867 $as_echo "$as_me: error: zlib header not found
11868 If you have zlib already installed, see config.log for details on the
11869 failure.  It is possible the compiler isn't looking in the proper directory.
11870 Use --without-zlib to disable zlib support." >&2;}
11871    { (exit 1); exit 1; }; }
11872 fi
11873
11874
11875 fi
11876
11877 if test "$with_gssapi" = yes ; then
11878
11879 for ac_header in gssapi/gssapi.h
11880 do
11881 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
11882 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11883   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
11884 $as_echo_n "checking for $ac_header... " >&6; }
11885 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
11886   $as_echo_n "(cached) " >&6
11887 fi
11888 ac_res=`eval 'as_val=${'$as_ac_Header'}
11889                  $as_echo "$as_val"'`
11890                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
11891 $as_echo "$ac_res" >&6; }
11892 else
11893   # Is the header compilable?
11894 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
11895 $as_echo_n "checking $ac_header usability... " >&6; }
11896 cat >conftest.$ac_ext <<_ACEOF
11897 /* confdefs.h.  */
11898 _ACEOF
11899 cat confdefs.h >>conftest.$ac_ext
11900 cat >>conftest.$ac_ext <<_ACEOF
11901 /* end confdefs.h.  */
11902 $ac_includes_default
11903 #include <$ac_header>
11904 _ACEOF
11905 rm -f conftest.$ac_objext
11906 if { (ac_try="$ac_compile"
11907 case "(($ac_try" in
11908   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11909   *) ac_try_echo=$ac_try;;
11910 esac
11911 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11912 $as_echo "$ac_try_echo") >&5
11913   (eval "$ac_compile") 2>conftest.er1
11914   ac_status=$?
11915   grep -v '^ *+' conftest.er1 >conftest.err
11916   rm -f conftest.er1
11917   cat conftest.err >&5
11918   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11919   (exit $ac_status); } && {
11920          test -z "$ac_c_werror_flag" ||
11921          test ! -s conftest.err
11922        } && test -s conftest.$ac_objext; then
11923   ac_header_compiler=yes
11924 else
11925   $as_echo "$as_me: failed program was:" >&5
11926 sed 's/^/| /' conftest.$ac_ext >&5
11927
11928         ac_header_compiler=no
11929 fi
11930
11931 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
11932 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
11933 $as_echo "$ac_header_compiler" >&6; }
11934
11935 # Is the header present?
11936 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
11937 $as_echo_n "checking $ac_header presence... " >&6; }
11938 cat >conftest.$ac_ext <<_ACEOF
11939 /* confdefs.h.  */
11940 _ACEOF
11941 cat confdefs.h >>conftest.$ac_ext
11942 cat >>conftest.$ac_ext <<_ACEOF
11943 /* end confdefs.h.  */
11944 #include <$ac_header>
11945 _ACEOF
11946 if { (ac_try="$ac_cpp conftest.$ac_ext"
11947 case "(($ac_try" in
11948   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
11949   *) ac_try_echo=$ac_try;;
11950 esac
11951 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
11952 $as_echo "$ac_try_echo") >&5
11953   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
11954   ac_status=$?
11955   grep -v '^ *+' conftest.er1 >conftest.err
11956   rm -f conftest.er1
11957   cat conftest.err >&5
11958   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
11959   (exit $ac_status); } >/dev/null && {
11960          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
11961          test ! -s conftest.err
11962        }; then
11963   ac_header_preproc=yes
11964 else
11965   $as_echo "$as_me: failed program was:" >&5
11966 sed 's/^/| /' conftest.$ac_ext >&5
11967
11968   ac_header_preproc=no
11969 fi
11970
11971 rm -f conftest.err conftest.$ac_ext
11972 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
11973 $as_echo "$ac_header_preproc" >&6; }
11974
11975 # So?  What about this header?
11976 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
11977   yes:no: )
11978     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
11979 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
11980     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
11981 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
11982     ac_header_preproc=yes
11983     ;;
11984   no:yes:* )
11985     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
11986 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
11987     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
11988 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
11989     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
11990 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
11991     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
11992 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
11993     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
11994 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
11995     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
11996 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
11997     ( cat <<\_ASBOX
11998 ## ---------------------------------------- ##
11999 ## Report this to pgsql-bugs@postgresql.org ##
12000 ## ---------------------------------------- ##
12001 _ASBOX
12002      ) | sed "s/^/$as_me: WARNING:     /" >&2
12003     ;;
12004 esac
12005 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12006 $as_echo_n "checking for $ac_header... " >&6; }
12007 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12008   $as_echo_n "(cached) " >&6
12009 else
12010   eval "$as_ac_Header=\$ac_header_preproc"
12011 fi
12012 ac_res=`eval 'as_val=${'$as_ac_Header'}
12013                  $as_echo "$as_val"'`
12014                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12015 $as_echo "$ac_res" >&6; }
12016
12017 fi
12018 as_val=`eval 'as_val=${'$as_ac_Header'}
12019                  $as_echo "$as_val"'`
12020    if test "x$as_val" = x""yes; then
12021   cat >>confdefs.h <<_ACEOF
12022 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12023 _ACEOF
12024
12025 else
12026
12027 for ac_header in gssapi.h
12028 do
12029 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12030 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12031   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12032 $as_echo_n "checking for $ac_header... " >&6; }
12033 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12034   $as_echo_n "(cached) " >&6
12035 fi
12036 ac_res=`eval 'as_val=${'$as_ac_Header'}
12037                  $as_echo "$as_val"'`
12038                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12039 $as_echo "$ac_res" >&6; }
12040 else
12041   # Is the header compilable?
12042 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12043 $as_echo_n "checking $ac_header usability... " >&6; }
12044 cat >conftest.$ac_ext <<_ACEOF
12045 /* confdefs.h.  */
12046 _ACEOF
12047 cat confdefs.h >>conftest.$ac_ext
12048 cat >>conftest.$ac_ext <<_ACEOF
12049 /* end confdefs.h.  */
12050 $ac_includes_default
12051 #include <$ac_header>
12052 _ACEOF
12053 rm -f conftest.$ac_objext
12054 if { (ac_try="$ac_compile"
12055 case "(($ac_try" in
12056   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12057   *) ac_try_echo=$ac_try;;
12058 esac
12059 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12060 $as_echo "$ac_try_echo") >&5
12061   (eval "$ac_compile") 2>conftest.er1
12062   ac_status=$?
12063   grep -v '^ *+' conftest.er1 >conftest.err
12064   rm -f conftest.er1
12065   cat conftest.err >&5
12066   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12067   (exit $ac_status); } && {
12068          test -z "$ac_c_werror_flag" ||
12069          test ! -s conftest.err
12070        } && test -s conftest.$ac_objext; then
12071   ac_header_compiler=yes
12072 else
12073   $as_echo "$as_me: failed program was:" >&5
12074 sed 's/^/| /' conftest.$ac_ext >&5
12075
12076         ac_header_compiler=no
12077 fi
12078
12079 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12080 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12081 $as_echo "$ac_header_compiler" >&6; }
12082
12083 # Is the header present?
12084 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12085 $as_echo_n "checking $ac_header presence... " >&6; }
12086 cat >conftest.$ac_ext <<_ACEOF
12087 /* confdefs.h.  */
12088 _ACEOF
12089 cat confdefs.h >>conftest.$ac_ext
12090 cat >>conftest.$ac_ext <<_ACEOF
12091 /* end confdefs.h.  */
12092 #include <$ac_header>
12093 _ACEOF
12094 if { (ac_try="$ac_cpp conftest.$ac_ext"
12095 case "(($ac_try" in
12096   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12097   *) ac_try_echo=$ac_try;;
12098 esac
12099 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12100 $as_echo "$ac_try_echo") >&5
12101   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12102   ac_status=$?
12103   grep -v '^ *+' conftest.er1 >conftest.err
12104   rm -f conftest.er1
12105   cat conftest.err >&5
12106   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12107   (exit $ac_status); } >/dev/null && {
12108          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12109          test ! -s conftest.err
12110        }; then
12111   ac_header_preproc=yes
12112 else
12113   $as_echo "$as_me: failed program was:" >&5
12114 sed 's/^/| /' conftest.$ac_ext >&5
12115
12116   ac_header_preproc=no
12117 fi
12118
12119 rm -f conftest.err conftest.$ac_ext
12120 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12121 $as_echo "$ac_header_preproc" >&6; }
12122
12123 # So?  What about this header?
12124 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12125   yes:no: )
12126     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12127 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12128     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12129 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12130     ac_header_preproc=yes
12131     ;;
12132   no:yes:* )
12133     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12134 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12135     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12136 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12137     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12138 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12139     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12140 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12141     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12142 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12143     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12144 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12145     ( cat <<\_ASBOX
12146 ## ---------------------------------------- ##
12147 ## Report this to pgsql-bugs@postgresql.org ##
12148 ## ---------------------------------------- ##
12149 _ASBOX
12150      ) | sed "s/^/$as_me: WARNING:     /" >&2
12151     ;;
12152 esac
12153 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12154 $as_echo_n "checking for $ac_header... " >&6; }
12155 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12156   $as_echo_n "(cached) " >&6
12157 else
12158   eval "$as_ac_Header=\$ac_header_preproc"
12159 fi
12160 ac_res=`eval 'as_val=${'$as_ac_Header'}
12161                  $as_echo "$as_val"'`
12162                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12163 $as_echo "$ac_res" >&6; }
12164
12165 fi
12166 as_val=`eval 'as_val=${'$as_ac_Header'}
12167                  $as_echo "$as_val"'`
12168    if test "x$as_val" = x""yes; then
12169   cat >>confdefs.h <<_ACEOF
12170 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12171 _ACEOF
12172
12173 else
12174   { { $as_echo "$as_me:$LINENO: error: gssapi.h header file is required for GSSAPI" >&5
12175 $as_echo "$as_me: error: gssapi.h header file is required for GSSAPI" >&2;}
12176    { (exit 1); exit 1; }; }
12177 fi
12178
12179 done
12180
12181 fi
12182
12183 done
12184
12185 fi
12186
12187 if test "$with_krb5" = yes ; then
12188   if test "${ac_cv_header_krb5_h+set}" = set; then
12189   { $as_echo "$as_me:$LINENO: checking for krb5.h" >&5
12190 $as_echo_n "checking for krb5.h... " >&6; }
12191 if test "${ac_cv_header_krb5_h+set}" = set; then
12192   $as_echo_n "(cached) " >&6
12193 fi
12194 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
12195 $as_echo "$ac_cv_header_krb5_h" >&6; }
12196 else
12197   # Is the header compilable?
12198 { $as_echo "$as_me:$LINENO: checking krb5.h usability" >&5
12199 $as_echo_n "checking krb5.h usability... " >&6; }
12200 cat >conftest.$ac_ext <<_ACEOF
12201 /* confdefs.h.  */
12202 _ACEOF
12203 cat confdefs.h >>conftest.$ac_ext
12204 cat >>conftest.$ac_ext <<_ACEOF
12205 /* end confdefs.h.  */
12206 $ac_includes_default
12207 #include <krb5.h>
12208 _ACEOF
12209 rm -f conftest.$ac_objext
12210 if { (ac_try="$ac_compile"
12211 case "(($ac_try" in
12212   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12213   *) ac_try_echo=$ac_try;;
12214 esac
12215 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12216 $as_echo "$ac_try_echo") >&5
12217   (eval "$ac_compile") 2>conftest.er1
12218   ac_status=$?
12219   grep -v '^ *+' conftest.er1 >conftest.err
12220   rm -f conftest.er1
12221   cat conftest.err >&5
12222   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12223   (exit $ac_status); } && {
12224          test -z "$ac_c_werror_flag" ||
12225          test ! -s conftest.err
12226        } && test -s conftest.$ac_objext; then
12227   ac_header_compiler=yes
12228 else
12229   $as_echo "$as_me: failed program was:" >&5
12230 sed 's/^/| /' conftest.$ac_ext >&5
12231
12232         ac_header_compiler=no
12233 fi
12234
12235 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12236 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12237 $as_echo "$ac_header_compiler" >&6; }
12238
12239 # Is the header present?
12240 { $as_echo "$as_me:$LINENO: checking krb5.h presence" >&5
12241 $as_echo_n "checking krb5.h presence... " >&6; }
12242 cat >conftest.$ac_ext <<_ACEOF
12243 /* confdefs.h.  */
12244 _ACEOF
12245 cat confdefs.h >>conftest.$ac_ext
12246 cat >>conftest.$ac_ext <<_ACEOF
12247 /* end confdefs.h.  */
12248 #include <krb5.h>
12249 _ACEOF
12250 if { (ac_try="$ac_cpp conftest.$ac_ext"
12251 case "(($ac_try" in
12252   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12253   *) ac_try_echo=$ac_try;;
12254 esac
12255 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12256 $as_echo "$ac_try_echo") >&5
12257   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12258   ac_status=$?
12259   grep -v '^ *+' conftest.er1 >conftest.err
12260   rm -f conftest.er1
12261   cat conftest.err >&5
12262   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12263   (exit $ac_status); } >/dev/null && {
12264          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12265          test ! -s conftest.err
12266        }; then
12267   ac_header_preproc=yes
12268 else
12269   $as_echo "$as_me: failed program was:" >&5
12270 sed 's/^/| /' conftest.$ac_ext >&5
12271
12272   ac_header_preproc=no
12273 fi
12274
12275 rm -f conftest.err conftest.$ac_ext
12276 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12277 $as_echo "$ac_header_preproc" >&6; }
12278
12279 # So?  What about this header?
12280 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12281   yes:no: )
12282     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&5
12283 $as_echo "$as_me: WARNING: krb5.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12284     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the compiler's result" >&5
12285 $as_echo "$as_me: WARNING: krb5.h: proceeding with the compiler's result" >&2;}
12286     ac_header_preproc=yes
12287     ;;
12288   no:yes:* )
12289     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: present but cannot be compiled" >&5
12290 $as_echo "$as_me: WARNING: krb5.h: present but cannot be compiled" >&2;}
12291     { $as_echo "$as_me:$LINENO: WARNING: krb5.h:     check for missing prerequisite headers?" >&5
12292 $as_echo "$as_me: WARNING: krb5.h:     check for missing prerequisite headers?" >&2;}
12293     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: see the Autoconf documentation" >&5
12294 $as_echo "$as_me: WARNING: krb5.h: see the Autoconf documentation" >&2;}
12295     { $as_echo "$as_me:$LINENO: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&5
12296 $as_echo "$as_me: WARNING: krb5.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12297     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: proceeding with the preprocessor's result" >&5
12298 $as_echo "$as_me: WARNING: krb5.h: proceeding with the preprocessor's result" >&2;}
12299     { $as_echo "$as_me:$LINENO: WARNING: krb5.h: in the future, the compiler will take precedence" >&5
12300 $as_echo "$as_me: WARNING: krb5.h: in the future, the compiler will take precedence" >&2;}
12301     ( cat <<\_ASBOX
12302 ## ---------------------------------------- ##
12303 ## Report this to pgsql-bugs@postgresql.org ##
12304 ## ---------------------------------------- ##
12305 _ASBOX
12306      ) | sed "s/^/$as_me: WARNING:     /" >&2
12307     ;;
12308 esac
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 else
12314   ac_cv_header_krb5_h=$ac_header_preproc
12315 fi
12316 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_krb5_h" >&5
12317 $as_echo "$ac_cv_header_krb5_h" >&6; }
12318
12319 fi
12320 if test "x$ac_cv_header_krb5_h" = x""yes; then
12321   :
12322 else
12323   { { $as_echo "$as_me:$LINENO: error: header file <krb5.h> is required for Kerberos 5" >&5
12324 $as_echo "$as_me: error: header file <krb5.h> is required for Kerberos 5" >&2;}
12325    { (exit 1); exit 1; }; }
12326 fi
12327
12328
12329 fi
12330
12331 if test "$with_openssl" = yes ; then
12332   if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12333   { $as_echo "$as_me:$LINENO: checking for openssl/ssl.h" >&5
12334 $as_echo_n "checking for openssl/ssl.h... " >&6; }
12335 if test "${ac_cv_header_openssl_ssl_h+set}" = set; then
12336   $as_echo_n "(cached) " >&6
12337 fi
12338 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
12339 $as_echo "$ac_cv_header_openssl_ssl_h" >&6; }
12340 else
12341   # Is the header compilable?
12342 { $as_echo "$as_me:$LINENO: checking openssl/ssl.h usability" >&5
12343 $as_echo_n "checking openssl/ssl.h usability... " >&6; }
12344 cat >conftest.$ac_ext <<_ACEOF
12345 /* confdefs.h.  */
12346 _ACEOF
12347 cat confdefs.h >>conftest.$ac_ext
12348 cat >>conftest.$ac_ext <<_ACEOF
12349 /* end confdefs.h.  */
12350 $ac_includes_default
12351 #include <openssl/ssl.h>
12352 _ACEOF
12353 rm -f conftest.$ac_objext
12354 if { (ac_try="$ac_compile"
12355 case "(($ac_try" in
12356   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12357   *) ac_try_echo=$ac_try;;
12358 esac
12359 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12360 $as_echo "$ac_try_echo") >&5
12361   (eval "$ac_compile") 2>conftest.er1
12362   ac_status=$?
12363   grep -v '^ *+' conftest.er1 >conftest.err
12364   rm -f conftest.er1
12365   cat conftest.err >&5
12366   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12367   (exit $ac_status); } && {
12368          test -z "$ac_c_werror_flag" ||
12369          test ! -s conftest.err
12370        } && test -s conftest.$ac_objext; then
12371   ac_header_compiler=yes
12372 else
12373   $as_echo "$as_me: failed program was:" >&5
12374 sed 's/^/| /' conftest.$ac_ext >&5
12375
12376         ac_header_compiler=no
12377 fi
12378
12379 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12380 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12381 $as_echo "$ac_header_compiler" >&6; }
12382
12383 # Is the header present?
12384 { $as_echo "$as_me:$LINENO: checking openssl/ssl.h presence" >&5
12385 $as_echo_n "checking openssl/ssl.h presence... " >&6; }
12386 cat >conftest.$ac_ext <<_ACEOF
12387 /* confdefs.h.  */
12388 _ACEOF
12389 cat confdefs.h >>conftest.$ac_ext
12390 cat >>conftest.$ac_ext <<_ACEOF
12391 /* end confdefs.h.  */
12392 #include <openssl/ssl.h>
12393 _ACEOF
12394 if { (ac_try="$ac_cpp conftest.$ac_ext"
12395 case "(($ac_try" in
12396   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12397   *) ac_try_echo=$ac_try;;
12398 esac
12399 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12400 $as_echo "$ac_try_echo") >&5
12401   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12402   ac_status=$?
12403   grep -v '^ *+' conftest.er1 >conftest.err
12404   rm -f conftest.er1
12405   cat conftest.err >&5
12406   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12407   (exit $ac_status); } >/dev/null && {
12408          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12409          test ! -s conftest.err
12410        }; then
12411   ac_header_preproc=yes
12412 else
12413   $as_echo "$as_me: failed program was:" >&5
12414 sed 's/^/| /' conftest.$ac_ext >&5
12415
12416   ac_header_preproc=no
12417 fi
12418
12419 rm -f conftest.err conftest.$ac_ext
12420 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12421 $as_echo "$ac_header_preproc" >&6; }
12422
12423 # So?  What about this header?
12424 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12425   yes:no: )
12426     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&5
12427 $as_echo "$as_me: WARNING: openssl/ssl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12428     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&5
12429 $as_echo "$as_me: WARNING: openssl/ssl.h: proceeding with the compiler's result" >&2;}
12430     ac_header_preproc=yes
12431     ;;
12432   no:yes:* )
12433     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: present but cannot be compiled" >&5
12434 $as_echo "$as_me: WARNING: openssl/ssl.h: present but cannot be compiled" >&2;}
12435     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&5
12436 $as_echo "$as_me: WARNING: openssl/ssl.h:     check for missing prerequisite headers?" >&2;}
12437     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: see the Autoconf documentation" >&5
12438 $as_echo "$as_me: WARNING: openssl/ssl.h: see the Autoconf documentation" >&2;}
12439     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&5
12440 $as_echo "$as_me: WARNING: openssl/ssl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12441     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&5
12442 $as_echo "$as_me: WARNING: openssl/ssl.h: proceeding with the preprocessor's result" >&2;}
12443     { $as_echo "$as_me:$LINENO: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&5
12444 $as_echo "$as_me: WARNING: openssl/ssl.h: in the future, the compiler will take precedence" >&2;}
12445     ( cat <<\_ASBOX
12446 ## ---------------------------------------- ##
12447 ## Report this to pgsql-bugs@postgresql.org ##
12448 ## ---------------------------------------- ##
12449 _ASBOX
12450      ) | sed "s/^/$as_me: WARNING:     /" >&2
12451     ;;
12452 esac
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 else
12458   ac_cv_header_openssl_ssl_h=$ac_header_preproc
12459 fi
12460 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_ssl_h" >&5
12461 $as_echo "$ac_cv_header_openssl_ssl_h" >&6; }
12462
12463 fi
12464 if test "x$ac_cv_header_openssl_ssl_h" = x""yes; then
12465   :
12466 else
12467   { { $as_echo "$as_me:$LINENO: error: header file <openssl/ssl.h> is required for OpenSSL" >&5
12468 $as_echo "$as_me: error: header file <openssl/ssl.h> is required for OpenSSL" >&2;}
12469    { (exit 1); exit 1; }; }
12470 fi
12471
12472
12473   if test "${ac_cv_header_openssl_err_h+set}" = set; then
12474   { $as_echo "$as_me:$LINENO: checking for openssl/err.h" >&5
12475 $as_echo_n "checking for openssl/err.h... " >&6; }
12476 if test "${ac_cv_header_openssl_err_h+set}" = set; then
12477   $as_echo_n "(cached) " >&6
12478 fi
12479 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
12480 $as_echo "$ac_cv_header_openssl_err_h" >&6; }
12481 else
12482   # Is the header compilable?
12483 { $as_echo "$as_me:$LINENO: checking openssl/err.h usability" >&5
12484 $as_echo_n "checking openssl/err.h usability... " >&6; }
12485 cat >conftest.$ac_ext <<_ACEOF
12486 /* confdefs.h.  */
12487 _ACEOF
12488 cat confdefs.h >>conftest.$ac_ext
12489 cat >>conftest.$ac_ext <<_ACEOF
12490 /* end confdefs.h.  */
12491 $ac_includes_default
12492 #include <openssl/err.h>
12493 _ACEOF
12494 rm -f conftest.$ac_objext
12495 if { (ac_try="$ac_compile"
12496 case "(($ac_try" in
12497   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12498   *) ac_try_echo=$ac_try;;
12499 esac
12500 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12501 $as_echo "$ac_try_echo") >&5
12502   (eval "$ac_compile") 2>conftest.er1
12503   ac_status=$?
12504   grep -v '^ *+' conftest.er1 >conftest.err
12505   rm -f conftest.er1
12506   cat conftest.err >&5
12507   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12508   (exit $ac_status); } && {
12509          test -z "$ac_c_werror_flag" ||
12510          test ! -s conftest.err
12511        } && test -s conftest.$ac_objext; then
12512   ac_header_compiler=yes
12513 else
12514   $as_echo "$as_me: failed program was:" >&5
12515 sed 's/^/| /' conftest.$ac_ext >&5
12516
12517         ac_header_compiler=no
12518 fi
12519
12520 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12521 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12522 $as_echo "$ac_header_compiler" >&6; }
12523
12524 # Is the header present?
12525 { $as_echo "$as_me:$LINENO: checking openssl/err.h presence" >&5
12526 $as_echo_n "checking openssl/err.h presence... " >&6; }
12527 cat >conftest.$ac_ext <<_ACEOF
12528 /* confdefs.h.  */
12529 _ACEOF
12530 cat confdefs.h >>conftest.$ac_ext
12531 cat >>conftest.$ac_ext <<_ACEOF
12532 /* end confdefs.h.  */
12533 #include <openssl/err.h>
12534 _ACEOF
12535 if { (ac_try="$ac_cpp conftest.$ac_ext"
12536 case "(($ac_try" in
12537   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12538   *) ac_try_echo=$ac_try;;
12539 esac
12540 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12541 $as_echo "$ac_try_echo") >&5
12542   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12543   ac_status=$?
12544   grep -v '^ *+' conftest.er1 >conftest.err
12545   rm -f conftest.er1
12546   cat conftest.err >&5
12547   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12548   (exit $ac_status); } >/dev/null && {
12549          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12550          test ! -s conftest.err
12551        }; then
12552   ac_header_preproc=yes
12553 else
12554   $as_echo "$as_me: failed program was:" >&5
12555 sed 's/^/| /' conftest.$ac_ext >&5
12556
12557   ac_header_preproc=no
12558 fi
12559
12560 rm -f conftest.err conftest.$ac_ext
12561 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12562 $as_echo "$ac_header_preproc" >&6; }
12563
12564 # So?  What about this header?
12565 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12566   yes:no: )
12567     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&5
12568 $as_echo "$as_me: WARNING: openssl/err.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
12569     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the compiler's result" >&5
12570 $as_echo "$as_me: WARNING: openssl/err.h: proceeding with the compiler's result" >&2;}
12571     ac_header_preproc=yes
12572     ;;
12573   no:yes:* )
12574     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: present but cannot be compiled" >&5
12575 $as_echo "$as_me: WARNING: openssl/err.h: present but cannot be compiled" >&2;}
12576     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&5
12577 $as_echo "$as_me: WARNING: openssl/err.h:     check for missing prerequisite headers?" >&2;}
12578     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: see the Autoconf documentation" >&5
12579 $as_echo "$as_me: WARNING: openssl/err.h: see the Autoconf documentation" >&2;}
12580     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&5
12581 $as_echo "$as_me: WARNING: openssl/err.h:     section \"Present But Cannot Be Compiled\"" >&2;}
12582     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&5
12583 $as_echo "$as_me: WARNING: openssl/err.h: proceeding with the preprocessor's result" >&2;}
12584     { $as_echo "$as_me:$LINENO: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&5
12585 $as_echo "$as_me: WARNING: openssl/err.h: in the future, the compiler will take precedence" >&2;}
12586     ( cat <<\_ASBOX
12587 ## ---------------------------------------- ##
12588 ## Report this to pgsql-bugs@postgresql.org ##
12589 ## ---------------------------------------- ##
12590 _ASBOX
12591      ) | sed "s/^/$as_me: WARNING:     /" >&2
12592     ;;
12593 esac
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 else
12599   ac_cv_header_openssl_err_h=$ac_header_preproc
12600 fi
12601 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_openssl_err_h" >&5
12602 $as_echo "$ac_cv_header_openssl_err_h" >&6; }
12603
12604 fi
12605 if test "x$ac_cv_header_openssl_err_h" = x""yes; then
12606   :
12607 else
12608   { { $as_echo "$as_me:$LINENO: error: header file <openssl/err.h> is required for OpenSSL" >&5
12609 $as_echo "$as_me: error: header file <openssl/err.h> is required for OpenSSL" >&2;}
12610    { (exit 1); exit 1; }; }
12611 fi
12612
12613
12614
12615 for ac_func in ERR_set_mark
12616 do
12617 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
12618 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
12619 $as_echo_n "checking for $ac_func... " >&6; }
12620 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
12621   $as_echo_n "(cached) " >&6
12622 else
12623   cat >conftest.$ac_ext <<_ACEOF
12624 /* confdefs.h.  */
12625 _ACEOF
12626 cat confdefs.h >>conftest.$ac_ext
12627 cat >>conftest.$ac_ext <<_ACEOF
12628 /* end confdefs.h.  */
12629 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
12630    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
12631 #define $ac_func innocuous_$ac_func
12632
12633 /* System header to define __stub macros and hopefully few prototypes,
12634     which can conflict with char $ac_func (); below.
12635     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12636     <limits.h> exists even on freestanding compilers.  */
12637
12638 #ifdef __STDC__
12639 # include <limits.h>
12640 #else
12641 # include <assert.h>
12642 #endif
12643
12644 #undef $ac_func
12645
12646 /* Override any GCC internal prototype to avoid an error.
12647    Use char because int might match the return type of a GCC
12648    builtin and then its argument prototype would still apply.  */
12649 #ifdef __cplusplus
12650 extern "C"
12651 #endif
12652 char $ac_func ();
12653 /* The GNU C library defines this for functions which it implements
12654     to always fail with ENOSYS.  Some functions are actually named
12655     something starting with __ and the normal name is an alias.  */
12656 #if defined __stub_$ac_func || defined __stub___$ac_func
12657 choke me
12658 #endif
12659
12660 int
12661 main ()
12662 {
12663 return $ac_func ();
12664   ;
12665   return 0;
12666 }
12667 _ACEOF
12668 rm -f conftest.$ac_objext conftest$ac_exeext
12669 if { (ac_try="$ac_link"
12670 case "(($ac_try" in
12671   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12672   *) ac_try_echo=$ac_try;;
12673 esac
12674 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12675 $as_echo "$ac_try_echo") >&5
12676   (eval "$ac_link") 2>conftest.er1
12677   ac_status=$?
12678   grep -v '^ *+' conftest.er1 >conftest.err
12679   rm -f conftest.er1
12680   cat conftest.err >&5
12681   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12682   (exit $ac_status); } && {
12683          test -z "$ac_c_werror_flag" ||
12684          test ! -s conftest.err
12685        } && test -s conftest$ac_exeext && {
12686          test "$cross_compiling" = yes ||
12687          $as_test_x conftest$ac_exeext
12688        }; then
12689   eval "$as_ac_var=yes"
12690 else
12691   $as_echo "$as_me: failed program was:" >&5
12692 sed 's/^/| /' conftest.$ac_ext >&5
12693
12694         eval "$as_ac_var=no"
12695 fi
12696
12697 rm -rf conftest.dSYM
12698 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
12699       conftest$ac_exeext conftest.$ac_ext
12700 fi
12701 ac_res=`eval 'as_val=${'$as_ac_var'}
12702                  $as_echo "$as_val"'`
12703                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12704 $as_echo "$ac_res" >&6; }
12705 as_val=`eval 'as_val=${'$as_ac_var'}
12706                  $as_echo "$as_val"'`
12707    if test "x$as_val" = x""yes; then
12708   cat >>confdefs.h <<_ACEOF
12709 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
12710 _ACEOF
12711
12712 fi
12713 done
12714
12715 fi
12716
12717 if test "$with_pam" = yes ; then
12718
12719 for ac_header in security/pam_appl.h
12720 do
12721 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12722 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12723   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12724 $as_echo_n "checking for $ac_header... " >&6; }
12725 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12726   $as_echo_n "(cached) " >&6
12727 fi
12728 ac_res=`eval 'as_val=${'$as_ac_Header'}
12729                  $as_echo "$as_val"'`
12730                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12731 $as_echo "$ac_res" >&6; }
12732 else
12733   # Is the header compilable?
12734 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12735 $as_echo_n "checking $ac_header usability... " >&6; }
12736 cat >conftest.$ac_ext <<_ACEOF
12737 /* confdefs.h.  */
12738 _ACEOF
12739 cat confdefs.h >>conftest.$ac_ext
12740 cat >>conftest.$ac_ext <<_ACEOF
12741 /* end confdefs.h.  */
12742 $ac_includes_default
12743 #include <$ac_header>
12744 _ACEOF
12745 rm -f conftest.$ac_objext
12746 if { (ac_try="$ac_compile"
12747 case "(($ac_try" in
12748   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12749   *) ac_try_echo=$ac_try;;
12750 esac
12751 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12752 $as_echo "$ac_try_echo") >&5
12753   (eval "$ac_compile") 2>conftest.er1
12754   ac_status=$?
12755   grep -v '^ *+' conftest.er1 >conftest.err
12756   rm -f conftest.er1
12757   cat conftest.err >&5
12758   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12759   (exit $ac_status); } && {
12760          test -z "$ac_c_werror_flag" ||
12761          test ! -s conftest.err
12762        } && test -s conftest.$ac_objext; then
12763   ac_header_compiler=yes
12764 else
12765   $as_echo "$as_me: failed program was:" >&5
12766 sed 's/^/| /' conftest.$ac_ext >&5
12767
12768         ac_header_compiler=no
12769 fi
12770
12771 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12772 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12773 $as_echo "$ac_header_compiler" >&6; }
12774
12775 # Is the header present?
12776 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12777 $as_echo_n "checking $ac_header presence... " >&6; }
12778 cat >conftest.$ac_ext <<_ACEOF
12779 /* confdefs.h.  */
12780 _ACEOF
12781 cat confdefs.h >>conftest.$ac_ext
12782 cat >>conftest.$ac_ext <<_ACEOF
12783 /* end confdefs.h.  */
12784 #include <$ac_header>
12785 _ACEOF
12786 if { (ac_try="$ac_cpp conftest.$ac_ext"
12787 case "(($ac_try" in
12788   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12789   *) ac_try_echo=$ac_try;;
12790 esac
12791 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12792 $as_echo "$ac_try_echo") >&5
12793   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12794   ac_status=$?
12795   grep -v '^ *+' conftest.er1 >conftest.err
12796   rm -f conftest.er1
12797   cat conftest.err >&5
12798   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12799   (exit $ac_status); } >/dev/null && {
12800          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12801          test ! -s conftest.err
12802        }; then
12803   ac_header_preproc=yes
12804 else
12805   $as_echo "$as_me: failed program was:" >&5
12806 sed 's/^/| /' conftest.$ac_ext >&5
12807
12808   ac_header_preproc=no
12809 fi
12810
12811 rm -f conftest.err conftest.$ac_ext
12812 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12813 $as_echo "$ac_header_preproc" >&6; }
12814
12815 # So?  What about this header?
12816 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12817   yes:no: )
12818     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12819 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12820     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12821 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12822     ac_header_preproc=yes
12823     ;;
12824   no:yes:* )
12825     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12826 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12827     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12828 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12829     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12830 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12831     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12832 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12833     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12834 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12835     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12836 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12837     ( cat <<\_ASBOX
12838 ## ---------------------------------------- ##
12839 ## Report this to pgsql-bugs@postgresql.org ##
12840 ## ---------------------------------------- ##
12841 _ASBOX
12842      ) | sed "s/^/$as_me: WARNING:     /" >&2
12843     ;;
12844 esac
12845 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12846 $as_echo_n "checking for $ac_header... " >&6; }
12847 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12848   $as_echo_n "(cached) " >&6
12849 else
12850   eval "$as_ac_Header=\$ac_header_preproc"
12851 fi
12852 ac_res=`eval 'as_val=${'$as_ac_Header'}
12853                  $as_echo "$as_val"'`
12854                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12855 $as_echo "$ac_res" >&6; }
12856
12857 fi
12858 as_val=`eval 'as_val=${'$as_ac_Header'}
12859                  $as_echo "$as_val"'`
12860    if test "x$as_val" = x""yes; then
12861   cat >>confdefs.h <<_ACEOF
12862 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
12863 _ACEOF
12864
12865 else
12866
12867 for ac_header in pam/pam_appl.h
12868 do
12869 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
12870 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12871   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12872 $as_echo_n "checking for $ac_header... " >&6; }
12873 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12874   $as_echo_n "(cached) " >&6
12875 fi
12876 ac_res=`eval 'as_val=${'$as_ac_Header'}
12877                  $as_echo "$as_val"'`
12878                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
12879 $as_echo "$ac_res" >&6; }
12880 else
12881   # Is the header compilable?
12882 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
12883 $as_echo_n "checking $ac_header usability... " >&6; }
12884 cat >conftest.$ac_ext <<_ACEOF
12885 /* confdefs.h.  */
12886 _ACEOF
12887 cat confdefs.h >>conftest.$ac_ext
12888 cat >>conftest.$ac_ext <<_ACEOF
12889 /* end confdefs.h.  */
12890 $ac_includes_default
12891 #include <$ac_header>
12892 _ACEOF
12893 rm -f conftest.$ac_objext
12894 if { (ac_try="$ac_compile"
12895 case "(($ac_try" in
12896   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12897   *) ac_try_echo=$ac_try;;
12898 esac
12899 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12900 $as_echo "$ac_try_echo") >&5
12901   (eval "$ac_compile") 2>conftest.er1
12902   ac_status=$?
12903   grep -v '^ *+' conftest.er1 >conftest.err
12904   rm -f conftest.er1
12905   cat conftest.err >&5
12906   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12907   (exit $ac_status); } && {
12908          test -z "$ac_c_werror_flag" ||
12909          test ! -s conftest.err
12910        } && test -s conftest.$ac_objext; then
12911   ac_header_compiler=yes
12912 else
12913   $as_echo "$as_me: failed program was:" >&5
12914 sed 's/^/| /' conftest.$ac_ext >&5
12915
12916         ac_header_compiler=no
12917 fi
12918
12919 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
12920 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12921 $as_echo "$ac_header_compiler" >&6; }
12922
12923 # Is the header present?
12924 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
12925 $as_echo_n "checking $ac_header presence... " >&6; }
12926 cat >conftest.$ac_ext <<_ACEOF
12927 /* confdefs.h.  */
12928 _ACEOF
12929 cat confdefs.h >>conftest.$ac_ext
12930 cat >>conftest.$ac_ext <<_ACEOF
12931 /* end confdefs.h.  */
12932 #include <$ac_header>
12933 _ACEOF
12934 if { (ac_try="$ac_cpp conftest.$ac_ext"
12935 case "(($ac_try" in
12936   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
12937   *) ac_try_echo=$ac_try;;
12938 esac
12939 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
12940 $as_echo "$ac_try_echo") >&5
12941   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
12942   ac_status=$?
12943   grep -v '^ *+' conftest.er1 >conftest.err
12944   rm -f conftest.er1
12945   cat conftest.err >&5
12946   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
12947   (exit $ac_status); } >/dev/null && {
12948          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
12949          test ! -s conftest.err
12950        }; then
12951   ac_header_preproc=yes
12952 else
12953   $as_echo "$as_me: failed program was:" >&5
12954 sed 's/^/| /' conftest.$ac_ext >&5
12955
12956   ac_header_preproc=no
12957 fi
12958
12959 rm -f conftest.err conftest.$ac_ext
12960 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12961 $as_echo "$ac_header_preproc" >&6; }
12962
12963 # So?  What about this header?
12964 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
12965   yes:no: )
12966     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12967 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12968     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12969 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12970     ac_header_preproc=yes
12971     ;;
12972   no:yes:* )
12973     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12974 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12975     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
12976 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
12977     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12978 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12979     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
12980 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
12981     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12982 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12983     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12984 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12985     ( cat <<\_ASBOX
12986 ## ---------------------------------------- ##
12987 ## Report this to pgsql-bugs@postgresql.org ##
12988 ## ---------------------------------------- ##
12989 _ASBOX
12990      ) | sed "s/^/$as_me: WARNING:     /" >&2
12991     ;;
12992 esac
12993 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
12994 $as_echo_n "checking for $ac_header... " >&6; }
12995 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
12996   $as_echo_n "(cached) " >&6
12997 else
12998   eval "$as_ac_Header=\$ac_header_preproc"
12999 fi
13000 ac_res=`eval 'as_val=${'$as_ac_Header'}
13001                  $as_echo "$as_val"'`
13002                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13003 $as_echo "$ac_res" >&6; }
13004
13005 fi
13006 as_val=`eval 'as_val=${'$as_ac_Header'}
13007                  $as_echo "$as_val"'`
13008    if test "x$as_val" = x""yes; then
13009   cat >>confdefs.h <<_ACEOF
13010 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13011 _ACEOF
13012
13013 else
13014   { { $as_echo "$as_me:$LINENO: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&5
13015 $as_echo "$as_me: error: header file <security/pam_appl.h> or <pam/pam_appl.h> is required for PAM." >&2;}
13016    { (exit 1); exit 1; }; }
13017 fi
13018
13019 done
13020
13021 fi
13022
13023 done
13024
13025 fi
13026
13027 if test "$with_libxml" = yes ; then
13028   if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13029   { $as_echo "$as_me:$LINENO: checking for libxml/parser.h" >&5
13030 $as_echo_n "checking for libxml/parser.h... " >&6; }
13031 if test "${ac_cv_header_libxml_parser_h+set}" = set; then
13032   $as_echo_n "(cached) " >&6
13033 fi
13034 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
13035 $as_echo "$ac_cv_header_libxml_parser_h" >&6; }
13036 else
13037   # Is the header compilable?
13038 { $as_echo "$as_me:$LINENO: checking libxml/parser.h usability" >&5
13039 $as_echo_n "checking libxml/parser.h usability... " >&6; }
13040 cat >conftest.$ac_ext <<_ACEOF
13041 /* confdefs.h.  */
13042 _ACEOF
13043 cat confdefs.h >>conftest.$ac_ext
13044 cat >>conftest.$ac_ext <<_ACEOF
13045 /* end confdefs.h.  */
13046 $ac_includes_default
13047 #include <libxml/parser.h>
13048 _ACEOF
13049 rm -f conftest.$ac_objext
13050 if { (ac_try="$ac_compile"
13051 case "(($ac_try" in
13052   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13053   *) ac_try_echo=$ac_try;;
13054 esac
13055 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13056 $as_echo "$ac_try_echo") >&5
13057   (eval "$ac_compile") 2>conftest.er1
13058   ac_status=$?
13059   grep -v '^ *+' conftest.er1 >conftest.err
13060   rm -f conftest.er1
13061   cat conftest.err >&5
13062   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13063   (exit $ac_status); } && {
13064          test -z "$ac_c_werror_flag" ||
13065          test ! -s conftest.err
13066        } && test -s conftest.$ac_objext; then
13067   ac_header_compiler=yes
13068 else
13069   $as_echo "$as_me: failed program was:" >&5
13070 sed 's/^/| /' conftest.$ac_ext >&5
13071
13072         ac_header_compiler=no
13073 fi
13074
13075 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13076 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13077 $as_echo "$ac_header_compiler" >&6; }
13078
13079 # Is the header present?
13080 { $as_echo "$as_me:$LINENO: checking libxml/parser.h presence" >&5
13081 $as_echo_n "checking libxml/parser.h presence... " >&6; }
13082 cat >conftest.$ac_ext <<_ACEOF
13083 /* confdefs.h.  */
13084 _ACEOF
13085 cat confdefs.h >>conftest.$ac_ext
13086 cat >>conftest.$ac_ext <<_ACEOF
13087 /* end confdefs.h.  */
13088 #include <libxml/parser.h>
13089 _ACEOF
13090 if { (ac_try="$ac_cpp conftest.$ac_ext"
13091 case "(($ac_try" in
13092   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13093   *) ac_try_echo=$ac_try;;
13094 esac
13095 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13096 $as_echo "$ac_try_echo") >&5
13097   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13098   ac_status=$?
13099   grep -v '^ *+' conftest.er1 >conftest.err
13100   rm -f conftest.er1
13101   cat conftest.err >&5
13102   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13103   (exit $ac_status); } >/dev/null && {
13104          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13105          test ! -s conftest.err
13106        }; then
13107   ac_header_preproc=yes
13108 else
13109   $as_echo "$as_me: failed program was:" >&5
13110 sed 's/^/| /' conftest.$ac_ext >&5
13111
13112   ac_header_preproc=no
13113 fi
13114
13115 rm -f conftest.err conftest.$ac_ext
13116 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13117 $as_echo "$ac_header_preproc" >&6; }
13118
13119 # So?  What about this header?
13120 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13121   yes:no: )
13122     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&5
13123 $as_echo "$as_me: WARNING: libxml/parser.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13124     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the compiler's result" >&5
13125 $as_echo "$as_me: WARNING: libxml/parser.h: proceeding with the compiler's result" >&2;}
13126     ac_header_preproc=yes
13127     ;;
13128   no:yes:* )
13129     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: present but cannot be compiled" >&5
13130 $as_echo "$as_me: WARNING: libxml/parser.h: present but cannot be compiled" >&2;}
13131     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&5
13132 $as_echo "$as_me: WARNING: libxml/parser.h:     check for missing prerequisite headers?" >&2;}
13133     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: see the Autoconf documentation" >&5
13134 $as_echo "$as_me: WARNING: libxml/parser.h: see the Autoconf documentation" >&2;}
13135     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&5
13136 $as_echo "$as_me: WARNING: libxml/parser.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13137     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&5
13138 $as_echo "$as_me: WARNING: libxml/parser.h: proceeding with the preprocessor's result" >&2;}
13139     { $as_echo "$as_me:$LINENO: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&5
13140 $as_echo "$as_me: WARNING: libxml/parser.h: in the future, the compiler will take precedence" >&2;}
13141     ( cat <<\_ASBOX
13142 ## ---------------------------------------- ##
13143 ## Report this to pgsql-bugs@postgresql.org ##
13144 ## ---------------------------------------- ##
13145 _ASBOX
13146      ) | sed "s/^/$as_me: WARNING:     /" >&2
13147     ;;
13148 esac
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 else
13154   ac_cv_header_libxml_parser_h=$ac_header_preproc
13155 fi
13156 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxml_parser_h" >&5
13157 $as_echo "$ac_cv_header_libxml_parser_h" >&6; }
13158
13159 fi
13160 if test "x$ac_cv_header_libxml_parser_h" = x""yes; then
13161   :
13162 else
13163   { { $as_echo "$as_me:$LINENO: error: header file <libxml/parser.h> is required for XML support" >&5
13164 $as_echo "$as_me: error: header file <libxml/parser.h> is required for XML support" >&2;}
13165    { (exit 1); exit 1; }; }
13166 fi
13167
13168
13169 fi
13170
13171 if test "$with_libxslt" = yes ; then
13172   if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13173   { $as_echo "$as_me:$LINENO: checking for libxslt/xslt.h" >&5
13174 $as_echo_n "checking for libxslt/xslt.h... " >&6; }
13175 if test "${ac_cv_header_libxslt_xslt_h+set}" = set; then
13176   $as_echo_n "(cached) " >&6
13177 fi
13178 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
13179 $as_echo "$ac_cv_header_libxslt_xslt_h" >&6; }
13180 else
13181   # Is the header compilable?
13182 { $as_echo "$as_me:$LINENO: checking libxslt/xslt.h usability" >&5
13183 $as_echo_n "checking libxslt/xslt.h usability... " >&6; }
13184 cat >conftest.$ac_ext <<_ACEOF
13185 /* confdefs.h.  */
13186 _ACEOF
13187 cat confdefs.h >>conftest.$ac_ext
13188 cat >>conftest.$ac_ext <<_ACEOF
13189 /* end confdefs.h.  */
13190 $ac_includes_default
13191 #include <libxslt/xslt.h>
13192 _ACEOF
13193 rm -f conftest.$ac_objext
13194 if { (ac_try="$ac_compile"
13195 case "(($ac_try" in
13196   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13197   *) ac_try_echo=$ac_try;;
13198 esac
13199 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13200 $as_echo "$ac_try_echo") >&5
13201   (eval "$ac_compile") 2>conftest.er1
13202   ac_status=$?
13203   grep -v '^ *+' conftest.er1 >conftest.err
13204   rm -f conftest.er1
13205   cat conftest.err >&5
13206   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13207   (exit $ac_status); } && {
13208          test -z "$ac_c_werror_flag" ||
13209          test ! -s conftest.err
13210        } && test -s conftest.$ac_objext; then
13211   ac_header_compiler=yes
13212 else
13213   $as_echo "$as_me: failed program was:" >&5
13214 sed 's/^/| /' conftest.$ac_ext >&5
13215
13216         ac_header_compiler=no
13217 fi
13218
13219 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13220 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13221 $as_echo "$ac_header_compiler" >&6; }
13222
13223 # Is the header present?
13224 { $as_echo "$as_me:$LINENO: checking libxslt/xslt.h presence" >&5
13225 $as_echo_n "checking libxslt/xslt.h presence... " >&6; }
13226 cat >conftest.$ac_ext <<_ACEOF
13227 /* confdefs.h.  */
13228 _ACEOF
13229 cat confdefs.h >>conftest.$ac_ext
13230 cat >>conftest.$ac_ext <<_ACEOF
13231 /* end confdefs.h.  */
13232 #include <libxslt/xslt.h>
13233 _ACEOF
13234 if { (ac_try="$ac_cpp conftest.$ac_ext"
13235 case "(($ac_try" in
13236   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13237   *) ac_try_echo=$ac_try;;
13238 esac
13239 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13240 $as_echo "$ac_try_echo") >&5
13241   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13242   ac_status=$?
13243   grep -v '^ *+' conftest.er1 >conftest.err
13244   rm -f conftest.er1
13245   cat conftest.err >&5
13246   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13247   (exit $ac_status); } >/dev/null && {
13248          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13249          test ! -s conftest.err
13250        }; then
13251   ac_header_preproc=yes
13252 else
13253   $as_echo "$as_me: failed program was:" >&5
13254 sed 's/^/| /' conftest.$ac_ext >&5
13255
13256   ac_header_preproc=no
13257 fi
13258
13259 rm -f conftest.err conftest.$ac_ext
13260 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13261 $as_echo "$ac_header_preproc" >&6; }
13262
13263 # So?  What about this header?
13264 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13265   yes:no: )
13266     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&5
13267 $as_echo "$as_me: WARNING: libxslt/xslt.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13268     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&5
13269 $as_echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the compiler's result" >&2;}
13270     ac_header_preproc=yes
13271     ;;
13272   no:yes:* )
13273     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: present but cannot be compiled" >&5
13274 $as_echo "$as_me: WARNING: libxslt/xslt.h: present but cannot be compiled" >&2;}
13275     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&5
13276 $as_echo "$as_me: WARNING: libxslt/xslt.h:     check for missing prerequisite headers?" >&2;}
13277     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&5
13278 $as_echo "$as_me: WARNING: libxslt/xslt.h: see the Autoconf documentation" >&2;}
13279     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&5
13280 $as_echo "$as_me: WARNING: libxslt/xslt.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13281     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&5
13282 $as_echo "$as_me: WARNING: libxslt/xslt.h: proceeding with the preprocessor's result" >&2;}
13283     { $as_echo "$as_me:$LINENO: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&5
13284 $as_echo "$as_me: WARNING: libxslt/xslt.h: in the future, the compiler will take precedence" >&2;}
13285     ( cat <<\_ASBOX
13286 ## ---------------------------------------- ##
13287 ## Report this to pgsql-bugs@postgresql.org ##
13288 ## ---------------------------------------- ##
13289 _ASBOX
13290      ) | sed "s/^/$as_me: WARNING:     /" >&2
13291     ;;
13292 esac
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 else
13298   ac_cv_header_libxslt_xslt_h=$ac_header_preproc
13299 fi
13300 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libxslt_xslt_h" >&5
13301 $as_echo "$ac_cv_header_libxslt_xslt_h" >&6; }
13302
13303 fi
13304 if test "x$ac_cv_header_libxslt_xslt_h" = x""yes; then
13305   :
13306 else
13307   { { $as_echo "$as_me:$LINENO: error: header file <libxslt/xslt.h> is required for XSLT support" >&5
13308 $as_echo "$as_me: error: header file <libxslt/xslt.h> is required for XSLT support" >&2;}
13309    { (exit 1); exit 1; }; }
13310 fi
13311
13312
13313 fi
13314
13315 if test "$with_ldap" = yes ; then
13316   if test "$PORTNAME" != "win32"; then
13317
13318 for ac_header in ldap.h
13319 do
13320 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13321 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13322   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13323 $as_echo_n "checking for $ac_header... " >&6; }
13324 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13325   $as_echo_n "(cached) " >&6
13326 fi
13327 ac_res=`eval 'as_val=${'$as_ac_Header'}
13328                  $as_echo "$as_val"'`
13329                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13330 $as_echo "$ac_res" >&6; }
13331 else
13332   # Is the header compilable?
13333 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13334 $as_echo_n "checking $ac_header usability... " >&6; }
13335 cat >conftest.$ac_ext <<_ACEOF
13336 /* confdefs.h.  */
13337 _ACEOF
13338 cat confdefs.h >>conftest.$ac_ext
13339 cat >>conftest.$ac_ext <<_ACEOF
13340 /* end confdefs.h.  */
13341 $ac_includes_default
13342 #include <$ac_header>
13343 _ACEOF
13344 rm -f conftest.$ac_objext
13345 if { (ac_try="$ac_compile"
13346 case "(($ac_try" in
13347   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13348   *) ac_try_echo=$ac_try;;
13349 esac
13350 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13351 $as_echo "$ac_try_echo") >&5
13352   (eval "$ac_compile") 2>conftest.er1
13353   ac_status=$?
13354   grep -v '^ *+' conftest.er1 >conftest.err
13355   rm -f conftest.er1
13356   cat conftest.err >&5
13357   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13358   (exit $ac_status); } && {
13359          test -z "$ac_c_werror_flag" ||
13360          test ! -s conftest.err
13361        } && test -s conftest.$ac_objext; then
13362   ac_header_compiler=yes
13363 else
13364   $as_echo "$as_me: failed program was:" >&5
13365 sed 's/^/| /' conftest.$ac_ext >&5
13366
13367         ac_header_compiler=no
13368 fi
13369
13370 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13371 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13372 $as_echo "$ac_header_compiler" >&6; }
13373
13374 # Is the header present?
13375 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13376 $as_echo_n "checking $ac_header presence... " >&6; }
13377 cat >conftest.$ac_ext <<_ACEOF
13378 /* confdefs.h.  */
13379 _ACEOF
13380 cat confdefs.h >>conftest.$ac_ext
13381 cat >>conftest.$ac_ext <<_ACEOF
13382 /* end confdefs.h.  */
13383 #include <$ac_header>
13384 _ACEOF
13385 if { (ac_try="$ac_cpp conftest.$ac_ext"
13386 case "(($ac_try" in
13387   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13388   *) ac_try_echo=$ac_try;;
13389 esac
13390 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13391 $as_echo "$ac_try_echo") >&5
13392   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13393   ac_status=$?
13394   grep -v '^ *+' conftest.er1 >conftest.err
13395   rm -f conftest.er1
13396   cat conftest.err >&5
13397   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13398   (exit $ac_status); } >/dev/null && {
13399          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13400          test ! -s conftest.err
13401        }; then
13402   ac_header_preproc=yes
13403 else
13404   $as_echo "$as_me: failed program was:" >&5
13405 sed 's/^/| /' conftest.$ac_ext >&5
13406
13407   ac_header_preproc=no
13408 fi
13409
13410 rm -f conftest.err conftest.$ac_ext
13411 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13412 $as_echo "$ac_header_preproc" >&6; }
13413
13414 # So?  What about this header?
13415 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13416   yes:no: )
13417     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13418 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13419     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13420 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13421     ac_header_preproc=yes
13422     ;;
13423   no:yes:* )
13424     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13425 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13426     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13427 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13428     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13429 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13430     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13431 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13432     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13433 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13434     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13435 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13436     ( cat <<\_ASBOX
13437 ## ---------------------------------------- ##
13438 ## Report this to pgsql-bugs@postgresql.org ##
13439 ## ---------------------------------------- ##
13440 _ASBOX
13441      ) | sed "s/^/$as_me: WARNING:     /" >&2
13442     ;;
13443 esac
13444 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13445 $as_echo_n "checking for $ac_header... " >&6; }
13446 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13447   $as_echo_n "(cached) " >&6
13448 else
13449   eval "$as_ac_Header=\$ac_header_preproc"
13450 fi
13451 ac_res=`eval 'as_val=${'$as_ac_Header'}
13452                  $as_echo "$as_val"'`
13453                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13454 $as_echo "$ac_res" >&6; }
13455
13456 fi
13457 as_val=`eval 'as_val=${'$as_ac_Header'}
13458                  $as_echo "$as_val"'`
13459    if test "x$as_val" = x""yes; then
13460   cat >>confdefs.h <<_ACEOF
13461 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13462 _ACEOF
13463
13464 else
13465   { { $as_echo "$as_me:$LINENO: error: header file <ldap.h> is required for LDAP" >&5
13466 $as_echo "$as_me: error: header file <ldap.h> is required for LDAP" >&2;}
13467    { (exit 1); exit 1; }; }
13468 fi
13469
13470 done
13471
13472   else
13473
13474 for ac_header in winldap.h
13475 do
13476 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13477 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13478 $as_echo_n "checking for $ac_header... " >&6; }
13479 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13480   $as_echo_n "(cached) " >&6
13481 else
13482   cat >conftest.$ac_ext <<_ACEOF
13483 /* confdefs.h.  */
13484 _ACEOF
13485 cat confdefs.h >>conftest.$ac_ext
13486 cat >>conftest.$ac_ext <<_ACEOF
13487 /* end confdefs.h.  */
13488 $ac_includes_default
13489 #include <windows.h>
13490
13491
13492 #include <$ac_header>
13493 _ACEOF
13494 rm -f conftest.$ac_objext
13495 if { (ac_try="$ac_compile"
13496 case "(($ac_try" in
13497   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13498   *) ac_try_echo=$ac_try;;
13499 esac
13500 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13501 $as_echo "$ac_try_echo") >&5
13502   (eval "$ac_compile") 2>conftest.er1
13503   ac_status=$?
13504   grep -v '^ *+' conftest.er1 >conftest.err
13505   rm -f conftest.er1
13506   cat conftest.err >&5
13507   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13508   (exit $ac_status); } && {
13509          test -z "$ac_c_werror_flag" ||
13510          test ! -s conftest.err
13511        } && test -s conftest.$ac_objext; then
13512   eval "$as_ac_Header=yes"
13513 else
13514   $as_echo "$as_me: failed program was:" >&5
13515 sed 's/^/| /' conftest.$ac_ext >&5
13516
13517         eval "$as_ac_Header=no"
13518 fi
13519
13520 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13521 fi
13522 ac_res=`eval 'as_val=${'$as_ac_Header'}
13523                  $as_echo "$as_val"'`
13524                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13525 $as_echo "$ac_res" >&6; }
13526 as_val=`eval 'as_val=${'$as_ac_Header'}
13527                  $as_echo "$as_val"'`
13528    if test "x$as_val" = x""yes; then
13529   cat >>confdefs.h <<_ACEOF
13530 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13531 _ACEOF
13532
13533 else
13534   { { $as_echo "$as_me:$LINENO: error: header file <winldap.h> is required for LDAP" >&5
13535 $as_echo "$as_me: error: header file <winldap.h> is required for LDAP" >&2;}
13536    { (exit 1); exit 1; }; }
13537 fi
13538
13539 done
13540
13541   fi
13542 fi
13543
13544 if test "$with_bonjour" = yes ; then
13545   if test "${ac_cv_header_dns_sd_h+set}" = set; then
13546   { $as_echo "$as_me:$LINENO: checking for dns_sd.h" >&5
13547 $as_echo_n "checking for dns_sd.h... " >&6; }
13548 if test "${ac_cv_header_dns_sd_h+set}" = set; then
13549   $as_echo_n "(cached) " >&6
13550 fi
13551 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_dns_sd_h" >&5
13552 $as_echo "$ac_cv_header_dns_sd_h" >&6; }
13553 else
13554   # Is the header compilable?
13555 { $as_echo "$as_me:$LINENO: checking dns_sd.h usability" >&5
13556 $as_echo_n "checking dns_sd.h usability... " >&6; }
13557 cat >conftest.$ac_ext <<_ACEOF
13558 /* confdefs.h.  */
13559 _ACEOF
13560 cat confdefs.h >>conftest.$ac_ext
13561 cat >>conftest.$ac_ext <<_ACEOF
13562 /* end confdefs.h.  */
13563 $ac_includes_default
13564 #include <dns_sd.h>
13565 _ACEOF
13566 rm -f conftest.$ac_objext
13567 if { (ac_try="$ac_compile"
13568 case "(($ac_try" in
13569   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13570   *) ac_try_echo=$ac_try;;
13571 esac
13572 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13573 $as_echo "$ac_try_echo") >&5
13574   (eval "$ac_compile") 2>conftest.er1
13575   ac_status=$?
13576   grep -v '^ *+' conftest.er1 >conftest.err
13577   rm -f conftest.er1
13578   cat conftest.err >&5
13579   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13580   (exit $ac_status); } && {
13581          test -z "$ac_c_werror_flag" ||
13582          test ! -s conftest.err
13583        } && test -s conftest.$ac_objext; then
13584   ac_header_compiler=yes
13585 else
13586   $as_echo "$as_me: failed program was:" >&5
13587 sed 's/^/| /' conftest.$ac_ext >&5
13588
13589         ac_header_compiler=no
13590 fi
13591
13592 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13593 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13594 $as_echo "$ac_header_compiler" >&6; }
13595
13596 # Is the header present?
13597 { $as_echo "$as_me:$LINENO: checking dns_sd.h presence" >&5
13598 $as_echo_n "checking dns_sd.h presence... " >&6; }
13599 cat >conftest.$ac_ext <<_ACEOF
13600 /* confdefs.h.  */
13601 _ACEOF
13602 cat confdefs.h >>conftest.$ac_ext
13603 cat >>conftest.$ac_ext <<_ACEOF
13604 /* end confdefs.h.  */
13605 #include <dns_sd.h>
13606 _ACEOF
13607 if { (ac_try="$ac_cpp conftest.$ac_ext"
13608 case "(($ac_try" in
13609   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13610   *) ac_try_echo=$ac_try;;
13611 esac
13612 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13613 $as_echo "$ac_try_echo") >&5
13614   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13615   ac_status=$?
13616   grep -v '^ *+' conftest.er1 >conftest.err
13617   rm -f conftest.er1
13618   cat conftest.err >&5
13619   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13620   (exit $ac_status); } >/dev/null && {
13621          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13622          test ! -s conftest.err
13623        }; then
13624   ac_header_preproc=yes
13625 else
13626   $as_echo "$as_me: failed program was:" >&5
13627 sed 's/^/| /' conftest.$ac_ext >&5
13628
13629   ac_header_preproc=no
13630 fi
13631
13632 rm -f conftest.err conftest.$ac_ext
13633 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13634 $as_echo "$ac_header_preproc" >&6; }
13635
13636 # So?  What about this header?
13637 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13638   yes:no: )
13639     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: accepted by the compiler, rejected by the preprocessor!" >&5
13640 $as_echo "$as_me: WARNING: dns_sd.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
13641     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: proceeding with the compiler's result" >&5
13642 $as_echo "$as_me: WARNING: dns_sd.h: proceeding with the compiler's result" >&2;}
13643     ac_header_preproc=yes
13644     ;;
13645   no:yes:* )
13646     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: present but cannot be compiled" >&5
13647 $as_echo "$as_me: WARNING: dns_sd.h: present but cannot be compiled" >&2;}
13648     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h:     check for missing prerequisite headers?" >&5
13649 $as_echo "$as_me: WARNING: dns_sd.h:     check for missing prerequisite headers?" >&2;}
13650     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: see the Autoconf documentation" >&5
13651 $as_echo "$as_me: WARNING: dns_sd.h: see the Autoconf documentation" >&2;}
13652     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h:     section \"Present But Cannot Be Compiled\"" >&5
13653 $as_echo "$as_me: WARNING: dns_sd.h:     section \"Present But Cannot Be Compiled\"" >&2;}
13654     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: proceeding with the preprocessor's result" >&5
13655 $as_echo "$as_me: WARNING: dns_sd.h: proceeding with the preprocessor's result" >&2;}
13656     { $as_echo "$as_me:$LINENO: WARNING: dns_sd.h: in the future, the compiler will take precedence" >&5
13657 $as_echo "$as_me: WARNING: dns_sd.h: in the future, the compiler will take precedence" >&2;}
13658     ( cat <<\_ASBOX
13659 ## ---------------------------------------- ##
13660 ## Report this to pgsql-bugs@postgresql.org ##
13661 ## ---------------------------------------- ##
13662 _ASBOX
13663      ) | sed "s/^/$as_me: WARNING:     /" >&2
13664     ;;
13665 esac
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 else
13671   ac_cv_header_dns_sd_h=$ac_header_preproc
13672 fi
13673 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_dns_sd_h" >&5
13674 $as_echo "$ac_cv_header_dns_sd_h" >&6; }
13675
13676 fi
13677 if test "x$ac_cv_header_dns_sd_h" = x""yes; then
13678   :
13679 else
13680   { { $as_echo "$as_me:$LINENO: error: header file <dns_sd.h> is required for Bonjour" >&5
13681 $as_echo "$as_me: error: header file <dns_sd.h> is required for Bonjour" >&2;}
13682    { (exit 1); exit 1; }; }
13683 fi
13684
13685
13686 fi
13687
13688 # for contrib/uuid-ossp
13689 if test "$with_ossp_uuid" = yes ; then
13690
13691 for ac_header in ossp/uuid.h
13692 do
13693 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13694 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13695   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13696 $as_echo_n "checking for $ac_header... " >&6; }
13697 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13698   $as_echo_n "(cached) " >&6
13699 fi
13700 ac_res=`eval 'as_val=${'$as_ac_Header'}
13701                  $as_echo "$as_val"'`
13702                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13703 $as_echo "$ac_res" >&6; }
13704 else
13705   # Is the header compilable?
13706 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13707 $as_echo_n "checking $ac_header usability... " >&6; }
13708 cat >conftest.$ac_ext <<_ACEOF
13709 /* confdefs.h.  */
13710 _ACEOF
13711 cat confdefs.h >>conftest.$ac_ext
13712 cat >>conftest.$ac_ext <<_ACEOF
13713 /* end confdefs.h.  */
13714 $ac_includes_default
13715 #include <$ac_header>
13716 _ACEOF
13717 rm -f conftest.$ac_objext
13718 if { (ac_try="$ac_compile"
13719 case "(($ac_try" in
13720   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13721   *) ac_try_echo=$ac_try;;
13722 esac
13723 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13724 $as_echo "$ac_try_echo") >&5
13725   (eval "$ac_compile") 2>conftest.er1
13726   ac_status=$?
13727   grep -v '^ *+' conftest.er1 >conftest.err
13728   rm -f conftest.er1
13729   cat conftest.err >&5
13730   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13731   (exit $ac_status); } && {
13732          test -z "$ac_c_werror_flag" ||
13733          test ! -s conftest.err
13734        } && test -s conftest.$ac_objext; then
13735   ac_header_compiler=yes
13736 else
13737   $as_echo "$as_me: failed program was:" >&5
13738 sed 's/^/| /' conftest.$ac_ext >&5
13739
13740         ac_header_compiler=no
13741 fi
13742
13743 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13744 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13745 $as_echo "$ac_header_compiler" >&6; }
13746
13747 # Is the header present?
13748 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13749 $as_echo_n "checking $ac_header presence... " >&6; }
13750 cat >conftest.$ac_ext <<_ACEOF
13751 /* confdefs.h.  */
13752 _ACEOF
13753 cat confdefs.h >>conftest.$ac_ext
13754 cat >>conftest.$ac_ext <<_ACEOF
13755 /* end confdefs.h.  */
13756 #include <$ac_header>
13757 _ACEOF
13758 if { (ac_try="$ac_cpp conftest.$ac_ext"
13759 case "(($ac_try" in
13760   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13761   *) ac_try_echo=$ac_try;;
13762 esac
13763 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13764 $as_echo "$ac_try_echo") >&5
13765   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13766   ac_status=$?
13767   grep -v '^ *+' conftest.er1 >conftest.err
13768   rm -f conftest.er1
13769   cat conftest.err >&5
13770   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13771   (exit $ac_status); } >/dev/null && {
13772          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13773          test ! -s conftest.err
13774        }; then
13775   ac_header_preproc=yes
13776 else
13777   $as_echo "$as_me: failed program was:" >&5
13778 sed 's/^/| /' conftest.$ac_ext >&5
13779
13780   ac_header_preproc=no
13781 fi
13782
13783 rm -f conftest.err conftest.$ac_ext
13784 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13785 $as_echo "$ac_header_preproc" >&6; }
13786
13787 # So?  What about this header?
13788 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13789   yes:no: )
13790     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13791 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13792     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13793 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13794     ac_header_preproc=yes
13795     ;;
13796   no:yes:* )
13797     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13798 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13799     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13800 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13801     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13802 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13803     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13804 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13805     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13806 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13807     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13808 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13809     ( cat <<\_ASBOX
13810 ## ---------------------------------------- ##
13811 ## Report this to pgsql-bugs@postgresql.org ##
13812 ## ---------------------------------------- ##
13813 _ASBOX
13814      ) | sed "s/^/$as_me: WARNING:     /" >&2
13815     ;;
13816 esac
13817 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13818 $as_echo_n "checking for $ac_header... " >&6; }
13819 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13820   $as_echo_n "(cached) " >&6
13821 else
13822   eval "$as_ac_Header=\$ac_header_preproc"
13823 fi
13824 ac_res=`eval 'as_val=${'$as_ac_Header'}
13825                  $as_echo "$as_val"'`
13826                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13827 $as_echo "$ac_res" >&6; }
13828
13829 fi
13830 as_val=`eval 'as_val=${'$as_ac_Header'}
13831                  $as_echo "$as_val"'`
13832    if test "x$as_val" = x""yes; then
13833   cat >>confdefs.h <<_ACEOF
13834 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13835 _ACEOF
13836
13837 else
13838
13839
13840 for ac_header in uuid.h
13841 do
13842 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
13843 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13844   { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13845 $as_echo_n "checking for $ac_header... " >&6; }
13846 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13847   $as_echo_n "(cached) " >&6
13848 fi
13849 ac_res=`eval 'as_val=${'$as_ac_Header'}
13850                  $as_echo "$as_val"'`
13851                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13852 $as_echo "$ac_res" >&6; }
13853 else
13854   # Is the header compilable?
13855 { $as_echo "$as_me:$LINENO: checking $ac_header usability" >&5
13856 $as_echo_n "checking $ac_header usability... " >&6; }
13857 cat >conftest.$ac_ext <<_ACEOF
13858 /* confdefs.h.  */
13859 _ACEOF
13860 cat confdefs.h >>conftest.$ac_ext
13861 cat >>conftest.$ac_ext <<_ACEOF
13862 /* end confdefs.h.  */
13863 $ac_includes_default
13864 #include <$ac_header>
13865 _ACEOF
13866 rm -f conftest.$ac_objext
13867 if { (ac_try="$ac_compile"
13868 case "(($ac_try" in
13869   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13870   *) ac_try_echo=$ac_try;;
13871 esac
13872 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13873 $as_echo "$ac_try_echo") >&5
13874   (eval "$ac_compile") 2>conftest.er1
13875   ac_status=$?
13876   grep -v '^ *+' conftest.er1 >conftest.err
13877   rm -f conftest.er1
13878   cat conftest.err >&5
13879   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13880   (exit $ac_status); } && {
13881          test -z "$ac_c_werror_flag" ||
13882          test ! -s conftest.err
13883        } && test -s conftest.$ac_objext; then
13884   ac_header_compiler=yes
13885 else
13886   $as_echo "$as_me: failed program was:" >&5
13887 sed 's/^/| /' conftest.$ac_ext >&5
13888
13889         ac_header_compiler=no
13890 fi
13891
13892 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
13893 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
13894 $as_echo "$ac_header_compiler" >&6; }
13895
13896 # Is the header present?
13897 { $as_echo "$as_me:$LINENO: checking $ac_header presence" >&5
13898 $as_echo_n "checking $ac_header presence... " >&6; }
13899 cat >conftest.$ac_ext <<_ACEOF
13900 /* confdefs.h.  */
13901 _ACEOF
13902 cat confdefs.h >>conftest.$ac_ext
13903 cat >>conftest.$ac_ext <<_ACEOF
13904 /* end confdefs.h.  */
13905 #include <$ac_header>
13906 _ACEOF
13907 if { (ac_try="$ac_cpp conftest.$ac_ext"
13908 case "(($ac_try" in
13909   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
13910   *) ac_try_echo=$ac_try;;
13911 esac
13912 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
13913 $as_echo "$ac_try_echo") >&5
13914   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
13915   ac_status=$?
13916   grep -v '^ *+' conftest.er1 >conftest.err
13917   rm -f conftest.er1
13918   cat conftest.err >&5
13919   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
13920   (exit $ac_status); } >/dev/null && {
13921          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
13922          test ! -s conftest.err
13923        }; then
13924   ac_header_preproc=yes
13925 else
13926   $as_echo "$as_me: failed program was:" >&5
13927 sed 's/^/| /' conftest.$ac_ext >&5
13928
13929   ac_header_preproc=no
13930 fi
13931
13932 rm -f conftest.err conftest.$ac_ext
13933 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
13934 $as_echo "$ac_header_preproc" >&6; }
13935
13936 # So?  What about this header?
13937 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
13938   yes:no: )
13939     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
13940 $as_echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
13941     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
13942 $as_echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
13943     ac_header_preproc=yes
13944     ;;
13945   no:yes:* )
13946     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
13947 $as_echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
13948     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     check for missing prerequisite headers?" >&5
13949 $as_echo "$as_me: WARNING: $ac_header:     check for missing prerequisite headers?" >&2;}
13950     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
13951 $as_echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
13952     { $as_echo "$as_me:$LINENO: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&5
13953 $as_echo "$as_me: WARNING: $ac_header:     section \"Present But Cannot Be Compiled\"" >&2;}
13954     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
13955 $as_echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
13956     { $as_echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
13957 $as_echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
13958     ( cat <<\_ASBOX
13959 ## ---------------------------------------- ##
13960 ## Report this to pgsql-bugs@postgresql.org ##
13961 ## ---------------------------------------- ##
13962 _ASBOX
13963      ) | sed "s/^/$as_me: WARNING:     /" >&2
13964     ;;
13965 esac
13966 { $as_echo "$as_me:$LINENO: checking for $ac_header" >&5
13967 $as_echo_n "checking for $ac_header... " >&6; }
13968 if { as_var=$as_ac_Header; eval "test \"\${$as_var+set}\" = set"; }; then
13969   $as_echo_n "(cached) " >&6
13970 else
13971   eval "$as_ac_Header=\$ac_header_preproc"
13972 fi
13973 ac_res=`eval 'as_val=${'$as_ac_Header'}
13974                  $as_echo "$as_val"'`
13975                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
13976 $as_echo "$ac_res" >&6; }
13977
13978 fi
13979 as_val=`eval 'as_val=${'$as_ac_Header'}
13980                  $as_echo "$as_val"'`
13981    if test "x$as_val" = x""yes; then
13982   cat >>confdefs.h <<_ACEOF
13983 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
13984 _ACEOF
13985
13986 else
13987   { { $as_echo "$as_me:$LINENO: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&5
13988 $as_echo "$as_me: error: header file <ossp/uuid.h> or <uuid.h> is required for OSSP-UUID" >&2;}
13989    { (exit 1); exit 1; }; }
13990 fi
13991
13992 done
13993
13994 fi
13995
13996 done
13997
13998 fi
13999
14000
14001 ##
14002 ## Types, structures, compiler characteristics
14003 ##
14004
14005
14006  { $as_echo "$as_me:$LINENO: checking whether byte ordering is bigendian" >&5
14007 $as_echo_n "checking whether byte ordering is bigendian... " >&6; }
14008 if test "${ac_cv_c_bigendian+set}" = set; then
14009   $as_echo_n "(cached) " >&6
14010 else
14011   ac_cv_c_bigendian=unknown
14012     # See if we're dealing with a universal compiler.
14013     cat >conftest.$ac_ext <<_ACEOF
14014 /* confdefs.h.  */
14015 _ACEOF
14016 cat confdefs.h >>conftest.$ac_ext
14017 cat >>conftest.$ac_ext <<_ACEOF
14018 /* end confdefs.h.  */
14019 #ifndef __APPLE_CC__
14020                not a universal capable compiler
14021              #endif
14022              typedef int dummy;
14023
14024 _ACEOF
14025 rm -f conftest.$ac_objext
14026 if { (ac_try="$ac_compile"
14027 case "(($ac_try" in
14028   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14029   *) ac_try_echo=$ac_try;;
14030 esac
14031 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14032 $as_echo "$ac_try_echo") >&5
14033   (eval "$ac_compile") 2>conftest.er1
14034   ac_status=$?
14035   grep -v '^ *+' conftest.er1 >conftest.err
14036   rm -f conftest.er1
14037   cat conftest.err >&5
14038   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14039   (exit $ac_status); } && {
14040          test -z "$ac_c_werror_flag" ||
14041          test ! -s conftest.err
14042        } && test -s conftest.$ac_objext; then
14043
14044         # Check for potential -arch flags.  It is not universal unless
14045         # there are some -arch flags.  Note that *ppc* also matches
14046         # ppc64.  This check is also rather less than ideal.
14047         case "${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS}" in  #(
14048           *-arch*ppc*|*-arch*i386*|*-arch*x86_64*) ac_cv_c_bigendian=universal;;
14049         esac
14050 else
14051   $as_echo "$as_me: failed program was:" >&5
14052 sed 's/^/| /' conftest.$ac_ext >&5
14053
14054
14055 fi
14056
14057 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14058     if test $ac_cv_c_bigendian = unknown; then
14059       # See if sys/param.h defines the BYTE_ORDER macro.
14060       cat >conftest.$ac_ext <<_ACEOF
14061 /* confdefs.h.  */
14062 _ACEOF
14063 cat confdefs.h >>conftest.$ac_ext
14064 cat >>conftest.$ac_ext <<_ACEOF
14065 /* end confdefs.h.  */
14066 #include <sys/types.h>
14067              #include <sys/param.h>
14068
14069 int
14070 main ()
14071 {
14072 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \
14073                      && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \
14074                      && LITTLE_ENDIAN)
14075               bogus endian macros
14076              #endif
14077
14078   ;
14079   return 0;
14080 }
14081 _ACEOF
14082 rm -f conftest.$ac_objext
14083 if { (ac_try="$ac_compile"
14084 case "(($ac_try" in
14085   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14086   *) ac_try_echo=$ac_try;;
14087 esac
14088 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14089 $as_echo "$ac_try_echo") >&5
14090   (eval "$ac_compile") 2>conftest.er1
14091   ac_status=$?
14092   grep -v '^ *+' conftest.er1 >conftest.err
14093   rm -f conftest.er1
14094   cat conftest.err >&5
14095   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14096   (exit $ac_status); } && {
14097          test -z "$ac_c_werror_flag" ||
14098          test ! -s conftest.err
14099        } && test -s conftest.$ac_objext; then
14100   # It does; now see whether it defined to BIG_ENDIAN or not.
14101          cat >conftest.$ac_ext <<_ACEOF
14102 /* confdefs.h.  */
14103 _ACEOF
14104 cat confdefs.h >>conftest.$ac_ext
14105 cat >>conftest.$ac_ext <<_ACEOF
14106 /* end confdefs.h.  */
14107 #include <sys/types.h>
14108                 #include <sys/param.h>
14109
14110 int
14111 main ()
14112 {
14113 #if BYTE_ORDER != BIG_ENDIAN
14114                  not big endian
14115                 #endif
14116
14117   ;
14118   return 0;
14119 }
14120 _ACEOF
14121 rm -f conftest.$ac_objext
14122 if { (ac_try="$ac_compile"
14123 case "(($ac_try" in
14124   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14125   *) ac_try_echo=$ac_try;;
14126 esac
14127 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14128 $as_echo "$ac_try_echo") >&5
14129   (eval "$ac_compile") 2>conftest.er1
14130   ac_status=$?
14131   grep -v '^ *+' conftest.er1 >conftest.err
14132   rm -f conftest.er1
14133   cat conftest.err >&5
14134   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14135   (exit $ac_status); } && {
14136          test -z "$ac_c_werror_flag" ||
14137          test ! -s conftest.err
14138        } && test -s conftest.$ac_objext; then
14139   ac_cv_c_bigendian=yes
14140 else
14141   $as_echo "$as_me: failed program was:" >&5
14142 sed 's/^/| /' conftest.$ac_ext >&5
14143
14144         ac_cv_c_bigendian=no
14145 fi
14146
14147 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14148 else
14149   $as_echo "$as_me: failed program was:" >&5
14150 sed 's/^/| /' conftest.$ac_ext >&5
14151
14152
14153 fi
14154
14155 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14156     fi
14157     if test $ac_cv_c_bigendian = unknown; then
14158       # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris).
14159       cat >conftest.$ac_ext <<_ACEOF
14160 /* confdefs.h.  */
14161 _ACEOF
14162 cat confdefs.h >>conftest.$ac_ext
14163 cat >>conftest.$ac_ext <<_ACEOF
14164 /* end confdefs.h.  */
14165 #include <limits.h>
14166
14167 int
14168 main ()
14169 {
14170 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN)
14171               bogus endian macros
14172              #endif
14173
14174   ;
14175   return 0;
14176 }
14177 _ACEOF
14178 rm -f conftest.$ac_objext
14179 if { (ac_try="$ac_compile"
14180 case "(($ac_try" in
14181   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14182   *) ac_try_echo=$ac_try;;
14183 esac
14184 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14185 $as_echo "$ac_try_echo") >&5
14186   (eval "$ac_compile") 2>conftest.er1
14187   ac_status=$?
14188   grep -v '^ *+' conftest.er1 >conftest.err
14189   rm -f conftest.er1
14190   cat conftest.err >&5
14191   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14192   (exit $ac_status); } && {
14193          test -z "$ac_c_werror_flag" ||
14194          test ! -s conftest.err
14195        } && test -s conftest.$ac_objext; then
14196   # It does; now see whether it defined to _BIG_ENDIAN or not.
14197          cat >conftest.$ac_ext <<_ACEOF
14198 /* confdefs.h.  */
14199 _ACEOF
14200 cat confdefs.h >>conftest.$ac_ext
14201 cat >>conftest.$ac_ext <<_ACEOF
14202 /* end confdefs.h.  */
14203 #include <limits.h>
14204
14205 int
14206 main ()
14207 {
14208 #ifndef _BIG_ENDIAN
14209                  not big endian
14210                 #endif
14211
14212   ;
14213   return 0;
14214 }
14215 _ACEOF
14216 rm -f conftest.$ac_objext
14217 if { (ac_try="$ac_compile"
14218 case "(($ac_try" in
14219   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14220   *) ac_try_echo=$ac_try;;
14221 esac
14222 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14223 $as_echo "$ac_try_echo") >&5
14224   (eval "$ac_compile") 2>conftest.er1
14225   ac_status=$?
14226   grep -v '^ *+' conftest.er1 >conftest.err
14227   rm -f conftest.er1
14228   cat conftest.err >&5
14229   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14230   (exit $ac_status); } && {
14231          test -z "$ac_c_werror_flag" ||
14232          test ! -s conftest.err
14233        } && test -s conftest.$ac_objext; then
14234   ac_cv_c_bigendian=yes
14235 else
14236   $as_echo "$as_me: failed program was:" >&5
14237 sed 's/^/| /' conftest.$ac_ext >&5
14238
14239         ac_cv_c_bigendian=no
14240 fi
14241
14242 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14243 else
14244   $as_echo "$as_me: failed program was:" >&5
14245 sed 's/^/| /' conftest.$ac_ext >&5
14246
14247
14248 fi
14249
14250 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14251     fi
14252     if test $ac_cv_c_bigendian = unknown; then
14253       # Compile a test program.
14254       if test "$cross_compiling" = yes; then
14255   # Try to guess by grepping values from an object file.
14256          cat >conftest.$ac_ext <<_ACEOF
14257 /* confdefs.h.  */
14258 _ACEOF
14259 cat confdefs.h >>conftest.$ac_ext
14260 cat >>conftest.$ac_ext <<_ACEOF
14261 /* end confdefs.h.  */
14262 short int ascii_mm[] =
14263                   { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 };
14264                 short int ascii_ii[] =
14265                   { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 };
14266                 int use_ascii (int i) {
14267                   return ascii_mm[i] + ascii_ii[i];
14268                 }
14269                 short int ebcdic_ii[] =
14270                   { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 };
14271                 short int ebcdic_mm[] =
14272                   { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 };
14273                 int use_ebcdic (int i) {
14274                   return ebcdic_mm[i] + ebcdic_ii[i];
14275                 }
14276                 extern int foo;
14277
14278 int
14279 main ()
14280 {
14281 return use_ascii (foo) == use_ebcdic (foo);
14282   ;
14283   return 0;
14284 }
14285 _ACEOF
14286 rm -f conftest.$ac_objext
14287 if { (ac_try="$ac_compile"
14288 case "(($ac_try" in
14289   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14290   *) ac_try_echo=$ac_try;;
14291 esac
14292 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14293 $as_echo "$ac_try_echo") >&5
14294   (eval "$ac_compile") 2>conftest.er1
14295   ac_status=$?
14296   grep -v '^ *+' conftest.er1 >conftest.err
14297   rm -f conftest.er1
14298   cat conftest.err >&5
14299   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14300   (exit $ac_status); } && {
14301          test -z "$ac_c_werror_flag" ||
14302          test ! -s conftest.err
14303        } && test -s conftest.$ac_objext; then
14304   if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then
14305               ac_cv_c_bigendian=yes
14306             fi
14307             if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then
14308               if test "$ac_cv_c_bigendian" = unknown; then
14309                 ac_cv_c_bigendian=no
14310               else
14311                 # finding both strings is unlikely to happen, but who knows?
14312                 ac_cv_c_bigendian=unknown
14313               fi
14314             fi
14315 else
14316   $as_echo "$as_me: failed program was:" >&5
14317 sed 's/^/| /' conftest.$ac_ext >&5
14318
14319
14320 fi
14321
14322 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14323 else
14324   cat >conftest.$ac_ext <<_ACEOF
14325 /* confdefs.h.  */
14326 _ACEOF
14327 cat confdefs.h >>conftest.$ac_ext
14328 cat >>conftest.$ac_ext <<_ACEOF
14329 /* end confdefs.h.  */
14330 $ac_includes_default
14331 int
14332 main ()
14333 {
14334
14335              /* Are we little or big endian?  From Harbison&Steele.  */
14336              union
14337              {
14338                long int l;
14339                char c[sizeof (long int)];
14340              } u;
14341              u.l = 1;
14342              return u.c[sizeof (long int) - 1] == 1;
14343
14344   ;
14345   return 0;
14346 }
14347 _ACEOF
14348 rm -f conftest$ac_exeext
14349 if { (ac_try="$ac_link"
14350 case "(($ac_try" in
14351   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14352   *) ac_try_echo=$ac_try;;
14353 esac
14354 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14355 $as_echo "$ac_try_echo") >&5
14356   (eval "$ac_link") 2>&5
14357   ac_status=$?
14358   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14359   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
14360   { (case "(($ac_try" in
14361   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14362   *) ac_try_echo=$ac_try;;
14363 esac
14364 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14365 $as_echo "$ac_try_echo") >&5
14366   (eval "$ac_try") 2>&5
14367   ac_status=$?
14368   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14369   (exit $ac_status); }; }; then
14370   ac_cv_c_bigendian=no
14371 else
14372   $as_echo "$as_me: program exited with status $ac_status" >&5
14373 $as_echo "$as_me: failed program was:" >&5
14374 sed 's/^/| /' conftest.$ac_ext >&5
14375
14376 ( exit $ac_status )
14377 ac_cv_c_bigendian=yes
14378 fi
14379 rm -rf conftest.dSYM
14380 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
14381 fi
14382
14383
14384     fi
14385 fi
14386 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_bigendian" >&5
14387 $as_echo "$ac_cv_c_bigendian" >&6; }
14388  case $ac_cv_c_bigendian in #(
14389    yes)
14390      cat >>confdefs.h <<\_ACEOF
14391 #define WORDS_BIGENDIAN 1
14392 _ACEOF
14393 ;; #(
14394    no)
14395       ;; #(
14396    universal)
14397
14398 cat >>confdefs.h <<\_ACEOF
14399 #define AC_APPLE_UNIVERSAL_BUILD 1
14400 _ACEOF
14401
14402      ;; #(
14403    *)
14404      { { $as_echo "$as_me:$LINENO: error: unknown endianness
14405  presetting ac_cv_c_bigendian=no (or yes) will help" >&5
14406 $as_echo "$as_me: error: unknown endianness
14407  presetting ac_cv_c_bigendian=no (or yes) will help" >&2;}
14408    { (exit 1); exit 1; }; } ;;
14409  esac
14410
14411 { $as_echo "$as_me:$LINENO: checking for an ANSI C-conforming const" >&5
14412 $as_echo_n "checking for an ANSI C-conforming const... " >&6; }
14413 if test "${ac_cv_c_const+set}" = set; then
14414   $as_echo_n "(cached) " >&6
14415 else
14416   cat >conftest.$ac_ext <<_ACEOF
14417 /* confdefs.h.  */
14418 _ACEOF
14419 cat confdefs.h >>conftest.$ac_ext
14420 cat >>conftest.$ac_ext <<_ACEOF
14421 /* end confdefs.h.  */
14422
14423 int
14424 main ()
14425 {
14426 /* FIXME: Include the comments suggested by Paul. */
14427 #ifndef __cplusplus
14428   /* Ultrix mips cc rejects this.  */
14429   typedef int charset[2];
14430   const charset cs;
14431   /* SunOS 4.1.1 cc rejects this.  */
14432   char const *const *pcpcc;
14433   char **ppc;
14434   /* NEC SVR4.0.2 mips cc rejects this.  */
14435   struct point {int x, y;};
14436   static struct point const zero = {0,0};
14437   /* AIX XL C 1.02.0.0 rejects this.
14438      It does not let you subtract one const X* pointer from another in
14439      an arm of an if-expression whose if-part is not a constant
14440      expression */
14441   const char *g = "string";
14442   pcpcc = &g + (g ? g-g : 0);
14443   /* HPUX 7.0 cc rejects these. */
14444   ++pcpcc;
14445   ppc = (char**) pcpcc;
14446   pcpcc = (char const *const *) ppc;
14447   { /* SCO 3.2v4 cc rejects this.  */
14448     char *t;
14449     char const *s = 0 ? (char *) 0 : (char const *) 0;
14450
14451     *t++ = 0;
14452     if (s) return 0;
14453   }
14454   { /* Someone thinks the Sun supposedly-ANSI compiler will reject this.  */
14455     int x[] = {25, 17};
14456     const int *foo = &x[0];
14457     ++foo;
14458   }
14459   { /* Sun SC1.0 ANSI compiler rejects this -- but not the above. */
14460     typedef const int *iptr;
14461     iptr p = 0;
14462     ++p;
14463   }
14464   { /* AIX XL C 1.02.0.0 rejects this saying
14465        "k.c", line 2.27: 1506-025 (S) Operand must be a modifiable lvalue. */
14466     struct s { int j; const int *ap[3]; };
14467     struct s *b; b->j = 5;
14468   }
14469   { /* ULTRIX-32 V3.1 (Rev 9) vcc rejects this */
14470     const int foo = 10;
14471     if (!foo) return 0;
14472   }
14473   return !cs[0] && !zero.x;
14474 #endif
14475
14476   ;
14477   return 0;
14478 }
14479 _ACEOF
14480 rm -f conftest.$ac_objext
14481 if { (ac_try="$ac_compile"
14482 case "(($ac_try" in
14483   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14484   *) ac_try_echo=$ac_try;;
14485 esac
14486 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14487 $as_echo "$ac_try_echo") >&5
14488   (eval "$ac_compile") 2>conftest.er1
14489   ac_status=$?
14490   grep -v '^ *+' conftest.er1 >conftest.err
14491   rm -f conftest.er1
14492   cat conftest.err >&5
14493   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14494   (exit $ac_status); } && {
14495          test -z "$ac_c_werror_flag" ||
14496          test ! -s conftest.err
14497        } && test -s conftest.$ac_objext; then
14498   ac_cv_c_const=yes
14499 else
14500   $as_echo "$as_me: failed program was:" >&5
14501 sed 's/^/| /' conftest.$ac_ext >&5
14502
14503         ac_cv_c_const=no
14504 fi
14505
14506 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14507 fi
14508 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_const" >&5
14509 $as_echo "$ac_cv_c_const" >&6; }
14510 if test $ac_cv_c_const = no; then
14511
14512 cat >>confdefs.h <<\_ACEOF
14513 #define const /**/
14514 _ACEOF
14515
14516 fi
14517
14518 { $as_echo "$as_me:$LINENO: checking for inline" >&5
14519 $as_echo_n "checking for inline... " >&6; }
14520 if test "${ac_cv_c_inline+set}" = set; then
14521   $as_echo_n "(cached) " >&6
14522 else
14523   ac_cv_c_inline=no
14524 for ac_kw in inline __inline__ __inline; do
14525   cat >conftest.$ac_ext <<_ACEOF
14526 /* confdefs.h.  */
14527 _ACEOF
14528 cat confdefs.h >>conftest.$ac_ext
14529 cat >>conftest.$ac_ext <<_ACEOF
14530 /* end confdefs.h.  */
14531 #ifndef __cplusplus
14532 typedef int foo_t;
14533 static $ac_kw foo_t static_foo () {return 0; }
14534 $ac_kw foo_t foo () {return 0; }
14535 #endif
14536
14537 _ACEOF
14538 rm -f conftest.$ac_objext
14539 if { (ac_try="$ac_compile"
14540 case "(($ac_try" in
14541   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14542   *) ac_try_echo=$ac_try;;
14543 esac
14544 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14545 $as_echo "$ac_try_echo") >&5
14546   (eval "$ac_compile") 2>conftest.er1
14547   ac_status=$?
14548   grep -v '^ *+' conftest.er1 >conftest.err
14549   rm -f conftest.er1
14550   cat conftest.err >&5
14551   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14552   (exit $ac_status); } && {
14553          test -z "$ac_c_werror_flag" ||
14554          test ! -s conftest.err
14555        } && test -s conftest.$ac_objext; then
14556   ac_cv_c_inline=$ac_kw
14557 else
14558   $as_echo "$as_me: failed program was:" >&5
14559 sed 's/^/| /' conftest.$ac_ext >&5
14560
14561
14562 fi
14563
14564 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14565   test "$ac_cv_c_inline" != no && break
14566 done
14567
14568 fi
14569 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_inline" >&5
14570 $as_echo "$ac_cv_c_inline" >&6; }
14571
14572
14573 case $ac_cv_c_inline in
14574   inline | yes) ;;
14575   *)
14576     case $ac_cv_c_inline in
14577       no) ac_val=;;
14578       *) ac_val=$ac_cv_c_inline;;
14579     esac
14580     cat >>confdefs.h <<_ACEOF
14581 #ifndef __cplusplus
14582 #define inline $ac_val
14583 #endif
14584 _ACEOF
14585     ;;
14586 esac
14587
14588 { $as_echo "$as_me:$LINENO: checking for quiet inline (no complaint if unreferenced)" >&5
14589 $as_echo_n "checking for quiet inline (no complaint if unreferenced)... " >&6; }
14590 if test "${pgac_cv_c_inline_quietly+set}" = set; then
14591   $as_echo_n "(cached) " >&6
14592 else
14593   pgac_cv_c_inline_quietly=no
14594   if test "$ac_cv_c_inline" != no; then
14595     pgac_c_inline_save_werror=$ac_c_werror_flag
14596     ac_c_werror_flag=yes
14597     cat >conftest.$ac_ext <<_ACEOF
14598 /* confdefs.h.  */
14599 _ACEOF
14600 cat confdefs.h >>conftest.$ac_ext
14601 cat >>conftest.$ac_ext <<_ACEOF
14602 /* end confdefs.h.  */
14603 static inline int fun () {return 0;}
14604 int
14605 main ()
14606 {
14607
14608   ;
14609   return 0;
14610 }
14611 _ACEOF
14612 rm -f conftest.$ac_objext conftest$ac_exeext
14613 if { (ac_try="$ac_link"
14614 case "(($ac_try" in
14615   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14616   *) ac_try_echo=$ac_try;;
14617 esac
14618 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14619 $as_echo "$ac_try_echo") >&5
14620   (eval "$ac_link") 2>conftest.er1
14621   ac_status=$?
14622   grep -v '^ *+' conftest.er1 >conftest.err
14623   rm -f conftest.er1
14624   cat conftest.err >&5
14625   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14626   (exit $ac_status); } && {
14627          test -z "$ac_c_werror_flag" ||
14628          test ! -s conftest.err
14629        } && test -s conftest$ac_exeext && {
14630          test "$cross_compiling" = yes ||
14631          $as_test_x conftest$ac_exeext
14632        }; then
14633   pgac_cv_c_inline_quietly=yes
14634 else
14635   $as_echo "$as_me: failed program was:" >&5
14636 sed 's/^/| /' conftest.$ac_ext >&5
14637
14638
14639 fi
14640
14641 rm -rf conftest.dSYM
14642 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
14643       conftest$ac_exeext conftest.$ac_ext
14644     ac_c_werror_flag=$pgac_c_inline_save_werror
14645   fi
14646 fi
14647 { $as_echo "$as_me:$LINENO: result: $pgac_cv_c_inline_quietly" >&5
14648 $as_echo "$pgac_cv_c_inline_quietly" >&6; }
14649 if test "$pgac_cv_c_inline_quietly" != no; then
14650
14651 cat >>confdefs.h <<_ACEOF
14652 #define USE_INLINE 1
14653 _ACEOF
14654
14655 fi
14656
14657 { $as_echo "$as_me:$LINENO: checking for preprocessor stringizing operator" >&5
14658 $as_echo_n "checking for preprocessor stringizing operator... " >&6; }
14659 if test "${ac_cv_c_stringize+set}" = set; then
14660   $as_echo_n "(cached) " >&6
14661 else
14662   cat >conftest.$ac_ext <<_ACEOF
14663 /* confdefs.h.  */
14664 _ACEOF
14665 cat confdefs.h >>conftest.$ac_ext
14666 cat >>conftest.$ac_ext <<_ACEOF
14667 /* end confdefs.h.  */
14668 #define x(y) #y
14669
14670 char *s = x(teststring);
14671 _ACEOF
14672 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 |
14673   $EGREP "#teststring" >/dev/null 2>&1; then
14674   ac_cv_c_stringize=no
14675 else
14676   ac_cv_c_stringize=yes
14677 fi
14678 rm -f conftest*
14679
14680 fi
14681 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_stringize" >&5
14682 $as_echo "$ac_cv_c_stringize" >&6; }
14683 if test $ac_cv_c_stringize = yes; then
14684
14685 cat >>confdefs.h <<\_ACEOF
14686 #define HAVE_STRINGIZE 1
14687 _ACEOF
14688
14689 fi
14690
14691 { $as_echo "$as_me:$LINENO: checking for signed types" >&5
14692 $as_echo_n "checking for signed types... " >&6; }
14693 if test "${pgac_cv_c_signed+set}" = set; then
14694   $as_echo_n "(cached) " >&6
14695 else
14696   cat >conftest.$ac_ext <<_ACEOF
14697 /* confdefs.h.  */
14698 _ACEOF
14699 cat confdefs.h >>conftest.$ac_ext
14700 cat >>conftest.$ac_ext <<_ACEOF
14701 /* end confdefs.h.  */
14702
14703 int
14704 main ()
14705 {
14706 signed char c; signed short s; signed int i;
14707   ;
14708   return 0;
14709 }
14710 _ACEOF
14711 rm -f conftest.$ac_objext
14712 if { (ac_try="$ac_compile"
14713 case "(($ac_try" in
14714   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14715   *) ac_try_echo=$ac_try;;
14716 esac
14717 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14718 $as_echo "$ac_try_echo") >&5
14719   (eval "$ac_compile") 2>conftest.er1
14720   ac_status=$?
14721   grep -v '^ *+' conftest.er1 >conftest.err
14722   rm -f conftest.er1
14723   cat conftest.err >&5
14724   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14725   (exit $ac_status); } && {
14726          test -z "$ac_c_werror_flag" ||
14727          test ! -s conftest.err
14728        } && test -s conftest.$ac_objext; then
14729   pgac_cv_c_signed=yes
14730 else
14731   $as_echo "$as_me: failed program was:" >&5
14732 sed 's/^/| /' conftest.$ac_ext >&5
14733
14734         pgac_cv_c_signed=no
14735 fi
14736
14737 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14738 fi
14739 { $as_echo "$as_me:$LINENO: result: $pgac_cv_c_signed" >&5
14740 $as_echo "$pgac_cv_c_signed" >&6; }
14741 if test x"$pgac_cv_c_signed" = xno ; then
14742
14743 cat >>confdefs.h <<\_ACEOF
14744 #define signed /**/
14745 _ACEOF
14746
14747 fi
14748 { $as_echo "$as_me:$LINENO: checking for working volatile" >&5
14749 $as_echo_n "checking for working volatile... " >&6; }
14750 if test "${ac_cv_c_volatile+set}" = set; then
14751   $as_echo_n "(cached) " >&6
14752 else
14753   cat >conftest.$ac_ext <<_ACEOF
14754 /* confdefs.h.  */
14755 _ACEOF
14756 cat confdefs.h >>conftest.$ac_ext
14757 cat >>conftest.$ac_ext <<_ACEOF
14758 /* end confdefs.h.  */
14759
14760 int
14761 main ()
14762 {
14763
14764 volatile int x;
14765 int * volatile y = (int *) 0;
14766 return !x && !y;
14767   ;
14768   return 0;
14769 }
14770 _ACEOF
14771 rm -f conftest.$ac_objext
14772 if { (ac_try="$ac_compile"
14773 case "(($ac_try" in
14774   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14775   *) ac_try_echo=$ac_try;;
14776 esac
14777 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14778 $as_echo "$ac_try_echo") >&5
14779   (eval "$ac_compile") 2>conftest.er1
14780   ac_status=$?
14781   grep -v '^ *+' conftest.er1 >conftest.err
14782   rm -f conftest.er1
14783   cat conftest.err >&5
14784   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14785   (exit $ac_status); } && {
14786          test -z "$ac_c_werror_flag" ||
14787          test ! -s conftest.err
14788        } && test -s conftest.$ac_objext; then
14789   ac_cv_c_volatile=yes
14790 else
14791   $as_echo "$as_me: failed program was:" >&5
14792 sed 's/^/| /' conftest.$ac_ext >&5
14793
14794         ac_cv_c_volatile=no
14795 fi
14796
14797 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14798 fi
14799 { $as_echo "$as_me:$LINENO: result: $ac_cv_c_volatile" >&5
14800 $as_echo "$ac_cv_c_volatile" >&6; }
14801 if test $ac_cv_c_volatile = no; then
14802
14803 cat >>confdefs.h <<\_ACEOF
14804 #define volatile /**/
14805 _ACEOF
14806
14807 fi
14808
14809 { $as_echo "$as_me:$LINENO: checking for __func__" >&5
14810 $as_echo_n "checking for __func__... " >&6; }
14811 if test "${pgac_cv_funcname_func_support+set}" = set; then
14812   $as_echo_n "(cached) " >&6
14813 else
14814   cat >conftest.$ac_ext <<_ACEOF
14815 /* confdefs.h.  */
14816 _ACEOF
14817 cat confdefs.h >>conftest.$ac_ext
14818 cat >>conftest.$ac_ext <<_ACEOF
14819 /* end confdefs.h.  */
14820 #include <stdio.h>
14821 int
14822 main ()
14823 {
14824 printf("%s\n", __func__);
14825   ;
14826   return 0;
14827 }
14828 _ACEOF
14829 rm -f conftest.$ac_objext
14830 if { (ac_try="$ac_compile"
14831 case "(($ac_try" in
14832   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14833   *) ac_try_echo=$ac_try;;
14834 esac
14835 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14836 $as_echo "$ac_try_echo") >&5
14837   (eval "$ac_compile") 2>conftest.er1
14838   ac_status=$?
14839   grep -v '^ *+' conftest.er1 >conftest.err
14840   rm -f conftest.er1
14841   cat conftest.err >&5
14842   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14843   (exit $ac_status); } && {
14844          test -z "$ac_c_werror_flag" ||
14845          test ! -s conftest.err
14846        } && test -s conftest.$ac_objext; then
14847   pgac_cv_funcname_func_support=yes
14848 else
14849   $as_echo "$as_me: failed program was:" >&5
14850 sed 's/^/| /' conftest.$ac_ext >&5
14851
14852         pgac_cv_funcname_func_support=no
14853 fi
14854
14855 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14856 fi
14857 { $as_echo "$as_me:$LINENO: result: $pgac_cv_funcname_func_support" >&5
14858 $as_echo "$pgac_cv_funcname_func_support" >&6; }
14859 if test x"$pgac_cv_funcname_func_support" = xyes ; then
14860
14861 cat >>confdefs.h <<\_ACEOF
14862 #define HAVE_FUNCNAME__FUNC 1
14863 _ACEOF
14864
14865 else
14866 { $as_echo "$as_me:$LINENO: checking for __FUNCTION__" >&5
14867 $as_echo_n "checking for __FUNCTION__... " >&6; }
14868 if test "${pgac_cv_funcname_function_support+set}" = set; then
14869   $as_echo_n "(cached) " >&6
14870 else
14871   cat >conftest.$ac_ext <<_ACEOF
14872 /* confdefs.h.  */
14873 _ACEOF
14874 cat confdefs.h >>conftest.$ac_ext
14875 cat >>conftest.$ac_ext <<_ACEOF
14876 /* end confdefs.h.  */
14877 #include <stdio.h>
14878 int
14879 main ()
14880 {
14881 printf("%s\n", __FUNCTION__);
14882   ;
14883   return 0;
14884 }
14885 _ACEOF
14886 rm -f conftest.$ac_objext
14887 if { (ac_try="$ac_compile"
14888 case "(($ac_try" in
14889   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14890   *) ac_try_echo=$ac_try;;
14891 esac
14892 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14893 $as_echo "$ac_try_echo") >&5
14894   (eval "$ac_compile") 2>conftest.er1
14895   ac_status=$?
14896   grep -v '^ *+' conftest.er1 >conftest.err
14897   rm -f conftest.er1
14898   cat conftest.err >&5
14899   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14900   (exit $ac_status); } && {
14901          test -z "$ac_c_werror_flag" ||
14902          test ! -s conftest.err
14903        } && test -s conftest.$ac_objext; then
14904   pgac_cv_funcname_function_support=yes
14905 else
14906   $as_echo "$as_me: failed program was:" >&5
14907 sed 's/^/| /' conftest.$ac_ext >&5
14908
14909         pgac_cv_funcname_function_support=no
14910 fi
14911
14912 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14913 fi
14914 { $as_echo "$as_me:$LINENO: result: $pgac_cv_funcname_function_support" >&5
14915 $as_echo "$pgac_cv_funcname_function_support" >&6; }
14916 if test x"$pgac_cv_funcname_function_support" = xyes ; then
14917
14918 cat >>confdefs.h <<\_ACEOF
14919 #define HAVE_FUNCNAME__FUNCTION 1
14920 _ACEOF
14921
14922 fi
14923 fi
14924 { $as_echo "$as_me:$LINENO: checking whether struct tm is in sys/time.h or time.h" >&5
14925 $as_echo_n "checking whether struct tm is in sys/time.h or time.h... " >&6; }
14926 if test "${ac_cv_struct_tm+set}" = set; then
14927   $as_echo_n "(cached) " >&6
14928 else
14929   cat >conftest.$ac_ext <<_ACEOF
14930 /* confdefs.h.  */
14931 _ACEOF
14932 cat confdefs.h >>conftest.$ac_ext
14933 cat >>conftest.$ac_ext <<_ACEOF
14934 /* end confdefs.h.  */
14935 #include <sys/types.h>
14936 #include <time.h>
14937
14938 int
14939 main ()
14940 {
14941 struct tm tm;
14942                                      int *p = &tm.tm_sec;
14943                                      return !p;
14944   ;
14945   return 0;
14946 }
14947 _ACEOF
14948 rm -f conftest.$ac_objext
14949 if { (ac_try="$ac_compile"
14950 case "(($ac_try" in
14951   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
14952   *) ac_try_echo=$ac_try;;
14953 esac
14954 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
14955 $as_echo "$ac_try_echo") >&5
14956   (eval "$ac_compile") 2>conftest.er1
14957   ac_status=$?
14958   grep -v '^ *+' conftest.er1 >conftest.err
14959   rm -f conftest.er1
14960   cat conftest.err >&5
14961   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
14962   (exit $ac_status); } && {
14963          test -z "$ac_c_werror_flag" ||
14964          test ! -s conftest.err
14965        } && test -s conftest.$ac_objext; then
14966   ac_cv_struct_tm=time.h
14967 else
14968   $as_echo "$as_me: failed program was:" >&5
14969 sed 's/^/| /' conftest.$ac_ext >&5
14970
14971         ac_cv_struct_tm=sys/time.h
14972 fi
14973
14974 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
14975 fi
14976 { $as_echo "$as_me:$LINENO: result: $ac_cv_struct_tm" >&5
14977 $as_echo "$ac_cv_struct_tm" >&6; }
14978 if test $ac_cv_struct_tm = sys/time.h; then
14979
14980 cat >>confdefs.h <<\_ACEOF
14981 #define TM_IN_SYS_TIME 1
14982 _ACEOF
14983
14984 fi
14985
14986 { $as_echo "$as_me:$LINENO: checking for struct tm.tm_zone" >&5
14987 $as_echo_n "checking for struct tm.tm_zone... " >&6; }
14988 if test "${ac_cv_member_struct_tm_tm_zone+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 <sys/types.h>
14998 #include <$ac_cv_struct_tm>
14999
15000
15001 int
15002 main ()
15003 {
15004 static struct tm ac_aggr;
15005 if (ac_aggr.tm_zone)
15006 return 0;
15007   ;
15008   return 0;
15009 }
15010 _ACEOF
15011 rm -f conftest.$ac_objext
15012 if { (ac_try="$ac_compile"
15013 case "(($ac_try" in
15014   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15015   *) ac_try_echo=$ac_try;;
15016 esac
15017 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15018 $as_echo "$ac_try_echo") >&5
15019   (eval "$ac_compile") 2>conftest.er1
15020   ac_status=$?
15021   grep -v '^ *+' conftest.er1 >conftest.err
15022   rm -f conftest.er1
15023   cat conftest.err >&5
15024   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15025   (exit $ac_status); } && {
15026          test -z "$ac_c_werror_flag" ||
15027          test ! -s conftest.err
15028        } && test -s conftest.$ac_objext; then
15029   ac_cv_member_struct_tm_tm_zone=yes
15030 else
15031   $as_echo "$as_me: failed program was:" >&5
15032 sed 's/^/| /' conftest.$ac_ext >&5
15033
15034         cat >conftest.$ac_ext <<_ACEOF
15035 /* confdefs.h.  */
15036 _ACEOF
15037 cat confdefs.h >>conftest.$ac_ext
15038 cat >>conftest.$ac_ext <<_ACEOF
15039 /* end confdefs.h.  */
15040 #include <sys/types.h>
15041 #include <$ac_cv_struct_tm>
15042
15043
15044 int
15045 main ()
15046 {
15047 static struct tm ac_aggr;
15048 if (sizeof ac_aggr.tm_zone)
15049 return 0;
15050   ;
15051   return 0;
15052 }
15053 _ACEOF
15054 rm -f conftest.$ac_objext
15055 if { (ac_try="$ac_compile"
15056 case "(($ac_try" in
15057   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15058   *) ac_try_echo=$ac_try;;
15059 esac
15060 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15061 $as_echo "$ac_try_echo") >&5
15062   (eval "$ac_compile") 2>conftest.er1
15063   ac_status=$?
15064   grep -v '^ *+' conftest.er1 >conftest.err
15065   rm -f conftest.er1
15066   cat conftest.err >&5
15067   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15068   (exit $ac_status); } && {
15069          test -z "$ac_c_werror_flag" ||
15070          test ! -s conftest.err
15071        } && test -s conftest.$ac_objext; then
15072   ac_cv_member_struct_tm_tm_zone=yes
15073 else
15074   $as_echo "$as_me: failed program was:" >&5
15075 sed 's/^/| /' conftest.$ac_ext >&5
15076
15077         ac_cv_member_struct_tm_tm_zone=no
15078 fi
15079
15080 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15081 fi
15082
15083 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15084 fi
15085 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_tm_tm_zone" >&5
15086 $as_echo "$ac_cv_member_struct_tm_tm_zone" >&6; }
15087 if test "x$ac_cv_member_struct_tm_tm_zone" = x""yes; then
15088
15089 cat >>confdefs.h <<_ACEOF
15090 #define HAVE_STRUCT_TM_TM_ZONE 1
15091 _ACEOF
15092
15093
15094 fi
15095
15096 if test "$ac_cv_member_struct_tm_tm_zone" = yes; then
15097
15098 cat >>confdefs.h <<\_ACEOF
15099 #define HAVE_TM_ZONE 1
15100 _ACEOF
15101
15102 fi
15103 { $as_echo "$as_me:$LINENO: checking for tzname" >&5
15104 $as_echo_n "checking for tzname... " >&6; }
15105 if test "${ac_cv_var_tzname+set}" = set; then
15106   $as_echo_n "(cached) " >&6
15107 else
15108   cat >conftest.$ac_ext <<_ACEOF
15109 /* confdefs.h.  */
15110 _ACEOF
15111 cat confdefs.h >>conftest.$ac_ext
15112 cat >>conftest.$ac_ext <<_ACEOF
15113 /* end confdefs.h.  */
15114 #include <time.h>
15115 #ifndef tzname /* For SGI.  */
15116 extern char *tzname[]; /* RS6000 and others reject char **tzname.  */
15117 #endif
15118
15119 int
15120 main ()
15121 {
15122 atoi(*tzname);
15123   ;
15124   return 0;
15125 }
15126 _ACEOF
15127 rm -f conftest.$ac_objext conftest$ac_exeext
15128 if { (ac_try="$ac_link"
15129 case "(($ac_try" in
15130   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15131   *) ac_try_echo=$ac_try;;
15132 esac
15133 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15134 $as_echo "$ac_try_echo") >&5
15135   (eval "$ac_link") 2>conftest.er1
15136   ac_status=$?
15137   grep -v '^ *+' conftest.er1 >conftest.err
15138   rm -f conftest.er1
15139   cat conftest.err >&5
15140   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15141   (exit $ac_status); } && {
15142          test -z "$ac_c_werror_flag" ||
15143          test ! -s conftest.err
15144        } && test -s conftest$ac_exeext && {
15145          test "$cross_compiling" = yes ||
15146          $as_test_x conftest$ac_exeext
15147        }; then
15148   ac_cv_var_tzname=yes
15149 else
15150   $as_echo "$as_me: failed program was:" >&5
15151 sed 's/^/| /' conftest.$ac_ext >&5
15152
15153         ac_cv_var_tzname=no
15154 fi
15155
15156 rm -rf conftest.dSYM
15157 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
15158       conftest$ac_exeext conftest.$ac_ext
15159 fi
15160 { $as_echo "$as_me:$LINENO: result: $ac_cv_var_tzname" >&5
15161 $as_echo "$ac_cv_var_tzname" >&6; }
15162 if test $ac_cv_var_tzname = yes; then
15163
15164 cat >>confdefs.h <<\_ACEOF
15165 #define HAVE_TZNAME 1
15166 _ACEOF
15167
15168 fi
15169
15170 { $as_echo "$as_me:$LINENO: checking for union semun" >&5
15171 $as_echo_n "checking for union semun... " >&6; }
15172 if test "${ac_cv_type_union_semun+set}" = set; then
15173   $as_echo_n "(cached) " >&6
15174 else
15175   ac_cv_type_union_semun=no
15176 cat >conftest.$ac_ext <<_ACEOF
15177 /* confdefs.h.  */
15178 _ACEOF
15179 cat confdefs.h >>conftest.$ac_ext
15180 cat >>conftest.$ac_ext <<_ACEOF
15181 /* end confdefs.h.  */
15182 #include <sys/types.h>
15183 #include <sys/ipc.h>
15184 #include <sys/sem.h>
15185
15186 int
15187 main ()
15188 {
15189 if (sizeof (union semun))
15190        return 0;
15191   ;
15192   return 0;
15193 }
15194 _ACEOF
15195 rm -f conftest.$ac_objext
15196 if { (ac_try="$ac_compile"
15197 case "(($ac_try" in
15198   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15199   *) ac_try_echo=$ac_try;;
15200 esac
15201 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15202 $as_echo "$ac_try_echo") >&5
15203   (eval "$ac_compile") 2>conftest.er1
15204   ac_status=$?
15205   grep -v '^ *+' conftest.er1 >conftest.err
15206   rm -f conftest.er1
15207   cat conftest.err >&5
15208   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15209   (exit $ac_status); } && {
15210          test -z "$ac_c_werror_flag" ||
15211          test ! -s conftest.err
15212        } && test -s conftest.$ac_objext; then
15213   cat >conftest.$ac_ext <<_ACEOF
15214 /* confdefs.h.  */
15215 _ACEOF
15216 cat confdefs.h >>conftest.$ac_ext
15217 cat >>conftest.$ac_ext <<_ACEOF
15218 /* end confdefs.h.  */
15219 #include <sys/types.h>
15220 #include <sys/ipc.h>
15221 #include <sys/sem.h>
15222
15223 int
15224 main ()
15225 {
15226 if (sizeof ((union semun)))
15227           return 0;
15228   ;
15229   return 0;
15230 }
15231 _ACEOF
15232 rm -f conftest.$ac_objext
15233 if { (ac_try="$ac_compile"
15234 case "(($ac_try" in
15235   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15236   *) ac_try_echo=$ac_try;;
15237 esac
15238 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15239 $as_echo "$ac_try_echo") >&5
15240   (eval "$ac_compile") 2>conftest.er1
15241   ac_status=$?
15242   grep -v '^ *+' conftest.er1 >conftest.err
15243   rm -f conftest.er1
15244   cat conftest.err >&5
15245   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15246   (exit $ac_status); } && {
15247          test -z "$ac_c_werror_flag" ||
15248          test ! -s conftest.err
15249        } && test -s conftest.$ac_objext; then
15250   :
15251 else
15252   $as_echo "$as_me: failed program was:" >&5
15253 sed 's/^/| /' conftest.$ac_ext >&5
15254
15255         ac_cv_type_union_semun=yes
15256 fi
15257
15258 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15259 else
15260   $as_echo "$as_me: failed program was:" >&5
15261 sed 's/^/| /' conftest.$ac_ext >&5
15262
15263
15264 fi
15265
15266 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15267 fi
15268 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_union_semun" >&5
15269 $as_echo "$ac_cv_type_union_semun" >&6; }
15270 if test "x$ac_cv_type_union_semun" = x""yes; then
15271
15272 cat >>confdefs.h <<_ACEOF
15273 #define HAVE_UNION_SEMUN 1
15274 _ACEOF
15275
15276
15277 fi
15278
15279 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_un" >&5
15280 $as_echo_n "checking for struct sockaddr_un... " >&6; }
15281 if test "${ac_cv_type_struct_sockaddr_un+set}" = set; then
15282   $as_echo_n "(cached) " >&6
15283 else
15284   ac_cv_type_struct_sockaddr_un=no
15285 cat >conftest.$ac_ext <<_ACEOF
15286 /* confdefs.h.  */
15287 _ACEOF
15288 cat confdefs.h >>conftest.$ac_ext
15289 cat >>conftest.$ac_ext <<_ACEOF
15290 /* end confdefs.h.  */
15291 #include <sys/types.h>
15292 #ifdef HAVE_SYS_UN_H
15293 #include <sys/un.h>
15294 #endif
15295
15296
15297 int
15298 main ()
15299 {
15300 if (sizeof (struct sockaddr_un))
15301        return 0;
15302   ;
15303   return 0;
15304 }
15305 _ACEOF
15306 rm -f conftest.$ac_objext
15307 if { (ac_try="$ac_compile"
15308 case "(($ac_try" in
15309   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15310   *) ac_try_echo=$ac_try;;
15311 esac
15312 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15313 $as_echo "$ac_try_echo") >&5
15314   (eval "$ac_compile") 2>conftest.er1
15315   ac_status=$?
15316   grep -v '^ *+' conftest.er1 >conftest.err
15317   rm -f conftest.er1
15318   cat conftest.err >&5
15319   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15320   (exit $ac_status); } && {
15321          test -z "$ac_c_werror_flag" ||
15322          test ! -s conftest.err
15323        } && test -s conftest.$ac_objext; then
15324   cat >conftest.$ac_ext <<_ACEOF
15325 /* confdefs.h.  */
15326 _ACEOF
15327 cat confdefs.h >>conftest.$ac_ext
15328 cat >>conftest.$ac_ext <<_ACEOF
15329 /* end confdefs.h.  */
15330 #include <sys/types.h>
15331 #ifdef HAVE_SYS_UN_H
15332 #include <sys/un.h>
15333 #endif
15334
15335
15336 int
15337 main ()
15338 {
15339 if (sizeof ((struct sockaddr_un)))
15340           return 0;
15341   ;
15342   return 0;
15343 }
15344 _ACEOF
15345 rm -f conftest.$ac_objext
15346 if { (ac_try="$ac_compile"
15347 case "(($ac_try" in
15348   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15349   *) ac_try_echo=$ac_try;;
15350 esac
15351 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15352 $as_echo "$ac_try_echo") >&5
15353   (eval "$ac_compile") 2>conftest.er1
15354   ac_status=$?
15355   grep -v '^ *+' conftest.er1 >conftest.err
15356   rm -f conftest.er1
15357   cat conftest.err >&5
15358   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15359   (exit $ac_status); } && {
15360          test -z "$ac_c_werror_flag" ||
15361          test ! -s conftest.err
15362        } && test -s conftest.$ac_objext; then
15363   :
15364 else
15365   $as_echo "$as_me: failed program was:" >&5
15366 sed 's/^/| /' conftest.$ac_ext >&5
15367
15368         ac_cv_type_struct_sockaddr_un=yes
15369 fi
15370
15371 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15372 else
15373   $as_echo "$as_me: failed program was:" >&5
15374 sed 's/^/| /' conftest.$ac_ext >&5
15375
15376
15377 fi
15378
15379 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15380 fi
15381 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_un" >&5
15382 $as_echo "$ac_cv_type_struct_sockaddr_un" >&6; }
15383 if test "x$ac_cv_type_struct_sockaddr_un" = x""yes; then
15384
15385 cat >>confdefs.h <<_ACEOF
15386 #define HAVE_STRUCT_SOCKADDR_UN 1
15387 _ACEOF
15388
15389
15390 cat >>confdefs.h <<\_ACEOF
15391 #define HAVE_UNIX_SOCKETS 1
15392 _ACEOF
15393
15394 fi
15395
15396 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage" >&5
15397 $as_echo_n "checking for struct sockaddr_storage... " >&6; }
15398 if test "${ac_cv_type_struct_sockaddr_storage+set}" = set; then
15399   $as_echo_n "(cached) " >&6
15400 else
15401   ac_cv_type_struct_sockaddr_storage=no
15402 cat >conftest.$ac_ext <<_ACEOF
15403 /* confdefs.h.  */
15404 _ACEOF
15405 cat confdefs.h >>conftest.$ac_ext
15406 cat >>conftest.$ac_ext <<_ACEOF
15407 /* end confdefs.h.  */
15408 #include <sys/types.h>
15409 #ifdef HAVE_SYS_SOCKET_H
15410 #include <sys/socket.h>
15411 #endif
15412
15413
15414 int
15415 main ()
15416 {
15417 if (sizeof (struct sockaddr_storage))
15418        return 0;
15419   ;
15420   return 0;
15421 }
15422 _ACEOF
15423 rm -f conftest.$ac_objext
15424 if { (ac_try="$ac_compile"
15425 case "(($ac_try" in
15426   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15427   *) ac_try_echo=$ac_try;;
15428 esac
15429 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15430 $as_echo "$ac_try_echo") >&5
15431   (eval "$ac_compile") 2>conftest.er1
15432   ac_status=$?
15433   grep -v '^ *+' conftest.er1 >conftest.err
15434   rm -f conftest.er1
15435   cat conftest.err >&5
15436   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15437   (exit $ac_status); } && {
15438          test -z "$ac_c_werror_flag" ||
15439          test ! -s conftest.err
15440        } && test -s conftest.$ac_objext; then
15441   cat >conftest.$ac_ext <<_ACEOF
15442 /* confdefs.h.  */
15443 _ACEOF
15444 cat confdefs.h >>conftest.$ac_ext
15445 cat >>conftest.$ac_ext <<_ACEOF
15446 /* end confdefs.h.  */
15447 #include <sys/types.h>
15448 #ifdef HAVE_SYS_SOCKET_H
15449 #include <sys/socket.h>
15450 #endif
15451
15452
15453 int
15454 main ()
15455 {
15456 if (sizeof ((struct sockaddr_storage)))
15457           return 0;
15458   ;
15459   return 0;
15460 }
15461 _ACEOF
15462 rm -f conftest.$ac_objext
15463 if { (ac_try="$ac_compile"
15464 case "(($ac_try" in
15465   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15466   *) ac_try_echo=$ac_try;;
15467 esac
15468 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15469 $as_echo "$ac_try_echo") >&5
15470   (eval "$ac_compile") 2>conftest.er1
15471   ac_status=$?
15472   grep -v '^ *+' conftest.er1 >conftest.err
15473   rm -f conftest.er1
15474   cat conftest.err >&5
15475   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15476   (exit $ac_status); } && {
15477          test -z "$ac_c_werror_flag" ||
15478          test ! -s conftest.err
15479        } && test -s conftest.$ac_objext; then
15480   :
15481 else
15482   $as_echo "$as_me: failed program was:" >&5
15483 sed 's/^/| /' conftest.$ac_ext >&5
15484
15485         ac_cv_type_struct_sockaddr_storage=yes
15486 fi
15487
15488 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15489 else
15490   $as_echo "$as_me: failed program was:" >&5
15491 sed 's/^/| /' conftest.$ac_ext >&5
15492
15493
15494 fi
15495
15496 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15497 fi
15498 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_storage" >&5
15499 $as_echo "$ac_cv_type_struct_sockaddr_storage" >&6; }
15500 if test "x$ac_cv_type_struct_sockaddr_storage" = x""yes; then
15501
15502 cat >>confdefs.h <<_ACEOF
15503 #define HAVE_STRUCT_SOCKADDR_STORAGE 1
15504 _ACEOF
15505
15506
15507 fi
15508
15509 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_family" >&5
15510 $as_echo_n "checking for struct sockaddr_storage.ss_family... " >&6; }
15511 if test "${ac_cv_member_struct_sockaddr_storage_ss_family+set}" = set; then
15512   $as_echo_n "(cached) " >&6
15513 else
15514   cat >conftest.$ac_ext <<_ACEOF
15515 /* confdefs.h.  */
15516 _ACEOF
15517 cat confdefs.h >>conftest.$ac_ext
15518 cat >>conftest.$ac_ext <<_ACEOF
15519 /* end confdefs.h.  */
15520 #include <sys/types.h>
15521 #ifdef HAVE_SYS_SOCKET_H
15522 #include <sys/socket.h>
15523 #endif
15524
15525
15526 int
15527 main ()
15528 {
15529 static struct sockaddr_storage ac_aggr;
15530 if (ac_aggr.ss_family)
15531 return 0;
15532   ;
15533   return 0;
15534 }
15535 _ACEOF
15536 rm -f conftest.$ac_objext
15537 if { (ac_try="$ac_compile"
15538 case "(($ac_try" in
15539   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15540   *) ac_try_echo=$ac_try;;
15541 esac
15542 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15543 $as_echo "$ac_try_echo") >&5
15544   (eval "$ac_compile") 2>conftest.er1
15545   ac_status=$?
15546   grep -v '^ *+' conftest.er1 >conftest.err
15547   rm -f conftest.er1
15548   cat conftest.err >&5
15549   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15550   (exit $ac_status); } && {
15551          test -z "$ac_c_werror_flag" ||
15552          test ! -s conftest.err
15553        } && test -s conftest.$ac_objext; then
15554   ac_cv_member_struct_sockaddr_storage_ss_family=yes
15555 else
15556   $as_echo "$as_me: failed program was:" >&5
15557 sed 's/^/| /' conftest.$ac_ext >&5
15558
15559         cat >conftest.$ac_ext <<_ACEOF
15560 /* confdefs.h.  */
15561 _ACEOF
15562 cat confdefs.h >>conftest.$ac_ext
15563 cat >>conftest.$ac_ext <<_ACEOF
15564 /* end confdefs.h.  */
15565 #include <sys/types.h>
15566 #ifdef HAVE_SYS_SOCKET_H
15567 #include <sys/socket.h>
15568 #endif
15569
15570
15571 int
15572 main ()
15573 {
15574 static struct sockaddr_storage ac_aggr;
15575 if (sizeof ac_aggr.ss_family)
15576 return 0;
15577   ;
15578   return 0;
15579 }
15580 _ACEOF
15581 rm -f conftest.$ac_objext
15582 if { (ac_try="$ac_compile"
15583 case "(($ac_try" in
15584   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15585   *) ac_try_echo=$ac_try;;
15586 esac
15587 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15588 $as_echo "$ac_try_echo") >&5
15589   (eval "$ac_compile") 2>conftest.er1
15590   ac_status=$?
15591   grep -v '^ *+' conftest.er1 >conftest.err
15592   rm -f conftest.er1
15593   cat conftest.err >&5
15594   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15595   (exit $ac_status); } && {
15596          test -z "$ac_c_werror_flag" ||
15597          test ! -s conftest.err
15598        } && test -s conftest.$ac_objext; then
15599   ac_cv_member_struct_sockaddr_storage_ss_family=yes
15600 else
15601   $as_echo "$as_me: failed program was:" >&5
15602 sed 's/^/| /' conftest.$ac_ext >&5
15603
15604         ac_cv_member_struct_sockaddr_storage_ss_family=no
15605 fi
15606
15607 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15608 fi
15609
15610 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15611 fi
15612 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_family" >&5
15613 $as_echo "$ac_cv_member_struct_sockaddr_storage_ss_family" >&6; }
15614 if test "x$ac_cv_member_struct_sockaddr_storage_ss_family" = x""yes; then
15615
15616 cat >>confdefs.h <<_ACEOF
15617 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_FAMILY 1
15618 _ACEOF
15619
15620
15621 fi
15622 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_family" >&5
15623 $as_echo_n "checking for struct sockaddr_storage.__ss_family... " >&6; }
15624 if test "${ac_cv_member_struct_sockaddr_storage___ss_family+set}" = set; then
15625   $as_echo_n "(cached) " >&6
15626 else
15627   cat >conftest.$ac_ext <<_ACEOF
15628 /* confdefs.h.  */
15629 _ACEOF
15630 cat confdefs.h >>conftest.$ac_ext
15631 cat >>conftest.$ac_ext <<_ACEOF
15632 /* end confdefs.h.  */
15633 #include <sys/types.h>
15634 #ifdef HAVE_SYS_SOCKET_H
15635 #include <sys/socket.h>
15636 #endif
15637
15638
15639 int
15640 main ()
15641 {
15642 static struct sockaddr_storage ac_aggr;
15643 if (ac_aggr.__ss_family)
15644 return 0;
15645   ;
15646   return 0;
15647 }
15648 _ACEOF
15649 rm -f conftest.$ac_objext
15650 if { (ac_try="$ac_compile"
15651 case "(($ac_try" in
15652   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15653   *) ac_try_echo=$ac_try;;
15654 esac
15655 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15656 $as_echo "$ac_try_echo") >&5
15657   (eval "$ac_compile") 2>conftest.er1
15658   ac_status=$?
15659   grep -v '^ *+' conftest.er1 >conftest.err
15660   rm -f conftest.er1
15661   cat conftest.err >&5
15662   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15663   (exit $ac_status); } && {
15664          test -z "$ac_c_werror_flag" ||
15665          test ! -s conftest.err
15666        } && test -s conftest.$ac_objext; then
15667   ac_cv_member_struct_sockaddr_storage___ss_family=yes
15668 else
15669   $as_echo "$as_me: failed program was:" >&5
15670 sed 's/^/| /' conftest.$ac_ext >&5
15671
15672         cat >conftest.$ac_ext <<_ACEOF
15673 /* confdefs.h.  */
15674 _ACEOF
15675 cat confdefs.h >>conftest.$ac_ext
15676 cat >>conftest.$ac_ext <<_ACEOF
15677 /* end confdefs.h.  */
15678 #include <sys/types.h>
15679 #ifdef HAVE_SYS_SOCKET_H
15680 #include <sys/socket.h>
15681 #endif
15682
15683
15684 int
15685 main ()
15686 {
15687 static struct sockaddr_storage ac_aggr;
15688 if (sizeof ac_aggr.__ss_family)
15689 return 0;
15690   ;
15691   return 0;
15692 }
15693 _ACEOF
15694 rm -f conftest.$ac_objext
15695 if { (ac_try="$ac_compile"
15696 case "(($ac_try" in
15697   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15698   *) ac_try_echo=$ac_try;;
15699 esac
15700 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15701 $as_echo "$ac_try_echo") >&5
15702   (eval "$ac_compile") 2>conftest.er1
15703   ac_status=$?
15704   grep -v '^ *+' conftest.er1 >conftest.err
15705   rm -f conftest.er1
15706   cat conftest.err >&5
15707   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15708   (exit $ac_status); } && {
15709          test -z "$ac_c_werror_flag" ||
15710          test ! -s conftest.err
15711        } && test -s conftest.$ac_objext; then
15712   ac_cv_member_struct_sockaddr_storage___ss_family=yes
15713 else
15714   $as_echo "$as_me: failed program was:" >&5
15715 sed 's/^/| /' conftest.$ac_ext >&5
15716
15717         ac_cv_member_struct_sockaddr_storage___ss_family=no
15718 fi
15719
15720 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15721 fi
15722
15723 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15724 fi
15725 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_family" >&5
15726 $as_echo "$ac_cv_member_struct_sockaddr_storage___ss_family" >&6; }
15727 if test "x$ac_cv_member_struct_sockaddr_storage___ss_family" = x""yes; then
15728
15729 cat >>confdefs.h <<_ACEOF
15730 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_FAMILY 1
15731 _ACEOF
15732
15733
15734 fi
15735 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.ss_len" >&5
15736 $as_echo_n "checking for struct sockaddr_storage.ss_len... " >&6; }
15737 if test "${ac_cv_member_struct_sockaddr_storage_ss_len+set}" = set; then
15738   $as_echo_n "(cached) " >&6
15739 else
15740   cat >conftest.$ac_ext <<_ACEOF
15741 /* confdefs.h.  */
15742 _ACEOF
15743 cat confdefs.h >>conftest.$ac_ext
15744 cat >>conftest.$ac_ext <<_ACEOF
15745 /* end confdefs.h.  */
15746 #include <sys/types.h>
15747 #ifdef HAVE_SYS_SOCKET_H
15748 #include <sys/socket.h>
15749 #endif
15750
15751
15752 int
15753 main ()
15754 {
15755 static struct sockaddr_storage ac_aggr;
15756 if (ac_aggr.ss_len)
15757 return 0;
15758   ;
15759   return 0;
15760 }
15761 _ACEOF
15762 rm -f conftest.$ac_objext
15763 if { (ac_try="$ac_compile"
15764 case "(($ac_try" in
15765   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15766   *) ac_try_echo=$ac_try;;
15767 esac
15768 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15769 $as_echo "$ac_try_echo") >&5
15770   (eval "$ac_compile") 2>conftest.er1
15771   ac_status=$?
15772   grep -v '^ *+' conftest.er1 >conftest.err
15773   rm -f conftest.er1
15774   cat conftest.err >&5
15775   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15776   (exit $ac_status); } && {
15777          test -z "$ac_c_werror_flag" ||
15778          test ! -s conftest.err
15779        } && test -s conftest.$ac_objext; then
15780   ac_cv_member_struct_sockaddr_storage_ss_len=yes
15781 else
15782   $as_echo "$as_me: failed program was:" >&5
15783 sed 's/^/| /' conftest.$ac_ext >&5
15784
15785         cat >conftest.$ac_ext <<_ACEOF
15786 /* confdefs.h.  */
15787 _ACEOF
15788 cat confdefs.h >>conftest.$ac_ext
15789 cat >>conftest.$ac_ext <<_ACEOF
15790 /* end confdefs.h.  */
15791 #include <sys/types.h>
15792 #ifdef HAVE_SYS_SOCKET_H
15793 #include <sys/socket.h>
15794 #endif
15795
15796
15797 int
15798 main ()
15799 {
15800 static struct sockaddr_storage ac_aggr;
15801 if (sizeof ac_aggr.ss_len)
15802 return 0;
15803   ;
15804   return 0;
15805 }
15806 _ACEOF
15807 rm -f conftest.$ac_objext
15808 if { (ac_try="$ac_compile"
15809 case "(($ac_try" in
15810   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15811   *) ac_try_echo=$ac_try;;
15812 esac
15813 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15814 $as_echo "$ac_try_echo") >&5
15815   (eval "$ac_compile") 2>conftest.er1
15816   ac_status=$?
15817   grep -v '^ *+' conftest.er1 >conftest.err
15818   rm -f conftest.er1
15819   cat conftest.err >&5
15820   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15821   (exit $ac_status); } && {
15822          test -z "$ac_c_werror_flag" ||
15823          test ! -s conftest.err
15824        } && test -s conftest.$ac_objext; then
15825   ac_cv_member_struct_sockaddr_storage_ss_len=yes
15826 else
15827   $as_echo "$as_me: failed program was:" >&5
15828 sed 's/^/| /' conftest.$ac_ext >&5
15829
15830         ac_cv_member_struct_sockaddr_storage_ss_len=no
15831 fi
15832
15833 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15834 fi
15835
15836 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15837 fi
15838 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage_ss_len" >&5
15839 $as_echo "$ac_cv_member_struct_sockaddr_storage_ss_len" >&6; }
15840 if test "x$ac_cv_member_struct_sockaddr_storage_ss_len" = x""yes; then
15841
15842 cat >>confdefs.h <<_ACEOF
15843 #define HAVE_STRUCT_SOCKADDR_STORAGE_SS_LEN 1
15844 _ACEOF
15845
15846
15847 fi
15848 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_storage.__ss_len" >&5
15849 $as_echo_n "checking for struct sockaddr_storage.__ss_len... " >&6; }
15850 if test "${ac_cv_member_struct_sockaddr_storage___ss_len+set}" = set; then
15851   $as_echo_n "(cached) " >&6
15852 else
15853   cat >conftest.$ac_ext <<_ACEOF
15854 /* confdefs.h.  */
15855 _ACEOF
15856 cat confdefs.h >>conftest.$ac_ext
15857 cat >>conftest.$ac_ext <<_ACEOF
15858 /* end confdefs.h.  */
15859 #include <sys/types.h>
15860 #ifdef HAVE_SYS_SOCKET_H
15861 #include <sys/socket.h>
15862 #endif
15863
15864
15865 int
15866 main ()
15867 {
15868 static struct sockaddr_storage ac_aggr;
15869 if (ac_aggr.__ss_len)
15870 return 0;
15871   ;
15872   return 0;
15873 }
15874 _ACEOF
15875 rm -f conftest.$ac_objext
15876 if { (ac_try="$ac_compile"
15877 case "(($ac_try" in
15878   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15879   *) ac_try_echo=$ac_try;;
15880 esac
15881 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15882 $as_echo "$ac_try_echo") >&5
15883   (eval "$ac_compile") 2>conftest.er1
15884   ac_status=$?
15885   grep -v '^ *+' conftest.er1 >conftest.err
15886   rm -f conftest.er1
15887   cat conftest.err >&5
15888   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15889   (exit $ac_status); } && {
15890          test -z "$ac_c_werror_flag" ||
15891          test ! -s conftest.err
15892        } && test -s conftest.$ac_objext; then
15893   ac_cv_member_struct_sockaddr_storage___ss_len=yes
15894 else
15895   $as_echo "$as_me: failed program was:" >&5
15896 sed 's/^/| /' conftest.$ac_ext >&5
15897
15898         cat >conftest.$ac_ext <<_ACEOF
15899 /* confdefs.h.  */
15900 _ACEOF
15901 cat confdefs.h >>conftest.$ac_ext
15902 cat >>conftest.$ac_ext <<_ACEOF
15903 /* end confdefs.h.  */
15904 #include <sys/types.h>
15905 #ifdef HAVE_SYS_SOCKET_H
15906 #include <sys/socket.h>
15907 #endif
15908
15909
15910 int
15911 main ()
15912 {
15913 static struct sockaddr_storage ac_aggr;
15914 if (sizeof ac_aggr.__ss_len)
15915 return 0;
15916   ;
15917   return 0;
15918 }
15919 _ACEOF
15920 rm -f conftest.$ac_objext
15921 if { (ac_try="$ac_compile"
15922 case "(($ac_try" in
15923   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15924   *) ac_try_echo=$ac_try;;
15925 esac
15926 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15927 $as_echo "$ac_try_echo") >&5
15928   (eval "$ac_compile") 2>conftest.er1
15929   ac_status=$?
15930   grep -v '^ *+' conftest.er1 >conftest.err
15931   rm -f conftest.er1
15932   cat conftest.err >&5
15933   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
15934   (exit $ac_status); } && {
15935          test -z "$ac_c_werror_flag" ||
15936          test ! -s conftest.err
15937        } && test -s conftest.$ac_objext; then
15938   ac_cv_member_struct_sockaddr_storage___ss_len=yes
15939 else
15940   $as_echo "$as_me: failed program was:" >&5
15941 sed 's/^/| /' conftest.$ac_ext >&5
15942
15943         ac_cv_member_struct_sockaddr_storage___ss_len=no
15944 fi
15945
15946 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15947 fi
15948
15949 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
15950 fi
15951 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_storage___ss_len" >&5
15952 $as_echo "$ac_cv_member_struct_sockaddr_storage___ss_len" >&6; }
15953 if test "x$ac_cv_member_struct_sockaddr_storage___ss_len" = x""yes; then
15954
15955 cat >>confdefs.h <<_ACEOF
15956 #define HAVE_STRUCT_SOCKADDR_STORAGE___SS_LEN 1
15957 _ACEOF
15958
15959
15960 fi
15961 { $as_echo "$as_me:$LINENO: checking for struct sockaddr.sa_len" >&5
15962 $as_echo_n "checking for struct sockaddr.sa_len... " >&6; }
15963 if test "${ac_cv_member_struct_sockaddr_sa_len+set}" = set; then
15964   $as_echo_n "(cached) " >&6
15965 else
15966   cat >conftest.$ac_ext <<_ACEOF
15967 /* confdefs.h.  */
15968 _ACEOF
15969 cat confdefs.h >>conftest.$ac_ext
15970 cat >>conftest.$ac_ext <<_ACEOF
15971 /* end confdefs.h.  */
15972 #include <sys/types.h>
15973 #ifdef HAVE_SYS_SOCKET_H
15974 #include <sys/socket.h>
15975 #endif
15976
15977
15978 int
15979 main ()
15980 {
15981 static struct sockaddr ac_aggr;
15982 if (ac_aggr.sa_len)
15983 return 0;
15984   ;
15985   return 0;
15986 }
15987 _ACEOF
15988 rm -f conftest.$ac_objext
15989 if { (ac_try="$ac_compile"
15990 case "(($ac_try" in
15991   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
15992   *) ac_try_echo=$ac_try;;
15993 esac
15994 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
15995 $as_echo "$ac_try_echo") >&5
15996   (eval "$ac_compile") 2>conftest.er1
15997   ac_status=$?
15998   grep -v '^ *+' conftest.er1 >conftest.err
15999   rm -f conftest.er1
16000   cat conftest.err >&5
16001   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16002   (exit $ac_status); } && {
16003          test -z "$ac_c_werror_flag" ||
16004          test ! -s conftest.err
16005        } && test -s conftest.$ac_objext; then
16006   ac_cv_member_struct_sockaddr_sa_len=yes
16007 else
16008   $as_echo "$as_me: failed program was:" >&5
16009 sed 's/^/| /' conftest.$ac_ext >&5
16010
16011         cat >conftest.$ac_ext <<_ACEOF
16012 /* confdefs.h.  */
16013 _ACEOF
16014 cat confdefs.h >>conftest.$ac_ext
16015 cat >>conftest.$ac_ext <<_ACEOF
16016 /* end confdefs.h.  */
16017 #include <sys/types.h>
16018 #ifdef HAVE_SYS_SOCKET_H
16019 #include <sys/socket.h>
16020 #endif
16021
16022
16023 int
16024 main ()
16025 {
16026 static struct sockaddr ac_aggr;
16027 if (sizeof ac_aggr.sa_len)
16028 return 0;
16029   ;
16030   return 0;
16031 }
16032 _ACEOF
16033 rm -f conftest.$ac_objext
16034 if { (ac_try="$ac_compile"
16035 case "(($ac_try" in
16036   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16037   *) ac_try_echo=$ac_try;;
16038 esac
16039 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16040 $as_echo "$ac_try_echo") >&5
16041   (eval "$ac_compile") 2>conftest.er1
16042   ac_status=$?
16043   grep -v '^ *+' conftest.er1 >conftest.err
16044   rm -f conftest.er1
16045   cat conftest.err >&5
16046   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16047   (exit $ac_status); } && {
16048          test -z "$ac_c_werror_flag" ||
16049          test ! -s conftest.err
16050        } && test -s conftest.$ac_objext; then
16051   ac_cv_member_struct_sockaddr_sa_len=yes
16052 else
16053   $as_echo "$as_me: failed program was:" >&5
16054 sed 's/^/| /' conftest.$ac_ext >&5
16055
16056         ac_cv_member_struct_sockaddr_sa_len=no
16057 fi
16058
16059 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16060 fi
16061
16062 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16063 fi
16064 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_struct_sockaddr_sa_len" >&5
16065 $as_echo "$ac_cv_member_struct_sockaddr_sa_len" >&6; }
16066 if test "x$ac_cv_member_struct_sockaddr_sa_len" = x""yes; then
16067
16068 cat >>confdefs.h <<_ACEOF
16069 #define HAVE_STRUCT_SOCKADDR_SA_LEN 1
16070 _ACEOF
16071
16072
16073 fi
16074
16075 { $as_echo "$as_me:$LINENO: checking for struct addrinfo" >&5
16076 $as_echo_n "checking for struct addrinfo... " >&6; }
16077 if test "${ac_cv_type_struct_addrinfo+set}" = set; then
16078   $as_echo_n "(cached) " >&6
16079 else
16080   ac_cv_type_struct_addrinfo=no
16081 cat >conftest.$ac_ext <<_ACEOF
16082 /* confdefs.h.  */
16083 _ACEOF
16084 cat confdefs.h >>conftest.$ac_ext
16085 cat >>conftest.$ac_ext <<_ACEOF
16086 /* end confdefs.h.  */
16087 #include <sys/types.h>
16088 #include <sys/socket.h>
16089 #include <netdb.h>
16090
16091
16092 int
16093 main ()
16094 {
16095 if (sizeof (struct addrinfo))
16096        return 0;
16097   ;
16098   return 0;
16099 }
16100 _ACEOF
16101 rm -f conftest.$ac_objext
16102 if { (ac_try="$ac_compile"
16103 case "(($ac_try" in
16104   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16105   *) ac_try_echo=$ac_try;;
16106 esac
16107 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16108 $as_echo "$ac_try_echo") >&5
16109   (eval "$ac_compile") 2>conftest.er1
16110   ac_status=$?
16111   grep -v '^ *+' conftest.er1 >conftest.err
16112   rm -f conftest.er1
16113   cat conftest.err >&5
16114   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16115   (exit $ac_status); } && {
16116          test -z "$ac_c_werror_flag" ||
16117          test ! -s conftest.err
16118        } && test -s conftest.$ac_objext; then
16119   cat >conftest.$ac_ext <<_ACEOF
16120 /* confdefs.h.  */
16121 _ACEOF
16122 cat confdefs.h >>conftest.$ac_ext
16123 cat >>conftest.$ac_ext <<_ACEOF
16124 /* end confdefs.h.  */
16125 #include <sys/types.h>
16126 #include <sys/socket.h>
16127 #include <netdb.h>
16128
16129
16130 int
16131 main ()
16132 {
16133 if (sizeof ((struct addrinfo)))
16134           return 0;
16135   ;
16136   return 0;
16137 }
16138 _ACEOF
16139 rm -f conftest.$ac_objext
16140 if { (ac_try="$ac_compile"
16141 case "(($ac_try" in
16142   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16143   *) ac_try_echo=$ac_try;;
16144 esac
16145 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16146 $as_echo "$ac_try_echo") >&5
16147   (eval "$ac_compile") 2>conftest.er1
16148   ac_status=$?
16149   grep -v '^ *+' conftest.er1 >conftest.err
16150   rm -f conftest.er1
16151   cat conftest.err >&5
16152   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16153   (exit $ac_status); } && {
16154          test -z "$ac_c_werror_flag" ||
16155          test ! -s conftest.err
16156        } && test -s conftest.$ac_objext; then
16157   :
16158 else
16159   $as_echo "$as_me: failed program was:" >&5
16160 sed 's/^/| /' conftest.$ac_ext >&5
16161
16162         ac_cv_type_struct_addrinfo=yes
16163 fi
16164
16165 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16166 else
16167   $as_echo "$as_me: failed program was:" >&5
16168 sed 's/^/| /' conftest.$ac_ext >&5
16169
16170
16171 fi
16172
16173 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16174 fi
16175 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_addrinfo" >&5
16176 $as_echo "$ac_cv_type_struct_addrinfo" >&6; }
16177 if test "x$ac_cv_type_struct_addrinfo" = x""yes; then
16178
16179 cat >>confdefs.h <<_ACEOF
16180 #define HAVE_STRUCT_ADDRINFO 1
16181 _ACEOF
16182
16183
16184 fi
16185
16186
16187   { $as_echo "$as_me:$LINENO: checking for intptr_t" >&5
16188 $as_echo_n "checking for intptr_t... " >&6; }
16189 if test "${ac_cv_type_intptr_t+set}" = set; then
16190   $as_echo_n "(cached) " >&6
16191 else
16192   ac_cv_type_intptr_t=no
16193 cat >conftest.$ac_ext <<_ACEOF
16194 /* confdefs.h.  */
16195 _ACEOF
16196 cat confdefs.h >>conftest.$ac_ext
16197 cat >>conftest.$ac_ext <<_ACEOF
16198 /* end confdefs.h.  */
16199 $ac_includes_default
16200 int
16201 main ()
16202 {
16203 if (sizeof (intptr_t))
16204        return 0;
16205   ;
16206   return 0;
16207 }
16208 _ACEOF
16209 rm -f conftest.$ac_objext
16210 if { (ac_try="$ac_compile"
16211 case "(($ac_try" in
16212   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16213   *) ac_try_echo=$ac_try;;
16214 esac
16215 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16216 $as_echo "$ac_try_echo") >&5
16217   (eval "$ac_compile") 2>conftest.er1
16218   ac_status=$?
16219   grep -v '^ *+' conftest.er1 >conftest.err
16220   rm -f conftest.er1
16221   cat conftest.err >&5
16222   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16223   (exit $ac_status); } && {
16224          test -z "$ac_c_werror_flag" ||
16225          test ! -s conftest.err
16226        } && test -s conftest.$ac_objext; then
16227   cat >conftest.$ac_ext <<_ACEOF
16228 /* confdefs.h.  */
16229 _ACEOF
16230 cat confdefs.h >>conftest.$ac_ext
16231 cat >>conftest.$ac_ext <<_ACEOF
16232 /* end confdefs.h.  */
16233 $ac_includes_default
16234 int
16235 main ()
16236 {
16237 if (sizeof ((intptr_t)))
16238           return 0;
16239   ;
16240   return 0;
16241 }
16242 _ACEOF
16243 rm -f conftest.$ac_objext
16244 if { (ac_try="$ac_compile"
16245 case "(($ac_try" in
16246   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16247   *) ac_try_echo=$ac_try;;
16248 esac
16249 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16250 $as_echo "$ac_try_echo") >&5
16251   (eval "$ac_compile") 2>conftest.er1
16252   ac_status=$?
16253   grep -v '^ *+' conftest.er1 >conftest.err
16254   rm -f conftest.er1
16255   cat conftest.err >&5
16256   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16257   (exit $ac_status); } && {
16258          test -z "$ac_c_werror_flag" ||
16259          test ! -s conftest.err
16260        } && test -s conftest.$ac_objext; then
16261   :
16262 else
16263   $as_echo "$as_me: failed program was:" >&5
16264 sed 's/^/| /' conftest.$ac_ext >&5
16265
16266         ac_cv_type_intptr_t=yes
16267 fi
16268
16269 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16270 else
16271   $as_echo "$as_me: failed program was:" >&5
16272 sed 's/^/| /' conftest.$ac_ext >&5
16273
16274
16275 fi
16276
16277 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16278 fi
16279 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_intptr_t" >&5
16280 $as_echo "$ac_cv_type_intptr_t" >&6; }
16281 if test "x$ac_cv_type_intptr_t" = x""yes; then
16282
16283 cat >>confdefs.h <<\_ACEOF
16284 #define HAVE_INTPTR_T 1
16285 _ACEOF
16286
16287 else
16288   for ac_type in 'int' 'long int' 'long long int'; do
16289        cat >conftest.$ac_ext <<_ACEOF
16290 /* confdefs.h.  */
16291 _ACEOF
16292 cat confdefs.h >>conftest.$ac_ext
16293 cat >>conftest.$ac_ext <<_ACEOF
16294 /* end confdefs.h.  */
16295 $ac_includes_default
16296 int
16297 main ()
16298 {
16299 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
16300 test_array [0] = 0
16301
16302   ;
16303   return 0;
16304 }
16305 _ACEOF
16306 rm -f conftest.$ac_objext
16307 if { (ac_try="$ac_compile"
16308 case "(($ac_try" in
16309   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16310   *) ac_try_echo=$ac_try;;
16311 esac
16312 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16313 $as_echo "$ac_try_echo") >&5
16314   (eval "$ac_compile") 2>conftest.er1
16315   ac_status=$?
16316   grep -v '^ *+' conftest.er1 >conftest.err
16317   rm -f conftest.er1
16318   cat conftest.err >&5
16319   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16320   (exit $ac_status); } && {
16321          test -z "$ac_c_werror_flag" ||
16322          test ! -s conftest.err
16323        } && test -s conftest.$ac_objext; then
16324
16325 cat >>confdefs.h <<_ACEOF
16326 #define intptr_t $ac_type
16327 _ACEOF
16328
16329           ac_type=
16330 else
16331   $as_echo "$as_me: failed program was:" >&5
16332 sed 's/^/| /' conftest.$ac_ext >&5
16333
16334
16335 fi
16336
16337 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16338        test -z "$ac_type" && break
16339      done
16340 fi
16341
16342
16343
16344   { $as_echo "$as_me:$LINENO: checking for uintptr_t" >&5
16345 $as_echo_n "checking for uintptr_t... " >&6; }
16346 if test "${ac_cv_type_uintptr_t+set}" = set; then
16347   $as_echo_n "(cached) " >&6
16348 else
16349   ac_cv_type_uintptr_t=no
16350 cat >conftest.$ac_ext <<_ACEOF
16351 /* confdefs.h.  */
16352 _ACEOF
16353 cat confdefs.h >>conftest.$ac_ext
16354 cat >>conftest.$ac_ext <<_ACEOF
16355 /* end confdefs.h.  */
16356 $ac_includes_default
16357 int
16358 main ()
16359 {
16360 if (sizeof (uintptr_t))
16361        return 0;
16362   ;
16363   return 0;
16364 }
16365 _ACEOF
16366 rm -f conftest.$ac_objext
16367 if { (ac_try="$ac_compile"
16368 case "(($ac_try" in
16369   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16370   *) ac_try_echo=$ac_try;;
16371 esac
16372 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16373 $as_echo "$ac_try_echo") >&5
16374   (eval "$ac_compile") 2>conftest.er1
16375   ac_status=$?
16376   grep -v '^ *+' conftest.er1 >conftest.err
16377   rm -f conftest.er1
16378   cat conftest.err >&5
16379   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16380   (exit $ac_status); } && {
16381          test -z "$ac_c_werror_flag" ||
16382          test ! -s conftest.err
16383        } && test -s conftest.$ac_objext; then
16384   cat >conftest.$ac_ext <<_ACEOF
16385 /* confdefs.h.  */
16386 _ACEOF
16387 cat confdefs.h >>conftest.$ac_ext
16388 cat >>conftest.$ac_ext <<_ACEOF
16389 /* end confdefs.h.  */
16390 $ac_includes_default
16391 int
16392 main ()
16393 {
16394 if (sizeof ((uintptr_t)))
16395           return 0;
16396   ;
16397   return 0;
16398 }
16399 _ACEOF
16400 rm -f conftest.$ac_objext
16401 if { (ac_try="$ac_compile"
16402 case "(($ac_try" in
16403   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16404   *) ac_try_echo=$ac_try;;
16405 esac
16406 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16407 $as_echo "$ac_try_echo") >&5
16408   (eval "$ac_compile") 2>conftest.er1
16409   ac_status=$?
16410   grep -v '^ *+' conftest.er1 >conftest.err
16411   rm -f conftest.er1
16412   cat conftest.err >&5
16413   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16414   (exit $ac_status); } && {
16415          test -z "$ac_c_werror_flag" ||
16416          test ! -s conftest.err
16417        } && test -s conftest.$ac_objext; then
16418   :
16419 else
16420   $as_echo "$as_me: failed program was:" >&5
16421 sed 's/^/| /' conftest.$ac_ext >&5
16422
16423         ac_cv_type_uintptr_t=yes
16424 fi
16425
16426 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16427 else
16428   $as_echo "$as_me: failed program was:" >&5
16429 sed 's/^/| /' conftest.$ac_ext >&5
16430
16431
16432 fi
16433
16434 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16435 fi
16436 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uintptr_t" >&5
16437 $as_echo "$ac_cv_type_uintptr_t" >&6; }
16438 if test "x$ac_cv_type_uintptr_t" = x""yes; then
16439
16440 cat >>confdefs.h <<\_ACEOF
16441 #define HAVE_UINTPTR_T 1
16442 _ACEOF
16443
16444 else
16445   for ac_type in 'unsigned int' 'unsigned long int' \
16446         'unsigned long long int'; do
16447        cat >conftest.$ac_ext <<_ACEOF
16448 /* confdefs.h.  */
16449 _ACEOF
16450 cat confdefs.h >>conftest.$ac_ext
16451 cat >>conftest.$ac_ext <<_ACEOF
16452 /* end confdefs.h.  */
16453 $ac_includes_default
16454 int
16455 main ()
16456 {
16457 static int test_array [1 - 2 * !(sizeof (void *) <= sizeof ($ac_type))];
16458 test_array [0] = 0
16459
16460   ;
16461   return 0;
16462 }
16463 _ACEOF
16464 rm -f conftest.$ac_objext
16465 if { (ac_try="$ac_compile"
16466 case "(($ac_try" in
16467   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16468   *) ac_try_echo=$ac_try;;
16469 esac
16470 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16471 $as_echo "$ac_try_echo") >&5
16472   (eval "$ac_compile") 2>conftest.er1
16473   ac_status=$?
16474   grep -v '^ *+' conftest.er1 >conftest.err
16475   rm -f conftest.er1
16476   cat conftest.err >&5
16477   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16478   (exit $ac_status); } && {
16479          test -z "$ac_c_werror_flag" ||
16480          test ! -s conftest.err
16481        } && test -s conftest.$ac_objext; then
16482
16483 cat >>confdefs.h <<_ACEOF
16484 #define uintptr_t $ac_type
16485 _ACEOF
16486
16487           ac_type=
16488 else
16489   $as_echo "$as_me: failed program was:" >&5
16490 sed 's/^/| /' conftest.$ac_ext >&5
16491
16492
16493 fi
16494
16495 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16496        test -z "$ac_type" && break
16497      done
16498 fi
16499
16500
16501
16502   { $as_echo "$as_me:$LINENO: checking for long long int" >&5
16503 $as_echo_n "checking for long long int... " >&6; }
16504 if test "${ac_cv_type_long_long_int+set}" = set; then
16505   $as_echo_n "(cached) " >&6
16506 else
16507   cat >conftest.$ac_ext <<_ACEOF
16508
16509   /* confdefs.h.  */
16510 _ACEOF
16511 cat confdefs.h >>conftest.$ac_ext
16512 cat >>conftest.$ac_ext <<_ACEOF
16513 /* end confdefs.h.  */
16514 /* For now, do not test the preprocessor; as of 2007 there are too many
16515          implementations with broken preprocessors.  Perhaps this can
16516          be revisited in 2012.  In the meantime, code should not expect
16517          #if to work with literals wider than 32 bits.  */
16518       /* Test literals.  */
16519       long long int ll = 9223372036854775807ll;
16520       long long int nll = -9223372036854775807LL;
16521       unsigned long long int ull = 18446744073709551615ULL;
16522       /* Test constant expressions.   */
16523       typedef int a[((-9223372036854775807LL < 0 && 0 < 9223372036854775807ll)
16524                      ? 1 : -1)];
16525       typedef int b[(18446744073709551615ULL <= (unsigned long long int) -1
16526                      ? 1 : -1)];
16527       int i = 63;
16528 int
16529 main ()
16530 {
16531 /* Test availability of runtime routines for shift and division.  */
16532       long long int llmax = 9223372036854775807ll;
16533       unsigned long long int ullmax = 18446744073709551615ull;
16534       return ((ll << 63) | (ll >> 63) | (ll < i) | (ll > i)
16535               | (llmax / ll) | (llmax % ll)
16536               | (ull << 63) | (ull >> 63) | (ull << i) | (ull >> i)
16537               | (ullmax / ull) | (ullmax % ull));
16538   ;
16539   return 0;
16540 }
16541
16542 _ACEOF
16543 rm -f conftest.$ac_objext conftest$ac_exeext
16544 if { (ac_try="$ac_link"
16545 case "(($ac_try" in
16546   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16547   *) ac_try_echo=$ac_try;;
16548 esac
16549 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16550 $as_echo "$ac_try_echo") >&5
16551   (eval "$ac_link") 2>conftest.er1
16552   ac_status=$?
16553   grep -v '^ *+' conftest.er1 >conftest.err
16554   rm -f conftest.er1
16555   cat conftest.err >&5
16556   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16557   (exit $ac_status); } && {
16558          test -z "$ac_c_werror_flag" ||
16559          test ! -s conftest.err
16560        } && test -s conftest$ac_exeext && {
16561          test "$cross_compiling" = yes ||
16562          $as_test_x conftest$ac_exeext
16563        }; then
16564                         if test "$cross_compiling" = yes; then
16565   ac_cv_type_long_long_int=yes
16566 else
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 #include <limits.h>
16574                #ifndef LLONG_MAX
16575                # define HALF \
16576                         (1LL << (sizeof (long long int) * CHAR_BIT - 2))
16577                # define LLONG_MAX (HALF - 1 + HALF)
16578                #endif
16579 int
16580 main ()
16581 {
16582 long long int n = 1;
16583                int i;
16584                for (i = 0; ; i++)
16585                  {
16586                    long long int m = n << i;
16587                    if (m >> i != n)
16588                      return 1;
16589                    if (LLONG_MAX / 2 < m)
16590                      break;
16591                  }
16592                return 0;
16593   ;
16594   return 0;
16595 }
16596 _ACEOF
16597 rm -f conftest$ac_exeext
16598 if { (ac_try="$ac_link"
16599 case "(($ac_try" in
16600   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16601   *) ac_try_echo=$ac_try;;
16602 esac
16603 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16604 $as_echo "$ac_try_echo") >&5
16605   (eval "$ac_link") 2>&5
16606   ac_status=$?
16607   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16608   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
16609   { (case "(($ac_try" in
16610   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16611   *) ac_try_echo=$ac_try;;
16612 esac
16613 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16614 $as_echo "$ac_try_echo") >&5
16615   (eval "$ac_try") 2>&5
16616   ac_status=$?
16617   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16618   (exit $ac_status); }; }; then
16619   ac_cv_type_long_long_int=yes
16620 else
16621   $as_echo "$as_me: program exited with status $ac_status" >&5
16622 $as_echo "$as_me: failed program was:" >&5
16623 sed 's/^/| /' conftest.$ac_ext >&5
16624
16625 ( exit $ac_status )
16626 ac_cv_type_long_long_int=no
16627 fi
16628 rm -rf conftest.dSYM
16629 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
16630 fi
16631
16632
16633 else
16634   $as_echo "$as_me: failed program was:" >&5
16635 sed 's/^/| /' conftest.$ac_ext >&5
16636
16637         ac_cv_type_long_long_int=no
16638 fi
16639
16640 rm -rf conftest.dSYM
16641 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
16642       conftest$ac_exeext conftest.$ac_ext
16643 fi
16644 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_long_long_int" >&5
16645 $as_echo "$ac_cv_type_long_long_int" >&6; }
16646   if test $ac_cv_type_long_long_int = yes; then
16647
16648 cat >>confdefs.h <<\_ACEOF
16649 #define HAVE_LONG_LONG_INT 1
16650 _ACEOF
16651
16652   fi
16653
16654
16655 { $as_echo "$as_me:$LINENO: checking for struct cmsgcred" >&5
16656 $as_echo_n "checking for struct cmsgcred... " >&6; }
16657 if test "${ac_cv_type_struct_cmsgcred+set}" = set; then
16658   $as_echo_n "(cached) " >&6
16659 else
16660   ac_cv_type_struct_cmsgcred=no
16661 cat >conftest.$ac_ext <<_ACEOF
16662 /* confdefs.h.  */
16663 _ACEOF
16664 cat confdefs.h >>conftest.$ac_ext
16665 cat >>conftest.$ac_ext <<_ACEOF
16666 /* end confdefs.h.  */
16667 #include <sys/param.h>
16668 #include <sys/types.h>
16669 #include <sys/socket.h>
16670 #include <sys/ucred.h>
16671
16672 int
16673 main ()
16674 {
16675 if (sizeof (struct cmsgcred))
16676        return 0;
16677   ;
16678   return 0;
16679 }
16680 _ACEOF
16681 rm -f conftest.$ac_objext
16682 if { (ac_try="$ac_compile"
16683 case "(($ac_try" in
16684   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16685   *) ac_try_echo=$ac_try;;
16686 esac
16687 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16688 $as_echo "$ac_try_echo") >&5
16689   (eval "$ac_compile") 2>conftest.er1
16690   ac_status=$?
16691   grep -v '^ *+' conftest.er1 >conftest.err
16692   rm -f conftest.er1
16693   cat conftest.err >&5
16694   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16695   (exit $ac_status); } && {
16696          test -z "$ac_c_werror_flag" ||
16697          test ! -s conftest.err
16698        } && test -s conftest.$ac_objext; then
16699   cat >conftest.$ac_ext <<_ACEOF
16700 /* confdefs.h.  */
16701 _ACEOF
16702 cat confdefs.h >>conftest.$ac_ext
16703 cat >>conftest.$ac_ext <<_ACEOF
16704 /* end confdefs.h.  */
16705 #include <sys/param.h>
16706 #include <sys/types.h>
16707 #include <sys/socket.h>
16708 #include <sys/ucred.h>
16709
16710 int
16711 main ()
16712 {
16713 if (sizeof ((struct cmsgcred)))
16714           return 0;
16715   ;
16716   return 0;
16717 }
16718 _ACEOF
16719 rm -f conftest.$ac_objext
16720 if { (ac_try="$ac_compile"
16721 case "(($ac_try" in
16722   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16723   *) ac_try_echo=$ac_try;;
16724 esac
16725 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16726 $as_echo "$ac_try_echo") >&5
16727   (eval "$ac_compile") 2>conftest.er1
16728   ac_status=$?
16729   grep -v '^ *+' conftest.er1 >conftest.err
16730   rm -f conftest.er1
16731   cat conftest.err >&5
16732   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16733   (exit $ac_status); } && {
16734          test -z "$ac_c_werror_flag" ||
16735          test ! -s conftest.err
16736        } && test -s conftest.$ac_objext; then
16737   :
16738 else
16739   $as_echo "$as_me: failed program was:" >&5
16740 sed 's/^/| /' conftest.$ac_ext >&5
16741
16742         ac_cv_type_struct_cmsgcred=yes
16743 fi
16744
16745 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16746 else
16747   $as_echo "$as_me: failed program was:" >&5
16748 sed 's/^/| /' conftest.$ac_ext >&5
16749
16750
16751 fi
16752
16753 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16754 fi
16755 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_cmsgcred" >&5
16756 $as_echo "$ac_cv_type_struct_cmsgcred" >&6; }
16757 if test "x$ac_cv_type_struct_cmsgcred" = x""yes; then
16758
16759 cat >>confdefs.h <<_ACEOF
16760 #define HAVE_STRUCT_CMSGCRED 1
16761 _ACEOF
16762
16763
16764 fi
16765 { $as_echo "$as_me:$LINENO: checking for struct fcred" >&5
16766 $as_echo_n "checking for struct fcred... " >&6; }
16767 if test "${ac_cv_type_struct_fcred+set}" = set; then
16768   $as_echo_n "(cached) " >&6
16769 else
16770   ac_cv_type_struct_fcred=no
16771 cat >conftest.$ac_ext <<_ACEOF
16772 /* confdefs.h.  */
16773 _ACEOF
16774 cat confdefs.h >>conftest.$ac_ext
16775 cat >>conftest.$ac_ext <<_ACEOF
16776 /* end confdefs.h.  */
16777 #include <sys/param.h>
16778 #include <sys/types.h>
16779 #include <sys/socket.h>
16780 #include <sys/ucred.h>
16781
16782 int
16783 main ()
16784 {
16785 if (sizeof (struct fcred))
16786        return 0;
16787   ;
16788   return 0;
16789 }
16790 _ACEOF
16791 rm -f conftest.$ac_objext
16792 if { (ac_try="$ac_compile"
16793 case "(($ac_try" in
16794   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16795   *) ac_try_echo=$ac_try;;
16796 esac
16797 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16798 $as_echo "$ac_try_echo") >&5
16799   (eval "$ac_compile") 2>conftest.er1
16800   ac_status=$?
16801   grep -v '^ *+' conftest.er1 >conftest.err
16802   rm -f conftest.er1
16803   cat conftest.err >&5
16804   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16805   (exit $ac_status); } && {
16806          test -z "$ac_c_werror_flag" ||
16807          test ! -s conftest.err
16808        } && test -s conftest.$ac_objext; then
16809   cat >conftest.$ac_ext <<_ACEOF
16810 /* confdefs.h.  */
16811 _ACEOF
16812 cat confdefs.h >>conftest.$ac_ext
16813 cat >>conftest.$ac_ext <<_ACEOF
16814 /* end confdefs.h.  */
16815 #include <sys/param.h>
16816 #include <sys/types.h>
16817 #include <sys/socket.h>
16818 #include <sys/ucred.h>
16819
16820 int
16821 main ()
16822 {
16823 if (sizeof ((struct fcred)))
16824           return 0;
16825   ;
16826   return 0;
16827 }
16828 _ACEOF
16829 rm -f conftest.$ac_objext
16830 if { (ac_try="$ac_compile"
16831 case "(($ac_try" in
16832   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16833   *) ac_try_echo=$ac_try;;
16834 esac
16835 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16836 $as_echo "$ac_try_echo") >&5
16837   (eval "$ac_compile") 2>conftest.er1
16838   ac_status=$?
16839   grep -v '^ *+' conftest.er1 >conftest.err
16840   rm -f conftest.er1
16841   cat conftest.err >&5
16842   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16843   (exit $ac_status); } && {
16844          test -z "$ac_c_werror_flag" ||
16845          test ! -s conftest.err
16846        } && test -s conftest.$ac_objext; then
16847   :
16848 else
16849   $as_echo "$as_me: failed program was:" >&5
16850 sed 's/^/| /' conftest.$ac_ext >&5
16851
16852         ac_cv_type_struct_fcred=yes
16853 fi
16854
16855 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16856 else
16857   $as_echo "$as_me: failed program was:" >&5
16858 sed 's/^/| /' conftest.$ac_ext >&5
16859
16860
16861 fi
16862
16863 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16864 fi
16865 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_fcred" >&5
16866 $as_echo "$ac_cv_type_struct_fcred" >&6; }
16867 if test "x$ac_cv_type_struct_fcred" = x""yes; then
16868
16869 cat >>confdefs.h <<_ACEOF
16870 #define HAVE_STRUCT_FCRED 1
16871 _ACEOF
16872
16873
16874 fi
16875 { $as_echo "$as_me:$LINENO: checking for struct sockcred" >&5
16876 $as_echo_n "checking for struct sockcred... " >&6; }
16877 if test "${ac_cv_type_struct_sockcred+set}" = set; then
16878   $as_echo_n "(cached) " >&6
16879 else
16880   ac_cv_type_struct_sockcred=no
16881 cat >conftest.$ac_ext <<_ACEOF
16882 /* confdefs.h.  */
16883 _ACEOF
16884 cat confdefs.h >>conftest.$ac_ext
16885 cat >>conftest.$ac_ext <<_ACEOF
16886 /* end confdefs.h.  */
16887 #include <sys/param.h>
16888 #include <sys/types.h>
16889 #include <sys/socket.h>
16890 #include <sys/ucred.h>
16891
16892 int
16893 main ()
16894 {
16895 if (sizeof (struct sockcred))
16896        return 0;
16897   ;
16898   return 0;
16899 }
16900 _ACEOF
16901 rm -f conftest.$ac_objext
16902 if { (ac_try="$ac_compile"
16903 case "(($ac_try" in
16904   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16905   *) ac_try_echo=$ac_try;;
16906 esac
16907 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16908 $as_echo "$ac_try_echo") >&5
16909   (eval "$ac_compile") 2>conftest.er1
16910   ac_status=$?
16911   grep -v '^ *+' conftest.er1 >conftest.err
16912   rm -f conftest.er1
16913   cat conftest.err >&5
16914   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16915   (exit $ac_status); } && {
16916          test -z "$ac_c_werror_flag" ||
16917          test ! -s conftest.err
16918        } && test -s conftest.$ac_objext; then
16919   cat >conftest.$ac_ext <<_ACEOF
16920 /* confdefs.h.  */
16921 _ACEOF
16922 cat confdefs.h >>conftest.$ac_ext
16923 cat >>conftest.$ac_ext <<_ACEOF
16924 /* end confdefs.h.  */
16925 #include <sys/param.h>
16926 #include <sys/types.h>
16927 #include <sys/socket.h>
16928 #include <sys/ucred.h>
16929
16930 int
16931 main ()
16932 {
16933 if (sizeof ((struct sockcred)))
16934           return 0;
16935   ;
16936   return 0;
16937 }
16938 _ACEOF
16939 rm -f conftest.$ac_objext
16940 if { (ac_try="$ac_compile"
16941 case "(($ac_try" in
16942   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
16943   *) ac_try_echo=$ac_try;;
16944 esac
16945 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
16946 $as_echo "$ac_try_echo") >&5
16947   (eval "$ac_compile") 2>conftest.er1
16948   ac_status=$?
16949   grep -v '^ *+' conftest.er1 >conftest.err
16950   rm -f conftest.er1
16951   cat conftest.err >&5
16952   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
16953   (exit $ac_status); } && {
16954          test -z "$ac_c_werror_flag" ||
16955          test ! -s conftest.err
16956        } && test -s conftest.$ac_objext; then
16957   :
16958 else
16959   $as_echo "$as_me: failed program was:" >&5
16960 sed 's/^/| /' conftest.$ac_ext >&5
16961
16962         ac_cv_type_struct_sockcred=yes
16963 fi
16964
16965 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16966 else
16967   $as_echo "$as_me: failed program was:" >&5
16968 sed 's/^/| /' conftest.$ac_ext >&5
16969
16970
16971 fi
16972
16973 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
16974 fi
16975 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockcred" >&5
16976 $as_echo "$ac_cv_type_struct_sockcred" >&6; }
16977 if test "x$ac_cv_type_struct_sockcred" = x""yes; then
16978
16979 cat >>confdefs.h <<_ACEOF
16980 #define HAVE_STRUCT_SOCKCRED 1
16981 _ACEOF
16982
16983
16984 fi
16985
16986
16987 { $as_echo "$as_me:$LINENO: checking for struct option" >&5
16988 $as_echo_n "checking for struct option... " >&6; }
16989 if test "${ac_cv_type_struct_option+set}" = set; then
16990   $as_echo_n "(cached) " >&6
16991 else
16992   ac_cv_type_struct_option=no
16993 cat >conftest.$ac_ext <<_ACEOF
16994 /* confdefs.h.  */
16995 _ACEOF
16996 cat confdefs.h >>conftest.$ac_ext
16997 cat >>conftest.$ac_ext <<_ACEOF
16998 /* end confdefs.h.  */
16999 #ifdef HAVE_GETOPT_H
17000 #include <getopt.h>
17001 #endif
17002
17003 int
17004 main ()
17005 {
17006 if (sizeof (struct option))
17007        return 0;
17008   ;
17009   return 0;
17010 }
17011 _ACEOF
17012 rm -f conftest.$ac_objext
17013 if { (ac_try="$ac_compile"
17014 case "(($ac_try" in
17015   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17016   *) ac_try_echo=$ac_try;;
17017 esac
17018 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17019 $as_echo "$ac_try_echo") >&5
17020   (eval "$ac_compile") 2>conftest.er1
17021   ac_status=$?
17022   grep -v '^ *+' conftest.er1 >conftest.err
17023   rm -f conftest.er1
17024   cat conftest.err >&5
17025   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17026   (exit $ac_status); } && {
17027          test -z "$ac_c_werror_flag" ||
17028          test ! -s conftest.err
17029        } && test -s conftest.$ac_objext; then
17030   cat >conftest.$ac_ext <<_ACEOF
17031 /* confdefs.h.  */
17032 _ACEOF
17033 cat confdefs.h >>conftest.$ac_ext
17034 cat >>conftest.$ac_ext <<_ACEOF
17035 /* end confdefs.h.  */
17036 #ifdef HAVE_GETOPT_H
17037 #include <getopt.h>
17038 #endif
17039
17040 int
17041 main ()
17042 {
17043 if (sizeof ((struct option)))
17044           return 0;
17045   ;
17046   return 0;
17047 }
17048 _ACEOF
17049 rm -f conftest.$ac_objext
17050 if { (ac_try="$ac_compile"
17051 case "(($ac_try" in
17052   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17053   *) ac_try_echo=$ac_try;;
17054 esac
17055 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17056 $as_echo "$ac_try_echo") >&5
17057   (eval "$ac_compile") 2>conftest.er1
17058   ac_status=$?
17059   grep -v '^ *+' conftest.er1 >conftest.err
17060   rm -f conftest.er1
17061   cat conftest.err >&5
17062   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17063   (exit $ac_status); } && {
17064          test -z "$ac_c_werror_flag" ||
17065          test ! -s conftest.err
17066        } && test -s conftest.$ac_objext; then
17067   :
17068 else
17069   $as_echo "$as_me: failed program was:" >&5
17070 sed 's/^/| /' conftest.$ac_ext >&5
17071
17072         ac_cv_type_struct_option=yes
17073 fi
17074
17075 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17076 else
17077   $as_echo "$as_me: failed program was:" >&5
17078 sed 's/^/| /' conftest.$ac_ext >&5
17079
17080
17081 fi
17082
17083 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17084 fi
17085 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_option" >&5
17086 $as_echo "$ac_cv_type_struct_option" >&6; }
17087 if test "x$ac_cv_type_struct_option" = x""yes; then
17088
17089 cat >>confdefs.h <<_ACEOF
17090 #define HAVE_STRUCT_OPTION 1
17091 _ACEOF
17092
17093
17094 fi
17095
17096
17097 if test "$with_zlib" = yes; then
17098   # Check that <zlib.h> defines z_streamp (versions before about 1.0.4
17099   # did not).  While we could work around the lack of z_streamp, it
17100   # seems unwise to encourage people to use such old zlib versions...
17101   { $as_echo "$as_me:$LINENO: checking for z_streamp" >&5
17102 $as_echo_n "checking for z_streamp... " >&6; }
17103 if test "${ac_cv_type_z_streamp+set}" = set; then
17104   $as_echo_n "(cached) " >&6
17105 else
17106   ac_cv_type_z_streamp=no
17107 cat >conftest.$ac_ext <<_ACEOF
17108 /* confdefs.h.  */
17109 _ACEOF
17110 cat confdefs.h >>conftest.$ac_ext
17111 cat >>conftest.$ac_ext <<_ACEOF
17112 /* end confdefs.h.  */
17113 #include <zlib.h>
17114
17115 int
17116 main ()
17117 {
17118 if (sizeof (z_streamp))
17119        return 0;
17120   ;
17121   return 0;
17122 }
17123 _ACEOF
17124 rm -f conftest.$ac_objext
17125 if { (ac_try="$ac_compile"
17126 case "(($ac_try" in
17127   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17128   *) ac_try_echo=$ac_try;;
17129 esac
17130 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17131 $as_echo "$ac_try_echo") >&5
17132   (eval "$ac_compile") 2>conftest.er1
17133   ac_status=$?
17134   grep -v '^ *+' conftest.er1 >conftest.err
17135   rm -f conftest.er1
17136   cat conftest.err >&5
17137   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17138   (exit $ac_status); } && {
17139          test -z "$ac_c_werror_flag" ||
17140          test ! -s conftest.err
17141        } && test -s conftest.$ac_objext; then
17142   cat >conftest.$ac_ext <<_ACEOF
17143 /* confdefs.h.  */
17144 _ACEOF
17145 cat confdefs.h >>conftest.$ac_ext
17146 cat >>conftest.$ac_ext <<_ACEOF
17147 /* end confdefs.h.  */
17148 #include <zlib.h>
17149
17150 int
17151 main ()
17152 {
17153 if (sizeof ((z_streamp)))
17154           return 0;
17155   ;
17156   return 0;
17157 }
17158 _ACEOF
17159 rm -f conftest.$ac_objext
17160 if { (ac_try="$ac_compile"
17161 case "(($ac_try" in
17162   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17163   *) ac_try_echo=$ac_try;;
17164 esac
17165 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17166 $as_echo "$ac_try_echo") >&5
17167   (eval "$ac_compile") 2>conftest.er1
17168   ac_status=$?
17169   grep -v '^ *+' conftest.er1 >conftest.err
17170   rm -f conftest.er1
17171   cat conftest.err >&5
17172   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17173   (exit $ac_status); } && {
17174          test -z "$ac_c_werror_flag" ||
17175          test ! -s conftest.err
17176        } && test -s conftest.$ac_objext; then
17177   :
17178 else
17179   $as_echo "$as_me: failed program was:" >&5
17180 sed 's/^/| /' conftest.$ac_ext >&5
17181
17182         ac_cv_type_z_streamp=yes
17183 fi
17184
17185 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17186 else
17187   $as_echo "$as_me: failed program was:" >&5
17188 sed 's/^/| /' conftest.$ac_ext >&5
17189
17190
17191 fi
17192
17193 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17194 fi
17195 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_z_streamp" >&5
17196 $as_echo "$ac_cv_type_z_streamp" >&6; }
17197 if test "x$ac_cv_type_z_streamp" = x""yes; then
17198   :
17199 else
17200   { { $as_echo "$as_me:$LINENO: error: zlib version is too old
17201 Use --without-zlib to disable zlib support." >&5
17202 $as_echo "$as_me: error: zlib version is too old
17203 Use --without-zlib to disable zlib support." >&2;}
17204    { (exit 1); exit 1; }; }
17205 fi
17206
17207 fi
17208
17209 if test "$with_krb5" = yes; then
17210 # Check for differences between MIT and Heimdal (KTH) releases
17211   { $as_echo "$as_me:$LINENO: checking for krb5_ticket.enc_part2" >&5
17212 $as_echo_n "checking for krb5_ticket.enc_part2... " >&6; }
17213 if test "${ac_cv_member_krb5_ticket_enc_part2+set}" = set; then
17214   $as_echo_n "(cached) " >&6
17215 else
17216   cat >conftest.$ac_ext <<_ACEOF
17217 /* confdefs.h.  */
17218 _ACEOF
17219 cat confdefs.h >>conftest.$ac_ext
17220 cat >>conftest.$ac_ext <<_ACEOF
17221 /* end confdefs.h.  */
17222 #include <krb5.h>
17223
17224 int
17225 main ()
17226 {
17227 static krb5_ticket ac_aggr;
17228 if (ac_aggr.enc_part2)
17229 return 0;
17230   ;
17231   return 0;
17232 }
17233 _ACEOF
17234 rm -f conftest.$ac_objext
17235 if { (ac_try="$ac_compile"
17236 case "(($ac_try" in
17237   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17238   *) ac_try_echo=$ac_try;;
17239 esac
17240 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17241 $as_echo "$ac_try_echo") >&5
17242   (eval "$ac_compile") 2>conftest.er1
17243   ac_status=$?
17244   grep -v '^ *+' conftest.er1 >conftest.err
17245   rm -f conftest.er1
17246   cat conftest.err >&5
17247   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17248   (exit $ac_status); } && {
17249          test -z "$ac_c_werror_flag" ||
17250          test ! -s conftest.err
17251        } && test -s conftest.$ac_objext; then
17252   ac_cv_member_krb5_ticket_enc_part2=yes
17253 else
17254   $as_echo "$as_me: failed program was:" >&5
17255 sed 's/^/| /' conftest.$ac_ext >&5
17256
17257         cat >conftest.$ac_ext <<_ACEOF
17258 /* confdefs.h.  */
17259 _ACEOF
17260 cat confdefs.h >>conftest.$ac_ext
17261 cat >>conftest.$ac_ext <<_ACEOF
17262 /* end confdefs.h.  */
17263 #include <krb5.h>
17264
17265 int
17266 main ()
17267 {
17268 static krb5_ticket ac_aggr;
17269 if (sizeof ac_aggr.enc_part2)
17270 return 0;
17271   ;
17272   return 0;
17273 }
17274 _ACEOF
17275 rm -f conftest.$ac_objext
17276 if { (ac_try="$ac_compile"
17277 case "(($ac_try" in
17278   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17279   *) ac_try_echo=$ac_try;;
17280 esac
17281 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17282 $as_echo "$ac_try_echo") >&5
17283   (eval "$ac_compile") 2>conftest.er1
17284   ac_status=$?
17285   grep -v '^ *+' conftest.er1 >conftest.err
17286   rm -f conftest.er1
17287   cat conftest.err >&5
17288   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17289   (exit $ac_status); } && {
17290          test -z "$ac_c_werror_flag" ||
17291          test ! -s conftest.err
17292        } && test -s conftest.$ac_objext; then
17293   ac_cv_member_krb5_ticket_enc_part2=yes
17294 else
17295   $as_echo "$as_me: failed program was:" >&5
17296 sed 's/^/| /' conftest.$ac_ext >&5
17297
17298         ac_cv_member_krb5_ticket_enc_part2=no
17299 fi
17300
17301 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17302 fi
17303
17304 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17305 fi
17306 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_enc_part2" >&5
17307 $as_echo "$ac_cv_member_krb5_ticket_enc_part2" >&6; }
17308 if test "x$ac_cv_member_krb5_ticket_enc_part2" = x""yes; then
17309
17310 cat >>confdefs.h <<_ACEOF
17311 #define HAVE_KRB5_TICKET_ENC_PART2 1
17312 _ACEOF
17313
17314
17315 else
17316   { $as_echo "$as_me:$LINENO: checking for krb5_ticket.client" >&5
17317 $as_echo_n "checking for krb5_ticket.client... " >&6; }
17318 if test "${ac_cv_member_krb5_ticket_client+set}" = set; then
17319   $as_echo_n "(cached) " >&6
17320 else
17321   cat >conftest.$ac_ext <<_ACEOF
17322 /* confdefs.h.  */
17323 _ACEOF
17324 cat confdefs.h >>conftest.$ac_ext
17325 cat >>conftest.$ac_ext <<_ACEOF
17326 /* end confdefs.h.  */
17327 #include <krb5.h>
17328
17329 int
17330 main ()
17331 {
17332 static krb5_ticket ac_aggr;
17333 if (ac_aggr.client)
17334 return 0;
17335   ;
17336   return 0;
17337 }
17338 _ACEOF
17339 rm -f conftest.$ac_objext
17340 if { (ac_try="$ac_compile"
17341 case "(($ac_try" in
17342   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17343   *) ac_try_echo=$ac_try;;
17344 esac
17345 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17346 $as_echo "$ac_try_echo") >&5
17347   (eval "$ac_compile") 2>conftest.er1
17348   ac_status=$?
17349   grep -v '^ *+' conftest.er1 >conftest.err
17350   rm -f conftest.er1
17351   cat conftest.err >&5
17352   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17353   (exit $ac_status); } && {
17354          test -z "$ac_c_werror_flag" ||
17355          test ! -s conftest.err
17356        } && test -s conftest.$ac_objext; then
17357   ac_cv_member_krb5_ticket_client=yes
17358 else
17359   $as_echo "$as_me: failed program was:" >&5
17360 sed 's/^/| /' conftest.$ac_ext >&5
17361
17362         cat >conftest.$ac_ext <<_ACEOF
17363 /* confdefs.h.  */
17364 _ACEOF
17365 cat confdefs.h >>conftest.$ac_ext
17366 cat >>conftest.$ac_ext <<_ACEOF
17367 /* end confdefs.h.  */
17368 #include <krb5.h>
17369
17370 int
17371 main ()
17372 {
17373 static krb5_ticket ac_aggr;
17374 if (sizeof ac_aggr.client)
17375 return 0;
17376   ;
17377   return 0;
17378 }
17379 _ACEOF
17380 rm -f conftest.$ac_objext
17381 if { (ac_try="$ac_compile"
17382 case "(($ac_try" in
17383   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17384   *) ac_try_echo=$ac_try;;
17385 esac
17386 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17387 $as_echo "$ac_try_echo") >&5
17388   (eval "$ac_compile") 2>conftest.er1
17389   ac_status=$?
17390   grep -v '^ *+' conftest.er1 >conftest.err
17391   rm -f conftest.er1
17392   cat conftest.err >&5
17393   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17394   (exit $ac_status); } && {
17395          test -z "$ac_c_werror_flag" ||
17396          test ! -s conftest.err
17397        } && test -s conftest.$ac_objext; then
17398   ac_cv_member_krb5_ticket_client=yes
17399 else
17400   $as_echo "$as_me: failed program was:" >&5
17401 sed 's/^/| /' conftest.$ac_ext >&5
17402
17403         ac_cv_member_krb5_ticket_client=no
17404 fi
17405
17406 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17407 fi
17408
17409 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17410 fi
17411 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_ticket_client" >&5
17412 $as_echo "$ac_cv_member_krb5_ticket_client" >&6; }
17413 if test "x$ac_cv_member_krb5_ticket_client" = x""yes; then
17414
17415 cat >>confdefs.h <<_ACEOF
17416 #define HAVE_KRB5_TICKET_CLIENT 1
17417 _ACEOF
17418
17419
17420 else
17421   { { $as_echo "$as_me:$LINENO: error: could not determine how to get client name from Kerberos 5 ticket" >&5
17422 $as_echo "$as_me: error: could not determine how to get client name from Kerberos 5 ticket" >&2;}
17423    { (exit 1); exit 1; }; }
17424 fi
17425
17426 fi
17427
17428   { $as_echo "$as_me:$LINENO: checking for krb5_error.text.data" >&5
17429 $as_echo_n "checking for krb5_error.text.data... " >&6; }
17430 if test "${ac_cv_member_krb5_error_text_data+set}" = set; then
17431   $as_echo_n "(cached) " >&6
17432 else
17433   cat >conftest.$ac_ext <<_ACEOF
17434 /* confdefs.h.  */
17435 _ACEOF
17436 cat confdefs.h >>conftest.$ac_ext
17437 cat >>conftest.$ac_ext <<_ACEOF
17438 /* end confdefs.h.  */
17439 #include <krb5.h>
17440
17441 int
17442 main ()
17443 {
17444 static krb5_error ac_aggr;
17445 if (ac_aggr.text.data)
17446 return 0;
17447   ;
17448   return 0;
17449 }
17450 _ACEOF
17451 rm -f conftest.$ac_objext
17452 if { (ac_try="$ac_compile"
17453 case "(($ac_try" in
17454   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17455   *) ac_try_echo=$ac_try;;
17456 esac
17457 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17458 $as_echo "$ac_try_echo") >&5
17459   (eval "$ac_compile") 2>conftest.er1
17460   ac_status=$?
17461   grep -v '^ *+' conftest.er1 >conftest.err
17462   rm -f conftest.er1
17463   cat conftest.err >&5
17464   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17465   (exit $ac_status); } && {
17466          test -z "$ac_c_werror_flag" ||
17467          test ! -s conftest.err
17468        } && test -s conftest.$ac_objext; then
17469   ac_cv_member_krb5_error_text_data=yes
17470 else
17471   $as_echo "$as_me: failed program was:" >&5
17472 sed 's/^/| /' conftest.$ac_ext >&5
17473
17474         cat >conftest.$ac_ext <<_ACEOF
17475 /* confdefs.h.  */
17476 _ACEOF
17477 cat confdefs.h >>conftest.$ac_ext
17478 cat >>conftest.$ac_ext <<_ACEOF
17479 /* end confdefs.h.  */
17480 #include <krb5.h>
17481
17482 int
17483 main ()
17484 {
17485 static krb5_error ac_aggr;
17486 if (sizeof ac_aggr.text.data)
17487 return 0;
17488   ;
17489   return 0;
17490 }
17491 _ACEOF
17492 rm -f conftest.$ac_objext
17493 if { (ac_try="$ac_compile"
17494 case "(($ac_try" in
17495   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17496   *) ac_try_echo=$ac_try;;
17497 esac
17498 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17499 $as_echo "$ac_try_echo") >&5
17500   (eval "$ac_compile") 2>conftest.er1
17501   ac_status=$?
17502   grep -v '^ *+' conftest.er1 >conftest.err
17503   rm -f conftest.er1
17504   cat conftest.err >&5
17505   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17506   (exit $ac_status); } && {
17507          test -z "$ac_c_werror_flag" ||
17508          test ! -s conftest.err
17509        } && test -s conftest.$ac_objext; then
17510   ac_cv_member_krb5_error_text_data=yes
17511 else
17512   $as_echo "$as_me: failed program was:" >&5
17513 sed 's/^/| /' conftest.$ac_ext >&5
17514
17515         ac_cv_member_krb5_error_text_data=no
17516 fi
17517
17518 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17519 fi
17520
17521 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17522 fi
17523 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_text_data" >&5
17524 $as_echo "$ac_cv_member_krb5_error_text_data" >&6; }
17525 if test "x$ac_cv_member_krb5_error_text_data" = x""yes; then
17526
17527 cat >>confdefs.h <<_ACEOF
17528 #define HAVE_KRB5_ERROR_TEXT_DATA 1
17529 _ACEOF
17530
17531
17532 else
17533   { $as_echo "$as_me:$LINENO: checking for krb5_error.e_data" >&5
17534 $as_echo_n "checking for krb5_error.e_data... " >&6; }
17535 if test "${ac_cv_member_krb5_error_e_data+set}" = set; then
17536   $as_echo_n "(cached) " >&6
17537 else
17538   cat >conftest.$ac_ext <<_ACEOF
17539 /* confdefs.h.  */
17540 _ACEOF
17541 cat confdefs.h >>conftest.$ac_ext
17542 cat >>conftest.$ac_ext <<_ACEOF
17543 /* end confdefs.h.  */
17544 #include <krb5.h>
17545
17546 int
17547 main ()
17548 {
17549 static krb5_error ac_aggr;
17550 if (ac_aggr.e_data)
17551 return 0;
17552   ;
17553   return 0;
17554 }
17555 _ACEOF
17556 rm -f conftest.$ac_objext
17557 if { (ac_try="$ac_compile"
17558 case "(($ac_try" in
17559   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17560   *) ac_try_echo=$ac_try;;
17561 esac
17562 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17563 $as_echo "$ac_try_echo") >&5
17564   (eval "$ac_compile") 2>conftest.er1
17565   ac_status=$?
17566   grep -v '^ *+' conftest.er1 >conftest.err
17567   rm -f conftest.er1
17568   cat conftest.err >&5
17569   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17570   (exit $ac_status); } && {
17571          test -z "$ac_c_werror_flag" ||
17572          test ! -s conftest.err
17573        } && test -s conftest.$ac_objext; then
17574   ac_cv_member_krb5_error_e_data=yes
17575 else
17576   $as_echo "$as_me: failed program was:" >&5
17577 sed 's/^/| /' conftest.$ac_ext >&5
17578
17579         cat >conftest.$ac_ext <<_ACEOF
17580 /* confdefs.h.  */
17581 _ACEOF
17582 cat confdefs.h >>conftest.$ac_ext
17583 cat >>conftest.$ac_ext <<_ACEOF
17584 /* end confdefs.h.  */
17585 #include <krb5.h>
17586
17587 int
17588 main ()
17589 {
17590 static krb5_error ac_aggr;
17591 if (sizeof ac_aggr.e_data)
17592 return 0;
17593   ;
17594   return 0;
17595 }
17596 _ACEOF
17597 rm -f conftest.$ac_objext
17598 if { (ac_try="$ac_compile"
17599 case "(($ac_try" in
17600   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17601   *) ac_try_echo=$ac_try;;
17602 esac
17603 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17604 $as_echo "$ac_try_echo") >&5
17605   (eval "$ac_compile") 2>conftest.er1
17606   ac_status=$?
17607   grep -v '^ *+' conftest.er1 >conftest.err
17608   rm -f conftest.er1
17609   cat conftest.err >&5
17610   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17611   (exit $ac_status); } && {
17612          test -z "$ac_c_werror_flag" ||
17613          test ! -s conftest.err
17614        } && test -s conftest.$ac_objext; then
17615   ac_cv_member_krb5_error_e_data=yes
17616 else
17617   $as_echo "$as_me: failed program was:" >&5
17618 sed 's/^/| /' conftest.$ac_ext >&5
17619
17620         ac_cv_member_krb5_error_e_data=no
17621 fi
17622
17623 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17624 fi
17625
17626 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17627 fi
17628 { $as_echo "$as_me:$LINENO: result: $ac_cv_member_krb5_error_e_data" >&5
17629 $as_echo "$ac_cv_member_krb5_error_e_data" >&6; }
17630 if test "x$ac_cv_member_krb5_error_e_data" = x""yes; then
17631
17632 cat >>confdefs.h <<_ACEOF
17633 #define HAVE_KRB5_ERROR_E_DATA 1
17634 _ACEOF
17635
17636
17637 else
17638   { { $as_echo "$as_me:$LINENO: error: could not determine how to extract Kerberos 5 error messages" >&5
17639 $as_echo "$as_me: error: could not determine how to extract Kerberos 5 error messages" >&2;}
17640    { (exit 1); exit 1; }; }
17641 fi
17642
17643 fi
17644
17645
17646 # Win32 requires headers to be loaded for __stdcall, so can't use
17647 # AC_CHECK_FUNCS here.
17648   { $as_echo "$as_me:$LINENO: checking for krb5_free_unparsed_name" >&5
17649 $as_echo_n "checking for krb5_free_unparsed_name... " >&6; }
17650   cat >conftest.$ac_ext <<_ACEOF
17651 /* confdefs.h.  */
17652 _ACEOF
17653 cat confdefs.h >>conftest.$ac_ext
17654 cat >>conftest.$ac_ext <<_ACEOF
17655 /* end confdefs.h.  */
17656 #include <krb5.h>
17657 int
17658 main ()
17659 {
17660 krb5_free_unparsed_name(NULL,NULL);
17661   ;
17662   return 0;
17663 }
17664 _ACEOF
17665 rm -f conftest.$ac_objext conftest$ac_exeext
17666 if { (ac_try="$ac_link"
17667 case "(($ac_try" in
17668   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17669   *) ac_try_echo=$ac_try;;
17670 esac
17671 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17672 $as_echo "$ac_try_echo") >&5
17673   (eval "$ac_link") 2>conftest.er1
17674   ac_status=$?
17675   grep -v '^ *+' conftest.er1 >conftest.err
17676   rm -f conftest.er1
17677   cat conftest.err >&5
17678   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17679   (exit $ac_status); } && {
17680          test -z "$ac_c_werror_flag" ||
17681          test ! -s conftest.err
17682        } && test -s conftest$ac_exeext && {
17683          test "$cross_compiling" = yes ||
17684          $as_test_x conftest$ac_exeext
17685        }; then
17686
17687 cat >>confdefs.h <<\_ACEOF
17688 #define HAVE_KRB5_FREE_UNPARSED_NAME 1
17689 _ACEOF
17690
17691 { $as_echo "$as_me:$LINENO: result: yes" >&5
17692 $as_echo "yes" >&6; }
17693 else
17694   $as_echo "$as_me: failed program was:" >&5
17695 sed 's/^/| /' conftest.$ac_ext >&5
17696
17697         { $as_echo "$as_me:$LINENO: result: no" >&5
17698 $as_echo "no" >&6; }
17699 fi
17700
17701 rm -rf conftest.dSYM
17702 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
17703       conftest$ac_exeext conftest.$ac_ext
17704 fi
17705
17706 # Check largefile support.  You might think this is a system service not a
17707 # compiler characteristic, but you'd be wrong.  We must check this before
17708 # probing existence of related functions such as fseeko, since the largefile
17709 # defines can affect what is generated for that.
17710 # Check whether --enable-largefile was given.
17711 if test "${enable_largefile+set}" = set; then
17712   enableval=$enable_largefile;
17713 fi
17714
17715 if test "$enable_largefile" != no; then
17716
17717   { $as_echo "$as_me:$LINENO: checking for special C compiler options needed for large files" >&5
17718 $as_echo_n "checking for special C compiler options needed for large files... " >&6; }
17719 if test "${ac_cv_sys_largefile_CC+set}" = set; then
17720   $as_echo_n "(cached) " >&6
17721 else
17722   ac_cv_sys_largefile_CC=no
17723      if test "$GCC" != yes; then
17724        ac_save_CC=$CC
17725        while :; do
17726          # IRIX 6.2 and later do not support large files by default,
17727          # so use the C compiler's -n32 option if that helps.
17728          cat >conftest.$ac_ext <<_ACEOF
17729 /* confdefs.h.  */
17730 _ACEOF
17731 cat confdefs.h >>conftest.$ac_ext
17732 cat >>conftest.$ac_ext <<_ACEOF
17733 /* end confdefs.h.  */
17734 #include <sys/types.h>
17735  /* Check that off_t can represent 2**63 - 1 correctly.
17736     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17737     since some C++ compilers masquerading as C compilers
17738     incorrectly reject 9223372036854775807.  */
17739 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17740   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17741                        && LARGE_OFF_T % 2147483647 == 1)
17742                       ? 1 : -1];
17743 int
17744 main ()
17745 {
17746
17747   ;
17748   return 0;
17749 }
17750 _ACEOF
17751          rm -f conftest.$ac_objext
17752 if { (ac_try="$ac_compile"
17753 case "(($ac_try" in
17754   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17755   *) ac_try_echo=$ac_try;;
17756 esac
17757 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17758 $as_echo "$ac_try_echo") >&5
17759   (eval "$ac_compile") 2>conftest.er1
17760   ac_status=$?
17761   grep -v '^ *+' conftest.er1 >conftest.err
17762   rm -f conftest.er1
17763   cat conftest.err >&5
17764   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17765   (exit $ac_status); } && {
17766          test -z "$ac_c_werror_flag" ||
17767          test ! -s conftest.err
17768        } && test -s conftest.$ac_objext; then
17769   break
17770 else
17771   $as_echo "$as_me: failed program was:" >&5
17772 sed 's/^/| /' conftest.$ac_ext >&5
17773
17774
17775 fi
17776
17777 rm -f core conftest.err conftest.$ac_objext
17778          CC="$CC -n32"
17779          rm -f conftest.$ac_objext
17780 if { (ac_try="$ac_compile"
17781 case "(($ac_try" in
17782   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17783   *) ac_try_echo=$ac_try;;
17784 esac
17785 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17786 $as_echo "$ac_try_echo") >&5
17787   (eval "$ac_compile") 2>conftest.er1
17788   ac_status=$?
17789   grep -v '^ *+' conftest.er1 >conftest.err
17790   rm -f conftest.er1
17791   cat conftest.err >&5
17792   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17793   (exit $ac_status); } && {
17794          test -z "$ac_c_werror_flag" ||
17795          test ! -s conftest.err
17796        } && test -s conftest.$ac_objext; then
17797   ac_cv_sys_largefile_CC=' -n32'; break
17798 else
17799   $as_echo "$as_me: failed program was:" >&5
17800 sed 's/^/| /' conftest.$ac_ext >&5
17801
17802
17803 fi
17804
17805 rm -f core conftest.err conftest.$ac_objext
17806          break
17807        done
17808        CC=$ac_save_CC
17809        rm -f conftest.$ac_ext
17810     fi
17811 fi
17812 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_CC" >&5
17813 $as_echo "$ac_cv_sys_largefile_CC" >&6; }
17814   if test "$ac_cv_sys_largefile_CC" != no; then
17815     CC=$CC$ac_cv_sys_largefile_CC
17816   fi
17817
17818   { $as_echo "$as_me:$LINENO: checking for _FILE_OFFSET_BITS value needed for large files" >&5
17819 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; }
17820 if test "${ac_cv_sys_file_offset_bits+set}" = set; then
17821   $as_echo_n "(cached) " >&6
17822 else
17823   while :; do
17824   cat >conftest.$ac_ext <<_ACEOF
17825 /* confdefs.h.  */
17826 _ACEOF
17827 cat confdefs.h >>conftest.$ac_ext
17828 cat >>conftest.$ac_ext <<_ACEOF
17829 /* end confdefs.h.  */
17830 #include <sys/types.h>
17831  /* Check that off_t can represent 2**63 - 1 correctly.
17832     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17833     since some C++ compilers masquerading as C compilers
17834     incorrectly reject 9223372036854775807.  */
17835 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17836   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17837                        && LARGE_OFF_T % 2147483647 == 1)
17838                       ? 1 : -1];
17839 int
17840 main ()
17841 {
17842
17843   ;
17844   return 0;
17845 }
17846 _ACEOF
17847 rm -f conftest.$ac_objext
17848 if { (ac_try="$ac_compile"
17849 case "(($ac_try" in
17850   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17851   *) ac_try_echo=$ac_try;;
17852 esac
17853 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17854 $as_echo "$ac_try_echo") >&5
17855   (eval "$ac_compile") 2>conftest.er1
17856   ac_status=$?
17857   grep -v '^ *+' conftest.er1 >conftest.err
17858   rm -f conftest.er1
17859   cat conftest.err >&5
17860   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17861   (exit $ac_status); } && {
17862          test -z "$ac_c_werror_flag" ||
17863          test ! -s conftest.err
17864        } && test -s conftest.$ac_objext; then
17865   ac_cv_sys_file_offset_bits=no; break
17866 else
17867   $as_echo "$as_me: failed program was:" >&5
17868 sed 's/^/| /' conftest.$ac_ext >&5
17869
17870
17871 fi
17872
17873 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17874   cat >conftest.$ac_ext <<_ACEOF
17875 /* confdefs.h.  */
17876 _ACEOF
17877 cat confdefs.h >>conftest.$ac_ext
17878 cat >>conftest.$ac_ext <<_ACEOF
17879 /* end confdefs.h.  */
17880 #define _FILE_OFFSET_BITS 64
17881 #include <sys/types.h>
17882  /* Check that off_t can represent 2**63 - 1 correctly.
17883     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17884     since some C++ compilers masquerading as C compilers
17885     incorrectly reject 9223372036854775807.  */
17886 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17887   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17888                        && LARGE_OFF_T % 2147483647 == 1)
17889                       ? 1 : -1];
17890 int
17891 main ()
17892 {
17893
17894   ;
17895   return 0;
17896 }
17897 _ACEOF
17898 rm -f conftest.$ac_objext
17899 if { (ac_try="$ac_compile"
17900 case "(($ac_try" in
17901   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17902   *) ac_try_echo=$ac_try;;
17903 esac
17904 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17905 $as_echo "$ac_try_echo") >&5
17906   (eval "$ac_compile") 2>conftest.er1
17907   ac_status=$?
17908   grep -v '^ *+' conftest.er1 >conftest.err
17909   rm -f conftest.er1
17910   cat conftest.err >&5
17911   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17912   (exit $ac_status); } && {
17913          test -z "$ac_c_werror_flag" ||
17914          test ! -s conftest.err
17915        } && test -s conftest.$ac_objext; then
17916   ac_cv_sys_file_offset_bits=64; break
17917 else
17918   $as_echo "$as_me: failed program was:" >&5
17919 sed 's/^/| /' conftest.$ac_ext >&5
17920
17921
17922 fi
17923
17924 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17925   ac_cv_sys_file_offset_bits=unknown
17926   break
17927 done
17928 fi
17929 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_file_offset_bits" >&5
17930 $as_echo "$ac_cv_sys_file_offset_bits" >&6; }
17931 case $ac_cv_sys_file_offset_bits in #(
17932   no | unknown) ;;
17933   *)
17934 cat >>confdefs.h <<_ACEOF
17935 #define _FILE_OFFSET_BITS $ac_cv_sys_file_offset_bits
17936 _ACEOF
17937 ;;
17938 esac
17939 rm -rf conftest*
17940   if test $ac_cv_sys_file_offset_bits = unknown; then
17941     { $as_echo "$as_me:$LINENO: checking for _LARGE_FILES value needed for large files" >&5
17942 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; }
17943 if test "${ac_cv_sys_large_files+set}" = set; then
17944   $as_echo_n "(cached) " >&6
17945 else
17946   while :; do
17947   cat >conftest.$ac_ext <<_ACEOF
17948 /* confdefs.h.  */
17949 _ACEOF
17950 cat confdefs.h >>conftest.$ac_ext
17951 cat >>conftest.$ac_ext <<_ACEOF
17952 /* end confdefs.h.  */
17953 #include <sys/types.h>
17954  /* Check that off_t can represent 2**63 - 1 correctly.
17955     We can't simply define LARGE_OFF_T to be 9223372036854775807,
17956     since some C++ compilers masquerading as C compilers
17957     incorrectly reject 9223372036854775807.  */
17958 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
17959   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
17960                        && LARGE_OFF_T % 2147483647 == 1)
17961                       ? 1 : -1];
17962 int
17963 main ()
17964 {
17965
17966   ;
17967   return 0;
17968 }
17969 _ACEOF
17970 rm -f conftest.$ac_objext
17971 if { (ac_try="$ac_compile"
17972 case "(($ac_try" in
17973   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
17974   *) ac_try_echo=$ac_try;;
17975 esac
17976 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
17977 $as_echo "$ac_try_echo") >&5
17978   (eval "$ac_compile") 2>conftest.er1
17979   ac_status=$?
17980   grep -v '^ *+' conftest.er1 >conftest.err
17981   rm -f conftest.er1
17982   cat conftest.err >&5
17983   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
17984   (exit $ac_status); } && {
17985          test -z "$ac_c_werror_flag" ||
17986          test ! -s conftest.err
17987        } && test -s conftest.$ac_objext; then
17988   ac_cv_sys_large_files=no; break
17989 else
17990   $as_echo "$as_me: failed program was:" >&5
17991 sed 's/^/| /' conftest.$ac_ext >&5
17992
17993
17994 fi
17995
17996 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
17997   cat >conftest.$ac_ext <<_ACEOF
17998 /* confdefs.h.  */
17999 _ACEOF
18000 cat confdefs.h >>conftest.$ac_ext
18001 cat >>conftest.$ac_ext <<_ACEOF
18002 /* end confdefs.h.  */
18003 #define _LARGE_FILES 1
18004 #include <sys/types.h>
18005  /* Check that off_t can represent 2**63 - 1 correctly.
18006     We can't simply define LARGE_OFF_T to be 9223372036854775807,
18007     since some C++ compilers masquerading as C compilers
18008     incorrectly reject 9223372036854775807.  */
18009 #define LARGE_OFF_T (((off_t) 1 << 62) - 1 + ((off_t) 1 << 62))
18010   int off_t_is_large[(LARGE_OFF_T % 2147483629 == 721
18011                        && LARGE_OFF_T % 2147483647 == 1)
18012                       ? 1 : -1];
18013 int
18014 main ()
18015 {
18016
18017   ;
18018   return 0;
18019 }
18020 _ACEOF
18021 rm -f conftest.$ac_objext
18022 if { (ac_try="$ac_compile"
18023 case "(($ac_try" in
18024   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18025   *) ac_try_echo=$ac_try;;
18026 esac
18027 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18028 $as_echo "$ac_try_echo") >&5
18029   (eval "$ac_compile") 2>conftest.er1
18030   ac_status=$?
18031   grep -v '^ *+' conftest.er1 >conftest.err
18032   rm -f conftest.er1
18033   cat conftest.err >&5
18034   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18035   (exit $ac_status); } && {
18036          test -z "$ac_c_werror_flag" ||
18037          test ! -s conftest.err
18038        } && test -s conftest.$ac_objext; then
18039   ac_cv_sys_large_files=1; break
18040 else
18041   $as_echo "$as_me: failed program was:" >&5
18042 sed 's/^/| /' conftest.$ac_ext >&5
18043
18044
18045 fi
18046
18047 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18048   ac_cv_sys_large_files=unknown
18049   break
18050 done
18051 fi
18052 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_large_files" >&5
18053 $as_echo "$ac_cv_sys_large_files" >&6; }
18054 case $ac_cv_sys_large_files in #(
18055   no | unknown) ;;
18056   *)
18057 cat >>confdefs.h <<_ACEOF
18058 #define _LARGE_FILES $ac_cv_sys_large_files
18059 _ACEOF
18060 ;;
18061 esac
18062 rm -rf conftest*
18063   fi
18064 fi
18065
18066
18067 # Check for largefile support (must be after AC_SYS_LARGEFILE)
18068 # The cast to long int works around a bug in the HP C Compiler
18069 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
18070 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
18071 # This bug is HP SR number 8606223364.
18072 { $as_echo "$as_me:$LINENO: checking size of off_t" >&5
18073 $as_echo_n "checking size of off_t... " >&6; }
18074 if test "${ac_cv_sizeof_off_t+set}" = set; then
18075   $as_echo_n "(cached) " >&6
18076 else
18077   if test "$cross_compiling" = yes; then
18078   # Depending upon the size, compute the lo and hi bounds.
18079 cat >conftest.$ac_ext <<_ACEOF
18080 /* confdefs.h.  */
18081 _ACEOF
18082 cat confdefs.h >>conftest.$ac_ext
18083 cat >>conftest.$ac_ext <<_ACEOF
18084 /* end confdefs.h.  */
18085 $ac_includes_default
18086 int
18087 main ()
18088 {
18089 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= 0)];
18090 test_array [0] = 0
18091
18092   ;
18093   return 0;
18094 }
18095 _ACEOF
18096 rm -f conftest.$ac_objext
18097 if { (ac_try="$ac_compile"
18098 case "(($ac_try" in
18099   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18100   *) ac_try_echo=$ac_try;;
18101 esac
18102 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18103 $as_echo "$ac_try_echo") >&5
18104   (eval "$ac_compile") 2>conftest.er1
18105   ac_status=$?
18106   grep -v '^ *+' conftest.er1 >conftest.err
18107   rm -f conftest.er1
18108   cat conftest.err >&5
18109   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18110   (exit $ac_status); } && {
18111          test -z "$ac_c_werror_flag" ||
18112          test ! -s conftest.err
18113        } && test -s conftest.$ac_objext; then
18114   ac_lo=0 ac_mid=0
18115   while :; do
18116     cat >conftest.$ac_ext <<_ACEOF
18117 /* confdefs.h.  */
18118 _ACEOF
18119 cat confdefs.h >>conftest.$ac_ext
18120 cat >>conftest.$ac_ext <<_ACEOF
18121 /* end confdefs.h.  */
18122 $ac_includes_default
18123 int
18124 main ()
18125 {
18126 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)];
18127 test_array [0] = 0
18128
18129   ;
18130   return 0;
18131 }
18132 _ACEOF
18133 rm -f conftest.$ac_objext
18134 if { (ac_try="$ac_compile"
18135 case "(($ac_try" in
18136   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18137   *) ac_try_echo=$ac_try;;
18138 esac
18139 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18140 $as_echo "$ac_try_echo") >&5
18141   (eval "$ac_compile") 2>conftest.er1
18142   ac_status=$?
18143   grep -v '^ *+' conftest.er1 >conftest.err
18144   rm -f conftest.er1
18145   cat conftest.err >&5
18146   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18147   (exit $ac_status); } && {
18148          test -z "$ac_c_werror_flag" ||
18149          test ! -s conftest.err
18150        } && test -s conftest.$ac_objext; then
18151   ac_hi=$ac_mid; break
18152 else
18153   $as_echo "$as_me: failed program was:" >&5
18154 sed 's/^/| /' conftest.$ac_ext >&5
18155
18156         ac_lo=`expr $ac_mid + 1`
18157                         if test $ac_lo -le $ac_mid; then
18158                           ac_lo= ac_hi=
18159                           break
18160                         fi
18161                         ac_mid=`expr 2 '*' $ac_mid + 1`
18162 fi
18163
18164 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18165   done
18166 else
18167   $as_echo "$as_me: failed program was:" >&5
18168 sed 's/^/| /' conftest.$ac_ext >&5
18169
18170         cat >conftest.$ac_ext <<_ACEOF
18171 /* confdefs.h.  */
18172 _ACEOF
18173 cat confdefs.h >>conftest.$ac_ext
18174 cat >>conftest.$ac_ext <<_ACEOF
18175 /* end confdefs.h.  */
18176 $ac_includes_default
18177 int
18178 main ()
18179 {
18180 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) < 0)];
18181 test_array [0] = 0
18182
18183   ;
18184   return 0;
18185 }
18186 _ACEOF
18187 rm -f conftest.$ac_objext
18188 if { (ac_try="$ac_compile"
18189 case "(($ac_try" in
18190   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18191   *) ac_try_echo=$ac_try;;
18192 esac
18193 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18194 $as_echo "$ac_try_echo") >&5
18195   (eval "$ac_compile") 2>conftest.er1
18196   ac_status=$?
18197   grep -v '^ *+' conftest.er1 >conftest.err
18198   rm -f conftest.er1
18199   cat conftest.err >&5
18200   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18201   (exit $ac_status); } && {
18202          test -z "$ac_c_werror_flag" ||
18203          test ! -s conftest.err
18204        } && test -s conftest.$ac_objext; then
18205   ac_hi=-1 ac_mid=-1
18206   while :; do
18207     cat >conftest.$ac_ext <<_ACEOF
18208 /* confdefs.h.  */
18209 _ACEOF
18210 cat confdefs.h >>conftest.$ac_ext
18211 cat >>conftest.$ac_ext <<_ACEOF
18212 /* end confdefs.h.  */
18213 $ac_includes_default
18214 int
18215 main ()
18216 {
18217 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) >= $ac_mid)];
18218 test_array [0] = 0
18219
18220   ;
18221   return 0;
18222 }
18223 _ACEOF
18224 rm -f conftest.$ac_objext
18225 if { (ac_try="$ac_compile"
18226 case "(($ac_try" in
18227   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18228   *) ac_try_echo=$ac_try;;
18229 esac
18230 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18231 $as_echo "$ac_try_echo") >&5
18232   (eval "$ac_compile") 2>conftest.er1
18233   ac_status=$?
18234   grep -v '^ *+' conftest.er1 >conftest.err
18235   rm -f conftest.er1
18236   cat conftest.err >&5
18237   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18238   (exit $ac_status); } && {
18239          test -z "$ac_c_werror_flag" ||
18240          test ! -s conftest.err
18241        } && test -s conftest.$ac_objext; then
18242   ac_lo=$ac_mid; break
18243 else
18244   $as_echo "$as_me: failed program was:" >&5
18245 sed 's/^/| /' conftest.$ac_ext >&5
18246
18247         ac_hi=`expr '(' $ac_mid ')' - 1`
18248                         if test $ac_mid -le $ac_hi; then
18249                           ac_lo= ac_hi=
18250                           break
18251                         fi
18252                         ac_mid=`expr 2 '*' $ac_mid`
18253 fi
18254
18255 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18256   done
18257 else
18258   $as_echo "$as_me: failed program was:" >&5
18259 sed 's/^/| /' conftest.$ac_ext >&5
18260
18261         ac_lo= ac_hi=
18262 fi
18263
18264 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18265 fi
18266
18267 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18268 # Binary search between lo and hi bounds.
18269 while test "x$ac_lo" != "x$ac_hi"; do
18270   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
18271   cat >conftest.$ac_ext <<_ACEOF
18272 /* confdefs.h.  */
18273 _ACEOF
18274 cat confdefs.h >>conftest.$ac_ext
18275 cat >>conftest.$ac_ext <<_ACEOF
18276 /* end confdefs.h.  */
18277 $ac_includes_default
18278 int
18279 main ()
18280 {
18281 static int test_array [1 - 2 * !(((long int) (sizeof (off_t))) <= $ac_mid)];
18282 test_array [0] = 0
18283
18284   ;
18285   return 0;
18286 }
18287 _ACEOF
18288 rm -f conftest.$ac_objext
18289 if { (ac_try="$ac_compile"
18290 case "(($ac_try" in
18291   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18292   *) ac_try_echo=$ac_try;;
18293 esac
18294 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18295 $as_echo "$ac_try_echo") >&5
18296   (eval "$ac_compile") 2>conftest.er1
18297   ac_status=$?
18298   grep -v '^ *+' conftest.er1 >conftest.err
18299   rm -f conftest.er1
18300   cat conftest.err >&5
18301   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18302   (exit $ac_status); } && {
18303          test -z "$ac_c_werror_flag" ||
18304          test ! -s conftest.err
18305        } && test -s conftest.$ac_objext; then
18306   ac_hi=$ac_mid
18307 else
18308   $as_echo "$as_me: failed program was:" >&5
18309 sed 's/^/| /' conftest.$ac_ext >&5
18310
18311         ac_lo=`expr '(' $ac_mid ')' + 1`
18312 fi
18313
18314 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18315 done
18316 case $ac_lo in
18317 ?*) ac_cv_sizeof_off_t=$ac_lo;;
18318 '') if test "$ac_cv_type_off_t" = yes; then
18319      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18320 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18321 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
18322 See \`config.log' for more details." >&5
18323 $as_echo "$as_me: error: cannot compute sizeof (off_t)
18324 See \`config.log' for more details." >&2;}
18325    { (exit 77); exit 77; }; }; }
18326    else
18327      ac_cv_sizeof_off_t=0
18328    fi ;;
18329 esac
18330 else
18331   cat >conftest.$ac_ext <<_ACEOF
18332 /* confdefs.h.  */
18333 _ACEOF
18334 cat confdefs.h >>conftest.$ac_ext
18335 cat >>conftest.$ac_ext <<_ACEOF
18336 /* end confdefs.h.  */
18337 $ac_includes_default
18338 static long int longval () { return (long int) (sizeof (off_t)); }
18339 static unsigned long int ulongval () { return (long int) (sizeof (off_t)); }
18340 #include <stdio.h>
18341 #include <stdlib.h>
18342 int
18343 main ()
18344 {
18345
18346   FILE *f = fopen ("conftest.val", "w");
18347   if (! f)
18348     return 1;
18349   if (((long int) (sizeof (off_t))) < 0)
18350     {
18351       long int i = longval ();
18352       if (i != ((long int) (sizeof (off_t))))
18353         return 1;
18354       fprintf (f, "%ld", i);
18355     }
18356   else
18357     {
18358       unsigned long int i = ulongval ();
18359       if (i != ((long int) (sizeof (off_t))))
18360         return 1;
18361       fprintf (f, "%lu", i);
18362     }
18363   /* Do not output a trailing newline, as this causes \r\n confusion
18364      on some platforms.  */
18365   return ferror (f) || fclose (f) != 0;
18366
18367   ;
18368   return 0;
18369 }
18370 _ACEOF
18371 rm -f conftest$ac_exeext
18372 if { (ac_try="$ac_link"
18373 case "(($ac_try" in
18374   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18375   *) ac_try_echo=$ac_try;;
18376 esac
18377 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18378 $as_echo "$ac_try_echo") >&5
18379   (eval "$ac_link") 2>&5
18380   ac_status=$?
18381   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18382   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
18383   { (case "(($ac_try" in
18384   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18385   *) ac_try_echo=$ac_try;;
18386 esac
18387 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18388 $as_echo "$ac_try_echo") >&5
18389   (eval "$ac_try") 2>&5
18390   ac_status=$?
18391   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18392   (exit $ac_status); }; }; then
18393   ac_cv_sizeof_off_t=`cat conftest.val`
18394 else
18395   $as_echo "$as_me: program exited with status $ac_status" >&5
18396 $as_echo "$as_me: failed program was:" >&5
18397 sed 's/^/| /' conftest.$ac_ext >&5
18398
18399 ( exit $ac_status )
18400 if test "$ac_cv_type_off_t" = yes; then
18401      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
18402 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
18403 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (off_t)
18404 See \`config.log' for more details." >&5
18405 $as_echo "$as_me: error: cannot compute sizeof (off_t)
18406 See \`config.log' for more details." >&2;}
18407    { (exit 77); exit 77; }; }; }
18408    else
18409      ac_cv_sizeof_off_t=0
18410    fi
18411 fi
18412 rm -rf conftest.dSYM
18413 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
18414 fi
18415 rm -f conftest.val
18416 fi
18417 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_off_t" >&5
18418 $as_echo "$ac_cv_sizeof_off_t" >&6; }
18419
18420
18421
18422 cat >>confdefs.h <<_ACEOF
18423 #define SIZEOF_OFF_T $ac_cv_sizeof_off_t
18424 _ACEOF
18425
18426
18427
18428 # If we don't have largefile support, can't handle segsize >= 2GB.
18429 if test "$ac_cv_sizeof_off_t" -lt 8 -a "$segsize" != "1"; then
18430    { { $as_echo "$as_me:$LINENO: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&5
18431 $as_echo "$as_me: error: Large file support is not enabled. Segment size cannot be larger than 1GB." >&2;}
18432    { (exit 1); exit 1; }; }
18433 fi
18434
18435
18436 ##
18437 ## Functions, global variables
18438 ##
18439
18440 { $as_echo "$as_me:$LINENO: checking for int timezone" >&5
18441 $as_echo_n "checking for int timezone... " >&6; }
18442 if test "${pgac_cv_var_int_timezone+set}" = set; then
18443   $as_echo_n "(cached) " >&6
18444 else
18445   cat >conftest.$ac_ext <<_ACEOF
18446 /* confdefs.h.  */
18447 _ACEOF
18448 cat confdefs.h >>conftest.$ac_ext
18449 cat >>conftest.$ac_ext <<_ACEOF
18450 /* end confdefs.h.  */
18451 #include <time.h>
18452 int res;
18453 int
18454 main ()
18455 {
18456 #ifndef __CYGWIN__
18457 res = timezone / 60;
18458 #else
18459 res = _timezone / 60;
18460 #endif
18461   ;
18462   return 0;
18463 }
18464 _ACEOF
18465 rm -f conftest.$ac_objext conftest$ac_exeext
18466 if { (ac_try="$ac_link"
18467 case "(($ac_try" in
18468   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18469   *) ac_try_echo=$ac_try;;
18470 esac
18471 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18472 $as_echo "$ac_try_echo") >&5
18473   (eval "$ac_link") 2>conftest.er1
18474   ac_status=$?
18475   grep -v '^ *+' conftest.er1 >conftest.err
18476   rm -f conftest.er1
18477   cat conftest.err >&5
18478   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18479   (exit $ac_status); } && {
18480          test -z "$ac_c_werror_flag" ||
18481          test ! -s conftest.err
18482        } && test -s conftest$ac_exeext && {
18483          test "$cross_compiling" = yes ||
18484          $as_test_x conftest$ac_exeext
18485        }; then
18486   pgac_cv_var_int_timezone=yes
18487 else
18488   $as_echo "$as_me: failed program was:" >&5
18489 sed 's/^/| /' conftest.$ac_ext >&5
18490
18491         pgac_cv_var_int_timezone=no
18492 fi
18493
18494 rm -rf conftest.dSYM
18495 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18496       conftest$ac_exeext conftest.$ac_ext
18497 fi
18498 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_timezone" >&5
18499 $as_echo "$pgac_cv_var_int_timezone" >&6; }
18500 if test x"$pgac_cv_var_int_timezone" = xyes ; then
18501
18502 cat >>confdefs.h <<\_ACEOF
18503 #define HAVE_INT_TIMEZONE /**/
18504 _ACEOF
18505
18506 fi
18507 { $as_echo "$as_me:$LINENO: checking types of arguments for accept()" >&5
18508 $as_echo_n "checking types of arguments for accept()... " >&6; }
18509  if test "${ac_cv_func_accept_return+set}" = set; then
18510   $as_echo_n "(cached) " >&6
18511 else
18512    if test "${ac_cv_func_accept_arg1+set}" = set; then
18513   $as_echo_n "(cached) " >&6
18514 else
18515     if test "${ac_cv_func_accept_arg2+set}" = set; then
18516   $as_echo_n "(cached) " >&6
18517 else
18518      if test "${ac_cv_func_accept_arg3+set}" = set; then
18519   $as_echo_n "(cached) " >&6
18520 else
18521       for ac_cv_func_accept_return in 'int' 'unsigned int PASCAL'; do
18522       for ac_cv_func_accept_arg1 in 'int' 'unsigned int'; do
18523        for ac_cv_func_accept_arg2 in 'struct sockaddr *' 'const struct sockaddr *' 'void *'; do
18524         for ac_cv_func_accept_arg3 in 'int' 'size_t' 'socklen_t' 'unsigned int' 'void'; do
18525          cat >conftest.$ac_ext <<_ACEOF
18526 /* confdefs.h.  */
18527 _ACEOF
18528 cat confdefs.h >>conftest.$ac_ext
18529 cat >>conftest.$ac_ext <<_ACEOF
18530 /* end confdefs.h.  */
18531 #ifdef HAVE_SYS_TYPES_H
18532 #include <sys/types.h>
18533 #endif
18534 #ifdef HAVE_SYS_SOCKET_H
18535 #include <sys/socket.h>
18536 #endif
18537 extern $ac_cv_func_accept_return accept ($ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *);
18538 int
18539 main ()
18540 {
18541
18542   ;
18543   return 0;
18544 }
18545 _ACEOF
18546 rm -f conftest.$ac_objext
18547 if { (ac_try="$ac_compile"
18548 case "(($ac_try" in
18549   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18550   *) ac_try_echo=$ac_try;;
18551 esac
18552 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18553 $as_echo "$ac_try_echo") >&5
18554   (eval "$ac_compile") 2>conftest.er1
18555   ac_status=$?
18556   grep -v '^ *+' conftest.er1 >conftest.err
18557   rm -f conftest.er1
18558   cat conftest.err >&5
18559   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18560   (exit $ac_status); } && {
18561          test -z "$ac_c_werror_flag" ||
18562          test ! -s conftest.err
18563        } && test -s conftest.$ac_objext; then
18564   ac_not_found=no; break 4
18565 else
18566   $as_echo "$as_me: failed program was:" >&5
18567 sed 's/^/| /' conftest.$ac_ext >&5
18568
18569         ac_not_found=yes
18570 fi
18571
18572 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18573        done
18574       done
18575      done
18576     done
18577     if test "$ac_not_found" = yes; then
18578       { { $as_echo "$as_me:$LINENO: error: could not determine argument types" >&5
18579 $as_echo "$as_me: error: could not determine argument types" >&2;}
18580    { (exit 1); exit 1; }; }
18581     fi
18582     if test "$ac_cv_func_accept_arg3" = "void"; then
18583       ac_cv_func_accept_arg3=int
18584     fi
18585
18586 fi
18587
18588 fi
18589
18590 fi
18591
18592 fi
18593  { $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
18594 $as_echo "$ac_cv_func_accept_return, $ac_cv_func_accept_arg1, $ac_cv_func_accept_arg2, $ac_cv_func_accept_arg3 *" >&6; }
18595
18596 cat >>confdefs.h <<_ACEOF
18597 #define ACCEPT_TYPE_RETURN $ac_cv_func_accept_return
18598 _ACEOF
18599
18600
18601 cat >>confdefs.h <<_ACEOF
18602 #define ACCEPT_TYPE_ARG1 $ac_cv_func_accept_arg1
18603 _ACEOF
18604
18605
18606 cat >>confdefs.h <<_ACEOF
18607 #define ACCEPT_TYPE_ARG2 $ac_cv_func_accept_arg2
18608 _ACEOF
18609
18610
18611 cat >>confdefs.h <<_ACEOF
18612 #define ACCEPT_TYPE_ARG3 $ac_cv_func_accept_arg3
18613 _ACEOF
18614
18615
18616 { $as_echo "$as_me:$LINENO: checking whether gettimeofday takes only one argument" >&5
18617 $as_echo_n "checking whether gettimeofday takes only one argument... " >&6; }
18618 if test "${pgac_cv_func_gettimeofday_1arg+set}" = set; then
18619   $as_echo_n "(cached) " >&6
18620 else
18621   cat >conftest.$ac_ext <<_ACEOF
18622 /* confdefs.h.  */
18623 _ACEOF
18624 cat confdefs.h >>conftest.$ac_ext
18625 cat >>conftest.$ac_ext <<_ACEOF
18626 /* end confdefs.h.  */
18627 #include <sys/time.h>
18628 int
18629 main ()
18630 {
18631 struct timeval *tp;
18632 struct timezone *tzp;
18633 gettimeofday(tp,tzp);
18634   ;
18635   return 0;
18636 }
18637 _ACEOF
18638 rm -f conftest.$ac_objext
18639 if { (ac_try="$ac_compile"
18640 case "(($ac_try" in
18641   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18642   *) ac_try_echo=$ac_try;;
18643 esac
18644 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18645 $as_echo "$ac_try_echo") >&5
18646   (eval "$ac_compile") 2>conftest.er1
18647   ac_status=$?
18648   grep -v '^ *+' conftest.er1 >conftest.err
18649   rm -f conftest.er1
18650   cat conftest.err >&5
18651   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18652   (exit $ac_status); } && {
18653          test -z "$ac_c_werror_flag" ||
18654          test ! -s conftest.err
18655        } && test -s conftest.$ac_objext; then
18656   pgac_cv_func_gettimeofday_1arg=no
18657 else
18658   $as_echo "$as_me: failed program was:" >&5
18659 sed 's/^/| /' conftest.$ac_ext >&5
18660
18661         pgac_cv_func_gettimeofday_1arg=yes
18662 fi
18663
18664 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
18665 fi
18666 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_gettimeofday_1arg" >&5
18667 $as_echo "$pgac_cv_func_gettimeofday_1arg" >&6; }
18668 if test x"$pgac_cv_func_gettimeofday_1arg" = xyes ; then
18669
18670 cat >>confdefs.h <<\_ACEOF
18671 #define GETTIMEOFDAY_1ARG /**/
18672 _ACEOF
18673
18674 fi
18675
18676
18677
18678
18679
18680
18681
18682
18683
18684
18685
18686
18687
18688
18689
18690
18691
18692
18693
18694
18695
18696
18697
18698
18699
18700
18701 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
18702 do
18703 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18704 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18705 $as_echo_n "checking for $ac_func... " >&6; }
18706 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18707   $as_echo_n "(cached) " >&6
18708 else
18709   cat >conftest.$ac_ext <<_ACEOF
18710 /* confdefs.h.  */
18711 _ACEOF
18712 cat confdefs.h >>conftest.$ac_ext
18713 cat >>conftest.$ac_ext <<_ACEOF
18714 /* end confdefs.h.  */
18715 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18716    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18717 #define $ac_func innocuous_$ac_func
18718
18719 /* System header to define __stub macros and hopefully few prototypes,
18720     which can conflict with char $ac_func (); below.
18721     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18722     <limits.h> exists even on freestanding compilers.  */
18723
18724 #ifdef __STDC__
18725 # include <limits.h>
18726 #else
18727 # include <assert.h>
18728 #endif
18729
18730 #undef $ac_func
18731
18732 /* Override any GCC internal prototype to avoid an error.
18733    Use char because int might match the return type of a GCC
18734    builtin and then its argument prototype would still apply.  */
18735 #ifdef __cplusplus
18736 extern "C"
18737 #endif
18738 char $ac_func ();
18739 /* The GNU C library defines this for functions which it implements
18740     to always fail with ENOSYS.  Some functions are actually named
18741     something starting with __ and the normal name is an alias.  */
18742 #if defined __stub_$ac_func || defined __stub___$ac_func
18743 choke me
18744 #endif
18745
18746 int
18747 main ()
18748 {
18749 return $ac_func ();
18750   ;
18751   return 0;
18752 }
18753 _ACEOF
18754 rm -f conftest.$ac_objext conftest$ac_exeext
18755 if { (ac_try="$ac_link"
18756 case "(($ac_try" in
18757   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18758   *) ac_try_echo=$ac_try;;
18759 esac
18760 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18761 $as_echo "$ac_try_echo") >&5
18762   (eval "$ac_link") 2>conftest.er1
18763   ac_status=$?
18764   grep -v '^ *+' conftest.er1 >conftest.err
18765   rm -f conftest.er1
18766   cat conftest.err >&5
18767   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18768   (exit $ac_status); } && {
18769          test -z "$ac_c_werror_flag" ||
18770          test ! -s conftest.err
18771        } && test -s conftest$ac_exeext && {
18772          test "$cross_compiling" = yes ||
18773          $as_test_x conftest$ac_exeext
18774        }; then
18775   eval "$as_ac_var=yes"
18776 else
18777   $as_echo "$as_me: failed program was:" >&5
18778 sed 's/^/| /' conftest.$ac_ext >&5
18779
18780         eval "$as_ac_var=no"
18781 fi
18782
18783 rm -rf conftest.dSYM
18784 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18785       conftest$ac_exeext conftest.$ac_ext
18786 fi
18787 ac_res=`eval 'as_val=${'$as_ac_var'}
18788                  $as_echo "$as_val"'`
18789                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
18790 $as_echo "$ac_res" >&6; }
18791 as_val=`eval 'as_val=${'$as_ac_var'}
18792                  $as_echo "$as_val"'`
18793    if test "x$as_val" = x""yes; then
18794   cat >>confdefs.h <<_ACEOF
18795 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18796 _ACEOF
18797
18798 fi
18799 done
18800
18801
18802
18803 for ac_func in fseeko
18804 do
18805 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
18806 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
18807 $as_echo_n "checking for $ac_func... " >&6; }
18808 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
18809   $as_echo_n "(cached) " >&6
18810 else
18811   cat >conftest.$ac_ext <<_ACEOF
18812 /* confdefs.h.  */
18813 _ACEOF
18814 cat confdefs.h >>conftest.$ac_ext
18815 cat >>conftest.$ac_ext <<_ACEOF
18816 /* end confdefs.h.  */
18817 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
18818    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
18819 #define $ac_func innocuous_$ac_func
18820
18821 /* System header to define __stub macros and hopefully few prototypes,
18822     which can conflict with char $ac_func (); below.
18823     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
18824     <limits.h> exists even on freestanding compilers.  */
18825
18826 #ifdef __STDC__
18827 # include <limits.h>
18828 #else
18829 # include <assert.h>
18830 #endif
18831
18832 #undef $ac_func
18833
18834 /* Override any GCC internal prototype to avoid an error.
18835    Use char because int might match the return type of a GCC
18836    builtin and then its argument prototype would still apply.  */
18837 #ifdef __cplusplus
18838 extern "C"
18839 #endif
18840 char $ac_func ();
18841 /* The GNU C library defines this for functions which it implements
18842     to always fail with ENOSYS.  Some functions are actually named
18843     something starting with __ and the normal name is an alias.  */
18844 #if defined __stub_$ac_func || defined __stub___$ac_func
18845 choke me
18846 #endif
18847
18848 int
18849 main ()
18850 {
18851 return $ac_func ();
18852   ;
18853   return 0;
18854 }
18855 _ACEOF
18856 rm -f conftest.$ac_objext conftest$ac_exeext
18857 if { (ac_try="$ac_link"
18858 case "(($ac_try" in
18859   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18860   *) ac_try_echo=$ac_try;;
18861 esac
18862 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18863 $as_echo "$ac_try_echo") >&5
18864   (eval "$ac_link") 2>conftest.er1
18865   ac_status=$?
18866   grep -v '^ *+' conftest.er1 >conftest.err
18867   rm -f conftest.er1
18868   cat conftest.err >&5
18869   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18870   (exit $ac_status); } && {
18871          test -z "$ac_c_werror_flag" ||
18872          test ! -s conftest.err
18873        } && test -s conftest$ac_exeext && {
18874          test "$cross_compiling" = yes ||
18875          $as_test_x conftest$ac_exeext
18876        }; then
18877   eval "$as_ac_var=yes"
18878 else
18879   $as_echo "$as_me: failed program was:" >&5
18880 sed 's/^/| /' conftest.$ac_ext >&5
18881
18882         eval "$as_ac_var=no"
18883 fi
18884
18885 rm -rf conftest.dSYM
18886 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18887       conftest$ac_exeext conftest.$ac_ext
18888 fi
18889 ac_res=`eval 'as_val=${'$as_ac_var'}
18890                  $as_echo "$as_val"'`
18891                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
18892 $as_echo "$ac_res" >&6; }
18893 as_val=`eval 'as_val=${'$as_ac_var'}
18894                  $as_echo "$as_val"'`
18895    if test "x$as_val" = x""yes; then
18896   cat >>confdefs.h <<_ACEOF
18897 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
18898 _ACEOF
18899
18900 else
18901   case " $LIBOBJS " in
18902   *" $ac_func.$ac_objext "* ) ;;
18903   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
18904  ;;
18905 esac
18906
18907 fi
18908 done
18909
18910
18911 case $host_os in
18912         # BSD/OS & NetBSD use a custom fseeko/ftello built on fsetpos/fgetpos
18913         # Mingw uses macros to access Win32 API calls
18914         bsdi*|netbsd*|mingw*)
18915
18916 cat >>confdefs.h <<\_ACEOF
18917 #define HAVE_FSEEKO 1
18918 _ACEOF
18919
18920                 ac_cv_func_fseeko=yes;;
18921         *)
18922                 { $as_echo "$as_me:$LINENO: checking for _LARGEFILE_SOURCE value needed for large files" >&5
18923 $as_echo_n "checking for _LARGEFILE_SOURCE value needed for large files... " >&6; }
18924 if test "${ac_cv_sys_largefile_source+set}" = set; then
18925   $as_echo_n "(cached) " >&6
18926 else
18927   while :; do
18928   cat >conftest.$ac_ext <<_ACEOF
18929 /* confdefs.h.  */
18930 _ACEOF
18931 cat confdefs.h >>conftest.$ac_ext
18932 cat >>conftest.$ac_ext <<_ACEOF
18933 /* end confdefs.h.  */
18934 #include <sys/types.h> /* for off_t */
18935      #include <stdio.h>
18936 int
18937 main ()
18938 {
18939 int (*fp) (FILE *, off_t, int) = fseeko;
18940      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
18941   ;
18942   return 0;
18943 }
18944 _ACEOF
18945 rm -f conftest.$ac_objext conftest$ac_exeext
18946 if { (ac_try="$ac_link"
18947 case "(($ac_try" in
18948   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18949   *) ac_try_echo=$ac_try;;
18950 esac
18951 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
18952 $as_echo "$ac_try_echo") >&5
18953   (eval "$ac_link") 2>conftest.er1
18954   ac_status=$?
18955   grep -v '^ *+' conftest.er1 >conftest.err
18956   rm -f conftest.er1
18957   cat conftest.err >&5
18958   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
18959   (exit $ac_status); } && {
18960          test -z "$ac_c_werror_flag" ||
18961          test ! -s conftest.err
18962        } && test -s conftest$ac_exeext && {
18963          test "$cross_compiling" = yes ||
18964          $as_test_x conftest$ac_exeext
18965        }; then
18966   ac_cv_sys_largefile_source=no; break
18967 else
18968   $as_echo "$as_me: failed program was:" >&5
18969 sed 's/^/| /' conftest.$ac_ext >&5
18970
18971
18972 fi
18973
18974 rm -rf conftest.dSYM
18975 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
18976       conftest$ac_exeext conftest.$ac_ext
18977   cat >conftest.$ac_ext <<_ACEOF
18978 /* confdefs.h.  */
18979 _ACEOF
18980 cat confdefs.h >>conftest.$ac_ext
18981 cat >>conftest.$ac_ext <<_ACEOF
18982 /* end confdefs.h.  */
18983 #define _LARGEFILE_SOURCE 1
18984 #include <sys/types.h> /* for off_t */
18985      #include <stdio.h>
18986 int
18987 main ()
18988 {
18989 int (*fp) (FILE *, off_t, int) = fseeko;
18990      return fseeko (stdin, 0, 0) && fp (stdin, 0, 0);
18991   ;
18992   return 0;
18993 }
18994 _ACEOF
18995 rm -f conftest.$ac_objext conftest$ac_exeext
18996 if { (ac_try="$ac_link"
18997 case "(($ac_try" in
18998   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
18999   *) ac_try_echo=$ac_try;;
19000 esac
19001 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19002 $as_echo "$ac_try_echo") >&5
19003   (eval "$ac_link") 2>conftest.er1
19004   ac_status=$?
19005   grep -v '^ *+' conftest.er1 >conftest.err
19006   rm -f conftest.er1
19007   cat conftest.err >&5
19008   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19009   (exit $ac_status); } && {
19010          test -z "$ac_c_werror_flag" ||
19011          test ! -s conftest.err
19012        } && test -s conftest$ac_exeext && {
19013          test "$cross_compiling" = yes ||
19014          $as_test_x conftest$ac_exeext
19015        }; then
19016   ac_cv_sys_largefile_source=1; break
19017 else
19018   $as_echo "$as_me: failed program was:" >&5
19019 sed 's/^/| /' conftest.$ac_ext >&5
19020
19021
19022 fi
19023
19024 rm -rf conftest.dSYM
19025 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19026       conftest$ac_exeext conftest.$ac_ext
19027   ac_cv_sys_largefile_source=unknown
19028   break
19029 done
19030 fi
19031 { $as_echo "$as_me:$LINENO: result: $ac_cv_sys_largefile_source" >&5
19032 $as_echo "$ac_cv_sys_largefile_source" >&6; }
19033 case $ac_cv_sys_largefile_source in #(
19034   no | unknown) ;;
19035   *)
19036 cat >>confdefs.h <<_ACEOF
19037 #define _LARGEFILE_SOURCE $ac_cv_sys_largefile_source
19038 _ACEOF
19039 ;;
19040 esac
19041 rm -rf conftest*
19042
19043 # We used to try defining _XOPEN_SOURCE=500 too, to work around a bug
19044 # in glibc 2.1.3, but that breaks too many other things.
19045 # If you want fseeko and ftello with glibc, upgrade to a fixed glibc.
19046 if test $ac_cv_sys_largefile_source != unknown; then
19047
19048 cat >>confdefs.h <<\_ACEOF
19049 #define HAVE_FSEEKO 1
19050 _ACEOF
19051
19052 fi
19053 ;;
19054 esac
19055
19056 # posix_fadvise() is a no-op on Solaris, so don't incur function overhead
19057 # by calling it, 2009-04-02
19058 # http://src.opensolaris.org/source/xref/onnv/onnv-gate/usr/src/lib/libc/port/gen/posix_fadvise.c
19059 if test "$PORTNAME" != "solaris"; then
19060
19061 for ac_func in posix_fadvise
19062 do
19063 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19064 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19065 $as_echo_n "checking for $ac_func... " >&6; }
19066 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19067   $as_echo_n "(cached) " >&6
19068 else
19069   cat >conftest.$ac_ext <<_ACEOF
19070 /* confdefs.h.  */
19071 _ACEOF
19072 cat confdefs.h >>conftest.$ac_ext
19073 cat >>conftest.$ac_ext <<_ACEOF
19074 /* end confdefs.h.  */
19075 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19076    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19077 #define $ac_func innocuous_$ac_func
19078
19079 /* System header to define __stub macros and hopefully few prototypes,
19080     which can conflict with char $ac_func (); below.
19081     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19082     <limits.h> exists even on freestanding compilers.  */
19083
19084 #ifdef __STDC__
19085 # include <limits.h>
19086 #else
19087 # include <assert.h>
19088 #endif
19089
19090 #undef $ac_func
19091
19092 /* Override any GCC internal prototype to avoid an error.
19093    Use char because int might match the return type of a GCC
19094    builtin and then its argument prototype would still apply.  */
19095 #ifdef __cplusplus
19096 extern "C"
19097 #endif
19098 char $ac_func ();
19099 /* The GNU C library defines this for functions which it implements
19100     to always fail with ENOSYS.  Some functions are actually named
19101     something starting with __ and the normal name is an alias.  */
19102 #if defined __stub_$ac_func || defined __stub___$ac_func
19103 choke me
19104 #endif
19105
19106 int
19107 main ()
19108 {
19109 return $ac_func ();
19110   ;
19111   return 0;
19112 }
19113 _ACEOF
19114 rm -f conftest.$ac_objext conftest$ac_exeext
19115 if { (ac_try="$ac_link"
19116 case "(($ac_try" in
19117   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19118   *) ac_try_echo=$ac_try;;
19119 esac
19120 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19121 $as_echo "$ac_try_echo") >&5
19122   (eval "$ac_link") 2>conftest.er1
19123   ac_status=$?
19124   grep -v '^ *+' conftest.er1 >conftest.err
19125   rm -f conftest.er1
19126   cat conftest.err >&5
19127   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19128   (exit $ac_status); } && {
19129          test -z "$ac_c_werror_flag" ||
19130          test ! -s conftest.err
19131        } && test -s conftest$ac_exeext && {
19132          test "$cross_compiling" = yes ||
19133          $as_test_x conftest$ac_exeext
19134        }; then
19135   eval "$as_ac_var=yes"
19136 else
19137   $as_echo "$as_me: failed program was:" >&5
19138 sed 's/^/| /' conftest.$ac_ext >&5
19139
19140         eval "$as_ac_var=no"
19141 fi
19142
19143 rm -rf conftest.dSYM
19144 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19145       conftest$ac_exeext conftest.$ac_ext
19146 fi
19147 ac_res=`eval 'as_val=${'$as_ac_var'}
19148                  $as_echo "$as_val"'`
19149                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19150 $as_echo "$ac_res" >&6; }
19151 as_val=`eval 'as_val=${'$as_ac_var'}
19152                  $as_echo "$as_val"'`
19153    if test "x$as_val" = x""yes; then
19154   cat >>confdefs.h <<_ACEOF
19155 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19156 _ACEOF
19157
19158 fi
19159 done
19160
19161 { $as_echo "$as_me:$LINENO: checking whether posix_fadvise is declared" >&5
19162 $as_echo_n "checking whether posix_fadvise is declared... " >&6; }
19163 if test "${ac_cv_have_decl_posix_fadvise+set}" = set; then
19164   $as_echo_n "(cached) " >&6
19165 else
19166   cat >conftest.$ac_ext <<_ACEOF
19167 /* confdefs.h.  */
19168 _ACEOF
19169 cat confdefs.h >>conftest.$ac_ext
19170 cat >>conftest.$ac_ext <<_ACEOF
19171 /* end confdefs.h.  */
19172 #include <fcntl.h>
19173
19174 int
19175 main ()
19176 {
19177 #ifndef posix_fadvise
19178   (void) posix_fadvise;
19179 #endif
19180
19181   ;
19182   return 0;
19183 }
19184 _ACEOF
19185 rm -f conftest.$ac_objext
19186 if { (ac_try="$ac_compile"
19187 case "(($ac_try" in
19188   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19189   *) ac_try_echo=$ac_try;;
19190 esac
19191 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19192 $as_echo "$ac_try_echo") >&5
19193   (eval "$ac_compile") 2>conftest.er1
19194   ac_status=$?
19195   grep -v '^ *+' conftest.er1 >conftest.err
19196   rm -f conftest.er1
19197   cat conftest.err >&5
19198   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19199   (exit $ac_status); } && {
19200          test -z "$ac_c_werror_flag" ||
19201          test ! -s conftest.err
19202        } && test -s conftest.$ac_objext; then
19203   ac_cv_have_decl_posix_fadvise=yes
19204 else
19205   $as_echo "$as_me: failed program was:" >&5
19206 sed 's/^/| /' conftest.$ac_ext >&5
19207
19208         ac_cv_have_decl_posix_fadvise=no
19209 fi
19210
19211 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19212 fi
19213 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_posix_fadvise" >&5
19214 $as_echo "$ac_cv_have_decl_posix_fadvise" >&6; }
19215 if test "x$ac_cv_have_decl_posix_fadvise" = x""yes; then
19216
19217 cat >>confdefs.h <<_ACEOF
19218 #define HAVE_DECL_POSIX_FADVISE 1
19219 _ACEOF
19220
19221
19222 else
19223   cat >>confdefs.h <<_ACEOF
19224 #define HAVE_DECL_POSIX_FADVISE 0
19225 _ACEOF
19226
19227
19228 fi
19229
19230
19231 fi
19232
19233 { $as_echo "$as_me:$LINENO: checking whether fdatasync is declared" >&5
19234 $as_echo_n "checking whether fdatasync is declared... " >&6; }
19235 if test "${ac_cv_have_decl_fdatasync+set}" = set; then
19236   $as_echo_n "(cached) " >&6
19237 else
19238   cat >conftest.$ac_ext <<_ACEOF
19239 /* confdefs.h.  */
19240 _ACEOF
19241 cat confdefs.h >>conftest.$ac_ext
19242 cat >>conftest.$ac_ext <<_ACEOF
19243 /* end confdefs.h.  */
19244 #include <unistd.h>
19245
19246 int
19247 main ()
19248 {
19249 #ifndef fdatasync
19250   (void) fdatasync;
19251 #endif
19252
19253   ;
19254   return 0;
19255 }
19256 _ACEOF
19257 rm -f conftest.$ac_objext
19258 if { (ac_try="$ac_compile"
19259 case "(($ac_try" in
19260   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19261   *) ac_try_echo=$ac_try;;
19262 esac
19263 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19264 $as_echo "$ac_try_echo") >&5
19265   (eval "$ac_compile") 2>conftest.er1
19266   ac_status=$?
19267   grep -v '^ *+' conftest.er1 >conftest.err
19268   rm -f conftest.er1
19269   cat conftest.err >&5
19270   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19271   (exit $ac_status); } && {
19272          test -z "$ac_c_werror_flag" ||
19273          test ! -s conftest.err
19274        } && test -s conftest.$ac_objext; then
19275   ac_cv_have_decl_fdatasync=yes
19276 else
19277   $as_echo "$as_me: failed program was:" >&5
19278 sed 's/^/| /' conftest.$ac_ext >&5
19279
19280         ac_cv_have_decl_fdatasync=no
19281 fi
19282
19283 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19284 fi
19285 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_fdatasync" >&5
19286 $as_echo "$ac_cv_have_decl_fdatasync" >&6; }
19287 if test "x$ac_cv_have_decl_fdatasync" = x""yes; then
19288
19289 cat >>confdefs.h <<_ACEOF
19290 #define HAVE_DECL_FDATASYNC 1
19291 _ACEOF
19292
19293
19294 else
19295   cat >>confdefs.h <<_ACEOF
19296 #define HAVE_DECL_FDATASYNC 0
19297 _ACEOF
19298
19299
19300 fi
19301
19302
19303 { $as_echo "$as_me:$LINENO: checking whether strlcat is declared" >&5
19304 $as_echo_n "checking whether strlcat is declared... " >&6; }
19305 if test "${ac_cv_have_decl_strlcat+set}" = set; then
19306   $as_echo_n "(cached) " >&6
19307 else
19308   cat >conftest.$ac_ext <<_ACEOF
19309 /* confdefs.h.  */
19310 _ACEOF
19311 cat confdefs.h >>conftest.$ac_ext
19312 cat >>conftest.$ac_ext <<_ACEOF
19313 /* end confdefs.h.  */
19314 $ac_includes_default
19315 int
19316 main ()
19317 {
19318 #ifndef strlcat
19319   (void) strlcat;
19320 #endif
19321
19322   ;
19323   return 0;
19324 }
19325 _ACEOF
19326 rm -f conftest.$ac_objext
19327 if { (ac_try="$ac_compile"
19328 case "(($ac_try" in
19329   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19330   *) ac_try_echo=$ac_try;;
19331 esac
19332 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19333 $as_echo "$ac_try_echo") >&5
19334   (eval "$ac_compile") 2>conftest.er1
19335   ac_status=$?
19336   grep -v '^ *+' conftest.er1 >conftest.err
19337   rm -f conftest.er1
19338   cat conftest.err >&5
19339   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19340   (exit $ac_status); } && {
19341          test -z "$ac_c_werror_flag" ||
19342          test ! -s conftest.err
19343        } && test -s conftest.$ac_objext; then
19344   ac_cv_have_decl_strlcat=yes
19345 else
19346   $as_echo "$as_me: failed program was:" >&5
19347 sed 's/^/| /' conftest.$ac_ext >&5
19348
19349         ac_cv_have_decl_strlcat=no
19350 fi
19351
19352 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19353 fi
19354 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcat" >&5
19355 $as_echo "$ac_cv_have_decl_strlcat" >&6; }
19356 if test "x$ac_cv_have_decl_strlcat" = x""yes; then
19357
19358 cat >>confdefs.h <<_ACEOF
19359 #define HAVE_DECL_STRLCAT 1
19360 _ACEOF
19361
19362
19363 else
19364   cat >>confdefs.h <<_ACEOF
19365 #define HAVE_DECL_STRLCAT 0
19366 _ACEOF
19367
19368
19369 fi
19370 { $as_echo "$as_me:$LINENO: checking whether strlcpy is declared" >&5
19371 $as_echo_n "checking whether strlcpy is declared... " >&6; }
19372 if test "${ac_cv_have_decl_strlcpy+set}" = set; then
19373   $as_echo_n "(cached) " >&6
19374 else
19375   cat >conftest.$ac_ext <<_ACEOF
19376 /* confdefs.h.  */
19377 _ACEOF
19378 cat confdefs.h >>conftest.$ac_ext
19379 cat >>conftest.$ac_ext <<_ACEOF
19380 /* end confdefs.h.  */
19381 $ac_includes_default
19382 int
19383 main ()
19384 {
19385 #ifndef strlcpy
19386   (void) strlcpy;
19387 #endif
19388
19389   ;
19390   return 0;
19391 }
19392 _ACEOF
19393 rm -f conftest.$ac_objext
19394 if { (ac_try="$ac_compile"
19395 case "(($ac_try" in
19396   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19397   *) ac_try_echo=$ac_try;;
19398 esac
19399 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19400 $as_echo "$ac_try_echo") >&5
19401   (eval "$ac_compile") 2>conftest.er1
19402   ac_status=$?
19403   grep -v '^ *+' conftest.er1 >conftest.err
19404   rm -f conftest.er1
19405   cat conftest.err >&5
19406   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19407   (exit $ac_status); } && {
19408          test -z "$ac_c_werror_flag" ||
19409          test ! -s conftest.err
19410        } && test -s conftest.$ac_objext; then
19411   ac_cv_have_decl_strlcpy=yes
19412 else
19413   $as_echo "$as_me: failed program was:" >&5
19414 sed 's/^/| /' conftest.$ac_ext >&5
19415
19416         ac_cv_have_decl_strlcpy=no
19417 fi
19418
19419 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19420 fi
19421 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_strlcpy" >&5
19422 $as_echo "$ac_cv_have_decl_strlcpy" >&6; }
19423 if test "x$ac_cv_have_decl_strlcpy" = x""yes; then
19424
19425 cat >>confdefs.h <<_ACEOF
19426 #define HAVE_DECL_STRLCPY 1
19427 _ACEOF
19428
19429
19430 else
19431   cat >>confdefs.h <<_ACEOF
19432 #define HAVE_DECL_STRLCPY 0
19433 _ACEOF
19434
19435
19436 fi
19437
19438
19439 # This is probably only present on Darwin, but may as well check always
19440 { $as_echo "$as_me:$LINENO: checking whether F_FULLFSYNC is declared" >&5
19441 $as_echo_n "checking whether F_FULLFSYNC is declared... " >&6; }
19442 if test "${ac_cv_have_decl_F_FULLFSYNC+set}" = set; then
19443   $as_echo_n "(cached) " >&6
19444 else
19445   cat >conftest.$ac_ext <<_ACEOF
19446 /* confdefs.h.  */
19447 _ACEOF
19448 cat confdefs.h >>conftest.$ac_ext
19449 cat >>conftest.$ac_ext <<_ACEOF
19450 /* end confdefs.h.  */
19451 #include <fcntl.h>
19452
19453 int
19454 main ()
19455 {
19456 #ifndef F_FULLFSYNC
19457   (void) F_FULLFSYNC;
19458 #endif
19459
19460   ;
19461   return 0;
19462 }
19463 _ACEOF
19464 rm -f conftest.$ac_objext
19465 if { (ac_try="$ac_compile"
19466 case "(($ac_try" in
19467   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19468   *) ac_try_echo=$ac_try;;
19469 esac
19470 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19471 $as_echo "$ac_try_echo") >&5
19472   (eval "$ac_compile") 2>conftest.er1
19473   ac_status=$?
19474   grep -v '^ *+' conftest.er1 >conftest.err
19475   rm -f conftest.er1
19476   cat conftest.err >&5
19477   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19478   (exit $ac_status); } && {
19479          test -z "$ac_c_werror_flag" ||
19480          test ! -s conftest.err
19481        } && test -s conftest.$ac_objext; then
19482   ac_cv_have_decl_F_FULLFSYNC=yes
19483 else
19484   $as_echo "$as_me: failed program was:" >&5
19485 sed 's/^/| /' conftest.$ac_ext >&5
19486
19487         ac_cv_have_decl_F_FULLFSYNC=no
19488 fi
19489
19490 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19491 fi
19492 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_F_FULLFSYNC" >&5
19493 $as_echo "$ac_cv_have_decl_F_FULLFSYNC" >&6; }
19494 if test "x$ac_cv_have_decl_F_FULLFSYNC" = x""yes; then
19495
19496 cat >>confdefs.h <<_ACEOF
19497 #define HAVE_DECL_F_FULLFSYNC 1
19498 _ACEOF
19499
19500
19501 else
19502   cat >>confdefs.h <<_ACEOF
19503 #define HAVE_DECL_F_FULLFSYNC 0
19504 _ACEOF
19505
19506
19507 fi
19508
19509
19510
19511 HAVE_IPV6=no
19512 { $as_echo "$as_me:$LINENO: checking for struct sockaddr_in6" >&5
19513 $as_echo_n "checking for struct sockaddr_in6... " >&6; }
19514 if test "${ac_cv_type_struct_sockaddr_in6+set}" = set; then
19515   $as_echo_n "(cached) " >&6
19516 else
19517   ac_cv_type_struct_sockaddr_in6=no
19518 cat >conftest.$ac_ext <<_ACEOF
19519 /* confdefs.h.  */
19520 _ACEOF
19521 cat confdefs.h >>conftest.$ac_ext
19522 cat >>conftest.$ac_ext <<_ACEOF
19523 /* end confdefs.h.  */
19524 $ac_includes_default
19525 #include <netinet/in.h>
19526
19527 int
19528 main ()
19529 {
19530 if (sizeof (struct sockaddr_in6))
19531        return 0;
19532   ;
19533   return 0;
19534 }
19535 _ACEOF
19536 rm -f conftest.$ac_objext
19537 if { (ac_try="$ac_compile"
19538 case "(($ac_try" in
19539   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19540   *) ac_try_echo=$ac_try;;
19541 esac
19542 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19543 $as_echo "$ac_try_echo") >&5
19544   (eval "$ac_compile") 2>conftest.er1
19545   ac_status=$?
19546   grep -v '^ *+' conftest.er1 >conftest.err
19547   rm -f conftest.er1
19548   cat conftest.err >&5
19549   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19550   (exit $ac_status); } && {
19551          test -z "$ac_c_werror_flag" ||
19552          test ! -s conftest.err
19553        } && test -s conftest.$ac_objext; then
19554   cat >conftest.$ac_ext <<_ACEOF
19555 /* confdefs.h.  */
19556 _ACEOF
19557 cat confdefs.h >>conftest.$ac_ext
19558 cat >>conftest.$ac_ext <<_ACEOF
19559 /* end confdefs.h.  */
19560 $ac_includes_default
19561 #include <netinet/in.h>
19562
19563 int
19564 main ()
19565 {
19566 if (sizeof ((struct sockaddr_in6)))
19567           return 0;
19568   ;
19569   return 0;
19570 }
19571 _ACEOF
19572 rm -f conftest.$ac_objext
19573 if { (ac_try="$ac_compile"
19574 case "(($ac_try" in
19575   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19576   *) ac_try_echo=$ac_try;;
19577 esac
19578 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19579 $as_echo "$ac_try_echo") >&5
19580   (eval "$ac_compile") 2>conftest.er1
19581   ac_status=$?
19582   grep -v '^ *+' conftest.er1 >conftest.err
19583   rm -f conftest.er1
19584   cat conftest.err >&5
19585   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19586   (exit $ac_status); } && {
19587          test -z "$ac_c_werror_flag" ||
19588          test ! -s conftest.err
19589        } && test -s conftest.$ac_objext; then
19590   :
19591 else
19592   $as_echo "$as_me: failed program was:" >&5
19593 sed 's/^/| /' conftest.$ac_ext >&5
19594
19595         ac_cv_type_struct_sockaddr_in6=yes
19596 fi
19597
19598 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19599 else
19600   $as_echo "$as_me: failed program was:" >&5
19601 sed 's/^/| /' conftest.$ac_ext >&5
19602
19603
19604 fi
19605
19606 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19607 fi
19608 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_struct_sockaddr_in6" >&5
19609 $as_echo "$ac_cv_type_struct_sockaddr_in6" >&6; }
19610 if test "x$ac_cv_type_struct_sockaddr_in6" = x""yes; then
19611
19612 cat >>confdefs.h <<\_ACEOF
19613 #define HAVE_IPV6 1
19614 _ACEOF
19615
19616          HAVE_IPV6=yes
19617 fi
19618
19619
19620
19621 { $as_echo "$as_me:$LINENO: checking for PS_STRINGS" >&5
19622 $as_echo_n "checking for PS_STRINGS... " >&6; }
19623 if test "${pgac_cv_var_PS_STRINGS+set}" = set; then
19624   $as_echo_n "(cached) " >&6
19625 else
19626   cat >conftest.$ac_ext <<_ACEOF
19627 /* confdefs.h.  */
19628 _ACEOF
19629 cat confdefs.h >>conftest.$ac_ext
19630 cat >>conftest.$ac_ext <<_ACEOF
19631 /* end confdefs.h.  */
19632 #include <machine/vmparam.h>
19633 #include <sys/exec.h>
19634
19635 int
19636 main ()
19637 {
19638 PS_STRINGS->ps_nargvstr = 1;
19639 PS_STRINGS->ps_argvstr = "foo";
19640   ;
19641   return 0;
19642 }
19643 _ACEOF
19644 rm -f conftest.$ac_objext conftest$ac_exeext
19645 if { (ac_try="$ac_link"
19646 case "(($ac_try" in
19647   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19648   *) ac_try_echo=$ac_try;;
19649 esac
19650 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19651 $as_echo "$ac_try_echo") >&5
19652   (eval "$ac_link") 2>conftest.er1
19653   ac_status=$?
19654   grep -v '^ *+' conftest.er1 >conftest.err
19655   rm -f conftest.er1
19656   cat conftest.err >&5
19657   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19658   (exit $ac_status); } && {
19659          test -z "$ac_c_werror_flag" ||
19660          test ! -s conftest.err
19661        } && test -s conftest$ac_exeext && {
19662          test "$cross_compiling" = yes ||
19663          $as_test_x conftest$ac_exeext
19664        }; then
19665   pgac_cv_var_PS_STRINGS=yes
19666 else
19667   $as_echo "$as_me: failed program was:" >&5
19668 sed 's/^/| /' conftest.$ac_ext >&5
19669
19670         pgac_cv_var_PS_STRINGS=no
19671 fi
19672
19673 rm -rf conftest.dSYM
19674 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19675       conftest$ac_exeext conftest.$ac_ext
19676 fi
19677 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_PS_STRINGS" >&5
19678 $as_echo "$pgac_cv_var_PS_STRINGS" >&6; }
19679 if test "$pgac_cv_var_PS_STRINGS" = yes ; then
19680
19681 cat >>confdefs.h <<\_ACEOF
19682 #define HAVE_PS_STRINGS /**/
19683 _ACEOF
19684
19685 fi
19686
19687
19688 # We use our snprintf.c emulation if either snprintf() or vsnprintf()
19689 # is missing.  Yes, there are machines that have only one.  We may
19690 # also decide to use snprintf.c if snprintf() is present but does not
19691 # have all the features we need --- see below.
19692
19693 if test "$PORTNAME" = "win32"; then
19694   # Win32 gets snprintf.c built unconditionally.
19695   #
19696   # To properly translate all NLS languages strings, we must support the
19697   # *printf() %$ format, which allows *printf() arguments to be selected
19698   # by position in the translated string.
19699   #
19700   # libintl versions < 0.13 use the native *printf() functions, and Win32
19701   # *printf() doesn't understand %$, so we must use our /port versions,
19702   # which do understand %$. libintl versions >= 0.13 include their own
19703   # *printf versions on Win32.  The libintl 0.13 release note text is:
19704   #
19705   #   C format strings with positions, as they arise when a translator
19706   #   needs to reorder a sentence, are now supported on all platforms.
19707   #   On those few platforms (NetBSD and Woe32) for which the native
19708   #   printf()/fprintf()/... functions don't support such format
19709   #   strings, replacements are provided through <libintl.h>.
19710   #
19711   # We could use libintl >= 0.13's *printf() if we were sure that we had
19712   # a litint >= 0.13 at runtime, but seeing that there is no clean way
19713   # to guarantee that, it is best to just use our own, so we are sure to
19714   # get %$ support. In include/port.h we disable the *printf() macros
19715   # that might have been defined by libintl.
19716   #
19717   # We do this unconditionally whether NLS is used or not so we are sure
19718   # that all Win32 libraries and binaries behave the same.
19719   pgac_need_repl_snprintf=yes
19720 else
19721   pgac_need_repl_snprintf=no
19722
19723 for ac_func in snprintf
19724 do
19725 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19726 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19727 $as_echo_n "checking for $ac_func... " >&6; }
19728 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19729   $as_echo_n "(cached) " >&6
19730 else
19731   cat >conftest.$ac_ext <<_ACEOF
19732 /* confdefs.h.  */
19733 _ACEOF
19734 cat confdefs.h >>conftest.$ac_ext
19735 cat >>conftest.$ac_ext <<_ACEOF
19736 /* end confdefs.h.  */
19737 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19738    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19739 #define $ac_func innocuous_$ac_func
19740
19741 /* System header to define __stub macros and hopefully few prototypes,
19742     which can conflict with char $ac_func (); below.
19743     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19744     <limits.h> exists even on freestanding compilers.  */
19745
19746 #ifdef __STDC__
19747 # include <limits.h>
19748 #else
19749 # include <assert.h>
19750 #endif
19751
19752 #undef $ac_func
19753
19754 /* Override any GCC internal prototype to avoid an error.
19755    Use char because int might match the return type of a GCC
19756    builtin and then its argument prototype would still apply.  */
19757 #ifdef __cplusplus
19758 extern "C"
19759 #endif
19760 char $ac_func ();
19761 /* The GNU C library defines this for functions which it implements
19762     to always fail with ENOSYS.  Some functions are actually named
19763     something starting with __ and the normal name is an alias.  */
19764 #if defined __stub_$ac_func || defined __stub___$ac_func
19765 choke me
19766 #endif
19767
19768 int
19769 main ()
19770 {
19771 return $ac_func ();
19772   ;
19773   return 0;
19774 }
19775 _ACEOF
19776 rm -f conftest.$ac_objext conftest$ac_exeext
19777 if { (ac_try="$ac_link"
19778 case "(($ac_try" in
19779   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19780   *) ac_try_echo=$ac_try;;
19781 esac
19782 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19783 $as_echo "$ac_try_echo") >&5
19784   (eval "$ac_link") 2>conftest.er1
19785   ac_status=$?
19786   grep -v '^ *+' conftest.er1 >conftest.err
19787   rm -f conftest.er1
19788   cat conftest.err >&5
19789   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19790   (exit $ac_status); } && {
19791          test -z "$ac_c_werror_flag" ||
19792          test ! -s conftest.err
19793        } && test -s conftest$ac_exeext && {
19794          test "$cross_compiling" = yes ||
19795          $as_test_x conftest$ac_exeext
19796        }; then
19797   eval "$as_ac_var=yes"
19798 else
19799   $as_echo "$as_me: failed program was:" >&5
19800 sed 's/^/| /' conftest.$ac_ext >&5
19801
19802         eval "$as_ac_var=no"
19803 fi
19804
19805 rm -rf conftest.dSYM
19806 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19807       conftest$ac_exeext conftest.$ac_ext
19808 fi
19809 ac_res=`eval 'as_val=${'$as_ac_var'}
19810                  $as_echo "$as_val"'`
19811                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19812 $as_echo "$ac_res" >&6; }
19813 as_val=`eval 'as_val=${'$as_ac_var'}
19814                  $as_echo "$as_val"'`
19815    if test "x$as_val" = x""yes; then
19816   cat >>confdefs.h <<_ACEOF
19817 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19818 _ACEOF
19819
19820 else
19821   pgac_need_repl_snprintf=yes
19822 fi
19823 done
19824
19825
19826 for ac_func in vsnprintf
19827 do
19828 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
19829 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
19830 $as_echo_n "checking for $ac_func... " >&6; }
19831 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
19832   $as_echo_n "(cached) " >&6
19833 else
19834   cat >conftest.$ac_ext <<_ACEOF
19835 /* confdefs.h.  */
19836 _ACEOF
19837 cat confdefs.h >>conftest.$ac_ext
19838 cat >>conftest.$ac_ext <<_ACEOF
19839 /* end confdefs.h.  */
19840 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
19841    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
19842 #define $ac_func innocuous_$ac_func
19843
19844 /* System header to define __stub macros and hopefully few prototypes,
19845     which can conflict with char $ac_func (); below.
19846     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
19847     <limits.h> exists even on freestanding compilers.  */
19848
19849 #ifdef __STDC__
19850 # include <limits.h>
19851 #else
19852 # include <assert.h>
19853 #endif
19854
19855 #undef $ac_func
19856
19857 /* Override any GCC internal prototype to avoid an error.
19858    Use char because int might match the return type of a GCC
19859    builtin and then its argument prototype would still apply.  */
19860 #ifdef __cplusplus
19861 extern "C"
19862 #endif
19863 char $ac_func ();
19864 /* The GNU C library defines this for functions which it implements
19865     to always fail with ENOSYS.  Some functions are actually named
19866     something starting with __ and the normal name is an alias.  */
19867 #if defined __stub_$ac_func || defined __stub___$ac_func
19868 choke me
19869 #endif
19870
19871 int
19872 main ()
19873 {
19874 return $ac_func ();
19875   ;
19876   return 0;
19877 }
19878 _ACEOF
19879 rm -f conftest.$ac_objext conftest$ac_exeext
19880 if { (ac_try="$ac_link"
19881 case "(($ac_try" in
19882   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19883   *) ac_try_echo=$ac_try;;
19884 esac
19885 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19886 $as_echo "$ac_try_echo") >&5
19887   (eval "$ac_link") 2>conftest.er1
19888   ac_status=$?
19889   grep -v '^ *+' conftest.er1 >conftest.err
19890   rm -f conftest.er1
19891   cat conftest.err >&5
19892   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19893   (exit $ac_status); } && {
19894          test -z "$ac_c_werror_flag" ||
19895          test ! -s conftest.err
19896        } && test -s conftest$ac_exeext && {
19897          test "$cross_compiling" = yes ||
19898          $as_test_x conftest$ac_exeext
19899        }; then
19900   eval "$as_ac_var=yes"
19901 else
19902   $as_echo "$as_me: failed program was:" >&5
19903 sed 's/^/| /' conftest.$ac_ext >&5
19904
19905         eval "$as_ac_var=no"
19906 fi
19907
19908 rm -rf conftest.dSYM
19909 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
19910       conftest$ac_exeext conftest.$ac_ext
19911 fi
19912 ac_res=`eval 'as_val=${'$as_ac_var'}
19913                  $as_echo "$as_val"'`
19914                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
19915 $as_echo "$ac_res" >&6; }
19916 as_val=`eval 'as_val=${'$as_ac_var'}
19917                  $as_echo "$as_val"'`
19918    if test "x$as_val" = x""yes; then
19919   cat >>confdefs.h <<_ACEOF
19920 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
19921 _ACEOF
19922
19923 else
19924   pgac_need_repl_snprintf=yes
19925 fi
19926 done
19927
19928 fi
19929
19930
19931 # Check whether <stdio.h> declares snprintf() and vsnprintf(); if not,
19932 # include/c.h will provide declarations.  Note this is a separate test
19933 # from whether the functions exist in the C library --- there are
19934 # systems that have the functions but don't bother to declare them :-(
19935
19936 { $as_echo "$as_me:$LINENO: checking whether snprintf is declared" >&5
19937 $as_echo_n "checking whether snprintf is declared... " >&6; }
19938 if test "${ac_cv_have_decl_snprintf+set}" = set; then
19939   $as_echo_n "(cached) " >&6
19940 else
19941   cat >conftest.$ac_ext <<_ACEOF
19942 /* confdefs.h.  */
19943 _ACEOF
19944 cat confdefs.h >>conftest.$ac_ext
19945 cat >>conftest.$ac_ext <<_ACEOF
19946 /* end confdefs.h.  */
19947 $ac_includes_default
19948 int
19949 main ()
19950 {
19951 #ifndef snprintf
19952   (void) snprintf;
19953 #endif
19954
19955   ;
19956   return 0;
19957 }
19958 _ACEOF
19959 rm -f conftest.$ac_objext
19960 if { (ac_try="$ac_compile"
19961 case "(($ac_try" in
19962   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
19963   *) ac_try_echo=$ac_try;;
19964 esac
19965 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
19966 $as_echo "$ac_try_echo") >&5
19967   (eval "$ac_compile") 2>conftest.er1
19968   ac_status=$?
19969   grep -v '^ *+' conftest.er1 >conftest.err
19970   rm -f conftest.er1
19971   cat conftest.err >&5
19972   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
19973   (exit $ac_status); } && {
19974          test -z "$ac_c_werror_flag" ||
19975          test ! -s conftest.err
19976        } && test -s conftest.$ac_objext; then
19977   ac_cv_have_decl_snprintf=yes
19978 else
19979   $as_echo "$as_me: failed program was:" >&5
19980 sed 's/^/| /' conftest.$ac_ext >&5
19981
19982         ac_cv_have_decl_snprintf=no
19983 fi
19984
19985 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
19986 fi
19987 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_snprintf" >&5
19988 $as_echo "$ac_cv_have_decl_snprintf" >&6; }
19989 if test "x$ac_cv_have_decl_snprintf" = x""yes; then
19990
19991 cat >>confdefs.h <<_ACEOF
19992 #define HAVE_DECL_SNPRINTF 1
19993 _ACEOF
19994
19995
19996 else
19997   cat >>confdefs.h <<_ACEOF
19998 #define HAVE_DECL_SNPRINTF 0
19999 _ACEOF
20000
20001
20002 fi
20003 { $as_echo "$as_me:$LINENO: checking whether vsnprintf is declared" >&5
20004 $as_echo_n "checking whether vsnprintf is declared... " >&6; }
20005 if test "${ac_cv_have_decl_vsnprintf+set}" = set; then
20006   $as_echo_n "(cached) " >&6
20007 else
20008   cat >conftest.$ac_ext <<_ACEOF
20009 /* confdefs.h.  */
20010 _ACEOF
20011 cat confdefs.h >>conftest.$ac_ext
20012 cat >>conftest.$ac_ext <<_ACEOF
20013 /* end confdefs.h.  */
20014 $ac_includes_default
20015 int
20016 main ()
20017 {
20018 #ifndef vsnprintf
20019   (void) vsnprintf;
20020 #endif
20021
20022   ;
20023   return 0;
20024 }
20025 _ACEOF
20026 rm -f conftest.$ac_objext
20027 if { (ac_try="$ac_compile"
20028 case "(($ac_try" in
20029   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20030   *) ac_try_echo=$ac_try;;
20031 esac
20032 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20033 $as_echo "$ac_try_echo") >&5
20034   (eval "$ac_compile") 2>conftest.er1
20035   ac_status=$?
20036   grep -v '^ *+' conftest.er1 >conftest.err
20037   rm -f conftest.er1
20038   cat conftest.err >&5
20039   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20040   (exit $ac_status); } && {
20041          test -z "$ac_c_werror_flag" ||
20042          test ! -s conftest.err
20043        } && test -s conftest.$ac_objext; then
20044   ac_cv_have_decl_vsnprintf=yes
20045 else
20046   $as_echo "$as_me: failed program was:" >&5
20047 sed 's/^/| /' conftest.$ac_ext >&5
20048
20049         ac_cv_have_decl_vsnprintf=no
20050 fi
20051
20052 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
20053 fi
20054 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_vsnprintf" >&5
20055 $as_echo "$ac_cv_have_decl_vsnprintf" >&6; }
20056 if test "x$ac_cv_have_decl_vsnprintf" = x""yes; then
20057
20058 cat >>confdefs.h <<_ACEOF
20059 #define HAVE_DECL_VSNPRINTF 1
20060 _ACEOF
20061
20062
20063 else
20064   cat >>confdefs.h <<_ACEOF
20065 #define HAVE_DECL_VSNPRINTF 0
20066 _ACEOF
20067
20068
20069 fi
20070
20071
20072
20073
20074 { $as_echo "$as_me:$LINENO: checking for isinf" >&5
20075 $as_echo_n "checking for isinf... " >&6; }
20076 if test "${ac_cv_func_isinf+set}" = set; then
20077   $as_echo_n "(cached) " >&6
20078 else
20079   cat >conftest.$ac_ext <<_ACEOF
20080 /* confdefs.h.  */
20081 _ACEOF
20082 cat confdefs.h >>conftest.$ac_ext
20083 cat >>conftest.$ac_ext <<_ACEOF
20084 /* end confdefs.h.  */
20085
20086 #include <math.h>
20087 double glob_double;
20088
20089 int
20090 main ()
20091 {
20092 return isinf(glob_double) ? 0 : 1;
20093   ;
20094   return 0;
20095 }
20096 _ACEOF
20097 rm -f conftest.$ac_objext conftest$ac_exeext
20098 if { (ac_try="$ac_link"
20099 case "(($ac_try" in
20100   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20101   *) ac_try_echo=$ac_try;;
20102 esac
20103 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20104 $as_echo "$ac_try_echo") >&5
20105   (eval "$ac_link") 2>conftest.er1
20106   ac_status=$?
20107   grep -v '^ *+' conftest.er1 >conftest.err
20108   rm -f conftest.er1
20109   cat conftest.err >&5
20110   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20111   (exit $ac_status); } && {
20112          test -z "$ac_c_werror_flag" ||
20113          test ! -s conftest.err
20114        } && test -s conftest$ac_exeext && {
20115          test "$cross_compiling" = yes ||
20116          $as_test_x conftest$ac_exeext
20117        }; then
20118   ac_cv_func_isinf=yes
20119 else
20120   $as_echo "$as_me: failed program was:" >&5
20121 sed 's/^/| /' conftest.$ac_ext >&5
20122
20123         ac_cv_func_isinf=no
20124 fi
20125
20126 rm -rf conftest.dSYM
20127 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20128       conftest$ac_exeext conftest.$ac_ext
20129 fi
20130 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_isinf" >&5
20131 $as_echo "$ac_cv_func_isinf" >&6; }
20132
20133 if test $ac_cv_func_isinf = yes ; then
20134
20135 cat >>confdefs.h <<\_ACEOF
20136 #define HAVE_ISINF 1
20137 _ACEOF
20138
20139 else
20140   case " $LIBOBJS " in
20141   *" isinf.$ac_objext "* ) ;;
20142   *) LIBOBJS="$LIBOBJS isinf.$ac_objext"
20143  ;;
20144 esac
20145
20146   # Look for a way to implement a substitute for isinf()
20147
20148
20149
20150
20151 for ac_func in fpclass fp_class fp_class_d class
20152 do
20153 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20154 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20155 $as_echo_n "checking for $ac_func... " >&6; }
20156 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20157   $as_echo_n "(cached) " >&6
20158 else
20159   cat >conftest.$ac_ext <<_ACEOF
20160 /* confdefs.h.  */
20161 _ACEOF
20162 cat confdefs.h >>conftest.$ac_ext
20163 cat >>conftest.$ac_ext <<_ACEOF
20164 /* end confdefs.h.  */
20165 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20166    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20167 #define $ac_func innocuous_$ac_func
20168
20169 /* System header to define __stub macros and hopefully few prototypes,
20170     which can conflict with char $ac_func (); below.
20171     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20172     <limits.h> exists even on freestanding compilers.  */
20173
20174 #ifdef __STDC__
20175 # include <limits.h>
20176 #else
20177 # include <assert.h>
20178 #endif
20179
20180 #undef $ac_func
20181
20182 /* Override any GCC internal prototype to avoid an error.
20183    Use char because int might match the return type of a GCC
20184    builtin and then its argument prototype would still apply.  */
20185 #ifdef __cplusplus
20186 extern "C"
20187 #endif
20188 char $ac_func ();
20189 /* The GNU C library defines this for functions which it implements
20190     to always fail with ENOSYS.  Some functions are actually named
20191     something starting with __ and the normal name is an alias.  */
20192 #if defined __stub_$ac_func || defined __stub___$ac_func
20193 choke me
20194 #endif
20195
20196 int
20197 main ()
20198 {
20199 return $ac_func ();
20200   ;
20201   return 0;
20202 }
20203 _ACEOF
20204 rm -f conftest.$ac_objext conftest$ac_exeext
20205 if { (ac_try="$ac_link"
20206 case "(($ac_try" in
20207   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20208   *) ac_try_echo=$ac_try;;
20209 esac
20210 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20211 $as_echo "$ac_try_echo") >&5
20212   (eval "$ac_link") 2>conftest.er1
20213   ac_status=$?
20214   grep -v '^ *+' conftest.er1 >conftest.err
20215   rm -f conftest.er1
20216   cat conftest.err >&5
20217   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20218   (exit $ac_status); } && {
20219          test -z "$ac_c_werror_flag" ||
20220          test ! -s conftest.err
20221        } && test -s conftest$ac_exeext && {
20222          test "$cross_compiling" = yes ||
20223          $as_test_x conftest$ac_exeext
20224        }; then
20225   eval "$as_ac_var=yes"
20226 else
20227   $as_echo "$as_me: failed program was:" >&5
20228 sed 's/^/| /' conftest.$ac_ext >&5
20229
20230         eval "$as_ac_var=no"
20231 fi
20232
20233 rm -rf conftest.dSYM
20234 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20235       conftest$ac_exeext conftest.$ac_ext
20236 fi
20237 ac_res=`eval 'as_val=${'$as_ac_var'}
20238                  $as_echo "$as_val"'`
20239                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20240 $as_echo "$ac_res" >&6; }
20241 as_val=`eval 'as_val=${'$as_ac_var'}
20242                  $as_echo "$as_val"'`
20243    if test "x$as_val" = x""yes; then
20244   cat >>confdefs.h <<_ACEOF
20245 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20246 _ACEOF
20247  break
20248 fi
20249 done
20250
20251 fi
20252
20253 # Some versions of libedit contain strlcpy(); so disregard that library while
20254 # checking for these standard libc functions.
20255 pgac_save_LIBS="$LIBS"
20256 LIBS=`echo "$LIBS" | sed -e 's/-ledit//g' -e 's/-lreadline//g'`
20257
20258
20259
20260
20261
20262
20263
20264
20265
20266
20267
20268
20269
20270
20271
20272 for ac_func in crypt erand48 getopt getrusage inet_aton random rint srandom strdup strerror strlcat strlcpy strtol strtoul
20273 do
20274 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20275 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20276 $as_echo_n "checking for $ac_func... " >&6; }
20277 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20278   $as_echo_n "(cached) " >&6
20279 else
20280   cat >conftest.$ac_ext <<_ACEOF
20281 /* confdefs.h.  */
20282 _ACEOF
20283 cat confdefs.h >>conftest.$ac_ext
20284 cat >>conftest.$ac_ext <<_ACEOF
20285 /* end confdefs.h.  */
20286 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20287    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20288 #define $ac_func innocuous_$ac_func
20289
20290 /* System header to define __stub macros and hopefully few prototypes,
20291     which can conflict with char $ac_func (); below.
20292     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20293     <limits.h> exists even on freestanding compilers.  */
20294
20295 #ifdef __STDC__
20296 # include <limits.h>
20297 #else
20298 # include <assert.h>
20299 #endif
20300
20301 #undef $ac_func
20302
20303 /* Override any GCC internal prototype to avoid an error.
20304    Use char because int might match the return type of a GCC
20305    builtin and then its argument prototype would still apply.  */
20306 #ifdef __cplusplus
20307 extern "C"
20308 #endif
20309 char $ac_func ();
20310 /* The GNU C library defines this for functions which it implements
20311     to always fail with ENOSYS.  Some functions are actually named
20312     something starting with __ and the normal name is an alias.  */
20313 #if defined __stub_$ac_func || defined __stub___$ac_func
20314 choke me
20315 #endif
20316
20317 int
20318 main ()
20319 {
20320 return $ac_func ();
20321   ;
20322   return 0;
20323 }
20324 _ACEOF
20325 rm -f conftest.$ac_objext conftest$ac_exeext
20326 if { (ac_try="$ac_link"
20327 case "(($ac_try" in
20328   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20329   *) ac_try_echo=$ac_try;;
20330 esac
20331 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20332 $as_echo "$ac_try_echo") >&5
20333   (eval "$ac_link") 2>conftest.er1
20334   ac_status=$?
20335   grep -v '^ *+' conftest.er1 >conftest.err
20336   rm -f conftest.er1
20337   cat conftest.err >&5
20338   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20339   (exit $ac_status); } && {
20340          test -z "$ac_c_werror_flag" ||
20341          test ! -s conftest.err
20342        } && test -s conftest$ac_exeext && {
20343          test "$cross_compiling" = yes ||
20344          $as_test_x conftest$ac_exeext
20345        }; then
20346   eval "$as_ac_var=yes"
20347 else
20348   $as_echo "$as_me: failed program was:" >&5
20349 sed 's/^/| /' conftest.$ac_ext >&5
20350
20351         eval "$as_ac_var=no"
20352 fi
20353
20354 rm -rf conftest.dSYM
20355 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20356       conftest$ac_exeext conftest.$ac_ext
20357 fi
20358 ac_res=`eval 'as_val=${'$as_ac_var'}
20359                  $as_echo "$as_val"'`
20360                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20361 $as_echo "$ac_res" >&6; }
20362 as_val=`eval 'as_val=${'$as_ac_var'}
20363                  $as_echo "$as_val"'`
20364    if test "x$as_val" = x""yes; then
20365   cat >>confdefs.h <<_ACEOF
20366 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20367 _ACEOF
20368
20369 else
20370   case " $LIBOBJS " in
20371   *" $ac_func.$ac_objext "* ) ;;
20372   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20373  ;;
20374 esac
20375
20376 fi
20377 done
20378
20379
20380
20381 case $host_os in
20382
20383         # Windows uses a specialised env handler
20384         mingw*)
20385
20386 cat >>confdefs.h <<\_ACEOF
20387 #define HAVE_UNSETENV 1
20388 _ACEOF
20389
20390                 ac_cv_func_unsetenv=yes;;
20391         *)
20392
20393 for ac_func in unsetenv
20394 do
20395 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20396 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20397 $as_echo_n "checking for $ac_func... " >&6; }
20398 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20399   $as_echo_n "(cached) " >&6
20400 else
20401   cat >conftest.$ac_ext <<_ACEOF
20402 /* confdefs.h.  */
20403 _ACEOF
20404 cat confdefs.h >>conftest.$ac_ext
20405 cat >>conftest.$ac_ext <<_ACEOF
20406 /* end confdefs.h.  */
20407 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20408    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20409 #define $ac_func innocuous_$ac_func
20410
20411 /* System header to define __stub macros and hopefully few prototypes,
20412     which can conflict with char $ac_func (); below.
20413     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20414     <limits.h> exists even on freestanding compilers.  */
20415
20416 #ifdef __STDC__
20417 # include <limits.h>
20418 #else
20419 # include <assert.h>
20420 #endif
20421
20422 #undef $ac_func
20423
20424 /* Override any GCC internal prototype to avoid an error.
20425    Use char because int might match the return type of a GCC
20426    builtin and then its argument prototype would still apply.  */
20427 #ifdef __cplusplus
20428 extern "C"
20429 #endif
20430 char $ac_func ();
20431 /* The GNU C library defines this for functions which it implements
20432     to always fail with ENOSYS.  Some functions are actually named
20433     something starting with __ and the normal name is an alias.  */
20434 #if defined __stub_$ac_func || defined __stub___$ac_func
20435 choke me
20436 #endif
20437
20438 int
20439 main ()
20440 {
20441 return $ac_func ();
20442   ;
20443   return 0;
20444 }
20445 _ACEOF
20446 rm -f conftest.$ac_objext conftest$ac_exeext
20447 if { (ac_try="$ac_link"
20448 case "(($ac_try" in
20449   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20450   *) ac_try_echo=$ac_try;;
20451 esac
20452 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20453 $as_echo "$ac_try_echo") >&5
20454   (eval "$ac_link") 2>conftest.er1
20455   ac_status=$?
20456   grep -v '^ *+' conftest.er1 >conftest.err
20457   rm -f conftest.er1
20458   cat conftest.err >&5
20459   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20460   (exit $ac_status); } && {
20461          test -z "$ac_c_werror_flag" ||
20462          test ! -s conftest.err
20463        } && test -s conftest$ac_exeext && {
20464          test "$cross_compiling" = yes ||
20465          $as_test_x conftest$ac_exeext
20466        }; then
20467   eval "$as_ac_var=yes"
20468 else
20469   $as_echo "$as_me: failed program was:" >&5
20470 sed 's/^/| /' conftest.$ac_ext >&5
20471
20472         eval "$as_ac_var=no"
20473 fi
20474
20475 rm -rf conftest.dSYM
20476 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20477       conftest$ac_exeext conftest.$ac_ext
20478 fi
20479 ac_res=`eval 'as_val=${'$as_ac_var'}
20480                  $as_echo "$as_val"'`
20481                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20482 $as_echo "$ac_res" >&6; }
20483 as_val=`eval 'as_val=${'$as_ac_var'}
20484                  $as_echo "$as_val"'`
20485    if test "x$as_val" = x""yes; then
20486   cat >>confdefs.h <<_ACEOF
20487 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20488 _ACEOF
20489
20490 else
20491   case " $LIBOBJS " in
20492   *" $ac_func.$ac_objext "* ) ;;
20493   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20494  ;;
20495 esac
20496
20497 fi
20498 done
20499
20500
20501                 ;;
20502 esac
20503
20504
20505 LIBS="$pgac_save_LIBS"
20506
20507 # System's version of getaddrinfo(), if any, may be used only if we found
20508 # a definition for struct addrinfo; see notes in src/include/getaddrinfo.h.
20509 # (Note: the AC_REPLACE_FUNCS probe fails on Windows, where the available
20510 # versions of getaddrinfo don't follow normal C call protocol.  This is OK
20511 # because we want to use our own getaddrinfo.c on Windows anyway.)
20512 if test x"$ac_cv_type_struct_addrinfo" = xyes ; then
20513
20514 for ac_func in getaddrinfo
20515 do
20516 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20517 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20518 $as_echo_n "checking for $ac_func... " >&6; }
20519 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20520   $as_echo_n "(cached) " >&6
20521 else
20522   cat >conftest.$ac_ext <<_ACEOF
20523 /* confdefs.h.  */
20524 _ACEOF
20525 cat confdefs.h >>conftest.$ac_ext
20526 cat >>conftest.$ac_ext <<_ACEOF
20527 /* end confdefs.h.  */
20528 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20529    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20530 #define $ac_func innocuous_$ac_func
20531
20532 /* System header to define __stub macros and hopefully few prototypes,
20533     which can conflict with char $ac_func (); below.
20534     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20535     <limits.h> exists even on freestanding compilers.  */
20536
20537 #ifdef __STDC__
20538 # include <limits.h>
20539 #else
20540 # include <assert.h>
20541 #endif
20542
20543 #undef $ac_func
20544
20545 /* Override any GCC internal prototype to avoid an error.
20546    Use char because int might match the return type of a GCC
20547    builtin and then its argument prototype would still apply.  */
20548 #ifdef __cplusplus
20549 extern "C"
20550 #endif
20551 char $ac_func ();
20552 /* The GNU C library defines this for functions which it implements
20553     to always fail with ENOSYS.  Some functions are actually named
20554     something starting with __ and the normal name is an alias.  */
20555 #if defined __stub_$ac_func || defined __stub___$ac_func
20556 choke me
20557 #endif
20558
20559 int
20560 main ()
20561 {
20562 return $ac_func ();
20563   ;
20564   return 0;
20565 }
20566 _ACEOF
20567 rm -f conftest.$ac_objext conftest$ac_exeext
20568 if { (ac_try="$ac_link"
20569 case "(($ac_try" in
20570   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20571   *) ac_try_echo=$ac_try;;
20572 esac
20573 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20574 $as_echo "$ac_try_echo") >&5
20575   (eval "$ac_link") 2>conftest.er1
20576   ac_status=$?
20577   grep -v '^ *+' conftest.er1 >conftest.err
20578   rm -f conftest.er1
20579   cat conftest.err >&5
20580   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20581   (exit $ac_status); } && {
20582          test -z "$ac_c_werror_flag" ||
20583          test ! -s conftest.err
20584        } && test -s conftest$ac_exeext && {
20585          test "$cross_compiling" = yes ||
20586          $as_test_x conftest$ac_exeext
20587        }; then
20588   eval "$as_ac_var=yes"
20589 else
20590   $as_echo "$as_me: failed program was:" >&5
20591 sed 's/^/| /' conftest.$ac_ext >&5
20592
20593         eval "$as_ac_var=no"
20594 fi
20595
20596 rm -rf conftest.dSYM
20597 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20598       conftest$ac_exeext conftest.$ac_ext
20599 fi
20600 ac_res=`eval 'as_val=${'$as_ac_var'}
20601                  $as_echo "$as_val"'`
20602                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20603 $as_echo "$ac_res" >&6; }
20604 as_val=`eval 'as_val=${'$as_ac_var'}
20605                  $as_echo "$as_val"'`
20606    if test "x$as_val" = x""yes; then
20607   cat >>confdefs.h <<_ACEOF
20608 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20609 _ACEOF
20610
20611 else
20612   case " $LIBOBJS " in
20613   *" $ac_func.$ac_objext "* ) ;;
20614   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20615  ;;
20616 esac
20617
20618 fi
20619 done
20620
20621
20622 else
20623   case " $LIBOBJS " in
20624   *" getaddrinfo.$ac_objext "* ) ;;
20625   *) LIBOBJS="$LIBOBJS getaddrinfo.$ac_objext"
20626  ;;
20627 esac
20628
20629 fi
20630
20631 # Similarly, use system's getopt_long() only if system provides struct option.
20632 if test x"$ac_cv_type_struct_option" = xyes ; then
20633
20634 for ac_func in getopt_long
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   *" getopt_long.$ac_objext "* ) ;;
20745   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
20746  ;;
20747 esac
20748
20749 fi
20750
20751 # Solaris' getopt() doesn't do what we want for long options, so always use
20752 # our version on that platform.
20753 if test "$PORTNAME" = "solaris"; then
20754   case " $LIBOBJS " in
20755   *" getopt.$ac_objext "* ) ;;
20756   *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
20757  ;;
20758 esac
20759
20760 fi
20761
20762 # mingw has adopted a GNU-centric interpretation of optind/optreset,
20763 # so always use our version on Windows.
20764 if test "$PORTNAME" = "win32"; then
20765   case " $LIBOBJS " in
20766   *" getopt.$ac_objext "* ) ;;
20767   *) LIBOBJS="$LIBOBJS getopt.$ac_objext"
20768  ;;
20769 esac
20770
20771   case " $LIBOBJS " in
20772   *" getopt_long.$ac_objext "* ) ;;
20773   *) LIBOBJS="$LIBOBJS getopt_long.$ac_objext"
20774  ;;
20775 esac
20776
20777 fi
20778
20779 # Cygwin's erand48() is broken (always returns zero) in some releases,
20780 # so force use of ours.
20781 if test "$PORTNAME" = "cygwin"; then
20782   case " $LIBOBJS " in
20783   *" erand48.$ac_objext "* ) ;;
20784   *) LIBOBJS="$LIBOBJS erand48.$ac_objext"
20785  ;;
20786 esac
20787
20788 fi
20789
20790 # Win32 support
20791 if test "$PORTNAME" = "win32"; then
20792
20793 for ac_func in gettimeofday
20794 do
20795 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
20796 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
20797 $as_echo_n "checking for $ac_func... " >&6; }
20798 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
20799   $as_echo_n "(cached) " >&6
20800 else
20801   cat >conftest.$ac_ext <<_ACEOF
20802 /* confdefs.h.  */
20803 _ACEOF
20804 cat confdefs.h >>conftest.$ac_ext
20805 cat >>conftest.$ac_ext <<_ACEOF
20806 /* end confdefs.h.  */
20807 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
20808    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
20809 #define $ac_func innocuous_$ac_func
20810
20811 /* System header to define __stub macros and hopefully few prototypes,
20812     which can conflict with char $ac_func (); below.
20813     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
20814     <limits.h> exists even on freestanding compilers.  */
20815
20816 #ifdef __STDC__
20817 # include <limits.h>
20818 #else
20819 # include <assert.h>
20820 #endif
20821
20822 #undef $ac_func
20823
20824 /* Override any GCC internal prototype to avoid an error.
20825    Use char because int might match the return type of a GCC
20826    builtin and then its argument prototype would still apply.  */
20827 #ifdef __cplusplus
20828 extern "C"
20829 #endif
20830 char $ac_func ();
20831 /* The GNU C library defines this for functions which it implements
20832     to always fail with ENOSYS.  Some functions are actually named
20833     something starting with __ and the normal name is an alias.  */
20834 #if defined __stub_$ac_func || defined __stub___$ac_func
20835 choke me
20836 #endif
20837
20838 int
20839 main ()
20840 {
20841 return $ac_func ();
20842   ;
20843   return 0;
20844 }
20845 _ACEOF
20846 rm -f conftest.$ac_objext conftest$ac_exeext
20847 if { (ac_try="$ac_link"
20848 case "(($ac_try" in
20849   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20850   *) ac_try_echo=$ac_try;;
20851 esac
20852 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20853 $as_echo "$ac_try_echo") >&5
20854   (eval "$ac_link") 2>conftest.er1
20855   ac_status=$?
20856   grep -v '^ *+' conftest.er1 >conftest.err
20857   rm -f conftest.er1
20858   cat conftest.err >&5
20859   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20860   (exit $ac_status); } && {
20861          test -z "$ac_c_werror_flag" ||
20862          test ! -s conftest.err
20863        } && test -s conftest$ac_exeext && {
20864          test "$cross_compiling" = yes ||
20865          $as_test_x conftest$ac_exeext
20866        }; then
20867   eval "$as_ac_var=yes"
20868 else
20869   $as_echo "$as_me: failed program was:" >&5
20870 sed 's/^/| /' conftest.$ac_ext >&5
20871
20872         eval "$as_ac_var=no"
20873 fi
20874
20875 rm -rf conftest.dSYM
20876 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
20877       conftest$ac_exeext conftest.$ac_ext
20878 fi
20879 ac_res=`eval 'as_val=${'$as_ac_var'}
20880                  $as_echo "$as_val"'`
20881                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
20882 $as_echo "$ac_res" >&6; }
20883 as_val=`eval 'as_val=${'$as_ac_var'}
20884                  $as_echo "$as_val"'`
20885    if test "x$as_val" = x""yes; then
20886   cat >>confdefs.h <<_ACEOF
20887 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
20888 _ACEOF
20889
20890 else
20891   case " $LIBOBJS " in
20892   *" $ac_func.$ac_objext "* ) ;;
20893   *) LIBOBJS="$LIBOBJS $ac_func.$ac_objext"
20894  ;;
20895 esac
20896
20897 fi
20898 done
20899
20900
20901   case " $LIBOBJS " in
20902   *" kill.$ac_objext "* ) ;;
20903   *) LIBOBJS="$LIBOBJS kill.$ac_objext"
20904  ;;
20905 esac
20906
20907   case " $LIBOBJS " in
20908   *" open.$ac_objext "* ) ;;
20909   *) LIBOBJS="$LIBOBJS open.$ac_objext"
20910  ;;
20911 esac
20912
20913   case " $LIBOBJS " in
20914   *" win32env.$ac_objext "* ) ;;
20915   *) LIBOBJS="$LIBOBJS win32env.$ac_objext"
20916  ;;
20917 esac
20918
20919   case " $LIBOBJS " in
20920   *" win32error.$ac_objext "* ) ;;
20921   *) LIBOBJS="$LIBOBJS win32error.$ac_objext"
20922  ;;
20923 esac
20924
20925
20926 cat >>confdefs.h <<\_ACEOF
20927 #define HAVE_SYMLINK 1
20928 _ACEOF
20929
20930   { $as_echo "$as_me:$LINENO: checking for MINIDUMP_TYPE" >&5
20931 $as_echo_n "checking for MINIDUMP_TYPE... " >&6; }
20932 if test "${ac_cv_type_MINIDUMP_TYPE+set}" = set; then
20933   $as_echo_n "(cached) " >&6
20934 else
20935   ac_cv_type_MINIDUMP_TYPE=no
20936 cat >conftest.$ac_ext <<_ACEOF
20937 /* confdefs.h.  */
20938 _ACEOF
20939 cat confdefs.h >>conftest.$ac_ext
20940 cat >>conftest.$ac_ext <<_ACEOF
20941 /* end confdefs.h.  */
20942
20943 #define WIN32_LEAN_AND_MEAN
20944 #include <windows.h>
20945 #include <string.h>
20946 #include <dbghelp.h>
20947
20948 int
20949 main ()
20950 {
20951 if (sizeof (MINIDUMP_TYPE))
20952        return 0;
20953   ;
20954   return 0;
20955 }
20956 _ACEOF
20957 rm -f conftest.$ac_objext
20958 if { (ac_try="$ac_compile"
20959 case "(($ac_try" in
20960   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
20961   *) ac_try_echo=$ac_try;;
20962 esac
20963 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
20964 $as_echo "$ac_try_echo") >&5
20965   (eval "$ac_compile") 2>conftest.er1
20966   ac_status=$?
20967   grep -v '^ *+' conftest.er1 >conftest.err
20968   rm -f conftest.er1
20969   cat conftest.err >&5
20970   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
20971   (exit $ac_status); } && {
20972          test -z "$ac_c_werror_flag" ||
20973          test ! -s conftest.err
20974        } && test -s conftest.$ac_objext; then
20975   cat >conftest.$ac_ext <<_ACEOF
20976 /* confdefs.h.  */
20977 _ACEOF
20978 cat confdefs.h >>conftest.$ac_ext
20979 cat >>conftest.$ac_ext <<_ACEOF
20980 /* end confdefs.h.  */
20981
20982 #define WIN32_LEAN_AND_MEAN
20983 #include <windows.h>
20984 #include <string.h>
20985 #include <dbghelp.h>
20986
20987 int
20988 main ()
20989 {
20990 if (sizeof ((MINIDUMP_TYPE)))
20991           return 0;
20992   ;
20993   return 0;
20994 }
20995 _ACEOF
20996 rm -f conftest.$ac_objext
20997 if { (ac_try="$ac_compile"
20998 case "(($ac_try" in
20999   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21000   *) ac_try_echo=$ac_try;;
21001 esac
21002 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21003 $as_echo "$ac_try_echo") >&5
21004   (eval "$ac_compile") 2>conftest.er1
21005   ac_status=$?
21006   grep -v '^ *+' conftest.er1 >conftest.err
21007   rm -f conftest.er1
21008   cat conftest.err >&5
21009   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21010   (exit $ac_status); } && {
21011          test -z "$ac_c_werror_flag" ||
21012          test ! -s conftest.err
21013        } && test -s conftest.$ac_objext; then
21014   :
21015 else
21016   $as_echo "$as_me: failed program was:" >&5
21017 sed 's/^/| /' conftest.$ac_ext >&5
21018
21019         ac_cv_type_MINIDUMP_TYPE=yes
21020 fi
21021
21022 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21023 else
21024   $as_echo "$as_me: failed program was:" >&5
21025 sed 's/^/| /' conftest.$ac_ext >&5
21026
21027
21028 fi
21029
21030 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21031 fi
21032 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_MINIDUMP_TYPE" >&5
21033 $as_echo "$ac_cv_type_MINIDUMP_TYPE" >&6; }
21034 if test "x$ac_cv_type_MINIDUMP_TYPE" = x""yes; then
21035
21036 cat >>confdefs.h <<_ACEOF
21037 #define HAVE_MINIDUMP_TYPE 1
21038 _ACEOF
21039
21040 pgac_minidump_type=yes
21041 else
21042   pgac_minidump_type=no
21043 fi
21044
21045 fi
21046 if test x"$pgac_minidump_type" = x"yes" ; then
21047   have_win32_dbghelp=yes
21048
21049 else
21050   have_win32_dbghelp=no
21051
21052 fi
21053
21054 if test "$with_readline" = yes; then
21055   { $as_echo "$as_me:$LINENO: checking for rl_completion_append_character" >&5
21056 $as_echo_n "checking for rl_completion_append_character... " >&6; }
21057 if test "${pgac_cv_var_rl_completion_append_character+set}" = set; then
21058   $as_echo_n "(cached) " >&6
21059 else
21060   cat >conftest.$ac_ext <<_ACEOF
21061 /* confdefs.h.  */
21062 _ACEOF
21063 cat confdefs.h >>conftest.$ac_ext
21064 cat >>conftest.$ac_ext <<_ACEOF
21065 /* end confdefs.h.  */
21066 #include <stdio.h>
21067 #ifdef HAVE_READLINE_READLINE_H
21068 # include <readline/readline.h>
21069 #elif defined(HAVE_READLINE_H)
21070 # include <readline.h>
21071 #endif
21072
21073 int
21074 main ()
21075 {
21076 rl_completion_append_character = 'x';
21077   ;
21078   return 0;
21079 }
21080 _ACEOF
21081 rm -f conftest.$ac_objext conftest$ac_exeext
21082 if { (ac_try="$ac_link"
21083 case "(($ac_try" in
21084   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21085   *) ac_try_echo=$ac_try;;
21086 esac
21087 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21088 $as_echo "$ac_try_echo") >&5
21089   (eval "$ac_link") 2>conftest.er1
21090   ac_status=$?
21091   grep -v '^ *+' conftest.er1 >conftest.err
21092   rm -f conftest.er1
21093   cat conftest.err >&5
21094   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21095   (exit $ac_status); } && {
21096          test -z "$ac_c_werror_flag" ||
21097          test ! -s conftest.err
21098        } && test -s conftest$ac_exeext && {
21099          test "$cross_compiling" = yes ||
21100          $as_test_x conftest$ac_exeext
21101        }; then
21102   pgac_cv_var_rl_completion_append_character=yes
21103 else
21104   $as_echo "$as_me: failed program was:" >&5
21105 sed 's/^/| /' conftest.$ac_ext >&5
21106
21107         pgac_cv_var_rl_completion_append_character=no
21108 fi
21109
21110 rm -rf conftest.dSYM
21111 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21112       conftest$ac_exeext conftest.$ac_ext
21113 fi
21114 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_rl_completion_append_character" >&5
21115 $as_echo "$pgac_cv_var_rl_completion_append_character" >&6; }
21116 if test x"$pgac_cv_var_rl_completion_append_character" = x"yes"; then
21117
21118 cat >>confdefs.h <<\_ACEOF
21119 #define HAVE_RL_COMPLETION_APPEND_CHARACTER 1
21120 _ACEOF
21121
21122 fi
21123
21124
21125 for ac_func in rl_completion_matches rl_filename_completion_function
21126 do
21127 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21128 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21129 $as_echo_n "checking for $ac_func... " >&6; }
21130 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21131   $as_echo_n "(cached) " >&6
21132 else
21133   cat >conftest.$ac_ext <<_ACEOF
21134 /* confdefs.h.  */
21135 _ACEOF
21136 cat confdefs.h >>conftest.$ac_ext
21137 cat >>conftest.$ac_ext <<_ACEOF
21138 /* end confdefs.h.  */
21139 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21140    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21141 #define $ac_func innocuous_$ac_func
21142
21143 /* System header to define __stub macros and hopefully few prototypes,
21144     which can conflict with char $ac_func (); below.
21145     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21146     <limits.h> exists even on freestanding compilers.  */
21147
21148 #ifdef __STDC__
21149 # include <limits.h>
21150 #else
21151 # include <assert.h>
21152 #endif
21153
21154 #undef $ac_func
21155
21156 /* Override any GCC internal prototype to avoid an error.
21157    Use char because int might match the return type of a GCC
21158    builtin and then its argument prototype would still apply.  */
21159 #ifdef __cplusplus
21160 extern "C"
21161 #endif
21162 char $ac_func ();
21163 /* The GNU C library defines this for functions which it implements
21164     to always fail with ENOSYS.  Some functions are actually named
21165     something starting with __ and the normal name is an alias.  */
21166 #if defined __stub_$ac_func || defined __stub___$ac_func
21167 choke me
21168 #endif
21169
21170 int
21171 main ()
21172 {
21173 return $ac_func ();
21174   ;
21175   return 0;
21176 }
21177 _ACEOF
21178 rm -f conftest.$ac_objext conftest$ac_exeext
21179 if { (ac_try="$ac_link"
21180 case "(($ac_try" in
21181   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21182   *) ac_try_echo=$ac_try;;
21183 esac
21184 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21185 $as_echo "$ac_try_echo") >&5
21186   (eval "$ac_link") 2>conftest.er1
21187   ac_status=$?
21188   grep -v '^ *+' conftest.er1 >conftest.err
21189   rm -f conftest.er1
21190   cat conftest.err >&5
21191   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21192   (exit $ac_status); } && {
21193          test -z "$ac_c_werror_flag" ||
21194          test ! -s conftest.err
21195        } && test -s conftest$ac_exeext && {
21196          test "$cross_compiling" = yes ||
21197          $as_test_x conftest$ac_exeext
21198        }; then
21199   eval "$as_ac_var=yes"
21200 else
21201   $as_echo "$as_me: failed program was:" >&5
21202 sed 's/^/| /' conftest.$ac_ext >&5
21203
21204         eval "$as_ac_var=no"
21205 fi
21206
21207 rm -rf conftest.dSYM
21208 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21209       conftest$ac_exeext conftest.$ac_ext
21210 fi
21211 ac_res=`eval 'as_val=${'$as_ac_var'}
21212                  $as_echo "$as_val"'`
21213                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21214 $as_echo "$ac_res" >&6; }
21215 as_val=`eval 'as_val=${'$as_ac_var'}
21216                  $as_echo "$as_val"'`
21217    if test "x$as_val" = x""yes; then
21218   cat >>confdefs.h <<_ACEOF
21219 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21220 _ACEOF
21221
21222 fi
21223 done
21224
21225
21226
21227 for ac_func in append_history history_truncate_file
21228 do
21229 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21230 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21231 $as_echo_n "checking for $ac_func... " >&6; }
21232 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21233   $as_echo_n "(cached) " >&6
21234 else
21235   cat >conftest.$ac_ext <<_ACEOF
21236 /* confdefs.h.  */
21237 _ACEOF
21238 cat confdefs.h >>conftest.$ac_ext
21239 cat >>conftest.$ac_ext <<_ACEOF
21240 /* end confdefs.h.  */
21241 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21242    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21243 #define $ac_func innocuous_$ac_func
21244
21245 /* System header to define __stub macros and hopefully few prototypes,
21246     which can conflict with char $ac_func (); below.
21247     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21248     <limits.h> exists even on freestanding compilers.  */
21249
21250 #ifdef __STDC__
21251 # include <limits.h>
21252 #else
21253 # include <assert.h>
21254 #endif
21255
21256 #undef $ac_func
21257
21258 /* Override any GCC internal prototype to avoid an error.
21259    Use char because int might match the return type of a GCC
21260    builtin and then its argument prototype would still apply.  */
21261 #ifdef __cplusplus
21262 extern "C"
21263 #endif
21264 char $ac_func ();
21265 /* The GNU C library defines this for functions which it implements
21266     to always fail with ENOSYS.  Some functions are actually named
21267     something starting with __ and the normal name is an alias.  */
21268 #if defined __stub_$ac_func || defined __stub___$ac_func
21269 choke me
21270 #endif
21271
21272 int
21273 main ()
21274 {
21275 return $ac_func ();
21276   ;
21277   return 0;
21278 }
21279 _ACEOF
21280 rm -f conftest.$ac_objext conftest$ac_exeext
21281 if { (ac_try="$ac_link"
21282 case "(($ac_try" in
21283   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21284   *) ac_try_echo=$ac_try;;
21285 esac
21286 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21287 $as_echo "$ac_try_echo") >&5
21288   (eval "$ac_link") 2>conftest.er1
21289   ac_status=$?
21290   grep -v '^ *+' conftest.er1 >conftest.err
21291   rm -f conftest.er1
21292   cat conftest.err >&5
21293   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21294   (exit $ac_status); } && {
21295          test -z "$ac_c_werror_flag" ||
21296          test ! -s conftest.err
21297        } && test -s conftest$ac_exeext && {
21298          test "$cross_compiling" = yes ||
21299          $as_test_x conftest$ac_exeext
21300        }; then
21301   eval "$as_ac_var=yes"
21302 else
21303   $as_echo "$as_me: failed program was:" >&5
21304 sed 's/^/| /' conftest.$ac_ext >&5
21305
21306         eval "$as_ac_var=no"
21307 fi
21308
21309 rm -rf conftest.dSYM
21310 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21311       conftest$ac_exeext conftest.$ac_ext
21312 fi
21313 ac_res=`eval 'as_val=${'$as_ac_var'}
21314                  $as_echo "$as_val"'`
21315                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21316 $as_echo "$ac_res" >&6; }
21317 as_val=`eval 'as_val=${'$as_ac_var'}
21318                  $as_echo "$as_val"'`
21319    if test "x$as_val" = x""yes; then
21320   cat >>confdefs.h <<_ACEOF
21321 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21322 _ACEOF
21323
21324 fi
21325 done
21326
21327 fi
21328
21329
21330 { $as_echo "$as_me:$LINENO: checking for sigsetjmp" >&5
21331 $as_echo_n "checking for sigsetjmp... " >&6; }
21332 if test "${pgac_cv_func_sigsetjmp+set}" = set; then
21333   $as_echo_n "(cached) " >&6
21334 else
21335   cat >conftest.$ac_ext <<_ACEOF
21336 /* confdefs.h.  */
21337 _ACEOF
21338 cat confdefs.h >>conftest.$ac_ext
21339 cat >>conftest.$ac_ext <<_ACEOF
21340 /* end confdefs.h.  */
21341 #include <setjmp.h>
21342 int
21343 main ()
21344 {
21345 sigjmp_buf x; sigsetjmp(x, 1);
21346   ;
21347   return 0;
21348 }
21349 _ACEOF
21350 rm -f conftest.$ac_objext conftest$ac_exeext
21351 if { (ac_try="$ac_link"
21352 case "(($ac_try" in
21353   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21354   *) ac_try_echo=$ac_try;;
21355 esac
21356 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21357 $as_echo "$ac_try_echo") >&5
21358   (eval "$ac_link") 2>conftest.er1
21359   ac_status=$?
21360   grep -v '^ *+' conftest.er1 >conftest.err
21361   rm -f conftest.er1
21362   cat conftest.err >&5
21363   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21364   (exit $ac_status); } && {
21365          test -z "$ac_c_werror_flag" ||
21366          test ! -s conftest.err
21367        } && test -s conftest$ac_exeext && {
21368          test "$cross_compiling" = yes ||
21369          $as_test_x conftest$ac_exeext
21370        }; then
21371   pgac_cv_func_sigsetjmp=yes
21372 else
21373   $as_echo "$as_me: failed program was:" >&5
21374 sed 's/^/| /' conftest.$ac_ext >&5
21375
21376         pgac_cv_func_sigsetjmp=no
21377 fi
21378
21379 rm -rf conftest.dSYM
21380 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21381       conftest$ac_exeext conftest.$ac_ext
21382 fi
21383 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_sigsetjmp" >&5
21384 $as_echo "$pgac_cv_func_sigsetjmp" >&6; }
21385 if test x"$pgac_cv_func_sigsetjmp" = x"yes"; then
21386
21387 cat >>confdefs.h <<\_ACEOF
21388 #define HAVE_SIGSETJMP 1
21389 _ACEOF
21390
21391 fi
21392
21393 { $as_echo "$as_me:$LINENO: checking whether sys_siglist is declared" >&5
21394 $as_echo_n "checking whether sys_siglist is declared... " >&6; }
21395 if test "${ac_cv_have_decl_sys_siglist+set}" = set; then
21396   $as_echo_n "(cached) " >&6
21397 else
21398   cat >conftest.$ac_ext <<_ACEOF
21399 /* confdefs.h.  */
21400 _ACEOF
21401 cat confdefs.h >>conftest.$ac_ext
21402 cat >>conftest.$ac_ext <<_ACEOF
21403 /* end confdefs.h.  */
21404 #include <signal.h>
21405 /* NetBSD declares sys_siglist in unistd.h.  */
21406 #ifdef HAVE_UNISTD_H
21407 # include <unistd.h>
21408 #endif
21409
21410
21411 int
21412 main ()
21413 {
21414 #ifndef sys_siglist
21415   (void) sys_siglist;
21416 #endif
21417
21418   ;
21419   return 0;
21420 }
21421 _ACEOF
21422 rm -f conftest.$ac_objext
21423 if { (ac_try="$ac_compile"
21424 case "(($ac_try" in
21425   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21426   *) ac_try_echo=$ac_try;;
21427 esac
21428 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21429 $as_echo "$ac_try_echo") >&5
21430   (eval "$ac_compile") 2>conftest.er1
21431   ac_status=$?
21432   grep -v '^ *+' conftest.er1 >conftest.err
21433   rm -f conftest.er1
21434   cat conftest.err >&5
21435   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21436   (exit $ac_status); } && {
21437          test -z "$ac_c_werror_flag" ||
21438          test ! -s conftest.err
21439        } && test -s conftest.$ac_objext; then
21440   ac_cv_have_decl_sys_siglist=yes
21441 else
21442   $as_echo "$as_me: failed program was:" >&5
21443 sed 's/^/| /' conftest.$ac_ext >&5
21444
21445         ac_cv_have_decl_sys_siglist=no
21446 fi
21447
21448 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21449 fi
21450 { $as_echo "$as_me:$LINENO: result: $ac_cv_have_decl_sys_siglist" >&5
21451 $as_echo "$ac_cv_have_decl_sys_siglist" >&6; }
21452 if test "x$ac_cv_have_decl_sys_siglist" = x""yes; then
21453
21454 cat >>confdefs.h <<_ACEOF
21455 #define HAVE_DECL_SYS_SIGLIST 1
21456 _ACEOF
21457
21458
21459 else
21460   cat >>confdefs.h <<_ACEOF
21461 #define HAVE_DECL_SYS_SIGLIST 0
21462 _ACEOF
21463
21464
21465 fi
21466
21467
21468
21469
21470 { $as_echo "$as_me:$LINENO: checking for syslog" >&5
21471 $as_echo_n "checking for syslog... " >&6; }
21472 if test "${ac_cv_func_syslog+set}" = set; then
21473   $as_echo_n "(cached) " >&6
21474 else
21475   cat >conftest.$ac_ext <<_ACEOF
21476 /* confdefs.h.  */
21477 _ACEOF
21478 cat confdefs.h >>conftest.$ac_ext
21479 cat >>conftest.$ac_ext <<_ACEOF
21480 /* end confdefs.h.  */
21481 /* Define syslog to an innocuous variant, in case <limits.h> declares syslog.
21482    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21483 #define syslog innocuous_syslog
21484
21485 /* System header to define __stub macros and hopefully few prototypes,
21486     which can conflict with char syslog (); below.
21487     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21488     <limits.h> exists even on freestanding compilers.  */
21489
21490 #ifdef __STDC__
21491 # include <limits.h>
21492 #else
21493 # include <assert.h>
21494 #endif
21495
21496 #undef syslog
21497
21498 /* Override any GCC internal prototype to avoid an error.
21499    Use char because int might match the return type of a GCC
21500    builtin and then its argument prototype would still apply.  */
21501 #ifdef __cplusplus
21502 extern "C"
21503 #endif
21504 char syslog ();
21505 /* The GNU C library defines this for functions which it implements
21506     to always fail with ENOSYS.  Some functions are actually named
21507     something starting with __ and the normal name is an alias.  */
21508 #if defined __stub_syslog || defined __stub___syslog
21509 choke me
21510 #endif
21511
21512 int
21513 main ()
21514 {
21515 return syslog ();
21516   ;
21517   return 0;
21518 }
21519 _ACEOF
21520 rm -f conftest.$ac_objext conftest$ac_exeext
21521 if { (ac_try="$ac_link"
21522 case "(($ac_try" in
21523   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21524   *) ac_try_echo=$ac_try;;
21525 esac
21526 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21527 $as_echo "$ac_try_echo") >&5
21528   (eval "$ac_link") 2>conftest.er1
21529   ac_status=$?
21530   grep -v '^ *+' conftest.er1 >conftest.err
21531   rm -f conftest.er1
21532   cat conftest.err >&5
21533   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21534   (exit $ac_status); } && {
21535          test -z "$ac_c_werror_flag" ||
21536          test ! -s conftest.err
21537        } && test -s conftest$ac_exeext && {
21538          test "$cross_compiling" = yes ||
21539          $as_test_x conftest$ac_exeext
21540        }; then
21541   ac_cv_func_syslog=yes
21542 else
21543   $as_echo "$as_me: failed program was:" >&5
21544 sed 's/^/| /' conftest.$ac_ext >&5
21545
21546         ac_cv_func_syslog=no
21547 fi
21548
21549 rm -rf conftest.dSYM
21550 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21551       conftest$ac_exeext conftest.$ac_ext
21552 fi
21553 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_syslog" >&5
21554 $as_echo "$ac_cv_func_syslog" >&6; }
21555 if test "x$ac_cv_func_syslog" = x""yes; then
21556   if test "${ac_cv_header_syslog_h+set}" = set; then
21557   { $as_echo "$as_me:$LINENO: checking for syslog.h" >&5
21558 $as_echo_n "checking for syslog.h... " >&6; }
21559 if test "${ac_cv_header_syslog_h+set}" = set; then
21560   $as_echo_n "(cached) " >&6
21561 fi
21562 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
21563 $as_echo "$ac_cv_header_syslog_h" >&6; }
21564 else
21565   # Is the header compilable?
21566 { $as_echo "$as_me:$LINENO: checking syslog.h usability" >&5
21567 $as_echo_n "checking syslog.h usability... " >&6; }
21568 cat >conftest.$ac_ext <<_ACEOF
21569 /* confdefs.h.  */
21570 _ACEOF
21571 cat confdefs.h >>conftest.$ac_ext
21572 cat >>conftest.$ac_ext <<_ACEOF
21573 /* end confdefs.h.  */
21574 $ac_includes_default
21575 #include <syslog.h>
21576 _ACEOF
21577 rm -f conftest.$ac_objext
21578 if { (ac_try="$ac_compile"
21579 case "(($ac_try" in
21580   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21581   *) ac_try_echo=$ac_try;;
21582 esac
21583 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21584 $as_echo "$ac_try_echo") >&5
21585   (eval "$ac_compile") 2>conftest.er1
21586   ac_status=$?
21587   grep -v '^ *+' conftest.er1 >conftest.err
21588   rm -f conftest.er1
21589   cat conftest.err >&5
21590   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21591   (exit $ac_status); } && {
21592          test -z "$ac_c_werror_flag" ||
21593          test ! -s conftest.err
21594        } && test -s conftest.$ac_objext; then
21595   ac_header_compiler=yes
21596 else
21597   $as_echo "$as_me: failed program was:" >&5
21598 sed 's/^/| /' conftest.$ac_ext >&5
21599
21600         ac_header_compiler=no
21601 fi
21602
21603 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
21604 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
21605 $as_echo "$ac_header_compiler" >&6; }
21606
21607 # Is the header present?
21608 { $as_echo "$as_me:$LINENO: checking syslog.h presence" >&5
21609 $as_echo_n "checking syslog.h presence... " >&6; }
21610 cat >conftest.$ac_ext <<_ACEOF
21611 /* confdefs.h.  */
21612 _ACEOF
21613 cat confdefs.h >>conftest.$ac_ext
21614 cat >>conftest.$ac_ext <<_ACEOF
21615 /* end confdefs.h.  */
21616 #include <syslog.h>
21617 _ACEOF
21618 if { (ac_try="$ac_cpp conftest.$ac_ext"
21619 case "(($ac_try" in
21620   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21621   *) ac_try_echo=$ac_try;;
21622 esac
21623 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21624 $as_echo "$ac_try_echo") >&5
21625   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
21626   ac_status=$?
21627   grep -v '^ *+' conftest.er1 >conftest.err
21628   rm -f conftest.er1
21629   cat conftest.err >&5
21630   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21631   (exit $ac_status); } >/dev/null && {
21632          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
21633          test ! -s conftest.err
21634        }; then
21635   ac_header_preproc=yes
21636 else
21637   $as_echo "$as_me: failed program was:" >&5
21638 sed 's/^/| /' conftest.$ac_ext >&5
21639
21640   ac_header_preproc=no
21641 fi
21642
21643 rm -f conftest.err conftest.$ac_ext
21644 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
21645 $as_echo "$ac_header_preproc" >&6; }
21646
21647 # So?  What about this header?
21648 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
21649   yes:no: )
21650     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&5
21651 $as_echo "$as_me: WARNING: syslog.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
21652     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the compiler's result" >&5
21653 $as_echo "$as_me: WARNING: syslog.h: proceeding with the compiler's result" >&2;}
21654     ac_header_preproc=yes
21655     ;;
21656   no:yes:* )
21657     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: present but cannot be compiled" >&5
21658 $as_echo "$as_me: WARNING: syslog.h: present but cannot be compiled" >&2;}
21659     { $as_echo "$as_me:$LINENO: WARNING: syslog.h:     check for missing prerequisite headers?" >&5
21660 $as_echo "$as_me: WARNING: syslog.h:     check for missing prerequisite headers?" >&2;}
21661     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: see the Autoconf documentation" >&5
21662 $as_echo "$as_me: WARNING: syslog.h: see the Autoconf documentation" >&2;}
21663     { $as_echo "$as_me:$LINENO: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&5
21664 $as_echo "$as_me: WARNING: syslog.h:     section \"Present But Cannot Be Compiled\"" >&2;}
21665     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: proceeding with the preprocessor's result" >&5
21666 $as_echo "$as_me: WARNING: syslog.h: proceeding with the preprocessor's result" >&2;}
21667     { $as_echo "$as_me:$LINENO: WARNING: syslog.h: in the future, the compiler will take precedence" >&5
21668 $as_echo "$as_me: WARNING: syslog.h: in the future, the compiler will take precedence" >&2;}
21669     ( cat <<\_ASBOX
21670 ## ---------------------------------------- ##
21671 ## Report this to pgsql-bugs@postgresql.org ##
21672 ## ---------------------------------------- ##
21673 _ASBOX
21674      ) | sed "s/^/$as_me: WARNING:     /" >&2
21675     ;;
21676 esac
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 else
21682   ac_cv_header_syslog_h=$ac_header_preproc
21683 fi
21684 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_syslog_h" >&5
21685 $as_echo "$ac_cv_header_syslog_h" >&6; }
21686
21687 fi
21688 if test "x$ac_cv_header_syslog_h" = x""yes; then
21689
21690 cat >>confdefs.h <<\_ACEOF
21691 #define HAVE_SYSLOG 1
21692 _ACEOF
21693
21694 fi
21695
21696
21697 fi
21698
21699
21700 { $as_echo "$as_me:$LINENO: checking for opterr" >&5
21701 $as_echo_n "checking for opterr... " >&6; }
21702 if test "${pgac_cv_var_int_opterr+set}" = set; then
21703   $as_echo_n "(cached) " >&6
21704 else
21705   cat >conftest.$ac_ext <<_ACEOF
21706 /* confdefs.h.  */
21707 _ACEOF
21708 cat confdefs.h >>conftest.$ac_ext
21709 cat >>conftest.$ac_ext <<_ACEOF
21710 /* end confdefs.h.  */
21711 #include <unistd.h>
21712 int
21713 main ()
21714 {
21715 extern int opterr; opterr = 1;
21716   ;
21717   return 0;
21718 }
21719 _ACEOF
21720 rm -f conftest.$ac_objext conftest$ac_exeext
21721 if { (ac_try="$ac_link"
21722 case "(($ac_try" in
21723   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21724   *) ac_try_echo=$ac_try;;
21725 esac
21726 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21727 $as_echo "$ac_try_echo") >&5
21728   (eval "$ac_link") 2>conftest.er1
21729   ac_status=$?
21730   grep -v '^ *+' conftest.er1 >conftest.err
21731   rm -f conftest.er1
21732   cat conftest.err >&5
21733   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21734   (exit $ac_status); } && {
21735          test -z "$ac_c_werror_flag" ||
21736          test ! -s conftest.err
21737        } && test -s conftest$ac_exeext && {
21738          test "$cross_compiling" = yes ||
21739          $as_test_x conftest$ac_exeext
21740        }; then
21741   pgac_cv_var_int_opterr=yes
21742 else
21743   $as_echo "$as_me: failed program was:" >&5
21744 sed 's/^/| /' conftest.$ac_ext >&5
21745
21746         pgac_cv_var_int_opterr=no
21747 fi
21748
21749 rm -rf conftest.dSYM
21750 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21751       conftest$ac_exeext conftest.$ac_ext
21752 fi
21753 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_opterr" >&5
21754 $as_echo "$pgac_cv_var_int_opterr" >&6; }
21755 if test x"$pgac_cv_var_int_opterr" = x"yes"; then
21756
21757 cat >>confdefs.h <<\_ACEOF
21758 #define HAVE_INT_OPTERR 1
21759 _ACEOF
21760
21761 fi
21762
21763 { $as_echo "$as_me:$LINENO: checking for optreset" >&5
21764 $as_echo_n "checking for optreset... " >&6; }
21765 if test "${pgac_cv_var_int_optreset+set}" = set; then
21766   $as_echo_n "(cached) " >&6
21767 else
21768   cat >conftest.$ac_ext <<_ACEOF
21769 /* confdefs.h.  */
21770 _ACEOF
21771 cat confdefs.h >>conftest.$ac_ext
21772 cat >>conftest.$ac_ext <<_ACEOF
21773 /* end confdefs.h.  */
21774 #include <unistd.h>
21775 int
21776 main ()
21777 {
21778 extern int optreset; optreset = 1;
21779   ;
21780   return 0;
21781 }
21782 _ACEOF
21783 rm -f conftest.$ac_objext conftest$ac_exeext
21784 if { (ac_try="$ac_link"
21785 case "(($ac_try" in
21786   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21787   *) ac_try_echo=$ac_try;;
21788 esac
21789 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21790 $as_echo "$ac_try_echo") >&5
21791   (eval "$ac_link") 2>conftest.er1
21792   ac_status=$?
21793   grep -v '^ *+' conftest.er1 >conftest.err
21794   rm -f conftest.er1
21795   cat conftest.err >&5
21796   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21797   (exit $ac_status); } && {
21798          test -z "$ac_c_werror_flag" ||
21799          test ! -s conftest.err
21800        } && test -s conftest$ac_exeext && {
21801          test "$cross_compiling" = yes ||
21802          $as_test_x conftest$ac_exeext
21803        }; then
21804   pgac_cv_var_int_optreset=yes
21805 else
21806   $as_echo "$as_me: failed program was:" >&5
21807 sed 's/^/| /' conftest.$ac_ext >&5
21808
21809         pgac_cv_var_int_optreset=no
21810 fi
21811
21812 rm -rf conftest.dSYM
21813 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21814       conftest$ac_exeext conftest.$ac_ext
21815 fi
21816 { $as_echo "$as_me:$LINENO: result: $pgac_cv_var_int_optreset" >&5
21817 $as_echo "$pgac_cv_var_int_optreset" >&6; }
21818 if test x"$pgac_cv_var_int_optreset" = x"yes"; then
21819
21820 cat >>confdefs.h <<\_ACEOF
21821 #define HAVE_INT_OPTRESET 1
21822 _ACEOF
21823
21824 fi
21825
21826
21827
21828 for ac_func in strtoll strtoq
21829 do
21830 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21831 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21832 $as_echo_n "checking for $ac_func... " >&6; }
21833 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21834   $as_echo_n "(cached) " >&6
21835 else
21836   cat >conftest.$ac_ext <<_ACEOF
21837 /* confdefs.h.  */
21838 _ACEOF
21839 cat confdefs.h >>conftest.$ac_ext
21840 cat >>conftest.$ac_ext <<_ACEOF
21841 /* end confdefs.h.  */
21842 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21843    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21844 #define $ac_func innocuous_$ac_func
21845
21846 /* System header to define __stub macros and hopefully few prototypes,
21847     which can conflict with char $ac_func (); below.
21848     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21849     <limits.h> exists even on freestanding compilers.  */
21850
21851 #ifdef __STDC__
21852 # include <limits.h>
21853 #else
21854 # include <assert.h>
21855 #endif
21856
21857 #undef $ac_func
21858
21859 /* Override any GCC internal prototype to avoid an error.
21860    Use char because int might match the return type of a GCC
21861    builtin and then its argument prototype would still apply.  */
21862 #ifdef __cplusplus
21863 extern "C"
21864 #endif
21865 char $ac_func ();
21866 /* The GNU C library defines this for functions which it implements
21867     to always fail with ENOSYS.  Some functions are actually named
21868     something starting with __ and the normal name is an alias.  */
21869 #if defined __stub_$ac_func || defined __stub___$ac_func
21870 choke me
21871 #endif
21872
21873 int
21874 main ()
21875 {
21876 return $ac_func ();
21877   ;
21878   return 0;
21879 }
21880 _ACEOF
21881 rm -f conftest.$ac_objext conftest$ac_exeext
21882 if { (ac_try="$ac_link"
21883 case "(($ac_try" in
21884   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21885   *) ac_try_echo=$ac_try;;
21886 esac
21887 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21888 $as_echo "$ac_try_echo") >&5
21889   (eval "$ac_link") 2>conftest.er1
21890   ac_status=$?
21891   grep -v '^ *+' conftest.er1 >conftest.err
21892   rm -f conftest.er1
21893   cat conftest.err >&5
21894   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21895   (exit $ac_status); } && {
21896          test -z "$ac_c_werror_flag" ||
21897          test ! -s conftest.err
21898        } && test -s conftest$ac_exeext && {
21899          test "$cross_compiling" = yes ||
21900          $as_test_x conftest$ac_exeext
21901        }; then
21902   eval "$as_ac_var=yes"
21903 else
21904   $as_echo "$as_me: failed program was:" >&5
21905 sed 's/^/| /' conftest.$ac_ext >&5
21906
21907         eval "$as_ac_var=no"
21908 fi
21909
21910 rm -rf conftest.dSYM
21911 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
21912       conftest$ac_exeext conftest.$ac_ext
21913 fi
21914 ac_res=`eval 'as_val=${'$as_ac_var'}
21915                  $as_echo "$as_val"'`
21916                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
21917 $as_echo "$ac_res" >&6; }
21918 as_val=`eval 'as_val=${'$as_ac_var'}
21919                  $as_echo "$as_val"'`
21920    if test "x$as_val" = x""yes; then
21921   cat >>confdefs.h <<_ACEOF
21922 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
21923 _ACEOF
21924  break
21925 fi
21926 done
21927
21928
21929
21930 for ac_func in strtoull strtouq
21931 do
21932 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
21933 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
21934 $as_echo_n "checking for $ac_func... " >&6; }
21935 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
21936   $as_echo_n "(cached) " >&6
21937 else
21938   cat >conftest.$ac_ext <<_ACEOF
21939 /* confdefs.h.  */
21940 _ACEOF
21941 cat confdefs.h >>conftest.$ac_ext
21942 cat >>conftest.$ac_ext <<_ACEOF
21943 /* end confdefs.h.  */
21944 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
21945    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
21946 #define $ac_func innocuous_$ac_func
21947
21948 /* System header to define __stub macros and hopefully few prototypes,
21949     which can conflict with char $ac_func (); below.
21950     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
21951     <limits.h> exists even on freestanding compilers.  */
21952
21953 #ifdef __STDC__
21954 # include <limits.h>
21955 #else
21956 # include <assert.h>
21957 #endif
21958
21959 #undef $ac_func
21960
21961 /* Override any GCC internal prototype to avoid an error.
21962    Use char because int might match the return type of a GCC
21963    builtin and then its argument prototype would still apply.  */
21964 #ifdef __cplusplus
21965 extern "C"
21966 #endif
21967 char $ac_func ();
21968 /* The GNU C library defines this for functions which it implements
21969     to always fail with ENOSYS.  Some functions are actually named
21970     something starting with __ and the normal name is an alias.  */
21971 #if defined __stub_$ac_func || defined __stub___$ac_func
21972 choke me
21973 #endif
21974
21975 int
21976 main ()
21977 {
21978 return $ac_func ();
21979   ;
21980   return 0;
21981 }
21982 _ACEOF
21983 rm -f conftest.$ac_objext conftest$ac_exeext
21984 if { (ac_try="$ac_link"
21985 case "(($ac_try" in
21986   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
21987   *) ac_try_echo=$ac_try;;
21988 esac
21989 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
21990 $as_echo "$ac_try_echo") >&5
21991   (eval "$ac_link") 2>conftest.er1
21992   ac_status=$?
21993   grep -v '^ *+' conftest.er1 >conftest.err
21994   rm -f conftest.er1
21995   cat conftest.err >&5
21996   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
21997   (exit $ac_status); } && {
21998          test -z "$ac_c_werror_flag" ||
21999          test ! -s conftest.err
22000        } && test -s conftest$ac_exeext && {
22001          test "$cross_compiling" = yes ||
22002          $as_test_x conftest$ac_exeext
22003        }; then
22004   eval "$as_ac_var=yes"
22005 else
22006   $as_echo "$as_me: failed program was:" >&5
22007 sed 's/^/| /' conftest.$ac_ext >&5
22008
22009         eval "$as_ac_var=no"
22010 fi
22011
22012 rm -rf conftest.dSYM
22013 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22014       conftest$ac_exeext conftest.$ac_ext
22015 fi
22016 ac_res=`eval 'as_val=${'$as_ac_var'}
22017                  $as_echo "$as_val"'`
22018                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22019 $as_echo "$ac_res" >&6; }
22020 as_val=`eval 'as_val=${'$as_ac_var'}
22021                  $as_echo "$as_val"'`
22022    if test "x$as_val" = x""yes; then
22023   cat >>confdefs.h <<_ACEOF
22024 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22025 _ACEOF
22026  break
22027 fi
22028 done
22029
22030
22031 # Check for one of atexit() or on_exit()
22032
22033 for ac_func in atexit
22034 do
22035 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22036 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22037 $as_echo_n "checking for $ac_func... " >&6; }
22038 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22039   $as_echo_n "(cached) " >&6
22040 else
22041   cat >conftest.$ac_ext <<_ACEOF
22042 /* confdefs.h.  */
22043 _ACEOF
22044 cat confdefs.h >>conftest.$ac_ext
22045 cat >>conftest.$ac_ext <<_ACEOF
22046 /* end confdefs.h.  */
22047 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22048    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22049 #define $ac_func innocuous_$ac_func
22050
22051 /* System header to define __stub macros and hopefully few prototypes,
22052     which can conflict with char $ac_func (); below.
22053     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22054     <limits.h> exists even on freestanding compilers.  */
22055
22056 #ifdef __STDC__
22057 # include <limits.h>
22058 #else
22059 # include <assert.h>
22060 #endif
22061
22062 #undef $ac_func
22063
22064 /* Override any GCC internal prototype to avoid an error.
22065    Use char because int might match the return type of a GCC
22066    builtin and then its argument prototype would still apply.  */
22067 #ifdef __cplusplus
22068 extern "C"
22069 #endif
22070 char $ac_func ();
22071 /* The GNU C library defines this for functions which it implements
22072     to always fail with ENOSYS.  Some functions are actually named
22073     something starting with __ and the normal name is an alias.  */
22074 #if defined __stub_$ac_func || defined __stub___$ac_func
22075 choke me
22076 #endif
22077
22078 int
22079 main ()
22080 {
22081 return $ac_func ();
22082   ;
22083   return 0;
22084 }
22085 _ACEOF
22086 rm -f conftest.$ac_objext conftest$ac_exeext
22087 if { (ac_try="$ac_link"
22088 case "(($ac_try" in
22089   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22090   *) ac_try_echo=$ac_try;;
22091 esac
22092 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22093 $as_echo "$ac_try_echo") >&5
22094   (eval "$ac_link") 2>conftest.er1
22095   ac_status=$?
22096   grep -v '^ *+' conftest.er1 >conftest.err
22097   rm -f conftest.er1
22098   cat conftest.err >&5
22099   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22100   (exit $ac_status); } && {
22101          test -z "$ac_c_werror_flag" ||
22102          test ! -s conftest.err
22103        } && test -s conftest$ac_exeext && {
22104          test "$cross_compiling" = yes ||
22105          $as_test_x conftest$ac_exeext
22106        }; then
22107   eval "$as_ac_var=yes"
22108 else
22109   $as_echo "$as_me: failed program was:" >&5
22110 sed 's/^/| /' conftest.$ac_ext >&5
22111
22112         eval "$as_ac_var=no"
22113 fi
22114
22115 rm -rf conftest.dSYM
22116 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22117       conftest$ac_exeext conftest.$ac_ext
22118 fi
22119 ac_res=`eval 'as_val=${'$as_ac_var'}
22120                  $as_echo "$as_val"'`
22121                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22122 $as_echo "$ac_res" >&6; }
22123 as_val=`eval 'as_val=${'$as_ac_var'}
22124                  $as_echo "$as_val"'`
22125    if test "x$as_val" = x""yes; then
22126   cat >>confdefs.h <<_ACEOF
22127 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22128 _ACEOF
22129
22130 else
22131
22132 for ac_func in on_exit
22133 do
22134 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22135 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22136 $as_echo_n "checking for $ac_func... " >&6; }
22137 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22138   $as_echo_n "(cached) " >&6
22139 else
22140   cat >conftest.$ac_ext <<_ACEOF
22141 /* confdefs.h.  */
22142 _ACEOF
22143 cat confdefs.h >>conftest.$ac_ext
22144 cat >>conftest.$ac_ext <<_ACEOF
22145 /* end confdefs.h.  */
22146 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22147    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22148 #define $ac_func innocuous_$ac_func
22149
22150 /* System header to define __stub macros and hopefully few prototypes,
22151     which can conflict with char $ac_func (); below.
22152     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22153     <limits.h> exists even on freestanding compilers.  */
22154
22155 #ifdef __STDC__
22156 # include <limits.h>
22157 #else
22158 # include <assert.h>
22159 #endif
22160
22161 #undef $ac_func
22162
22163 /* Override any GCC internal prototype to avoid an error.
22164    Use char because int might match the return type of a GCC
22165    builtin and then its argument prototype would still apply.  */
22166 #ifdef __cplusplus
22167 extern "C"
22168 #endif
22169 char $ac_func ();
22170 /* The GNU C library defines this for functions which it implements
22171     to always fail with ENOSYS.  Some functions are actually named
22172     something starting with __ and the normal name is an alias.  */
22173 #if defined __stub_$ac_func || defined __stub___$ac_func
22174 choke me
22175 #endif
22176
22177 int
22178 main ()
22179 {
22180 return $ac_func ();
22181   ;
22182   return 0;
22183 }
22184 _ACEOF
22185 rm -f conftest.$ac_objext conftest$ac_exeext
22186 if { (ac_try="$ac_link"
22187 case "(($ac_try" in
22188   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22189   *) ac_try_echo=$ac_try;;
22190 esac
22191 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22192 $as_echo "$ac_try_echo") >&5
22193   (eval "$ac_link") 2>conftest.er1
22194   ac_status=$?
22195   grep -v '^ *+' conftest.er1 >conftest.err
22196   rm -f conftest.er1
22197   cat conftest.err >&5
22198   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22199   (exit $ac_status); } && {
22200          test -z "$ac_c_werror_flag" ||
22201          test ! -s conftest.err
22202        } && test -s conftest$ac_exeext && {
22203          test "$cross_compiling" = yes ||
22204          $as_test_x conftest$ac_exeext
22205        }; then
22206   eval "$as_ac_var=yes"
22207 else
22208   $as_echo "$as_me: failed program was:" >&5
22209 sed 's/^/| /' conftest.$ac_ext >&5
22210
22211         eval "$as_ac_var=no"
22212 fi
22213
22214 rm -rf conftest.dSYM
22215 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22216       conftest$ac_exeext conftest.$ac_ext
22217 fi
22218 ac_res=`eval 'as_val=${'$as_ac_var'}
22219                  $as_echo "$as_val"'`
22220                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
22221 $as_echo "$ac_res" >&6; }
22222 as_val=`eval 'as_val=${'$as_ac_var'}
22223                  $as_echo "$as_val"'`
22224    if test "x$as_val" = x""yes; then
22225   cat >>confdefs.h <<_ACEOF
22226 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
22227 _ACEOF
22228
22229 else
22230   { { $as_echo "$as_me:$LINENO: error: neither atexit() nor on_exit() found" >&5
22231 $as_echo "$as_me: error: neither atexit() nor on_exit() found" >&2;}
22232    { (exit 1); exit 1; }; }
22233 fi
22234 done
22235
22236 fi
22237 done
22238
22239
22240
22241 #
22242 # Pthreads
22243 #
22244 # For each platform, we need to know about any special compile and link
22245 # libraries, and whether the normal C function names are thread-safe.
22246 # See the comment at the top of src/port/thread.c for more information.
22247 # WIN32 doesn't need the pthread tests;  it always uses threads
22248 if test "$enable_thread_safety" = yes -a "$PORTNAME" != "win32"; then
22249
22250
22251
22252 ac_ext=c
22253 ac_cpp='$CPP $CPPFLAGS'
22254 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22255 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22256 ac_compiler_gnu=$ac_cv_c_compiler_gnu
22257
22258 acx_pthread_ok=no
22259
22260 # We used to check for pthread.h first, but this fails if pthread.h
22261 # requires special compiler flags (e.g. on True64 or Sequent).
22262 # It gets checked for in the link test anyway.
22263
22264 # First of all, check if the user has set any of the PTHREAD_LIBS,
22265 # etcetera environment variables, and if threads linking works using
22266 # them:
22267 if test x"$PTHREAD_LIBS$PTHREAD_CFLAGS" != x; then
22268         save_CFLAGS="$CFLAGS"
22269         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
22270         save_LIBS="$LIBS"
22271         LIBS="$PTHREAD_LIBS $LIBS"
22272         { $as_echo "$as_me:$LINENO: checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS" >&5
22273 $as_echo_n "checking for pthread_join in LIBS=$PTHREAD_LIBS with CFLAGS=$PTHREAD_CFLAGS... " >&6; }
22274         cat >conftest.$ac_ext <<_ACEOF
22275 /* confdefs.h.  */
22276 _ACEOF
22277 cat confdefs.h >>conftest.$ac_ext
22278 cat >>conftest.$ac_ext <<_ACEOF
22279 /* end confdefs.h.  */
22280
22281 /* Override any GCC internal prototype to avoid an error.
22282    Use char because int might match the return type of a GCC
22283    builtin and then its argument prototype would still apply.  */
22284 #ifdef __cplusplus
22285 extern "C"
22286 #endif
22287 char pthread_join ();
22288 int
22289 main ()
22290 {
22291 return pthread_join ();
22292   ;
22293   return 0;
22294 }
22295 _ACEOF
22296 rm -f conftest.$ac_objext conftest$ac_exeext
22297 if { (ac_try="$ac_link"
22298 case "(($ac_try" in
22299   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22300   *) ac_try_echo=$ac_try;;
22301 esac
22302 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22303 $as_echo "$ac_try_echo") >&5
22304   (eval "$ac_link") 2>conftest.er1
22305   ac_status=$?
22306   grep -v '^ *+' conftest.er1 >conftest.err
22307   rm -f conftest.er1
22308   cat conftest.err >&5
22309   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22310   (exit $ac_status); } && {
22311          test -z "$ac_c_werror_flag" ||
22312          test ! -s conftest.err
22313        } && test -s conftest$ac_exeext && {
22314          test "$cross_compiling" = yes ||
22315          $as_test_x conftest$ac_exeext
22316        }; then
22317   acx_pthread_ok=yes
22318 else
22319   $as_echo "$as_me: failed program was:" >&5
22320 sed 's/^/| /' conftest.$ac_ext >&5
22321
22322
22323 fi
22324
22325 rm -rf conftest.dSYM
22326 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22327       conftest$ac_exeext conftest.$ac_ext
22328         { $as_echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
22329 $as_echo "$acx_pthread_ok" >&6; }
22330         if test x"$acx_pthread_ok" = xno; then
22331                 PTHREAD_LIBS=""
22332                 PTHREAD_CFLAGS=""
22333         fi
22334         LIBS="$save_LIBS"
22335         CFLAGS="$save_CFLAGS"
22336 fi
22337
22338 # We must check for the threads library under a number of different
22339 # names; the ordering is very important because some systems
22340 # (e.g. DEC) have both -lpthread and -lpthreads, where one of the
22341 # libraries is broken (non-POSIX).
22342
22343 # Create a list of thread flags to try.  Items starting with a "-" are
22344 # C compiler flags, and other items are library names, except for "none"
22345 # which indicates that we try without any flags at all, and "pthread-config"
22346 # which is a program returning the flags for the Pth emulation library.
22347
22348 acx_pthread_flags="pthreads none -Kthread -kthread lthread -pthread -pthreads -mthreads pthread --thread-safe -mt pthread-config pthreadGC2"
22349
22350 # The ordering *is* (sometimes) important.  Some notes on the
22351 # individual items follow:
22352
22353 # pthreads: AIX (must check this before -lpthread)
22354 # none: in case threads are in libc; should be tried before -Kthread and
22355 #       other compiler flags to prevent continual compiler warnings
22356 # -Kthread: Sequent (threads in libc, but -Kthread needed for pthread.h)
22357 # -kthread: FreeBSD kernel threads (preferred to -pthread since SMP-able)
22358 # lthread: LinuxThreads port on FreeBSD (also preferred to -pthread)
22359 # -pthread: Linux/gcc (kernel threads), BSD/gcc (userland threads)
22360 # -pthreads: Solaris/gcc
22361 # -mthreads: Mingw32/gcc, Lynx/gcc
22362 # -mt: Sun Workshop C (may only link SunOS threads [-lthread], but it
22363 #      doesn't hurt to check since this sometimes defines pthreads too;
22364 #      also defines -D_REENTRANT)
22365 # pthread: Linux, etcetera
22366 # --thread-safe: KAI C++
22367 # pthread-config: use pthread-config program (for GNU Pth library)
22368
22369 case "${host_cpu}-${host_os}" in
22370         *solaris*)
22371
22372         # On Solaris (at least, for some versions), libc contains stubbed
22373         # (non-functional) versions of the pthreads routines, so link-based
22374         # tests will erroneously succeed.  (We need to link with -pthread or
22375         # -lpthread.)  (The stubs are missing pthread_cleanup_push, or rather
22376         # a function called by this macro, so we could check for that, but
22377         # who knows whether they'll stub that too in a future libc.)  So,
22378         # we'll just look for -pthreads and -lpthread first:
22379
22380         acx_pthread_flags="-pthread -pthreads pthread -mt $acx_pthread_flags"
22381         ;;
22382 esac
22383
22384 if test x"$acx_pthread_ok" = xno; then
22385 for flag in $acx_pthread_flags; do
22386
22387         tryPTHREAD_CFLAGS=""
22388         tryPTHREAD_LIBS=""
22389         case $flag in
22390                 none)
22391                 { $as_echo "$as_me:$LINENO: checking whether pthreads work without any flags" >&5
22392 $as_echo_n "checking whether pthreads work without any flags... " >&6; }
22393                 ;;
22394
22395                 -*)
22396                 { $as_echo "$as_me:$LINENO: checking whether pthreads work with $flag" >&5
22397 $as_echo_n "checking whether pthreads work with $flag... " >&6; }
22398                 tryPTHREAD_CFLAGS="$flag"
22399                 ;;
22400
22401                 pthread-config)
22402                 # skip this if we already have flags defined, for PostgreSQL
22403                 if test x"$PTHREAD_CFLAGS" != x -o x"$PTHREAD_LIBS" != x; then continue; fi
22404                 # Extract the first word of "pthread-config", so it can be a program name with args.
22405 set dummy pthread-config; ac_word=$2
22406 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
22407 $as_echo_n "checking for $ac_word... " >&6; }
22408 if test "${ac_cv_prog_acx_pthread_config+set}" = set; then
22409   $as_echo_n "(cached) " >&6
22410 else
22411   if test -n "$acx_pthread_config"; then
22412   ac_cv_prog_acx_pthread_config="$acx_pthread_config" # Let the user override the test.
22413 else
22414 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22415 for as_dir in $PATH
22416 do
22417   IFS=$as_save_IFS
22418   test -z "$as_dir" && as_dir=.
22419   for ac_exec_ext in '' $ac_executable_extensions; do
22420   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
22421     ac_cv_prog_acx_pthread_config="yes"
22422     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22423     break 2
22424   fi
22425 done
22426 done
22427 IFS=$as_save_IFS
22428
22429   test -z "$ac_cv_prog_acx_pthread_config" && ac_cv_prog_acx_pthread_config="no"
22430 fi
22431 fi
22432 acx_pthread_config=$ac_cv_prog_acx_pthread_config
22433 if test -n "$acx_pthread_config"; then
22434   { $as_echo "$as_me:$LINENO: result: $acx_pthread_config" >&5
22435 $as_echo "$acx_pthread_config" >&6; }
22436 else
22437   { $as_echo "$as_me:$LINENO: result: no" >&5
22438 $as_echo "no" >&6; }
22439 fi
22440
22441
22442                 if test x"$acx_pthread_config" = xno; then continue; fi
22443                 tryPTHREAD_CFLAGS="`pthread-config --cflags`"
22444                 tryPTHREAD_LIBS="`pthread-config --ldflags` `pthread-config --libs`"
22445                 ;;
22446
22447                 *)
22448                 { $as_echo "$as_me:$LINENO: checking for the pthreads library -l$flag" >&5
22449 $as_echo_n "checking for the pthreads library -l$flag... " >&6; }
22450                 tryPTHREAD_LIBS="-l$flag"
22451                 ;;
22452         esac
22453
22454         save_LIBS="$LIBS"
22455         save_CFLAGS="$CFLAGS"
22456         LIBS="$tryPTHREAD_LIBS $PTHREAD_LIBS $LIBS"
22457         CFLAGS="$CFLAGS $PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
22458
22459         # Check for various functions.  We must include pthread.h,
22460         # since some functions may be macros.  (On the Sequent, we
22461         # need a special flag -Kthread to make this header compile.)
22462         # We check for pthread_join because it is in -lpthread on IRIX
22463         # while pthread_create is in libc.  We check for pthread_attr_init
22464         # due to DEC craziness with -lpthreads.  We check for
22465         # pthread_cleanup_push because it is one of the few pthread
22466         # functions on Solaris that doesn't have a non-functional libc stub.
22467         # We try pthread_create on general principles.
22468         cat >conftest.$ac_ext <<_ACEOF
22469 /* confdefs.h.  */
22470 _ACEOF
22471 cat confdefs.h >>conftest.$ac_ext
22472 cat >>conftest.$ac_ext <<_ACEOF
22473 /* end confdefs.h.  */
22474 #include <pthread.h>
22475 int
22476 main ()
22477 {
22478 pthread_t th; pthread_join(th, 0);
22479                      pthread_attr_init(0); pthread_cleanup_push(0, 0);
22480                      pthread_create(0,0,0,0); pthread_cleanup_pop(0);
22481   ;
22482   return 0;
22483 }
22484 _ACEOF
22485 rm -f conftest.$ac_objext conftest$ac_exeext
22486 if { (ac_try="$ac_link"
22487 case "(($ac_try" in
22488   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22489   *) ac_try_echo=$ac_try;;
22490 esac
22491 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22492 $as_echo "$ac_try_echo") >&5
22493   (eval "$ac_link") 2>conftest.er1
22494   ac_status=$?
22495   grep -v '^ *+' conftest.er1 >conftest.err
22496   rm -f conftest.er1
22497   cat conftest.err >&5
22498   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22499   (exit $ac_status); } && {
22500          test -z "$ac_c_werror_flag" ||
22501          test ! -s conftest.err
22502        } && test -s conftest$ac_exeext && {
22503          test "$cross_compiling" = yes ||
22504          $as_test_x conftest$ac_exeext
22505        }; then
22506   acx_pthread_ok=yes
22507 else
22508   $as_echo "$as_me: failed program was:" >&5
22509 sed 's/^/| /' conftest.$ac_ext >&5
22510
22511         acx_pthread_ok=no
22512 fi
22513
22514 rm -rf conftest.dSYM
22515 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22516       conftest$ac_exeext conftest.$ac_ext
22517
22518         if test "x$acx_pthread_ok" = xyes; then
22519             # Don't use options that are ignored by the compiler.
22520             # We find them by checking stderror.
22521             cat >conftest.$ac_ext <<_ACEOF
22522 int
22523 main (int argc, char **argv)
22524 {
22525   (void) argc;
22526   (void) argv;
22527   return 0;
22528 }
22529 _ACEOF
22530             rm -f conftest.$ac_objext conftest$ac_exeext
22531             if test "`(eval $ac_link 2>&1 1>&5)`" = ""; then
22532                 # we continue with more flags because Linux needs -lpthread
22533                 # for libpq builds on PostgreSQL.  The test above only
22534                 # tests for building binaries, not shared libraries.
22535                 PTHREAD_LIBS=" $tryPTHREAD_LIBS $PTHREAD_LIBS"
22536                 PTHREAD_CFLAGS="$PTHREAD_CFLAGS $tryPTHREAD_CFLAGS"
22537             else   acx_pthread_ok=no
22538             fi
22539         fi
22540
22541         LIBS="$save_LIBS"
22542         CFLAGS="$save_CFLAGS"
22543
22544         { $as_echo "$as_me:$LINENO: result: $acx_pthread_ok" >&5
22545 $as_echo "$acx_pthread_ok" >&6; }
22546 done
22547 fi
22548
22549 # Various other checks:
22550 if test "x$acx_pthread_ok" = xyes; then
22551         save_LIBS="$LIBS"
22552         LIBS="$PTHREAD_LIBS $LIBS"
22553         save_CFLAGS="$CFLAGS"
22554         CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
22555
22556         # Detect AIX lossage: threads are created detached by default
22557         # and the JOINABLE attribute has a nonstandard name (UNDETACHED).
22558         { $as_echo "$as_me:$LINENO: checking for joinable pthread attribute" >&5
22559 $as_echo_n "checking for joinable pthread attribute... " >&6; }
22560         cat >conftest.$ac_ext <<_ACEOF
22561 /* confdefs.h.  */
22562 _ACEOF
22563 cat confdefs.h >>conftest.$ac_ext
22564 cat >>conftest.$ac_ext <<_ACEOF
22565 /* end confdefs.h.  */
22566 #include <pthread.h>
22567 int
22568 main ()
22569 {
22570 int attr=PTHREAD_CREATE_JOINABLE;
22571   ;
22572   return 0;
22573 }
22574 _ACEOF
22575 rm -f conftest.$ac_objext conftest$ac_exeext
22576 if { (ac_try="$ac_link"
22577 case "(($ac_try" in
22578   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22579   *) ac_try_echo=$ac_try;;
22580 esac
22581 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22582 $as_echo "$ac_try_echo") >&5
22583   (eval "$ac_link") 2>conftest.er1
22584   ac_status=$?
22585   grep -v '^ *+' conftest.er1 >conftest.err
22586   rm -f conftest.er1
22587   cat conftest.err >&5
22588   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22589   (exit $ac_status); } && {
22590          test -z "$ac_c_werror_flag" ||
22591          test ! -s conftest.err
22592        } && test -s conftest$ac_exeext && {
22593          test "$cross_compiling" = yes ||
22594          $as_test_x conftest$ac_exeext
22595        }; then
22596   ok=PTHREAD_CREATE_JOINABLE
22597 else
22598   $as_echo "$as_me: failed program was:" >&5
22599 sed 's/^/| /' conftest.$ac_ext >&5
22600
22601         ok=unknown
22602 fi
22603
22604 rm -rf conftest.dSYM
22605 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22606       conftest$ac_exeext conftest.$ac_ext
22607         if test x"$ok" = xunknown; then
22608                 cat >conftest.$ac_ext <<_ACEOF
22609 /* confdefs.h.  */
22610 _ACEOF
22611 cat confdefs.h >>conftest.$ac_ext
22612 cat >>conftest.$ac_ext <<_ACEOF
22613 /* end confdefs.h.  */
22614 #include <pthread.h>
22615 int
22616 main ()
22617 {
22618 int attr=PTHREAD_CREATE_UNDETACHED;
22619   ;
22620   return 0;
22621 }
22622 _ACEOF
22623 rm -f conftest.$ac_objext conftest$ac_exeext
22624 if { (ac_try="$ac_link"
22625 case "(($ac_try" in
22626   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22627   *) ac_try_echo=$ac_try;;
22628 esac
22629 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22630 $as_echo "$ac_try_echo") >&5
22631   (eval "$ac_link") 2>conftest.er1
22632   ac_status=$?
22633   grep -v '^ *+' conftest.er1 >conftest.err
22634   rm -f conftest.er1
22635   cat conftest.err >&5
22636   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22637   (exit $ac_status); } && {
22638          test -z "$ac_c_werror_flag" ||
22639          test ! -s conftest.err
22640        } && test -s conftest$ac_exeext && {
22641          test "$cross_compiling" = yes ||
22642          $as_test_x conftest$ac_exeext
22643        }; then
22644   ok=PTHREAD_CREATE_UNDETACHED
22645 else
22646   $as_echo "$as_me: failed program was:" >&5
22647 sed 's/^/| /' conftest.$ac_ext >&5
22648
22649         ok=unknown
22650 fi
22651
22652 rm -rf conftest.dSYM
22653 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
22654       conftest$ac_exeext conftest.$ac_ext
22655         fi
22656         if test x"$ok" != xPTHREAD_CREATE_JOINABLE; then
22657
22658 cat >>confdefs.h <<\_ACEOF
22659 #define PTHREAD_CREATE_JOINABLE $ok
22660 _ACEOF
22661
22662         fi
22663         { $as_echo "$as_me:$LINENO: result: ${ok}" >&5
22664 $as_echo "${ok}" >&6; }
22665         if test x"$ok" = xunknown; then
22666                 { $as_echo "$as_me:$LINENO: WARNING: we do not know how to create joinable pthreads" >&5
22667 $as_echo "$as_me: WARNING: we do not know how to create joinable pthreads" >&2;}
22668         fi
22669
22670         { $as_echo "$as_me:$LINENO: checking if more special flags are required for pthreads" >&5
22671 $as_echo_n "checking if more special flags are required for pthreads... " >&6; }
22672         flag=no
22673 # We always add these in PostgreSQL
22674 #       case "${host_cpu}-${host_os}" in
22675 #               *-aix* | *-freebsd* | *-darwin*) flag="-D_THREAD_SAFE";;
22676 #               *solaris* | *-osf* | *-hpux*) flag="-D_REENTRANT";;
22677 #       esac
22678         { $as_echo "$as_me:$LINENO: result: ${flag}" >&5
22679 $as_echo "${flag}" >&6; }
22680         if test "x$flag" != xno; then
22681                 PTHREAD_CFLAGS="$flag $PTHREAD_CFLAGS"
22682         fi
22683
22684         LIBS="$save_LIBS"
22685         CFLAGS="$save_CFLAGS"
22686
22687 # Supporting cc_r would require a special CC in all places that
22688 # use libpq, and that is ugly, so we don't do it.  Users can still
22689 # define their compiler as cc_r to do thread builds of everything.
22690         # More AIX lossage: must compile with cc_r
22691         # Extract the first word of "cc_r", so it can be a program name with args.
22692 set dummy cc_r; ac_word=$2
22693 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
22694 $as_echo_n "checking for $ac_word... " >&6; }
22695 if test "${ac_cv_prog_PTHREAD_CC+set}" = set; then
22696   $as_echo_n "(cached) " >&6
22697 else
22698   if test -n "$PTHREAD_CC"; then
22699   ac_cv_prog_PTHREAD_CC="$PTHREAD_CC" # Let the user override the test.
22700 else
22701 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
22702 for as_dir in $PATH
22703 do
22704   IFS=$as_save_IFS
22705   test -z "$as_dir" && as_dir=.
22706   for ac_exec_ext in '' $ac_executable_extensions; do
22707   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
22708     ac_cv_prog_PTHREAD_CC="cc_r"
22709     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
22710     break 2
22711   fi
22712 done
22713 done
22714 IFS=$as_save_IFS
22715
22716   test -z "$ac_cv_prog_PTHREAD_CC" && ac_cv_prog_PTHREAD_CC="${CC}"
22717 fi
22718 fi
22719 PTHREAD_CC=$ac_cv_prog_PTHREAD_CC
22720 if test -n "$PTHREAD_CC"; then
22721   { $as_echo "$as_me:$LINENO: result: $PTHREAD_CC" >&5
22722 $as_echo "$PTHREAD_CC" >&6; }
22723 else
22724   { $as_echo "$as_me:$LINENO: result: no" >&5
22725 $as_echo "no" >&6; }
22726 fi
22727
22728
22729 else
22730         PTHREAD_CC="$CC"
22731 fi
22732
22733
22734
22735
22736
22737 # Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
22738 if test x"$acx_pthread_ok" = xyes; then
22739
22740 cat >>confdefs.h <<\_ACEOF
22741 #define HAVE_PTHREAD 1
22742 _ACEOF
22743
22744         :
22745 else
22746         acx_pthread_ok=no
22747
22748 fi
22749 ac_ext=c
22750 ac_cpp='$CPP $CPPFLAGS'
22751 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
22752 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
22753 ac_compiler_gnu=$ac_cv_c_compiler_gnu
22754
22755         # set thread flags
22756
22757 # Some platforms use these, so just define them.  They can't hurt if they
22758 # are not supported.  For example, on Solaris -D_POSIX_PTHREAD_SEMANTICS
22759 # enables 5-arg getpwuid_r, among other things.
22760 PTHREAD_CFLAGS="$PTHREAD_CFLAGS -D_REENTRANT -D_THREAD_SAFE -D_POSIX_PTHREAD_SEMANTICS"
22761
22762
22763 # At this point, we don't want to muck with the compiler name for threading.
22764 # Let's see who fails, perhaps AIX.  2004-04-23
22765 if test "$PTHREAD_CC" != "$CC"; then
22766 { { $as_echo "$as_me:$LINENO: error:
22767 PostgreSQL does not support platforms that require a special compiler
22768 for thread safety;  use --disable-thread-safety to disable thread safety." >&5
22769 $as_echo "$as_me: error:
22770 PostgreSQL does not support platforms that require a special compiler
22771 for thread safety;  use --disable-thread-safety to disable thread safety." >&2;}
22772    { (exit 1); exit 1; }; }
22773 fi
22774
22775 # Check for *_r functions
22776 _CFLAGS="$CFLAGS"
22777 _LIBS="$LIBS"
22778 CFLAGS="$CFLAGS $PTHREAD_CFLAGS"
22779 LIBS="$LIBS $PTHREAD_LIBS"
22780
22781 if test "$PORTNAME" != "win32"; then
22782 if test "${ac_cv_header_pthread_h+set}" = set; then
22783   { $as_echo "$as_me:$LINENO: checking for pthread.h" >&5
22784 $as_echo_n "checking for pthread.h... " >&6; }
22785 if test "${ac_cv_header_pthread_h+set}" = set; then
22786   $as_echo_n "(cached) " >&6
22787 fi
22788 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
22789 $as_echo "$ac_cv_header_pthread_h" >&6; }
22790 else
22791   # Is the header compilable?
22792 { $as_echo "$as_me:$LINENO: checking pthread.h usability" >&5
22793 $as_echo_n "checking pthread.h usability... " >&6; }
22794 cat >conftest.$ac_ext <<_ACEOF
22795 /* confdefs.h.  */
22796 _ACEOF
22797 cat confdefs.h >>conftest.$ac_ext
22798 cat >>conftest.$ac_ext <<_ACEOF
22799 /* end confdefs.h.  */
22800 $ac_includes_default
22801 #include <pthread.h>
22802 _ACEOF
22803 rm -f conftest.$ac_objext
22804 if { (ac_try="$ac_compile"
22805 case "(($ac_try" in
22806   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22807   *) ac_try_echo=$ac_try;;
22808 esac
22809 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22810 $as_echo "$ac_try_echo") >&5
22811   (eval "$ac_compile") 2>conftest.er1
22812   ac_status=$?
22813   grep -v '^ *+' conftest.er1 >conftest.err
22814   rm -f conftest.er1
22815   cat conftest.err >&5
22816   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22817   (exit $ac_status); } && {
22818          test -z "$ac_c_werror_flag" ||
22819          test ! -s conftest.err
22820        } && test -s conftest.$ac_objext; then
22821   ac_header_compiler=yes
22822 else
22823   $as_echo "$as_me: failed program was:" >&5
22824 sed 's/^/| /' conftest.$ac_ext >&5
22825
22826         ac_header_compiler=no
22827 fi
22828
22829 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
22830 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
22831 $as_echo "$ac_header_compiler" >&6; }
22832
22833 # Is the header present?
22834 { $as_echo "$as_me:$LINENO: checking pthread.h presence" >&5
22835 $as_echo_n "checking pthread.h presence... " >&6; }
22836 cat >conftest.$ac_ext <<_ACEOF
22837 /* confdefs.h.  */
22838 _ACEOF
22839 cat confdefs.h >>conftest.$ac_ext
22840 cat >>conftest.$ac_ext <<_ACEOF
22841 /* end confdefs.h.  */
22842 #include <pthread.h>
22843 _ACEOF
22844 if { (ac_try="$ac_cpp conftest.$ac_ext"
22845 case "(($ac_try" in
22846   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22847   *) ac_try_echo=$ac_try;;
22848 esac
22849 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22850 $as_echo "$ac_try_echo") >&5
22851   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
22852   ac_status=$?
22853   grep -v '^ *+' conftest.er1 >conftest.err
22854   rm -f conftest.er1
22855   cat conftest.err >&5
22856   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22857   (exit $ac_status); } >/dev/null && {
22858          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
22859          test ! -s conftest.err
22860        }; then
22861   ac_header_preproc=yes
22862 else
22863   $as_echo "$as_me: failed program was:" >&5
22864 sed 's/^/| /' conftest.$ac_ext >&5
22865
22866   ac_header_preproc=no
22867 fi
22868
22869 rm -f conftest.err conftest.$ac_ext
22870 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
22871 $as_echo "$ac_header_preproc" >&6; }
22872
22873 # So?  What about this header?
22874 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
22875   yes:no: )
22876     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&5
22877 $as_echo "$as_me: WARNING: pthread.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
22878     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the compiler's result" >&5
22879 $as_echo "$as_me: WARNING: pthread.h: proceeding with the compiler's result" >&2;}
22880     ac_header_preproc=yes
22881     ;;
22882   no:yes:* )
22883     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: present but cannot be compiled" >&5
22884 $as_echo "$as_me: WARNING: pthread.h: present but cannot be compiled" >&2;}
22885     { $as_echo "$as_me:$LINENO: WARNING: pthread.h:     check for missing prerequisite headers?" >&5
22886 $as_echo "$as_me: WARNING: pthread.h:     check for missing prerequisite headers?" >&2;}
22887     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: see the Autoconf documentation" >&5
22888 $as_echo "$as_me: WARNING: pthread.h: see the Autoconf documentation" >&2;}
22889     { $as_echo "$as_me:$LINENO: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&5
22890 $as_echo "$as_me: WARNING: pthread.h:     section \"Present But Cannot Be Compiled\"" >&2;}
22891     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: proceeding with the preprocessor's result" >&5
22892 $as_echo "$as_me: WARNING: pthread.h: proceeding with the preprocessor's result" >&2;}
22893     { $as_echo "$as_me:$LINENO: WARNING: pthread.h: in the future, the compiler will take precedence" >&5
22894 $as_echo "$as_me: WARNING: pthread.h: in the future, the compiler will take precedence" >&2;}
22895     ( cat <<\_ASBOX
22896 ## ---------------------------------------- ##
22897 ## Report this to pgsql-bugs@postgresql.org ##
22898 ## ---------------------------------------- ##
22899 _ASBOX
22900      ) | sed "s/^/$as_me: WARNING:     /" >&2
22901     ;;
22902 esac
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 else
22908   ac_cv_header_pthread_h=$ac_header_preproc
22909 fi
22910 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_pthread_h" >&5
22911 $as_echo "$ac_cv_header_pthread_h" >&6; }
22912
22913 fi
22914 if test "x$ac_cv_header_pthread_h" = x""yes; then
22915   :
22916 else
22917   { { $as_echo "$as_me:$LINENO: error:
22918 pthread.h not found;  use --disable-thread-safety to disable thread safety" >&5
22919 $as_echo "$as_me: error:
22920 pthread.h not found;  use --disable-thread-safety to disable thread safety" >&2;}
22921    { (exit 1); exit 1; }; }
22922 fi
22923
22924
22925 fi
22926
22927
22928
22929
22930 for ac_func in strerror_r getpwuid_r gethostbyname_r
22931 do
22932 as_ac_var=`$as_echo "ac_cv_func_$ac_func" | $as_tr_sh`
22933 { $as_echo "$as_me:$LINENO: checking for $ac_func" >&5
22934 $as_echo_n "checking for $ac_func... " >&6; }
22935 if { as_var=$as_ac_var; eval "test \"\${$as_var+set}\" = set"; }; then
22936   $as_echo_n "(cached) " >&6
22937 else
22938   cat >conftest.$ac_ext <<_ACEOF
22939 /* confdefs.h.  */
22940 _ACEOF
22941 cat confdefs.h >>conftest.$ac_ext
22942 cat >>conftest.$ac_ext <<_ACEOF
22943 /* end confdefs.h.  */
22944 /* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
22945    For example, HP-UX 11i <limits.h> declares gettimeofday.  */
22946 #define $ac_func innocuous_$ac_func
22947
22948 /* System header to define __stub macros and hopefully few prototypes,
22949     which can conflict with char $ac_func (); below.
22950     Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
22951     <limits.h> exists even on freestanding compilers.  */
22952
22953 #ifdef __STDC__
22954 # include <limits.h>
22955 #else
22956 # include <assert.h>
22957 #endif
22958
22959 #undef $ac_func
22960
22961 /* Override any GCC internal prototype to avoid an error.
22962    Use char because int might match the return type of a GCC
22963    builtin and then its argument prototype would still apply.  */
22964 #ifdef __cplusplus
22965 extern "C"
22966 #endif
22967 char $ac_func ();
22968 /* The GNU C library defines this for functions which it implements
22969     to always fail with ENOSYS.  Some functions are actually named
22970     something starting with __ and the normal name is an alias.  */
22971 #if defined __stub_$ac_func || defined __stub___$ac_func
22972 choke me
22973 #endif
22974
22975 int
22976 main ()
22977 {
22978 return $ac_func ();
22979   ;
22980   return 0;
22981 }
22982 _ACEOF
22983 rm -f conftest.$ac_objext conftest$ac_exeext
22984 if { (ac_try="$ac_link"
22985 case "(($ac_try" in
22986   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
22987   *) ac_try_echo=$ac_try;;
22988 esac
22989 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
22990 $as_echo "$ac_try_echo") >&5
22991   (eval "$ac_link") 2>conftest.er1
22992   ac_status=$?
22993   grep -v '^ *+' conftest.er1 >conftest.err
22994   rm -f conftest.er1
22995   cat conftest.err >&5
22996   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
22997   (exit $ac_status); } && {
22998          test -z "$ac_c_werror_flag" ||
22999          test ! -s conftest.err
23000        } && test -s conftest$ac_exeext && {
23001          test "$cross_compiling" = yes ||
23002          $as_test_x conftest$ac_exeext
23003        }; then
23004   eval "$as_ac_var=yes"
23005 else
23006   $as_echo "$as_me: failed program was:" >&5
23007 sed 's/^/| /' conftest.$ac_ext >&5
23008
23009         eval "$as_ac_var=no"
23010 fi
23011
23012 rm -rf conftest.dSYM
23013 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23014       conftest$ac_exeext conftest.$ac_ext
23015 fi
23016 ac_res=`eval 'as_val=${'$as_ac_var'}
23017                  $as_echo "$as_val"'`
23018                { $as_echo "$as_me:$LINENO: result: $ac_res" >&5
23019 $as_echo "$ac_res" >&6; }
23020 as_val=`eval 'as_val=${'$as_ac_var'}
23021                  $as_echo "$as_val"'`
23022    if test "x$as_val" = x""yes; then
23023   cat >>confdefs.h <<_ACEOF
23024 #define `$as_echo "HAVE_$ac_func" | $as_tr_cpp` 1
23025 _ACEOF
23026
23027 fi
23028 done
23029
23030
23031 # Do test here with the proper thread flags
23032 { $as_echo "$as_me:$LINENO: checking whether getpwuid_r takes a fifth argument" >&5
23033 $as_echo_n "checking whether getpwuid_r takes a fifth argument... " >&6; }
23034 if test "${pgac_cv_func_getpwuid_r_5arg+set}" = set; then
23035   $as_echo_n "(cached) " >&6
23036 else
23037   cat >conftest.$ac_ext <<_ACEOF
23038 /* confdefs.h.  */
23039 _ACEOF
23040 cat confdefs.h >>conftest.$ac_ext
23041 cat >>conftest.$ac_ext <<_ACEOF
23042 /* end confdefs.h.  */
23043 #include <sys/types.h>
23044 #include <pwd.h>
23045 int
23046 main ()
23047 {
23048 uid_t uid;
23049 struct passwd *space;
23050 char *buf;
23051 size_t bufsize;
23052 struct passwd **result;
23053 getpwuid_r(uid, space, buf, bufsize, result);
23054   ;
23055   return 0;
23056 }
23057 _ACEOF
23058 rm -f conftest.$ac_objext
23059 if { (ac_try="$ac_compile"
23060 case "(($ac_try" in
23061   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23062   *) ac_try_echo=$ac_try;;
23063 esac
23064 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23065 $as_echo "$ac_try_echo") >&5
23066   (eval "$ac_compile") 2>conftest.er1
23067   ac_status=$?
23068   grep -v '^ *+' conftest.er1 >conftest.err
23069   rm -f conftest.er1
23070   cat conftest.err >&5
23071   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23072   (exit $ac_status); } && {
23073          test -z "$ac_c_werror_flag" ||
23074          test ! -s conftest.err
23075        } && test -s conftest.$ac_objext; then
23076   pgac_cv_func_getpwuid_r_5arg=yes
23077 else
23078   $as_echo "$as_me: failed program was:" >&5
23079 sed 's/^/| /' conftest.$ac_ext >&5
23080
23081         pgac_cv_func_getpwuid_r_5arg=no
23082 fi
23083
23084 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23085 fi
23086 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_getpwuid_r_5arg" >&5
23087 $as_echo "$pgac_cv_func_getpwuid_r_5arg" >&6; }
23088 if test x"$pgac_cv_func_getpwuid_r_5arg" = xyes ; then
23089
23090 cat >>confdefs.h <<\_ACEOF
23091 #define GETPWUID_R_5ARG /**/
23092 _ACEOF
23093
23094 fi
23095
23096 { $as_echo "$as_me:$LINENO: checking whether strerror_r returns int" >&5
23097 $as_echo_n "checking whether strerror_r returns int... " >&6; }
23098 if test "${pgac_cv_func_strerror_r_int+set}" = set; then
23099   $as_echo_n "(cached) " >&6
23100 else
23101   cat >conftest.$ac_ext <<_ACEOF
23102 /* confdefs.h.  */
23103 _ACEOF
23104 cat confdefs.h >>conftest.$ac_ext
23105 cat >>conftest.$ac_ext <<_ACEOF
23106 /* end confdefs.h.  */
23107 #include <string.h>
23108 int
23109 main ()
23110 {
23111 #ifndef _AIX
23112 int strerror_r(int, char *, size_t);
23113 #else
23114 /* Older AIX has 'int' for the third argument so we don't test the args. */
23115 int strerror_r();
23116 #endif
23117   ;
23118   return 0;
23119 }
23120 _ACEOF
23121 rm -f conftest.$ac_objext
23122 if { (ac_try="$ac_compile"
23123 case "(($ac_try" in
23124   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23125   *) ac_try_echo=$ac_try;;
23126 esac
23127 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23128 $as_echo "$ac_try_echo") >&5
23129   (eval "$ac_compile") 2>conftest.er1
23130   ac_status=$?
23131   grep -v '^ *+' conftest.er1 >conftest.err
23132   rm -f conftest.er1
23133   cat conftest.err >&5
23134   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23135   (exit $ac_status); } && {
23136          test -z "$ac_c_werror_flag" ||
23137          test ! -s conftest.err
23138        } && test -s conftest.$ac_objext; then
23139   pgac_cv_func_strerror_r_int=yes
23140 else
23141   $as_echo "$as_me: failed program was:" >&5
23142 sed 's/^/| /' conftest.$ac_ext >&5
23143
23144         pgac_cv_func_strerror_r_int=no
23145 fi
23146
23147 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23148 fi
23149 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_strerror_r_int" >&5
23150 $as_echo "$pgac_cv_func_strerror_r_int" >&6; }
23151 if test x"$pgac_cv_func_strerror_r_int" = xyes ; then
23152
23153 cat >>confdefs.h <<\_ACEOF
23154 #define STRERROR_R_INT /**/
23155 _ACEOF
23156
23157 fi
23158
23159
23160 CFLAGS="$_CFLAGS"
23161 LIBS="$_LIBS"
23162
23163 else
23164 # do not use values from template file
23165 PTHREAD_CFLAGS=
23166 PTHREAD_LIBS=
23167 fi
23168
23169
23170
23171
23172
23173 # We can test for libldap_r only after we know PTHREAD_LIBS
23174 if test "$with_ldap" = yes ; then
23175   _LIBS="$LIBS"
23176   if test "$PORTNAME" != "win32"; then
23177
23178 { $as_echo "$as_me:$LINENO: checking for ldap_bind in -lldap" >&5
23179 $as_echo_n "checking for ldap_bind in -lldap... " >&6; }
23180 if test "${ac_cv_lib_ldap_ldap_bind+set}" = set; then
23181   $as_echo_n "(cached) " >&6
23182 else
23183   ac_check_lib_save_LIBS=$LIBS
23184 LIBS="-lldap $EXTRA_LDAP_LIBS $LIBS"
23185 cat >conftest.$ac_ext <<_ACEOF
23186 /* confdefs.h.  */
23187 _ACEOF
23188 cat confdefs.h >>conftest.$ac_ext
23189 cat >>conftest.$ac_ext <<_ACEOF
23190 /* end confdefs.h.  */
23191
23192 /* Override any GCC internal prototype to avoid an error.
23193    Use char because int might match the return type of a GCC
23194    builtin and then its argument prototype would still apply.  */
23195 #ifdef __cplusplus
23196 extern "C"
23197 #endif
23198 char ldap_bind ();
23199 int
23200 main ()
23201 {
23202 return ldap_bind ();
23203   ;
23204   return 0;
23205 }
23206 _ACEOF
23207 rm -f conftest.$ac_objext conftest$ac_exeext
23208 if { (ac_try="$ac_link"
23209 case "(($ac_try" in
23210   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23211   *) ac_try_echo=$ac_try;;
23212 esac
23213 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23214 $as_echo "$ac_try_echo") >&5
23215   (eval "$ac_link") 2>conftest.er1
23216   ac_status=$?
23217   grep -v '^ *+' conftest.er1 >conftest.err
23218   rm -f conftest.er1
23219   cat conftest.err >&5
23220   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23221   (exit $ac_status); } && {
23222          test -z "$ac_c_werror_flag" ||
23223          test ! -s conftest.err
23224        } && test -s conftest$ac_exeext && {
23225          test "$cross_compiling" = yes ||
23226          $as_test_x conftest$ac_exeext
23227        }; then
23228   ac_cv_lib_ldap_ldap_bind=yes
23229 else
23230   $as_echo "$as_me: failed program was:" >&5
23231 sed 's/^/| /' conftest.$ac_ext >&5
23232
23233         ac_cv_lib_ldap_ldap_bind=no
23234 fi
23235
23236 rm -rf conftest.dSYM
23237 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23238       conftest$ac_exeext conftest.$ac_ext
23239 LIBS=$ac_check_lib_save_LIBS
23240 fi
23241 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_ldap_bind" >&5
23242 $as_echo "$ac_cv_lib_ldap_ldap_bind" >&6; }
23243 if test "x$ac_cv_lib_ldap_ldap_bind" = x""yes; then
23244   cat >>confdefs.h <<_ACEOF
23245 #define HAVE_LIBLDAP 1
23246 _ACEOF
23247
23248   LIBS="-lldap $LIBS"
23249
23250 else
23251   { { $as_echo "$as_me:$LINENO: error: library 'ldap' is required for LDAP" >&5
23252 $as_echo "$as_me: error: library 'ldap' is required for LDAP" >&2;}
23253    { (exit 1); exit 1; }; }
23254 fi
23255
23256     LDAP_LIBS_BE="-lldap $EXTRA_LDAP_LIBS"
23257     if test "$enable_thread_safety" = yes; then
23258       # on some platforms ldap_r fails to link without PTHREAD_LIBS
23259
23260 { $as_echo "$as_me:$LINENO: checking for ldap_simple_bind in -lldap_r" >&5
23261 $as_echo_n "checking for ldap_simple_bind in -lldap_r... " >&6; }
23262 if test "${ac_cv_lib_ldap_r_ldap_simple_bind+set}" = set; then
23263   $as_echo_n "(cached) " >&6
23264 else
23265   ac_check_lib_save_LIBS=$LIBS
23266 LIBS="-lldap_r $PTHREAD_CFLAGS $PTHREAD_LIBS $EXTRA_LDAP_LIBS $LIBS"
23267 cat >conftest.$ac_ext <<_ACEOF
23268 /* confdefs.h.  */
23269 _ACEOF
23270 cat confdefs.h >>conftest.$ac_ext
23271 cat >>conftest.$ac_ext <<_ACEOF
23272 /* end confdefs.h.  */
23273
23274 /* Override any GCC internal prototype to avoid an error.
23275    Use char because int might match the return type of a GCC
23276    builtin and then its argument prototype would still apply.  */
23277 #ifdef __cplusplus
23278 extern "C"
23279 #endif
23280 char ldap_simple_bind ();
23281 int
23282 main ()
23283 {
23284 return ldap_simple_bind ();
23285   ;
23286   return 0;
23287 }
23288 _ACEOF
23289 rm -f conftest.$ac_objext conftest$ac_exeext
23290 if { (ac_try="$ac_link"
23291 case "(($ac_try" in
23292   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23293   *) ac_try_echo=$ac_try;;
23294 esac
23295 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23296 $as_echo "$ac_try_echo") >&5
23297   (eval "$ac_link") 2>conftest.er1
23298   ac_status=$?
23299   grep -v '^ *+' conftest.er1 >conftest.err
23300   rm -f conftest.er1
23301   cat conftest.err >&5
23302   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23303   (exit $ac_status); } && {
23304          test -z "$ac_c_werror_flag" ||
23305          test ! -s conftest.err
23306        } && test -s conftest$ac_exeext && {
23307          test "$cross_compiling" = yes ||
23308          $as_test_x conftest$ac_exeext
23309        }; then
23310   ac_cv_lib_ldap_r_ldap_simple_bind=yes
23311 else
23312   $as_echo "$as_me: failed program was:" >&5
23313 sed 's/^/| /' conftest.$ac_ext >&5
23314
23315         ac_cv_lib_ldap_r_ldap_simple_bind=no
23316 fi
23317
23318 rm -rf conftest.dSYM
23319 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23320       conftest$ac_exeext conftest.$ac_ext
23321 LIBS=$ac_check_lib_save_LIBS
23322 fi
23323 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_ldap_r_ldap_simple_bind" >&5
23324 $as_echo "$ac_cv_lib_ldap_r_ldap_simple_bind" >&6; }
23325 if test "x$ac_cv_lib_ldap_r_ldap_simple_bind" = x""yes; then
23326   cat >>confdefs.h <<_ACEOF
23327 #define HAVE_LIBLDAP_R 1
23328 _ACEOF
23329
23330   LIBS="-lldap_r $LIBS"
23331
23332 else
23333   { { $as_echo "$as_me:$LINENO: error: library 'ldap_r' is required for LDAP" >&5
23334 $as_echo "$as_me: error: library 'ldap_r' is required for LDAP" >&2;}
23335    { (exit 1); exit 1; }; }
23336 fi
23337
23338       LDAP_LIBS_FE="-lldap_r $EXTRA_LDAP_LIBS"
23339     else
23340       LDAP_LIBS_FE="-lldap $EXTRA_LDAP_LIBS"
23341     fi
23342   else
23343
23344 { $as_echo "$as_me:$LINENO: checking for ldap_bind in -lwldap32" >&5
23345 $as_echo_n "checking for ldap_bind in -lwldap32... " >&6; }
23346 if test "${ac_cv_lib_wldap32_ldap_bind+set}" = set; then
23347   $as_echo_n "(cached) " >&6
23348 else
23349   ac_check_lib_save_LIBS=$LIBS
23350 LIBS="-lwldap32  $LIBS"
23351 cat >conftest.$ac_ext <<_ACEOF
23352 /* confdefs.h.  */
23353 _ACEOF
23354 cat confdefs.h >>conftest.$ac_ext
23355 cat >>conftest.$ac_ext <<_ACEOF
23356 /* end confdefs.h.  */
23357
23358 /* Override any GCC internal prototype to avoid an error.
23359    Use char because int might match the return type of a GCC
23360    builtin and then its argument prototype would still apply.  */
23361 #ifdef __cplusplus
23362 extern "C"
23363 #endif
23364 char ldap_bind ();
23365 int
23366 main ()
23367 {
23368 return ldap_bind ();
23369   ;
23370   return 0;
23371 }
23372 _ACEOF
23373 rm -f conftest.$ac_objext conftest$ac_exeext
23374 if { (ac_try="$ac_link"
23375 case "(($ac_try" in
23376   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23377   *) ac_try_echo=$ac_try;;
23378 esac
23379 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23380 $as_echo "$ac_try_echo") >&5
23381   (eval "$ac_link") 2>conftest.er1
23382   ac_status=$?
23383   grep -v '^ *+' conftest.er1 >conftest.err
23384   rm -f conftest.er1
23385   cat conftest.err >&5
23386   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23387   (exit $ac_status); } && {
23388          test -z "$ac_c_werror_flag" ||
23389          test ! -s conftest.err
23390        } && test -s conftest$ac_exeext && {
23391          test "$cross_compiling" = yes ||
23392          $as_test_x conftest$ac_exeext
23393        }; then
23394   ac_cv_lib_wldap32_ldap_bind=yes
23395 else
23396   $as_echo "$as_me: failed program was:" >&5
23397 sed 's/^/| /' conftest.$ac_ext >&5
23398
23399         ac_cv_lib_wldap32_ldap_bind=no
23400 fi
23401
23402 rm -rf conftest.dSYM
23403 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
23404       conftest$ac_exeext conftest.$ac_ext
23405 LIBS=$ac_check_lib_save_LIBS
23406 fi
23407 { $as_echo "$as_me:$LINENO: result: $ac_cv_lib_wldap32_ldap_bind" >&5
23408 $as_echo "$ac_cv_lib_wldap32_ldap_bind" >&6; }
23409 if test "x$ac_cv_lib_wldap32_ldap_bind" = x""yes; then
23410   cat >>confdefs.h <<_ACEOF
23411 #define HAVE_LIBWLDAP32 1
23412 _ACEOF
23413
23414   LIBS="-lwldap32 $LIBS"
23415
23416 else
23417   { { $as_echo "$as_me:$LINENO: error: library 'wldap32' is required for LDAP" >&5
23418 $as_echo "$as_me: error: library 'wldap32' is required for LDAP" >&2;}
23419    { (exit 1); exit 1; }; }
23420 fi
23421
23422     LDAP_LIBS_FE="-lwldap32"
23423     LDAP_LIBS_BE="-lwldap32"
23424   fi
23425   LIBS="$_LIBS"
23426 fi
23427
23428
23429
23430
23431 # This test makes sure that run tests work at all.  Sometimes a shared
23432 # library is found by the linker, but the runtime linker can't find it.
23433 # This check should come after all modifications of compiler or linker
23434 # variables, and before any other run tests.
23435 { $as_echo "$as_me:$LINENO: checking test program" >&5
23436 $as_echo_n "checking test program... " >&6; }
23437 if test "$cross_compiling" = yes; then
23438   { $as_echo "$as_me:$LINENO: result: cross-compiling" >&5
23439 $as_echo "cross-compiling" >&6; }
23440 else
23441   cat >conftest.$ac_ext <<_ACEOF
23442 /* confdefs.h.  */
23443 _ACEOF
23444 cat confdefs.h >>conftest.$ac_ext
23445 cat >>conftest.$ac_ext <<_ACEOF
23446 /* end confdefs.h.  */
23447 int main() { return 0; }
23448 _ACEOF
23449 rm -f conftest$ac_exeext
23450 if { (ac_try="$ac_link"
23451 case "(($ac_try" in
23452   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23453   *) ac_try_echo=$ac_try;;
23454 esac
23455 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23456 $as_echo "$ac_try_echo") >&5
23457   (eval "$ac_link") 2>&5
23458   ac_status=$?
23459   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23460   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23461   { (case "(($ac_try" in
23462   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23463   *) ac_try_echo=$ac_try;;
23464 esac
23465 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23466 $as_echo "$ac_try_echo") >&5
23467   (eval "$ac_try") 2>&5
23468   ac_status=$?
23469   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23470   (exit $ac_status); }; }; then
23471   { $as_echo "$as_me:$LINENO: result: ok" >&5
23472 $as_echo "ok" >&6; }
23473 else
23474   $as_echo "$as_me: program exited with status $ac_status" >&5
23475 $as_echo "$as_me: failed program was:" >&5
23476 sed 's/^/| /' conftest.$ac_ext >&5
23477
23478 ( exit $ac_status )
23479 { $as_echo "$as_me:$LINENO: result: failed" >&5
23480 $as_echo "failed" >&6; }
23481 { { $as_echo "$as_me:$LINENO: error:
23482 Could not execute a simple test program.  This may be a problem
23483 related to locating shared libraries.  Check the file 'config.log'
23484 for the exact reason." >&5
23485 $as_echo "$as_me: error:
23486 Could not execute a simple test program.  This may be a problem
23487 related to locating shared libraries.  Check the file 'config.log'
23488 for the exact reason." >&2;}
23489    { (exit 1); exit 1; }; }
23490 fi
23491 rm -rf conftest.dSYM
23492 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23493 fi
23494
23495
23496
23497 # --------------------
23498 # Run tests below here
23499 # --------------------
23500
23501 # Force use of our snprintf if system's doesn't do arg control
23502 # See comment above at snprintf test for details.
23503 if test "$enable_nls" = yes -a "$pgac_need_repl_snprintf" = no; then
23504   { $as_echo "$as_me:$LINENO: checking whether printf supports argument control" >&5
23505 $as_echo_n "checking whether printf supports argument control... " >&6; }
23506 if test "${pgac_cv_printf_arg_control+set}" = set; then
23507   $as_echo_n "(cached) " >&6
23508 else
23509   if test "$cross_compiling" = yes; then
23510   pgac_cv_printf_arg_control=cross
23511 else
23512   cat >conftest.$ac_ext <<_ACEOF
23513 /* confdefs.h.  */
23514 _ACEOF
23515 cat confdefs.h >>conftest.$ac_ext
23516 cat >>conftest.$ac_ext <<_ACEOF
23517 /* end confdefs.h.  */
23518 #include <stdio.h>
23519 #include <string.h>
23520
23521 int main()
23522 {
23523   char buf[100];
23524
23525   /* can it swap arguments? */
23526   snprintf(buf, 100, "%2\$d %1\$d", 3, 4);
23527   if (strcmp(buf, "4 3") != 0)
23528     return 1;
23529   return 0;
23530 }
23531 _ACEOF
23532 rm -f conftest$ac_exeext
23533 if { (ac_try="$ac_link"
23534 case "(($ac_try" in
23535   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23536   *) ac_try_echo=$ac_try;;
23537 esac
23538 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23539 $as_echo "$ac_try_echo") >&5
23540   (eval "$ac_link") 2>&5
23541   ac_status=$?
23542   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23543   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23544   { (case "(($ac_try" in
23545   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23546   *) ac_try_echo=$ac_try;;
23547 esac
23548 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23549 $as_echo "$ac_try_echo") >&5
23550   (eval "$ac_try") 2>&5
23551   ac_status=$?
23552   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23553   (exit $ac_status); }; }; then
23554   pgac_cv_printf_arg_control=yes
23555 else
23556   $as_echo "$as_me: program exited with status $ac_status" >&5
23557 $as_echo "$as_me: failed program was:" >&5
23558 sed 's/^/| /' conftest.$ac_ext >&5
23559
23560 ( exit $ac_status )
23561 pgac_cv_printf_arg_control=no
23562 fi
23563 rm -rf conftest.dSYM
23564 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23565 fi
23566
23567
23568
23569 fi
23570 { $as_echo "$as_me:$LINENO: result: $pgac_cv_printf_arg_control" >&5
23571 $as_echo "$pgac_cv_printf_arg_control" >&6; }
23572
23573   if test $pgac_cv_printf_arg_control != yes ; then
23574     pgac_need_repl_snprintf=yes
23575   fi
23576 fi
23577
23578
23579
23580
23581 { $as_echo "$as_me:$LINENO: checking whether long int is 64 bits" >&5
23582 $as_echo_n "checking whether long int is 64 bits... " >&6; }
23583 if test "${pgac_cv_type_long_int_64+set}" = set; then
23584   $as_echo_n "(cached) " >&6
23585 else
23586   if test "$cross_compiling" = yes; then
23587   # If cross-compiling, check the size reported by the compiler and
23588 # trust that the arithmetic works.
23589 cat >conftest.$ac_ext <<_ACEOF
23590 /* confdefs.h.  */
23591 _ACEOF
23592 cat confdefs.h >>conftest.$ac_ext
23593 cat >>conftest.$ac_ext <<_ACEOF
23594 /* end confdefs.h.  */
23595
23596 int
23597 main ()
23598 {
23599 static int test_array [1 - 2 * !(sizeof(long int) == 8)];
23600 test_array [0] = 0
23601
23602   ;
23603   return 0;
23604 }
23605 _ACEOF
23606 rm -f conftest.$ac_objext
23607 if { (ac_try="$ac_compile"
23608 case "(($ac_try" in
23609   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23610   *) ac_try_echo=$ac_try;;
23611 esac
23612 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23613 $as_echo "$ac_try_echo") >&5
23614   (eval "$ac_compile") 2>conftest.er1
23615   ac_status=$?
23616   grep -v '^ *+' conftest.er1 >conftest.err
23617   rm -f conftest.er1
23618   cat conftest.err >&5
23619   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23620   (exit $ac_status); } && {
23621          test -z "$ac_c_werror_flag" ||
23622          test ! -s conftest.err
23623        } && test -s conftest.$ac_objext; then
23624   pgac_cv_type_long_int_64=yes
23625 else
23626   $as_echo "$as_me: failed program was:" >&5
23627 sed 's/^/| /' conftest.$ac_ext >&5
23628
23629         pgac_cv_type_long_int_64=no
23630 fi
23631
23632 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23633 else
23634   cat >conftest.$ac_ext <<_ACEOF
23635 /* confdefs.h.  */
23636 _ACEOF
23637 cat confdefs.h >>conftest.$ac_ext
23638 cat >>conftest.$ac_ext <<_ACEOF
23639 /* end confdefs.h.  */
23640 typedef long int ac_int64;
23641
23642 /*
23643  * These are globals to discourage the compiler from folding all the
23644  * arithmetic tests down to compile-time constants.
23645  */
23646 ac_int64 a = 20000001;
23647 ac_int64 b = 40000005;
23648
23649 int does_int64_work()
23650 {
23651   ac_int64 c,d;
23652
23653   if (sizeof(ac_int64) != 8)
23654     return 0;                   /* definitely not the right size */
23655
23656   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
23657   c = a * b;
23658   d = (c + b) / b;
23659   if (d != a+1)
23660     return 0;
23661   return 1;
23662 }
23663 main() {
23664   exit(! does_int64_work());
23665 }
23666 _ACEOF
23667 rm -f conftest$ac_exeext
23668 if { (ac_try="$ac_link"
23669 case "(($ac_try" in
23670   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23671   *) ac_try_echo=$ac_try;;
23672 esac
23673 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23674 $as_echo "$ac_try_echo") >&5
23675   (eval "$ac_link") 2>&5
23676   ac_status=$?
23677   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23678   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23679   { (case "(($ac_try" in
23680   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23681   *) ac_try_echo=$ac_try;;
23682 esac
23683 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23684 $as_echo "$ac_try_echo") >&5
23685   (eval "$ac_try") 2>&5
23686   ac_status=$?
23687   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23688   (exit $ac_status); }; }; then
23689   pgac_cv_type_long_int_64=yes
23690 else
23691   $as_echo "$as_me: program exited with status $ac_status" >&5
23692 $as_echo "$as_me: failed program was:" >&5
23693 sed 's/^/| /' conftest.$ac_ext >&5
23694
23695 ( exit $ac_status )
23696 pgac_cv_type_long_int_64=no
23697 fi
23698 rm -rf conftest.dSYM
23699 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23700 fi
23701
23702
23703 fi
23704 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_long_int_64" >&5
23705 $as_echo "$pgac_cv_type_long_int_64" >&6; }
23706
23707 HAVE_LONG_INT_64=$pgac_cv_type_long_int_64
23708 if test x"$pgac_cv_type_long_int_64" = xyes ; then
23709
23710 cat >>confdefs.h <<\_ACEOF
23711 #define HAVE_LONG_INT_64 1
23712 _ACEOF
23713
23714 fi
23715
23716
23717 if test x"$HAVE_LONG_INT_64" = x"no" ; then
23718   { $as_echo "$as_me:$LINENO: checking whether long long int is 64 bits" >&5
23719 $as_echo_n "checking whether long long int is 64 bits... " >&6; }
23720 if test "${pgac_cv_type_long_long_int_64+set}" = set; then
23721   $as_echo_n "(cached) " >&6
23722 else
23723   if test "$cross_compiling" = yes; then
23724   # If cross-compiling, check the size reported by the compiler and
23725 # trust that the arithmetic works.
23726 cat >conftest.$ac_ext <<_ACEOF
23727 /* confdefs.h.  */
23728 _ACEOF
23729 cat confdefs.h >>conftest.$ac_ext
23730 cat >>conftest.$ac_ext <<_ACEOF
23731 /* end confdefs.h.  */
23732
23733 int
23734 main ()
23735 {
23736 static int test_array [1 - 2 * !(sizeof(long long int) == 8)];
23737 test_array [0] = 0
23738
23739   ;
23740   return 0;
23741 }
23742 _ACEOF
23743 rm -f conftest.$ac_objext
23744 if { (ac_try="$ac_compile"
23745 case "(($ac_try" in
23746   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23747   *) ac_try_echo=$ac_try;;
23748 esac
23749 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23750 $as_echo "$ac_try_echo") >&5
23751   (eval "$ac_compile") 2>conftest.er1
23752   ac_status=$?
23753   grep -v '^ *+' conftest.er1 >conftest.err
23754   rm -f conftest.er1
23755   cat conftest.err >&5
23756   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23757   (exit $ac_status); } && {
23758          test -z "$ac_c_werror_flag" ||
23759          test ! -s conftest.err
23760        } && test -s conftest.$ac_objext; then
23761   pgac_cv_type_long_long_int_64=yes
23762 else
23763   $as_echo "$as_me: failed program was:" >&5
23764 sed 's/^/| /' conftest.$ac_ext >&5
23765
23766         pgac_cv_type_long_long_int_64=no
23767 fi
23768
23769 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23770 else
23771   cat >conftest.$ac_ext <<_ACEOF
23772 /* confdefs.h.  */
23773 _ACEOF
23774 cat confdefs.h >>conftest.$ac_ext
23775 cat >>conftest.$ac_ext <<_ACEOF
23776 /* end confdefs.h.  */
23777 typedef long long int ac_int64;
23778
23779 /*
23780  * These are globals to discourage the compiler from folding all the
23781  * arithmetic tests down to compile-time constants.
23782  */
23783 ac_int64 a = 20000001;
23784 ac_int64 b = 40000005;
23785
23786 int does_int64_work()
23787 {
23788   ac_int64 c,d;
23789
23790   if (sizeof(ac_int64) != 8)
23791     return 0;                   /* definitely not the right size */
23792
23793   /* Do perfunctory checks to see if 64-bit arithmetic seems to work */
23794   c = a * b;
23795   d = (c + b) / b;
23796   if (d != a+1)
23797     return 0;
23798   return 1;
23799 }
23800 main() {
23801   exit(! does_int64_work());
23802 }
23803 _ACEOF
23804 rm -f conftest$ac_exeext
23805 if { (ac_try="$ac_link"
23806 case "(($ac_try" in
23807   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23808   *) ac_try_echo=$ac_try;;
23809 esac
23810 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23811 $as_echo "$ac_try_echo") >&5
23812   (eval "$ac_link") 2>&5
23813   ac_status=$?
23814   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23815   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23816   { (case "(($ac_try" in
23817   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23818   *) ac_try_echo=$ac_try;;
23819 esac
23820 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23821 $as_echo "$ac_try_echo") >&5
23822   (eval "$ac_try") 2>&5
23823   ac_status=$?
23824   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23825   (exit $ac_status); }; }; then
23826   pgac_cv_type_long_long_int_64=yes
23827 else
23828   $as_echo "$as_me: program exited with status $ac_status" >&5
23829 $as_echo "$as_me: failed program was:" >&5
23830 sed 's/^/| /' conftest.$ac_ext >&5
23831
23832 ( exit $ac_status )
23833 pgac_cv_type_long_long_int_64=no
23834 fi
23835 rm -rf conftest.dSYM
23836 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23837 fi
23838
23839
23840 fi
23841 { $as_echo "$as_me:$LINENO: result: $pgac_cv_type_long_long_int_64" >&5
23842 $as_echo "$pgac_cv_type_long_long_int_64" >&6; }
23843
23844 HAVE_LONG_LONG_INT_64=$pgac_cv_type_long_long_int_64
23845 if test x"$pgac_cv_type_long_long_int_64" = xyes ; then
23846
23847 cat >>confdefs.h <<\_ACEOF
23848 #define HAVE_LONG_LONG_INT_64 1
23849 _ACEOF
23850
23851 fi
23852
23853   if test x"$HAVE_LONG_LONG_INT_64" = x"no" ; then
23854     { { $as_echo "$as_me:$LINENO: error: Cannot find a working 64-bit integer type." >&5
23855 $as_echo "$as_me: error: Cannot find a working 64-bit integer type." >&2;}
23856    { (exit 1); exit 1; }; }
23857   fi
23858 fi
23859
23860
23861
23862 if test x"$HAVE_LONG_LONG_INT_64" = xyes ; then
23863   cat >conftest.$ac_ext <<_ACEOF
23864 /* confdefs.h.  */
23865 _ACEOF
23866 cat confdefs.h >>conftest.$ac_ext
23867 cat >>conftest.$ac_ext <<_ACEOF
23868 /* end confdefs.h.  */
23869
23870 #define INT64CONST(x)  x##LL
23871 long long int foo = INT64CONST(0x1234567890123456);
23872
23873 int
23874 main ()
23875 {
23876
23877   ;
23878   return 0;
23879 }
23880 _ACEOF
23881 rm -f conftest.$ac_objext
23882 if { (ac_try="$ac_compile"
23883 case "(($ac_try" in
23884   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23885   *) ac_try_echo=$ac_try;;
23886 esac
23887 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23888 $as_echo "$ac_try_echo") >&5
23889   (eval "$ac_compile") 2>conftest.er1
23890   ac_status=$?
23891   grep -v '^ *+' conftest.er1 >conftest.err
23892   rm -f conftest.er1
23893   cat conftest.err >&5
23894   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23895   (exit $ac_status); } && {
23896          test -z "$ac_c_werror_flag" ||
23897          test ! -s conftest.err
23898        } && test -s conftest.$ac_objext; then
23899
23900 cat >>confdefs.h <<\_ACEOF
23901 #define HAVE_LL_CONSTANTS 1
23902 _ACEOF
23903
23904 else
23905   $as_echo "$as_me: failed program was:" >&5
23906 sed 's/^/| /' conftest.$ac_ext >&5
23907
23908
23909 fi
23910
23911 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
23912 fi
23913
23914
23915 # If we found "long int" is 64 bits, assume snprintf handles it.  If
23916 # we found we need to use "long long int", better check.  We cope with
23917 # snprintfs that use %lld, %qd, or %I64d as the format.  If none of these
23918 # work, fall back to our own snprintf emulation (which we know uses %lld).
23919
23920 if test "$HAVE_LONG_LONG_INT_64" = yes ; then
23921   if test $pgac_need_repl_snprintf = no; then
23922     { $as_echo "$as_me:$LINENO: checking snprintf format for long long int" >&5
23923 $as_echo_n "checking snprintf format for long long int... " >&6; }
23924 if test "${pgac_cv_snprintf_long_long_int_format+set}" = set; then
23925   $as_echo_n "(cached) " >&6
23926 else
23927   for pgac_format in '%lld' '%qd' '%I64d'; do
23928 if test "$cross_compiling" = yes; then
23929   pgac_cv_snprintf_long_long_int_format=cross; break
23930 else
23931   cat >conftest.$ac_ext <<_ACEOF
23932 /* confdefs.h.  */
23933 _ACEOF
23934 cat confdefs.h >>conftest.$ac_ext
23935 cat >>conftest.$ac_ext <<_ACEOF
23936 /* end confdefs.h.  */
23937 #include <stdio.h>
23938 typedef long long int ac_int64;
23939 #define INT64_FORMAT "$pgac_format"
23940
23941 ac_int64 a = 20000001;
23942 ac_int64 b = 40000005;
23943
23944 int does_int64_snprintf_work()
23945 {
23946   ac_int64 c;
23947   char buf[100];
23948
23949   if (sizeof(ac_int64) != 8)
23950     return 0;                   /* doesn't look like the right size */
23951
23952   c = a * b;
23953   snprintf(buf, 100, INT64_FORMAT, c);
23954   if (strcmp(buf, "800000140000005") != 0)
23955     return 0;                   /* either multiply or snprintf is busted */
23956   return 1;
23957 }
23958 main() {
23959   exit(! does_int64_snprintf_work());
23960 }
23961 _ACEOF
23962 rm -f conftest$ac_exeext
23963 if { (ac_try="$ac_link"
23964 case "(($ac_try" in
23965   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23966   *) ac_try_echo=$ac_try;;
23967 esac
23968 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23969 $as_echo "$ac_try_echo") >&5
23970   (eval "$ac_link") 2>&5
23971   ac_status=$?
23972   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23973   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
23974   { (case "(($ac_try" in
23975   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
23976   *) ac_try_echo=$ac_try;;
23977 esac
23978 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
23979 $as_echo "$ac_try_echo") >&5
23980   (eval "$ac_try") 2>&5
23981   ac_status=$?
23982   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
23983   (exit $ac_status); }; }; then
23984   pgac_cv_snprintf_long_long_int_format=$pgac_format; break
23985 else
23986   $as_echo "$as_me: program exited with status $ac_status" >&5
23987 $as_echo "$as_me: failed program was:" >&5
23988 sed 's/^/| /' conftest.$ac_ext >&5
23989
23990 fi
23991 rm -rf conftest.dSYM
23992 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
23993 fi
23994
23995
23996 done
23997 fi
23998
23999 LONG_LONG_INT_FORMAT=''
24000
24001 case $pgac_cv_snprintf_long_long_int_format in
24002   cross) { $as_echo "$as_me:$LINENO: result: cannot test (not on host machine)" >&5
24003 $as_echo "cannot test (not on host machine)" >&6; };;
24004   ?*)    { $as_echo "$as_me:$LINENO: result: $pgac_cv_snprintf_long_long_int_format" >&5
24005 $as_echo "$pgac_cv_snprintf_long_long_int_format" >&6; }
24006          LONG_LONG_INT_FORMAT=$pgac_cv_snprintf_long_long_int_format;;
24007   *)     { $as_echo "$as_me:$LINENO: result: none" >&5
24008 $as_echo "none" >&6; };;
24009 esac
24010     if test "$LONG_LONG_INT_FORMAT" = ""; then
24011       # Force usage of our own snprintf, since system snprintf is broken
24012       pgac_need_repl_snprintf=yes
24013       LONG_LONG_INT_FORMAT='%lld'
24014     fi
24015   else
24016     # Here if we previously decided we needed to use our own snprintf
24017     LONG_LONG_INT_FORMAT='%lld'
24018   fi
24019   LONG_LONG_UINT_FORMAT=`echo "$LONG_LONG_INT_FORMAT" | sed 's/d$/u/'`
24020   INT64_FORMAT="\"$LONG_LONG_INT_FORMAT\""
24021   UINT64_FORMAT="\"$LONG_LONG_UINT_FORMAT\""
24022 else
24023   # Here if we are not using 'long long int' at all
24024   INT64_FORMAT='"%ld"'
24025   UINT64_FORMAT='"%lu"'
24026 fi
24027
24028
24029 cat >>confdefs.h <<_ACEOF
24030 #define INT64_FORMAT $INT64_FORMAT
24031 _ACEOF
24032
24033
24034
24035 cat >>confdefs.h <<_ACEOF
24036 #define UINT64_FORMAT $UINT64_FORMAT
24037 _ACEOF
24038
24039
24040 # Now we have checked all the reasons to replace snprintf
24041 if test $pgac_need_repl_snprintf = yes; then
24042
24043 cat >>confdefs.h <<\_ACEOF
24044 #define USE_REPL_SNPRINTF 1
24045 _ACEOF
24046
24047   case " $LIBOBJS " in
24048   *" snprintf.$ac_objext "* ) ;;
24049   *) LIBOBJS="$LIBOBJS snprintf.$ac_objext"
24050  ;;
24051 esac
24052
24053 fi
24054
24055 # Check size of void *, size_t (enables tweaks for > 32bit address space)
24056 # The cast to long int works around a bug in the HP C Compiler
24057 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24058 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24059 # This bug is HP SR number 8606223364.
24060 { $as_echo "$as_me:$LINENO: checking size of void *" >&5
24061 $as_echo_n "checking size of void *... " >&6; }
24062 if test "${ac_cv_sizeof_void_p+set}" = set; then
24063   $as_echo_n "(cached) " >&6
24064 else
24065   if test "$cross_compiling" = yes; then
24066   # Depending upon the size, compute the lo and hi bounds.
24067 cat >conftest.$ac_ext <<_ACEOF
24068 /* confdefs.h.  */
24069 _ACEOF
24070 cat confdefs.h >>conftest.$ac_ext
24071 cat >>conftest.$ac_ext <<_ACEOF
24072 /* end confdefs.h.  */
24073 $ac_includes_default
24074 int
24075 main ()
24076 {
24077 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= 0)];
24078 test_array [0] = 0
24079
24080   ;
24081   return 0;
24082 }
24083 _ACEOF
24084 rm -f conftest.$ac_objext
24085 if { (ac_try="$ac_compile"
24086 case "(($ac_try" in
24087   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24088   *) ac_try_echo=$ac_try;;
24089 esac
24090 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24091 $as_echo "$ac_try_echo") >&5
24092   (eval "$ac_compile") 2>conftest.er1
24093   ac_status=$?
24094   grep -v '^ *+' conftest.er1 >conftest.err
24095   rm -f conftest.er1
24096   cat conftest.err >&5
24097   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24098   (exit $ac_status); } && {
24099          test -z "$ac_c_werror_flag" ||
24100          test ! -s conftest.err
24101        } && test -s conftest.$ac_objext; then
24102   ac_lo=0 ac_mid=0
24103   while :; do
24104     cat >conftest.$ac_ext <<_ACEOF
24105 /* confdefs.h.  */
24106 _ACEOF
24107 cat confdefs.h >>conftest.$ac_ext
24108 cat >>conftest.$ac_ext <<_ACEOF
24109 /* end confdefs.h.  */
24110 $ac_includes_default
24111 int
24112 main ()
24113 {
24114 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
24115 test_array [0] = 0
24116
24117   ;
24118   return 0;
24119 }
24120 _ACEOF
24121 rm -f conftest.$ac_objext
24122 if { (ac_try="$ac_compile"
24123 case "(($ac_try" in
24124   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24125   *) ac_try_echo=$ac_try;;
24126 esac
24127 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24128 $as_echo "$ac_try_echo") >&5
24129   (eval "$ac_compile") 2>conftest.er1
24130   ac_status=$?
24131   grep -v '^ *+' conftest.er1 >conftest.err
24132   rm -f conftest.er1
24133   cat conftest.err >&5
24134   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24135   (exit $ac_status); } && {
24136          test -z "$ac_c_werror_flag" ||
24137          test ! -s conftest.err
24138        } && test -s conftest.$ac_objext; then
24139   ac_hi=$ac_mid; break
24140 else
24141   $as_echo "$as_me: failed program was:" >&5
24142 sed 's/^/| /' conftest.$ac_ext >&5
24143
24144         ac_lo=`expr $ac_mid + 1`
24145                         if test $ac_lo -le $ac_mid; then
24146                           ac_lo= ac_hi=
24147                           break
24148                         fi
24149                         ac_mid=`expr 2 '*' $ac_mid + 1`
24150 fi
24151
24152 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24153   done
24154 else
24155   $as_echo "$as_me: failed program was:" >&5
24156 sed 's/^/| /' conftest.$ac_ext >&5
24157
24158         cat >conftest.$ac_ext <<_ACEOF
24159 /* confdefs.h.  */
24160 _ACEOF
24161 cat confdefs.h >>conftest.$ac_ext
24162 cat >>conftest.$ac_ext <<_ACEOF
24163 /* end confdefs.h.  */
24164 $ac_includes_default
24165 int
24166 main ()
24167 {
24168 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) < 0)];
24169 test_array [0] = 0
24170
24171   ;
24172   return 0;
24173 }
24174 _ACEOF
24175 rm -f conftest.$ac_objext
24176 if { (ac_try="$ac_compile"
24177 case "(($ac_try" in
24178   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24179   *) ac_try_echo=$ac_try;;
24180 esac
24181 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24182 $as_echo "$ac_try_echo") >&5
24183   (eval "$ac_compile") 2>conftest.er1
24184   ac_status=$?
24185   grep -v '^ *+' conftest.er1 >conftest.err
24186   rm -f conftest.er1
24187   cat conftest.err >&5
24188   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24189   (exit $ac_status); } && {
24190          test -z "$ac_c_werror_flag" ||
24191          test ! -s conftest.err
24192        } && test -s conftest.$ac_objext; then
24193   ac_hi=-1 ac_mid=-1
24194   while :; do
24195     cat >conftest.$ac_ext <<_ACEOF
24196 /* confdefs.h.  */
24197 _ACEOF
24198 cat confdefs.h >>conftest.$ac_ext
24199 cat >>conftest.$ac_ext <<_ACEOF
24200 /* end confdefs.h.  */
24201 $ac_includes_default
24202 int
24203 main ()
24204 {
24205 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) >= $ac_mid)];
24206 test_array [0] = 0
24207
24208   ;
24209   return 0;
24210 }
24211 _ACEOF
24212 rm -f conftest.$ac_objext
24213 if { (ac_try="$ac_compile"
24214 case "(($ac_try" in
24215   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24216   *) ac_try_echo=$ac_try;;
24217 esac
24218 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24219 $as_echo "$ac_try_echo") >&5
24220   (eval "$ac_compile") 2>conftest.er1
24221   ac_status=$?
24222   grep -v '^ *+' conftest.er1 >conftest.err
24223   rm -f conftest.er1
24224   cat conftest.err >&5
24225   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24226   (exit $ac_status); } && {
24227          test -z "$ac_c_werror_flag" ||
24228          test ! -s conftest.err
24229        } && test -s conftest.$ac_objext; then
24230   ac_lo=$ac_mid; break
24231 else
24232   $as_echo "$as_me: failed program was:" >&5
24233 sed 's/^/| /' conftest.$ac_ext >&5
24234
24235         ac_hi=`expr '(' $ac_mid ')' - 1`
24236                         if test $ac_mid -le $ac_hi; then
24237                           ac_lo= ac_hi=
24238                           break
24239                         fi
24240                         ac_mid=`expr 2 '*' $ac_mid`
24241 fi
24242
24243 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24244   done
24245 else
24246   $as_echo "$as_me: failed program was:" >&5
24247 sed 's/^/| /' conftest.$ac_ext >&5
24248
24249         ac_lo= ac_hi=
24250 fi
24251
24252 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24253 fi
24254
24255 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24256 # Binary search between lo and hi bounds.
24257 while test "x$ac_lo" != "x$ac_hi"; do
24258   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24259   cat >conftest.$ac_ext <<_ACEOF
24260 /* confdefs.h.  */
24261 _ACEOF
24262 cat confdefs.h >>conftest.$ac_ext
24263 cat >>conftest.$ac_ext <<_ACEOF
24264 /* end confdefs.h.  */
24265 $ac_includes_default
24266 int
24267 main ()
24268 {
24269 static int test_array [1 - 2 * !(((long int) (sizeof (void *))) <= $ac_mid)];
24270 test_array [0] = 0
24271
24272   ;
24273   return 0;
24274 }
24275 _ACEOF
24276 rm -f conftest.$ac_objext
24277 if { (ac_try="$ac_compile"
24278 case "(($ac_try" in
24279   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24280   *) ac_try_echo=$ac_try;;
24281 esac
24282 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24283 $as_echo "$ac_try_echo") >&5
24284   (eval "$ac_compile") 2>conftest.er1
24285   ac_status=$?
24286   grep -v '^ *+' conftest.er1 >conftest.err
24287   rm -f conftest.er1
24288   cat conftest.err >&5
24289   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24290   (exit $ac_status); } && {
24291          test -z "$ac_c_werror_flag" ||
24292          test ! -s conftest.err
24293        } && test -s conftest.$ac_objext; then
24294   ac_hi=$ac_mid
24295 else
24296   $as_echo "$as_me: failed program was:" >&5
24297 sed 's/^/| /' conftest.$ac_ext >&5
24298
24299         ac_lo=`expr '(' $ac_mid ')' + 1`
24300 fi
24301
24302 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24303 done
24304 case $ac_lo in
24305 ?*) ac_cv_sizeof_void_p=$ac_lo;;
24306 '') if test "$ac_cv_type_void_p" = yes; then
24307      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24308 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24309 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
24310 See \`config.log' for more details." >&5
24311 $as_echo "$as_me: error: cannot compute sizeof (void *)
24312 See \`config.log' for more details." >&2;}
24313    { (exit 77); exit 77; }; }; }
24314    else
24315      ac_cv_sizeof_void_p=0
24316    fi ;;
24317 esac
24318 else
24319   cat >conftest.$ac_ext <<_ACEOF
24320 /* confdefs.h.  */
24321 _ACEOF
24322 cat confdefs.h >>conftest.$ac_ext
24323 cat >>conftest.$ac_ext <<_ACEOF
24324 /* end confdefs.h.  */
24325 $ac_includes_default
24326 static long int longval () { return (long int) (sizeof (void *)); }
24327 static unsigned long int ulongval () { return (long int) (sizeof (void *)); }
24328 #include <stdio.h>
24329 #include <stdlib.h>
24330 int
24331 main ()
24332 {
24333
24334   FILE *f = fopen ("conftest.val", "w");
24335   if (! f)
24336     return 1;
24337   if (((long int) (sizeof (void *))) < 0)
24338     {
24339       long int i = longval ();
24340       if (i != ((long int) (sizeof (void *))))
24341         return 1;
24342       fprintf (f, "%ld", i);
24343     }
24344   else
24345     {
24346       unsigned long int i = ulongval ();
24347       if (i != ((long int) (sizeof (void *))))
24348         return 1;
24349       fprintf (f, "%lu", i);
24350     }
24351   /* Do not output a trailing newline, as this causes \r\n confusion
24352      on some platforms.  */
24353   return ferror (f) || fclose (f) != 0;
24354
24355   ;
24356   return 0;
24357 }
24358 _ACEOF
24359 rm -f conftest$ac_exeext
24360 if { (ac_try="$ac_link"
24361 case "(($ac_try" in
24362   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24363   *) ac_try_echo=$ac_try;;
24364 esac
24365 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24366 $as_echo "$ac_try_echo") >&5
24367   (eval "$ac_link") 2>&5
24368   ac_status=$?
24369   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24370   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24371   { (case "(($ac_try" in
24372   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24373   *) ac_try_echo=$ac_try;;
24374 esac
24375 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24376 $as_echo "$ac_try_echo") >&5
24377   (eval "$ac_try") 2>&5
24378   ac_status=$?
24379   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24380   (exit $ac_status); }; }; then
24381   ac_cv_sizeof_void_p=`cat conftest.val`
24382 else
24383   $as_echo "$as_me: program exited with status $ac_status" >&5
24384 $as_echo "$as_me: failed program was:" >&5
24385 sed 's/^/| /' conftest.$ac_ext >&5
24386
24387 ( exit $ac_status )
24388 if test "$ac_cv_type_void_p" = yes; then
24389      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24390 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24391 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (void *)
24392 See \`config.log' for more details." >&5
24393 $as_echo "$as_me: error: cannot compute sizeof (void *)
24394 See \`config.log' for more details." >&2;}
24395    { (exit 77); exit 77; }; }; }
24396    else
24397      ac_cv_sizeof_void_p=0
24398    fi
24399 fi
24400 rm -rf conftest.dSYM
24401 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24402 fi
24403 rm -f conftest.val
24404 fi
24405 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_void_p" >&5
24406 $as_echo "$ac_cv_sizeof_void_p" >&6; }
24407
24408
24409
24410 cat >>confdefs.h <<_ACEOF
24411 #define SIZEOF_VOID_P $ac_cv_sizeof_void_p
24412 _ACEOF
24413
24414
24415 # The cast to long int works around a bug in the HP C Compiler
24416 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24417 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24418 # This bug is HP SR number 8606223364.
24419 { $as_echo "$as_me:$LINENO: checking size of size_t" >&5
24420 $as_echo_n "checking size of size_t... " >&6; }
24421 if test "${ac_cv_sizeof_size_t+set}" = set; then
24422   $as_echo_n "(cached) " >&6
24423 else
24424   if test "$cross_compiling" = yes; then
24425   # Depending upon the size, compute the lo and hi bounds.
24426 cat >conftest.$ac_ext <<_ACEOF
24427 /* confdefs.h.  */
24428 _ACEOF
24429 cat confdefs.h >>conftest.$ac_ext
24430 cat >>conftest.$ac_ext <<_ACEOF
24431 /* end confdefs.h.  */
24432 $ac_includes_default
24433 int
24434 main ()
24435 {
24436 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= 0)];
24437 test_array [0] = 0
24438
24439   ;
24440   return 0;
24441 }
24442 _ACEOF
24443 rm -f conftest.$ac_objext
24444 if { (ac_try="$ac_compile"
24445 case "(($ac_try" in
24446   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24447   *) ac_try_echo=$ac_try;;
24448 esac
24449 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24450 $as_echo "$ac_try_echo") >&5
24451   (eval "$ac_compile") 2>conftest.er1
24452   ac_status=$?
24453   grep -v '^ *+' conftest.er1 >conftest.err
24454   rm -f conftest.er1
24455   cat conftest.err >&5
24456   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24457   (exit $ac_status); } && {
24458          test -z "$ac_c_werror_flag" ||
24459          test ! -s conftest.err
24460        } && test -s conftest.$ac_objext; then
24461   ac_lo=0 ac_mid=0
24462   while :; do
24463     cat >conftest.$ac_ext <<_ACEOF
24464 /* confdefs.h.  */
24465 _ACEOF
24466 cat confdefs.h >>conftest.$ac_ext
24467 cat >>conftest.$ac_ext <<_ACEOF
24468 /* end confdefs.h.  */
24469 $ac_includes_default
24470 int
24471 main ()
24472 {
24473 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
24474 test_array [0] = 0
24475
24476   ;
24477   return 0;
24478 }
24479 _ACEOF
24480 rm -f conftest.$ac_objext
24481 if { (ac_try="$ac_compile"
24482 case "(($ac_try" in
24483   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24484   *) ac_try_echo=$ac_try;;
24485 esac
24486 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24487 $as_echo "$ac_try_echo") >&5
24488   (eval "$ac_compile") 2>conftest.er1
24489   ac_status=$?
24490   grep -v '^ *+' conftest.er1 >conftest.err
24491   rm -f conftest.er1
24492   cat conftest.err >&5
24493   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24494   (exit $ac_status); } && {
24495          test -z "$ac_c_werror_flag" ||
24496          test ! -s conftest.err
24497        } && test -s conftest.$ac_objext; then
24498   ac_hi=$ac_mid; break
24499 else
24500   $as_echo "$as_me: failed program was:" >&5
24501 sed 's/^/| /' conftest.$ac_ext >&5
24502
24503         ac_lo=`expr $ac_mid + 1`
24504                         if test $ac_lo -le $ac_mid; then
24505                           ac_lo= ac_hi=
24506                           break
24507                         fi
24508                         ac_mid=`expr 2 '*' $ac_mid + 1`
24509 fi
24510
24511 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24512   done
24513 else
24514   $as_echo "$as_me: failed program was:" >&5
24515 sed 's/^/| /' conftest.$ac_ext >&5
24516
24517         cat >conftest.$ac_ext <<_ACEOF
24518 /* confdefs.h.  */
24519 _ACEOF
24520 cat confdefs.h >>conftest.$ac_ext
24521 cat >>conftest.$ac_ext <<_ACEOF
24522 /* end confdefs.h.  */
24523 $ac_includes_default
24524 int
24525 main ()
24526 {
24527 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) < 0)];
24528 test_array [0] = 0
24529
24530   ;
24531   return 0;
24532 }
24533 _ACEOF
24534 rm -f conftest.$ac_objext
24535 if { (ac_try="$ac_compile"
24536 case "(($ac_try" in
24537   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24538   *) ac_try_echo=$ac_try;;
24539 esac
24540 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24541 $as_echo "$ac_try_echo") >&5
24542   (eval "$ac_compile") 2>conftest.er1
24543   ac_status=$?
24544   grep -v '^ *+' conftest.er1 >conftest.err
24545   rm -f conftest.er1
24546   cat conftest.err >&5
24547   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24548   (exit $ac_status); } && {
24549          test -z "$ac_c_werror_flag" ||
24550          test ! -s conftest.err
24551        } && test -s conftest.$ac_objext; then
24552   ac_hi=-1 ac_mid=-1
24553   while :; do
24554     cat >conftest.$ac_ext <<_ACEOF
24555 /* confdefs.h.  */
24556 _ACEOF
24557 cat confdefs.h >>conftest.$ac_ext
24558 cat >>conftest.$ac_ext <<_ACEOF
24559 /* end confdefs.h.  */
24560 $ac_includes_default
24561 int
24562 main ()
24563 {
24564 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) >= $ac_mid)];
24565 test_array [0] = 0
24566
24567   ;
24568   return 0;
24569 }
24570 _ACEOF
24571 rm -f conftest.$ac_objext
24572 if { (ac_try="$ac_compile"
24573 case "(($ac_try" in
24574   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24575   *) ac_try_echo=$ac_try;;
24576 esac
24577 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24578 $as_echo "$ac_try_echo") >&5
24579   (eval "$ac_compile") 2>conftest.er1
24580   ac_status=$?
24581   grep -v '^ *+' conftest.er1 >conftest.err
24582   rm -f conftest.er1
24583   cat conftest.err >&5
24584   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24585   (exit $ac_status); } && {
24586          test -z "$ac_c_werror_flag" ||
24587          test ! -s conftest.err
24588        } && test -s conftest.$ac_objext; then
24589   ac_lo=$ac_mid; break
24590 else
24591   $as_echo "$as_me: failed program was:" >&5
24592 sed 's/^/| /' conftest.$ac_ext >&5
24593
24594         ac_hi=`expr '(' $ac_mid ')' - 1`
24595                         if test $ac_mid -le $ac_hi; then
24596                           ac_lo= ac_hi=
24597                           break
24598                         fi
24599                         ac_mid=`expr 2 '*' $ac_mid`
24600 fi
24601
24602 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24603   done
24604 else
24605   $as_echo "$as_me: failed program was:" >&5
24606 sed 's/^/| /' conftest.$ac_ext >&5
24607
24608         ac_lo= ac_hi=
24609 fi
24610
24611 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24612 fi
24613
24614 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24615 # Binary search between lo and hi bounds.
24616 while test "x$ac_lo" != "x$ac_hi"; do
24617   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24618   cat >conftest.$ac_ext <<_ACEOF
24619 /* confdefs.h.  */
24620 _ACEOF
24621 cat confdefs.h >>conftest.$ac_ext
24622 cat >>conftest.$ac_ext <<_ACEOF
24623 /* end confdefs.h.  */
24624 $ac_includes_default
24625 int
24626 main ()
24627 {
24628 static int test_array [1 - 2 * !(((long int) (sizeof (size_t))) <= $ac_mid)];
24629 test_array [0] = 0
24630
24631   ;
24632   return 0;
24633 }
24634 _ACEOF
24635 rm -f conftest.$ac_objext
24636 if { (ac_try="$ac_compile"
24637 case "(($ac_try" in
24638   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24639   *) ac_try_echo=$ac_try;;
24640 esac
24641 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24642 $as_echo "$ac_try_echo") >&5
24643   (eval "$ac_compile") 2>conftest.er1
24644   ac_status=$?
24645   grep -v '^ *+' conftest.er1 >conftest.err
24646   rm -f conftest.er1
24647   cat conftest.err >&5
24648   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24649   (exit $ac_status); } && {
24650          test -z "$ac_c_werror_flag" ||
24651          test ! -s conftest.err
24652        } && test -s conftest.$ac_objext; then
24653   ac_hi=$ac_mid
24654 else
24655   $as_echo "$as_me: failed program was:" >&5
24656 sed 's/^/| /' conftest.$ac_ext >&5
24657
24658         ac_lo=`expr '(' $ac_mid ')' + 1`
24659 fi
24660
24661 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24662 done
24663 case $ac_lo in
24664 ?*) ac_cv_sizeof_size_t=$ac_lo;;
24665 '') if test "$ac_cv_type_size_t" = yes; then
24666      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24667 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24668 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
24669 See \`config.log' for more details." >&5
24670 $as_echo "$as_me: error: cannot compute sizeof (size_t)
24671 See \`config.log' for more details." >&2;}
24672    { (exit 77); exit 77; }; }; }
24673    else
24674      ac_cv_sizeof_size_t=0
24675    fi ;;
24676 esac
24677 else
24678   cat >conftest.$ac_ext <<_ACEOF
24679 /* confdefs.h.  */
24680 _ACEOF
24681 cat confdefs.h >>conftest.$ac_ext
24682 cat >>conftest.$ac_ext <<_ACEOF
24683 /* end confdefs.h.  */
24684 $ac_includes_default
24685 static long int longval () { return (long int) (sizeof (size_t)); }
24686 static unsigned long int ulongval () { return (long int) (sizeof (size_t)); }
24687 #include <stdio.h>
24688 #include <stdlib.h>
24689 int
24690 main ()
24691 {
24692
24693   FILE *f = fopen ("conftest.val", "w");
24694   if (! f)
24695     return 1;
24696   if (((long int) (sizeof (size_t))) < 0)
24697     {
24698       long int i = longval ();
24699       if (i != ((long int) (sizeof (size_t))))
24700         return 1;
24701       fprintf (f, "%ld", i);
24702     }
24703   else
24704     {
24705       unsigned long int i = ulongval ();
24706       if (i != ((long int) (sizeof (size_t))))
24707         return 1;
24708       fprintf (f, "%lu", i);
24709     }
24710   /* Do not output a trailing newline, as this causes \r\n confusion
24711      on some platforms.  */
24712   return ferror (f) || fclose (f) != 0;
24713
24714   ;
24715   return 0;
24716 }
24717 _ACEOF
24718 rm -f conftest$ac_exeext
24719 if { (ac_try="$ac_link"
24720 case "(($ac_try" in
24721   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24722   *) ac_try_echo=$ac_try;;
24723 esac
24724 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24725 $as_echo "$ac_try_echo") >&5
24726   (eval "$ac_link") 2>&5
24727   ac_status=$?
24728   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24729   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
24730   { (case "(($ac_try" in
24731   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24732   *) ac_try_echo=$ac_try;;
24733 esac
24734 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24735 $as_echo "$ac_try_echo") >&5
24736   (eval "$ac_try") 2>&5
24737   ac_status=$?
24738   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24739   (exit $ac_status); }; }; then
24740   ac_cv_sizeof_size_t=`cat conftest.val`
24741 else
24742   $as_echo "$as_me: program exited with status $ac_status" >&5
24743 $as_echo "$as_me: failed program was:" >&5
24744 sed 's/^/| /' conftest.$ac_ext >&5
24745
24746 ( exit $ac_status )
24747 if test "$ac_cv_type_size_t" = yes; then
24748      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
24749 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
24750 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (size_t)
24751 See \`config.log' for more details." >&5
24752 $as_echo "$as_me: error: cannot compute sizeof (size_t)
24753 See \`config.log' for more details." >&2;}
24754    { (exit 77); exit 77; }; }; }
24755    else
24756      ac_cv_sizeof_size_t=0
24757    fi
24758 fi
24759 rm -rf conftest.dSYM
24760 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
24761 fi
24762 rm -f conftest.val
24763 fi
24764 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_size_t" >&5
24765 $as_echo "$ac_cv_sizeof_size_t" >&6; }
24766
24767
24768
24769 cat >>confdefs.h <<_ACEOF
24770 #define SIZEOF_SIZE_T $ac_cv_sizeof_size_t
24771 _ACEOF
24772
24773
24774 # The cast to long int works around a bug in the HP C Compiler
24775 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects
24776 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'.
24777 # This bug is HP SR number 8606223364.
24778 { $as_echo "$as_me:$LINENO: checking size of long" >&5
24779 $as_echo_n "checking size of long... " >&6; }
24780 if test "${ac_cv_sizeof_long+set}" = set; then
24781   $as_echo_n "(cached) " >&6
24782 else
24783   if test "$cross_compiling" = yes; then
24784   # Depending upon the size, compute the lo and hi bounds.
24785 cat >conftest.$ac_ext <<_ACEOF
24786 /* confdefs.h.  */
24787 _ACEOF
24788 cat confdefs.h >>conftest.$ac_ext
24789 cat >>conftest.$ac_ext <<_ACEOF
24790 /* end confdefs.h.  */
24791 $ac_includes_default
24792 int
24793 main ()
24794 {
24795 static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= 0)];
24796 test_array [0] = 0
24797
24798   ;
24799   return 0;
24800 }
24801 _ACEOF
24802 rm -f conftest.$ac_objext
24803 if { (ac_try="$ac_compile"
24804 case "(($ac_try" in
24805   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24806   *) ac_try_echo=$ac_try;;
24807 esac
24808 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24809 $as_echo "$ac_try_echo") >&5
24810   (eval "$ac_compile") 2>conftest.er1
24811   ac_status=$?
24812   grep -v '^ *+' conftest.er1 >conftest.err
24813   rm -f conftest.er1
24814   cat conftest.err >&5
24815   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24816   (exit $ac_status); } && {
24817          test -z "$ac_c_werror_flag" ||
24818          test ! -s conftest.err
24819        } && test -s conftest.$ac_objext; then
24820   ac_lo=0 ac_mid=0
24821   while :; do
24822     cat >conftest.$ac_ext <<_ACEOF
24823 /* confdefs.h.  */
24824 _ACEOF
24825 cat confdefs.h >>conftest.$ac_ext
24826 cat >>conftest.$ac_ext <<_ACEOF
24827 /* end confdefs.h.  */
24828 $ac_includes_default
24829 int
24830 main ()
24831 {
24832 static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)];
24833 test_array [0] = 0
24834
24835   ;
24836   return 0;
24837 }
24838 _ACEOF
24839 rm -f conftest.$ac_objext
24840 if { (ac_try="$ac_compile"
24841 case "(($ac_try" in
24842   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24843   *) ac_try_echo=$ac_try;;
24844 esac
24845 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24846 $as_echo "$ac_try_echo") >&5
24847   (eval "$ac_compile") 2>conftest.er1
24848   ac_status=$?
24849   grep -v '^ *+' conftest.er1 >conftest.err
24850   rm -f conftest.er1
24851   cat conftest.err >&5
24852   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24853   (exit $ac_status); } && {
24854          test -z "$ac_c_werror_flag" ||
24855          test ! -s conftest.err
24856        } && test -s conftest.$ac_objext; then
24857   ac_hi=$ac_mid; break
24858 else
24859   $as_echo "$as_me: failed program was:" >&5
24860 sed 's/^/| /' conftest.$ac_ext >&5
24861
24862         ac_lo=`expr $ac_mid + 1`
24863                         if test $ac_lo -le $ac_mid; then
24864                           ac_lo= ac_hi=
24865                           break
24866                         fi
24867                         ac_mid=`expr 2 '*' $ac_mid + 1`
24868 fi
24869
24870 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24871   done
24872 else
24873   $as_echo "$as_me: failed program was:" >&5
24874 sed 's/^/| /' conftest.$ac_ext >&5
24875
24876         cat >conftest.$ac_ext <<_ACEOF
24877 /* confdefs.h.  */
24878 _ACEOF
24879 cat confdefs.h >>conftest.$ac_ext
24880 cat >>conftest.$ac_ext <<_ACEOF
24881 /* end confdefs.h.  */
24882 $ac_includes_default
24883 int
24884 main ()
24885 {
24886 static int test_array [1 - 2 * !(((long int) (sizeof (long))) < 0)];
24887 test_array [0] = 0
24888
24889   ;
24890   return 0;
24891 }
24892 _ACEOF
24893 rm -f conftest.$ac_objext
24894 if { (ac_try="$ac_compile"
24895 case "(($ac_try" in
24896   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24897   *) ac_try_echo=$ac_try;;
24898 esac
24899 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24900 $as_echo "$ac_try_echo") >&5
24901   (eval "$ac_compile") 2>conftest.er1
24902   ac_status=$?
24903   grep -v '^ *+' conftest.er1 >conftest.err
24904   rm -f conftest.er1
24905   cat conftest.err >&5
24906   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24907   (exit $ac_status); } && {
24908          test -z "$ac_c_werror_flag" ||
24909          test ! -s conftest.err
24910        } && test -s conftest.$ac_objext; then
24911   ac_hi=-1 ac_mid=-1
24912   while :; do
24913     cat >conftest.$ac_ext <<_ACEOF
24914 /* confdefs.h.  */
24915 _ACEOF
24916 cat confdefs.h >>conftest.$ac_ext
24917 cat >>conftest.$ac_ext <<_ACEOF
24918 /* end confdefs.h.  */
24919 $ac_includes_default
24920 int
24921 main ()
24922 {
24923 static int test_array [1 - 2 * !(((long int) (sizeof (long))) >= $ac_mid)];
24924 test_array [0] = 0
24925
24926   ;
24927   return 0;
24928 }
24929 _ACEOF
24930 rm -f conftest.$ac_objext
24931 if { (ac_try="$ac_compile"
24932 case "(($ac_try" in
24933   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24934   *) ac_try_echo=$ac_try;;
24935 esac
24936 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
24937 $as_echo "$ac_try_echo") >&5
24938   (eval "$ac_compile") 2>conftest.er1
24939   ac_status=$?
24940   grep -v '^ *+' conftest.er1 >conftest.err
24941   rm -f conftest.er1
24942   cat conftest.err >&5
24943   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
24944   (exit $ac_status); } && {
24945          test -z "$ac_c_werror_flag" ||
24946          test ! -s conftest.err
24947        } && test -s conftest.$ac_objext; then
24948   ac_lo=$ac_mid; break
24949 else
24950   $as_echo "$as_me: failed program was:" >&5
24951 sed 's/^/| /' conftest.$ac_ext >&5
24952
24953         ac_hi=`expr '(' $ac_mid ')' - 1`
24954                         if test $ac_mid -le $ac_hi; then
24955                           ac_lo= ac_hi=
24956                           break
24957                         fi
24958                         ac_mid=`expr 2 '*' $ac_mid`
24959 fi
24960
24961 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24962   done
24963 else
24964   $as_echo "$as_me: failed program was:" >&5
24965 sed 's/^/| /' conftest.$ac_ext >&5
24966
24967         ac_lo= ac_hi=
24968 fi
24969
24970 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24971 fi
24972
24973 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
24974 # Binary search between lo and hi bounds.
24975 while test "x$ac_lo" != "x$ac_hi"; do
24976   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
24977   cat >conftest.$ac_ext <<_ACEOF
24978 /* confdefs.h.  */
24979 _ACEOF
24980 cat confdefs.h >>conftest.$ac_ext
24981 cat >>conftest.$ac_ext <<_ACEOF
24982 /* end confdefs.h.  */
24983 $ac_includes_default
24984 int
24985 main ()
24986 {
24987 static int test_array [1 - 2 * !(((long int) (sizeof (long))) <= $ac_mid)];
24988 test_array [0] = 0
24989
24990   ;
24991   return 0;
24992 }
24993 _ACEOF
24994 rm -f conftest.$ac_objext
24995 if { (ac_try="$ac_compile"
24996 case "(($ac_try" in
24997   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
24998   *) ac_try_echo=$ac_try;;
24999 esac
25000 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25001 $as_echo "$ac_try_echo") >&5
25002   (eval "$ac_compile") 2>conftest.er1
25003   ac_status=$?
25004   grep -v '^ *+' conftest.er1 >conftest.err
25005   rm -f conftest.er1
25006   cat conftest.err >&5
25007   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25008   (exit $ac_status); } && {
25009          test -z "$ac_c_werror_flag" ||
25010          test ! -s conftest.err
25011        } && test -s conftest.$ac_objext; then
25012   ac_hi=$ac_mid
25013 else
25014   $as_echo "$as_me: failed program was:" >&5
25015 sed 's/^/| /' conftest.$ac_ext >&5
25016
25017         ac_lo=`expr '(' $ac_mid ')' + 1`
25018 fi
25019
25020 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25021 done
25022 case $ac_lo in
25023 ?*) ac_cv_sizeof_long=$ac_lo;;
25024 '') if test "$ac_cv_type_long" = yes; then
25025      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25026 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25027 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long)
25028 See \`config.log' for more details." >&5
25029 $as_echo "$as_me: error: cannot compute sizeof (long)
25030 See \`config.log' for more details." >&2;}
25031    { (exit 77); exit 77; }; }; }
25032    else
25033      ac_cv_sizeof_long=0
25034    fi ;;
25035 esac
25036 else
25037   cat >conftest.$ac_ext <<_ACEOF
25038 /* confdefs.h.  */
25039 _ACEOF
25040 cat confdefs.h >>conftest.$ac_ext
25041 cat >>conftest.$ac_ext <<_ACEOF
25042 /* end confdefs.h.  */
25043 $ac_includes_default
25044 static long int longval () { return (long int) (sizeof (long)); }
25045 static unsigned long int ulongval () { return (long int) (sizeof (long)); }
25046 #include <stdio.h>
25047 #include <stdlib.h>
25048 int
25049 main ()
25050 {
25051
25052   FILE *f = fopen ("conftest.val", "w");
25053   if (! f)
25054     return 1;
25055   if (((long int) (sizeof (long))) < 0)
25056     {
25057       long int i = longval ();
25058       if (i != ((long int) (sizeof (long))))
25059         return 1;
25060       fprintf (f, "%ld", i);
25061     }
25062   else
25063     {
25064       unsigned long int i = ulongval ();
25065       if (i != ((long int) (sizeof (long))))
25066         return 1;
25067       fprintf (f, "%lu", i);
25068     }
25069   /* Do not output a trailing newline, as this causes \r\n confusion
25070      on some platforms.  */
25071   return ferror (f) || fclose (f) != 0;
25072
25073   ;
25074   return 0;
25075 }
25076 _ACEOF
25077 rm -f conftest$ac_exeext
25078 if { (ac_try="$ac_link"
25079 case "(($ac_try" in
25080   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25081   *) ac_try_echo=$ac_try;;
25082 esac
25083 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25084 $as_echo "$ac_try_echo") >&5
25085   (eval "$ac_link") 2>&5
25086   ac_status=$?
25087   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25088   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25089   { (case "(($ac_try" in
25090   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25091   *) ac_try_echo=$ac_try;;
25092 esac
25093 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25094 $as_echo "$ac_try_echo") >&5
25095   (eval "$ac_try") 2>&5
25096   ac_status=$?
25097   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25098   (exit $ac_status); }; }; then
25099   ac_cv_sizeof_long=`cat conftest.val`
25100 else
25101   $as_echo "$as_me: program exited with status $ac_status" >&5
25102 $as_echo "$as_me: failed program was:" >&5
25103 sed 's/^/| /' conftest.$ac_ext >&5
25104
25105 ( exit $ac_status )
25106 if test "$ac_cv_type_long" = yes; then
25107      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25108 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25109 { { $as_echo "$as_me:$LINENO: error: cannot compute sizeof (long)
25110 See \`config.log' for more details." >&5
25111 $as_echo "$as_me: error: cannot compute sizeof (long)
25112 See \`config.log' for more details." >&2;}
25113    { (exit 77); exit 77; }; }; }
25114    else
25115      ac_cv_sizeof_long=0
25116    fi
25117 fi
25118 rm -rf conftest.dSYM
25119 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25120 fi
25121 rm -f conftest.val
25122 fi
25123 { $as_echo "$as_me:$LINENO: result: $ac_cv_sizeof_long" >&5
25124 $as_echo "$ac_cv_sizeof_long" >&6; }
25125
25126
25127
25128 cat >>confdefs.h <<_ACEOF
25129 #define SIZEOF_LONG $ac_cv_sizeof_long
25130 _ACEOF
25131
25132
25133
25134 # Decide whether float4 is passed by value: user-selectable, enabled by default
25135 { $as_echo "$as_me:$LINENO: checking whether to build with float4 passed by value" >&5
25136 $as_echo_n "checking whether to build with float4 passed by value... " >&6; }
25137
25138
25139 # Check whether --enable-float4-byval was given.
25140 if test "${enable_float4_byval+set}" = set; then
25141   enableval=$enable_float4_byval;
25142   case $enableval in
25143     yes)
25144
25145 cat >>confdefs.h <<\_ACEOF
25146 #define USE_FLOAT4_BYVAL 1
25147 _ACEOF
25148
25149                float4passbyval=true
25150       ;;
25151     no)
25152       float4passbyval=false
25153       ;;
25154     *)
25155       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float4-byval option" >&5
25156 $as_echo "$as_me: error: no argument expected for --enable-float4-byval option" >&2;}
25157    { (exit 1); exit 1; }; }
25158       ;;
25159   esac
25160
25161 else
25162   enable_float4_byval=yes
25163
25164 cat >>confdefs.h <<\_ACEOF
25165 #define USE_FLOAT4_BYVAL 1
25166 _ACEOF
25167
25168                float4passbyval=true
25169 fi
25170
25171
25172 { $as_echo "$as_me:$LINENO: result: $enable_float4_byval" >&5
25173 $as_echo "$enable_float4_byval" >&6; }
25174
25175 cat >>confdefs.h <<_ACEOF
25176 #define FLOAT4PASSBYVAL $float4passbyval
25177 _ACEOF
25178
25179
25180 # Decide whether float8 is passed by value.
25181 # Note: this setting also controls int8 and related types such as timestamp.
25182 # If sizeof(Datum) >= 8, this is user-selectable, enabled by default.
25183 # If not, trying to select it is an error.
25184 { $as_echo "$as_me:$LINENO: checking whether to build with float8 passed by value" >&5
25185 $as_echo_n "checking whether to build with float8 passed by value... " >&6; }
25186 if test $ac_cv_sizeof_void_p -ge 8 ; then
25187
25188
25189 # Check whether --enable-float8-byval was given.
25190 if test "${enable_float8_byval+set}" = set; then
25191   enableval=$enable_float8_byval;
25192   case $enableval in
25193     yes)
25194       :
25195       ;;
25196     no)
25197       :
25198       ;;
25199     *)
25200       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
25201 $as_echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
25202    { (exit 1); exit 1; }; }
25203       ;;
25204   esac
25205
25206 else
25207   enable_float8_byval=yes
25208
25209 fi
25210
25211
25212 else
25213
25214
25215 # Check whether --enable-float8-byval was given.
25216 if test "${enable_float8_byval+set}" = set; then
25217   enableval=$enable_float8_byval;
25218   case $enableval in
25219     yes)
25220       :
25221       ;;
25222     no)
25223       :
25224       ;;
25225     *)
25226       { { $as_echo "$as_me:$LINENO: error: no argument expected for --enable-float8-byval option" >&5
25227 $as_echo "$as_me: error: no argument expected for --enable-float8-byval option" >&2;}
25228    { (exit 1); exit 1; }; }
25229       ;;
25230   esac
25231
25232 else
25233   enable_float8_byval=no
25234
25235 fi
25236
25237
25238   if test "$enable_float8_byval" = yes ; then
25239     { { $as_echo "$as_me:$LINENO: error: --enable-float8-byval is not supported on 32-bit platforms." >&5
25240 $as_echo "$as_me: error: --enable-float8-byval is not supported on 32-bit platforms." >&2;}
25241    { (exit 1); exit 1; }; }
25242   fi
25243 fi
25244 if test "$enable_float8_byval" = yes ; then
25245
25246 cat >>confdefs.h <<\_ACEOF
25247 #define USE_FLOAT8_BYVAL 1
25248 _ACEOF
25249
25250   float8passbyval=true
25251 else
25252   float8passbyval=false
25253 fi
25254 { $as_echo "$as_me:$LINENO: result: $enable_float8_byval" >&5
25255 $as_echo "$enable_float8_byval" >&6; }
25256
25257 cat >>confdefs.h <<_ACEOF
25258 #define FLOAT8PASSBYVAL $float8passbyval
25259 _ACEOF
25260
25261
25262 # Determine memory alignment requirements for the basic C data types.
25263
25264 # The cast to long int works around a bug in the HP C Compiler,
25265 # see AC_CHECK_SIZEOF for more information.
25266 { $as_echo "$as_me:$LINENO: checking alignment of short" >&5
25267 $as_echo_n "checking alignment of short... " >&6; }
25268 if test "${ac_cv_alignof_short+set}" = set; then
25269   $as_echo_n "(cached) " >&6
25270 else
25271   if test "$cross_compiling" = yes; then
25272   # Depending upon the size, compute the lo and hi bounds.
25273 cat >conftest.$ac_ext <<_ACEOF
25274 /* confdefs.h.  */
25275 _ACEOF
25276 cat confdefs.h >>conftest.$ac_ext
25277 cat >>conftest.$ac_ext <<_ACEOF
25278 /* end confdefs.h.  */
25279 $ac_includes_default
25280 #ifndef offsetof
25281 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25282 #endif
25283 typedef struct { char x; short y; } ac__type_alignof_;
25284 int
25285 main ()
25286 {
25287 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
25288 test_array [0] = 0
25289
25290   ;
25291   return 0;
25292 }
25293 _ACEOF
25294 rm -f conftest.$ac_objext
25295 if { (ac_try="$ac_compile"
25296 case "(($ac_try" in
25297   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25298   *) ac_try_echo=$ac_try;;
25299 esac
25300 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25301 $as_echo "$ac_try_echo") >&5
25302   (eval "$ac_compile") 2>conftest.er1
25303   ac_status=$?
25304   grep -v '^ *+' conftest.er1 >conftest.err
25305   rm -f conftest.er1
25306   cat conftest.err >&5
25307   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25308   (exit $ac_status); } && {
25309          test -z "$ac_c_werror_flag" ||
25310          test ! -s conftest.err
25311        } && test -s conftest.$ac_objext; then
25312   ac_lo=0 ac_mid=0
25313   while :; do
25314     cat >conftest.$ac_ext <<_ACEOF
25315 /* confdefs.h.  */
25316 _ACEOF
25317 cat confdefs.h >>conftest.$ac_ext
25318 cat >>conftest.$ac_ext <<_ACEOF
25319 /* end confdefs.h.  */
25320 $ac_includes_default
25321 #ifndef offsetof
25322 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25323 #endif
25324 typedef struct { char x; short y; } ac__type_alignof_;
25325 int
25326 main ()
25327 {
25328 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25329 test_array [0] = 0
25330
25331   ;
25332   return 0;
25333 }
25334 _ACEOF
25335 rm -f conftest.$ac_objext
25336 if { (ac_try="$ac_compile"
25337 case "(($ac_try" in
25338   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25339   *) ac_try_echo=$ac_try;;
25340 esac
25341 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25342 $as_echo "$ac_try_echo") >&5
25343   (eval "$ac_compile") 2>conftest.er1
25344   ac_status=$?
25345   grep -v '^ *+' conftest.er1 >conftest.err
25346   rm -f conftest.er1
25347   cat conftest.err >&5
25348   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25349   (exit $ac_status); } && {
25350          test -z "$ac_c_werror_flag" ||
25351          test ! -s conftest.err
25352        } && test -s conftest.$ac_objext; then
25353   ac_hi=$ac_mid; break
25354 else
25355   $as_echo "$as_me: failed program was:" >&5
25356 sed 's/^/| /' conftest.$ac_ext >&5
25357
25358         ac_lo=`expr $ac_mid + 1`
25359                         if test $ac_lo -le $ac_mid; then
25360                           ac_lo= ac_hi=
25361                           break
25362                         fi
25363                         ac_mid=`expr 2 '*' $ac_mid + 1`
25364 fi
25365
25366 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25367   done
25368 else
25369   $as_echo "$as_me: failed program was:" >&5
25370 sed 's/^/| /' conftest.$ac_ext >&5
25371
25372         cat >conftest.$ac_ext <<_ACEOF
25373 /* confdefs.h.  */
25374 _ACEOF
25375 cat confdefs.h >>conftest.$ac_ext
25376 cat >>conftest.$ac_ext <<_ACEOF
25377 /* end confdefs.h.  */
25378 $ac_includes_default
25379 #ifndef offsetof
25380 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25381 #endif
25382 typedef struct { char x; short y; } ac__type_alignof_;
25383 int
25384 main ()
25385 {
25386 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
25387 test_array [0] = 0
25388
25389   ;
25390   return 0;
25391 }
25392 _ACEOF
25393 rm -f conftest.$ac_objext
25394 if { (ac_try="$ac_compile"
25395 case "(($ac_try" in
25396   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25397   *) ac_try_echo=$ac_try;;
25398 esac
25399 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25400 $as_echo "$ac_try_echo") >&5
25401   (eval "$ac_compile") 2>conftest.er1
25402   ac_status=$?
25403   grep -v '^ *+' conftest.er1 >conftest.err
25404   rm -f conftest.er1
25405   cat conftest.err >&5
25406   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25407   (exit $ac_status); } && {
25408          test -z "$ac_c_werror_flag" ||
25409          test ! -s conftest.err
25410        } && test -s conftest.$ac_objext; then
25411   ac_hi=-1 ac_mid=-1
25412   while :; do
25413     cat >conftest.$ac_ext <<_ACEOF
25414 /* confdefs.h.  */
25415 _ACEOF
25416 cat confdefs.h >>conftest.$ac_ext
25417 cat >>conftest.$ac_ext <<_ACEOF
25418 /* end confdefs.h.  */
25419 $ac_includes_default
25420 #ifndef offsetof
25421 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25422 #endif
25423 typedef struct { char x; short y; } ac__type_alignof_;
25424 int
25425 main ()
25426 {
25427 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
25428 test_array [0] = 0
25429
25430   ;
25431   return 0;
25432 }
25433 _ACEOF
25434 rm -f conftest.$ac_objext
25435 if { (ac_try="$ac_compile"
25436 case "(($ac_try" in
25437   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25438   *) ac_try_echo=$ac_try;;
25439 esac
25440 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25441 $as_echo "$ac_try_echo") >&5
25442   (eval "$ac_compile") 2>conftest.er1
25443   ac_status=$?
25444   grep -v '^ *+' conftest.er1 >conftest.err
25445   rm -f conftest.er1
25446   cat conftest.err >&5
25447   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25448   (exit $ac_status); } && {
25449          test -z "$ac_c_werror_flag" ||
25450          test ! -s conftest.err
25451        } && test -s conftest.$ac_objext; then
25452   ac_lo=$ac_mid; break
25453 else
25454   $as_echo "$as_me: failed program was:" >&5
25455 sed 's/^/| /' conftest.$ac_ext >&5
25456
25457         ac_hi=`expr '(' $ac_mid ')' - 1`
25458                         if test $ac_mid -le $ac_hi; then
25459                           ac_lo= ac_hi=
25460                           break
25461                         fi
25462                         ac_mid=`expr 2 '*' $ac_mid`
25463 fi
25464
25465 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25466   done
25467 else
25468   $as_echo "$as_me: failed program was:" >&5
25469 sed 's/^/| /' conftest.$ac_ext >&5
25470
25471         ac_lo= ac_hi=
25472 fi
25473
25474 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25475 fi
25476
25477 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25478 # Binary search between lo and hi bounds.
25479 while test "x$ac_lo" != "x$ac_hi"; do
25480   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25481   cat >conftest.$ac_ext <<_ACEOF
25482 /* confdefs.h.  */
25483 _ACEOF
25484 cat confdefs.h >>conftest.$ac_ext
25485 cat >>conftest.$ac_ext <<_ACEOF
25486 /* end confdefs.h.  */
25487 $ac_includes_default
25488 #ifndef offsetof
25489 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25490 #endif
25491 typedef struct { char x; short y; } ac__type_alignof_;
25492 int
25493 main ()
25494 {
25495 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25496 test_array [0] = 0
25497
25498   ;
25499   return 0;
25500 }
25501 _ACEOF
25502 rm -f conftest.$ac_objext
25503 if { (ac_try="$ac_compile"
25504 case "(($ac_try" in
25505   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25506   *) ac_try_echo=$ac_try;;
25507 esac
25508 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25509 $as_echo "$ac_try_echo") >&5
25510   (eval "$ac_compile") 2>conftest.er1
25511   ac_status=$?
25512   grep -v '^ *+' conftest.er1 >conftest.err
25513   rm -f conftest.er1
25514   cat conftest.err >&5
25515   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25516   (exit $ac_status); } && {
25517          test -z "$ac_c_werror_flag" ||
25518          test ! -s conftest.err
25519        } && test -s conftest.$ac_objext; then
25520   ac_hi=$ac_mid
25521 else
25522   $as_echo "$as_me: failed program was:" >&5
25523 sed 's/^/| /' conftest.$ac_ext >&5
25524
25525         ac_lo=`expr '(' $ac_mid ')' + 1`
25526 fi
25527
25528 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25529 done
25530 case $ac_lo in
25531 ?*) ac_cv_alignof_short=$ac_lo;;
25532 '') if test "$ac_cv_type_short" = yes; then
25533      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25534 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25535 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of short
25536 See \`config.log' for more details." >&5
25537 $as_echo "$as_me: error: cannot compute alignment of short
25538 See \`config.log' for more details." >&2;}
25539    { (exit 77); exit 77; }; }; }
25540    else
25541      ac_cv_alignof_short=0
25542    fi ;;
25543 esac
25544 else
25545   cat >conftest.$ac_ext <<_ACEOF
25546 /* confdefs.h.  */
25547 _ACEOF
25548 cat confdefs.h >>conftest.$ac_ext
25549 cat >>conftest.$ac_ext <<_ACEOF
25550 /* end confdefs.h.  */
25551 $ac_includes_default
25552 #ifndef offsetof
25553 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25554 #endif
25555 typedef struct { char x; short y; } ac__type_alignof_;
25556 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
25557 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
25558 #include <stdio.h>
25559 #include <stdlib.h>
25560 int
25561 main ()
25562 {
25563
25564   FILE *f = fopen ("conftest.val", "w");
25565   if (! f)
25566     return 1;
25567   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
25568     {
25569       long int i = longval ();
25570       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25571         return 1;
25572       fprintf (f, "%ld", i);
25573     }
25574   else
25575     {
25576       unsigned long int i = ulongval ();
25577       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25578         return 1;
25579       fprintf (f, "%lu", i);
25580     }
25581   /* Do not output a trailing newline, as this causes \r\n confusion
25582      on some platforms.  */
25583   return ferror (f) || fclose (f) != 0;
25584
25585   ;
25586   return 0;
25587 }
25588 _ACEOF
25589 rm -f conftest$ac_exeext
25590 if { (ac_try="$ac_link"
25591 case "(($ac_try" in
25592   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25593   *) ac_try_echo=$ac_try;;
25594 esac
25595 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25596 $as_echo "$ac_try_echo") >&5
25597   (eval "$ac_link") 2>&5
25598   ac_status=$?
25599   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25600   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25601   { (case "(($ac_try" in
25602   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25603   *) ac_try_echo=$ac_try;;
25604 esac
25605 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25606 $as_echo "$ac_try_echo") >&5
25607   (eval "$ac_try") 2>&5
25608   ac_status=$?
25609   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25610   (exit $ac_status); }; }; then
25611   ac_cv_alignof_short=`cat conftest.val`
25612 else
25613   $as_echo "$as_me: program exited with status $ac_status" >&5
25614 $as_echo "$as_me: failed program was:" >&5
25615 sed 's/^/| /' conftest.$ac_ext >&5
25616
25617 ( exit $ac_status )
25618 if test "$ac_cv_type_short" = yes; then
25619      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25620 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25621 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of short
25622 See \`config.log' for more details." >&5
25623 $as_echo "$as_me: error: cannot compute alignment of short
25624 See \`config.log' for more details." >&2;}
25625    { (exit 77); exit 77; }; }; }
25626    else
25627      ac_cv_alignof_short=0
25628    fi
25629 fi
25630 rm -rf conftest.dSYM
25631 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
25632 fi
25633 rm -f conftest.val
25634 fi
25635 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_short" >&5
25636 $as_echo "$ac_cv_alignof_short" >&6; }
25637
25638
25639
25640 cat >>confdefs.h <<_ACEOF
25641 #define ALIGNOF_SHORT $ac_cv_alignof_short
25642 _ACEOF
25643
25644
25645 # The cast to long int works around a bug in the HP C Compiler,
25646 # see AC_CHECK_SIZEOF for more information.
25647 { $as_echo "$as_me:$LINENO: checking alignment of int" >&5
25648 $as_echo_n "checking alignment of int... " >&6; }
25649 if test "${ac_cv_alignof_int+set}" = set; then
25650   $as_echo_n "(cached) " >&6
25651 else
25652   if test "$cross_compiling" = yes; then
25653   # Depending upon the size, compute the lo and hi bounds.
25654 cat >conftest.$ac_ext <<_ACEOF
25655 /* confdefs.h.  */
25656 _ACEOF
25657 cat confdefs.h >>conftest.$ac_ext
25658 cat >>conftest.$ac_ext <<_ACEOF
25659 /* end confdefs.h.  */
25660 $ac_includes_default
25661 #ifndef offsetof
25662 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25663 #endif
25664 typedef struct { char x; int y; } ac__type_alignof_;
25665 int
25666 main ()
25667 {
25668 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
25669 test_array [0] = 0
25670
25671   ;
25672   return 0;
25673 }
25674 _ACEOF
25675 rm -f conftest.$ac_objext
25676 if { (ac_try="$ac_compile"
25677 case "(($ac_try" in
25678   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25679   *) ac_try_echo=$ac_try;;
25680 esac
25681 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25682 $as_echo "$ac_try_echo") >&5
25683   (eval "$ac_compile") 2>conftest.er1
25684   ac_status=$?
25685   grep -v '^ *+' conftest.er1 >conftest.err
25686   rm -f conftest.er1
25687   cat conftest.err >&5
25688   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25689   (exit $ac_status); } && {
25690          test -z "$ac_c_werror_flag" ||
25691          test ! -s conftest.err
25692        } && test -s conftest.$ac_objext; then
25693   ac_lo=0 ac_mid=0
25694   while :; do
25695     cat >conftest.$ac_ext <<_ACEOF
25696 /* confdefs.h.  */
25697 _ACEOF
25698 cat confdefs.h >>conftest.$ac_ext
25699 cat >>conftest.$ac_ext <<_ACEOF
25700 /* end confdefs.h.  */
25701 $ac_includes_default
25702 #ifndef offsetof
25703 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25704 #endif
25705 typedef struct { char x; int y; } ac__type_alignof_;
25706 int
25707 main ()
25708 {
25709 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25710 test_array [0] = 0
25711
25712   ;
25713   return 0;
25714 }
25715 _ACEOF
25716 rm -f conftest.$ac_objext
25717 if { (ac_try="$ac_compile"
25718 case "(($ac_try" in
25719   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25720   *) ac_try_echo=$ac_try;;
25721 esac
25722 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25723 $as_echo "$ac_try_echo") >&5
25724   (eval "$ac_compile") 2>conftest.er1
25725   ac_status=$?
25726   grep -v '^ *+' conftest.er1 >conftest.err
25727   rm -f conftest.er1
25728   cat conftest.err >&5
25729   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25730   (exit $ac_status); } && {
25731          test -z "$ac_c_werror_flag" ||
25732          test ! -s conftest.err
25733        } && test -s conftest.$ac_objext; then
25734   ac_hi=$ac_mid; break
25735 else
25736   $as_echo "$as_me: failed program was:" >&5
25737 sed 's/^/| /' conftest.$ac_ext >&5
25738
25739         ac_lo=`expr $ac_mid + 1`
25740                         if test $ac_lo -le $ac_mid; then
25741                           ac_lo= ac_hi=
25742                           break
25743                         fi
25744                         ac_mid=`expr 2 '*' $ac_mid + 1`
25745 fi
25746
25747 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25748   done
25749 else
25750   $as_echo "$as_me: failed program was:" >&5
25751 sed 's/^/| /' conftest.$ac_ext >&5
25752
25753         cat >conftest.$ac_ext <<_ACEOF
25754 /* confdefs.h.  */
25755 _ACEOF
25756 cat confdefs.h >>conftest.$ac_ext
25757 cat >>conftest.$ac_ext <<_ACEOF
25758 /* end confdefs.h.  */
25759 $ac_includes_default
25760 #ifndef offsetof
25761 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25762 #endif
25763 typedef struct { char x; int y; } ac__type_alignof_;
25764 int
25765 main ()
25766 {
25767 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
25768 test_array [0] = 0
25769
25770   ;
25771   return 0;
25772 }
25773 _ACEOF
25774 rm -f conftest.$ac_objext
25775 if { (ac_try="$ac_compile"
25776 case "(($ac_try" in
25777   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25778   *) ac_try_echo=$ac_try;;
25779 esac
25780 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25781 $as_echo "$ac_try_echo") >&5
25782   (eval "$ac_compile") 2>conftest.er1
25783   ac_status=$?
25784   grep -v '^ *+' conftest.er1 >conftest.err
25785   rm -f conftest.er1
25786   cat conftest.err >&5
25787   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25788   (exit $ac_status); } && {
25789          test -z "$ac_c_werror_flag" ||
25790          test ! -s conftest.err
25791        } && test -s conftest.$ac_objext; then
25792   ac_hi=-1 ac_mid=-1
25793   while :; do
25794     cat >conftest.$ac_ext <<_ACEOF
25795 /* confdefs.h.  */
25796 _ACEOF
25797 cat confdefs.h >>conftest.$ac_ext
25798 cat >>conftest.$ac_ext <<_ACEOF
25799 /* end confdefs.h.  */
25800 $ac_includes_default
25801 #ifndef offsetof
25802 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25803 #endif
25804 typedef struct { char x; int y; } ac__type_alignof_;
25805 int
25806 main ()
25807 {
25808 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
25809 test_array [0] = 0
25810
25811   ;
25812   return 0;
25813 }
25814 _ACEOF
25815 rm -f conftest.$ac_objext
25816 if { (ac_try="$ac_compile"
25817 case "(($ac_try" in
25818   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25819   *) ac_try_echo=$ac_try;;
25820 esac
25821 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25822 $as_echo "$ac_try_echo") >&5
25823   (eval "$ac_compile") 2>conftest.er1
25824   ac_status=$?
25825   grep -v '^ *+' conftest.er1 >conftest.err
25826   rm -f conftest.er1
25827   cat conftest.err >&5
25828   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25829   (exit $ac_status); } && {
25830          test -z "$ac_c_werror_flag" ||
25831          test ! -s conftest.err
25832        } && test -s conftest.$ac_objext; then
25833   ac_lo=$ac_mid; break
25834 else
25835   $as_echo "$as_me: failed program was:" >&5
25836 sed 's/^/| /' conftest.$ac_ext >&5
25837
25838         ac_hi=`expr '(' $ac_mid ')' - 1`
25839                         if test $ac_mid -le $ac_hi; then
25840                           ac_lo= ac_hi=
25841                           break
25842                         fi
25843                         ac_mid=`expr 2 '*' $ac_mid`
25844 fi
25845
25846 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25847   done
25848 else
25849   $as_echo "$as_me: failed program was:" >&5
25850 sed 's/^/| /' conftest.$ac_ext >&5
25851
25852         ac_lo= ac_hi=
25853 fi
25854
25855 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25856 fi
25857
25858 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25859 # Binary search between lo and hi bounds.
25860 while test "x$ac_lo" != "x$ac_hi"; do
25861   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
25862   cat >conftest.$ac_ext <<_ACEOF
25863 /* confdefs.h.  */
25864 _ACEOF
25865 cat confdefs.h >>conftest.$ac_ext
25866 cat >>conftest.$ac_ext <<_ACEOF
25867 /* end confdefs.h.  */
25868 $ac_includes_default
25869 #ifndef offsetof
25870 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25871 #endif
25872 typedef struct { char x; int y; } ac__type_alignof_;
25873 int
25874 main ()
25875 {
25876 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
25877 test_array [0] = 0
25878
25879   ;
25880   return 0;
25881 }
25882 _ACEOF
25883 rm -f conftest.$ac_objext
25884 if { (ac_try="$ac_compile"
25885 case "(($ac_try" in
25886   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25887   *) ac_try_echo=$ac_try;;
25888 esac
25889 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25890 $as_echo "$ac_try_echo") >&5
25891   (eval "$ac_compile") 2>conftest.er1
25892   ac_status=$?
25893   grep -v '^ *+' conftest.er1 >conftest.err
25894   rm -f conftest.er1
25895   cat conftest.err >&5
25896   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25897   (exit $ac_status); } && {
25898          test -z "$ac_c_werror_flag" ||
25899          test ! -s conftest.err
25900        } && test -s conftest.$ac_objext; then
25901   ac_hi=$ac_mid
25902 else
25903   $as_echo "$as_me: failed program was:" >&5
25904 sed 's/^/| /' conftest.$ac_ext >&5
25905
25906         ac_lo=`expr '(' $ac_mid ')' + 1`
25907 fi
25908
25909 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
25910 done
25911 case $ac_lo in
25912 ?*) ac_cv_alignof_int=$ac_lo;;
25913 '') if test "$ac_cv_type_int" = yes; then
25914      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
25915 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
25916 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of int
25917 See \`config.log' for more details." >&5
25918 $as_echo "$as_me: error: cannot compute alignment of int
25919 See \`config.log' for more details." >&2;}
25920    { (exit 77); exit 77; }; }; }
25921    else
25922      ac_cv_alignof_int=0
25923    fi ;;
25924 esac
25925 else
25926   cat >conftest.$ac_ext <<_ACEOF
25927 /* confdefs.h.  */
25928 _ACEOF
25929 cat confdefs.h >>conftest.$ac_ext
25930 cat >>conftest.$ac_ext <<_ACEOF
25931 /* end confdefs.h.  */
25932 $ac_includes_default
25933 #ifndef offsetof
25934 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
25935 #endif
25936 typedef struct { char x; int y; } ac__type_alignof_;
25937 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
25938 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
25939 #include <stdio.h>
25940 #include <stdlib.h>
25941 int
25942 main ()
25943 {
25944
25945   FILE *f = fopen ("conftest.val", "w");
25946   if (! f)
25947     return 1;
25948   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
25949     {
25950       long int i = longval ();
25951       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25952         return 1;
25953       fprintf (f, "%ld", i);
25954     }
25955   else
25956     {
25957       unsigned long int i = ulongval ();
25958       if (i != ((long int) offsetof (ac__type_alignof_, y)))
25959         return 1;
25960       fprintf (f, "%lu", i);
25961     }
25962   /* Do not output a trailing newline, as this causes \r\n confusion
25963      on some platforms.  */
25964   return ferror (f) || fclose (f) != 0;
25965
25966   ;
25967   return 0;
25968 }
25969 _ACEOF
25970 rm -f conftest$ac_exeext
25971 if { (ac_try="$ac_link"
25972 case "(($ac_try" in
25973   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25974   *) ac_try_echo=$ac_try;;
25975 esac
25976 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25977 $as_echo "$ac_try_echo") >&5
25978   (eval "$ac_link") 2>&5
25979   ac_status=$?
25980   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25981   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
25982   { (case "(($ac_try" in
25983   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
25984   *) ac_try_echo=$ac_try;;
25985 esac
25986 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
25987 $as_echo "$ac_try_echo") >&5
25988   (eval "$ac_try") 2>&5
25989   ac_status=$?
25990   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
25991   (exit $ac_status); }; }; then
25992   ac_cv_alignof_int=`cat conftest.val`
25993 else
25994   $as_echo "$as_me: program exited with status $ac_status" >&5
25995 $as_echo "$as_me: failed program was:" >&5
25996 sed 's/^/| /' conftest.$ac_ext >&5
25997
25998 ( exit $ac_status )
25999 if test "$ac_cv_type_int" = yes; then
26000      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26001 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26002 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of int
26003 See \`config.log' for more details." >&5
26004 $as_echo "$as_me: error: cannot compute alignment of int
26005 See \`config.log' for more details." >&2;}
26006    { (exit 77); exit 77; }; }; }
26007    else
26008      ac_cv_alignof_int=0
26009    fi
26010 fi
26011 rm -rf conftest.dSYM
26012 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26013 fi
26014 rm -f conftest.val
26015 fi
26016 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_int" >&5
26017 $as_echo "$ac_cv_alignof_int" >&6; }
26018
26019
26020
26021 cat >>confdefs.h <<_ACEOF
26022 #define ALIGNOF_INT $ac_cv_alignof_int
26023 _ACEOF
26024
26025
26026 # The cast to long int works around a bug in the HP C Compiler,
26027 # see AC_CHECK_SIZEOF for more information.
26028 { $as_echo "$as_me:$LINENO: checking alignment of long" >&5
26029 $as_echo_n "checking alignment of long... " >&6; }
26030 if test "${ac_cv_alignof_long+set}" = set; then
26031   $as_echo_n "(cached) " >&6
26032 else
26033   if test "$cross_compiling" = yes; then
26034   # Depending upon the size, compute the lo and hi bounds.
26035 cat >conftest.$ac_ext <<_ACEOF
26036 /* confdefs.h.  */
26037 _ACEOF
26038 cat confdefs.h >>conftest.$ac_ext
26039 cat >>conftest.$ac_ext <<_ACEOF
26040 /* end confdefs.h.  */
26041 $ac_includes_default
26042 #ifndef offsetof
26043 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26044 #endif
26045 typedef struct { char x; long y; } ac__type_alignof_;
26046 int
26047 main ()
26048 {
26049 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26050 test_array [0] = 0
26051
26052   ;
26053   return 0;
26054 }
26055 _ACEOF
26056 rm -f conftest.$ac_objext
26057 if { (ac_try="$ac_compile"
26058 case "(($ac_try" in
26059   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26060   *) ac_try_echo=$ac_try;;
26061 esac
26062 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26063 $as_echo "$ac_try_echo") >&5
26064   (eval "$ac_compile") 2>conftest.er1
26065   ac_status=$?
26066   grep -v '^ *+' conftest.er1 >conftest.err
26067   rm -f conftest.er1
26068   cat conftest.err >&5
26069   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26070   (exit $ac_status); } && {
26071          test -z "$ac_c_werror_flag" ||
26072          test ! -s conftest.err
26073        } && test -s conftest.$ac_objext; then
26074   ac_lo=0 ac_mid=0
26075   while :; do
26076     cat >conftest.$ac_ext <<_ACEOF
26077 /* confdefs.h.  */
26078 _ACEOF
26079 cat confdefs.h >>conftest.$ac_ext
26080 cat >>conftest.$ac_ext <<_ACEOF
26081 /* end confdefs.h.  */
26082 $ac_includes_default
26083 #ifndef offsetof
26084 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26085 #endif
26086 typedef struct { char x; long y; } ac__type_alignof_;
26087 int
26088 main ()
26089 {
26090 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26091 test_array [0] = 0
26092
26093   ;
26094   return 0;
26095 }
26096 _ACEOF
26097 rm -f conftest.$ac_objext
26098 if { (ac_try="$ac_compile"
26099 case "(($ac_try" in
26100   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26101   *) ac_try_echo=$ac_try;;
26102 esac
26103 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26104 $as_echo "$ac_try_echo") >&5
26105   (eval "$ac_compile") 2>conftest.er1
26106   ac_status=$?
26107   grep -v '^ *+' conftest.er1 >conftest.err
26108   rm -f conftest.er1
26109   cat conftest.err >&5
26110   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26111   (exit $ac_status); } && {
26112          test -z "$ac_c_werror_flag" ||
26113          test ! -s conftest.err
26114        } && test -s conftest.$ac_objext; then
26115   ac_hi=$ac_mid; break
26116 else
26117   $as_echo "$as_me: failed program was:" >&5
26118 sed 's/^/| /' conftest.$ac_ext >&5
26119
26120         ac_lo=`expr $ac_mid + 1`
26121                         if test $ac_lo -le $ac_mid; then
26122                           ac_lo= ac_hi=
26123                           break
26124                         fi
26125                         ac_mid=`expr 2 '*' $ac_mid + 1`
26126 fi
26127
26128 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26129   done
26130 else
26131   $as_echo "$as_me: failed program was:" >&5
26132 sed 's/^/| /' conftest.$ac_ext >&5
26133
26134         cat >conftest.$ac_ext <<_ACEOF
26135 /* confdefs.h.  */
26136 _ACEOF
26137 cat confdefs.h >>conftest.$ac_ext
26138 cat >>conftest.$ac_ext <<_ACEOF
26139 /* end confdefs.h.  */
26140 $ac_includes_default
26141 #ifndef offsetof
26142 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26143 #endif
26144 typedef struct { char x; long y; } ac__type_alignof_;
26145 int
26146 main ()
26147 {
26148 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26149 test_array [0] = 0
26150
26151   ;
26152   return 0;
26153 }
26154 _ACEOF
26155 rm -f conftest.$ac_objext
26156 if { (ac_try="$ac_compile"
26157 case "(($ac_try" in
26158   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26159   *) ac_try_echo=$ac_try;;
26160 esac
26161 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26162 $as_echo "$ac_try_echo") >&5
26163   (eval "$ac_compile") 2>conftest.er1
26164   ac_status=$?
26165   grep -v '^ *+' conftest.er1 >conftest.err
26166   rm -f conftest.er1
26167   cat conftest.err >&5
26168   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26169   (exit $ac_status); } && {
26170          test -z "$ac_c_werror_flag" ||
26171          test ! -s conftest.err
26172        } && test -s conftest.$ac_objext; then
26173   ac_hi=-1 ac_mid=-1
26174   while :; do
26175     cat >conftest.$ac_ext <<_ACEOF
26176 /* confdefs.h.  */
26177 _ACEOF
26178 cat confdefs.h >>conftest.$ac_ext
26179 cat >>conftest.$ac_ext <<_ACEOF
26180 /* end confdefs.h.  */
26181 $ac_includes_default
26182 #ifndef offsetof
26183 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26184 #endif
26185 typedef struct { char x; long y; } ac__type_alignof_;
26186 int
26187 main ()
26188 {
26189 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26190 test_array [0] = 0
26191
26192   ;
26193   return 0;
26194 }
26195 _ACEOF
26196 rm -f conftest.$ac_objext
26197 if { (ac_try="$ac_compile"
26198 case "(($ac_try" in
26199   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26200   *) ac_try_echo=$ac_try;;
26201 esac
26202 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26203 $as_echo "$ac_try_echo") >&5
26204   (eval "$ac_compile") 2>conftest.er1
26205   ac_status=$?
26206   grep -v '^ *+' conftest.er1 >conftest.err
26207   rm -f conftest.er1
26208   cat conftest.err >&5
26209   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26210   (exit $ac_status); } && {
26211          test -z "$ac_c_werror_flag" ||
26212          test ! -s conftest.err
26213        } && test -s conftest.$ac_objext; then
26214   ac_lo=$ac_mid; break
26215 else
26216   $as_echo "$as_me: failed program was:" >&5
26217 sed 's/^/| /' conftest.$ac_ext >&5
26218
26219         ac_hi=`expr '(' $ac_mid ')' - 1`
26220                         if test $ac_mid -le $ac_hi; then
26221                           ac_lo= ac_hi=
26222                           break
26223                         fi
26224                         ac_mid=`expr 2 '*' $ac_mid`
26225 fi
26226
26227 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26228   done
26229 else
26230   $as_echo "$as_me: failed program was:" >&5
26231 sed 's/^/| /' conftest.$ac_ext >&5
26232
26233         ac_lo= ac_hi=
26234 fi
26235
26236 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26237 fi
26238
26239 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26240 # Binary search between lo and hi bounds.
26241 while test "x$ac_lo" != "x$ac_hi"; do
26242   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26243   cat >conftest.$ac_ext <<_ACEOF
26244 /* confdefs.h.  */
26245 _ACEOF
26246 cat confdefs.h >>conftest.$ac_ext
26247 cat >>conftest.$ac_ext <<_ACEOF
26248 /* end confdefs.h.  */
26249 $ac_includes_default
26250 #ifndef offsetof
26251 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26252 #endif
26253 typedef struct { char x; long y; } ac__type_alignof_;
26254 int
26255 main ()
26256 {
26257 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26258 test_array [0] = 0
26259
26260   ;
26261   return 0;
26262 }
26263 _ACEOF
26264 rm -f conftest.$ac_objext
26265 if { (ac_try="$ac_compile"
26266 case "(($ac_try" in
26267   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26268   *) ac_try_echo=$ac_try;;
26269 esac
26270 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26271 $as_echo "$ac_try_echo") >&5
26272   (eval "$ac_compile") 2>conftest.er1
26273   ac_status=$?
26274   grep -v '^ *+' conftest.er1 >conftest.err
26275   rm -f conftest.er1
26276   cat conftest.err >&5
26277   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26278   (exit $ac_status); } && {
26279          test -z "$ac_c_werror_flag" ||
26280          test ! -s conftest.err
26281        } && test -s conftest.$ac_objext; then
26282   ac_hi=$ac_mid
26283 else
26284   $as_echo "$as_me: failed program was:" >&5
26285 sed 's/^/| /' conftest.$ac_ext >&5
26286
26287         ac_lo=`expr '(' $ac_mid ')' + 1`
26288 fi
26289
26290 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26291 done
26292 case $ac_lo in
26293 ?*) ac_cv_alignof_long=$ac_lo;;
26294 '') if test "$ac_cv_type_long" = yes; then
26295      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26296 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26297 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long
26298 See \`config.log' for more details." >&5
26299 $as_echo "$as_me: error: cannot compute alignment of long
26300 See \`config.log' for more details." >&2;}
26301    { (exit 77); exit 77; }; }; }
26302    else
26303      ac_cv_alignof_long=0
26304    fi ;;
26305 esac
26306 else
26307   cat >conftest.$ac_ext <<_ACEOF
26308 /* confdefs.h.  */
26309 _ACEOF
26310 cat confdefs.h >>conftest.$ac_ext
26311 cat >>conftest.$ac_ext <<_ACEOF
26312 /* end confdefs.h.  */
26313 $ac_includes_default
26314 #ifndef offsetof
26315 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26316 #endif
26317 typedef struct { char x; long y; } ac__type_alignof_;
26318 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26319 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26320 #include <stdio.h>
26321 #include <stdlib.h>
26322 int
26323 main ()
26324 {
26325
26326   FILE *f = fopen ("conftest.val", "w");
26327   if (! f)
26328     return 1;
26329   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
26330     {
26331       long int i = longval ();
26332       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26333         return 1;
26334       fprintf (f, "%ld", i);
26335     }
26336   else
26337     {
26338       unsigned long int i = ulongval ();
26339       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26340         return 1;
26341       fprintf (f, "%lu", i);
26342     }
26343   /* Do not output a trailing newline, as this causes \r\n confusion
26344      on some platforms.  */
26345   return ferror (f) || fclose (f) != 0;
26346
26347   ;
26348   return 0;
26349 }
26350 _ACEOF
26351 rm -f conftest$ac_exeext
26352 if { (ac_try="$ac_link"
26353 case "(($ac_try" in
26354   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26355   *) ac_try_echo=$ac_try;;
26356 esac
26357 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26358 $as_echo "$ac_try_echo") >&5
26359   (eval "$ac_link") 2>&5
26360   ac_status=$?
26361   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26362   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26363   { (case "(($ac_try" in
26364   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26365   *) ac_try_echo=$ac_try;;
26366 esac
26367 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26368 $as_echo "$ac_try_echo") >&5
26369   (eval "$ac_try") 2>&5
26370   ac_status=$?
26371   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26372   (exit $ac_status); }; }; then
26373   ac_cv_alignof_long=`cat conftest.val`
26374 else
26375   $as_echo "$as_me: program exited with status $ac_status" >&5
26376 $as_echo "$as_me: failed program was:" >&5
26377 sed 's/^/| /' conftest.$ac_ext >&5
26378
26379 ( exit $ac_status )
26380 if test "$ac_cv_type_long" = yes; then
26381      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26382 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26383 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long
26384 See \`config.log' for more details." >&5
26385 $as_echo "$as_me: error: cannot compute alignment of long
26386 See \`config.log' for more details." >&2;}
26387    { (exit 77); exit 77; }; }; }
26388    else
26389      ac_cv_alignof_long=0
26390    fi
26391 fi
26392 rm -rf conftest.dSYM
26393 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26394 fi
26395 rm -f conftest.val
26396 fi
26397 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_long" >&5
26398 $as_echo "$ac_cv_alignof_long" >&6; }
26399
26400
26401
26402 cat >>confdefs.h <<_ACEOF
26403 #define ALIGNOF_LONG $ac_cv_alignof_long
26404 _ACEOF
26405
26406
26407 if test x"$HAVE_LONG_LONG_INT_64" = x"yes" ; then
26408   # The cast to long int works around a bug in the HP C Compiler,
26409 # see AC_CHECK_SIZEOF for more information.
26410 { $as_echo "$as_me:$LINENO: checking alignment of long long int" >&5
26411 $as_echo_n "checking alignment of long long int... " >&6; }
26412 if test "${ac_cv_alignof_long_long_int+set}" = set; then
26413   $as_echo_n "(cached) " >&6
26414 else
26415   if test "$cross_compiling" = yes; then
26416   # Depending upon the size, compute the lo and hi bounds.
26417 cat >conftest.$ac_ext <<_ACEOF
26418 /* confdefs.h.  */
26419 _ACEOF
26420 cat confdefs.h >>conftest.$ac_ext
26421 cat >>conftest.$ac_ext <<_ACEOF
26422 /* end confdefs.h.  */
26423 $ac_includes_default
26424 #ifndef offsetof
26425 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26426 #endif
26427 typedef struct { char x; long long int y; } ac__type_alignof_;
26428 int
26429 main ()
26430 {
26431 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26432 test_array [0] = 0
26433
26434   ;
26435   return 0;
26436 }
26437 _ACEOF
26438 rm -f conftest.$ac_objext
26439 if { (ac_try="$ac_compile"
26440 case "(($ac_try" in
26441   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26442   *) ac_try_echo=$ac_try;;
26443 esac
26444 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26445 $as_echo "$ac_try_echo") >&5
26446   (eval "$ac_compile") 2>conftest.er1
26447   ac_status=$?
26448   grep -v '^ *+' conftest.er1 >conftest.err
26449   rm -f conftest.er1
26450   cat conftest.err >&5
26451   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26452   (exit $ac_status); } && {
26453          test -z "$ac_c_werror_flag" ||
26454          test ! -s conftest.err
26455        } && test -s conftest.$ac_objext; then
26456   ac_lo=0 ac_mid=0
26457   while :; do
26458     cat >conftest.$ac_ext <<_ACEOF
26459 /* confdefs.h.  */
26460 _ACEOF
26461 cat confdefs.h >>conftest.$ac_ext
26462 cat >>conftest.$ac_ext <<_ACEOF
26463 /* end confdefs.h.  */
26464 $ac_includes_default
26465 #ifndef offsetof
26466 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26467 #endif
26468 typedef struct { char x; long long int y; } ac__type_alignof_;
26469 int
26470 main ()
26471 {
26472 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26473 test_array [0] = 0
26474
26475   ;
26476   return 0;
26477 }
26478 _ACEOF
26479 rm -f conftest.$ac_objext
26480 if { (ac_try="$ac_compile"
26481 case "(($ac_try" in
26482   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26483   *) ac_try_echo=$ac_try;;
26484 esac
26485 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26486 $as_echo "$ac_try_echo") >&5
26487   (eval "$ac_compile") 2>conftest.er1
26488   ac_status=$?
26489   grep -v '^ *+' conftest.er1 >conftest.err
26490   rm -f conftest.er1
26491   cat conftest.err >&5
26492   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26493   (exit $ac_status); } && {
26494          test -z "$ac_c_werror_flag" ||
26495          test ! -s conftest.err
26496        } && test -s conftest.$ac_objext; then
26497   ac_hi=$ac_mid; break
26498 else
26499   $as_echo "$as_me: failed program was:" >&5
26500 sed 's/^/| /' conftest.$ac_ext >&5
26501
26502         ac_lo=`expr $ac_mid + 1`
26503                         if test $ac_lo -le $ac_mid; then
26504                           ac_lo= ac_hi=
26505                           break
26506                         fi
26507                         ac_mid=`expr 2 '*' $ac_mid + 1`
26508 fi
26509
26510 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26511   done
26512 else
26513   $as_echo "$as_me: failed program was:" >&5
26514 sed 's/^/| /' conftest.$ac_ext >&5
26515
26516         cat >conftest.$ac_ext <<_ACEOF
26517 /* confdefs.h.  */
26518 _ACEOF
26519 cat confdefs.h >>conftest.$ac_ext
26520 cat >>conftest.$ac_ext <<_ACEOF
26521 /* end confdefs.h.  */
26522 $ac_includes_default
26523 #ifndef offsetof
26524 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26525 #endif
26526 typedef struct { char x; long long int y; } ac__type_alignof_;
26527 int
26528 main ()
26529 {
26530 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26531 test_array [0] = 0
26532
26533   ;
26534   return 0;
26535 }
26536 _ACEOF
26537 rm -f conftest.$ac_objext
26538 if { (ac_try="$ac_compile"
26539 case "(($ac_try" in
26540   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26541   *) ac_try_echo=$ac_try;;
26542 esac
26543 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26544 $as_echo "$ac_try_echo") >&5
26545   (eval "$ac_compile") 2>conftest.er1
26546   ac_status=$?
26547   grep -v '^ *+' conftest.er1 >conftest.err
26548   rm -f conftest.er1
26549   cat conftest.err >&5
26550   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26551   (exit $ac_status); } && {
26552          test -z "$ac_c_werror_flag" ||
26553          test ! -s conftest.err
26554        } && test -s conftest.$ac_objext; then
26555   ac_hi=-1 ac_mid=-1
26556   while :; do
26557     cat >conftest.$ac_ext <<_ACEOF
26558 /* confdefs.h.  */
26559 _ACEOF
26560 cat confdefs.h >>conftest.$ac_ext
26561 cat >>conftest.$ac_ext <<_ACEOF
26562 /* end confdefs.h.  */
26563 $ac_includes_default
26564 #ifndef offsetof
26565 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26566 #endif
26567 typedef struct { char x; long long int y; } ac__type_alignof_;
26568 int
26569 main ()
26570 {
26571 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26572 test_array [0] = 0
26573
26574   ;
26575   return 0;
26576 }
26577 _ACEOF
26578 rm -f conftest.$ac_objext
26579 if { (ac_try="$ac_compile"
26580 case "(($ac_try" in
26581   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26582   *) ac_try_echo=$ac_try;;
26583 esac
26584 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26585 $as_echo "$ac_try_echo") >&5
26586   (eval "$ac_compile") 2>conftest.er1
26587   ac_status=$?
26588   grep -v '^ *+' conftest.er1 >conftest.err
26589   rm -f conftest.er1
26590   cat conftest.err >&5
26591   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26592   (exit $ac_status); } && {
26593          test -z "$ac_c_werror_flag" ||
26594          test ! -s conftest.err
26595        } && test -s conftest.$ac_objext; then
26596   ac_lo=$ac_mid; break
26597 else
26598   $as_echo "$as_me: failed program was:" >&5
26599 sed 's/^/| /' conftest.$ac_ext >&5
26600
26601         ac_hi=`expr '(' $ac_mid ')' - 1`
26602                         if test $ac_mid -le $ac_hi; then
26603                           ac_lo= ac_hi=
26604                           break
26605                         fi
26606                         ac_mid=`expr 2 '*' $ac_mid`
26607 fi
26608
26609 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26610   done
26611 else
26612   $as_echo "$as_me: failed program was:" >&5
26613 sed 's/^/| /' conftest.$ac_ext >&5
26614
26615         ac_lo= ac_hi=
26616 fi
26617
26618 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26619 fi
26620
26621 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26622 # Binary search between lo and hi bounds.
26623 while test "x$ac_lo" != "x$ac_hi"; do
26624   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
26625   cat >conftest.$ac_ext <<_ACEOF
26626 /* confdefs.h.  */
26627 _ACEOF
26628 cat confdefs.h >>conftest.$ac_ext
26629 cat >>conftest.$ac_ext <<_ACEOF
26630 /* end confdefs.h.  */
26631 $ac_includes_default
26632 #ifndef offsetof
26633 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26634 #endif
26635 typedef struct { char x; long long int y; } ac__type_alignof_;
26636 int
26637 main ()
26638 {
26639 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26640 test_array [0] = 0
26641
26642   ;
26643   return 0;
26644 }
26645 _ACEOF
26646 rm -f conftest.$ac_objext
26647 if { (ac_try="$ac_compile"
26648 case "(($ac_try" in
26649   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26650   *) ac_try_echo=$ac_try;;
26651 esac
26652 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26653 $as_echo "$ac_try_echo") >&5
26654   (eval "$ac_compile") 2>conftest.er1
26655   ac_status=$?
26656   grep -v '^ *+' conftest.er1 >conftest.err
26657   rm -f conftest.er1
26658   cat conftest.err >&5
26659   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26660   (exit $ac_status); } && {
26661          test -z "$ac_c_werror_flag" ||
26662          test ! -s conftest.err
26663        } && test -s conftest.$ac_objext; then
26664   ac_hi=$ac_mid
26665 else
26666   $as_echo "$as_me: failed program was:" >&5
26667 sed 's/^/| /' conftest.$ac_ext >&5
26668
26669         ac_lo=`expr '(' $ac_mid ')' + 1`
26670 fi
26671
26672 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26673 done
26674 case $ac_lo in
26675 ?*) ac_cv_alignof_long_long_int=$ac_lo;;
26676 '') if test "$ac_cv_type_long_long_int" = yes; then
26677      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26678 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26679 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long long int
26680 See \`config.log' for more details." >&5
26681 $as_echo "$as_me: error: cannot compute alignment of long long int
26682 See \`config.log' for more details." >&2;}
26683    { (exit 77); exit 77; }; }; }
26684    else
26685      ac_cv_alignof_long_long_int=0
26686    fi ;;
26687 esac
26688 else
26689   cat >conftest.$ac_ext <<_ACEOF
26690 /* confdefs.h.  */
26691 _ACEOF
26692 cat confdefs.h >>conftest.$ac_ext
26693 cat >>conftest.$ac_ext <<_ACEOF
26694 /* end confdefs.h.  */
26695 $ac_includes_default
26696 #ifndef offsetof
26697 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26698 #endif
26699 typedef struct { char x; long long int y; } ac__type_alignof_;
26700 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
26701 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
26702 #include <stdio.h>
26703 #include <stdlib.h>
26704 int
26705 main ()
26706 {
26707
26708   FILE *f = fopen ("conftest.val", "w");
26709   if (! f)
26710     return 1;
26711   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
26712     {
26713       long int i = longval ();
26714       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26715         return 1;
26716       fprintf (f, "%ld", i);
26717     }
26718   else
26719     {
26720       unsigned long int i = ulongval ();
26721       if (i != ((long int) offsetof (ac__type_alignof_, y)))
26722         return 1;
26723       fprintf (f, "%lu", i);
26724     }
26725   /* Do not output a trailing newline, as this causes \r\n confusion
26726      on some platforms.  */
26727   return ferror (f) || fclose (f) != 0;
26728
26729   ;
26730   return 0;
26731 }
26732 _ACEOF
26733 rm -f conftest$ac_exeext
26734 if { (ac_try="$ac_link"
26735 case "(($ac_try" in
26736   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26737   *) ac_try_echo=$ac_try;;
26738 esac
26739 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26740 $as_echo "$ac_try_echo") >&5
26741   (eval "$ac_link") 2>&5
26742   ac_status=$?
26743   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26744   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
26745   { (case "(($ac_try" in
26746   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26747   *) ac_try_echo=$ac_try;;
26748 esac
26749 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26750 $as_echo "$ac_try_echo") >&5
26751   (eval "$ac_try") 2>&5
26752   ac_status=$?
26753   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26754   (exit $ac_status); }; }; then
26755   ac_cv_alignof_long_long_int=`cat conftest.val`
26756 else
26757   $as_echo "$as_me: program exited with status $ac_status" >&5
26758 $as_echo "$as_me: failed program was:" >&5
26759 sed 's/^/| /' conftest.$ac_ext >&5
26760
26761 ( exit $ac_status )
26762 if test "$ac_cv_type_long_long_int" = yes; then
26763      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
26764 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
26765 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of long long int
26766 See \`config.log' for more details." >&5
26767 $as_echo "$as_me: error: cannot compute alignment of long long int
26768 See \`config.log' for more details." >&2;}
26769    { (exit 77); exit 77; }; }; }
26770    else
26771      ac_cv_alignof_long_long_int=0
26772    fi
26773 fi
26774 rm -rf conftest.dSYM
26775 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
26776 fi
26777 rm -f conftest.val
26778 fi
26779 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_long_long_int" >&5
26780 $as_echo "$ac_cv_alignof_long_long_int" >&6; }
26781
26782
26783
26784 cat >>confdefs.h <<_ACEOF
26785 #define ALIGNOF_LONG_LONG_INT $ac_cv_alignof_long_long_int
26786 _ACEOF
26787
26788
26789 fi
26790 # The cast to long int works around a bug in the HP C Compiler,
26791 # see AC_CHECK_SIZEOF for more information.
26792 { $as_echo "$as_me:$LINENO: checking alignment of double" >&5
26793 $as_echo_n "checking alignment of double... " >&6; }
26794 if test "${ac_cv_alignof_double+set}" = set; then
26795   $as_echo_n "(cached) " >&6
26796 else
26797   if test "$cross_compiling" = yes; then
26798   # Depending upon the size, compute the lo and hi bounds.
26799 cat >conftest.$ac_ext <<_ACEOF
26800 /* confdefs.h.  */
26801 _ACEOF
26802 cat confdefs.h >>conftest.$ac_ext
26803 cat >>conftest.$ac_ext <<_ACEOF
26804 /* end confdefs.h.  */
26805 $ac_includes_default
26806 #ifndef offsetof
26807 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26808 #endif
26809 typedef struct { char x; double y; } ac__type_alignof_;
26810 int
26811 main ()
26812 {
26813 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= 0)];
26814 test_array [0] = 0
26815
26816   ;
26817   return 0;
26818 }
26819 _ACEOF
26820 rm -f conftest.$ac_objext
26821 if { (ac_try="$ac_compile"
26822 case "(($ac_try" in
26823   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26824   *) ac_try_echo=$ac_try;;
26825 esac
26826 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26827 $as_echo "$ac_try_echo") >&5
26828   (eval "$ac_compile") 2>conftest.er1
26829   ac_status=$?
26830   grep -v '^ *+' conftest.er1 >conftest.err
26831   rm -f conftest.er1
26832   cat conftest.err >&5
26833   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26834   (exit $ac_status); } && {
26835          test -z "$ac_c_werror_flag" ||
26836          test ! -s conftest.err
26837        } && test -s conftest.$ac_objext; then
26838   ac_lo=0 ac_mid=0
26839   while :; do
26840     cat >conftest.$ac_ext <<_ACEOF
26841 /* confdefs.h.  */
26842 _ACEOF
26843 cat confdefs.h >>conftest.$ac_ext
26844 cat >>conftest.$ac_ext <<_ACEOF
26845 /* end confdefs.h.  */
26846 $ac_includes_default
26847 #ifndef offsetof
26848 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26849 #endif
26850 typedef struct { char x; double y; } ac__type_alignof_;
26851 int
26852 main ()
26853 {
26854 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
26855 test_array [0] = 0
26856
26857   ;
26858   return 0;
26859 }
26860 _ACEOF
26861 rm -f conftest.$ac_objext
26862 if { (ac_try="$ac_compile"
26863 case "(($ac_try" in
26864   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26865   *) ac_try_echo=$ac_try;;
26866 esac
26867 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26868 $as_echo "$ac_try_echo") >&5
26869   (eval "$ac_compile") 2>conftest.er1
26870   ac_status=$?
26871   grep -v '^ *+' conftest.er1 >conftest.err
26872   rm -f conftest.er1
26873   cat conftest.err >&5
26874   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26875   (exit $ac_status); } && {
26876          test -z "$ac_c_werror_flag" ||
26877          test ! -s conftest.err
26878        } && test -s conftest.$ac_objext; then
26879   ac_hi=$ac_mid; break
26880 else
26881   $as_echo "$as_me: failed program was:" >&5
26882 sed 's/^/| /' conftest.$ac_ext >&5
26883
26884         ac_lo=`expr $ac_mid + 1`
26885                         if test $ac_lo -le $ac_mid; then
26886                           ac_lo= ac_hi=
26887                           break
26888                         fi
26889                         ac_mid=`expr 2 '*' $ac_mid + 1`
26890 fi
26891
26892 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26893   done
26894 else
26895   $as_echo "$as_me: failed program was:" >&5
26896 sed 's/^/| /' conftest.$ac_ext >&5
26897
26898         cat >conftest.$ac_ext <<_ACEOF
26899 /* confdefs.h.  */
26900 _ACEOF
26901 cat confdefs.h >>conftest.$ac_ext
26902 cat >>conftest.$ac_ext <<_ACEOF
26903 /* end confdefs.h.  */
26904 $ac_includes_default
26905 #ifndef offsetof
26906 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26907 #endif
26908 typedef struct { char x; double y; } ac__type_alignof_;
26909 int
26910 main ()
26911 {
26912 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) < 0)];
26913 test_array [0] = 0
26914
26915   ;
26916   return 0;
26917 }
26918 _ACEOF
26919 rm -f conftest.$ac_objext
26920 if { (ac_try="$ac_compile"
26921 case "(($ac_try" in
26922   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26923   *) ac_try_echo=$ac_try;;
26924 esac
26925 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26926 $as_echo "$ac_try_echo") >&5
26927   (eval "$ac_compile") 2>conftest.er1
26928   ac_status=$?
26929   grep -v '^ *+' conftest.er1 >conftest.err
26930   rm -f conftest.er1
26931   cat conftest.err >&5
26932   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26933   (exit $ac_status); } && {
26934          test -z "$ac_c_werror_flag" ||
26935          test ! -s conftest.err
26936        } && test -s conftest.$ac_objext; then
26937   ac_hi=-1 ac_mid=-1
26938   while :; do
26939     cat >conftest.$ac_ext <<_ACEOF
26940 /* confdefs.h.  */
26941 _ACEOF
26942 cat confdefs.h >>conftest.$ac_ext
26943 cat >>conftest.$ac_ext <<_ACEOF
26944 /* end confdefs.h.  */
26945 $ac_includes_default
26946 #ifndef offsetof
26947 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
26948 #endif
26949 typedef struct { char x; double y; } ac__type_alignof_;
26950 int
26951 main ()
26952 {
26953 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) >= $ac_mid)];
26954 test_array [0] = 0
26955
26956   ;
26957   return 0;
26958 }
26959 _ACEOF
26960 rm -f conftest.$ac_objext
26961 if { (ac_try="$ac_compile"
26962 case "(($ac_try" in
26963   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
26964   *) ac_try_echo=$ac_try;;
26965 esac
26966 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
26967 $as_echo "$ac_try_echo") >&5
26968   (eval "$ac_compile") 2>conftest.er1
26969   ac_status=$?
26970   grep -v '^ *+' conftest.er1 >conftest.err
26971   rm -f conftest.er1
26972   cat conftest.err >&5
26973   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
26974   (exit $ac_status); } && {
26975          test -z "$ac_c_werror_flag" ||
26976          test ! -s conftest.err
26977        } && test -s conftest.$ac_objext; then
26978   ac_lo=$ac_mid; break
26979 else
26980   $as_echo "$as_me: failed program was:" >&5
26981 sed 's/^/| /' conftest.$ac_ext >&5
26982
26983         ac_hi=`expr '(' $ac_mid ')' - 1`
26984                         if test $ac_mid -le $ac_hi; then
26985                           ac_lo= ac_hi=
26986                           break
26987                         fi
26988                         ac_mid=`expr 2 '*' $ac_mid`
26989 fi
26990
26991 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
26992   done
26993 else
26994   $as_echo "$as_me: failed program was:" >&5
26995 sed 's/^/| /' conftest.$ac_ext >&5
26996
26997         ac_lo= ac_hi=
26998 fi
26999
27000 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27001 fi
27002
27003 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27004 # Binary search between lo and hi bounds.
27005 while test "x$ac_lo" != "x$ac_hi"; do
27006   ac_mid=`expr '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo`
27007   cat >conftest.$ac_ext <<_ACEOF
27008 /* confdefs.h.  */
27009 _ACEOF
27010 cat confdefs.h >>conftest.$ac_ext
27011 cat >>conftest.$ac_ext <<_ACEOF
27012 /* end confdefs.h.  */
27013 $ac_includes_default
27014 #ifndef offsetof
27015 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27016 #endif
27017 typedef struct { char x; double y; } ac__type_alignof_;
27018 int
27019 main ()
27020 {
27021 static int test_array [1 - 2 * !(((long int) offsetof (ac__type_alignof_, y)) <= $ac_mid)];
27022 test_array [0] = 0
27023
27024   ;
27025   return 0;
27026 }
27027 _ACEOF
27028 rm -f conftest.$ac_objext
27029 if { (ac_try="$ac_compile"
27030 case "(($ac_try" in
27031   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27032   *) ac_try_echo=$ac_try;;
27033 esac
27034 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27035 $as_echo "$ac_try_echo") >&5
27036   (eval "$ac_compile") 2>conftest.er1
27037   ac_status=$?
27038   grep -v '^ *+' conftest.er1 >conftest.err
27039   rm -f conftest.er1
27040   cat conftest.err >&5
27041   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27042   (exit $ac_status); } && {
27043          test -z "$ac_c_werror_flag" ||
27044          test ! -s conftest.err
27045        } && test -s conftest.$ac_objext; then
27046   ac_hi=$ac_mid
27047 else
27048   $as_echo "$as_me: failed program was:" >&5
27049 sed 's/^/| /' conftest.$ac_ext >&5
27050
27051         ac_lo=`expr '(' $ac_mid ')' + 1`
27052 fi
27053
27054 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27055 done
27056 case $ac_lo in
27057 ?*) ac_cv_alignof_double=$ac_lo;;
27058 '') if test "$ac_cv_type_double" = yes; then
27059      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27060 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27061 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of double
27062 See \`config.log' for more details." >&5
27063 $as_echo "$as_me: error: cannot compute alignment of double
27064 See \`config.log' for more details." >&2;}
27065    { (exit 77); exit 77; }; }; }
27066    else
27067      ac_cv_alignof_double=0
27068    fi ;;
27069 esac
27070 else
27071   cat >conftest.$ac_ext <<_ACEOF
27072 /* confdefs.h.  */
27073 _ACEOF
27074 cat confdefs.h >>conftest.$ac_ext
27075 cat >>conftest.$ac_ext <<_ACEOF
27076 /* end confdefs.h.  */
27077 $ac_includes_default
27078 #ifndef offsetof
27079 # define offsetof(type, member) ((char *) &((type *) 0)->member - (char *) 0)
27080 #endif
27081 typedef struct { char x; double y; } ac__type_alignof_;
27082 static long int longval () { return (long int) offsetof (ac__type_alignof_, y); }
27083 static unsigned long int ulongval () { return (long int) offsetof (ac__type_alignof_, y); }
27084 #include <stdio.h>
27085 #include <stdlib.h>
27086 int
27087 main ()
27088 {
27089
27090   FILE *f = fopen ("conftest.val", "w");
27091   if (! f)
27092     return 1;
27093   if (((long int) offsetof (ac__type_alignof_, y)) < 0)
27094     {
27095       long int i = longval ();
27096       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27097         return 1;
27098       fprintf (f, "%ld", i);
27099     }
27100   else
27101     {
27102       unsigned long int i = ulongval ();
27103       if (i != ((long int) offsetof (ac__type_alignof_, y)))
27104         return 1;
27105       fprintf (f, "%lu", i);
27106     }
27107   /* Do not output a trailing newline, as this causes \r\n confusion
27108      on some platforms.  */
27109   return ferror (f) || fclose (f) != 0;
27110
27111   ;
27112   return 0;
27113 }
27114 _ACEOF
27115 rm -f conftest$ac_exeext
27116 if { (ac_try="$ac_link"
27117 case "(($ac_try" in
27118   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27119   *) ac_try_echo=$ac_try;;
27120 esac
27121 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27122 $as_echo "$ac_try_echo") >&5
27123   (eval "$ac_link") 2>&5
27124   ac_status=$?
27125   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27126   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27127   { (case "(($ac_try" in
27128   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27129   *) ac_try_echo=$ac_try;;
27130 esac
27131 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27132 $as_echo "$ac_try_echo") >&5
27133   (eval "$ac_try") 2>&5
27134   ac_status=$?
27135   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27136   (exit $ac_status); }; }; then
27137   ac_cv_alignof_double=`cat conftest.val`
27138 else
27139   $as_echo "$as_me: program exited with status $ac_status" >&5
27140 $as_echo "$as_me: failed program was:" >&5
27141 sed 's/^/| /' conftest.$ac_ext >&5
27142
27143 ( exit $ac_status )
27144 if test "$ac_cv_type_double" = yes; then
27145      { { $as_echo "$as_me:$LINENO: error: in \`$ac_pwd':" >&5
27146 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
27147 { { $as_echo "$as_me:$LINENO: error: cannot compute alignment of double
27148 See \`config.log' for more details." >&5
27149 $as_echo "$as_me: error: cannot compute alignment of double
27150 See \`config.log' for more details." >&2;}
27151    { (exit 77); exit 77; }; }; }
27152    else
27153      ac_cv_alignof_double=0
27154    fi
27155 fi
27156 rm -rf conftest.dSYM
27157 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27158 fi
27159 rm -f conftest.val
27160 fi
27161 { $as_echo "$as_me:$LINENO: result: $ac_cv_alignof_double" >&5
27162 $as_echo "$ac_cv_alignof_double" >&6; }
27163
27164
27165
27166 cat >>confdefs.h <<_ACEOF
27167 #define ALIGNOF_DOUBLE $ac_cv_alignof_double
27168 _ACEOF
27169
27170
27171
27172 # Compute maximum alignment of any basic type.
27173 # We assume long's alignment is at least as strong as char, short, or int;
27174 # but we must check long long (if it exists) and double.
27175
27176 MAX_ALIGNOF=$ac_cv_alignof_long
27177 if test $MAX_ALIGNOF -lt $ac_cv_alignof_double ; then
27178   MAX_ALIGNOF=$ac_cv_alignof_double
27179 fi
27180 if test x"$HAVE_LONG_LONG_INT_64" = xyes && test $MAX_ALIGNOF -lt $ac_cv_alignof_long_long_int ; then
27181   MAX_ALIGNOF="$ac_cv_alignof_long_long_int"
27182 fi
27183
27184 cat >>confdefs.h <<_ACEOF
27185 #define MAXIMUM_ALIGNOF $MAX_ALIGNOF
27186 _ACEOF
27187
27188
27189
27190 # Some platforms predefine the types int8, int16, etc.  Only check
27191 # a (hopefully) representative subset.
27192 { $as_echo "$as_me:$LINENO: checking for int8" >&5
27193 $as_echo_n "checking for int8... " >&6; }
27194 if test "${ac_cv_type_int8+set}" = set; then
27195   $as_echo_n "(cached) " >&6
27196 else
27197   ac_cv_type_int8=no
27198 cat >conftest.$ac_ext <<_ACEOF
27199 /* confdefs.h.  */
27200 _ACEOF
27201 cat confdefs.h >>conftest.$ac_ext
27202 cat >>conftest.$ac_ext <<_ACEOF
27203 /* end confdefs.h.  */
27204 #include <stdio.h>
27205 #ifdef HAVE_SUPPORTDEFS_H
27206 #include <SupportDefs.h>
27207 #endif
27208
27209 int
27210 main ()
27211 {
27212 if (sizeof (int8))
27213        return 0;
27214   ;
27215   return 0;
27216 }
27217 _ACEOF
27218 rm -f conftest.$ac_objext
27219 if { (ac_try="$ac_compile"
27220 case "(($ac_try" in
27221   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27222   *) ac_try_echo=$ac_try;;
27223 esac
27224 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27225 $as_echo "$ac_try_echo") >&5
27226   (eval "$ac_compile") 2>conftest.er1
27227   ac_status=$?
27228   grep -v '^ *+' conftest.er1 >conftest.err
27229   rm -f conftest.er1
27230   cat conftest.err >&5
27231   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27232   (exit $ac_status); } && {
27233          test -z "$ac_c_werror_flag" ||
27234          test ! -s conftest.err
27235        } && test -s conftest.$ac_objext; then
27236   cat >conftest.$ac_ext <<_ACEOF
27237 /* confdefs.h.  */
27238 _ACEOF
27239 cat confdefs.h >>conftest.$ac_ext
27240 cat >>conftest.$ac_ext <<_ACEOF
27241 /* end confdefs.h.  */
27242 #include <stdio.h>
27243 #ifdef HAVE_SUPPORTDEFS_H
27244 #include <SupportDefs.h>
27245 #endif
27246
27247 int
27248 main ()
27249 {
27250 if (sizeof ((int8)))
27251           return 0;
27252   ;
27253   return 0;
27254 }
27255 _ACEOF
27256 rm -f conftest.$ac_objext
27257 if { (ac_try="$ac_compile"
27258 case "(($ac_try" in
27259   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27260   *) ac_try_echo=$ac_try;;
27261 esac
27262 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27263 $as_echo "$ac_try_echo") >&5
27264   (eval "$ac_compile") 2>conftest.er1
27265   ac_status=$?
27266   grep -v '^ *+' conftest.er1 >conftest.err
27267   rm -f conftest.er1
27268   cat conftest.err >&5
27269   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27270   (exit $ac_status); } && {
27271          test -z "$ac_c_werror_flag" ||
27272          test ! -s conftest.err
27273        } && test -s conftest.$ac_objext; then
27274   :
27275 else
27276   $as_echo "$as_me: failed program was:" >&5
27277 sed 's/^/| /' conftest.$ac_ext >&5
27278
27279         ac_cv_type_int8=yes
27280 fi
27281
27282 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27283 else
27284   $as_echo "$as_me: failed program was:" >&5
27285 sed 's/^/| /' conftest.$ac_ext >&5
27286
27287
27288 fi
27289
27290 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27291 fi
27292 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_int8" >&5
27293 $as_echo "$ac_cv_type_int8" >&6; }
27294 if test "x$ac_cv_type_int8" = x""yes; then
27295
27296 cat >>confdefs.h <<_ACEOF
27297 #define HAVE_INT8 1
27298 _ACEOF
27299
27300
27301 fi
27302 { $as_echo "$as_me:$LINENO: checking for uint8" >&5
27303 $as_echo_n "checking for uint8... " >&6; }
27304 if test "${ac_cv_type_uint8+set}" = set; then
27305   $as_echo_n "(cached) " >&6
27306 else
27307   ac_cv_type_uint8=no
27308 cat >conftest.$ac_ext <<_ACEOF
27309 /* confdefs.h.  */
27310 _ACEOF
27311 cat confdefs.h >>conftest.$ac_ext
27312 cat >>conftest.$ac_ext <<_ACEOF
27313 /* end confdefs.h.  */
27314 #include <stdio.h>
27315 #ifdef HAVE_SUPPORTDEFS_H
27316 #include <SupportDefs.h>
27317 #endif
27318
27319 int
27320 main ()
27321 {
27322 if (sizeof (uint8))
27323        return 0;
27324   ;
27325   return 0;
27326 }
27327 _ACEOF
27328 rm -f conftest.$ac_objext
27329 if { (ac_try="$ac_compile"
27330 case "(($ac_try" in
27331   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27332   *) ac_try_echo=$ac_try;;
27333 esac
27334 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27335 $as_echo "$ac_try_echo") >&5
27336   (eval "$ac_compile") 2>conftest.er1
27337   ac_status=$?
27338   grep -v '^ *+' conftest.er1 >conftest.err
27339   rm -f conftest.er1
27340   cat conftest.err >&5
27341   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27342   (exit $ac_status); } && {
27343          test -z "$ac_c_werror_flag" ||
27344          test ! -s conftest.err
27345        } && test -s conftest.$ac_objext; then
27346   cat >conftest.$ac_ext <<_ACEOF
27347 /* confdefs.h.  */
27348 _ACEOF
27349 cat confdefs.h >>conftest.$ac_ext
27350 cat >>conftest.$ac_ext <<_ACEOF
27351 /* end confdefs.h.  */
27352 #include <stdio.h>
27353 #ifdef HAVE_SUPPORTDEFS_H
27354 #include <SupportDefs.h>
27355 #endif
27356
27357 int
27358 main ()
27359 {
27360 if (sizeof ((uint8)))
27361           return 0;
27362   ;
27363   return 0;
27364 }
27365 _ACEOF
27366 rm -f conftest.$ac_objext
27367 if { (ac_try="$ac_compile"
27368 case "(($ac_try" in
27369   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27370   *) ac_try_echo=$ac_try;;
27371 esac
27372 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27373 $as_echo "$ac_try_echo") >&5
27374   (eval "$ac_compile") 2>conftest.er1
27375   ac_status=$?
27376   grep -v '^ *+' conftest.er1 >conftest.err
27377   rm -f conftest.er1
27378   cat conftest.err >&5
27379   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27380   (exit $ac_status); } && {
27381          test -z "$ac_c_werror_flag" ||
27382          test ! -s conftest.err
27383        } && test -s conftest.$ac_objext; then
27384   :
27385 else
27386   $as_echo "$as_me: failed program was:" >&5
27387 sed 's/^/| /' conftest.$ac_ext >&5
27388
27389         ac_cv_type_uint8=yes
27390 fi
27391
27392 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27393 else
27394   $as_echo "$as_me: failed program was:" >&5
27395 sed 's/^/| /' conftest.$ac_ext >&5
27396
27397
27398 fi
27399
27400 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27401 fi
27402 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uint8" >&5
27403 $as_echo "$ac_cv_type_uint8" >&6; }
27404 if test "x$ac_cv_type_uint8" = x""yes; then
27405
27406 cat >>confdefs.h <<_ACEOF
27407 #define HAVE_UINT8 1
27408 _ACEOF
27409
27410
27411 fi
27412 { $as_echo "$as_me:$LINENO: checking for int64" >&5
27413 $as_echo_n "checking for int64... " >&6; }
27414 if test "${ac_cv_type_int64+set}" = set; then
27415   $as_echo_n "(cached) " >&6
27416 else
27417   ac_cv_type_int64=no
27418 cat >conftest.$ac_ext <<_ACEOF
27419 /* confdefs.h.  */
27420 _ACEOF
27421 cat confdefs.h >>conftest.$ac_ext
27422 cat >>conftest.$ac_ext <<_ACEOF
27423 /* end confdefs.h.  */
27424 #include <stdio.h>
27425 #ifdef HAVE_SUPPORTDEFS_H
27426 #include <SupportDefs.h>
27427 #endif
27428
27429 int
27430 main ()
27431 {
27432 if (sizeof (int64))
27433        return 0;
27434   ;
27435   return 0;
27436 }
27437 _ACEOF
27438 rm -f conftest.$ac_objext
27439 if { (ac_try="$ac_compile"
27440 case "(($ac_try" in
27441   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27442   *) ac_try_echo=$ac_try;;
27443 esac
27444 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27445 $as_echo "$ac_try_echo") >&5
27446   (eval "$ac_compile") 2>conftest.er1
27447   ac_status=$?
27448   grep -v '^ *+' conftest.er1 >conftest.err
27449   rm -f conftest.er1
27450   cat conftest.err >&5
27451   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27452   (exit $ac_status); } && {
27453          test -z "$ac_c_werror_flag" ||
27454          test ! -s conftest.err
27455        } && test -s conftest.$ac_objext; then
27456   cat >conftest.$ac_ext <<_ACEOF
27457 /* confdefs.h.  */
27458 _ACEOF
27459 cat confdefs.h >>conftest.$ac_ext
27460 cat >>conftest.$ac_ext <<_ACEOF
27461 /* end confdefs.h.  */
27462 #include <stdio.h>
27463 #ifdef HAVE_SUPPORTDEFS_H
27464 #include <SupportDefs.h>
27465 #endif
27466
27467 int
27468 main ()
27469 {
27470 if (sizeof ((int64)))
27471           return 0;
27472   ;
27473   return 0;
27474 }
27475 _ACEOF
27476 rm -f conftest.$ac_objext
27477 if { (ac_try="$ac_compile"
27478 case "(($ac_try" in
27479   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27480   *) ac_try_echo=$ac_try;;
27481 esac
27482 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27483 $as_echo "$ac_try_echo") >&5
27484   (eval "$ac_compile") 2>conftest.er1
27485   ac_status=$?
27486   grep -v '^ *+' conftest.er1 >conftest.err
27487   rm -f conftest.er1
27488   cat conftest.err >&5
27489   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27490   (exit $ac_status); } && {
27491          test -z "$ac_c_werror_flag" ||
27492          test ! -s conftest.err
27493        } && test -s conftest.$ac_objext; then
27494   :
27495 else
27496   $as_echo "$as_me: failed program was:" >&5
27497 sed 's/^/| /' conftest.$ac_ext >&5
27498
27499         ac_cv_type_int64=yes
27500 fi
27501
27502 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27503 else
27504   $as_echo "$as_me: failed program was:" >&5
27505 sed 's/^/| /' conftest.$ac_ext >&5
27506
27507
27508 fi
27509
27510 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27511 fi
27512 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_int64" >&5
27513 $as_echo "$ac_cv_type_int64" >&6; }
27514 if test "x$ac_cv_type_int64" = x""yes; then
27515
27516 cat >>confdefs.h <<_ACEOF
27517 #define HAVE_INT64 1
27518 _ACEOF
27519
27520
27521 fi
27522 { $as_echo "$as_me:$LINENO: checking for uint64" >&5
27523 $as_echo_n "checking for uint64... " >&6; }
27524 if test "${ac_cv_type_uint64+set}" = set; then
27525   $as_echo_n "(cached) " >&6
27526 else
27527   ac_cv_type_uint64=no
27528 cat >conftest.$ac_ext <<_ACEOF
27529 /* confdefs.h.  */
27530 _ACEOF
27531 cat confdefs.h >>conftest.$ac_ext
27532 cat >>conftest.$ac_ext <<_ACEOF
27533 /* end confdefs.h.  */
27534 #include <stdio.h>
27535 #ifdef HAVE_SUPPORTDEFS_H
27536 #include <SupportDefs.h>
27537 #endif
27538
27539 int
27540 main ()
27541 {
27542 if (sizeof (uint64))
27543        return 0;
27544   ;
27545   return 0;
27546 }
27547 _ACEOF
27548 rm -f conftest.$ac_objext
27549 if { (ac_try="$ac_compile"
27550 case "(($ac_try" in
27551   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27552   *) ac_try_echo=$ac_try;;
27553 esac
27554 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27555 $as_echo "$ac_try_echo") >&5
27556   (eval "$ac_compile") 2>conftest.er1
27557   ac_status=$?
27558   grep -v '^ *+' conftest.er1 >conftest.err
27559   rm -f conftest.er1
27560   cat conftest.err >&5
27561   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27562   (exit $ac_status); } && {
27563          test -z "$ac_c_werror_flag" ||
27564          test ! -s conftest.err
27565        } && test -s conftest.$ac_objext; then
27566   cat >conftest.$ac_ext <<_ACEOF
27567 /* confdefs.h.  */
27568 _ACEOF
27569 cat confdefs.h >>conftest.$ac_ext
27570 cat >>conftest.$ac_ext <<_ACEOF
27571 /* end confdefs.h.  */
27572 #include <stdio.h>
27573 #ifdef HAVE_SUPPORTDEFS_H
27574 #include <SupportDefs.h>
27575 #endif
27576
27577 int
27578 main ()
27579 {
27580 if (sizeof ((uint64)))
27581           return 0;
27582   ;
27583   return 0;
27584 }
27585 _ACEOF
27586 rm -f conftest.$ac_objext
27587 if { (ac_try="$ac_compile"
27588 case "(($ac_try" in
27589   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27590   *) ac_try_echo=$ac_try;;
27591 esac
27592 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27593 $as_echo "$ac_try_echo") >&5
27594   (eval "$ac_compile") 2>conftest.er1
27595   ac_status=$?
27596   grep -v '^ *+' conftest.er1 >conftest.err
27597   rm -f conftest.er1
27598   cat conftest.err >&5
27599   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27600   (exit $ac_status); } && {
27601          test -z "$ac_c_werror_flag" ||
27602          test ! -s conftest.err
27603        } && test -s conftest.$ac_objext; then
27604   :
27605 else
27606   $as_echo "$as_me: failed program was:" >&5
27607 sed 's/^/| /' conftest.$ac_ext >&5
27608
27609         ac_cv_type_uint64=yes
27610 fi
27611
27612 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27613 else
27614   $as_echo "$as_me: failed program was:" >&5
27615 sed 's/^/| /' conftest.$ac_ext >&5
27616
27617
27618 fi
27619
27620 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27621 fi
27622 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_uint64" >&5
27623 $as_echo "$ac_cv_type_uint64" >&6; }
27624 if test "x$ac_cv_type_uint64" = x""yes; then
27625
27626 cat >>confdefs.h <<_ACEOF
27627 #define HAVE_UINT64 1
27628 _ACEOF
27629
27630
27631 fi
27632
27633
27634 # We also check for sig_atomic_t, which *should* be defined per ANSI
27635 # C, but is missing on some old platforms.
27636 { $as_echo "$as_me:$LINENO: checking for sig_atomic_t" >&5
27637 $as_echo_n "checking for sig_atomic_t... " >&6; }
27638 if test "${ac_cv_type_sig_atomic_t+set}" = set; then
27639   $as_echo_n "(cached) " >&6
27640 else
27641   ac_cv_type_sig_atomic_t=no
27642 cat >conftest.$ac_ext <<_ACEOF
27643 /* confdefs.h.  */
27644 _ACEOF
27645 cat confdefs.h >>conftest.$ac_ext
27646 cat >>conftest.$ac_ext <<_ACEOF
27647 /* end confdefs.h.  */
27648 #include <signal.h>
27649
27650 int
27651 main ()
27652 {
27653 if (sizeof (sig_atomic_t))
27654        return 0;
27655   ;
27656   return 0;
27657 }
27658 _ACEOF
27659 rm -f conftest.$ac_objext
27660 if { (ac_try="$ac_compile"
27661 case "(($ac_try" in
27662   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27663   *) ac_try_echo=$ac_try;;
27664 esac
27665 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27666 $as_echo "$ac_try_echo") >&5
27667   (eval "$ac_compile") 2>conftest.er1
27668   ac_status=$?
27669   grep -v '^ *+' conftest.er1 >conftest.err
27670   rm -f conftest.er1
27671   cat conftest.err >&5
27672   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27673   (exit $ac_status); } && {
27674          test -z "$ac_c_werror_flag" ||
27675          test ! -s conftest.err
27676        } && test -s conftest.$ac_objext; then
27677   cat >conftest.$ac_ext <<_ACEOF
27678 /* confdefs.h.  */
27679 _ACEOF
27680 cat confdefs.h >>conftest.$ac_ext
27681 cat >>conftest.$ac_ext <<_ACEOF
27682 /* end confdefs.h.  */
27683 #include <signal.h>
27684
27685 int
27686 main ()
27687 {
27688 if (sizeof ((sig_atomic_t)))
27689           return 0;
27690   ;
27691   return 0;
27692 }
27693 _ACEOF
27694 rm -f conftest.$ac_objext
27695 if { (ac_try="$ac_compile"
27696 case "(($ac_try" in
27697   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27698   *) ac_try_echo=$ac_try;;
27699 esac
27700 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27701 $as_echo "$ac_try_echo") >&5
27702   (eval "$ac_compile") 2>conftest.er1
27703   ac_status=$?
27704   grep -v '^ *+' conftest.er1 >conftest.err
27705   rm -f conftest.er1
27706   cat conftest.err >&5
27707   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27708   (exit $ac_status); } && {
27709          test -z "$ac_c_werror_flag" ||
27710          test ! -s conftest.err
27711        } && test -s conftest.$ac_objext; then
27712   :
27713 else
27714   $as_echo "$as_me: failed program was:" >&5
27715 sed 's/^/| /' conftest.$ac_ext >&5
27716
27717         ac_cv_type_sig_atomic_t=yes
27718 fi
27719
27720 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27721 else
27722   $as_echo "$as_me: failed program was:" >&5
27723 sed 's/^/| /' conftest.$ac_ext >&5
27724
27725
27726 fi
27727
27728 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
27729 fi
27730 { $as_echo "$as_me:$LINENO: result: $ac_cv_type_sig_atomic_t" >&5
27731 $as_echo "$ac_cv_type_sig_atomic_t" >&6; }
27732 if test "x$ac_cv_type_sig_atomic_t" = x""yes; then
27733
27734 cat >>confdefs.h <<_ACEOF
27735 #define HAVE_SIG_ATOMIC_T 1
27736 _ACEOF
27737
27738
27739 fi
27740
27741
27742
27743 if test "$PORTNAME" != "win32"
27744 then
27745 { $as_echo "$as_me:$LINENO: checking for POSIX signal interface" >&5
27746 $as_echo_n "checking for POSIX signal interface... " >&6; }
27747 if test "${pgac_cv_func_posix_signals+set}" = set; then
27748   $as_echo_n "(cached) " >&6
27749 else
27750   cat >conftest.$ac_ext <<_ACEOF
27751 /* confdefs.h.  */
27752 _ACEOF
27753 cat confdefs.h >>conftest.$ac_ext
27754 cat >>conftest.$ac_ext <<_ACEOF
27755 /* end confdefs.h.  */
27756 #include <signal.h>
27757
27758 int
27759 main ()
27760 {
27761 struct sigaction act, oact;
27762 sigemptyset(&act.sa_mask);
27763 act.sa_flags = SA_RESTART;
27764 sigaction(0, &act, &oact);
27765   ;
27766   return 0;
27767 }
27768 _ACEOF
27769 rm -f conftest.$ac_objext conftest$ac_exeext
27770 if { (ac_try="$ac_link"
27771 case "(($ac_try" in
27772   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27773   *) ac_try_echo=$ac_try;;
27774 esac
27775 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27776 $as_echo "$ac_try_echo") >&5
27777   (eval "$ac_link") 2>conftest.er1
27778   ac_status=$?
27779   grep -v '^ *+' conftest.er1 >conftest.err
27780   rm -f conftest.er1
27781   cat conftest.err >&5
27782   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27783   (exit $ac_status); } && {
27784          test -z "$ac_c_werror_flag" ||
27785          test ! -s conftest.err
27786        } && test -s conftest$ac_exeext && {
27787          test "$cross_compiling" = yes ||
27788          $as_test_x conftest$ac_exeext
27789        }; then
27790   pgac_cv_func_posix_signals=yes
27791 else
27792   $as_echo "$as_me: failed program was:" >&5
27793 sed 's/^/| /' conftest.$ac_ext >&5
27794
27795         pgac_cv_func_posix_signals=no
27796 fi
27797
27798 rm -rf conftest.dSYM
27799 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
27800       conftest$ac_exeext conftest.$ac_ext
27801 fi
27802 { $as_echo "$as_me:$LINENO: result: $pgac_cv_func_posix_signals" >&5
27803 $as_echo "$pgac_cv_func_posix_signals" >&6; }
27804 if test x"$pgac_cv_func_posix_signals" = xyes ; then
27805
27806 cat >>confdefs.h <<\_ACEOF
27807 #define HAVE_POSIX_SIGNALS /**/
27808 _ACEOF
27809
27810 fi
27811 HAVE_POSIX_SIGNALS=$pgac_cv_func_posix_signals
27812
27813 if test "$pgac_cv_func_posix_signals" != yes -a "$enable_thread_safety" = yes; then
27814   { { $as_echo "$as_me:$LINENO: error:
27815 Thread-safety requires POSIX signals, which are not supported by this
27816 operating system;  use --disable-thread-safety to disable thread safety." >&5
27817 $as_echo "$as_me: error:
27818 Thread-safety requires POSIX signals, which are not supported by this
27819 operating system;  use --disable-thread-safety to disable thread safety." >&2;}
27820    { (exit 1); exit 1; }; }
27821 fi
27822 fi
27823
27824 # SunOS doesn't handle negative byte comparisons properly with +/- return
27825 { $as_echo "$as_me:$LINENO: checking for working memcmp" >&5
27826 $as_echo_n "checking for working memcmp... " >&6; }
27827 if test "${ac_cv_func_memcmp_working+set}" = set; then
27828   $as_echo_n "(cached) " >&6
27829 else
27830   if test "$cross_compiling" = yes; then
27831   ac_cv_func_memcmp_working=no
27832 else
27833   cat >conftest.$ac_ext <<_ACEOF
27834 /* confdefs.h.  */
27835 _ACEOF
27836 cat confdefs.h >>conftest.$ac_ext
27837 cat >>conftest.$ac_ext <<_ACEOF
27838 /* end confdefs.h.  */
27839 $ac_includes_default
27840 int
27841 main ()
27842 {
27843
27844   /* Some versions of memcmp are not 8-bit clean.  */
27845   char c0 = '\100', c1 = '\200', c2 = '\201';
27846   if (memcmp(&c0, &c2, 1) >= 0 || memcmp(&c1, &c2, 1) >= 0)
27847     return 1;
27848
27849   /* The Next x86 OpenStep bug shows up only when comparing 16 bytes
27850      or more and with at least one buffer not starting on a 4-byte boundary.
27851      William Lewis provided this test program.   */
27852   {
27853     char foo[21];
27854     char bar[21];
27855     int i;
27856     for (i = 0; i < 4; i++)
27857       {
27858         char *a = foo + i;
27859         char *b = bar + i;
27860         strcpy (a, "--------01111111");
27861         strcpy (b, "--------10000000");
27862         if (memcmp (a, b, 16) >= 0)
27863           return 1;
27864       }
27865     return 0;
27866   }
27867
27868   ;
27869   return 0;
27870 }
27871 _ACEOF
27872 rm -f conftest$ac_exeext
27873 if { (ac_try="$ac_link"
27874 case "(($ac_try" in
27875   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27876   *) ac_try_echo=$ac_try;;
27877 esac
27878 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27879 $as_echo "$ac_try_echo") >&5
27880   (eval "$ac_link") 2>&5
27881   ac_status=$?
27882   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27883   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
27884   { (case "(($ac_try" in
27885   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
27886   *) ac_try_echo=$ac_try;;
27887 esac
27888 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
27889 $as_echo "$ac_try_echo") >&5
27890   (eval "$ac_try") 2>&5
27891   ac_status=$?
27892   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
27893   (exit $ac_status); }; }; then
27894   ac_cv_func_memcmp_working=yes
27895 else
27896   $as_echo "$as_me: program exited with status $ac_status" >&5
27897 $as_echo "$as_me: failed program was:" >&5
27898 sed 's/^/| /' conftest.$ac_ext >&5
27899
27900 ( exit $ac_status )
27901 ac_cv_func_memcmp_working=no
27902 fi
27903 rm -rf conftest.dSYM
27904 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
27905 fi
27906
27907
27908 fi
27909 { $as_echo "$as_me:$LINENO: result: $ac_cv_func_memcmp_working" >&5
27910 $as_echo "$ac_cv_func_memcmp_working" >&6; }
27911 test $ac_cv_func_memcmp_working = no && case " $LIBOBJS " in
27912   *" memcmp.$ac_objext "* ) ;;
27913   *) LIBOBJS="$LIBOBJS memcmp.$ac_objext"
27914  ;;
27915 esac
27916
27917
27918
27919
27920 # Select semaphore implementation type.
27921 if test "$PORTNAME" != "win32"; then
27922   if test x"$USE_NAMED_POSIX_SEMAPHORES" = x"1" ; then
27923
27924 cat >>confdefs.h <<\_ACEOF
27925 #define USE_NAMED_POSIX_SEMAPHORES 1
27926 _ACEOF
27927
27928     SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
27929   else
27930     if test x"$USE_UNNAMED_POSIX_SEMAPHORES" = x"1" ; then
27931
27932 cat >>confdefs.h <<\_ACEOF
27933 #define USE_UNNAMED_POSIX_SEMAPHORES 1
27934 _ACEOF
27935
27936       SEMA_IMPLEMENTATION="src/backend/port/posix_sema.c"
27937     else
27938
27939 cat >>confdefs.h <<\_ACEOF
27940 #define USE_SYSV_SEMAPHORES 1
27941 _ACEOF
27942
27943       SEMA_IMPLEMENTATION="src/backend/port/sysv_sema.c"
27944     fi
27945   fi
27946 else
27947
27948 cat >>confdefs.h <<\_ACEOF
27949 #define USE_WIN32_SEMAPHORES 1
27950 _ACEOF
27951
27952   SEMA_IMPLEMENTATION="src/backend/port/win32_sema.c"
27953 fi
27954
27955
27956 # Select shared-memory implementation type.
27957 if test "$PORTNAME" != "win32"; then
27958
27959 cat >>confdefs.h <<\_ACEOF
27960 #define USE_SYSV_SHARED_MEMORY 1
27961 _ACEOF
27962
27963   SHMEM_IMPLEMENTATION="src/backend/port/sysv_shmem.c"
27964 else
27965
27966 cat >>confdefs.h <<\_ACEOF
27967 #define USE_WIN32_SHARED_MEMORY 1
27968 _ACEOF
27969
27970   SHMEM_IMPLEMENTATION="src/backend/port/win32_shmem.c"
27971 fi
27972
27973 # Select latch implementation type.
27974 if test "$PORTNAME" != "win32"; then
27975   LATCH_IMPLEMENTATION="src/backend/port/unix_latch.c"
27976 else
27977   LATCH_IMPLEMENTATION="src/backend/port/win32_latch.c"
27978 fi
27979
27980 # If not set in template file, set bytes to use libc memset()
27981 if test x"$MEMSET_LOOP_LIMIT" = x"" ; then
27982   MEMSET_LOOP_LIMIT=1024
27983 fi
27984
27985 cat >>confdefs.h <<_ACEOF
27986 #define MEMSET_LOOP_LIMIT ${MEMSET_LOOP_LIMIT}
27987 _ACEOF
27988
27989
27990
27991 if test "$enable_nls" = yes ; then
27992
27993   { $as_echo "$as_me:$LINENO: checking for library containing bind_textdomain_codeset" >&5
27994 $as_echo_n "checking for library containing bind_textdomain_codeset... " >&6; }
27995 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
27996   $as_echo_n "(cached) " >&6
27997 else
27998   ac_func_search_save_LIBS=$LIBS
27999 cat >conftest.$ac_ext <<_ACEOF
28000 /* confdefs.h.  */
28001 _ACEOF
28002 cat confdefs.h >>conftest.$ac_ext
28003 cat >>conftest.$ac_ext <<_ACEOF
28004 /* end confdefs.h.  */
28005
28006 /* Override any GCC internal prototype to avoid an error.
28007    Use char because int might match the return type of a GCC
28008    builtin and then its argument prototype would still apply.  */
28009 #ifdef __cplusplus
28010 extern "C"
28011 #endif
28012 char bind_textdomain_codeset ();
28013 int
28014 main ()
28015 {
28016 return bind_textdomain_codeset ();
28017   ;
28018   return 0;
28019 }
28020 _ACEOF
28021 for ac_lib in '' intl; do
28022   if test -z "$ac_lib"; then
28023     ac_res="none required"
28024   else
28025     ac_res=-l$ac_lib
28026     LIBS="-l$ac_lib  $ac_func_search_save_LIBS"
28027   fi
28028   rm -f conftest.$ac_objext conftest$ac_exeext
28029 if { (ac_try="$ac_link"
28030 case "(($ac_try" in
28031   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28032   *) ac_try_echo=$ac_try;;
28033 esac
28034 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28035 $as_echo "$ac_try_echo") >&5
28036   (eval "$ac_link") 2>conftest.er1
28037   ac_status=$?
28038   grep -v '^ *+' conftest.er1 >conftest.err
28039   rm -f conftest.er1
28040   cat conftest.err >&5
28041   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28042   (exit $ac_status); } && {
28043          test -z "$ac_c_werror_flag" ||
28044          test ! -s conftest.err
28045        } && test -s conftest$ac_exeext && {
28046          test "$cross_compiling" = yes ||
28047          $as_test_x conftest$ac_exeext
28048        }; then
28049   ac_cv_search_bind_textdomain_codeset=$ac_res
28050 else
28051   $as_echo "$as_me: failed program was:" >&5
28052 sed 's/^/| /' conftest.$ac_ext >&5
28053
28054
28055 fi
28056
28057 rm -rf conftest.dSYM
28058 rm -f core conftest.err conftest.$ac_objext conftest_ipa8_conftest.oo \
28059       conftest$ac_exeext
28060   if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
28061   break
28062 fi
28063 done
28064 if test "${ac_cv_search_bind_textdomain_codeset+set}" = set; then
28065   :
28066 else
28067   ac_cv_search_bind_textdomain_codeset=no
28068 fi
28069 rm conftest.$ac_ext
28070 LIBS=$ac_func_search_save_LIBS
28071 fi
28072 { $as_echo "$as_me:$LINENO: result: $ac_cv_search_bind_textdomain_codeset" >&5
28073 $as_echo "$ac_cv_search_bind_textdomain_codeset" >&6; }
28074 ac_res=$ac_cv_search_bind_textdomain_codeset
28075 if test "$ac_res" != no; then
28076   test "$ac_res" = "none required" || LIBS="$ac_res $LIBS"
28077
28078 else
28079   { { $as_echo "$as_me:$LINENO: error: a gettext implementation is required for NLS" >&5
28080 $as_echo "$as_me: error: a gettext implementation is required for NLS" >&2;}
28081    { (exit 1); exit 1; }; }
28082 fi
28083
28084   if test "${ac_cv_header_libintl_h+set}" = set; then
28085   { $as_echo "$as_me:$LINENO: checking for libintl.h" >&5
28086 $as_echo_n "checking for libintl.h... " >&6; }
28087 if test "${ac_cv_header_libintl_h+set}" = set; then
28088   $as_echo_n "(cached) " >&6
28089 fi
28090 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
28091 $as_echo "$ac_cv_header_libintl_h" >&6; }
28092 else
28093   # Is the header compilable?
28094 { $as_echo "$as_me:$LINENO: checking libintl.h usability" >&5
28095 $as_echo_n "checking libintl.h usability... " >&6; }
28096 cat >conftest.$ac_ext <<_ACEOF
28097 /* confdefs.h.  */
28098 _ACEOF
28099 cat confdefs.h >>conftest.$ac_ext
28100 cat >>conftest.$ac_ext <<_ACEOF
28101 /* end confdefs.h.  */
28102 $ac_includes_default
28103 #include <libintl.h>
28104 _ACEOF
28105 rm -f conftest.$ac_objext
28106 if { (ac_try="$ac_compile"
28107 case "(($ac_try" in
28108   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28109   *) ac_try_echo=$ac_try;;
28110 esac
28111 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28112 $as_echo "$ac_try_echo") >&5
28113   (eval "$ac_compile") 2>conftest.er1
28114   ac_status=$?
28115   grep -v '^ *+' conftest.er1 >conftest.err
28116   rm -f conftest.er1
28117   cat conftest.err >&5
28118   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28119   (exit $ac_status); } && {
28120          test -z "$ac_c_werror_flag" ||
28121          test ! -s conftest.err
28122        } && test -s conftest.$ac_objext; then
28123   ac_header_compiler=yes
28124 else
28125   $as_echo "$as_me: failed program was:" >&5
28126 sed 's/^/| /' conftest.$ac_ext >&5
28127
28128         ac_header_compiler=no
28129 fi
28130
28131 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28132 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28133 $as_echo "$ac_header_compiler" >&6; }
28134
28135 # Is the header present?
28136 { $as_echo "$as_me:$LINENO: checking libintl.h presence" >&5
28137 $as_echo_n "checking libintl.h presence... " >&6; }
28138 cat >conftest.$ac_ext <<_ACEOF
28139 /* confdefs.h.  */
28140 _ACEOF
28141 cat confdefs.h >>conftest.$ac_ext
28142 cat >>conftest.$ac_ext <<_ACEOF
28143 /* end confdefs.h.  */
28144 #include <libintl.h>
28145 _ACEOF
28146 if { (ac_try="$ac_cpp conftest.$ac_ext"
28147 case "(($ac_try" in
28148   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28149   *) ac_try_echo=$ac_try;;
28150 esac
28151 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28152 $as_echo "$ac_try_echo") >&5
28153   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
28154   ac_status=$?
28155   grep -v '^ *+' conftest.er1 >conftest.err
28156   rm -f conftest.er1
28157   cat conftest.err >&5
28158   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28159   (exit $ac_status); } >/dev/null && {
28160          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
28161          test ! -s conftest.err
28162        }; then
28163   ac_header_preproc=yes
28164 else
28165   $as_echo "$as_me: failed program was:" >&5
28166 sed 's/^/| /' conftest.$ac_ext >&5
28167
28168   ac_header_preproc=no
28169 fi
28170
28171 rm -f conftest.err conftest.$ac_ext
28172 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28173 $as_echo "$ac_header_preproc" >&6; }
28174
28175 # So?  What about this header?
28176 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
28177   yes:no: )
28178     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&5
28179 $as_echo "$as_me: WARNING: libintl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
28180     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the compiler's result" >&5
28181 $as_echo "$as_me: WARNING: libintl.h: proceeding with the compiler's result" >&2;}
28182     ac_header_preproc=yes
28183     ;;
28184   no:yes:* )
28185     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: present but cannot be compiled" >&5
28186 $as_echo "$as_me: WARNING: libintl.h: present but cannot be compiled" >&2;}
28187     { $as_echo "$as_me:$LINENO: WARNING: libintl.h:     check for missing prerequisite headers?" >&5
28188 $as_echo "$as_me: WARNING: libintl.h:     check for missing prerequisite headers?" >&2;}
28189     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: see the Autoconf documentation" >&5
28190 $as_echo "$as_me: WARNING: libintl.h: see the Autoconf documentation" >&2;}
28191     { $as_echo "$as_me:$LINENO: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&5
28192 $as_echo "$as_me: WARNING: libintl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
28193     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: proceeding with the preprocessor's result" >&5
28194 $as_echo "$as_me: WARNING: libintl.h: proceeding with the preprocessor's result" >&2;}
28195     { $as_echo "$as_me:$LINENO: WARNING: libintl.h: in the future, the compiler will take precedence" >&5
28196 $as_echo "$as_me: WARNING: libintl.h: in the future, the compiler will take precedence" >&2;}
28197     ( cat <<\_ASBOX
28198 ## ---------------------------------------- ##
28199 ## Report this to pgsql-bugs@postgresql.org ##
28200 ## ---------------------------------------- ##
28201 _ASBOX
28202      ) | sed "s/^/$as_me: WARNING:     /" >&2
28203     ;;
28204 esac
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 else
28210   ac_cv_header_libintl_h=$ac_header_preproc
28211 fi
28212 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_libintl_h" >&5
28213 $as_echo "$ac_cv_header_libintl_h" >&6; }
28214
28215 fi
28216 if test "x$ac_cv_header_libintl_h" = x""yes; then
28217   :
28218 else
28219   { { $as_echo "$as_me:$LINENO: error: header file <libintl.h> is required for NLS" >&5
28220 $as_echo "$as_me: error: header file <libintl.h> is required for NLS" >&2;}
28221    { (exit 1); exit 1; }; }
28222 fi
28223
28224
28225   for ac_prog in msgfmt
28226 do
28227   # Extract the first word of "$ac_prog", so it can be a program name with args.
28228 set dummy $ac_prog; ac_word=$2
28229 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28230 $as_echo_n "checking for $ac_word... " >&6; }
28231 if test "${ac_cv_prog_MSGFMT+set}" = set; then
28232   $as_echo_n "(cached) " >&6
28233 else
28234   if test -n "$MSGFMT"; then
28235   ac_cv_prog_MSGFMT="$MSGFMT" # Let the user override the test.
28236 else
28237 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28238 for as_dir in $PATH
28239 do
28240   IFS=$as_save_IFS
28241   test -z "$as_dir" && as_dir=.
28242   for ac_exec_ext in '' $ac_executable_extensions; do
28243   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28244     ac_cv_prog_MSGFMT="$ac_prog"
28245     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28246     break 2
28247   fi
28248 done
28249 done
28250 IFS=$as_save_IFS
28251
28252 fi
28253 fi
28254 MSGFMT=$ac_cv_prog_MSGFMT
28255 if test -n "$MSGFMT"; then
28256   { $as_echo "$as_me:$LINENO: result: $MSGFMT" >&5
28257 $as_echo "$MSGFMT" >&6; }
28258 else
28259   { $as_echo "$as_me:$LINENO: result: no" >&5
28260 $as_echo "no" >&6; }
28261 fi
28262
28263
28264   test -n "$MSGFMT" && break
28265 done
28266
28267   if test -z "$MSGFMT"; then
28268     { { $as_echo "$as_me:$LINENO: error: msgfmt is required for NLS" >&5
28269 $as_echo "$as_me: error: msgfmt is required for NLS" >&2;}
28270    { (exit 1); exit 1; }; }
28271   fi
28272   for ac_prog in msgmerge
28273 do
28274   # Extract the first word of "$ac_prog", so it can be a program name with args.
28275 set dummy $ac_prog; ac_word=$2
28276 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28277 $as_echo_n "checking for $ac_word... " >&6; }
28278 if test "${ac_cv_prog_MSGMERGE+set}" = set; then
28279   $as_echo_n "(cached) " >&6
28280 else
28281   if test -n "$MSGMERGE"; then
28282   ac_cv_prog_MSGMERGE="$MSGMERGE" # Let the user override the test.
28283 else
28284 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28285 for as_dir in $PATH
28286 do
28287   IFS=$as_save_IFS
28288   test -z "$as_dir" && as_dir=.
28289   for ac_exec_ext in '' $ac_executable_extensions; do
28290   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28291     ac_cv_prog_MSGMERGE="$ac_prog"
28292     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28293     break 2
28294   fi
28295 done
28296 done
28297 IFS=$as_save_IFS
28298
28299 fi
28300 fi
28301 MSGMERGE=$ac_cv_prog_MSGMERGE
28302 if test -n "$MSGMERGE"; then
28303   { $as_echo "$as_me:$LINENO: result: $MSGMERGE" >&5
28304 $as_echo "$MSGMERGE" >&6; }
28305 else
28306   { $as_echo "$as_me:$LINENO: result: no" >&5
28307 $as_echo "no" >&6; }
28308 fi
28309
28310
28311   test -n "$MSGMERGE" && break
28312 done
28313
28314   for ac_prog in xgettext
28315 do
28316   # Extract the first word of "$ac_prog", so it can be a program name with args.
28317 set dummy $ac_prog; ac_word=$2
28318 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28319 $as_echo_n "checking for $ac_word... " >&6; }
28320 if test "${ac_cv_prog_XGETTEXT+set}" = set; then
28321   $as_echo_n "(cached) " >&6
28322 else
28323   if test -n "$XGETTEXT"; then
28324   ac_cv_prog_XGETTEXT="$XGETTEXT" # Let the user override the test.
28325 else
28326 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28327 for as_dir in $PATH
28328 do
28329   IFS=$as_save_IFS
28330   test -z "$as_dir" && as_dir=.
28331   for ac_exec_ext in '' $ac_executable_extensions; do
28332   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28333     ac_cv_prog_XGETTEXT="$ac_prog"
28334     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28335     break 2
28336   fi
28337 done
28338 done
28339 IFS=$as_save_IFS
28340
28341 fi
28342 fi
28343 XGETTEXT=$ac_cv_prog_XGETTEXT
28344 if test -n "$XGETTEXT"; then
28345   { $as_echo "$as_me:$LINENO: result: $XGETTEXT" >&5
28346 $as_echo "$XGETTEXT" >&6; }
28347 else
28348   { $as_echo "$as_me:$LINENO: result: no" >&5
28349 $as_echo "no" >&6; }
28350 fi
28351
28352
28353   test -n "$XGETTEXT" && break
28354 done
28355
28356
28357 fi
28358
28359 # Check for Tcl configuration script tclConfig.sh
28360 if test "$with_tcl" = yes; then
28361     for ac_prog in tclsh tcl tclsh8.5 tclsh85 tclsh8.4 tclsh84 tclsh8.3 tclsh83
28362 do
28363   # Extract the first word of "$ac_prog", so it can be a program name with args.
28364 set dummy $ac_prog; ac_word=$2
28365 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28366 $as_echo_n "checking for $ac_word... " >&6; }
28367 if test "${ac_cv_path_TCLSH+set}" = set; then
28368   $as_echo_n "(cached) " >&6
28369 else
28370   case $TCLSH in
28371   [\\/]* | ?:[\\/]*)
28372   ac_cv_path_TCLSH="$TCLSH" # Let the user override the test with a path.
28373   ;;
28374   *)
28375   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28376 for as_dir in $PATH
28377 do
28378   IFS=$as_save_IFS
28379   test -z "$as_dir" && as_dir=.
28380   for ac_exec_ext in '' $ac_executable_extensions; do
28381   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28382     ac_cv_path_TCLSH="$as_dir/$ac_word$ac_exec_ext"
28383     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28384     break 2
28385   fi
28386 done
28387 done
28388 IFS=$as_save_IFS
28389
28390   ;;
28391 esac
28392 fi
28393 TCLSH=$ac_cv_path_TCLSH
28394 if test -n "$TCLSH"; then
28395   { $as_echo "$as_me:$LINENO: result: $TCLSH" >&5
28396 $as_echo "$TCLSH" >&6; }
28397 else
28398   { $as_echo "$as_me:$LINENO: result: no" >&5
28399 $as_echo "no" >&6; }
28400 fi
28401
28402
28403   test -n "$TCLSH" && break
28404 done
28405
28406 if test x"$TCLSH" = x""; then
28407   { { $as_echo "$as_me:$LINENO: error: Tcl shell not found" >&5
28408 $as_echo "$as_me: error: Tcl shell not found" >&2;}
28409    { (exit 1); exit 1; }; }
28410 fi
28411
28412 { $as_echo "$as_me:$LINENO: checking for tclConfig.sh" >&5
28413 $as_echo_n "checking for tclConfig.sh... " >&6; }
28414 # Let user override test
28415 if test -z "$TCL_CONFIG_SH"; then
28416     pgac_test_dirs="$with_tclconfig"
28417
28418     set X $pgac_test_dirs; shift
28419     if test $# -eq 0; then
28420         test -z "$TCLSH" && { { $as_echo "$as_me:$LINENO: error: unable to locate tclConfig.sh because no Tcl shell was found" >&5
28421 $as_echo "$as_me: error: unable to locate tclConfig.sh because no Tcl shell was found" >&2;}
28422    { (exit 1); exit 1; }; }
28423         set X `echo 'puts $auto_path' | $TCLSH`; shift
28424     fi
28425
28426     for pgac_dir do
28427         if test -r "$pgac_dir/tclConfig.sh"; then
28428             TCL_CONFIG_SH=$pgac_dir/tclConfig.sh
28429             break
28430         fi
28431     done
28432 fi
28433
28434 if test -z "$TCL_CONFIG_SH"; then
28435     { $as_echo "$as_me:$LINENO: result: no" >&5
28436 $as_echo "no" >&6; }
28437     { { $as_echo "$as_me:$LINENO: error: file 'tclConfig.sh' is required for Tcl" >&5
28438 $as_echo "$as_me: error: file 'tclConfig.sh' is required for Tcl" >&2;}
28439    { (exit 1); exit 1; }; }
28440 else
28441     { $as_echo "$as_me:$LINENO: result: $TCL_CONFIG_SH" >&5
28442 $as_echo "$TCL_CONFIG_SH" >&6; }
28443 fi
28444
28445
28446
28447     . "$TCL_CONFIG_SH"
28448 eval TCL_INCLUDE_SPEC=\"$TCL_INCLUDE_SPEC\"
28449 eval TCL_LIB_FILE=\"$TCL_LIB_FILE\"
28450 eval TCL_LIBS=\"$TCL_LIBS\"
28451 eval TCL_LIB_SPEC=\"$TCL_LIB_SPEC\"
28452 eval TCL_SHARED_BUILD=\"$TCL_SHARED_BUILD\"
28453
28454         # now that we have TCL_INCLUDE_SPEC, we can check for <tcl.h>
28455     ac_save_CPPFLAGS=$CPPFLAGS
28456     CPPFLAGS="$TCL_INCLUDE_SPEC $CPPFLAGS"
28457     if test "${ac_cv_header_tcl_h+set}" = set; then
28458   { $as_echo "$as_me:$LINENO: checking for tcl.h" >&5
28459 $as_echo_n "checking for tcl.h... " >&6; }
28460 if test "${ac_cv_header_tcl_h+set}" = set; then
28461   $as_echo_n "(cached) " >&6
28462 fi
28463 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
28464 $as_echo "$ac_cv_header_tcl_h" >&6; }
28465 else
28466   # Is the header compilable?
28467 { $as_echo "$as_me:$LINENO: checking tcl.h usability" >&5
28468 $as_echo_n "checking tcl.h usability... " >&6; }
28469 cat >conftest.$ac_ext <<_ACEOF
28470 /* confdefs.h.  */
28471 _ACEOF
28472 cat confdefs.h >>conftest.$ac_ext
28473 cat >>conftest.$ac_ext <<_ACEOF
28474 /* end confdefs.h.  */
28475 $ac_includes_default
28476 #include <tcl.h>
28477 _ACEOF
28478 rm -f conftest.$ac_objext
28479 if { (ac_try="$ac_compile"
28480 case "(($ac_try" in
28481   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28482   *) ac_try_echo=$ac_try;;
28483 esac
28484 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28485 $as_echo "$ac_try_echo") >&5
28486   (eval "$ac_compile") 2>conftest.er1
28487   ac_status=$?
28488   grep -v '^ *+' conftest.er1 >conftest.err
28489   rm -f conftest.er1
28490   cat conftest.err >&5
28491   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28492   (exit $ac_status); } && {
28493          test -z "$ac_c_werror_flag" ||
28494          test ! -s conftest.err
28495        } && test -s conftest.$ac_objext; then
28496   ac_header_compiler=yes
28497 else
28498   $as_echo "$as_me: failed program was:" >&5
28499 sed 's/^/| /' conftest.$ac_ext >&5
28500
28501         ac_header_compiler=no
28502 fi
28503
28504 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
28505 { $as_echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
28506 $as_echo "$ac_header_compiler" >&6; }
28507
28508 # Is the header present?
28509 { $as_echo "$as_me:$LINENO: checking tcl.h presence" >&5
28510 $as_echo_n "checking tcl.h presence... " >&6; }
28511 cat >conftest.$ac_ext <<_ACEOF
28512 /* confdefs.h.  */
28513 _ACEOF
28514 cat confdefs.h >>conftest.$ac_ext
28515 cat >>conftest.$ac_ext <<_ACEOF
28516 /* end confdefs.h.  */
28517 #include <tcl.h>
28518 _ACEOF
28519 if { (ac_try="$ac_cpp conftest.$ac_ext"
28520 case "(($ac_try" in
28521   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28522   *) ac_try_echo=$ac_try;;
28523 esac
28524 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28525 $as_echo "$ac_try_echo") >&5
28526   (eval "$ac_cpp conftest.$ac_ext") 2>conftest.er1
28527   ac_status=$?
28528   grep -v '^ *+' conftest.er1 >conftest.err
28529   rm -f conftest.er1
28530   cat conftest.err >&5
28531   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28532   (exit $ac_status); } >/dev/null && {
28533          test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" ||
28534          test ! -s conftest.err
28535        }; then
28536   ac_header_preproc=yes
28537 else
28538   $as_echo "$as_me: failed program was:" >&5
28539 sed 's/^/| /' conftest.$ac_ext >&5
28540
28541   ac_header_preproc=no
28542 fi
28543
28544 rm -f conftest.err conftest.$ac_ext
28545 { $as_echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
28546 $as_echo "$ac_header_preproc" >&6; }
28547
28548 # So?  What about this header?
28549 case $ac_header_compiler:$ac_header_preproc:$ac_c_preproc_warn_flag in
28550   yes:no: )
28551     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&5
28552 $as_echo "$as_me: WARNING: tcl.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
28553     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the compiler's result" >&5
28554 $as_echo "$as_me: WARNING: tcl.h: proceeding with the compiler's result" >&2;}
28555     ac_header_preproc=yes
28556     ;;
28557   no:yes:* )
28558     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: present but cannot be compiled" >&5
28559 $as_echo "$as_me: WARNING: tcl.h: present but cannot be compiled" >&2;}
28560     { $as_echo "$as_me:$LINENO: WARNING: tcl.h:     check for missing prerequisite headers?" >&5
28561 $as_echo "$as_me: WARNING: tcl.h:     check for missing prerequisite headers?" >&2;}
28562     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: see the Autoconf documentation" >&5
28563 $as_echo "$as_me: WARNING: tcl.h: see the Autoconf documentation" >&2;}
28564     { $as_echo "$as_me:$LINENO: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&5
28565 $as_echo "$as_me: WARNING: tcl.h:     section \"Present But Cannot Be Compiled\"" >&2;}
28566     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: proceeding with the preprocessor's result" >&5
28567 $as_echo "$as_me: WARNING: tcl.h: proceeding with the preprocessor's result" >&2;}
28568     { $as_echo "$as_me:$LINENO: WARNING: tcl.h: in the future, the compiler will take precedence" >&5
28569 $as_echo "$as_me: WARNING: tcl.h: in the future, the compiler will take precedence" >&2;}
28570     ( cat <<\_ASBOX
28571 ## ---------------------------------------- ##
28572 ## Report this to pgsql-bugs@postgresql.org ##
28573 ## ---------------------------------------- ##
28574 _ASBOX
28575      ) | sed "s/^/$as_me: WARNING:     /" >&2
28576     ;;
28577 esac
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 else
28583   ac_cv_header_tcl_h=$ac_header_preproc
28584 fi
28585 { $as_echo "$as_me:$LINENO: result: $ac_cv_header_tcl_h" >&5
28586 $as_echo "$ac_cv_header_tcl_h" >&6; }
28587
28588 fi
28589 if test "x$ac_cv_header_tcl_h" = x""yes; then
28590   :
28591 else
28592   { { $as_echo "$as_me:$LINENO: error: header file <tcl.h> is required for Tcl" >&5
28593 $as_echo "$as_me: error: header file <tcl.h> is required for Tcl" >&2;}
28594    { (exit 1); exit 1; }; }
28595 fi
28596
28597
28598     CPPFLAGS=$ac_save_CPPFLAGS
28599 fi
28600
28601 #
28602 # Check for DocBook and tools
28603 #
28604 for ac_prog in onsgmls nsgmls
28605 do
28606   # Extract the first word of "$ac_prog", so it can be a program name with args.
28607 set dummy $ac_prog; ac_word=$2
28608 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28609 $as_echo_n "checking for $ac_word... " >&6; }
28610 if test "${ac_cv_prog_NSGMLS+set}" = set; then
28611   $as_echo_n "(cached) " >&6
28612 else
28613   if test -n "$NSGMLS"; then
28614   ac_cv_prog_NSGMLS="$NSGMLS" # Let the user override the test.
28615 else
28616 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28617 for as_dir in $PATH
28618 do
28619   IFS=$as_save_IFS
28620   test -z "$as_dir" && as_dir=.
28621   for ac_exec_ext in '' $ac_executable_extensions; do
28622   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28623     ac_cv_prog_NSGMLS="$ac_prog"
28624     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28625     break 2
28626   fi
28627 done
28628 done
28629 IFS=$as_save_IFS
28630
28631 fi
28632 fi
28633 NSGMLS=$ac_cv_prog_NSGMLS
28634 if test -n "$NSGMLS"; then
28635   { $as_echo "$as_me:$LINENO: result: $NSGMLS" >&5
28636 $as_echo "$NSGMLS" >&6; }
28637 else
28638   { $as_echo "$as_me:$LINENO: result: no" >&5
28639 $as_echo "no" >&6; }
28640 fi
28641
28642
28643   test -n "$NSGMLS" && break
28644 done
28645
28646 for ac_prog in openjade jade
28647 do
28648   # Extract the first word of "$ac_prog", so it can be a program name with args.
28649 set dummy $ac_prog; ac_word=$2
28650 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28651 $as_echo_n "checking for $ac_word... " >&6; }
28652 if test "${ac_cv_prog_JADE+set}" = set; then
28653   $as_echo_n "(cached) " >&6
28654 else
28655   if test -n "$JADE"; then
28656   ac_cv_prog_JADE="$JADE" # Let the user override the test.
28657 else
28658 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28659 for as_dir in $PATH
28660 do
28661   IFS=$as_save_IFS
28662   test -z "$as_dir" && as_dir=.
28663   for ac_exec_ext in '' $ac_executable_extensions; do
28664   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28665     ac_cv_prog_JADE="$ac_prog"
28666     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28667     break 2
28668   fi
28669 done
28670 done
28671 IFS=$as_save_IFS
28672
28673 fi
28674 fi
28675 JADE=$ac_cv_prog_JADE
28676 if test -n "$JADE"; then
28677   { $as_echo "$as_me:$LINENO: result: $JADE" >&5
28678 $as_echo "$JADE" >&6; }
28679 else
28680   { $as_echo "$as_me:$LINENO: result: no" >&5
28681 $as_echo "no" >&6; }
28682 fi
28683
28684
28685   test -n "$JADE" && break
28686 done
28687
28688
28689 { $as_echo "$as_me:$LINENO: checking for DocBook V4.2" >&5
28690 $as_echo_n "checking for DocBook V4.2... " >&6; }
28691 if test "${pgac_cv_check_docbook+set}" = set; then
28692   $as_echo_n "(cached) " >&6
28693 else
28694   cat >conftest.sgml <<EOF
28695 <!doctype book PUBLIC "-//OASIS//DTD DocBook V4.2//EN">
28696 <book>
28697  <title>test</title>
28698  <chapter>
28699   <title>random</title>
28700    <sect1>
28701     <title>testsect</title>
28702     <para>text</para>
28703   </sect1>
28704  </chapter>
28705 </book>
28706 EOF
28707
28708 pgac_cv_check_docbook=no
28709
28710 if test -n "$NSGMLS"; then
28711   $NSGMLS -s conftest.sgml 1>&5 2>&1
28712   if test $? -eq 0; then
28713     pgac_cv_check_docbook=yes
28714   fi
28715 fi
28716 rm -f conftest.sgml
28717 fi
28718 { $as_echo "$as_me:$LINENO: result: $pgac_cv_check_docbook" >&5
28719 $as_echo "$pgac_cv_check_docbook" >&6; }
28720
28721 have_docbook=$pgac_cv_check_docbook
28722
28723
28724 { $as_echo "$as_me:$LINENO: checking for DocBook stylesheets" >&5
28725 $as_echo_n "checking for DocBook stylesheets... " >&6; }
28726 if test "${pgac_cv_path_stylesheets+set}" = set; then
28727   $as_echo_n "(cached) " >&6
28728 else
28729   if test -n "$DOCBOOKSTYLE"; then
28730   pgac_cv_path_stylesheets=$DOCBOOKSTYLE
28731 else
28732   for pgac_prefix in /usr /usr/local /opt /sw; do
28733     for pgac_infix in share lib; do
28734       for pgac_postfix in \
28735         sgml/stylesheets/nwalsh-modular \
28736         sgml/stylesheets/docbook \
28737         sgml/stylesheets/dsssl/docbook \
28738         sgml/docbook-dsssl \
28739         sgml/docbook/dsssl/modular \
28740         sgml/docbook/stylesheet/dsssl/modular \
28741         sgml/docbook/dsssl-stylesheets \
28742         sgml/dsssl/docbook-dsssl-nwalsh
28743       do
28744         pgac_candidate=$pgac_prefix/$pgac_infix/$pgac_postfix
28745         if test -r "$pgac_candidate/html/docbook.dsl" \
28746            && test -r "$pgac_candidate/print/docbook.dsl"
28747         then
28748           pgac_cv_path_stylesheets=$pgac_candidate
28749           break 3
28750         fi
28751       done
28752     done
28753   done
28754 fi
28755 fi
28756
28757 DOCBOOKSTYLE=$pgac_cv_path_stylesheets
28758
28759 if test -n "$DOCBOOKSTYLE"; then
28760   { $as_echo "$as_me:$LINENO: result: $DOCBOOKSTYLE" >&5
28761 $as_echo "$DOCBOOKSTYLE" >&6; }
28762 else
28763   { $as_echo "$as_me:$LINENO: result: no" >&5
28764 $as_echo "no" >&6; }
28765 fi
28766 if test -n "$DOCBOOKSTYLE"; then
28767   for ac_prog in collateindex.pl
28768 do
28769   # Extract the first word of "$ac_prog", so it can be a program name with args.
28770 set dummy $ac_prog; ac_word=$2
28771 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28772 $as_echo_n "checking for $ac_word... " >&6; }
28773 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
28774   $as_echo_n "(cached) " >&6
28775 else
28776   case $COLLATEINDEX in
28777   [\\/]* | ?:[\\/]*)
28778   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
28779   ;;
28780   *)
28781   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28782 for as_dir in $DOCBOOKSTYLE/bin $PATH
28783 do
28784   IFS=$as_save_IFS
28785   test -z "$as_dir" && as_dir=.
28786   for ac_exec_ext in '' $ac_executable_extensions; do
28787   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28788     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
28789     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28790     break 2
28791   fi
28792 done
28793 done
28794 IFS=$as_save_IFS
28795
28796   ;;
28797 esac
28798 fi
28799 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
28800 if test -n "$COLLATEINDEX"; then
28801   { $as_echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
28802 $as_echo "$COLLATEINDEX" >&6; }
28803 else
28804   { $as_echo "$as_me:$LINENO: result: no" >&5
28805 $as_echo "no" >&6; }
28806 fi
28807
28808
28809   test -n "$COLLATEINDEX" && break
28810 done
28811
28812 else
28813   for ac_prog in collateindex.pl
28814 do
28815   # Extract the first word of "$ac_prog", so it can be a program name with args.
28816 set dummy $ac_prog; ac_word=$2
28817 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28818 $as_echo_n "checking for $ac_word... " >&6; }
28819 if test "${ac_cv_path_COLLATEINDEX+set}" = set; then
28820   $as_echo_n "(cached) " >&6
28821 else
28822   case $COLLATEINDEX in
28823   [\\/]* | ?:[\\/]*)
28824   ac_cv_path_COLLATEINDEX="$COLLATEINDEX" # Let the user override the test with a path.
28825   ;;
28826   *)
28827   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28828 for as_dir in $PATH
28829 do
28830   IFS=$as_save_IFS
28831   test -z "$as_dir" && as_dir=.
28832   for ac_exec_ext in '' $ac_executable_extensions; do
28833   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28834     ac_cv_path_COLLATEINDEX="$as_dir/$ac_word$ac_exec_ext"
28835     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28836     break 2
28837   fi
28838 done
28839 done
28840 IFS=$as_save_IFS
28841
28842   ;;
28843 esac
28844 fi
28845 COLLATEINDEX=$ac_cv_path_COLLATEINDEX
28846 if test -n "$COLLATEINDEX"; then
28847   { $as_echo "$as_me:$LINENO: result: $COLLATEINDEX" >&5
28848 $as_echo "$COLLATEINDEX" >&6; }
28849 else
28850   { $as_echo "$as_me:$LINENO: result: no" >&5
28851 $as_echo "no" >&6; }
28852 fi
28853
28854
28855   test -n "$COLLATEINDEX" && break
28856 done
28857
28858 fi
28859 for ac_prog in xsltproc
28860 do
28861   # Extract the first word of "$ac_prog", so it can be a program name with args.
28862 set dummy $ac_prog; ac_word=$2
28863 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28864 $as_echo_n "checking for $ac_word... " >&6; }
28865 if test "${ac_cv_prog_XSLTPROC+set}" = set; then
28866   $as_echo_n "(cached) " >&6
28867 else
28868   if test -n "$XSLTPROC"; then
28869   ac_cv_prog_XSLTPROC="$XSLTPROC" # Let the user override the test.
28870 else
28871 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28872 for as_dir in $PATH
28873 do
28874   IFS=$as_save_IFS
28875   test -z "$as_dir" && as_dir=.
28876   for ac_exec_ext in '' $ac_executable_extensions; do
28877   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28878     ac_cv_prog_XSLTPROC="$ac_prog"
28879     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28880     break 2
28881   fi
28882 done
28883 done
28884 IFS=$as_save_IFS
28885
28886 fi
28887 fi
28888 XSLTPROC=$ac_cv_prog_XSLTPROC
28889 if test -n "$XSLTPROC"; then
28890   { $as_echo "$as_me:$LINENO: result: $XSLTPROC" >&5
28891 $as_echo "$XSLTPROC" >&6; }
28892 else
28893   { $as_echo "$as_me:$LINENO: result: no" >&5
28894 $as_echo "no" >&6; }
28895 fi
28896
28897
28898   test -n "$XSLTPROC" && break
28899 done
28900
28901 for ac_prog in osx sgml2xml sx
28902 do
28903   # Extract the first word of "$ac_prog", so it can be a program name with args.
28904 set dummy $ac_prog; ac_word=$2
28905 { $as_echo "$as_me:$LINENO: checking for $ac_word" >&5
28906 $as_echo_n "checking for $ac_word... " >&6; }
28907 if test "${ac_cv_prog_OSX+set}" = set; then
28908   $as_echo_n "(cached) " >&6
28909 else
28910   if test -n "$OSX"; then
28911   ac_cv_prog_OSX="$OSX" # Let the user override the test.
28912 else
28913 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
28914 for as_dir in $PATH
28915 do
28916   IFS=$as_save_IFS
28917   test -z "$as_dir" && as_dir=.
28918   for ac_exec_ext in '' $ac_executable_extensions; do
28919   if { test -f "$as_dir/$ac_word$ac_exec_ext" && $as_test_x "$as_dir/$ac_word$ac_exec_ext"; }; then
28920     ac_cv_prog_OSX="$ac_prog"
28921     $as_echo "$as_me:$LINENO: found $as_dir/$ac_word$ac_exec_ext" >&5
28922     break 2
28923   fi
28924 done
28925 done
28926 IFS=$as_save_IFS
28927
28928 fi
28929 fi
28930 OSX=$ac_cv_prog_OSX
28931 if test -n "$OSX"; then
28932   { $as_echo "$as_me:$LINENO: result: $OSX" >&5
28933 $as_echo "$OSX" >&6; }
28934 else
28935   { $as_echo "$as_me:$LINENO: result: no" >&5
28936 $as_echo "no" >&6; }
28937 fi
28938
28939
28940   test -n "$OSX" && break
28941 done
28942
28943
28944 # Thread testing
28945
28946 # We have to run the thread test near the end so we have all our symbols
28947 # defined.  Cross compiling throws a warning.
28948 #
28949 if test "$enable_thread_safety" = yes; then
28950 if test "$PORTNAME" != "win32"
28951 then
28952 { $as_echo "$as_me:$LINENO: checking thread safety of required library functions" >&5
28953 $as_echo_n "checking thread safety of required library functions... " >&6; }
28954
28955 _CFLAGS="$CFLAGS"
28956 _LIBS="$LIBS"
28957 CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE"
28958 LIBS="$LIBS $PTHREAD_LIBS"
28959 if test "$cross_compiling" = yes; then
28960   { $as_echo "$as_me:$LINENO: result: maybe" >&5
28961 $as_echo "maybe" >&6; }
28962   { $as_echo "$as_me:$LINENO: WARNING:
28963 *** Skipping thread test program because of cross-compile build.
28964 *** Run the program in src/test/thread on the target machine.
28965 " >&5
28966 $as_echo "$as_me: WARNING:
28967 *** Skipping thread test program because of cross-compile build.
28968 *** Run the program in src/test/thread on the target machine.
28969 " >&2;}
28970 else
28971   cat >conftest.$ac_ext <<_ACEOF
28972 /* confdefs.h.  */
28973 _ACEOF
28974 cat confdefs.h >>conftest.$ac_ext
28975 cat >>conftest.$ac_ext <<_ACEOF
28976 /* end confdefs.h.  */
28977 #include "$srcdir/src/test/thread/thread_test.c"
28978 _ACEOF
28979 rm -f conftest$ac_exeext
28980 if { (ac_try="$ac_link"
28981 case "(($ac_try" in
28982   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28983   *) ac_try_echo=$ac_try;;
28984 esac
28985 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28986 $as_echo "$ac_try_echo") >&5
28987   (eval "$ac_link") 2>&5
28988   ac_status=$?
28989   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
28990   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
28991   { (case "(($ac_try" in
28992   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
28993   *) ac_try_echo=$ac_try;;
28994 esac
28995 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
28996 $as_echo "$ac_try_echo") >&5
28997   (eval "$ac_try") 2>&5
28998   ac_status=$?
28999   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29000   (exit $ac_status); }; }; then
29001   { $as_echo "$as_me:$LINENO: result: yes" >&5
29002 $as_echo "yes" >&6; }
29003 else
29004   $as_echo "$as_me: program exited with status $ac_status" >&5
29005 $as_echo "$as_me: failed program was:" >&5
29006 sed 's/^/| /' conftest.$ac_ext >&5
29007
29008 ( exit $ac_status )
29009 { $as_echo "$as_me:$LINENO: result: no" >&5
29010 $as_echo "no" >&6; }
29011   { { $as_echo "$as_me:$LINENO: error: thread test program failed
29012 This platform is not thread-safe.  Check the file 'config.log' or compile
29013 and run src/test/thread/thread_test for the exact reason.
29014 Use --disable-thread-safety to disable thread safety." >&5
29015 $as_echo "$as_me: error: thread test program failed
29016 This platform is not thread-safe.  Check the file 'config.log' or compile
29017 and run src/test/thread/thread_test for the exact reason.
29018 Use --disable-thread-safety to disable thread safety." >&2;}
29019    { (exit 1); exit 1; }; }
29020 fi
29021 rm -rf conftest.dSYM
29022 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29023 fi
29024
29025
29026 CFLAGS="$_CFLAGS"
29027 LIBS="$_LIBS"
29028 else
29029 { $as_echo "$as_me:$LINENO: WARNING: *** skipping thread test on Win32" >&5
29030 $as_echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;}
29031 fi
29032 fi
29033
29034 # If compiler will take -Wl,--as-needed (or various platform-specific
29035 # spellings thereof) then add that to LDFLAGS.  This is much easier than
29036 # trying to filter LIBS to the minimum for each executable.
29037 # On (at least) some Red-Hat-derived systems, this switch breaks linking to
29038 # libreadline; therefore we postpone testing it until we know what library
29039 # dependencies readline has.  The test code will try to link with $LIBS.
29040 if test "$with_readline" = yes; then
29041   link_test_func=readline
29042 else
29043   link_test_func=exit
29044 fi
29045
29046 if test "$PORTNAME" = "darwin"; then
29047   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,-dead_strip_dylibs" >&5
29048 $as_echo_n "checking whether $CC supports -Wl,-dead_strip_dylibs... " >&6; }
29049 if test "${pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs+set}" = set; then
29050   $as_echo_n "(cached) " >&6
29051 else
29052   pgac_save_LDFLAGS=$LDFLAGS
29053 LDFLAGS="$pgac_save_LDFLAGS -Wl,-dead_strip_dylibs"
29054 if test "$cross_compiling" = yes; then
29055   pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs="assuming no"
29056 else
29057   cat >conftest.$ac_ext <<_ACEOF
29058 /* confdefs.h.  */
29059 _ACEOF
29060 cat confdefs.h >>conftest.$ac_ext
29061 cat >>conftest.$ac_ext <<_ACEOF
29062 /* end confdefs.h.  */
29063 extern void $link_test_func (); void (*fptr) () = $link_test_func;
29064 int
29065 main ()
29066 {
29067
29068   ;
29069   return 0;
29070 }
29071 _ACEOF
29072 rm -f conftest$ac_exeext
29073 if { (ac_try="$ac_link"
29074 case "(($ac_try" in
29075   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29076   *) ac_try_echo=$ac_try;;
29077 esac
29078 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29079 $as_echo "$ac_try_echo") >&5
29080   (eval "$ac_link") 2>&5
29081   ac_status=$?
29082   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29083   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29084   { (case "(($ac_try" in
29085   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29086   *) ac_try_echo=$ac_try;;
29087 esac
29088 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29089 $as_echo "$ac_try_echo") >&5
29090   (eval "$ac_try") 2>&5
29091   ac_status=$?
29092   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29093   (exit $ac_status); }; }; then
29094   pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=yes
29095 else
29096   $as_echo "$as_me: program exited with status $ac_status" >&5
29097 $as_echo "$as_me: failed program was:" >&5
29098 sed 's/^/| /' conftest.$ac_ext >&5
29099
29100 ( exit $ac_status )
29101 pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs=no
29102 fi
29103 rm -rf conftest.dSYM
29104 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29105 fi
29106
29107
29108 LDFLAGS="$pgac_save_LDFLAGS"
29109 fi
29110 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&5
29111 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" >&6; }
29112 if test x"$pgac_cv_prog_cc_ldflags__Wl__dead_strip_dylibs" = x"yes"; then
29113   LDFLAGS="$LDFLAGS -Wl,-dead_strip_dylibs"
29114 fi
29115
29116 elif test "$PORTNAME" = "openbsd"; then
29117   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,-Bdynamic" >&5
29118 $as_echo_n "checking whether $CC supports -Wl,-Bdynamic... " >&6; }
29119 if test "${pgac_cv_prog_cc_ldflags__Wl__Bdynamic+set}" = set; then
29120   $as_echo_n "(cached) " >&6
29121 else
29122   pgac_save_LDFLAGS=$LDFLAGS
29123 LDFLAGS="$pgac_save_LDFLAGS -Wl,-Bdynamic"
29124 if test "$cross_compiling" = yes; then
29125   pgac_cv_prog_cc_ldflags__Wl__Bdynamic="assuming no"
29126 else
29127   cat >conftest.$ac_ext <<_ACEOF
29128 /* confdefs.h.  */
29129 _ACEOF
29130 cat confdefs.h >>conftest.$ac_ext
29131 cat >>conftest.$ac_ext <<_ACEOF
29132 /* end confdefs.h.  */
29133 extern void $link_test_func (); void (*fptr) () = $link_test_func;
29134 int
29135 main ()
29136 {
29137
29138   ;
29139   return 0;
29140 }
29141 _ACEOF
29142 rm -f conftest$ac_exeext
29143 if { (ac_try="$ac_link"
29144 case "(($ac_try" in
29145   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29146   *) ac_try_echo=$ac_try;;
29147 esac
29148 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29149 $as_echo "$ac_try_echo") >&5
29150   (eval "$ac_link") 2>&5
29151   ac_status=$?
29152   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29153   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29154   { (case "(($ac_try" in
29155   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29156   *) ac_try_echo=$ac_try;;
29157 esac
29158 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29159 $as_echo "$ac_try_echo") >&5
29160   (eval "$ac_try") 2>&5
29161   ac_status=$?
29162   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29163   (exit $ac_status); }; }; then
29164   pgac_cv_prog_cc_ldflags__Wl__Bdynamic=yes
29165 else
29166   $as_echo "$as_me: program exited with status $ac_status" >&5
29167 $as_echo "$as_me: failed program was:" >&5
29168 sed 's/^/| /' conftest.$ac_ext >&5
29169
29170 ( exit $ac_status )
29171 pgac_cv_prog_cc_ldflags__Wl__Bdynamic=no
29172 fi
29173 rm -rf conftest.dSYM
29174 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29175 fi
29176
29177
29178 LDFLAGS="$pgac_save_LDFLAGS"
29179 fi
29180 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&5
29181 $as_echo "$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" >&6; }
29182 if test x"$pgac_cv_prog_cc_ldflags__Wl__Bdynamic" = x"yes"; then
29183   LDFLAGS="$LDFLAGS -Wl,-Bdynamic"
29184 fi
29185
29186 else
29187   { $as_echo "$as_me:$LINENO: checking whether $CC supports -Wl,--as-needed" >&5
29188 $as_echo_n "checking whether $CC supports -Wl,--as-needed... " >&6; }
29189 if test "${pgac_cv_prog_cc_ldflags__Wl___as_needed+set}" = set; then
29190   $as_echo_n "(cached) " >&6
29191 else
29192   pgac_save_LDFLAGS=$LDFLAGS
29193 LDFLAGS="$pgac_save_LDFLAGS -Wl,--as-needed"
29194 if test "$cross_compiling" = yes; then
29195   pgac_cv_prog_cc_ldflags__Wl___as_needed="assuming no"
29196 else
29197   cat >conftest.$ac_ext <<_ACEOF
29198 /* confdefs.h.  */
29199 _ACEOF
29200 cat confdefs.h >>conftest.$ac_ext
29201 cat >>conftest.$ac_ext <<_ACEOF
29202 /* end confdefs.h.  */
29203 extern void $link_test_func (); void (*fptr) () = $link_test_func;
29204 int
29205 main ()
29206 {
29207
29208   ;
29209   return 0;
29210 }
29211 _ACEOF
29212 rm -f conftest$ac_exeext
29213 if { (ac_try="$ac_link"
29214 case "(($ac_try" in
29215   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29216   *) ac_try_echo=$ac_try;;
29217 esac
29218 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29219 $as_echo "$ac_try_echo") >&5
29220   (eval "$ac_link") 2>&5
29221   ac_status=$?
29222   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29223   (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
29224   { (case "(($ac_try" in
29225   *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;;
29226   *) ac_try_echo=$ac_try;;
29227 esac
29228 eval ac_try_echo="\"\$as_me:$LINENO: $ac_try_echo\""
29229 $as_echo "$ac_try_echo") >&5
29230   (eval "$ac_try") 2>&5
29231   ac_status=$?
29232   $as_echo "$as_me:$LINENO: \$? = $ac_status" >&5
29233   (exit $ac_status); }; }; then
29234   pgac_cv_prog_cc_ldflags__Wl___as_needed=yes
29235 else
29236   $as_echo "$as_me: program exited with status $ac_status" >&5
29237 $as_echo "$as_me: failed program was:" >&5
29238 sed 's/^/| /' conftest.$ac_ext >&5
29239
29240 ( exit $ac_status )
29241 pgac_cv_prog_cc_ldflags__Wl___as_needed=no
29242 fi
29243 rm -rf conftest.dSYM
29244 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
29245 fi
29246
29247
29248 LDFLAGS="$pgac_save_LDFLAGS"
29249 fi
29250 { $as_echo "$as_me:$LINENO: result: $pgac_cv_prog_cc_ldflags__Wl___as_needed" >&5
29251 $as_echo "$pgac_cv_prog_cc_ldflags__Wl___as_needed" >&6; }
29252 if test x"$pgac_cv_prog_cc_ldflags__Wl___as_needed" = x"yes"; then
29253   LDFLAGS="$LDFLAGS -Wl,--as-needed"
29254 fi
29255
29256 fi
29257
29258
29259 # Begin output steps
29260
29261 { $as_echo "$as_me:$LINENO: using CFLAGS=$CFLAGS" >&5
29262 $as_echo "$as_me: using CFLAGS=$CFLAGS" >&6;}
29263 { $as_echo "$as_me:$LINENO: using CPPFLAGS=$CPPFLAGS" >&5
29264 $as_echo "$as_me: using CPPFLAGS=$CPPFLAGS" >&6;}
29265 { $as_echo "$as_me:$LINENO: using LDFLAGS=$LDFLAGS" >&5
29266 $as_echo "$as_me: using LDFLAGS=$LDFLAGS" >&6;}
29267
29268 # Create compiler version string
29269 if test x"$GCC" = x"yes" ; then
29270   cc_string="GCC `${CC} --version | sed q`"
29271 elif test x"$SUN_STUDIO_CC" = x"yes" ; then
29272   cc_string=`${CC} -V 2>&1 | sed q`
29273 else
29274   cc_string=$CC
29275 fi
29276
29277
29278 cat >>confdefs.h <<_ACEOF
29279 #define PG_VERSION_STR "PostgreSQL $PACKAGE_VERSION on $host, compiled by $cc_string, `expr $ac_cv_sizeof_void_p \* 8`-bit"
29280 _ACEOF
29281
29282
29283 # Supply a numeric version string for use by 3rd party add-ons
29284 # awk -F is a regex on some platforms, and not on others, so make "." a tab
29285 PG_VERSION_NUM="`echo "$PACKAGE_VERSION" | sed 's/[A-Za-z].*$//' |
29286 tr '.' '        ' |
29287 $AWK '{printf "%d%02d%02d", $1, $2, (NF >= 3) ? $3 : 0}'`"
29288
29289 cat >>confdefs.h <<_ACEOF
29290 #define PG_VERSION_NUM $PG_VERSION_NUM
29291 _ACEOF
29292
29293
29294
29295 # prepare build tree if outside source tree
29296 # Note 1: test -ef might not exist, but it's more reliable than `pwd`.
29297 # Note 2: /bin/pwd might be better than shell's built-in at getting
29298 #         a symlink-free name.
29299 if ( test "$srcdir" -ef . ) >/dev/null 2>&1 || test "`cd $srcdir && /bin/pwd`" = "`/bin/pwd`"; then
29300   vpath_build=no
29301 else
29302   vpath_build=yes
29303   if test "$no_create" != yes; then
29304     $as_echo_n "preparing build tree... " >&6
29305     pgac_abs_top_srcdir=`cd "$srcdir" && pwd`
29306     $SHELL "$ac_aux_dir/prep_buildtree" "$pgac_abs_top_srcdir" "." \
29307       || { { $as_echo "$as_me:$LINENO: error: failed" >&5
29308 $as_echo "$as_me: error: failed" >&2;}
29309    { (exit 1); exit 1; }; }
29310     { $as_echo "$as_me:$LINENO: result: done" >&5
29311 $as_echo "done" >&6; }
29312   fi
29313 fi
29314
29315
29316
29317 ac_config_files="$ac_config_files GNUmakefile src/Makefile.global"
29318
29319
29320 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}"
29321
29322
29323 if test "$PORTNAME" = "win32"; then
29324 ac_config_commands="$ac_config_commands check_win32_symlinks"
29325
29326 fi
29327
29328 ac_config_headers="$ac_config_headers src/include/pg_config.h"
29329
29330
29331 ac_config_headers="$ac_config_headers src/interfaces/ecpg/include/ecpg_config.h"
29332
29333
29334 cat >confcache <<\_ACEOF
29335 # This file is a shell script that caches the results of configure
29336 # tests run on this system so they can be shared between configure
29337 # scripts and configure runs, see configure's option --config-cache.
29338 # It is not useful on other systems.  If it contains results you don't
29339 # want to keep, you may remove or edit it.
29340 #
29341 # config.status only pays attention to the cache file if you give it
29342 # the --recheck option to rerun configure.
29343 #
29344 # `ac_cv_env_foo' variables (set or unset) will be overridden when
29345 # loading this file, other *unset* `ac_cv_foo' will be assigned the
29346 # following values.
29347
29348 _ACEOF
29349
29350 # The following way of writing the cache mishandles newlines in values,
29351 # but we know of no workaround that is simple, portable, and efficient.
29352 # So, we kill variables containing newlines.
29353 # Ultrix sh set writes to stderr and can't be redirected directly,
29354 # and sets the high bit in the cache file unless we assign to the vars.
29355 (
29356   for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do
29357     eval ac_val=\$$ac_var
29358     case $ac_val in #(
29359     *${as_nl}*)
29360       case $ac_var in #(
29361       *_cv_*) { $as_echo "$as_me:$LINENO: WARNING: cache variable $ac_var contains a newline" >&5
29362 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;;
29363       esac
29364       case $ac_var in #(
29365       _ | IFS | as_nl) ;; #(
29366       BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #(
29367       *) $as_unset $ac_var ;;
29368       esac ;;
29369     esac
29370   done
29371
29372   (set) 2>&1 |
29373     case $as_nl`(ac_space=' '; set) 2>&1` in #(
29374     *${as_nl}ac_space=\ *)
29375       # `set' does not quote correctly, so add quotes (double-quote
29376       # substitution turns \\\\ into \\, and sed turns \\ into \).
29377       sed -n \
29378         "s/'/'\\\\''/g;
29379           s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p"
29380       ;; #(
29381     *)
29382       # `set' quotes correctly as required by POSIX, so do not add quotes.
29383       sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p"
29384       ;;
29385     esac |
29386     sort
29387 ) |
29388   sed '
29389      /^ac_cv_env_/b end
29390      t clear
29391      :clear
29392      s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/
29393      t end
29394      s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/
29395      :end' >>confcache
29396 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else
29397   if test -w "$cache_file"; then
29398     test "x$cache_file" != "x/dev/null" &&
29399       { $as_echo "$as_me:$LINENO: updating cache $cache_file" >&5
29400 $as_echo "$as_me: updating cache $cache_file" >&6;}
29401     cat confcache >$cache_file
29402   else
29403     { $as_echo "$as_me:$LINENO: not updating unwritable cache $cache_file" >&5
29404 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;}
29405   fi
29406 fi
29407 rm -f confcache
29408
29409 test "x$prefix" = xNONE && prefix=$ac_default_prefix
29410 # Let make expand exec_prefix.
29411 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}'
29412
29413 DEFS=-DHAVE_CONFIG_H
29414
29415 ac_libobjs=
29416 ac_ltlibobjs=
29417 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue
29418   # 1. Remove the extension, and $U if already installed.
29419   ac_script='s/\$U\././;s/\.o$//;s/\.obj$//'
29420   ac_i=`$as_echo "$ac_i" | sed "$ac_script"`
29421   # 2. Prepend LIBOBJDIR.  When used with automake>=1.10 LIBOBJDIR
29422   #    will be set to the directory where LIBOBJS objects are built.
29423   ac_libobjs="$ac_libobjs \${LIBOBJDIR}$ac_i\$U.$ac_objext"
29424   ac_ltlibobjs="$ac_ltlibobjs \${LIBOBJDIR}$ac_i"'$U.lo'
29425 done
29426 LIBOBJS=$ac_libobjs
29427
29428 LTLIBOBJS=$ac_ltlibobjs
29429
29430
29431
29432
29433 : ${CONFIG_STATUS=./config.status}
29434 ac_write_fail=0
29435 ac_clean_files_save=$ac_clean_files
29436 ac_clean_files="$ac_clean_files $CONFIG_STATUS"
29437 { $as_echo "$as_me:$LINENO: creating $CONFIG_STATUS" >&5
29438 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;}
29439 cat >$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29440 #! $SHELL
29441 # Generated by $as_me.
29442 # Run this file to recreate the current configuration.
29443 # Compiler output produced by configure, useful for debugging
29444 # configure, is in config.log if it exists.
29445
29446 debug=false
29447 ac_cs_recheck=false
29448 ac_cs_silent=false
29449 SHELL=\${CONFIG_SHELL-$SHELL}
29450 _ACEOF
29451
29452 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29453 ## --------------------- ##
29454 ## M4sh Initialization.  ##
29455 ## --------------------- ##
29456
29457 # Be more Bourne compatible
29458 DUALCASE=1; export DUALCASE # for MKS sh
29459 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then
29460   emulate sh
29461   NULLCMD=:
29462   # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which
29463   # is contrary to our usage.  Disable this feature.
29464   alias -g '${1+"$@"}'='"$@"'
29465   setopt NO_GLOB_SUBST
29466 else
29467   case `(set -o) 2>/dev/null` in
29468   *posix*) set -o posix ;;
29469 esac
29470
29471 fi
29472
29473
29474
29475
29476 # PATH needs CR
29477 # Avoid depending upon Character Ranges.
29478 as_cr_letters='abcdefghijklmnopqrstuvwxyz'
29479 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ'
29480 as_cr_Letters=$as_cr_letters$as_cr_LETTERS
29481 as_cr_digits='0123456789'
29482 as_cr_alnum=$as_cr_Letters$as_cr_digits
29483
29484 as_nl='
29485 '
29486 export as_nl
29487 # Printing a long string crashes Solaris 7 /usr/bin/printf.
29488 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\'
29489 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo
29490 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo
29491 if (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then
29492   as_echo='printf %s\n'
29493   as_echo_n='printf %s'
29494 else
29495   if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then
29496     as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"'
29497     as_echo_n='/usr/ucb/echo -n'
29498   else
29499     as_echo_body='eval expr "X$1" : "X\\(.*\\)"'
29500     as_echo_n_body='eval
29501       arg=$1;
29502       case $arg in
29503       *"$as_nl"*)
29504         expr "X$arg" : "X\\(.*\\)$as_nl";
29505         arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;;
29506       esac;
29507       expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl"
29508     '
29509     export as_echo_n_body
29510     as_echo_n='sh -c $as_echo_n_body as_echo'
29511   fi
29512   export as_echo_body
29513   as_echo='sh -c $as_echo_body as_echo'
29514 fi
29515
29516 # The user is always right.
29517 if test "${PATH_SEPARATOR+set}" != set; then
29518   PATH_SEPARATOR=:
29519   (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && {
29520     (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 ||
29521       PATH_SEPARATOR=';'
29522   }
29523 fi
29524
29525 # Support unset when possible.
29526 if ( (MAIL=60; unset MAIL) || exit) >/dev/null 2>&1; then
29527   as_unset=unset
29528 else
29529   as_unset=false
29530 fi
29531
29532
29533 # IFS
29534 # We need space, tab and new line, in precisely that order.  Quoting is
29535 # there to prevent editors from complaining about space-tab.
29536 # (If _AS_PATH_WALK were called with IFS unset, it would disable word
29537 # splitting by setting IFS to empty value.)
29538 IFS=" ""        $as_nl"
29539
29540 # Find who we are.  Look in the path if we contain no directory separator.
29541 case $0 in
29542   *[\\/]* ) as_myself=$0 ;;
29543   *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29544 for as_dir in $PATH
29545 do
29546   IFS=$as_save_IFS
29547   test -z "$as_dir" && as_dir=.
29548   test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break
29549 done
29550 IFS=$as_save_IFS
29551
29552      ;;
29553 esac
29554 # We did not find ourselves, most probably we were run as `sh COMMAND'
29555 # in which case we are not to be found in the path.
29556 if test "x$as_myself" = x; then
29557   as_myself=$0
29558 fi
29559 if test ! -f "$as_myself"; then
29560   $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2
29561   { (exit 1); exit 1; }
29562 fi
29563
29564 # Work around bugs in pre-3.0 UWIN ksh.
29565 for as_var in ENV MAIL MAILPATH
29566 do ($as_unset $as_var) >/dev/null 2>&1 && $as_unset $as_var
29567 done
29568 PS1='$ '
29569 PS2='> '
29570 PS4='+ '
29571
29572 # NLS nuisances.
29573 LC_ALL=C
29574 export LC_ALL
29575 LANGUAGE=C
29576 export LANGUAGE
29577
29578 # Required to use basename.
29579 if expr a : '\(a\)' >/dev/null 2>&1 &&
29580    test "X`expr 00001 : '.*\(...\)'`" = X001; then
29581   as_expr=expr
29582 else
29583   as_expr=false
29584 fi
29585
29586 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then
29587   as_basename=basename
29588 else
29589   as_basename=false
29590 fi
29591
29592
29593 # Name of the executable.
29594 as_me=`$as_basename -- "$0" ||
29595 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \
29596          X"$0" : 'X\(//\)$' \| \
29597          X"$0" : 'X\(/\)' \| . 2>/dev/null ||
29598 $as_echo X/"$0" |
29599     sed '/^.*\/\([^/][^/]*\)\/*$/{
29600             s//\1/
29601             q
29602           }
29603           /^X\/\(\/\/\)$/{
29604             s//\1/
29605             q
29606           }
29607           /^X\/\(\/\).*/{
29608             s//\1/
29609             q
29610           }
29611           s/.*/./; q'`
29612
29613 # CDPATH.
29614 $as_unset CDPATH
29615
29616
29617
29618   as_lineno_1=$LINENO
29619   as_lineno_2=$LINENO
29620   test "x$as_lineno_1" != "x$as_lineno_2" &&
29621   test "x`expr $as_lineno_1 + 1`" = "x$as_lineno_2" || {
29622
29623   # Create $as_me.lineno as a copy of $as_myself, but with $LINENO
29624   # uniformly replaced by the line number.  The first 'sed' inserts a
29625   # line-number line after each line using $LINENO; the second 'sed'
29626   # does the real work.  The second script uses 'N' to pair each
29627   # line-number line with the line containing $LINENO, and appends
29628   # trailing '-' during substitution so that $LINENO is not a special
29629   # case at line end.
29630   # (Raja R Harinath suggested sed '=', and Paul Eggert wrote the
29631   # scripts with optimization help from Paolo Bonzini.  Blame Lee
29632   # E. McMahon (1931-1989) for sed's syntax.  :-)
29633   sed -n '
29634     p
29635     /[$]LINENO/=
29636   ' <$as_myself |
29637     sed '
29638       s/[$]LINENO.*/&-/
29639       t lineno
29640       b
29641       :lineno
29642       N
29643       :loop
29644       s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/
29645       t loop
29646       s/-\n.*//
29647     ' >$as_me.lineno &&
29648   chmod +x "$as_me.lineno" ||
29649     { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2
29650    { (exit 1); exit 1; }; }
29651
29652   # Don't try to exec as it changes $[0], causing all sort of problems
29653   # (the dirname of $[0] is not the place where we might find the
29654   # original and so on.  Autoconf is especially sensitive to this).
29655   . "./$as_me.lineno"
29656   # Exit status is that of the last command.
29657   exit
29658 }
29659
29660
29661 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then
29662   as_dirname=dirname
29663 else
29664   as_dirname=false
29665 fi
29666
29667 ECHO_C= ECHO_N= ECHO_T=
29668 case `echo -n x` in
29669 -n*)
29670   case `echo 'x\c'` in
29671   *c*) ECHO_T=' ';;     # ECHO_T is single tab character.
29672   *)   ECHO_C='\c';;
29673   esac;;
29674 *)
29675   ECHO_N='-n';;
29676 esac
29677 if expr a : '\(a\)' >/dev/null 2>&1 &&
29678    test "X`expr 00001 : '.*\(...\)'`" = X001; then
29679   as_expr=expr
29680 else
29681   as_expr=false
29682 fi
29683
29684 rm -f conf$$ conf$$.exe conf$$.file
29685 if test -d conf$$.dir; then
29686   rm -f conf$$.dir/conf$$.file
29687 else
29688   rm -f conf$$.dir
29689   mkdir conf$$.dir 2>/dev/null
29690 fi
29691 if (echo >conf$$.file) 2>/dev/null; then
29692   if ln -s conf$$.file conf$$ 2>/dev/null; then
29693     as_ln_s='ln -s'
29694     # ... but there are two gotchas:
29695     # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail.
29696     # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable.
29697     # In both cases, we have to default to `cp -p'.
29698     ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe ||
29699       as_ln_s='cp -p'
29700   elif ln conf$$.file conf$$ 2>/dev/null; then
29701     as_ln_s=ln
29702   else
29703     as_ln_s='cp -p'
29704   fi
29705 else
29706   as_ln_s='cp -p'
29707 fi
29708 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file
29709 rmdir conf$$.dir 2>/dev/null
29710
29711 if mkdir -p . 2>/dev/null; then
29712   as_mkdir_p=:
29713 else
29714   test -d ./-p && rmdir ./-p
29715   as_mkdir_p=false
29716 fi
29717
29718 if test -x / >/dev/null 2>&1; then
29719   as_test_x='test -x'
29720 else
29721   if ls -dL / >/dev/null 2>&1; then
29722     as_ls_L_option=L
29723   else
29724     as_ls_L_option=
29725   fi
29726   as_test_x='
29727     eval sh -c '\''
29728       if test -d "$1"; then
29729         test -d "$1/.";
29730       else
29731         case $1 in
29732         -*)set "./$1";;
29733         esac;
29734         case `ls -ld'$as_ls_L_option' "$1" 2>/dev/null` in
29735         ???[sx]*):;;*)false;;esac;fi
29736     '\'' sh
29737   '
29738 fi
29739 as_executable_p=$as_test_x
29740
29741 # Sed expression to map a string onto a valid CPP name.
29742 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'"
29743
29744 # Sed expression to map a string onto a valid variable name.
29745 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'"
29746
29747
29748 exec 6>&1
29749
29750 # Save the log message, to keep $[0] and so on meaningful, and to
29751 # report actual input values of CONFIG_FILES etc. instead of their
29752 # values after options handling.
29753 ac_log="
29754 This file was extended by PostgreSQL $as_me 9.1devel, which was
29755 generated by GNU Autoconf 2.63.  Invocation command line was
29756
29757   CONFIG_FILES    = $CONFIG_FILES
29758   CONFIG_HEADERS  = $CONFIG_HEADERS
29759   CONFIG_LINKS    = $CONFIG_LINKS
29760   CONFIG_COMMANDS = $CONFIG_COMMANDS
29761   $ $0 $@
29762
29763 on `(hostname || uname -n) 2>/dev/null | sed 1q`
29764 "
29765
29766 _ACEOF
29767
29768 case $ac_config_files in *"
29769 "*) set x $ac_config_files; shift; ac_config_files=$*;;
29770 esac
29771
29772 case $ac_config_headers in *"
29773 "*) set x $ac_config_headers; shift; ac_config_headers=$*;;
29774 esac
29775
29776
29777 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29778 # Files that config.status was made for.
29779 config_files="$ac_config_files"
29780 config_headers="$ac_config_headers"
29781 config_links="$ac_config_links"
29782 config_commands="$ac_config_commands"
29783
29784 _ACEOF
29785
29786 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29787 ac_cs_usage="\
29788 \`$as_me' instantiates files from templates according to the
29789 current configuration.
29790
29791 Usage: $0 [OPTION]... [FILE]...
29792
29793   -h, --help       print this help, then exit
29794   -V, --version    print version number and configuration settings, then exit
29795   -q, --quiet, --silent
29796                    do not print progress messages
29797   -d, --debug      don't remove temporary files
29798       --recheck    update $as_me by reconfiguring in the same conditions
29799       --file=FILE[:TEMPLATE]
29800                    instantiate the configuration file FILE
29801       --header=FILE[:TEMPLATE]
29802                    instantiate the configuration header FILE
29803
29804 Configuration files:
29805 $config_files
29806
29807 Configuration headers:
29808 $config_headers
29809
29810 Configuration links:
29811 $config_links
29812
29813 Configuration commands:
29814 $config_commands
29815
29816 Report bugs to <bug-autoconf@gnu.org>."
29817
29818 _ACEOF
29819 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29820 ac_cs_version="\\
29821 PostgreSQL config.status 9.1devel
29822 configured by $0, generated by GNU Autoconf 2.63,
29823   with options \\"`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`\\"
29824
29825 Copyright (C) 2008 Free Software Foundation, Inc.
29826 This config.status script is free software; the Free Software Foundation
29827 gives unlimited permission to copy, distribute and modify it."
29828
29829 ac_pwd='$ac_pwd'
29830 srcdir='$srcdir'
29831 MKDIR_P='$MKDIR_P'
29832 AWK='$AWK'
29833 test -n "\$AWK" || AWK=awk
29834 _ACEOF
29835
29836 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29837 # The default lists apply if the user does not specify any file.
29838 ac_need_defaults=:
29839 while test $# != 0
29840 do
29841   case $1 in
29842   --*=*)
29843     ac_option=`expr "X$1" : 'X\([^=]*\)='`
29844     ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'`
29845     ac_shift=:
29846     ;;
29847   *)
29848     ac_option=$1
29849     ac_optarg=$2
29850     ac_shift=shift
29851     ;;
29852   esac
29853
29854   case $ac_option in
29855   # Handling of the options.
29856   -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r)
29857     ac_cs_recheck=: ;;
29858   --version | --versio | --versi | --vers | --ver | --ve | --v | -V )
29859     $as_echo "$ac_cs_version"; exit ;;
29860   --debug | --debu | --deb | --de | --d | -d )
29861     debug=: ;;
29862   --file | --fil | --fi | --f )
29863     $ac_shift
29864     case $ac_optarg in
29865     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29866     esac
29867     CONFIG_FILES="$CONFIG_FILES '$ac_optarg'"
29868     ac_need_defaults=false;;
29869   --header | --heade | --head | --hea )
29870     $ac_shift
29871     case $ac_optarg in
29872     *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;;
29873     esac
29874     CONFIG_HEADERS="$CONFIG_HEADERS '$ac_optarg'"
29875     ac_need_defaults=false;;
29876   --he | --h)
29877     # Conflict between --help and --header
29878     { $as_echo "$as_me: error: ambiguous option: $1
29879 Try \`$0 --help' for more information." >&2
29880    { (exit 1); exit 1; }; };;
29881   --help | --hel | -h )
29882     $as_echo "$ac_cs_usage"; exit ;;
29883   -q | -quiet | --quiet | --quie | --qui | --qu | --q \
29884   | -silent | --silent | --silen | --sile | --sil | --si | --s)
29885     ac_cs_silent=: ;;
29886
29887   # This is an error.
29888   -*) { $as_echo "$as_me: error: unrecognized option: $1
29889 Try \`$0 --help' for more information." >&2
29890    { (exit 1); exit 1; }; } ;;
29891
29892   *) ac_config_targets="$ac_config_targets $1"
29893      ac_need_defaults=false ;;
29894
29895   esac
29896   shift
29897 done
29898
29899 ac_configure_extra_args=
29900
29901 if $ac_cs_silent; then
29902   exec 6>/dev/null
29903   ac_configure_extra_args="$ac_configure_extra_args --silent"
29904 fi
29905
29906 _ACEOF
29907 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29908 if \$ac_cs_recheck; then
29909   set X '$SHELL' '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion
29910   shift
29911   \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6
29912   CONFIG_SHELL='$SHELL'
29913   export CONFIG_SHELL
29914   exec "\$@"
29915 fi
29916
29917 _ACEOF
29918 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29919 exec 5>>config.log
29920 {
29921   echo
29922   sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX
29923 ## Running $as_me. ##
29924 _ASBOX
29925   $as_echo "$ac_log"
29926 } >&5
29927
29928 _ACEOF
29929 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
29930 _ACEOF
29931
29932 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
29933
29934 # Handling of arguments.
29935 for ac_config_target in $ac_config_targets
29936 do
29937   case $ac_config_target in
29938     "src/backend/port/tas.s") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/tas.s:src/backend/port/tas/${tas_file}" ;;
29939     "GNUmakefile") CONFIG_FILES="$CONFIG_FILES GNUmakefile" ;;
29940     "src/Makefile.global") CONFIG_FILES="$CONFIG_FILES src/Makefile.global" ;;
29941     "src/backend/port/dynloader.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/dynloader.c:src/backend/port/dynloader/${template}.c" ;;
29942     "src/backend/port/pg_sema.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_sema.c:${SEMA_IMPLEMENTATION}" ;;
29943     "src/backend/port/pg_shmem.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_shmem.c:${SHMEM_IMPLEMENTATION}" ;;
29944     "src/backend/port/pg_latch.c") CONFIG_LINKS="$CONFIG_LINKS src/backend/port/pg_latch.c:${LATCH_IMPLEMENTATION}" ;;
29945     "src/include/dynloader.h") CONFIG_LINKS="$CONFIG_LINKS src/include/dynloader.h:src/backend/port/dynloader/${template}.h" ;;
29946     "src/include/pg_config_os.h") CONFIG_LINKS="$CONFIG_LINKS src/include/pg_config_os.h:src/include/port/${template}.h" ;;
29947     "src/Makefile.port") CONFIG_LINKS="$CONFIG_LINKS src/Makefile.port:src/makefiles/Makefile.${template}" ;;
29948     "check_win32_symlinks") CONFIG_COMMANDS="$CONFIG_COMMANDS check_win32_symlinks" ;;
29949     "src/include/pg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/include/pg_config.h" ;;
29950     "src/interfaces/ecpg/include/ecpg_config.h") CONFIG_HEADERS="$CONFIG_HEADERS src/interfaces/ecpg/include/ecpg_config.h" ;;
29951
29952   *) { { $as_echo "$as_me:$LINENO: error: invalid argument: $ac_config_target" >&5
29953 $as_echo "$as_me: error: invalid argument: $ac_config_target" >&2;}
29954    { (exit 1); exit 1; }; };;
29955   esac
29956 done
29957
29958
29959 # If the user did not use the arguments to specify the items to instantiate,
29960 # then the envvar interface is used.  Set only those that are not.
29961 # We use the long form for the default assignment because of an extremely
29962 # bizarre bug on SunOS 4.1.3.
29963 if $ac_need_defaults; then
29964   test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files
29965   test "${CONFIG_HEADERS+set}" = set || CONFIG_HEADERS=$config_headers
29966   test "${CONFIG_LINKS+set}" = set || CONFIG_LINKS=$config_links
29967   test "${CONFIG_COMMANDS+set}" = set || CONFIG_COMMANDS=$config_commands
29968 fi
29969
29970 # Have a temporary directory for convenience.  Make it in the build tree
29971 # simply because there is no reason against having it here, and in addition,
29972 # creating and moving files from /tmp can sometimes cause problems.
29973 # Hook for its removal unless debugging.
29974 # Note that there is a small window in which the directory will not be cleaned:
29975 # after its creation but before its name has been assigned to `$tmp'.
29976 $debug ||
29977 {
29978   tmp=
29979   trap 'exit_status=$?
29980   { test -z "$tmp" || test ! -d "$tmp" || rm -fr "$tmp"; } && exit $exit_status
29981 ' 0
29982   trap '{ (exit 1); exit 1; }' 1 2 13 15
29983 }
29984 # Create a (secure) tmp directory for tmp files.
29985
29986 {
29987   tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` &&
29988   test -n "$tmp" && test -d "$tmp"
29989 }  ||
29990 {
29991   tmp=./conf$$-$RANDOM
29992   (umask 077 && mkdir "$tmp")
29993 } ||
29994 {
29995    $as_echo "$as_me: cannot create a temporary directory in ." >&2
29996    { (exit 1); exit 1; }
29997 }
29998
29999 # Set up the scripts for CONFIG_FILES section.
30000 # No need to generate them if there are no CONFIG_FILES.
30001 # This happens for instance with `./config.status config.h'.
30002 if test -n "$CONFIG_FILES"; then
30003
30004
30005 ac_cr='\r'
30006 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null`
30007 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then
30008   ac_cs_awk_cr='\\r'
30009 else
30010   ac_cs_awk_cr=$ac_cr
30011 fi
30012
30013 echo 'BEGIN {' >"$tmp/subs1.awk" &&
30014 _ACEOF
30015
30016
30017 {
30018   echo "cat >conf$$subs.awk <<_ACEOF" &&
30019   echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' &&
30020   echo "_ACEOF"
30021 } >conf$$subs.sh ||
30022   { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
30023 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
30024    { (exit 1); exit 1; }; }
30025 ac_delim_num=`echo "$ac_subst_vars" | grep -c '$'`
30026 ac_delim='%!_!# '
30027 for ac_last_try in false false false false false :; do
30028   . ./conf$$subs.sh ||
30029     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
30030 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
30031    { (exit 1); exit 1; }; }
30032
30033   ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X`
30034   if test $ac_delim_n = $ac_delim_num; then
30035     break
30036   elif $ac_last_try; then
30037     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_STATUS" >&5
30038 $as_echo "$as_me: error: could not make $CONFIG_STATUS" >&2;}
30039    { (exit 1); exit 1; }; }
30040   else
30041     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30042   fi
30043 done
30044 rm -f conf$$subs.sh
30045
30046 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30047 cat >>"\$tmp/subs1.awk" <<\\_ACAWK &&
30048 _ACEOF
30049 sed -n '
30050 h
30051 s/^/S["/; s/!.*/"]=/
30052 p
30053 g
30054 s/^[^!]*!//
30055 :repl
30056 t repl
30057 s/'"$ac_delim"'$//
30058 t delim
30059 :nl
30060 h
30061 s/\(.\{148\}\).*/\1/
30062 t more1
30063 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/
30064 p
30065 n
30066 b repl
30067 :more1
30068 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30069 p
30070 g
30071 s/.\{148\}//
30072 t nl
30073 :delim
30074 h
30075 s/\(.\{148\}\).*/\1/
30076 t more2
30077 s/["\\]/\\&/g; s/^/"/; s/$/"/
30078 p
30079 b
30080 :more2
30081 s/["\\]/\\&/g; s/^/"/; s/$/"\\/
30082 p
30083 g
30084 s/.\{148\}//
30085 t delim
30086 ' <conf$$subs.awk | sed '
30087 /^[^""]/{
30088   N
30089   s/\n//
30090 }
30091 ' >>$CONFIG_STATUS || ac_write_fail=1
30092 rm -f conf$$subs.awk
30093 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30094 _ACAWK
30095 cat >>"\$tmp/subs1.awk" <<_ACAWK &&
30096   for (key in S) S_is_set[key] = 1
30097   FS = "\a"
30098
30099 }
30100 {
30101   line = $ 0
30102   nfields = split(line, field, "@")
30103   substed = 0
30104   len = length(field[1])
30105   for (i = 2; i < nfields; i++) {
30106     key = field[i]
30107     keylen = length(key)
30108     if (S_is_set[key]) {
30109       value = S[key]
30110       line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3)
30111       len += length(value) + length(field[++i])
30112       substed = 1
30113     } else
30114       len += 1 + keylen
30115   }
30116
30117   print line
30118 }
30119
30120 _ACAWK
30121 _ACEOF
30122 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30123 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then
30124   sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g"
30125 else
30126   cat
30127 fi < "$tmp/subs1.awk" > "$tmp/subs.awk" \
30128   || { { $as_echo "$as_me:$LINENO: error: could not setup config files machinery" >&5
30129 $as_echo "$as_me: error: could not setup config files machinery" >&2;}
30130    { (exit 1); exit 1; }; }
30131 _ACEOF
30132
30133 # VPATH may cause trouble with some makes, so we remove $(srcdir),
30134 # ${srcdir} and @srcdir@ from VPATH if srcdir is ".", strip leading and
30135 # trailing colons and then remove the whole line if VPATH becomes empty
30136 # (actually we leave an empty line to preserve line numbers).
30137 if test "x$srcdir" = x.; then
30138   ac_vpsub='/^[  ]*VPATH[        ]*=/{
30139 s/:*\$(srcdir):*/:/
30140 s/:*\${srcdir}:*/:/
30141 s/:*@srcdir@:*/:/
30142 s/^\([^=]*=[     ]*\):*/\1/
30143 s/:*$//
30144 s/^[^=]*=[       ]*$//
30145 }'
30146 fi
30147
30148 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30149 fi # test -n "$CONFIG_FILES"
30150
30151 # Set up the scripts for CONFIG_HEADERS section.
30152 # No need to generate them if there are no CONFIG_HEADERS.
30153 # This happens for instance with `./config.status Makefile'.
30154 if test -n "$CONFIG_HEADERS"; then
30155 cat >"$tmp/defines.awk" <<\_ACAWK ||
30156 BEGIN {
30157 _ACEOF
30158
30159 # Transform confdefs.h into an awk script `defines.awk', embedded as
30160 # here-document in config.status, that substitutes the proper values into
30161 # config.h.in to produce config.h.
30162
30163 # Create a delimiter string that does not exist in confdefs.h, to ease
30164 # handling of long lines.
30165 ac_delim='%!_!# '
30166 for ac_last_try in false false :; do
30167   ac_t=`sed -n "/$ac_delim/p" confdefs.h`
30168   if test -z "$ac_t"; then
30169     break
30170   elif $ac_last_try; then
30171     { { $as_echo "$as_me:$LINENO: error: could not make $CONFIG_HEADERS" >&5
30172 $as_echo "$as_me: error: could not make $CONFIG_HEADERS" >&2;}
30173    { (exit 1); exit 1; }; }
30174   else
30175     ac_delim="$ac_delim!$ac_delim _$ac_delim!! "
30176   fi
30177 done
30178
30179 # For the awk script, D is an array of macro values keyed by name,
30180 # likewise P contains macro parameters if any.  Preserve backslash
30181 # newline sequences.
30182
30183 ac_word_re=[_$as_cr_Letters][_$as_cr_alnum]*
30184 sed -n '
30185 s/.\{148\}/&'"$ac_delim"'/g
30186 t rset
30187 :rset
30188 s/^[     ]*#[    ]*define[       ][      ]*/ /
30189 t def
30190 d
30191 :def
30192 s/\\$//
30193 t bsnl
30194 s/["\\]/\\&/g
30195 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
30196 D["\1"]=" \3"/p
30197 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2"/p
30198 d
30199 :bsnl
30200 s/["\\]/\\&/g
30201 s/^ \('"$ac_word_re"'\)\(([^()]*)\)[     ]*\(.*\)/P["\1"]="\2"\
30202 D["\1"]=" \3\\\\\\n"\\/p
30203 t cont
30204 s/^ \('"$ac_word_re"'\)[         ]*\(.*\)/D["\1"]=" \2\\\\\\n"\\/p
30205 t cont
30206 d
30207 :cont
30208 n
30209 s/.\{148\}/&'"$ac_delim"'/g
30210 t clear
30211 :clear
30212 s/\\$//
30213 t bsnlc
30214 s/["\\]/\\&/g; s/^/"/; s/$/"/p
30215 d
30216 :bsnlc
30217 s/["\\]/\\&/g; s/^/"/; s/$/\\\\\\n"\\/p
30218 b cont
30219 ' <confdefs.h | sed '
30220 s/'"$ac_delim"'/"\\\
30221 "/g' >>$CONFIG_STATUS || ac_write_fail=1
30222
30223 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30224   for (key in D) D_is_set[key] = 1
30225   FS = "\a"
30226 }
30227 /^[\t ]*#[\t ]*(define|undef)[\t ]+$ac_word_re([\t (]|\$)/ {
30228   line = \$ 0
30229   split(line, arg, " ")
30230   if (arg[1] == "#") {
30231     defundef = arg[2]
30232     mac1 = arg[3]
30233   } else {
30234     defundef = substr(arg[1], 2)
30235     mac1 = arg[2]
30236   }
30237   split(mac1, mac2, "(") #)
30238   macro = mac2[1]
30239   prefix = substr(line, 1, index(line, defundef) - 1)
30240   if (D_is_set[macro]) {
30241     # Preserve the white space surrounding the "#".
30242     print prefix "define", macro P[macro] D[macro]
30243     next
30244   } else {
30245     # Replace #undef with comments.  This is necessary, for example,
30246     # in the case of _POSIX_SOURCE, which is predefined and required
30247     # on some systems where configure will not decide to define it.
30248     if (defundef == "undef") {
30249       print "/*", prefix defundef, macro, "*/"
30250       next
30251     }
30252   }
30253 }
30254 { print }
30255 _ACAWK
30256 _ACEOF
30257 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30258   { { $as_echo "$as_me:$LINENO: error: could not setup config headers machinery" >&5
30259 $as_echo "$as_me: error: could not setup config headers machinery" >&2;}
30260    { (exit 1); exit 1; }; }
30261 fi # test -n "$CONFIG_HEADERS"
30262
30263
30264 eval set X "  :F $CONFIG_FILES  :H $CONFIG_HEADERS  :L $CONFIG_LINKS  :C $CONFIG_COMMANDS"
30265 shift
30266 for ac_tag
30267 do
30268   case $ac_tag in
30269   :[FHLC]) ac_mode=$ac_tag; continue;;
30270   esac
30271   case $ac_mode$ac_tag in
30272   :[FHL]*:*);;
30273   :L* | :C*:*) { { $as_echo "$as_me:$LINENO: error: invalid tag $ac_tag" >&5
30274 $as_echo "$as_me: error: invalid tag $ac_tag" >&2;}
30275    { (exit 1); exit 1; }; };;
30276   :[FH]-) ac_tag=-:-;;
30277   :[FH]*) ac_tag=$ac_tag:$ac_tag.in;;
30278   esac
30279   ac_save_IFS=$IFS
30280   IFS=:
30281   set x $ac_tag
30282   IFS=$ac_save_IFS
30283   shift
30284   ac_file=$1
30285   shift
30286
30287   case $ac_mode in
30288   :L) ac_source=$1;;
30289   :[FH])
30290     ac_file_inputs=
30291     for ac_f
30292     do
30293       case $ac_f in
30294       -) ac_f="$tmp/stdin";;
30295       *) # Look for the file first in the build tree, then in the source tree
30296          # (if the path is not absolute).  The absolute path cannot be DOS-style,
30297          # because $ac_f cannot contain `:'.
30298          test -f "$ac_f" ||
30299            case $ac_f in
30300            [\\/$]*) false;;
30301            *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";;
30302            esac ||
30303            { { $as_echo "$as_me:$LINENO: error: cannot find input file: $ac_f" >&5
30304 $as_echo "$as_me: error: cannot find input file: $ac_f" >&2;}
30305    { (exit 1); exit 1; }; };;
30306       esac
30307       case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac
30308       ac_file_inputs="$ac_file_inputs '$ac_f'"
30309     done
30310
30311     # Let's still pretend it is `configure' which instantiates (i.e., don't
30312     # use $as_me), people would be surprised to read:
30313     #    /* config.h.  Generated by config.status.  */
30314     configure_input='Generated from '`
30315           $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g'
30316         `' by configure.'
30317     if test x"$ac_file" != x-; then
30318       configure_input="$ac_file.  $configure_input"
30319       { $as_echo "$as_me:$LINENO: creating $ac_file" >&5
30320 $as_echo "$as_me: creating $ac_file" >&6;}
30321     fi
30322     # Neutralize special characters interpreted by sed in replacement strings.
30323     case $configure_input in #(
30324     *\&* | *\|* | *\\* )
30325        ac_sed_conf_input=`$as_echo "$configure_input" |
30326        sed 's/[\\\\&|]/\\\\&/g'`;; #(
30327     *) ac_sed_conf_input=$configure_input;;
30328     esac
30329
30330     case $ac_tag in
30331     *:-:* | *:-) cat >"$tmp/stdin" \
30332       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30333 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30334    { (exit 1); exit 1; }; } ;;
30335     esac
30336     ;;
30337   esac
30338
30339   ac_dir=`$as_dirname -- "$ac_file" ||
30340 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30341          X"$ac_file" : 'X\(//\)[^/]' \| \
30342          X"$ac_file" : 'X\(//\)$' \| \
30343          X"$ac_file" : 'X\(/\)' \| . 2>/dev/null ||
30344 $as_echo X"$ac_file" |
30345     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30346             s//\1/
30347             q
30348           }
30349           /^X\(\/\/\)[^/].*/{
30350             s//\1/
30351             q
30352           }
30353           /^X\(\/\/\)$/{
30354             s//\1/
30355             q
30356           }
30357           /^X\(\/\).*/{
30358             s//\1/
30359             q
30360           }
30361           s/.*/./; q'`
30362   { as_dir="$ac_dir"
30363   case $as_dir in #(
30364   -*) as_dir=./$as_dir;;
30365   esac
30366   test -d "$as_dir" || { $as_mkdir_p && mkdir -p "$as_dir"; } || {
30367     as_dirs=
30368     while :; do
30369       case $as_dir in #(
30370       *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'(
30371       *) as_qdir=$as_dir;;
30372       esac
30373       as_dirs="'$as_qdir' $as_dirs"
30374       as_dir=`$as_dirname -- "$as_dir" ||
30375 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \
30376          X"$as_dir" : 'X\(//\)[^/]' \| \
30377          X"$as_dir" : 'X\(//\)$' \| \
30378          X"$as_dir" : 'X\(/\)' \| . 2>/dev/null ||
30379 $as_echo X"$as_dir" |
30380     sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{
30381             s//\1/
30382             q
30383           }
30384           /^X\(\/\/\)[^/].*/{
30385             s//\1/
30386             q
30387           }
30388           /^X\(\/\/\)$/{
30389             s//\1/
30390             q
30391           }
30392           /^X\(\/\).*/{
30393             s//\1/
30394             q
30395           }
30396           s/.*/./; q'`
30397       test -d "$as_dir" && break
30398     done
30399     test -z "$as_dirs" || eval "mkdir $as_dirs"
30400   } || test -d "$as_dir" || { { $as_echo "$as_me:$LINENO: error: cannot create directory $as_dir" >&5
30401 $as_echo "$as_me: error: cannot create directory $as_dir" >&2;}
30402    { (exit 1); exit 1; }; }; }
30403   ac_builddir=.
30404
30405 case "$ac_dir" in
30406 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;;
30407 *)
30408   ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'`
30409   # A ".." for each directory in $ac_dir_suffix.
30410   ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'`
30411   case $ac_top_builddir_sub in
30412   "") ac_top_builddir_sub=. ac_top_build_prefix= ;;
30413   *)  ac_top_build_prefix=$ac_top_builddir_sub/ ;;
30414   esac ;;
30415 esac
30416 ac_abs_top_builddir=$ac_pwd
30417 ac_abs_builddir=$ac_pwd$ac_dir_suffix
30418 # for backward compatibility:
30419 ac_top_builddir=$ac_top_build_prefix
30420
30421 case $srcdir in
30422   .)  # We are building in place.
30423     ac_srcdir=.
30424     ac_top_srcdir=$ac_top_builddir_sub
30425     ac_abs_top_srcdir=$ac_pwd ;;
30426   [\\/]* | ?:[\\/]* )  # Absolute name.
30427     ac_srcdir=$srcdir$ac_dir_suffix;
30428     ac_top_srcdir=$srcdir
30429     ac_abs_top_srcdir=$srcdir ;;
30430   *) # Relative name.
30431     ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix
30432     ac_top_srcdir=$ac_top_build_prefix$srcdir
30433     ac_abs_top_srcdir=$ac_pwd/$srcdir ;;
30434 esac
30435 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix
30436
30437
30438   case $ac_mode in
30439   :F)
30440   #
30441   # CONFIG_FILE
30442   #
30443
30444   ac_MKDIR_P=$MKDIR_P
30445   case $MKDIR_P in
30446   [\\/$]* | ?:[\\/]* ) ;;
30447   */*) ac_MKDIR_P=$ac_top_build_prefix$MKDIR_P ;;
30448   esac
30449 _ACEOF
30450
30451 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30452 # If the template does not know about datarootdir, expand it.
30453 # FIXME: This hack should be removed a few years after 2.60.
30454 ac_datarootdir_hack=; ac_datarootdir_seen=
30455
30456 ac_sed_dataroot='
30457 /datarootdir/ {
30458   p
30459   q
30460 }
30461 /@datadir@/p
30462 /@docdir@/p
30463 /@infodir@/p
30464 /@localedir@/p
30465 /@mandir@/p
30466 '
30467 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in
30468 *datarootdir*) ac_datarootdir_seen=yes;;
30469 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*)
30470   { $as_echo "$as_me:$LINENO: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5
30471 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;}
30472 _ACEOF
30473 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30474   ac_datarootdir_hack='
30475   s&@datadir@&$datadir&g
30476   s&@docdir@&$docdir&g
30477   s&@infodir@&$infodir&g
30478   s&@localedir@&$localedir&g
30479   s&@mandir@&$mandir&g
30480     s&\\\${datarootdir}&$datarootdir&g' ;;
30481 esac
30482 _ACEOF
30483
30484 # Neutralize VPATH when `$srcdir' = `.'.
30485 # Shell code in configure.ac might set extrasub.
30486 # FIXME: do we really want to maintain this feature?
30487 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
30488 ac_sed_extra="$ac_vpsub
30489 $extrasub
30490 _ACEOF
30491 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
30492 :t
30493 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b
30494 s|@configure_input@|$ac_sed_conf_input|;t t
30495 s&@top_builddir@&$ac_top_builddir_sub&;t t
30496 s&@top_build_prefix@&$ac_top_build_prefix&;t t
30497 s&@srcdir@&$ac_srcdir&;t t
30498 s&@abs_srcdir@&$ac_abs_srcdir&;t t
30499 s&@top_srcdir@&$ac_top_srcdir&;t t
30500 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t
30501 s&@builddir@&$ac_builddir&;t t
30502 s&@abs_builddir@&$ac_abs_builddir&;t t
30503 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t
30504 s&@MKDIR_P@&$ac_MKDIR_P&;t t
30505 $ac_datarootdir_hack
30506 "
30507 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$tmp/subs.awk" >$tmp/out \
30508   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30509 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30510    { (exit 1); exit 1; }; }
30511
30512 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" &&
30513   { ac_out=`sed -n '/\${datarootdir}/p' "$tmp/out"`; test -n "$ac_out"; } &&
30514   { ac_out=`sed -n '/^[  ]*datarootdir[  ]*:*=/p' "$tmp/out"`; test -z "$ac_out"; } &&
30515   { $as_echo "$as_me:$LINENO: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30516 which seems to be undefined.  Please make sure it is defined." >&5
30517 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir'
30518 which seems to be undefined.  Please make sure it is defined." >&2;}
30519
30520   rm -f "$tmp/stdin"
30521   case $ac_file in
30522   -) cat "$tmp/out" && rm -f "$tmp/out";;
30523   *) rm -f "$ac_file" && mv "$tmp/out" "$ac_file";;
30524   esac \
30525   || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30526 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30527    { (exit 1); exit 1; }; }
30528  ;;
30529   :H)
30530   #
30531   # CONFIG_HEADER
30532   #
30533   if test x"$ac_file" != x-; then
30534     {
30535       $as_echo "/* $configure_input  */" \
30536       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs"
30537     } >"$tmp/config.h" \
30538       || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30539 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30540    { (exit 1); exit 1; }; }
30541     if diff "$ac_file" "$tmp/config.h" >/dev/null 2>&1; then
30542       { $as_echo "$as_me:$LINENO: $ac_file is unchanged" >&5
30543 $as_echo "$as_me: $ac_file is unchanged" >&6;}
30544     else
30545       rm -f "$ac_file"
30546       mv "$tmp/config.h" "$ac_file" \
30547         || { { $as_echo "$as_me:$LINENO: error: could not create $ac_file" >&5
30548 $as_echo "$as_me: error: could not create $ac_file" >&2;}
30549    { (exit 1); exit 1; }; }
30550     fi
30551   else
30552     $as_echo "/* $configure_input  */" \
30553       && eval '$AWK -f "$tmp/defines.awk"' "$ac_file_inputs" \
30554       || { { $as_echo "$as_me:$LINENO: error: could not create -" >&5
30555 $as_echo "$as_me: error: could not create -" >&2;}
30556    { (exit 1); exit 1; }; }
30557   fi
30558  ;;
30559   :L)
30560   #
30561   # CONFIG_LINK
30562   #
30563
30564   if test "$ac_source" = "$ac_file" && test "$srcdir" = '.'; then
30565     :
30566   else
30567     # Prefer the file from the source tree if names are identical.
30568     if test "$ac_source" = "$ac_file" || test ! -r "$ac_source"; then
30569       ac_source=$srcdir/$ac_source
30570     fi
30571
30572     { $as_echo "$as_me:$LINENO: linking $ac_source to $ac_file" >&5
30573 $as_echo "$as_me: linking $ac_source to $ac_file" >&6;}
30574
30575     if test ! -r "$ac_source"; then
30576       { { $as_echo "$as_me:$LINENO: error: $ac_source: file not found" >&5
30577 $as_echo "$as_me: error: $ac_source: file not found" >&2;}
30578    { (exit 1); exit 1; }; }
30579     fi
30580     rm -f "$ac_file"
30581
30582     # Try a relative symlink, then a hard link, then a copy.
30583     case $srcdir in
30584     [\\/$]* | ?:[\\/]* ) ac_rel_source=$ac_source ;;
30585         *) ac_rel_source=$ac_top_build_prefix$ac_source ;;
30586     esac
30587     ln -s "$ac_rel_source" "$ac_file" 2>/dev/null ||
30588       ln "$ac_source" "$ac_file" 2>/dev/null ||
30589       cp -p "$ac_source" "$ac_file" ||
30590       { { $as_echo "$as_me:$LINENO: error: cannot link or copy $ac_source to $ac_file" >&5
30591 $as_echo "$as_me: error: cannot link or copy $ac_source to $ac_file" >&2;}
30592    { (exit 1); exit 1; }; }
30593   fi
30594  ;;
30595   :C)  { $as_echo "$as_me:$LINENO: executing $ac_file commands" >&5
30596 $as_echo "$as_me: executing $ac_file commands" >&6;}
30597  ;;
30598   esac
30599
30600
30601   case $ac_file$ac_mode in
30602     "check_win32_symlinks":C)
30603 # Links sometimes fail undetected on Mingw -
30604 # so here we detect it and warn the user
30605 for FILE in $CONFIG_LINKS
30606  do
30607         # test -e works for symlinks in the MinGW console
30608         test -e `expr "$FILE" : '\([^:]*\)'` || { $as_echo "$as_me:$LINENO: WARNING: *** link for $FILE -- please fix by hand" >&5
30609 $as_echo "$as_me: WARNING: *** link for $FILE -- please fix by hand" >&2;}
30610  done
30611  ;;
30612     "src/include/pg_config.h":H)
30613 # Update timestamp for pg_config.h (see Makefile.global)
30614 echo >src/include/stamp-h
30615  ;;
30616     "src/interfaces/ecpg/include/ecpg_config.h":H) echo >src/interfaces/ecpg/include/stamp-h ;;
30617
30618   esac
30619 done # for ac_tag
30620
30621
30622 { (exit 0); exit 0; }
30623 _ACEOF
30624 chmod +x $CONFIG_STATUS
30625 ac_clean_files=$ac_clean_files_save
30626
30627 test $ac_write_fail = 0 ||
30628   { { $as_echo "$as_me:$LINENO: error: write failure creating $CONFIG_STATUS" >&5
30629 $as_echo "$as_me: error: write failure creating $CONFIG_STATUS" >&2;}
30630    { (exit 1); exit 1; }; }
30631
30632
30633 # configure is writing to config.log, and then calls config.status.
30634 # config.status does its own redirection, appending to config.log.
30635 # Unfortunately, on DOS this fails, as config.log is still kept open
30636 # by configure, so config.status won't be able to write to it; its
30637 # output is simply discarded.  So we exec the FD to /dev/null,
30638 # effectively closing config.log, so it can be properly (re)opened and
30639 # appended to by config.status.  When coming back to configure, we
30640 # need to make the FD available again.
30641 if test "$no_create" != yes; then
30642   ac_cs_success=:
30643   ac_config_status_args=
30644   test "$silent" = yes &&
30645     ac_config_status_args="$ac_config_status_args --quiet"
30646   exec 5>/dev/null
30647   $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false
30648   exec 5>>config.log
30649   # Use ||, not &&, to avoid exiting from the if with $? = 1, which
30650   # would make configure fail if this is the last instruction.
30651   $ac_cs_success || { (exit 1); exit 1; }
30652 fi
30653 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then
30654   { $as_echo "$as_me:$LINENO: WARNING: unrecognized options: $ac_unrecognized_opts" >&5
30655 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;}
30656 fi
30657